If you know a bit about matrices :
The first 2 equations can be written this way :
Recall how to find the inverse of a 2x2 matrix, recall that and you're done.
An online text explaining rotation of axes includes this step:
x = X cos - Y sin
y = X sin + Y cos
By solving Equations (above) for X and Y we obtain
X = x cos +y sin
Y = -x sin + y cos
How do they get from the upper equations to the lower ones? Thanks in advance.