School-Safe Puzzle Games

## The Complex Clock Puzzle

OK, so here we have it: Bilbao’s 4th and final clock challenge.

Our general audience will be pleased because it is entirely feasible for you to come up with an approximate solution to the puzzle.  To get an exact answer, however, you’ll need to be a math ace.

So for all who asked for harder puzzles (hope you’re still out there Tommy!), here we go:

What is the exact time when the three hands of a clock (hour, minute, second) are closest to being evenly separated (i.e. 120 degrees)

Will list those who can figure out the exact answer here, as they come in.

Update: After discussing things with Bilbao, there is one exact answer to this puzzle, and many incredibly good approximations. So far, no one 1 person has gotten the exact answer. What we do have, however, are several ‘almost’ exact valid solutions, but it seems they are not being reached by the method that gives the exact answer.

While many of these approximations are so close to the exact value that all but your math professor would consider them valid, we’re going to hold out hope that someone will come up with the exact method & answer. We’ll even throw in a Smartkit tshrit if you can do it.

Valid approximations (almost exact answers):

### 66 Comments to “The Complex Clock Puzzle”

1. Jimmy Anders | PUZZLE MASTER | Profile

Oh, we are to minimize the absolute value of the errors? In that case my answer would be at:
02:54:34 + 4334/7909 s and 09:05:25 + 3575/7909 s.

This is achieved by following my work right until the formula to be minimized, which would now be:

abs(a_1 – 120) + abs(a_2 – 120) + abs(a_3 – 120).

This is achieved by writing the equation as a piecewise function and then plugging in the limit points of each piece. The one that yields the smallest answer is 14400/7909 s, which when added to my t_1 and subtracted from my t_2 gives me my two above answers.

2. markodiablo | Profile

OK let’s give this a go. The closest I can see is 09:05 where the angle between the hour and minute hands is just under 120°. So if:

09:05 = Time
AH = Angle the hour hand moves by from Time 09:05
AM = Angle the minute hand moves by from Time 09:05

then:
AH = 360*MINUTE(Time)/60/60 + 360*SECOND(Time)/60/60/60
AM = 360*MINUTE(Time)/60+360*SECOND(Time)/60/60

Looking at a clock, the exact angle between hour and minute hands (AE) is:

AE = 90° – AH + AM
= 90° – [360*MINUTE(Time)/60/60 + 360*SECOND(Time)/60/60/60] + [360*MINUTE(Time)/60+360*SECOND(Time)/60/60]

Going up in seconds between the times 09:00:00 and 09:00:10 (11 seconds inclusive), we get this table:

Time AH AM AE Diff to 120°
9:05:00 0.500 30.000 119.500 0.500
9:05:01 0.502 30.100 119.598 0.402
9:05:02 0.503 30.200 119.697 0.303
9:05:03 0.505 30.300 119.795 0.205
9:05:04 0.507 30.400 119.893 0.107
9:05:05 0.508 30.500 119.992 0.008
9:05:06 0.510 30.600 120.090 0.090
9:05:07 0.512 30.700 120.188 0.188
9:05:08 0.513 30.800 120.287 0.287
9:05:09 0.515 30.900 120.385 0.385
9:05:10 0.517 31.000 120.483 0.483

From the table we can see that the exact time nearest to 120° (i.e. with the least difference) is…

09:05:05

Phew, I’m glad that’s done, I think my brain is melting.

3. hex | PUZZLE MASTER | Profile

Hi Bilbao,
I agree that the linear error method is more logical than the square error one. However, in the linear error method, the total error is the sum of the absolute values of the 3 error components as outlined in your solution (hence it is +/- too). Due to the absolute functions (which your solution uses), maximums and minimums cannot be solved for by straight differentiation.
Assuming that h:m=9:05 and using the simple error method, I have got the following:
a1 (angle hours-minutes) = -11/120 x s + 485/2 – 360
a2 (angle minutes-seconds) = -59/10 x s + 30
a3 (angle hours-seconds) = 719/120 x s – 545/2

Noting that a1, a2 and a3 are negative,
Total error = |a1 + 120| + |a2 + 120| + |a3 + 120|
This function does not have a continuous derivative where ai+120 changes signs. Specifically, the minimum occurs at one of the discontinuities. I guess the same applies to your formula, and hence the question.

When should we expect the next math puzzle? :mrgreen:

4. RK | Founder | Profile

will put up Bilbao’s solution as well as Bizarette18 later today, so you can better discuss this (incredibly) hard puzzle!

5. bizarette18 | PUZZLE MASTER | Profile

I think Jimmy Anders also has the right answer now.

6. RK | Founder | Profile

Just unmasked Bizarette18’s answer, and here is Bilbao’s:
http://www.smart-kit.com/wp-co.....lution.jpg

7. michaelc | Profile

The minimal linear error solution gives the angles below,

120, 120.1668985, and 119.8331015. Solution has one perfect angle, and the other 2 equally off from each other.

The minimal standard deviation solution gives these angles,

120.0821332, 120.0860218, and 119.8318450.

I’m not convinced that 1 is better than the other.

Standard deviation “penalizes” data that is farther away from the average more so than linear error. That’s about the extent of the difference between the 2.

Love to hear more feedback from others. Anyone else out there have persuading arguements for or against either one of these?

8. hex | PUZZLE MASTER | Profile

The more I think about the choice of linear vs square error method, the more clueless I am. It all depends on the definition of “closest to being evenly separated”. Michaelc has pointed out that farther values are penalized more than closer ones in the case of the square error.

9. KMESON | Profile

Great problem… My physics background stymied me. I assumed that the optimal angles would minimize the sum of the unit vectors pointing in the direction of each hand. Then it is easy to represent each hand with a phasor and write down the expression to minimize. Sadly it was transcendental. I then briefly tried minimizing square errors. Didn’t even think of trying absolute error. Congrats to the solvers!

10. suineg | PUZZLE MASTER | Profile

Congratulations to Bizarette18 and Bilbao, Bizarette18 answer was a much more intuitive answer, like a recursive process, kind of my aproach using the simplex method for the continuos part( I will try to do it today, see if my result match yours and post the comment of the process)
But Bilbao answer was what I have in mind it was to be done to solve the problem in an elegant way using complex numbers, also using Laplace transform could be a way to get to a continuos function that you derivate is equal to 0 in order to get the answer, but is far way more complicated, I did not fully get the details of the solution, especially the first arguments of creating the basics equations, but cool, very cool this problem it make me review Laplace, jaja.

11. markodiablo | Profile

Wowsers B and B that was some solution. Well done.

12. bilbao | Profile

Hi Hex,
now I fully understand what you meant. The fact that Maple showed the derivative of the error function made me thought it was continuous (true) and could be differentiated in every point(false).
So when I tried ‘fsolve’ in Maple and didn´t come up with a solution I just thought I was missing something in Maple (it is first time I use it). So I pinpointed the solution from the plot of the error function.
Eager to quickly share it with you all I guess I rushed.
Jimmy Anders might show us how this last step can be fulfilled in a more elegant way (piecewise,…

13. hex | PUZZLE MASTER | Profile

Hi Bilbao,
Glad you got what I meant concerning the error function. Note that it is a linear function that changes slopes. It is pretty straight forward to find out where the changes of slopes occur (by setting each of the 3 terms in the sum to zero), add to that the boundary conditions for the validity of the function (0<=h<=11, 0<=m<=59, 0<=s<60), and check the function value at each of these points. The minimum is bound to be at one of these points due to the function’s linearity.
Very nice puzzle; When’s the next one due?

14. oddy | Profile

If the second-hand of the clock moves in one second increments the time when they are closest (the amount the three hands deviate from 120 deg apart is 1.15 deg in total) is 5:49:09 – any other time results in larger gaps.

This assumes that the second hand moves in 1/60th, the minute hand moves in 1/3600th and the hour hand moves in 1/43200th of a full circle increments at each click of a second, and there are no in-betweens.

15. Goat Problem « Demo Blog | Guest

[…] New to the Smartkit? Check out this really hard math puzzle […]

16. SmileyGirl: match 3 puzzle game | Smart-Kit Puzzles and Games | Guest

[…] Will continue to keep an eye out for anyone else besides Bizarette18 that can solve The Complex Clock Puzzle… […]

To comment log in or register for a free Smartkit account.