algorithmic modeling for Rhino
I'm trying to construct a solid starting from the edges only. The first step, where I have some troubles, is to "group" the edges by face. If I had the edges grouped by face then I
could use BoundarySurfaces component to get all the faces and then join them into a solid.
Anyone has any suggestion?
I attached an image of my starting edges.
Thank you in advance for replies.
Thank you for your reply, I'm sorry if I were not clear in my explanation. I have to construct a solid starting from the edges and not the reverse.
I attached the Rhino file.
This is a classic closed circuit problem (very common in Graph applications). Imagine a bunch of curves (randomly sampled in a List) that are connected via some way: a Graph, that is.
Now imagine the Graph nodes (end/start vertices) and the Connectivity Tree (Vertex to vertex like the one made by Sandbox LineTopo). Based on an Adjacency Matrix extracted from that VV Tree one can compute closed circuits either for all possible combinations (not your case) of for primary islands (your case).
If we forget abstract Graph theory stuff this is used mostly in irregular "random" truss designs and other similar AEC applications. See the screenshot where the simplified demo "flat" collection of randomly sampled edges (as a Graph) yields the required closed circuits (i.e. we get a tree with the island vertex indices "sorted" appropriately).
The solution is carried over solely via code. I can't imagine any way to do that with native components. In theory the Join curves GH component should(?) be able to do that ... but it can't.
thank you for your exhaustive reply. Working on it during the way I understood that coding is the only way to solve the problem. I'm not very experienced whit code but it's a good reason to start.
Thank you very much for the explanation and the input.
Well ... this is NOT the "ideal" case to start crossing the Rubicon. As a minimum requires familiarity with connectivity concepts (like the stuff that Sandbox does) and in depth knowledge of trees (if you plan to stay in the GH bandwagon) and recursion techniques (very tricky for a newbie).
Kinda like buying a Panigale 1299 as your first motorcycle (avoid at any cost, he he).
I'll try (this w/e) to remove several sensitive portions within the available code (C#: strictly for internal use) especially stuff related with parallel processing and if the massacre yields any meaningful/working solution I'll post it here
BTW: what is your experience insofar with coding? Post here the ...er ... hmm ...trickier thingy that you've done.
Here comes the pain:
Let's forget planar stuff and the likes and stick to the general case: a graph in 2d/3d/4d/...etc.
Sandbox can't work with curves so let's use lines.
The attached uses 3 demo (line) graphs, makes a classic VV (vertex to vertex connectivity) Adjacency Matrix based on what Sandbox has to say (the Matrix is not actually required if someone wants to stay 100% in the GH world) and then ...er ... hmm ... attempts to find closed circuits as Microsoft suggests (forgot/lost the link but who cares? not me anyway [see VS stuff attached]).
It's quite faulty (like Windows) ... but is an indication on some things. Try to understand the recursion (critical in most AEC stuff). Recursion means that Matteo calls Matteo who calls Matteo ... until Matteo calls Maria and the loop is over. Notify if you need other recursion C# examples on other things (dozens available).
The working(?) chopped (minus sensitive stuff) real thing next week: just realized that this w/e there's the Malaysian MotoGP (Valentino lost the championship) AND a critical Formula 1 race in Mexico (forza Lewis).
Attached as well the original VS stuff from Microsoft (requires VS 2017)
Thank you very much for the help Peter!!
Have a nice weekend, you can stay relaxed the F1 championship is already finished for Ferrari unfortunately..
maybe you could try end points/ cull duplicates/ deconstruc points . group the ones with the closest x,y / make poly line / closed loft/ cap ex
© 2023 Created by Scott Davidson. Powered by