@observerly/astrometry
Version:
observerly's lightweight, zero-dependency, type safe astrometry library written in Typescript for calculating the position of celestial objects in the sky.
60 lines (59 loc) • 2.41 kB
TypeScript
/*****************************************************************************************************************/
import type { EquatorialCoordinate, GeographicCoordinate, HorizontalCoordinate } from './common';
/*****************************************************************************************************************/
type Q = EquatorialCoordinate & {
/**
*
* The Q index is a measure of the quality of the an observation, which takes into account the
* illumination of the Moon, the altitude of the target, and the altitude of the Sun as well as
* the angular separation between the Moon and the target.
*
* The Q index is a value between -1 and 1.
*
*/
Q: number;
/**
*
*
* The Moon's illumination factor, which has a range of 0 to 100 percent.
*
*/
K: number;
/**
*
* Angular separation between the Moon and the target, which has a range of 0 to 180 degrees.
*
*/
φ: number;
/**
*
* The altitude of the target, which has a range of -90 to 90 degrees.
*
*/
A: number;
/**
*
* The altitude of the Sun, which has a range of -90 to 90 degrees.
*
*/
alt: number;
};
/*****************************************************************************************************************/
export declare const q: (K: number, φ: number, A: number, sun: HorizontalCoordinate, moon: HorizontalCoordinate) => number;
/*****************************************************************************************************************/
/**
*
* getQIndex()
*
* @brief The Q index is a measure of the quality of the an observation, which takes into account the
* illumination of the Moon, the altitude of the target, and the altitude of the Sun as well as
* the angular separation between the Moon and the target.
*
* @param datetime - The date and time of the observation.
* @param observer - The geographic coordinates of the observer.
* @param target - The equatorial coordinates of the target object (at J2000.0).
* @returns The Q index of the observation, a value between -1 and 1.
*/
export declare function getQIndex(datetime: Date, observer: GeographicCoordinate, target: EquatorialCoordinate): Q;
export {};
/*****************************************************************************************************************/