I'm trying to come up with a Perl module to turn a pile of lines into an ordered polygon. The hangup comes when you have "dead-ends" and open chains as well as multiple chains (closed and open) that could be found in one pile of lines. Anyone know of some reference material or a library for this sort of interconnected nodes problem? Google is giving me mostly image-vectorization stuff. I'm starting to think that it is nearly a traveling-salesman problem (but without the shortest path issue?) --Eric -- A counterintuitive sansevieria trifasciata was once literalized guiltily. --Product of Artificial Intelligence