## jts-topo-suite-user

 [Jts-topo-suite-user] Topological sorting of triangles From: Brian Sanjeewa Rupasinghe - 2013-04-27 08:50:23 Attachments: Message as HTML Thanks Stefan, I manged to get the adjacent candidates for each triangle with the method Martin suggested, maintaining edge adjacency list of normalized edges. Best, Brian.
 Re: [Jts-topo-suite-user] Topological sorting of triangles From: Brian Sanjeewa Rupasinghe - 2013-04-28 10:16:10 Attachments: Message as HTML Hi Stefan, Although I can get the adjacent triangle IDs for each triangle, it is difficult to rearrange the triangulation array according to adjacent sequence. What about the method you suggested? Can't we create the MBR of each triangle, rotate each MBR along X-Y axes, get the lower coordiante pair of each rotated MBR and sort along X-Y....? Brian. On Sat, Apr 27, 2013 at 9:50 AM, Brian Sanjeewa Rupasinghe < jinkabs@...> wrote: > Thanks Stefan, > > I manged to get the adjacent candidates for each triangle with the method > Martin suggested, maintaining edge adjacency list of normalized edges. > > Best, Brian. >
 [Jts-topo-suite-user] Overlapping Geometries From: Shahak Nagiel - 2013-05-01 18:23:29 Attachments: Message as HTML I've got two multipolygons which--visually and by design--intersect but should not overlap.  (Visualize two adjacent zip codes/cities/counties/countries.)  However, poly1.overlaps(poly2) returns true. So I get the IntersectionMatrix (poly1.relate(poly2)), which yields: 212-111-212.  This confuses me.  The boundary-boundary relationship (1) suggests they share only a one-dimensional boundary.  Indeed, calling poly1.intersection(poly2) yields a multilinestring.  But the interior-interior relationship (2) suggests a two-dimensional overlap, and would explain why poly1.overlaps(poly2) returns true. In a unit test with simpler geometries (two overlapping squares), I find a similar relationship: 212-101-212, the key difference being the boundary-boundary relationship (0 in this case).  This makes sense, since their boundaries cross at (0-dimensional) points, and their overlap is a 2-dimensional polygon.  When I line them up side-by-side, then I get the expected relationship FF2-F11-212 and square1.overlaps(square2) == false.  So, in other words, I'm unable to duplicate the relationship I see with the poly's above. Can anyone make sense of this? Thanks!