Find the number of positive integer solutions such that $a+b+c\le 12$ and the shown square can be formed. Find the number of positive integer solutions such that $a+b+c\le 12$ and the
shown square can be formed.

$a \perp b$ and $b\perp c$.
the segments $a,b,c$ lie completely inside the square  as shown.

Here is my attempt but I am pretty sure this is not the efficient method
Let the angle between left edge of square and segment $a$ be $\alpha$. To form a square we need the horizontal projections equal the vertical projections. Using similar triangles it is easy to get to below equation
$$\langle \cos\alpha ,~\sin \alpha\rangle \cdot \langle b-a-c,~a \rangle = 0  $$
I feel stuck after this. Any help ?

Here is a start.
Extend the line
of length $a$
by an amount $c$
and then draw a line
from the end of that
to the corner of the square
that ends the line of length $c$.
This forms a right triangle
with sides
$a+c$ and $b$
whose hypotenuse is the
diagonal of the square.
This length is
$\sqrt{(a+c)^2+b^2}$,
so the side of the square is
$\sqrt{((a+c)^2+b^2)/2}$.
This does not take into account
the condition that
the lines line inside the square,
but it is a start.
