I think it's just Gaussian elimination. However, since you must divide by variables at some spots, you gotta make sure that you don't get zeroes in the denominator. The system has a unique solution if the matrix is invertible, right? So you can just take the determinant and see.
Hint: Once you solve for a1,a2 and a3, the denominators will be just the determinant of the coefficient matrix.
In fact, try the 2D case and then extend it.