Product (to Sum) formulas
\begin{eqnarray*}\sin A\cos B&=&\frac{1}{2}\{\sin (A+B)+\sin (A-B)\}\\\cos A\sin B&=&\frac{1}{2}\{\sin (A+B)-\sin (A-B)\}\\\cos A\cos B&=&\frac{1}{2}\{\cos (A+B)+\cos (A-B)\}\\\sin A\sin B&=&-\frac{1}{2}\{\cos (A+B)-\cos (A-B)\}\end{eqnarray*}
To prove, we use the addition and subtraction formula:
\begin{eqnarray*}\sin (A+ B)&=&\sin A\cos B+ \cos A\sin B\ \ \ \cdots\ (1)\ \\\sin (A- B)&=&\sin A\cos B- \cos A\sin B\ \ \ \cdots\ (2)\ \\\cos (A + B)&=&\cos A\cos B- \sin A\sin B\ \ \ \cdots\ (3) \\\cos (A + B)&=&\cos A\cos B+ \sin A\sin B\ \ \ \cdots \ (4)\end{eqnarray*}
If we (1)+(2), we get $$\sin(A+B)+\sin(A-B)=2\sin A\cos B$$
Now if we divide both sides by 2, we obtain
$$\sin A\cos B=\frac{1}{2}{\sin (A+B)+\sin (A-B)}$$
Similarly,
- By {(1)-(2)}÷2, we obtain : $\cos A\sin B=\frac{1}{2}{\sin (A+B)-\sin (A-B)}$
- By {(3)+(4)}÷2, we obtain : $\cos A\cos B=\frac{1}{2}{\cos (A+B)+\cos (A-B)}$
- By {(3)-(4)}÷2, we obtain : $\sin A\sin B=-\frac{1}{2}{\cos (A+B)-\cos (A-B)}$
Sum (to Product) Formulas
\begin{eqnarray*}\sin A+\sin B&=&2\sin \frac{A+B}{2}\cos\frac{A-B}{2}\\\sin A-\sin B&=&2\sin \frac{A-B}{2}\cos\frac{A+B}{2}\\\cos A+\cos B&=&2\cos \frac{A+B}{2}\cos\frac{A-B}{2}\\\cos A-\cos B&=&-2\sin \frac{A+B}{2}\sin\frac{A-B}{2}\end{eqnarray*}
We use the product formulas:
\begin{eqnarray*}\sin A\cos B&=&\frac{1}{2}\{\sin (A+B)+\sin (A-B)\}\\\cos A\sin B&=&\frac{1}{2}\{\sin (A+B)-\sin (A-B)\}\\\cos A\cos B&=&\frac{1}{2}\{\cos (A+B)+\cos (A-B)\}\\\sin A\sin B&=&-\frac{1}{2}\{\cos (A+B)-\cos (A-B)\}\end{eqnarray*}
If we set $A+B=A’, \ \ \ A-B=B’$, we have
$$A=\frac{A’+B’}{2}, \ \ \ B=\frac{A’-B’}{2}$$
and if you substitute each, we obtain
\begin{eqnarray*}\sin \frac{A’+B’}{2}\cos \frac{A’-B’}{2}&=&\frac{1}{2}\left(\sin A’+\sin B’\right)\\\cos \frac{A’+B’}{2}\sin \frac{A’-B’}{2}&=&\frac{1}{2}\left(\sin A’-\sin B’\right)\\\cos \frac{A’+B’}{2}\cos \frac{A’-B’}{2}&=&\frac{1}{2}\left(\cos A’+\cos B’\right)\\\sin \frac{A’+B’}{2}\sin \frac{A’-B’}{2}&=&-\frac{1}{2}\left(\cos A’+\cos B’\right)\end{eqnarray*}
Now, the sum formulas can be obtained from equations above.