# How do I calculate the phase shift between sine and cosine?

I know that $\sin(\alpha + x)=\cos(\alpha)$. How do I find $x$ ?

I'd start by using the angle sum identity for sine:

$\cos(\alpha)*\sin(x)+\sin(\alpha)*\cos(x)=\cos(\alpha)$

I had some ideas about what to do next but they didn't get me anywhere.

-
Try $x=\pi/2$ radians. Look at the graphs of sine and cosine. Notice that if the hypotenuse of a right triangle (made from the point $(x,y)$, the origin, and the $x$ axis) is rotated $90^\circ$ counterclockwise, a new triangle is made with a hypotenuse to the point $(-y,x)$. This means the cosine of the first triangle's angle ($x/r$) is equal to the sine of the second triangle's angle. – anon Aug 16 '11 at 7:42

I'll try to expand a bit on joriki's answer. Since we want the identity $$\cos(\alpha)\sin(x)+\sin(\alpha)\cos(x)=\cos(\alpha)$$ to be true for all $\alpha$, it has to be true in particular for $\alpha=0$ and $\alpha=\frac{\pi}{2}$. Thus, the $x$ we are looking for must satisfy both $$\cos(0)\sin(x)+\sin(0)\cos(x)=\cos(0)$$ $$1\cdot\sin(x)+0\cdot\cos(x)=1$$ $$\sin(x)=1$$ and $$\cos(\tfrac{\pi}{2})\sin(x)+\sin(\tfrac{\pi}{2})\cos(x)=\cos(\tfrac{\pi}{2})$$ $$0\cdot\sin(x)+1\cdot\cos(x)=0$$ $$\cos(x)=0$$

Which value of $x$ satisfies both $\sin(x)=1$ and $\cos(x)=0$?

-
Thanks this helps. $\alpha=0$ and $\alpha=\frac{pi}{2}$ are chosen because they eliminate one half of the sum, right? Once I have $sin(x)=1$ is there any value of x that would not satisfy $cos(x)=0$? – fgm2r Aug 16 '11 at 8:14
@fgm2r: That's precisely the idea! We have to be strategic about which $\alpha$'s to look at in order to get the equation to become simpler, and $\alpha=0$ and $\alpha=\frac{\pi}{2}$ are ones which serve this purpose (we could also have chosen $\alpha=\pi$ and $\alpha=\frac{3\pi}{2}$). You are also correct in pointing out that $\sin(x)=1$ already forces $x=\frac{\pi}{2}$, while $\cos(x)=0$ is weaker, because it only implies that either $x=\frac{\pi}{2}$ or $x=\frac{3\pi}{2}$. – Zev Chonoles Aug 16 '11 at 8:24

Good start. Now you want the left-hand side to be $\cos\alpha$, so you want the coefficient of $\cos\alpha$, which is $\sin x$, to be $1$ and the coefficient of $\sin\alpha$, which is $\cos x$, to be $0$. Which $x$ yields those values?

-

Somewhat similar to Zev's method: if you say that $\sin(x+\alpha)=\cos(\alpha)$, then it is also true that $\sin(x-\alpha)=\cos(-\alpha)=\cos(\alpha)$. If you apply the usual sum and difference formulae for the trigonometric functions, you should obtain a system of two equations in the two unknowns $\sin(x)$ and $\cos(x)$. Solving those equations will yield $\sin(x)=1$ and $\cos(x)=0$

As already mentioned, $x=\pi/2$ is one such value of $x$; in general, due to periodicity, any number of the form $\pi/2+2k\pi$, $k$ an integer, is a possible value of $x$.

-