If we take it that the triangle with sides a, b, c is right-angled such that $\displaystyle a^2+b^2=c^2$
and the inner shape with sides c is a square, then if we label the angle and side as shown in the attachment..
and the area of the required shape equals the rectangle area,
we only need calculate $\displaystyle kc$.
$\displaystyle Cos\theta=\frac{k}{b}\Rightarrow\ k=bCos\theta$
Using the larger triangle... $\displaystyle Cos\theta=\frac{b}{c}$
Hence, it's straightforward to calculate $\displaystyle kc$ in terms of $\displaystyle b$.