Zero-Length Edges

A general question… I model mostly with solids usually destined for 3d print and often use sub-object selection to move faces, and edges. I’m aware doing this is not always perfect but is very stable for my purposes. One thing I know to avoid are the operations in the image below. Are there easy eays to find and eliminate zero-length surfaces? I understand nurbs have 4 edges so I need to replace the first example with a trimmed surface but I’m not really sure I’ve ever seen issues with booleans, mesh generation, etc. I cant find any good discussions about this I’m just curious to learn a little more.

Hi Alexander - the first thing to try, at least, is to run Check on the objects if you are suspicious - if Check does not say it is valid, try ExtractBadSrf and see if any of those skinnies is pulled out.


Does this end up with the same polysrfs as selbadobjects? If so, zero-length (maybe zero area is more apt) surfaces are not always found. I just tested with a simple case.

Hi Alexander - it is the same in my simple test, but I guess you’ve just shown that is not necessarily useful…

@Alexander_Kaplan - in case it helps - here’s a quick script that will mark very short edges - it may help in locating these skinnies. Use it with RunPythonScript or -RunPythonScript "Full path to script file in double quotes" (721 Bytes)

Note this thing just looks for very short edges so far - that will get you some markers on edges that happen to be fragmented or split up but are not on any ultra skinny faces - false positives if you will. I’ll see if I can make it smarter.



This makes sense to me. I’ll use this test alongside edge tolerance when I’m doing exports. False positives are fine by me. I just like having clean solids and I’ve noticed this is a bad feature I’m often making. Revit & sketchup both do not like them.

Hi Alexander - another tactic is to select the polysurface, Explode , Join and see if the slivers are left out of the result.


Oh true. Nice, thanks.

Interestingly, while it is easy to know if a face is tiny, it looks to me like it is not obvious how to mark a degenerate face in 3d based on the information from the face itself - bounding boxes, evaluation at parameters, area centroids, edge parameters are all incorrect or likely to be, and result in markers off of the face itself.



Are you using a test that isn’t the simple case? Your script correctly identifies short edges. Rather, I guess you’re looking to mark the center of the face? For me identifying tiny edges is equivalent to identifying degenerate faces. Either way its a symptom and I know how to find and delete the face

Yeah, I know it works OK and it’s not an emergency or anything, I was hoping to just work off zero-area faces and avoid the possibly misleading short edges, which can exist on a perfectly OK face. So, yes, I can find zero or near zero area faces but when they are zero area, marking the middle of one of these, or the middle of one of its edges, is problematic.


1 Like

I went searching for this feature, and of course it’s a script from you. :laughing:

If I could wish for a feature here it would be to have the script ask for a maximum length and then mark all edges below that length of the polysurface (I’m not only on the hunt for zero-length edges, but also for very small edges resulting from improper “match by closest points” usage).

Hello - I found one of those as well - see how this works: (1.8 KB)

To use the Python script use RunPythonScript, or a macro:

_-RunPythonScript "Full path to py file inside double-quotes"



Absolutely amazing! Thank you so much once again (and my god, this should really be a part of the built-in analyze menu). :+1::trophy:

(EDIT: Also, ouch… my model is much worse than I thought…) :rofl:

Oh, I just noticed that an offset with Solid=Yes produced some zero-length edges, yet it’s still a closed polysurface… hmm…