I need a Lisp routine that will find gaps and also intersections between vetices of
2D polyline sections. The routine should joint the gaps between vertices that are
a given distance to each other. This distance can be a variable in the routine.
Sections that intersect each other should also be trimmed to the intersection point.
Objective is to joint all the sections into one continuous and closed polyline.