Coordinates¤
Coordinate helpers used by trajectory/parallax calculations.
Classes¤
microlux.coordinates.Coordinates
¤
Bases: NamedTuple
A NamedTuple storing sky coordinates of the target source.
Attributes:
| Name | Type | Description |
|---|---|---|
ra |
str
|
Right ascension string in sexagesimal format ( |
dec |
str
|
Declination string in sexagesimal format ( |
get_degrees()
¤
Convert RA/Dec from sexagesimal strings to decimal degrees.
Returns
alpha: Right ascension in degrees.delta: Declination in degrees.
get_EN_vector()
¤
Calculate East/North unit vectors on the sky plane.
Returns
north_projected: Unit vector toward North on the tangent plane.east_projected: Unit vector toward East on the tangent plane.
Functions¤
microlux.coordinates.normalize_jd_for_ephemeris(times, time_ref, reduced_jd_cutoff: float = 2450000.0)
¤
Normalize reduced Julian dates for ephemeris calls.
Parameters
times: Observation epochs as a 1D array.time_ref: Reference epoch.reduced_jd_cutoff: Threshold used to detect reduced-JD input. Defaults to2450000.0.
Returns
times_jd: Full-JD epochs for ephemeris lookup.time_ref_jd: Full-JD reference epoch.
If times[0] < reduced_jd_cutoff, both outputs are shifted by reduced_jd_cutoff.
microlux.coordinates.velocity_of_Earth(full_BJD)
¤
Calculate Earth's barycentric velocity at a given epoch.
Parameters
full_BJD: Barycentric Julian Date in full-JD form (e.g.,245xxxxor246xxxx).
Returns
velocity: Earth barycentric velocity vector inAU/day, shape(3,).
microlux.coordinates.annual_parallax_shift(times, time_ref, coords: Coordinates)
¤
Compute annual parallax displacement projected to North/East.
Parameters
times: Observation epochs in JD.time_ref: Reference epoch in JD (typicallyt0_par).coords: Source sky coordinates.
Returns
delta_s_projected: Array with shape(N, 2)where columns are[North, East]inAU.