   SEARCH HOME Math Central Quandaries & Queries  Question from Dave, a parent: I want to make a tunnel from Toronto to Montreal (for example) Something like this http://mathcentral.uregina.ca/QQ/database/QQ.09.09/h/grant1.html ------------- My coordinates are 45.442455,-73.861340 (Montreal) and 43.442455, -79.861340 (Toronto) We have two responses for you

Dave,

There are three obvious approaches. (BTW, I'm not quite sure why you're using so many significant digits when half of them are obviously made up - I doubt that the lat-long's of Toronto and Montreal differ by integers to 5 sig-figs. It doesn't even make things much easier. But let it pass.)

1. For all practical purposes you can assume the arc & chord have the same length. Six degrees of longitude E-W at 45N is about 2.1 degrees great circle, and the chord/arc ratio is

sin(2.1 degrees)/(2.1 degrees in radians) ~ 0.9997

This is not to say the depth is not significant (it's about 5km deep), but that in such a long distance a big detour can be snuck in. This allows a plane Cartesian solution but it's a bit cheesy.

2. You can convert everything to Cartesian (x,y,z) coordinates to get the chord easily. For simplicity use coordinates with Toronto on the prime meridian, so Montreal is 6.00 degrees West.

Toronto is at (0, R cos(43.44), R sin(43.44))
Montreal is at (R cos(45.44)sin(6), R cos(45.44)sin(6), R sin(45.44))

where R is the radius of the earth and angles are in degrees

Pythagoras' theorem gives the chord. The arc is twice the arcsine of half the chord over R.

3. Another approach is to use spherical trig. Solve a spherical triangle with two edges 44.56 and 46.56 degrees and included angle 6 degrees. (You will need the spherical cosine law

cos(c) = cos(a) cos(b) + sin(a) sin(b) cos(C)

to do this.) This gives the arc directly; you then solve for the chord.

Good Hunting!
RD

I don't know why you had difficulty finding a useful web page. I googled "spherical distance formula" and found

http://www.movable-type.co.uk/scripts/latlong.html

Just enter your coordinates and click "see it on a map" and you are shown that your the points you've chosen are somewhat west of Mississauga and a bit west of the Montreal airport, with the great-circle distance between them equal to 525.5 km. (which agrees favorably with the official distance between the cities). The web page gives you the formula used. To understand the formula, of course, you would have to be able to understand how spherical coordinates work. If instead of using spherical coordinates you prefer to use an inner product, I discuss that method at the end.

Everybody seems to use the "average earth radius" of 6371 km. (= 3958.8 mi); for greater accuracy you would have to learn more about the earth radius (from Wikipedia or from somebody who knows something about geography). It is not clear to me what "greater accuracy" means in this context -- roads curve around and go up and down; airplanes deviate by dozens of miles from the shortest path.

For the "tunnel distance" it is perhaps easiest to switch from spherical to cartesian coordinates, then use the standard formula for the distance between two points. For this you need a calculator with trig functions (or use some program like Excel). If the latitude and longitude of point A are lata and longa, while those of point B are latb and longb, then the cartesian coordinates on the unit sphere are

x = cos(lata)*cos(longa)
y = cos(lata)*sin(longa)
z = sin(lata)

u = cos(latb)*cos(longb)
v = cos(latb)*sin(longb)
w = sin(latb)

dist = SQRT[(x-u)2 + (y-v)2 + (z-w)2] (= the chord length between the two points on a unit sphere).

To find the tunnel distance, multiply dist by the earth radius (6371). Note that for points that are as close together as Montreal and Toronto, the tunnel distance is only slightly less than the great-circle distance (measured along the earth). The numbers I found are 525.36 and 525.50.

Finally, once you have the cartesian coordinates of the points, the easy way to find the great-circle distance between them by using their inner product:
cos (angle subtended by the chord) = x*u + y*v + z*w.
If ARC = arccos (x*u + y*v + z*w) (in radians), the great-circle distance between the points is 6731*ARC.

Chris     Math Central is supported by the University of Regina and The Pacific Institute for the Mathematical Sciences.