<div dir="ltr"><div><div><div><div><div><div>Hi,<br><br></div>I have used the function 
gc_pnt2gc, but it doesn&#39;t appear to be doing what I think it should be 
doing.  I assume this is because I am misunderstanding it.  What I think
 it does is give the distance in degrees between a lat/lon point (p_lat,
 p_lon), and its closest approach to the great circle line between two 
other lat/lon pairs (lat[2], lon[2]: and I assume that this great circle
 line is the shortest greatest circle line between these lat/lon 
pairs.)  Here is an example snippet of what I am trying to do:<br><br> p_lat = 41.6<br> p_lon = -76.84<br> lat = (/52.9921,55.3543/)<br> lon = (/-168.693,-160.346/)<br> dist = gc_pnt2gc(p_lat,p_lon,lat,lon)<br> print (&quot;The distance is: &quot; + dist)<br><br></div>Here is the output:<br>(0)     The distance is: 0.105952<br><br></div>I would expect the distance to be something around 53 degrees.<br><br></div>Could
 someone please explain to me what I am misunderstanding about this 
function?  And, do you know of another function that does what I am 
trying to do?  (That is, find the shortest distance between a point and a
 line on the Earth.)<br><br></div>Thank you!<br><br></div>Joe Grim<br></div>