Position 3D (pygeoid.coordinates.position)
This module contains Position3D class.
- class pygeoid.coordinates.position.Position3D(x, y, z)[source]
Class represents a 3D positioning vector.
The main purpose of the class is to store 3D positioning of the points in cartesian coordinates, so they can be easily transformed to curvilinear coordinates: geodetic, spherical, elliposidal-harmonic.
- Parameters:
x (float or array_like of floats) – Cartesian coordinates, in metres.
y (float or array_like of floats) – Cartesian coordinates, in metres.
z (float or array_like of floats) – Cartesian coordinates, in metres.
- classmethod from_geodetic(lat, lon, height, ell)[source]
Position, initialized from geodetic coordinates.
- Parameters:
lat (Quantity) – Geodetic latitude.
lon (Quantity) – Geodetic longitude.
height (Quantity) – Geodetic height.
ell (instance of the pygeoid.coordinates.ellipsoid.Ellipsoid) – Reference ellipsoid to which geodetic coordinates are referenced to.
- classmethod from_spherical(lat, lon, radius)[source]
Position, initialized from spherical coordinates.
- Parameters:
lat (Quantity) – Spherical latitude.
lon (Quantity) – Spherical longitude.
r (Quantity) – Radius.
radius (Unit("m"))
- classmethod from_ellipsoidal(rlat, lon, u_ax, ell)[source]
Position, initialized from ellipsoidal coordinates.
- Parameters:
rlat (Quantity) – Reduced latitude.
lon (Quantity) – Longitude.
u_ax (Quantity) – Polar axis of the ellipsoid passing through the given point.
ell (instance of the pygeoid.coordinates.ellipsoid.Ellipsoid) – Reference ellipsoid to which geodetic coordinates are referenced to.
- property cartesian
Return 3D cartesian coordinates
- property x
Return x coordinate
- property y
Return y coordinate
- property z
Return z coordinate
- geodetic(ell)[source]
Return geodetic coordinates.
- Parameters:
ell (instance of the pygeoid.coordinates.ellipsoid.Ellipsoid) – Reference ellipsoid to which geodetic coordinates are referenced to.
- Returns:
lat (~astropy.units.Quantity) – Geodetic latitude.
lon (~astropy.units.Quantity) – Geodetic longitude.
height (~astropy.units.Quantity) – Geodetic height.
- spherical()[source]
Return spherical (geocentric) coordinates.
- Returns:
lat (~astropy.units.Quantity) – Spherical latitude.
lon (~astropy.units.Quantity) – Spherical longitude.
r (~astropy.units.Quantity) – Radius.
- ellipsoidal(ell)[source]
Return ellipsoidal-harmonic coordinates.
- Parameters:
ell (instance of the pygeoid.coordinates.ellipsoid.Ellipsoid) – Reference ellipsoid to which ellipsoidal coordinates are referenced to.
- Returns:
rlat (~astropy.units.Quantity) – Reduced latitude.
lon (~astropy.units.Quantity) – Longitude.
u_ax (~astropy.units.Quantity) – Polar axis of the ellipsoid passing through the given point.
- enu(origin, ell=None)[source]
Return local east-north-up cartesian coordinates.
- Parameters:
origin (tuple of Quantity) – Ggeocentric (spherical) or geodetic coordinates of the origin (lat0, lon0, r0) or (lat0, lon0, h0).
ell (instance of the pygeoid.coordinates.ellipsoid.Ellipsoid) – Reference ellipsoid to which geodetic coordinates are referenced to. Default is None, meaning spherical coordinates instead of geodetic.
- Returns:
east, north, up – Local east-north-up cartesian coordinates.
- Return type:
Quantity