I am trying to draw a clock with both hour and minute hands in a computer program. The movement of the clock hands would mirror a traditional wall clock (hours from $12, 1, 2, 3,..., 11$ and back to $12$ etc.) Suppose I know the center (starting point) and the radii of both the hour and the minute hands. In order to locate the endpoints (tip) of the clock hands, what parametric equation I should use? The complication seems to be that the hour hands start from $12$ (or we could assume it's "$0$") at the top of the clock. So, the traditional parametric equation for finding a point around a circle's circumference (see below) needs to be modified a bit here. If I get the hour hand equation down, I think I can adapt it for minute hand. My trig knowledge isn't that good, so if someone could provide me a solution (or even just a clue), that'd be very helpful. Thank you!

The conventional parametric equations of a circle are:

\begin{align} x &= r \cos(t)\\ y &= r \sin(t) \end{align} where $r$ is the radius and $t$ is in radian for above equations.

I found a document that derives how to graph the hour and minute hands, but the equations there (pasted below) doesn't seem to draw at least the hour hand right. For example, from $12$ to $3$ hour, it draws points in the fourth quadrant of a circle...

\begin{align} x &= r \cos(\frac\pi{360}t)\\ y &= r \sin(\frac\pi{360}t) \end{align} where $t$ is time in minutes.

  • $\begingroup$ I think I found a working solution (equation) by switching the 'sin' and 'cos' in the above question like this: x = radius * sin(pi/360 * time_in_minutes) y = radius * cos(pi/360 * time_in_minutes) BUT I still would like someone to explain why this actually worked. I will think about it and will surely post if I figure out the explanation as to why. Thank you! $\endgroup$ – user1330974 May 13 '15 at 19:34

This is NOT a proper answer to the request on parametric equations. However, if only the locations of the tips of the hands are of interest, you can consider the following:-

Let the lengths of the minute and hour hands be $M$ and $H$ respectively.

After 60 minutes = 1 hr, the minute hand moved $2 \pi M(1)$.

After 30 minutes = 0.5 hr, the minute hand moved $2 \pi M(0.5)$

After x minutes; (where $x \le 60$) $= \frac {x}{60}$ hour, the minute hand moved $2 \pi M(\frac {x}{60})$.

After 60 minutes = 1 hour, the hour hand moved $2 \pi H (\frac {1}{12})$.

After y hours (where $y \le 12$) $= \frac {y}{12}$ parts of a 12 hour revolution, the hour hand moved $2 \pi H(\frac {y}{12})$.


Advisor: This answer is not parametric, and requires multiple equations.

Mick did give a good answer, but what I believe you want is 2 linear lines.

From the center of the circle to the edge for a linear line, you take the sin(t)/cos(t) implying that 0 < t < 2π. sin(x)/cos(x)=tan(x), a rule of trigonometry, so we do y=tan(t)x and then limit the x (or y, but I am using x) on the equation. Now we have y=tan(t)x{0<x<cos(t)}, keep in mind you will have to make another equation stating thatcos(t)

Now, we just do some tweaking with the time. The minute clock moves 12 times faster than the hour clock, so for the minute equations we just multiply t by 12 in the y=tan(t) to make it y=tan(12t). Then we make the domain {0<x<cos(12n)}

Tweak this to your needs. Keep in mind this will move counter clockwise, so you must make your 't's negative.

This was a basic understanding, but hopefully useful for you.


Following the usual conventions, the $x$ axis is horizontal and points to the right, while the $y$ axis is vertical and points upward. When you plot $x = r \cos t, y = r \sin t$ using these coordinate axes, you get a point that starts on the positive $x$ axis at $t = 0$ and moves counterclockwise as $t$ increases.

In the document you linked to, look at the figures illustrating the hour hand. Notice that the hour hand is horizontal and pointing to the right; yet the parameteric equations are set up so that the hour hand is in this position at $t = 0.$ That is, the simulated clock face starts at three o'clock (am or pm, they do not say which), not at twelve o'clock (noon or midnight).

In particular, if you put $t = 60$ minutes in the equations in that document, you will get the position of the hour hand at one hour after three o'clock, that is, at $4$ o'clock. The equations then correctly tell you to plot the hour hand in the lower right quadrant of the circle.

By the way, the exact equations in the linked document are \begin{align} x &= r\cos\left(\frac\pi{360} t\right),\\ y &= -r\sin\left(\frac\pi{360} t\right). \end{align} You left out the negative sign when you copied the equations to your question. In some computer-graphics interfaces, however, the vertical axis points down instead of up, which you can reconcile with the mathematical convention simply by changing the sign of the $y$ coordinate; in this case, canceling the negative sign.

To get the hour hand to start at the twelve-o'clock position at $t = 0,$ assuming that is on the positive $y$ axis, you have a couple of options. One option is, you could take the number of minutes since twelve o'clock and subtract $180$ to get the number of minutes after three o'clock: \begin{align} x &= r\cos\left(\frac\pi{360} (t - 180)\right),\\ y &= -r\sin\left(\frac\pi{360} (t - 180)\right). \end{align}

Another option is to go through the same steps as in the document, from the beginning, plotting the position of the hour hands at various times, but putting the hour hand at the twelve-o'clock position $(0,r)$ at $t = 0$ instead of at three o'clock. When you graph $x$ and $y$ in this way you get equations like these: \begin{align} x &= r\sin\left(\frac\pi{360} t\right),\\ y &= r\cos\left(\frac\pi{360} t\right). \end{align}


$ \theta $ is in radians ;

$$ x_H= H \sin \theta ;\quad y_H=H \cos \theta ; $$

$$ x_M= M \sin \theta ;\quad y_M = M\cos \theta ; $$

$ \theta_{minute\, hand} = \Omega t ; \quad\theta_{hour\, hand} = \omega t ; $ where $t$ is in minutes.

$ \omega =\frac12 ^0 $ per minute, $ \Omega = 6 ^0$per minute


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.