I'm assuming that the second terms in each equation should involve an exp,
Subtracting  from  gives an expression for y in terms of x:
Subbing this expression for y into  and reorganizing gives
This can be simplified using the following two identities.
Unfortunately, this equation is transcendental in x, which means it cannot be solved analitically. The solution for x (for which there will be an infinite number due to the periodic nature of the trig functions, as long as P isn't too large compared to the Qs) can be found either graphically or numerically. For a graphical solution, you plot the right-hand side of the equation and see where it crosses the x-axis (these will be the points where the function on the right is equal to zero, satisfying the equation). For a numerical solution check out root finding methods like the bisection method. Once you have values for x you can plug them into the above expression for y.