How do I calculate the perodicity of a spirograph (hypotrochoid)? The parametric equations for hypotrochoids produced by the "spirograph" toy are given by (source: wikipedia):
$x(t) = R((1-k)\cos t + l k \cos (\frac{1-k}{k}t)$
$y(t) = R((1-k)\sin t - l k \sin (\frac{1-k}{k}t)$
For a given $R$, $k$ and $l$, can I determine at what value of $t$ the figure will start repeating? This is to aid in drawing it.

I found my answer here:
http://www.reddit.com/r/math/comments/27nz3l/how_do_i_calculate_the_periodicity_of_a/
To quote user Superdorps:

In practice, with an actual Spirograph, you take the least common multiple of tooth counts - for example, the 40-tooth gear and 104-tooth ring (I think these exist, but it's been at least fifteen years since I've had a chance to dig out my Spirograph) will repeat after 520 teeth, or five full revolutions (with the gear having made 13 revolutions).
So, let's look at this. We have r = 40, R = 104, and therefore k = 5/13. The number of repeats will be the numerator to k assuming it's been reduced as far as possible, and the number of revolutions the gear makes will be its denominator. R is mostly irrelevant (except for how it contributes to k) and l is entirely irrelevant (the period over t is solely based on the circumferences, and therefore the radii, of the two circles in question).

