A period function P(x) can (provided it's not too pathological) be represented by a (probably infinite) sum of sine and cosine functions.

Specifically

$P(x)=\sum_{n=0}^\infty(a_i\cos(nx)+b_i\sin(nx))$

This is called its Fourier Series.