# Inscribed ellipse in a rectangle

Given a rectangle with size 2a > 2b (let's say 32 cm × 48cm)
We study here the ellipses inscribed in this rectangle, that is tangent to the 4 sides. There are of course infinitely many.
We first construct that one with :
• a given contact point with the larger side
• or given direction of axes
• or given excentricity

We also search for the one with the larger area.

First of all, the obvious symmetry of the figure implies the ellipse center is at the rectangle center.
To formally prove that, just consider the two parallel tangents being two opposite sides.
The line connecting the two contact points is the polar of point at infinity on these tangents.
The ellipse center is the midpoint of this chord, on the median connecting the two other sides.
And similarily for the two other sides.
Also recall the known properties of ellipses : focii, director circle, circular directrix, properties of tangents...

#### Ellipse given a contact point

That is to find the three other contact points, the focii and axes.
Consider the two tangents from A, the midpoint of line PS connecting the contact points is on the diagonal OA.
And similarilky with the tangents from B.
PQRS is therefore a parallelogram, with sides parallel to the diagonals of ABCD, whence the immediate construction of QRS from P.

Remains now to construct the focii and axes.
The axes may be constructed by considering the following pairs of conjugate diameters :

• The diagonals AC and BD
• A median NN' and the line connecting opposite contact points PR

We thus define an involution on the pencil of lines O* (lines through O)
The pair of perpendicular lines which correspond in this involution are thes ellipse axes.
Classical construction by projecting this involution of O* on any circle going through O.

The focii are obtained as harmonic conjugates of intersections X and X' of the tangent and the normal in P with the focal axis,
that is from OF² = OF'² = OX.OX' (again a classical construction)

The director circle is obtained from the classical property of the projection H of focus on the tangent being on that director circle.
The ellipse vertices are immediately deduced, then the drawing friom a stretch of the director circle in ratio OV/OU.

In the applet, A and C define the rectangle ABCD. C is contrained by AB > BC > 0
P defines the contact point with AB
During the construction of axes, w choses the "any circle through O".
The previous construction of OF² = OF'² = OX.OX' fails if the focal axis is parallel to AB, that is when P is in M.
The applet prevents this case by restricting P in the segment MB - ε.

Note : The previous construction doesn't uses the angles of the rectangle ABCD being 90°, It is then valid without any change for a parallelogram ABCD.