# Area of inscribed rectangle as a function of right triangle base

I am stuck with trying to find the area of the rectangle $A$ as a function of $x$:

(Drawing replicated from my textbook, not sure if more labels would be helpful?)

Obviously $A$ is given by the product of two adjacent rectangle sides, one of which is equal to the hypotenuse of the bottom-left inner triangle. The hypotenuse in turn is given by the Pythagorean relation $\sqrt{x^2+y^2}$, if we let $y$ be equal to $b$ minus the hypotenuse of the upper-left inner triangle.

I have tried doing some algebra from there, but I am unable to eliminate all the variables I believe I am supposed to. Am I correct that the final expression may take the outer triangle as given, but otherwise should only depend on $x$?

Any hints as to which (geometric?) relations I may be missing out on? Or similar problems posted here earlier that I should take a more thorough look at?

(I have seen similar problems discussed on this site, but not with the rectangle in this position. Also, similar problems I have seen tend to include some numbers and not just general quantities, which in my experience is a bit easier to wrap my mind around. The next step of the task is to optimize the area of the inscribed rectangle, but that should be simple enough once I have the formula worked out.)

• To answer the question 'Would more labels be helpful?', I'd ask 'Does the textbook drawing have more labels?' and if so 'Do they convey useful information?' If so, it's obviously worth including them. – George Tomlinson Oct 18 '13 at 13:19
• Does the question explicitly state that $a$ and $b$ are constants and that $x$ is the only variable? You can definitely find a function in terms of $a, b, x$. A hint would be to think of using ratios i.e. we reduce $a$ to $x$ by multiplying it by some constant $k$. – matthras Oct 18 '13 at 13:24
• Also it might help if you would clarify whether the labels currently on the diagram are all from the textbook. – George Tomlinson Oct 18 '13 at 13:28
• Yes, the drawing is an exact (if not very beautiful) replication of the textbook illustration, including labels given there. Should have made that more clear. @matthras: The context is an optimization problem, i.e. for any right triangle where a rectangle is inscribed like this, what is the largest possible rectangle. I was assuming – but not sure – if that necessarily implies that $a$ and $b$ can be treated as constants. – Jenny542 Oct 18 '13 at 14:49
• (The task explicitly asks that one first finds $A(x)$, then determines the greatest possible rectangle.) – Jenny542 Oct 18 '13 at 15:00

Note that you know all angles. Let $\alpha$ be the lower-right angle and $\beta$ the upper left angle (you don't need it, but anyway). Now, the triangles are similar so, they share the same angles.

Denote by $z$ the long side of the rectangle $A$ and $l$ the short side, so that $Area(A)=z\cdot l$. Now, it is easy to check that

$z=\frac{x}{\cos\alpha}=\frac{cx}{a}$, and

$l=(a-x)\sin\alpha=(a-x)\frac{b}{c}$.

So $A=z\cdot l=\dfrac{x(a-x)b}{a}$

Edit: For the biggest area, take a look of $A'_x(x)=0$ so you'd have that area is max. when $x=a/2$.

Let $c$ and $d$ be the lengths of the two sides of the rectangle, as indicated on the figure. The area of the rectangle is $cd$.

With the notations introduced in the figure above, the triangles $GDC$ and $ABC$ are similar because they are right triangles sharing one of the non-right angles. Thus $\frac{GD}{AB} = \frac{GC}{AC}$, ie $$\frac{c}{b} = \frac{a-x}{\sqrt{a^2+b^2}}.$$

In the same way, using the similarity of triangles $FBG$ and $ABC$, we obtain $$\frac{d}{\sqrt{a^2+b^2}} = \frac{x}{a}.$$

From these two equalities you can compute $c$ and $d$ as functions of $x, a$ and $b$.

Thus the rectangle area is $\mathcal{A} = cd = \frac{b}{a}x(a-x)$.