Ellipse (source code)

= Ellipse
{title2=$x^2/a^2+y^2/b^2=1$}
{wiki}

An ellipse is the <locus> of <points> whose <Euclidean distances> from two fixed <foci of a conic> have constant sum $2a$. If the distance between the <foci of a conic> is $d<2a$, the <semi-major and semi-minor axes> are $a$ and $\sqrt{4a^2-d^2}/2$. Writing $c=d/2$ gives the conventional relation $b^2=a^2-c^2$.<Precalculus 2e by Jay Abramson/10.1 The Ellipse>[Precalculus 2e, §10.1, ellipse definition and Deriving the Equation of an Ellipse Centered at the Origin, Figure 5]{ref}

For an original calculation, choose $a=5$, $b=3$, and hence $c=4$. The <ellipse>
$$
\boxed{\frac{x^2}{25}+\frac{y^2}{9}=1}
$$
has <foci of a conic> $F_-=(-4,0)$ and $F_+=(4,0)$. The point $P=(3,12/5)$ lies on it since $9/25+16/25=1$. Its focal distances are
$$
|P-F_-|=\frac{37}5,\qquad |P-F_+|=\frac{13}5,\qquad |P-F_-|+|P-F_+|=10.
$$
Its <eccentricity of a conic> is $e=4/5$. The matching <directrix of a conic> for $F_+$ is $x=a/e=25/4$, and the perpendicular distance from $P$ to that <straight line> is $13/4$. Therefore the ratio of focal distance to directrix distance is $(13/5)/(13/4)=4/5$, agreeing with $e$.

\Image[/ellipse-focal-distances-and-directrix.png]
{title=One <ellipse> has a constant focal-distance sum and a constant focus-directrix ratio}
{description=Original example with semiaxes $5,3$, foci at $(\pm4,0)$, and $P=(3,12/5)$. The left triangle represents a taut closed-loop construction; the right panel uses one matched focus and directrix. All lengths are in the same arbitrary unit.}

The constant sum can be turned into a construction. Fix a pin at each <focus of a conic> and pull a closed string loop taut with a pencil. In this example the segment between the pins has length $8$, so a loop of length $18$ leaves $10$ for the two pencil-to-pin segments. Moving the pencil while keeping that loop taut traces the <ellipse>. This is a geometric prediction from the length constraint, not an assertion about a measured drawing.

The parametrization $x=5\cos t$, $y=3\sin t$ maps the <unit circle> onto this <ellipse>. It makes plotting easy, but is an <affine map> rather than an <isometry>: horizontal and vertical lengths have different scale factors. An <ellipse> is not a <circle> under the original <Euclidean metric> merely because this map exists. Its two semiaxes and <eccentricity of a conic> retain the metric information lost by that equivalence.

A useful proof outline begins with $|X-F_-|+|X-F_+|=2a$. Isolate one <square root>, square, and then repeat; the resulting <quadratic equation> is $x^2/a^2+y^2/(a^2-c^2)=1$. Since $a>c$, the quantities isolated before squaring have the required signs, so the reverse implication introduces no extra branch. The condition $a>c$ is essential: at equality the focal-distance locus becomes the <line segment> between the <foci of a conic>.