|
From: KURT P. <pet...@ms...> - 2013-03-28 13:29:53
|
If I'm using this SGP4 library: https://pypi.python.org/pypi/sgp4/which provides x,y,z of a satellite with respect to the center of the Earth, what do you think would be the best way to calculate the distance from the satellite to a lat/long point on the Earth using MATPLOT library basemaps? I suppose using WGS 84, I could do something like:# setup of basemap ('lcc' = lambert conformal conic). # use major and minor sphere radii from WGS84 ellipsoid. m = Basemap(llcrnrlon=-145.5,llcrnrlat=1.,urcrnrlon=-2.566,urcrnrlat=46.352,\ rsphere=(6378137.00,6356752.3142),\ resolution='l',area_thresh=1000.,projection='lcc',\ lat_1=50.,lon_0=-107.,ax=ax) x,y = m(lon, lat) But how could I get "Z" for a particular coordinate so I could be this norm calculation? And... would the x,y yielded above be in the same coordinate frame (ie, from the center of the Earth) as the SGP4 library in the first place? Regards,Kurt |