Area of the Trajectory of a Rotating Square

areacalculusrotations

The Question
We have a square with vertices $(0,0), (0,1), (1,0)$ and $(1,1)$ that is rotating as in the link below. What is the area of the trajectory the it traces out? Here's the link. Use the slider for $s$ to show the animation.
I have no idea how to start and would appreciate any type of answer.

Thanks in advance.

Edit
The problem I'm having is that when $s$ is around $\frac{3}{4}$, there's this region of the square that is not included in the heart-like shape, as it is not a convex set. The other parts are very easy so as long as we can find the area of that region, the problem is solved.

Best Answer

If the unrotated square has the following vertices: $A (0,0), B = (0, 1), C = (1,1), D (1, 0)$, then consider a rotation of the square by an angle $t$ counter clockwise. In this case the new vertices will be at

$A = (\sin t, 0) , B = (0, \cos t) $

$C = B + (1)(\cos t, \sin t ) = (\cos t , \cos t + \sin t ) $

$ D = A + (1) ( \cos t, \sin t ) = (\sin t + \cos t , \sin t ) $

In addition to the trajectories of $C$ and $D$, we need to find the envelope of the straight line segment that connects $C$ to $D$. The equation of this segment as a function of $t$ is

$ \dfrac{y - (\cos t + \sin t)}{x - \cos t } = - \dfrac{\cos t }{\sin t} $

Therefore,

$ \sin t (y - (\cos t + \sin t) ) + \cos t (x - \cos t ) = 0 \hspace{5pt} (1)$

Differentiating this equation with respect to $t$, gives us

$ \cos t (y - (\cos t + \sin t) ) + \sin t ( - (- \sin t + \cos t ) ) - \sin t (x - \cos t ) + \cos t ( \sin t ) = 0 $

So that

$ \cos t (y - (\cos t + \sin t) ) - \sin t (x - \cos t ) = - \sin^2 t \hspace{5pt}(2) $

Solving $(1)$ and $(2)$ we obtain

$ x - \cos t = \sin^3 t $

$ y - (\cos t + \sin t) = - \cos t \sin^2 t = - \cos t (1 - \cos^2 t)$

So that,

$ x = \cos t + \sin^3 t $

$ y = \sin t + \cos^3 t $

Both the trajectories of $C$ and $D$ are plotted in black in the figure below, while the envelope is plotted in red.

enter image description here

The total area enclosed is the area within the black curve plus the area within the red curve. The overlap is negligible.

To find the total area bounded by the curve that $C$ and $D$ traces, we have to combine the three curves and apply the following formula

$ \text{Area} = \dfrac{1}{2} \displaystyle \int x(t) y'(t) - x'(t) y(t) dt $

For the $D$ curve, we have

$ x = \sin t + \cos t $

$ y = \sin t $

So,

$ x' = \cos t - \sin t $

$ y' = \cos t $

Therefore, the integrand is

$ x y' - y x' = (\sin t + \cos t ) (\cos t ) - (\sin t) (\cos t - \sin t ) = 1 $

While for the $E$ curve we have

$ x = \cos s + \sin^3 s $

$ y = \sin s + \cos^3 s $

So,

$ x' = - \sin s + 3 \sin^2 s \cos s $

$ y' = \cos s - 3 \cos^2 s \sin s $

It can be easily shown that the integrand will be

$ x y' - y x' = \dfrac{5}{8} - \sin(2 s) + \dfrac{3}{8} \cos(4 s) $

Therefore, the area is given by

$ \text{Area} = (2)(\frac{1}{2})\displaystyle \int_{0}^{\pi/2} 1 \ d t + \frac{1}{2} \int_{0}^{\pi / 2 } \left(\dfrac{5}{8} - \sin(2 s) + \dfrac{3}{8} \cos(4 s) \right) \ d s $

The above integral is straight forward to evaluate and the result is

$ \text{Area} = 1.579922 $

Now, if we want to be more precise, we have to find the intersection points between the trajectory of $D$ and the envelope (the lower right blue dot), the other intersection (the upper left dot) is symmetrical with respect to the line $y = x$. To find the intersection point, we recall that $D$ is given by

$ C = ( \sin t + \cos t , \sin t ) $

while the envelope is

$E = ( \cos s + \sin^3 s , \sin s + \cos^3 s ) $

Using Newton-Raphson multivariate root finding method, we find that the two curves intersect at

$ t = 1.39094282700263$

$ s = 1.10714871778309$

(This gives the precise intersection lower right intersection point close the extreme point marked in blue where the $E$ curve flips direction)

The area integral changes now to

$ \text{Area} = (2)(\frac{1}{2})\displaystyle \int_{0}^{1.390942827} 1 \ d t + (2) \frac{1}{2} \int_{1.1071487178}^{\pi / 4 } \left(\dfrac{5}{8} - \sin(2 s) + \dfrac{3}{8} \cos(4 s) \right) \ d s $

The precise value of the area as computed by this integral is

$ \text{Area} = 1.5798487305 $

The difference in the two calculations is the area of the overlap between black region and the red region and this is $\approx 0.00007326$