You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Jiří Cihelka edited this page Jan 2, 2024
·
1 revision
Description
This procedure finds the intersection point between two lines.
Inputs
line1: The first line.
line2: The second line.
Outputs
intersection: The intersection point between the two lines.
Intersection can be a point, line, or null.
Procedure
The procedure for this is as follows:
If the lines are parallel, check their distance. If the distance is 0, then the lines are coincident, and the intersection is the first line. Otherwise, the lines are parallel and do not intersect.
If the lines are not parallel, then they intersect at a point. The point is found by solving the system of equations formed by the two line equations.
$a_1x + b_1y + c_1 = 0$ $a_2x + b_2y + c_2 = 0$
We know, that the determinant of the system is not 0, because the lines are not parallel. Therefore, the system has a unique solution.