Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Suppose we have a rectangle at the center of the coordinates. One top point of the rectangle has the coordinates (a, b), the second (-a, b), third (-a, -b) and (a, -b). We rotate this rectangle with the angle $\phi $ counterclockwise to get a second rectangle.

Question: Find the common area of these two rectangles.

By common area I mean the area of the polygon that is limited by the intersection points of the two rectangles

share|cite|improve this question
up vote 3 down vote accepted

I'll assume $0<a<b$ and $0\leq\phi\leq\frac\pi2$. All other cases can be reduced to this.

Case 1: $\phi < 2\arctan\left(\frac ab\right)$

In this case you have an octagonal intersection, with an area of

$$2\frac{2ab\sin(\phi) + \bigl(a^2 + b^2\bigr)\bigl(\cos(\phi) - 1\bigr)} {\sin(\phi)\,\cos(\phi)}$$

Case 2: $\phi \geq 2\arctan\left(\frac ab\right)$

In this case you get a quadrilateral intersection, with an area of


I obtained the above results using symbolic expressions for all coordinates, performing the computation using sage.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.