When searching the 'prime' period $T_p$ (also called the smallest period) the answer from Michael Hardy is not longer applicable. Example: $$a = 3, b=6 \rightarrow p=3, q=1, r=6, s=1 \rightarrow l = 1, c = 3, d = 6$$
The period calculated from Michael answer is $T = 2\pi\operatorname{lcm}(3,6) = 12\pi$.
The prime period $T_p$ however is $\frac{2\pi}{3}$, which can be seen from a plot.
This paper explains in detail how $T_p$ can be calculated for trigonometric functions.
For $a = 3, b=6$ (following examples 17 and 18 on page 60) $T_p$ can be calculated as follows
For the multiplication part: $\frac{T_1}{T_2} = \frac{3}{6} \rightarrow T_{p,mult} = 2 T_1 = \frac{4\pi}{3}$
For the summation part:$\frac{T_1}{T_2} = \frac{3}{9} \rightarrow T_{p,sum} = 3 T_1 = \frac{2\pi}{3}$
Finally, $T_p = \operatorname{min}(T_{p,mult},T_{p,sum})$ results in $T_p =\frac{2\pi}{3}$.
Paper is:
On Periodicity of Trigonometric Functions and Connections with Elementary Number Theoretic Ideas
Stupel, Moshe
Australian Senior Mathematics Journal
v26 n1 p50-63 2012