Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

3
  • $\begingroup$ I think that nf in the first block finds the segment whose extended line is closest to a point. But the problem is about distance to a segment only, not to its extended line, isn't it? $\endgroup$ Commented Apr 19, 2013 at 9:01
  • $\begingroup$ How then do you define "distance to a segment"? $\endgroup$ Commented Apr 19, 2013 at 9:02
  • $\begingroup$ Something like Min[EuclideanDistance[p1 + t (p2 - p1), p3]] with 0 < t < 1. $\endgroup$ Commented Apr 19, 2013 at 9:32