Circle and Line Intersection Calculator

Enter a circle and a line to find where they meet.

The x-coordinate of the circle's centre.

The y-coordinate of the circle's centre.

A length more than 0.

An equation in x and y, such as y = x + 1 or 3x + 4y = 5.

Try

Result

You entered(x)2+(y)2=25and−x+y=1\left(x\right)^2 + \left(y\right)^2 = 25 \quad\text{and}\quad -x + y = 1

(−4,−3) and (3,4)\displaystyle \left(-4, -3\right) \text{ and } \left(3, 4\right)

Distance from the centre

22≈0.707107\displaystyle \frac{\sqrt{2}}{2} \approx 0.707107

Chord length

72≈9.899495\displaystyle 7\sqrt{2} \approx 9.899495
Show the work
  1. Distance from the centre to the line

    Write the line as Ax+By=CAx + By = C and the circle's centre as (h,k)(h, k). The distance dd from the centre to the line is compared with the radius r=5r = 5: a line meets the circle in two points when d<rd < r, touches it when d=rd = r and misses it when d>rd > r.

    d=∣Ah+Bk−C∣A2+B2=∣(−1)×0+1×0−1∣(−1)2+12=12=22≈0.707107\begin{aligned} d &= \frac{\left|Ah + Bk - C\right|}{\sqrt{A^2 + B^2}} \\ &= \frac{\left|\left(-1\right)\times0 + 1\times0 - 1\right|}{\sqrt{\left(-1\right)^2 + 1^2}} \\ &= \frac{1}{\sqrt{2}} \\ &= \frac{\sqrt{2}}{2} \approx 0.707107 \end{aligned}
  2. The foot of the perpendicular

    The closest point of the line to the centre is the foot FF of the perpendicular from (h,k)(h, k), found by moving from the centre against the normal direction (A,B)(A, B) by t=Ah+Bk−CA2+B2t = \frac{Ah + Bk - C}{A^2 + B^2}.

    t=−12=−12F=(0−(−12)×(−1), 0−(−12)×1)=(−12,12)\begin{gathered} t = \frac{-1}{2} = -\frac{1}{2} \\ F = \left(0 - \left(-\frac{1}{2}\right) \times \left(-1\right),\ 0 - \left(-\frac{1}{2}\right) \times 1\right) = \left(-\frac{1}{2}, \frac{1}{2}\right) \end{gathered}
  3. Points a half-chord from the foot

    From FF the two intersection points lie along the line, each a half-chord r2−d2\sqrt{r^2 - d^2} away. Written with the direction (B,−A)(B, -A) of the line, the offset is r2N−e2N\frac{\sqrt{r^2 N - e^2}}{N} times (B,−A)(B, -A), with N=A2+B2N = A^2 + B^2 and e=Ah+Bk−Ce = Ah + Bk - C.

    25×2−(−1)22=3.5(−4,−3), (3,4)\begin{gathered} \frac{\sqrt{25 \times 2 - \left(-1\right)^2}}{2} = 3.5 \\ \left(-4, -3\right), \ \left(3, 4\right) \end{gathered}
  4. Result

    So the line meets the circle at (−4,−3)\left(-4, -3\right) and (3,4)\left(3, 4\right).

Worked examples