You don't really need to derive them, but try choosing a set of integers (say 0,1,2) to use as n and sub it in, it gives you an idea of how the whole thing works.
ie. when sinx=siny, x=n(pi)+((-1)^n)y
for n=0, x=y (first quadrant)
for n=1, x=pi-y (second quadrant)
for n=2, x=2pi-y (third...