# How do I solve this simultaneous equation for x and y: ax+by=c bx+ay=c Thank you for the help!

*print*Print*list*Cite

Hello!

The most straightforward way is to use Cramer's Rule. The main determinant of this system is `D = |[a,b],[b,a]| = a^2-b^2 = (a-b)(a+b).` If it is nonzero, the system has the only solution. The determinant for the variable `x` is `D_x =|[c,b],[c,a]| = c(a-b),` the determinant for the variable `y` is also `D_y =|[a,c],[b,c]| = c(a-b).`

By the rule `x = D_x/D = (c(a-b)) / ((a-b)(a+b)) = c/(a+b),` `y = D_y/D = c/(a+b).`

[the remaining options are probably less interesting but we have to consider them]

If the main determinant `D` is zero, the system has many or no solutions.

If `a = b,` then both equations are the same, `ax+ay=c.` If `a` is nonzero, then the general solution is `x=t, y=c/a-t.` If `a` is zero and `c` is nonzero, there are no solutions. If `a` is zero and `c` is zero, then any pair of numbers is a solution.

If `a = -b,` we get equations `ax-ay=c, -ax+ay=c,` or `a(x-y)=c=-c.` If `c` is nonzero, then there are no solutions. If `c` is zero and `a` is nonzero, the general solution is `x=t, y=t.` If `c` is zero and `a` is zero, then any pair of numbers is a solution.