pytmosph3r.planetary_system.observer
Module Contents
- class Observer(latitude: float | astropy.units.Quantity[pytmosph3r.util.pt.angle] = None, longitude: float | astropy.units.Quantity[pytmosph3r.util.pt.angle] = None, orbit=None, **kwargs)[source]
Bases:
pytmosph3r.log.LoggerDefines the position of the observer using a unit vector. The starting point of the vector is the center of the planet. The ending point is located at the coordinate (
latitude,longitude) on the unit sphere. Astropy’s units are supported. Floats are considered to be in SI units. WARNING: This class has been extracted fromRaysand should probably not be used independently.Set the observer’s position with:
- Parameters:
latitude (float, Unit, optional) – Latitude (in \(rad\) or astropy units). Default to 0.
longitude (float, Unit, optional) – Longitude (in \(rad\) or astropy units). Default to $pi$.
- property coordinates
Tuple (latitude, longitude).
- property orbit
- property cartesian_system
Cartesian coordinate system (x,y,z) of which:
z is oriented along the rotation axis (pointing towards the North Pole)
x points towards a reference point on the equator that corresponds to a longitude equal to zero
y is chosen to have a direct basis.
The coordinates of the unit vector defining the direction of the rays are then computed through
CartesianCoordinateSystemusing its spherical coordinates (latitude,longitude).
- latitude
Latitude coordinate of the ending point of the unit vector (in radians).
- longitude
Longitude coordinate of the ending point of the unit vector (in radians).
- add_ray_origin(altitude, angle)[source]
Function to add the origin point of a ray, i.e., its intersection with the terminator using its polar coordinates (
altitude,angle), to the Cartesian coordinate systemcartesian_system.This function is used for each ray in
Rays.compute_sub_rays.- Parameters:
altitude (float) – altitude (m) of the origin point
angle (float) – angle (radians) of the origin point