Find the coordinates of intersection of two lines

5 views (last 30 days)
I have two lines in the form y1 = 1 + tand(theta1)*x and y2 = 1 - tand(theta2)*x
How would I be able to determine the point of intersection of these two lines? How would I be able to do the same if I have more than one pair of lines?

Answers (1)

Image Analyst
Image Analyst on 27 Dec 2015
They intersect when the y values are the same, so y1=y2, or
1 + tand(theta1)*x = 1 - tand(theta2)*x
So obviously the answer is x=0, which makes sense. You have two lines intersecting the y axis at 1 with different slopes: slope1 = tand(theta1) and slope2 = tand(theta2). But if you have two lines both intersecting at the y axis at a height of 1, and the two slopes are different, then they must only cross at the y intercept and nowhere else, unless the slopes are equal in which case they will overlap 100% and intersect/cross everywhere.

Categories

Find more on Line Plots in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!