Look at the picture.
We have the equation (1) 12x + 4y = 40.
We know, the sum of the acute angles in a right triangle is 90°.
Therefore we have the equation (2) (12x + 4y) + (17x - y) = 90
Substitute (1) to (2):
40 + 17x - y = 90 subtract 40 from both sides
17x - y = 50 (3)
We have the system of equations:
[tex]\left\{\begin{array}{ccc}12x + 4y = 40&|:4\\17x-y=50\end{array}\right\\\underline{+\left\{\begin{array}{ccc}3x + y = 10\\17x-y=50\end{array}\right}\ \text{add both side of equations}\\.\qquad20x=60\qquad|:20\\.\qquad x=3[/tex]
Substitute the value of x to (3)
[tex]17(3)-y=50\\51-y=50\qquad|-51\\-y=-1\to y=1[/tex]
Answer: x = 3 and y = 1.