You may have mixed up the variables in one of the two equations. You should be starting with the two equations: and . Multiply the first equation by and add this to the second equation.