UNPKG

ootk

Version:

Orbital Object Toolkit including Multiple Propagators, Initial Orbit Determination, and Maneuver Calculations.

97 lines (96 loc) 5.06 kB
/** * @author @thkruz Theodore Kruczek * @description Orbital Object ToolKit (ootk) is a collection of tools for working * with satellites and other orbital objects. * @license AGPL-3.0-or-later * @copyright (c) 2025 Kruczek Labs LLC * * Many of the classes are based off of the work of @david-rc-dayton and his * Pious Squid library (https://github.com/david-rc-dayton/pious_squid) which * is licensed under the MIT license. * * Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the * terms of the GNU Affero General Public License as published by the Free Software * Foundation, either version 3 of the License, or (at your option) any later version. * * Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * See the GNU Affero General Public License for more details. * * You should have received a copy of the GNU Affero General Public License along with * Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>. */ import { AzEl, Degrees, Radians } from '../main.js'; /** * Celestial is a static class that provides methods for calculating the position of celestial objects such as the Sun, * Moon, and planets in the sky. To create an instance of a Celestial object, use the Star class. */ export declare class Celestial { private constructor(); /** * Calculates the azimuth and elevation of a celestial object at a given date, latitude, * longitude, right ascension, and declination. * @param date - The date for which to calculate the azimuth and elevation. * @param lat - The latitude of the observer. * @param lon - The longitude of the observer. * @param ra - The right ascension of the celestial object. * @param dec - The declination of the celestial object. * @returns An object containing the azimuth and elevation in degrees. */ static azEl(date: Date, lat: Degrees, lon: Degrees, ra: Radians, dec: Radians): AzEl<Degrees>; /** * Atmospheric refraction in astronomy, refers to the bending of light as it passes through the Earth's * atmosphere. This effect is most noticeable for celestial objects like stars and planets when they are * close to the horizon. Here's a breakdown of how it works: * * Actual Position: Due to this bending of light, the apparent position of a celestial object is slightly * different from its true position in the sky. When a star or planet is near the horizon, the effect is more * pronounced because the light path passes through more of the Earth's atmosphere, which increases the amount of * bending. * * A familiar example of atmospheric refraction is observed during sunrise and sunset. The Sun appears to * be above the horizon when it is actually just below it. This is because the light from the Sun is bent * upwards as it passes through the atmosphere. * @param h - elevation * @returns refraction */ static atmosphericRefraction(h: Radians): Radians; /** * Calculate the declination. Similar to latitude on Earth, declination is another celestial coordinate. * It measures how far north or south an object is from the celestial equator * @param l - ecliptic longitude * @param b - ecliptic latitude * @returns declination */ static declination(l: number, b: number): Radians; /** * Calculate the right ascension. This is a celestial coordinate used to determine the position of objects * in the sky. It's analogous to longitude on Earth. Right Ascension indicates how far east an object is * from the vernal equinox along the celestial equator. * @param l - ecliptic longitude * @param b - ecliptic latitude * @returns right ascension */ static rightAscension(l: number, b: number): Radians; /** * Calculate the elevation. Elevation, or altitude, is the angle between an object in the sky and the * observer's local horizon. It's commonly expressed in degrees, where 0 degrees is right at the horizon * and 90 degrees is directly overhead (the zenith), but we are using radians to support trigonometric * functions like Math.sin() and Math.cos(). * @param H - siderealTime * @param phi - latitude * @param dec - The declination of the sun * @returns elevation */ static elevation(H: number, phi: Radians, dec: Radians): Radians; /** * Calculate the azimuth. This is a compass direction measurement. Azimuth measures the angle along * the horizon from a specific reference direction (usually true north) to the point where a vertical * line from the object intersects the horizon. * @param H - siderealTime * @param phi - latitude * @param dec - The declination of the sun * @returns azimuth in rad */ static azimuth(H: number, phi: Radians, dec: Radians): Radians; }