Sort similar geometry with matching edge dimensions

Hello everyone,

I have a question regarding sorting geometry based on their edge dimensions and bake them to different layers. Even if its the same area the dimensions might change. I have two shapes, Rectangle and traingle. What’s the best way to match dimensions of both the shapes separately? The idea is to sort similar and unique objects.

20220803_Sort similar (16.7 KB)


Here is a first approach using string representation.
Note that this will more likely not detect all the more complex cases.
If it fails at some point, you could add more information to the string (texts in the panel) that would help to detect different cases (list of angles, relative coordinate of the verticies to the center of the shape, or anything else relevant :slight_smile: )

Here you end up with a tree {A;B}[C] where
A is the type of geo
B is the different geo of each type
C is all the same geo for {A;B}

Note that you can vary the precision (slider named “Variable y”). So you also have some (small) control over the “similarity” of the shapes, without needing to be exactly the same.

20220803_Sort similar (26.3 KB)

Let me know if it helps or if you need more details !