PyObserver#

class cysgp4.PyObserver(double lon_deg=0, double lat_deg=0, double alt_km=0)#

Bases: object

Thin wrapper around sgp4 (C++) Observer class.

The Observer class holds the location (as ECI, see PyEci) of an observer.

Note: Usually, a datetime is attached to an ECI location in sgp4. However, the Observer class has no interface to set the datetime and internally it is always set to zero. This is an odd design choice, because a geographic location is not fixed in the ECI system if time passes.

Parameters:
lon_degfloat (default: 0.)

Longitude of observer (geographic location) [deg].

lat_degfloat (default: 0.)

Latitude of observer (geographic location) [deg].

alt_kmfloat (default: 0.)

Altitude of observer (geographic location) [km].

Returns:
obsPyObserver object

Examples

Constructing and using a PyObserver object is straightforward:

>>> from cysgp4 import PyObserver, PyCoordGeodetic

>>> lon_deg, lat_deg = 6.88375, 50.525
>>> alt_km = 0.366
>>> obs = PyObserver(lon_deg, lat_deg, alt_km)
>>> obs
<PyObserver: 6.8838d, 50.5250d, 0.3660km>

>>> # Access is also possible via location property:
>>> obs.loc
<PyCoordGeodetic: 6.8838d, 50.5250d, 0.3660km>
>>> obs.loc = PyCoordGeodetic(1, 2, 3)

Constructor PyObserver(double lon_deg, double lat_deg, double alt_km)

Attributes Summary

loc

Geographic location (see also Class documentation).

Attributes Documentation

loc#

Geographic location (see also Class documentation).