a b c

Drag the blue dot to change a, the red dot to change b. The hypotenuse c follows.

a
= —
b
= —
c
= √(a² + b²) = —
c² a² b²
c² a² + b²

leftover area: c² = a² + b² · — = — + —