This version uses a unit circle (i.e. radius = 1) and lets you choose the number of steps around the circle, which determines the period of the sine wave. Note that it overshoots as you decrease the number of steps. Below four steps it becomes very erratic.