Theory: Line And Curve Intersection Finder
An intersection point is any point \((x,y)\) that satisfies both equations at the same time.
The key idea is to reduce the system to a single equation in one variable (often a quadratic).
1) Two lines
A line in standard form is
\[
Ax + By + C = 0.
\]
For two lines
\[
A_1x + B_1y + C_1 = 0,\qquad
A_2x + B_2y + C_2 = 0,
\]
we solve a 2×2 linear system. The determinant
\[
\Delta = A_1B_2 - A_2B_1
\]
tells us what happens:
- \(\Delta \neq 0\): one unique intersection point.
- \(\Delta = 0\) and not proportional: lines are parallel (no intersection).
- \(\Delta = 0\) and proportional: lines are coincident (infinitely many intersections).
2) Line & circle
A common circle form is
\[
(x-h)^2 + (y-k)^2 = r^2.
\]
Expanding gives the general circle form
\[
x^2 + y^2 + Dx + Ey + F = 0,
\]
where \(D=-2h\), \(E=-2k\), \(F=h^2+k^2-r^2\).
If the line is not vertical, write it as \(y=mx+b\) and substitute into the circle equation:
\[
x^2 + (mx+b)^2 + Dx + E(mx+b) + F = 0.
\]
This becomes a quadratic in \(x\), so there can be:
- 0 real solutions → no intersection
- 1 real solution → tangent (touches at one point)
- 2 real solutions → two intersection points
If the line is vertical \(x=x_0\), substitute \(x_0\) into the circle equation to get a quadratic in \(y\).
3) Line & parabola
For an upright parabola
\[
y=ax^2+bx+c,
\]
and a non-vertical line \(y=mx+q\), set them equal:
\[
ax^2+bx+c = mx+q \;\;\Rightarrow\;\; ax^2 + (b-m)x + (c-q)=0.
\]
Again, the intersection points come from solving a quadratic in \(x\), then plugging into \(y=mx+q\).
Graph note
The plot uses square units (equal scaling in x and y) so circles look round and angles/distances are not distorted.
Tick labels are drawn near the axes to stay readable while panning/zooming.