Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I'm looking for an efficient way to determine if two paths (sets of x,y coordinates) intersect at a point.

Input - (x,y) from a Mercator Projection (longitude,latitude) coordinates

Output - Intersection point

I looked at this question here: Solve for the intersection point, given two sets of data but there doesn't seem to be an answer.

Does anyone have any suggestions on where to start?

share|improve this question
add comment

1 Answer

You can find the interpolation equation of p1=ax+b for x1,y1 points and p2=cx+d for x2,y2 points using "Least Squares method" . Then solve for p1=p2.

If you know that some intersections occurs between some "specific points inside the bound" and calculating intersection coordinates matters, you may fit the points you have in a polynomial (Using Newton's Limited Divided Differences method or Lagrange method). Then numerically solve for P1=P2 ( Caution: This interpolation may fail for points far out of bound of the given points)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.