Hello everybody,

I was wondering if there is a way to figure out the shortest and farthest distance within any given Brep. I want to use the ratio of this as a way of describing the complexity.

Would be super grateful for any help! Thanks

Hello everybody,

I was wondering if there is a way to figure out the shortest and farthest distance within any given Brep. I want to use the ratio of this as a way of describing the complexity.

Would be super grateful for any help! Thanks

If you share a Rhino file with some BREP examples, we can take a look.

You might need to be a bit more explicit about what those terms mean. But if they refer to analysing thickness, one can implement the native RhinoCommon method in a scripting component:

Also welcome on board

So my idea is to find the smallest axis and the longest axis in the geometry (similar to calculating the eccentricity of an ellipse). Maybe one can better understand what I mean in the picture. The red arrow being the longest axis and the green arrow the shortest. Thanks for the help so far

But that green arrow goes outside the brep !? And itâ€™s not the shortest â€śaxisâ€ť anyway, a vertical line would be shorter.

Obvious, right? So how come you had to be asked to post geometry? And when you did, itâ€™s an R8 file that canâ€™t be opened in R7.

1 Like

And longest distance as well - would surely run the length of the part (or diagonally etc). Longest and Shortest need to be much more explicitly defined before building this in GH. Unless all they want is the max/min distance in a particular cross-section. I dunno.

1 Like

Thanks for the replies. Sorry I was a bit unclear on what I meant. An easier example would be this geometry with both axis going through the centre of the geometry (incorrectly drawn on my other picture sorry about that). Then the idea is that one axis finds the shortest distance within the geometry intersecting with the centre of the geometry. The same for the other axis only that it searches for the longest distance.

Geometry Example.3dm (90.8 KB)

How are you defining center? Volume centroid? Area centriod? Center of the bounding box with a specified orientation? Somthing else???

1 Like

Volume centroid

sorry, Iâ€™m a bit slow do you mean that this measurement should be done on the XY plane passing through the Volume Centroid:

â€¦or also on Z direction?

1 Like

I thought you could read minds?

1 Like

Thanks for taking a look:) Also in the Z direction

Create lines from your volume center and where it intersects the part take a measurement.

intersect.gh (20.3 KB)