Sorry guys, I don't know how to be more specific in the question without writing a way too long question...

Anyway my problem:

I have this formula to calculate the distance between two points on the earth. $$d=\operatorname{arcos}\left(\sin\theta_1\ \sin\theta_2+\cos\theta_1\ \cos\theta_2\ \cos(\phi_2-\phi_1)\right)$$

Now I need to calculate $\phi_2$.

I tried to change the formula myself but I failed to do it right. Now I am asking you guys to help me. It would be nice if someone could show me how he resolves it.

Thanks in advance

  • $\begingroup$ Welcome to math.SE: please note that your question has probably already been answered here. $\endgroup$ – A.P. May 8 '13 at 7:42
  • $\begingroup$ @A.P. well as i see it he wants to know the distance between two points, my problem is i know the distance but i dont know how o get the value at the end of the given distance $\endgroup$ – Andreas May 8 '13 at 7:56
  • $\begingroup$ I took the liberty of trying to improve the readability of your question using Tex. I hope this is fine with you. $\endgroup$ – A.P. May 8 '13 at 8:36

This basically amounts to some algebraic manipulation.
You have a formula of the form $$d=\operatorname{arcos}\left(\sin\theta_1\ \sin\theta_2+\cos\theta_1\ \cos\theta_2\ \cos(\phi_2-\phi_1)\right)$$ Now recall that $\operatorname{arcos}(x)$ is the inverse function of $\cos(\theta)$; therefore applying $\cos$ to both sides of the equation gives you the formula from the question I linked $$\cos d=\sin\theta_1\ \sin\theta_2+\cos\theta_1\ \cos\theta_2\ \cos(\phi_2-\phi_1)$$ But you actually want to know $\phi_2$ so we start by taking $\cos(\phi_2-\phi_1)$ to one side of the equality and leaving the rest on the other side $$\cos(\phi_2-\phi_1)=\frac{\cos d-\sin\theta_1\ \sin\theta_2}{\cos\theta_1\ \cos\theta_2}$$ Finally, we apply $\operatorname{arcos}$ to both sides of the equation and add $\phi_1$ $$ \begin{align} \phi_2-\phi_1&=\operatorname{arcos}\left(\frac{\cos d-\sin\theta_1\ \sin\theta_2}{\cos\theta_1\ \cos\theta_2}\right)\\ \phi_2&=\operatorname{arcos}\left(\frac{\cos d-\sin\theta_1\ \sin\theta_2}{\cos\theta_1\ \cos\theta_2}\right)+\phi_1\\ \end{align} $$

  • $\begingroup$ It won't work like that when i try with my code. Does d need to be a radiant value too? Tried both but none gives me the right answer... $\endgroup$ – Andreas May 8 '13 at 11:21
  • $\begingroup$ Everything should be in radians, yes. Could you please give me the example you tried? How did you check that it doesn't give you the right answer? $\endgroup$ – A.P. May 8 '13 at 17:23
  • $\begingroup$ Found the mistake: you have to divide d with the radius of the earth before getting the cos(d): cos(d/6370) $\endgroup$ – Andreas May 14 '13 at 13:45
  • $\begingroup$ Yes, @Andreas, that's exactly what it means for it to be in radians. ^_^ $\endgroup$ – A.P. May 15 '13 at 9:40

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.