Grasshopper

algorithmic modeling for Rhino

Automate area calculations of urban planning volumes

Hi Everyone

First time with grasshopper, so bear with me on this one...

I want to do what I think should be a fairly simple script, I will try to describe it.

I have been doing a lot of urban planning projects lately and would like to automate some of the work - I've looked into buying a life-size robot but found that to be slightly over my current budget - so instead I want to do the following:

Imagine a alot of simple boxes (and simple polygon extrusions) scattered in a rhino model. I would like to know the total area of each box (several floors on most of them). Then I would like to place a text tag at the center of each volume (projected to z=0) displaying how many floors, what the footprint and total area of the building is.


Bonus would be to name each volume uniquely like this for example: 001, 002, 003 etc. And then of course export to excell.

I have gotten the main part working, but something is wrong. As you can see, I can only get the total area of both boxes and not the individual total area of each box.

Any ideas would be greatly appreciated!

Best regards

Mikkel, Denmark

Views: 8144

Replies to This Discussion

use shift path .. rather than flatten

That worked! Thanks very much! I still have an issue though. When the contour cuts at excactly the lowest face it can't figure out what to do with the area of that contour. Sometimes it is included in the calculation of the total area and sometimes it isn't. Can't really figure out what to do about it...

Thankyou very much for your help so far!

Best

Mikkel

If the forms are regular shapes like shown here, I would just do the calculations mathematically...figure out the height, divide by floor to floor, multiply that number by the product of the length times the width...

This is helpful if you have many buildings...contour and area can be heavy in such situations so doing it mathematically will speed things up considerably.

Ok - that sounds reasonable. But how would you get the footprint of the objects to use in that calculation?

Best Mikkel 

well, you could extract the wireframe curves of the 'building' and get three curves, one for the length, one for the width and one for the height...

You could either use Brep Components to explode the building into separate faces. Then select the ground face either by sorting them on height or knowing which face it will be i=4 probably.

Or alternatively you could use the Box Components to get the sizes of the XYZ domains

Hi again

Worked a bit further and have now reached a viable solution. If anyone can use it - here is a link for it:

LINK

https://dl.dropbox.com/u/3783295/AREA%20CALCULATION%20METHOD_06.gh

And here is what i looks like - can proparbly be simplified quite a bit - but now it works.

Best regards

MikkelNext up is outputting this to a nice and tidy excel sheet. 

Oh - and naming each brep automatically... Like building_001 building_002 etc.

hey do you still have this?

RSS

About

Translate

Search

Videos

  • Add Videos
  • View All

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service