Module marlu::pos::pal[][src]

Expand description

Useful Starlink PAL functions re-written in Rust.

PAL depends on ERFA and (luckily) all the PAL functions we need just use ERFA. Code is derived from https://github.com/Starlink/pal commit 7af65f0 and is licensed under the LGPL-3.0.

Why not just depend on PAL? It’s a huge pain. (1) The C library is either named libstarlink-pal or libpal, (2) it depends on ERFA so statically compiling it in a -sys crate is much harder than it should be, (3) this code changes so slowly that we’re unlikely to be out-of-date.

Functions

Cartesian to spherical coordinates

Spherical coordinates to direction cosines

Performs the 3-D forward unitary transformation

Normalize angle into range 0-2 pi

Scalar product of two 3-vectors Arguments: va = double[3] (Given) First vector vb = double[3] (Given) Second vector Returned Value: Scalar product va.vb Notes:

Normalizes a 3-vector also giving the modulus

Barycentric and heliocentric velocity and position of the Earth.

Greenwich mean sidereal time (consistent with IAU 2006 precession)

Compute parameters needed by palAmpqk and palMapqk.

Form the matrix of bias-precession-nutation (IAU 2006/2000A)