# Ratio of areas determined by a square inscribed in the corner of a right triangle

I’m having trouble working out how to algebraically get to the answer of this question. (See original image below.)

A square is drawn in the corner of a right-angled triangle with side lengths $a$, $b$, and [hypotenuse] $c$, as shown.

Which expression gives the ratio of the unshaded area [inside the triangle, but outside the square] to the shaded area [of the square] in all cases?

• (A) $1:1$
• (B) $c:(a+b)$
• (C) $a b: c^2$
• (D) $( a + b )^2 : 2 c^2$
• (E) $c^2 : 2 a b$

Apparently the answer is $c^2 : 2 a b$ (choice E), but how?

Your help is greatly appreciated! Thank you in advance. (Please ignore the pen marks! They are incorrect assumptions a friend made on the diagram.)

• Do you see any similar triangles in the figure, and can you see how to use them to determine the length of the side of the square? – Blue Aug 5 '18 at 4:01
• Hi, yeah all three triangles in the diagram are similar, but I don't know how to use them to determine the length of the side of the square. I ended up splitting a and b and calling them a1/a2 and b1/b2, but that made it confusing. – Zelda_01 Aug 5 '18 at 4:03
• Suppose the side of the square is $s$. What are the sides of the two smaller triangles? – Blue Aug 5 '18 at 4:05
• (a-s) and (b-s)? Or am I missing something easier? – Zelda_01 Aug 5 '18 at 4:06
• Good! Specifically, $a-s$ and $b-s$ are two of the legs. (I meant "legs", not "sides".) The two other legs are ... what? And what proportion links all four of these values? – Blue Aug 5 '18 at 4:08

## 2 Answers

Let the side of the square is $x$. Then, using similarity of triangles, $\frac{b-x}{x}=\frac{x}{a-x}$ or $(b-x)(a-x)=x^2$; $ab-ax-bx+x^2=x^2$; $ab=x(a+b)$ or $x=\frac{ab}{a+b}$. Thus, the shaded area is $\frac{(ab)^2}{(a+b)^2}$.
The unshaded area is $$0.5x(b-x)+0.5x(a-x)=0.5\left(\frac{ab}{a+b}(b-\frac{ab}{a+b})+\frac{ab}{a+b}(a-\frac{ab}{a+b}\right)=\frac{ab(b^2+a^2)}{2(a+b)^2}=\frac{abc^2}{2(a+b)^2}$$ so the final ratio is $$\frac{2ab}{c^2}$$

• Thanks for this, was just wondering how you went from working out both areas to then finding the final ratio? I haven't done ratios in a while sorry! – Zelda_01 Aug 5 '18 at 4:42
• Wait, nevermind I worked it out, thanks! – Zelda_01 Aug 5 '18 at 4:49

Let $x$ be the side length of the square.

By similarity,

• The hypotenuse of the lower small right triangle is $\bigl({\large{\frac{c}{b}}}\bigr)x$.$\\[4pt]$
• The hypotenuse of the upper small right triangle is $\bigl({\large{\frac{c}{a}}}\bigr)x$.

Hence we get $$\left(\frac{c}{b}\right)x+\left(\frac{c}{a}\right)x=c$$ which yields $$x=\frac{ab}{a+b}$$ If $S,U$ are the respective areas of the shaded and unshaded regions, then

• $S=x^2$$\\[4pt]$
• $U=\bigl({\large{\frac{1}{2}}}\bigr)ab-x^2$

hence, the required ratio can be expressed as \begin{align*} \frac{U}{S} &=\frac{\left(\frac{1}{2}\right)ab-x^2}{x^2}\\[4pt] &=\frac{\left(\frac{1}{2}\right)ab}{x^2}-1\\[4pt] &=\left( \left({\small{\frac{1}{2}}}\right)ab \right) \left({\small{\frac{1}{x}}}\right)^2 -1 \\[4pt] &=\left( \left({\small{\frac{1}{2}}}\right)ab \right) \left({\small{\frac{a+b}{ab}}}\right)^2 -1 \\[4pt] &=\frac{(a+b)^2}{2ab}-1\\[4pt] &=\frac{(a+b)^2-2ab}{2ab}\\[4pt] &=\frac{a^2+b^2}{2ab}\\[4pt] &=\frac{c^2}{2ab}\\[4pt] \end{align*}