# Find an area of a rectangle by its diagonal and quotient of its sides.

Okay, I've found no formulas for this one online but I'm pretty sure that the area of a rectangle is calculable from its diagonal and ratio (quotient of its sides).

Think of it: with a constant quotient of sides, the rectangle will always have the same shape and a variable diagonal would only affect its size — the length of sides is directly proportional to the diagonal of the rectangle.

So how exactly would I go about calculating the sides of a rectangle if only the diagonal and quotient of sides is known?

• Have you tried making a drawing? – Bobson Dugnutt Sep 10 '16 at 21:15
• Do you mean making proportional measurements? That's always a practical way with geometry but I always loved math while never being able to properly wrap my head around geometry. I like precise formulas and they can also be used in programming as is. Sorry if I'm not getting something obvious. – Erquint Sep 10 '16 at 21:52

## 3 Answers

Say the length and width are $L,W$. We are given values $A,B$ with $$\frac LW = A\quad\&\quad L^2+W^2=B^2$$

We note that $$L=AW\implies (1+A^2)W^2=B^2\implies W=\frac B{\sqrt {1+A^2}}$$

It follows that $$Area =LW = AW^2= \frac {AB^2}{1+A^2}$$

Let $d$ denote the rectangle's diagonal and $a$, $b$ its side respectively. Then we have by the good old pythagorean theorem $d = \sqrt{a^2 + b^2}$ and further by the ratio denoted by $r$ we have $r = \frac{b}{a}$ or equivalently $b = ra$. Thus $$d^2 = (r^2 + 1)a^2 \Leftrightarrow a = \frac{d}{\sqrt{r^2 + 1}}$$ For $b$ we have similarly $$b = \frac{d}{\sqrt{\frac{1}{r^2} + 1}}$$ Thus simply $$A = ab = \frac{d^2}{\sqrt{2 + r^2 + \frac{1}{r^2}}}$$ and you have your formula.

The side ratio $r$ is the tangent of one of the acute angles $\theta$ of the triangle formed by the sides and diagonal of the rectangle. The sine and cosine of this angle can be recovered via basic trigonometric identities: $$\cos^2\theta={1\over1+r^2}, \sin^2\theta={r^2\over1+r^2}.$$ Letting $d$ be the diameter, this gives $$A=(d\cos\theta)(d\sin\theta)={rd^2\over1+r^2}.$$