What identity is $\cos \left(x\right)+\sin \left(x\right)=\sqrt{2}\sin \left(\frac{\pi }{4}+x\right)$? I saw this on symbolab but I can find proof for it anyway online. I tried using $$\sin 2x$$ double angle but that doesn't explain the $$\frac{\pi }{4}$$
 A: Addition theorem...
$$
\sin(\alpha+\beta) = \sin(\alpha)\cos(\beta) + \cos(\alpha)\sin(\beta)
$$
Try it with $\alpha=\pi/4$ and $\beta = x$.
A: Here's a general guide and explanation for problems of your type:
If we have an expression, $a\sin{x}+b\cos{x}$, let us assume it can be written in the form $R\sin(x+\alpha)$ Now to see if we can find values for $R$ and $\alpha$ in terms of $a$ and $b$. Using the compund angle formulae, also known as the addition formulae:
$$R\sin(x+\alpha)=R\sin{x}\cos{\alpha}+R\sin\alpha\cos x=a\sin{x}+b\cos{x}$$
So we have
$$R\cos\alpha=a,R\sin\alpha=b$$
So dividing the second equality by the first:
$$\tan\alpha=\frac{b}{a}$$
meaning we can find $\alpha$ in terms of $a$ and $b$, as we wanted. Now, to find $R$:
Squaring the $2$ equalities above we have
$$R^2\cos^2\alpha+R^2\sin^2\alpha=R^2(\cos^2\alpha+\sin^2\alpha)=R^2=a^2+b^2\implies R=\sqrt{a^2+b^2}$$
So, to finish off by recapping what we have learnt:
$$\tan\alpha=\frac{b}{a},R=\sqrt{a^2+b^2}$$
Try applying that to your question. I hope that was helpful :)
A: The $\frac{\pi}{4}$ is there because
$$\sin\frac{\pi}{4}=\cos\frac{\pi}{4}=\frac{1}{\sqrt{2}}$$
Can you now see why $\sqrt{2}$ is on the right side? If you use the sum of angles identity on the right side, you'll get your answer.
