Here's a trick that I like to use when I can't properly remember the formulas.

The only formula you need to remember is Euler's formula:$\displaystyle e^{ix} = \cos x + i \sin x$

together with its rewritten forms (that you can both deduce from Euler's formula if you forget):$\displaystyle \cos x = \dfrac 1 2 (e^{ix} + e^{-ix})$

$\displaystyle \sin x = \dfrac 1 {2i} (e^{ix} - e^{-ix})$

In your case:

$\displaystyle \cos(4x)\cos(x) = \frac 1 2 (e^{i4x} + e^{-i4x}) \cdot \frac 1 2 (e^{ix} + e^{-ix}) $

$\displaystyle = \frac 1 4 ((e^{i5x} + e^{-i5x}) + (e^{i3x} + e^{-i3x})) $

$\displaystyle = \frac 1 2 (\cos(5x) + \cos(3x)) \qquad \blacksquare$