id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 13636,distance calculation can be wrong for rings with collinear segments,stfn ,Barend Gehrels,"While unit-testing our code using boost::geometry, I stumbled upon a weird distance calculation: For two rings that are perfect 2d boxes and share the orientation and one segment length, their distance is calculated as zero although they are clearly not intersecting: https://wandbox.org/permlink/Z9DMLo52IdhZRCFb I made a rough sketch of the situation: https://www.desmos.com/calculator/7jbmeu9jqq. ---- Note the line {{{ // slightly change the values vehicleRing[2] = Point2D(vehicleRing[2].x() + 1e-10, vehicleRing[2].y() + 1e-10); }}} .. changing vehicleRing[0] or vehicleRing[1] also results in zero distance, whereas slightly moving vehicleRing[2] results in the expected distance. ---- Sorry for being lazy and not finding a simpler test-case (resp. simpler numbers), I just copied the values I generated in my own testing pipeline.",Bugs,new,To Be Determined,geometry,Boost 1.67.0,Problem,,distance ring collinear pythagoras segment,