the equation of a circle
A circle is the set of all points that sit at one fixed distance — the radius — from a fixed center point. That sentence is a geometric definition, but coordinate geometry turns it directly into an equation by feeding the distance formula into it. The result is one of the cleanest equations in all of mathematics.
Let the center be C = (h, k) and the radius be r. A point (x, y) is on the circle exactly when its distance from C equals r, that is sqrt((x - h)^2 + (y - k)^2) = r. Squaring both sides clears the root and gives the standard form (x - h)^2 + (y - k)^2 = r^2. Read it backward and it hands you everything: the center sits at (h, k) — note the minus signs, so x - h = 0 means h is the number subtracted — and the radius is r = sqrt(right-hand side). For instance (x - 2)^2 + (y + 3)^2 = 25 is the circle with center (2, -3) (because y + 3 = y - (-3)) and radius sqrt(25) = 5. A circle centered at the origin simplifies to x^2 + y^2 = r^2.
This equation lets you decide instantly whether a point is inside, on, or outside a circle (compare (x - h)^2 + (y - k)^2 with r^2), and it interacts cleanly with lines: substituting a line's equation in and solving a quadratic tells you the points where line and circle meet. One honest caveat: a circle is not the graph of a function — most vertical lines cross it twice — so you cannot write the whole circle as a single y = f(x); the implicit equation above is the right object.
Write the equation of the circle with center (-1, 4) passing through the point (2, 8). The radius is the distance from center to that point: r = sqrt((2 - (-1))^2 + (8 - 4)^2) = sqrt(9 + 16) = 5. So the equation is (x + 1)^2 + (y - 4)^2 = 25.
The radius comes from the distance formula; then read center and r straight off the standard form.
Watch the signs: in (x - h)^2 + (y - k)^2 = r^2 the center is (h, k), so (x + 1)^2 means h = -1, not +1. And the right side is r^2, not r — for radius 5 it is 25.