Calculating direction of travel on a clock face

Join the discussion
Registration is free. Start your own thread to ask a follow-up.
6 replies · 3K views
medelec35
Messages
4
Reaction score
0
This is not a a school or college question, it is just for my interest.

Homework Statement



suppose I travel 605 meters North , then travel 673 meters West.
I have calculated shortest distance of Sq Root(605^2 + 673^2) = 905 meters

What I am now trying to calculate is direction to face as if standing on a clock.
e.g. calculate angle e.g 140 Deg, then convert that to 10 o'clock = NW
I and applying this to excel that's why I'm after a formula.


Homework Equations



360-(ARCTAN(605/673))/30 = 10 o'clock. ARCTAN was used because of TAN = OPP/ADJ

The Attempt at a Solution



although this formula worked in this case, I would like to know if fluke or proven in every case.

Thank you in advance for any assistance given.
 
Physics news on Phys.org
Welcome to PF.

Well, you can do that. But isn't it only useful with granularity of 30° increments.

In your case your angle is 42° from the horizontal, but might be expressed as 48° West of North. That lies inconveniently between 30° and 60° West of North. So is your direction then to be given as 8° clockwise of 10 O'clock or 22° Counter-Clockwise of 11 O'clock?
 
Thank you for your reply.
Good point.
I was thinking that north will always be 12 o'clock = 0 deg for this I would need an if statement for excel (assuming deg is in cell A1) e.g =IF(A1/30=0,12,A1/30)
east will always be 3 o'clock = 90 deg = 90/30 = 3 o'clock
south will always be six o'clock = 180 deg = 180/30 = 6 = 6 o'clock
NE will probably be be 10.30 = 315 deg? 315/30=10.50. Int 10.50= 10. (10.50-10)*60 =30 therefore time = 10.30
Etc.

So I may have to amend my formula but not sure what to yet, so degrees will always correct .

30 was used because hour hand moves 30 deg each hour

Doesn’t the deg calculation depend on the quadrant?
Going N then E would be in a different quadrant to going S then E
 
Last edited:
medelec35 said:
Doesn’t the deg calculation depend on the quadrant?
Going N then E would be in a different quadrant to going S then E

Yes. The sign is important. +x,+y = 1 - 3, +x,-y = 4 - 6, etc.

Degrees from a reference is not ambiguous.

Clever those mariners.
 
I believe I have worked out the answer.

In excell if two distances are stored in cells J16 and J11
then if direction is NW then use (ATAN(J16/J11)*180/PI())
If direction is SE then use 180-(ATAN(J16/J11)*180/PI())
If direction is SW then use 270-(ATAN(J16/J11)*180/PI())
If direction is NW then use 360-(ATAN(J16/J11)*180/PI())
I have used a nested if statement to use correct formula. Its a fairly large formula, so won't show it, since will not know what is in all other cells.
Then
Hour = deg/30
minutes = INT(((deg/30)-INT(deg/30))*60)
So if hand on a clock was adjusted to same time as answer, if you faced same direction as hour hand, then in theory you be facing correct way.
Could some one please let me know if all above formulas are correct?
Thank you.
 
ps. You should generaly use atan2() rather than atan(), it handles the infinity properly.
But be careful Excel's atan2() function has the arguments the opposite way around to everyone else.

There is also a degrees() function to handle the rad-deg conversion
 
Thanks for that.
In your opinion would all the formulas work in practice? I have tried 1 out but was a case of nearly bit not quiet there. A result of 3:39 should of been 2 something.
After trying a few more, most work ok.
I'm just after formula confirmation but with atan2() instead?