2
$\begingroup$

Assuming the world is a sphere with no wind, can the great circle route of a vessel be predicted from the current position $\{\phi_i,\lambda_i\}$ and the current true course $\theta_i$?

Presently, I'm not concerning myself with speed, just the ability generate a formula for the GC so that I can draw it.

These are the useful formulae I've discovered.

$$ \begin{array}{ll} d &= \cos^{-1}\left(\sin\phi_i \sin\phi_j + \cos\phi_i \cos\phi_j \cos (\lambda_i-\lambda_j) \right) \\ b &= \cos^{-1}\left(\frac{\sin\phi_j-\sin\phi_i\cos(d)}{\sin(d)\cos\phi_i}\right) \\ s &= \sin(\lambda_j-\lambda_i) \\ \theta_i &= \left\{ \begin{array}{ll} b & \mbox{if } s < 0 \\ 2\pi-b & \mbox{if } s > 0 \end{array} \right. \end{array} $$

I am not presently concerning myself with the poles.

It is true to say that any great circle will cross all meridians so it does not seem unreasonable to determine a formula of the form:

$$ \phi = f(\lambda,\phi_0,\lambda_0,\theta_0) $$

I note that $\cos(2\pi - \theta) = \cos(\theta)$ so:

$$\begin{array}{ll} \cos(\theta_i) &= \frac{\sin\phi_j-\sin\phi_i\cos(d)}{\sin(d)\cos\phi_i} \\ &= \frac{\sin\phi_j-\sin\phi_i(\sin\phi_i \sin\phi_j + \cos\phi_i \cos\phi_j \cos (\lambda_i-\lambda_j))}{\sin\left(\cos^{-1}\left(\sin\phi_i \sin\phi_j + \cos\phi_i \cos\phi_j \cos (\lambda_i-\lambda_j) \right)\right)\cos\phi_i} \end{array}$$

This is an equation that has all the right variables, but I can't rearrange it.

Is there a better approach I should be taking?

UPDATE

It's worth noting that if we use colatitude ($\phi'$), the distance equation looks just like the law of cosines:

$$cos(d) = \cos\phi'_i \cos\phi'_j + \sin\phi'_i \sin\phi'_j \cos (\lambda_i-\lambda_j)$$

$\endgroup$
9
  • $\begingroup$ In LaTeX, you can use \sin, \cos, \tan etc for trig functions. Otherwise they are typeset as three variables being multiplied together. This also applies to \ln, \log, \exp, \det, and any other basic math functions. $\endgroup$ – alex.jordan Oct 9 '13 at 21:48
  • 1
    $\begingroup$ Updated with better LaTeX now. $\endgroup$ – stevemarvell Oct 9 '13 at 21:54
  • $\begingroup$ I think I know how to answer your question, once you explain what your symbols are. The symbols may be commonly understood among navigators, but not among this audience. You have an original location given in latitude and longitude, and you have an original heading angle. Then what information do you want? Do you want the position after traveling a certain number of degrees (or radians)? Or do you want the position when you attain a given longitude? Whatever, it’s relatively simple spherical trigonometry, your formulas look much too complicated to me. $\endgroup$ – Lubin Oct 9 '13 at 22:00
  • $\begingroup$ Are you looking for an exact great circle, or an approximation to some accuracy from a series of varying rhumb lines? $\endgroup$ – Pieter Geerkens Oct 9 '13 at 22:02
  • $\begingroup$ I know what a rhumb line is, and I assume that "varying rhumb lines" are ones where the meridians are not crossed with a constant bearing. So I'm not sure what the implications are. If you approach gives an approximation which is indistinguishable when views on a screen sized world map then I'd be happy to use it if it's simpler. $\endgroup$ – stevemarvell Oct 9 '13 at 22:10
2
$\begingroup$

You’re in an angle-side-angle situation, and you want to know the length of a side. One angle is given to you by the original heading, I’ll call it $\eta$, say measured clockwise from north. The other angle is the angle at the pole, difference between the original longitude and the longitude of the meridian you’re thinking of as variable. Let’s call that $\theta$. The side is the “colatitude”, the distance, in degrees (or radians) from the pole to the original position. Let’s call this $\lambda$. And you want to know the colatitude of your new point, since you already know its longitude. Call this $\Lambda$. Then I would solve your problem by using two standards from trigonometry, the alternative form of Law of Cosines, which reads $$ \cos a=-\cos b\cos c + \sin b \sin c \cos A\,, $$ where the angles of the triangle are $a,b,c$ and the corresponding opposite sides are $A,B,C$. The other is the Law of Sines, which reads, $$ \frac{\sin a}{\sin A}=\frac{\sin b}{\sin B}=\frac{\sin c}{\sin C}\,, $$ very much like the corresponding one in plane trig.

Now, we need to name the angle opposite the side that measures your original colatitude, call it $\alpha$. It becomes the $a$ of the Law of Cosines, and the longitude-difference $\theta$ becomes your $b$ there, while the heading angle is $\eta$, your $c$, and the (original) given colatitude is your $A$. Now apply L of C to get $\alpha$, and plug this into Law of Sines, since you have $$ \frac{\sin\Lambda}{\sin\eta}=\frac{\sin\lambda}{\sin\alpha}\,. $$ You wanted $\Lambda$, and there it is.

$\endgroup$
7
  • $\begingroup$ That looks extremely elegant. I can't really visualise how the ASA approach fits in with the sphere. I may have to reread and reread again. $\endgroup$ – stevemarvell Oct 9 '13 at 23:17
  • $\begingroup$ It is worth noting, though you may know already, that the bearing to north changes as vessel moves along the great circle. This seems to my naive eyes to assume the bearing is constant. I would prefer to be wrong. $\endgroup$ – stevemarvell Oct 9 '13 at 23:20
  • $\begingroup$ @stevemarvell, of course the vessel’s bearing changes during the trip, and I made no assumption of its constancy. But the initial bearing abides, and you keep that but repeat the computation for each meridian, changing only the longitude angle, which I called $\theta$. Sorry if my arbitrary choice of letters is inconsistent with your original notation! $\endgroup$ – Lubin Oct 10 '13 at 4:45
  • $\begingroup$ thanks for the confirmation. It was my fault regarding \theta. I didn't adhere to spherical geometry standards. $\endgroup$ – stevemarvell Oct 10 '13 at 13:23
  • $\begingroup$ I've started playing with it and have become mightily confused because you've used $\lambda$ to mean two different things in different contexts. Is it the longitude difference or the original colatitude? $\endgroup$ – stevemarvell Oct 10 '13 at 15:08
0
$\begingroup$

Attempt at @Lubin's solution

Let A be the colatitude of the initial position

Let B be the colatitude of the final position

Let C be the distance travelled along the GC

Let c be the longitude difference

Let b be the initial course

Let a be the ill defined angle

We wish to find B given b, c and A

$$\cos a = -\cos b\cos c + \sin b \sin c \cos A$$

$$\frac{\sin a}{\sin A}=\frac{\sin b}{\sin B}=\frac{\sin c}{\sin C}$$

$$ \begin{array}{ll} \sin B&=\frac{\sin b \sin A}{\sin a} \\ &=\frac{\sin b \sin A}{\sin (\cos^{-1}(-\cos b\cos c + \sin b \sin c \cos A)}\\ B &=\sin^{-1}\left(\frac{\sin b \sin A}{\sin (\cos^{-1}(-\cos b\cos c + \sin b \sin c \cos A)}\right)\\ \end{array} $$

Now converting to latitudes from colatitudes

$$ B' =\cos^{-1}\left(\frac{\sin b \cos A'}{\sin (\cos^{-1}(-\cos b\cos c + \sin b \sin c \sin A')}\right) $$

And into lat and lon

$$ \phi =\cos^{-1}\left(\frac{\sin \theta_0 \cos \phi_0}{\sin (\cos^{-1}(-\cos \theta_0 \cos (\lambda - \lambda_0) + \sin \theta_0 \sin (\lambda - \lambda_0) \sin \phi_0)}\right) $$

And that work other than some obvious multiple possible inverses issues. I guess there is some conditional I can apply.

I wonder if it can be simplified.

There is an oddity for some paths where all the lats are over 90, so I take them from 180.

In fact, it's also not handling negative latitudes at all.

UPDATE

$$B =\sin^{-1}\left(\frac{\sin b \sin A}{\sqrt{1-(-\cos b\cos c + \sin b \sin c \cos A)^2}}\right)$$

Lost an inverse, but got nowhere.

$\endgroup$
8
  • 1
    $\begingroup$ I definitely recommend holding with the “colatitude” notion, so that instead of negative latitudes, you are using colatitudes that are bigger than $90^\circ$. $\endgroup$ – Lubin Oct 11 '13 at 2:41
  • $\begingroup$ They are still coming out wrong. It's all those inverses I suspect. $\endgroup$ – stevemarvell Oct 11 '13 at 3:19
  • $\begingroup$ docs.google.com/spreadsheet/… $\endgroup$ – stevemarvell Oct 11 '13 at 3:21
  • $\begingroup$ You might be taking the wrong sign in the square-root part of the formula - - - $\endgroup$ – Lubin Oct 11 '13 at 17:09
  • $\begingroup$ @Lubin Yes, as would be similar with inverse trig. I'm not sure if there is a precondition I can check. $\endgroup$ – stevemarvell Oct 11 '13 at 18:43

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.