ootk 4.0.8 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +9 -2
- package/README.md +0 -15
- package/dist/body/Celestial.d.ts +96 -0
- package/dist/body/Celestial.js +124 -0
- package/dist/body/Celestial.js.map +1 -0
- package/dist/body/Earth.d.ts +68 -0
- package/dist/body/Earth.js +198 -0
- package/dist/body/Earth.js.map +1 -0
- package/dist/body/Moon.d.ts +137 -0
- package/dist/body/Moon.js +464 -0
- package/dist/body/Moon.js.map +1 -0
- package/dist/body/NutationAngles.d.ts +38 -0
- package/dist/body/NutationAngles.js +24 -0
- package/dist/body/NutationAngles.js.map +1 -0
- package/dist/body/PrecessionAngles.d.ts +29 -0
- package/dist/body/PrecessionAngles.js +24 -0
- package/dist/body/PrecessionAngles.js.map +1 -0
- package/dist/body/Sun.d.ts +305 -0
- package/dist/body/Sun.js +548 -0
- package/dist/body/Sun.js.map +1 -0
- package/dist/body/index.d.ts +26 -0
- package/dist/body/index.js +27 -0
- package/dist/body/index.js.map +1 -0
- package/dist/coordinate/ClassicalElements.d.ts +132 -0
- package/dist/coordinate/ClassicalElements.js +279 -0
- package/dist/coordinate/ClassicalElements.js.map +1 -0
- package/dist/coordinate/EquinoctialElements.d.ts +114 -0
- package/dist/coordinate/EquinoctialElements.js +172 -0
- package/dist/coordinate/EquinoctialElements.js.map +1 -0
- package/dist/coordinate/FormatTle.d.ts +95 -0
- package/dist/coordinate/FormatTle.js +184 -0
- package/dist/coordinate/FormatTle.js.map +1 -0
- package/dist/coordinate/Geodetic.d.ts +110 -0
- package/dist/coordinate/Geodetic.js +163 -0
- package/dist/coordinate/Geodetic.js.map +1 -0
- package/dist/coordinate/Hill.d.ts +1 -1
- package/dist/coordinate/Hill.js +1 -1
- package/dist/coordinate/Hill.js.map +1 -1
- package/dist/coordinate/ITRF.d.ts +75 -0
- package/dist/coordinate/ITRF.js +135 -0
- package/dist/coordinate/ITRF.js.map +1 -0
- package/dist/coordinate/J2000.d.ts +65 -0
- package/dist/coordinate/J2000.js +120 -0
- package/dist/coordinate/J2000.js.map +1 -0
- package/dist/coordinate/RIC.d.ts +64 -0
- package/dist/coordinate/RIC.js +79 -0
- package/dist/coordinate/RIC.js.map +1 -0
- package/dist/coordinate/RelativeState.d.ts +70 -0
- package/dist/coordinate/RelativeState.js +79 -0
- package/dist/coordinate/RelativeState.js.map +1 -0
- package/dist/coordinate/StateVector.d.ts +76 -0
- package/dist/coordinate/StateVector.js +97 -0
- package/dist/coordinate/StateVector.js.map +1 -0
- package/dist/coordinate/TEME.d.ts +57 -0
- package/dist/coordinate/TEME.js +89 -0
- package/dist/coordinate/TEME.js.map +1 -0
- package/dist/coordinate/Tle.d.ts +430 -0
- package/dist/coordinate/Tle.js +865 -0
- package/dist/coordinate/Tle.js.map +1 -0
- package/dist/coordinate/index.d.ts +11 -0
- package/dist/coordinate/index.js +12 -0
- package/dist/coordinate/index.js.map +1 -1
- package/dist/coordinate/tle-format-data.d.ts +41 -0
- package/dist/coordinate/tle-format-data.js +46 -0
- package/dist/coordinate/tle-format-data.js.map +1 -0
- package/dist/covariance/CovarianceSample.d.ts +1 -1
- package/dist/covariance/CovarianceSample.js +1 -1
- package/dist/covariance/CovarianceSample.js.map +1 -1
- package/dist/covariance/StateCovariance.d.ts +1 -1
- package/dist/covariance/StateCovariance.js +1 -1
- package/dist/covariance/StateCovariance.js.map +1 -1
- package/dist/data/DataHandler.d.ts +66 -0
- package/dist/data/DataHandler.js +80 -0
- package/dist/data/DataHandler.js.map +1 -0
- package/dist/data/values/Egm96Data.d.ts +37 -0
- package/dist/data/values/Egm96Data.js +63 -0
- package/dist/data/values/Egm96Data.js.map +1 -0
- package/dist/data/values/HpAtmosphereData.d.ts +33 -0
- package/dist/data/values/HpAtmosphereData.js +58 -0
- package/dist/data/values/HpAtmosphereData.js.map +1 -0
- package/dist/data/values/HpAtmosphereResult.d.ts +29 -0
- package/dist/data/values/HpAtmosphereResult.js +38 -0
- package/dist/data/values/HpAtmosphereResult.js.map +1 -0
- package/dist/data/values/Iau1980Data.d.ts +36 -0
- package/dist/data/values/Iau1980Data.js +52 -0
- package/dist/data/values/Iau1980Data.js.map +1 -0
- package/dist/data/values/LeapSecond.d.ts +27 -0
- package/dist/data/values/LeapSecond.js +35 -0
- package/dist/data/values/LeapSecond.js.map +1 -0
- package/dist/data/values/LeapSecondData.d.ts +41 -0
- package/dist/data/values/LeapSecondData.js +103 -0
- package/dist/data/values/LeapSecondData.js.map +1 -0
- package/dist/data/values/egm96.d.ts +24 -0
- package/dist/data/values/egm96.js +726 -0
- package/dist/data/values/egm96.js.map +1 -0
- package/dist/data/values/hpAtmosphere.d.ts +24 -0
- package/dist/data/values/hpAtmosphere.js +76 -0
- package/dist/data/values/hpAtmosphere.js.map +1 -0
- package/dist/data/values/iau1980.d.ts +24 -0
- package/dist/data/values/iau1980.js +30 -0
- package/dist/data/values/iau1980.js.map +1 -0
- package/dist/enums/AngularDiameterMethod.d.ts +27 -0
- package/dist/enums/AngularDiameterMethod.js +29 -0
- package/dist/enums/AngularDiameterMethod.js.map +1 -0
- package/dist/enums/AngularDistanceMethod.d.ts +27 -0
- package/dist/enums/AngularDistanceMethod.js +29 -0
- package/dist/enums/AngularDistanceMethod.js.map +1 -0
- package/dist/enums/OrbitRegime.d.ts +30 -0
- package/dist/enums/OrbitRegime.js +32 -0
- package/dist/enums/OrbitRegime.js.map +1 -0
- package/dist/enums/PassType.d.ts +28 -0
- package/dist/enums/PassType.js +30 -0
- package/dist/enums/PassType.js.map +1 -0
- package/dist/enums/Sgp4OpsMode.d.ts +26 -0
- package/dist/enums/Sgp4OpsMode.js +28 -0
- package/dist/enums/Sgp4OpsMode.js.map +1 -0
- package/dist/enums/index.d.ts +5 -0
- package/dist/enums/index.js +5 -0
- package/dist/enums/index.js.map +1 -1
- package/dist/force/AtmosphericDrag.d.ts +1 -1
- package/dist/force/AtmosphericDrag.js +1 -1
- package/dist/force/AtmosphericDrag.js.map +1 -1
- package/dist/force/EarthGravity.d.ts +1 -1
- package/dist/force/EarthGravity.js +1 -1
- package/dist/force/EarthGravity.js.map +1 -1
- package/dist/force/Force.d.ts +1 -1
- package/dist/force/ForceModel.d.ts +1 -1
- package/dist/force/ForceModel.js +1 -1
- package/dist/force/ForceModel.js.map +1 -1
- package/dist/force/Gravity.d.ts +1 -1
- package/dist/force/Gravity.js +1 -1
- package/dist/force/Gravity.js.map +1 -1
- package/dist/force/SolarRadiationPressure.d.ts +1 -1
- package/dist/force/SolarRadiationPressure.js +1 -1
- package/dist/force/SolarRadiationPressure.js.map +1 -1
- package/dist/force/ThirdBodyGravity.d.ts +1 -1
- package/dist/force/ThirdBodyGravity.js +1 -1
- package/dist/force/ThirdBodyGravity.js.map +1 -1
- package/dist/force/Thrust.d.ts +1 -1
- package/dist/force/Thrust.js +1 -1
- package/dist/force/Thrust.js.map +1 -1
- package/dist/interfaces/BaseObjectParams.d.ts +31 -0
- package/dist/interfaces/BaseObjectParams.js +24 -0
- package/dist/interfaces/BaseObjectParams.js.map +1 -0
- package/dist/interfaces/ClassicalElementsParams.d.ts +33 -0
- package/dist/interfaces/ClassicalElementsParams.js +24 -0
- package/dist/interfaces/ClassicalElementsParams.js.map +1 -0
- package/dist/interfaces/EquinoctialElementsParams.d.ts +35 -0
- package/dist/interfaces/EquinoctialElementsParams.js +24 -0
- package/dist/interfaces/EquinoctialElementsParams.js.map +1 -0
- package/dist/interfaces/GroundPositionParams.d.ts +28 -0
- package/dist/interfaces/GroundPositionParams.js +24 -0
- package/dist/interfaces/GroundPositionParams.js.map +1 -0
- package/dist/interfaces/OmmFormat.d.ts +62 -0
- package/dist/interfaces/OmmFormat.js +2 -0
- package/dist/interfaces/OmmFormat.js.map +1 -0
- package/dist/interfaces/OptionsParams.d.ts +3 -0
- package/dist/interfaces/OptionsParams.js +2 -0
- package/dist/interfaces/OptionsParams.js.map +1 -0
- package/dist/interfaces/RfSensorParams.d.ts +1 -1
- package/dist/interfaces/SatelliteParams.d.ts +18 -0
- package/dist/interfaces/SatelliteParams.js +2 -0
- package/dist/interfaces/SatelliteParams.js.map +1 -0
- package/dist/interfaces/SensorParams.d.ts +38 -0
- package/dist/interfaces/SensorParams.js +2 -0
- package/dist/interfaces/SensorParams.js.map +1 -0
- package/dist/interfaces/StarObjectParams.d.ts +10 -0
- package/dist/interfaces/StarObjectParams.js +2 -0
- package/dist/interfaces/StarObjectParams.js.map +1 -0
- package/dist/interfaces/TimeVariables.d.ts +6 -0
- package/dist/interfaces/TimeVariables.js +2 -0
- package/dist/interfaces/TimeVariables.js.map +1 -0
- package/dist/interfaces/index.d.ts +8 -0
- package/dist/interpolator/ChebyshevCoefficients.d.ts +1 -1
- package/dist/interpolator/ChebyshevCoefficients.js +1 -1
- package/dist/interpolator/ChebyshevCoefficients.js.map +1 -1
- package/dist/interpolator/ChebyshevInterpolator.d.ts +1 -1
- package/dist/interpolator/ChebyshevInterpolator.js +1 -1
- package/dist/interpolator/ChebyshevInterpolator.js.map +1 -1
- package/dist/interpolator/CubicSpline.d.ts +1 -1
- package/dist/interpolator/CubicSplineInterpolator.d.ts +1 -1
- package/dist/interpolator/CubicSplineInterpolator.js +1 -1
- package/dist/interpolator/CubicSplineInterpolator.js.map +1 -1
- package/dist/interpolator/Interpolator.d.ts +1 -1
- package/dist/interpolator/Interpolator.js +1 -1
- package/dist/interpolator/Interpolator.js.map +1 -1
- package/dist/interpolator/LagrangeInterpolator.d.ts +1 -1
- package/dist/interpolator/LagrangeInterpolator.js +1 -1
- package/dist/interpolator/LagrangeInterpolator.js.map +1 -1
- package/dist/interpolator/StateInterpolator.d.ts +1 -1
- package/dist/interpolator/VerletBlendInterpolator.d.ts +1 -1
- package/dist/interpolator/VerletBlendInterpolator.js +1 -1
- package/dist/interpolator/VerletBlendInterpolator.js.map +1 -1
- package/dist/main.d.ts +11 -3
- package/dist/main.js +11 -3
- package/dist/main.js.map +1 -1
- package/dist/maneuver/TwoBurnOrbitTransfer.d.ts +1 -1
- package/dist/maneuver/TwoBurnOrbitTransfer.js +1 -1
- package/dist/maneuver/TwoBurnOrbitTransfer.js.map +1 -1
- package/dist/maneuver/Waypoint.d.ts +1 -1
- package/dist/maneuver/Waypoint.js +1 -1
- package/dist/maneuver/Waypoint.js.map +1 -1
- package/dist/objects/BaseObject.d.ts +74 -0
- package/dist/objects/BaseObject.js +151 -0
- package/dist/objects/BaseObject.js.map +1 -0
- package/dist/objects/DetailedSatellite.d.ts +3 -1
- package/dist/objects/DetailedSatellite.js +4 -2
- package/dist/objects/DetailedSatellite.js.map +1 -1
- package/dist/objects/DetailedSensor.d.ts +2 -1
- package/dist/objects/DetailedSensor.js +1 -1
- package/dist/objects/DetailedSensor.js.map +1 -1
- package/dist/objects/GroundObject.d.ts +85 -0
- package/dist/objects/GroundObject.js +143 -0
- package/dist/objects/GroundObject.js.map +1 -0
- package/dist/objects/LandObject.d.ts +2 -1
- package/dist/objects/LandObject.js +1 -1
- package/dist/objects/LandObject.js.map +1 -1
- package/dist/objects/Marker.d.ts +1 -1
- package/dist/objects/Marker.js +1 -1
- package/dist/objects/Marker.js.map +1 -1
- package/dist/objects/RfSensor.d.ts +1 -2
- package/dist/objects/RfSensor.js +1 -2
- package/dist/objects/RfSensor.js.map +1 -1
- package/dist/objects/Satellite.d.ts +226 -0
- package/dist/objects/Satellite.js +443 -0
- package/dist/objects/Satellite.js.map +1 -0
- package/dist/objects/Sensor.d.ts +100 -0
- package/dist/objects/Sensor.js +239 -0
- package/dist/objects/Sensor.js.map +1 -0
- package/dist/objects/Star.d.ts +36 -0
- package/dist/objects/Star.js +59 -0
- package/dist/objects/Star.js.map +1 -0
- package/dist/objects/index.d.ts +5 -0
- package/dist/objects/index.js +5 -0
- package/dist/objects/index.js.map +1 -1
- package/dist/observation/Observation.d.ts +1 -1
- package/dist/observation/ObservationOptical.d.ts +1 -1
- package/dist/observation/ObservationOptical.js +1 -1
- package/dist/observation/ObservationOptical.js.map +1 -1
- package/dist/observation/ObservationRadar.d.ts +1 -1
- package/dist/observation/ObservationRadar.js +1 -1
- package/dist/observation/ObservationRadar.js.map +1 -1
- package/dist/observation/ObservationUtils.d.ts +3 -1
- package/dist/observation/ObservationUtils.js +15 -1
- package/dist/observation/ObservationUtils.js.map +1 -1
- package/dist/observation/RAE.d.ts +111 -0
- package/dist/observation/RAE.js +215 -0
- package/dist/observation/RAE.js.map +1 -0
- package/dist/observation/RadecGeocentric.d.ts +111 -0
- package/dist/observation/RadecGeocentric.js +169 -0
- package/dist/observation/RadecGeocentric.js.map +1 -0
- package/dist/observation/RadecTopocentric.d.ts +123 -0
- package/dist/observation/RadecTopocentric.js +196 -0
- package/dist/observation/RadecTopocentric.js.map +1 -0
- package/dist/observation/index.d.ts +26 -0
- package/dist/observation/index.js +27 -0
- package/dist/observation/index.js.map +1 -0
- package/dist/operations/BoxMuller.d.ts +1 -1
- package/dist/operations/BoxMuller.js +1 -1
- package/dist/operations/BoxMuller.js.map +1 -1
- package/dist/operations/EulerAngles.d.ts +1 -1
- package/dist/operations/EulerAngles.js +1 -1
- package/dist/operations/EulerAngles.js.map +1 -1
- package/dist/operations/Matrix.d.ts +170 -0
- package/dist/operations/Matrix.js +405 -0
- package/dist/operations/Matrix.js.map +1 -0
- package/dist/operations/Quaternion.d.ts +1 -1
- package/dist/operations/Quaternion.js +1 -1
- package/dist/operations/Quaternion.js.map +1 -1
- package/dist/operations/Random.d.ts +40 -0
- package/dist/operations/Random.js +50 -0
- package/dist/operations/Random.js.map +1 -0
- package/dist/operations/RandomGaussianSource.d.ts +1 -1
- package/dist/operations/RandomGaussianSource.js +1 -1
- package/dist/operations/RandomGaussianSource.js.map +1 -1
- package/dist/operations/Vector.d.ts +262 -0
- package/dist/operations/Vector.js +415 -0
- package/dist/operations/Vector.js.map +1 -0
- package/dist/operations/Vector3D.d.ts +86 -0
- package/dist/operations/Vector3D.js +241 -0
- package/dist/operations/Vector3D.js.map +1 -0
- package/dist/operations/operations.d.ts +26 -0
- package/dist/operations/operations.js +27 -0
- package/dist/operations/operations.js.map +1 -0
- package/dist/optimize/ChebyshevCompressor.js +1 -1
- package/dist/optimize/ChebyshevCompressor.js.map +1 -1
- package/dist/optimize/PolynomialRegression.js +1 -1
- package/dist/optimize/PolynomialRegression.js.map +1 -1
- package/dist/optimize/SimplexEntry.js +1 -1
- package/dist/optimize/SimplexEntry.js.map +1 -1
- package/dist/orbit_determination/BatchLeastSquaresOD.d.ts +1 -1
- package/dist/orbit_determination/BatchLeastSquaresOD.js +1 -1
- package/dist/orbit_determination/BatchLeastSquaresOD.js.map +1 -1
- package/dist/orbit_determination/BatchLeastSquaresResult.d.ts +1 -1
- package/dist/orbit_determination/GibbsIOD.d.ts +1 -1
- package/dist/orbit_determination/GibbsIOD.js +1 -1
- package/dist/orbit_determination/GibbsIOD.js.map +1 -1
- package/dist/orbit_determination/GoodingIOD.d.ts +1 -1
- package/dist/orbit_determination/GoodingIOD.js +1 -1
- package/dist/orbit_determination/GoodingIOD.js.map +1 -1
- package/dist/orbit_determination/HerrickGibbsIOD.d.ts +1 -1
- package/dist/orbit_determination/HerrickGibbsIOD.js +1 -1
- package/dist/orbit_determination/HerrickGibbsIOD.js.map +1 -1
- package/dist/orbit_determination/LambertIOD.d.ts +1 -1
- package/dist/orbit_determination/LambertIOD.js +1 -1
- package/dist/orbit_determination/LambertIOD.js.map +1 -1
- package/dist/orbit_determination/ModifiedGoodingIOD.d.ts +1 -1
- package/dist/orbit_determination/ModifiedGoodingIOD.js +1 -1
- package/dist/orbit_determination/ModifiedGoodingIOD.js.map +1 -1
- package/dist/orbit_determination/index.d.ts +7 -0
- package/dist/orbit_determination/index.js +8 -0
- package/dist/orbit_determination/index.js.map +1 -0
- package/dist/propagator/KeplerPropagator.d.ts +1 -1
- package/dist/propagator/KeplerPropagator.js +1 -1
- package/dist/propagator/KeplerPropagator.js.map +1 -1
- package/dist/propagator/Propagator.d.ts +1 -1
- package/dist/propagator/Propagator.js +1 -1
- package/dist/propagator/Propagator.js.map +1 -1
- package/dist/propagator/RkCheckpoint.d.ts +1 -1
- package/dist/propagator/RkResult.d.ts +1 -1
- package/dist/propagator/RungeKutta4Propagator.d.ts +1 -1
- package/dist/propagator/RungeKutta4Propagator.js +1 -1
- package/dist/propagator/RungeKutta4Propagator.js.map +1 -1
- package/dist/propagator/RungeKuttaAdaptive.d.ts +1 -1
- package/dist/propagator/RungeKuttaAdaptive.js +1 -1
- package/dist/propagator/RungeKuttaAdaptive.js.map +1 -1
- package/dist/propagator/Sgp4Propagator.d.ts +1 -1
- package/dist/sgp4/index.d.ts +23 -0
- package/dist/sgp4/index.js +24 -0
- package/dist/sgp4/index.js.map +1 -0
- package/dist/sgp4/sgp4-error.d.ts +22 -0
- package/dist/sgp4/sgp4-error.js +44 -0
- package/dist/sgp4/sgp4-error.js.map +1 -0
- package/dist/sgp4/sgp4.d.ts +102 -0
- package/dist/sgp4/sgp4.js +3167 -0
- package/dist/sgp4/sgp4.js.map +1 -0
- package/dist/smoothing/ExponentialSmoothing.d.ts +1 -1
- package/dist/time/Epoch.d.ts +44 -0
- package/dist/time/Epoch.js +109 -0
- package/dist/time/Epoch.js.map +1 -0
- package/dist/time/EpochGPS.d.ts +42 -0
- package/dist/time/EpochGPS.js +70 -0
- package/dist/time/EpochGPS.js.map +1 -0
- package/dist/time/EpochTAI.d.ts +26 -0
- package/dist/time/EpochTAI.js +27 -0
- package/dist/time/EpochTAI.js.map +1 -0
- package/dist/time/EpochTDB.d.ts +26 -0
- package/dist/time/EpochTDB.js +27 -0
- package/dist/time/EpochTDB.js.map +1 -0
- package/dist/time/EpochTT.d.ts +26 -0
- package/dist/time/EpochTT.js +27 -0
- package/dist/time/EpochTT.js.map +1 -0
- package/dist/time/EpochUTC.d.ts +59 -0
- package/dist/time/EpochUTC.js +137 -0
- package/dist/time/EpochUTC.js.map +1 -0
- package/dist/time/EpochWindow.d.ts +28 -0
- package/dist/time/EpochWindow.js +31 -0
- package/dist/time/EpochWindow.js.map +1 -0
- package/dist/time/TimeStamped.d.ts +43 -0
- package/dist/time/TimeStamped.js +46 -0
- package/dist/time/TimeStamped.js.map +1 -0
- package/dist/time/index.d.ts +30 -0
- package/dist/time/index.js +31 -0
- package/dist/time/index.js.map +1 -0
- package/dist/transforms/TransformCache.d.ts +27 -0
- package/dist/transforms/TransformCache.js +41 -0
- package/dist/transforms/TransformCache.js.map +1 -0
- package/dist/transforms/conversions.d.ts +63 -0
- package/dist/transforms/conversions.js +88 -0
- package/dist/transforms/conversions.js.map +1 -0
- package/dist/transforms/index.d.ts +1 -0
- package/dist/transforms/index.js +1 -0
- package/dist/transforms/index.js.map +1 -1
- package/dist/transforms/transforms.d.ts +166 -2
- package/dist/transforms/transforms.js +372 -1
- package/dist/transforms/transforms.js.map +1 -1
- package/dist/types/types.d.ts +674 -2
- package/dist/types/types.js +36 -0
- package/dist/types/types.js.map +1 -1
- package/dist/utils/constants.d.ts +80 -0
- package/dist/utils/constants.js +87 -0
- package/dist/utils/constants.js.map +1 -0
- package/dist/utils/functions.d.ts +228 -0
- package/dist/utils/functions.js +476 -0
- package/dist/utils/functions.js.map +1 -1
- package/dist/utils/index.d.ts +3 -1
- package/dist/utils/index.js +3 -1
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/jacobian.d.ts +1 -1
- package/dist/utils/jacobian.js +1 -1
- package/dist/utils/jacobian.js.map +1 -1
- package/dist/utils/linearDistance.d.ts +8 -0
- package/dist/utils/linearDistance.js +10 -0
- package/dist/utils/linearDistance.js.map +1 -0
- package/package.json +4 -7
- package/src/body/Celestial.ts +134 -0
- package/src/body/Earth.ts +260 -0
- package/src/body/Moon.ts +556 -0
- package/src/body/NutationAngles.ts +40 -0
- package/src/body/PrecessionAngles.ts +31 -0
- package/src/body/Sun.ts +669 -0
- package/src/body/index.ts +27 -0
- package/src/body/suncalc.LICENSE.md +18 -0
- package/src/coordinate/ClassicalElements.ts +326 -0
- package/src/coordinate/EquinoctialElements.ts +189 -0
- package/src/coordinate/FormatTle.ts +214 -0
- package/src/coordinate/Geodetic.ts +186 -0
- package/src/coordinate/Hill.ts +1 -1
- package/src/coordinate/ITRF.ts +146 -0
- package/src/coordinate/J2000.ts +130 -0
- package/src/coordinate/RIC.ts +87 -0
- package/src/coordinate/RelativeState.ts +101 -0
- package/src/coordinate/StateVector.ts +122 -0
- package/src/coordinate/TEME.ts +97 -0
- package/src/coordinate/Tle.ts +1024 -0
- package/src/coordinate/index.ts +12 -0
- package/src/coordinate/tle-format-data.ts +47 -0
- package/src/covariance/CovarianceSample.ts +1 -1
- package/src/covariance/StateCovariance.ts +1 -1
- package/src/data/DataHandler.ts +88 -0
- package/src/data/values/Egm96Data.ts +75 -0
- package/src/data/values/HpAtmosphereData.ts +76 -0
- package/src/data/values/HpAtmosphereResult.ts +41 -0
- package/src/data/values/Iau1980Data.ts +63 -0
- package/src/data/values/LeapSecond.ts +37 -0
- package/src/data/values/LeapSecondData.ts +113 -0
- package/src/data/values/egm96.ts +728 -0
- package/src/data/values/hpAtmosphere.ts +79 -0
- package/src/data/values/iau1980.ts +32 -0
- package/src/enums/AngularDiameterMethod.ts +28 -0
- package/src/enums/AngularDistanceMethod.ts +28 -0
- package/src/enums/OrbitRegime.ts +31 -0
- package/src/enums/PassType.ts +29 -0
- package/src/enums/Sgp4OpsMode.ts +27 -0
- package/src/enums/index.ts +5 -0
- package/src/force/AtmosphericDrag.ts +1 -1
- package/src/force/EarthGravity.ts +1 -1
- package/src/force/Force.ts +1 -1
- package/src/force/ForceModel.ts +1 -1
- package/src/force/Gravity.ts +1 -1
- package/src/force/SolarRadiationPressure.ts +1 -1
- package/src/force/ThirdBodyGravity.ts +1 -1
- package/src/force/Thrust.ts +1 -1
- package/src/interfaces/BaseObjectParams.ts +33 -0
- package/src/interfaces/ClassicalElementsParams.ts +35 -0
- package/src/interfaces/EquinoctialElementsParams.ts +37 -0
- package/src/interfaces/GroundPositionParams.ts +30 -0
- package/src/interfaces/OmmFormat.ts +63 -0
- package/src/interfaces/OptionsParams.ts +3 -0
- package/src/interfaces/RfSensorParams.ts +1 -1
- package/src/interfaces/SatelliteParams.ts +20 -0
- package/src/interfaces/SensorParams.ts +39 -0
- package/src/interfaces/StarObjectParams.ts +11 -0
- package/src/interfaces/TimeVariables.ts +7 -0
- package/src/interfaces/index.ts +8 -0
- package/src/interpolator/ChebyshevCoefficients.ts +1 -1
- package/src/interpolator/ChebyshevInterpolator.ts +1 -1
- package/src/interpolator/CubicSpline.ts +1 -1
- package/src/interpolator/CubicSplineInterpolator.ts +1 -1
- package/src/interpolator/Interpolator.ts +1 -1
- package/src/interpolator/LagrangeInterpolator.ts +1 -1
- package/src/interpolator/StateInterpolator.ts +1 -1
- package/src/interpolator/VerletBlendInterpolator.ts +1 -1
- package/src/main.ts +11 -3
- package/src/maneuver/TwoBurnOrbitTransfer.ts +1 -1
- package/src/maneuver/Waypoint.ts +1 -1
- package/src/objects/BaseObject.ts +171 -0
- package/src/objects/DetailedSatellite.ts +5 -3
- package/src/objects/DetailedSensor.ts +2 -1
- package/src/objects/GroundObject.ts +176 -0
- package/src/objects/LandObject.ts +2 -1
- package/src/objects/Marker.ts +1 -1
- package/src/objects/RfSensor.ts +1 -2
- package/src/objects/Satellite.ts +552 -0
- package/src/objects/Sensor.ts +280 -0
- package/src/objects/Star.ts +96 -0
- package/src/objects/index.ts +5 -0
- package/src/observation/Observation.ts +1 -1
- package/src/observation/ObservationOptical.ts +1 -1
- package/src/observation/ObservationRadar.ts +1 -1
- package/src/observation/ObservationUtils.ts +30 -1
- package/src/observation/RAE.ts +262 -0
- package/src/observation/RadecGeocentric.ts +206 -0
- package/src/observation/RadecTopocentric.ts +241 -0
- package/src/observation/index.ts +27 -0
- package/src/operations/BoxMuller.ts +1 -1
- package/src/operations/EulerAngles.ts +1 -1
- package/src/operations/Matrix.ts +473 -0
- package/src/operations/Quaternion.ts +1 -1
- package/src/operations/Random.ts +54 -0
- package/src/operations/RandomGaussianSource.ts +1 -1
- package/src/operations/Vector.ts +484 -0
- package/src/operations/Vector3D.ts +289 -0
- package/src/operations/operations.ts +27 -0
- package/src/optimize/ChebyshevCompressor.ts +1 -1
- package/src/optimize/PolynomialRegression.ts +1 -1
- package/src/optimize/SimplexEntry.ts +1 -1
- package/src/orbit_determination/BatchLeastSquaresOD.ts +1 -1
- package/src/orbit_determination/BatchLeastSquaresResult.ts +1 -1
- package/src/orbit_determination/GibbsIOD.ts +3 -1
- package/src/orbit_determination/GoodingIOD.ts +1 -1
- package/src/orbit_determination/HerrickGibbsIOD.ts +1 -1
- package/src/orbit_determination/LambertIOD.ts +1 -1
- package/src/orbit_determination/ModifiedGoodingIOD.ts +1 -1
- package/src/orbit_determination/index.ts +7 -0
- package/src/propagator/KeplerPropagator.ts +1 -1
- package/src/propagator/Propagator.ts +1 -1
- package/src/propagator/RkCheckpoint.ts +1 -1
- package/src/propagator/RkResult.ts +1 -1
- package/src/propagator/RungeKutta4Propagator.ts +1 -1
- package/src/propagator/RungeKuttaAdaptive.ts +1 -1
- package/src/propagator/Sgp4Propagator.ts +1 -1
- package/src/sgp4/index.ts +24 -0
- package/src/sgp4/sgp4-error.ts +53 -0
- package/src/sgp4/sgp4.LICENSE.md +28 -0
- package/src/sgp4/sgp4.ts +3986 -0
- package/src/smoothing/ExponentialSmoothing.ts +1 -1
- package/src/time/Epoch.ts +128 -0
- package/src/time/EpochGPS.ts +76 -0
- package/src/time/EpochTAI.ts +27 -0
- package/src/time/EpochTDB.ts +27 -0
- package/src/time/EpochTT.ts +27 -0
- package/src/time/EpochUTC.ts +188 -0
- package/src/time/EpochWindow.ts +33 -0
- package/src/time/TimeStamped.ts +50 -0
- package/src/time/index.ts +31 -0
- package/src/transforms/TransformCache.ts +46 -0
- package/src/transforms/conversions.ts +98 -0
- package/src/transforms/index.ts +1 -0
- package/src/transforms/transforms.ts +478 -2
- package/src/types/types.ts +721 -2
- package/src/utils/constants.ts +113 -0
- package/src/utils/functions.ts +562 -0
- package/src/utils/index.ts +3 -1
- package/src/utils/jacobian.ts +1 -1
- package/src/utils/linearDistance.ts +11 -0
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author Theodore Kruczek.
|
|
3
|
+
* @license MIT
|
|
4
|
+
* @copyright (c) 2022-2025 Theodore Kruczek Permission is
|
|
5
|
+
* hereby granted, free of charge, to any person obtaining a copy of this
|
|
6
|
+
* software and associated documentation files (the "Software"), to deal in the
|
|
7
|
+
* Software without restriction, including without limitation the rights to use,
|
|
8
|
+
* copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
9
|
+
* the Software, and to permit persons to whom the Software is furnished to do
|
|
10
|
+
* so, subject to the following conditions:
|
|
11
|
+
*
|
|
12
|
+
* The above copyright notice and this permission notice shall be included in
|
|
13
|
+
* all copies or substantial portions of the Software.
|
|
14
|
+
*
|
|
15
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
* SOFTWARE.
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
import { AzEl, Degrees, Kilometers, RAD2DEG, RaDec, Radians, Sun } from '../main.js';
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Celestial is a static class that provides methods for calculating the position of celestial objects such as the Sun,
|
|
28
|
+
* Moon, and planets in the sky.
|
|
29
|
+
*/
|
|
30
|
+
export class Celestial {
|
|
31
|
+
private constructor() {
|
|
32
|
+
// disable constructor
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/**
|
|
36
|
+
* Calculates the azimuth and elevation of a celestial object at a given date, latitude,
|
|
37
|
+
* longitude, right ascension, and declination.
|
|
38
|
+
* @param date - The date for which to calculate the azimuth and elevation.
|
|
39
|
+
* @param lat - The latitude of the observer.
|
|
40
|
+
* @param lon - The longitude of the observer.
|
|
41
|
+
* @param ra - The right ascension of the celestial object.
|
|
42
|
+
* @param dec - The declination of the celestial object.
|
|
43
|
+
* @returns An object containing the azimuth and elevation in degrees.
|
|
44
|
+
*/
|
|
45
|
+
static azEl(date: Date, lat: Degrees, lon: Degrees, ra: Radians, dec: Radians): AzEl<Degrees> {
|
|
46
|
+
const c: RaDec = {
|
|
47
|
+
ra,
|
|
48
|
+
dec,
|
|
49
|
+
dist: 0 as Kilometers,
|
|
50
|
+
};
|
|
51
|
+
const azEl = Sun.azEl(date, lat, lon, c);
|
|
52
|
+
|
|
53
|
+
const el = <Radians>(azEl.el + Celestial.atmosphericRefraction(azEl.el)); // elevation correction for refraction
|
|
54
|
+
|
|
55
|
+
return {
|
|
56
|
+
az: (azEl.az * RAD2DEG) as Degrees,
|
|
57
|
+
el: (el * RAD2DEG) as Degrees,
|
|
58
|
+
};
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* Atmospheric refraction in astronomy, refers to the bending of light as it passes through the Earth's
|
|
63
|
+
* atmosphere. This effect is most noticeable for celestial objects like stars and planets when they are
|
|
64
|
+
* close to the horizon. Here's a breakdown of how it works:
|
|
65
|
+
*
|
|
66
|
+
* Actual Position: Due to this bending of light, the apparent position of a celestial object is slightly
|
|
67
|
+
* different from its true position in the sky. When a star or planet is near the horizon, the effect is more
|
|
68
|
+
* pronounced because the light path passes through more of the Earth's atmosphere, which increases the amount of
|
|
69
|
+
* bending.
|
|
70
|
+
*
|
|
71
|
+
* A familiar example of atmospheric refraction is observed during sunrise and sunset. The Sun appears to
|
|
72
|
+
* be above the horizon when it is actually just below it. This is because the light from the Sun is bent
|
|
73
|
+
* upwards as it passes through the atmosphere.
|
|
74
|
+
* @param h - elevation
|
|
75
|
+
* @returns refraction
|
|
76
|
+
*/
|
|
77
|
+
static atmosphericRefraction(h: Radians): Radians {
|
|
78
|
+
if (h < 0) {
|
|
79
|
+
h = <Radians>0;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return <Radians>(0.0002967 / Math.tan(h + 0.00312536 / (h + 0.08901179)));
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Calculate the declination. Similar to latitude on Earth, declination is another celestial coordinate.
|
|
87
|
+
* It measures how far north or south an object is from the celestial equator
|
|
88
|
+
* @param l - ecliptic longitude
|
|
89
|
+
* @param b - ecliptic latitude
|
|
90
|
+
* @returns declination
|
|
91
|
+
*/
|
|
92
|
+
static declination(l: number, b: number): Radians {
|
|
93
|
+
return <Radians>Math.asin(Math.sin(b) * Math.cos(Sun.e) + Math.cos(b) * Math.sin(Sun.e) * Math.sin(l));
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
/**
|
|
97
|
+
* Calculate the right ascension. This is a celestial coordinate used to determine the position of objects
|
|
98
|
+
* in the sky. It's analogous to longitude on Earth. Right Ascension indicates how far east an object is
|
|
99
|
+
* from the vernal equinox along the celestial equator.
|
|
100
|
+
* @param l - ecliptic longitude
|
|
101
|
+
* @param b - ecliptic latitude
|
|
102
|
+
* @returns right ascension
|
|
103
|
+
*/
|
|
104
|
+
static rightAscension(l: number, b: number): Radians {
|
|
105
|
+
return <Radians>Math.atan2(Math.sin(l) * Math.cos(Sun.e) - Math.tan(b) * Math.sin(Sun.e), Math.cos(l));
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* Calculate the elevation. Elevation, or altitude, is the angle between an object in the sky and the
|
|
110
|
+
* observer's local horizon. It's commonly expressed in degrees, where 0 degrees is right at the horizon
|
|
111
|
+
* and 90 degrees is directly overhead (the zenith), but we are using radians to support trigonometric
|
|
112
|
+
* functions like Math.sin() and Math.cos().
|
|
113
|
+
* @param H - siderealTime
|
|
114
|
+
* @param phi - latitude
|
|
115
|
+
* @param dec - The declination of the sun
|
|
116
|
+
* @returns elevation
|
|
117
|
+
*/
|
|
118
|
+
static elevation(H: number, phi: Radians, dec: Radians): Radians {
|
|
119
|
+
return <Radians>Math.asin(Math.sin(phi) * Math.sin(dec) + Math.cos(phi) * Math.cos(dec) * Math.cos(H));
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* Calculate the azimuth. This is a compass direction measurement. Azimuth measures the angle along
|
|
124
|
+
* the horizon from a specific reference direction (usually true north) to the point where a vertical
|
|
125
|
+
* line from the object intersects the horizon.
|
|
126
|
+
* @param H - siderealTime
|
|
127
|
+
* @param phi - latitude
|
|
128
|
+
* @param dec - The declination of the sun
|
|
129
|
+
* @returns azimuth in rad
|
|
130
|
+
*/
|
|
131
|
+
static azimuth(H: number, phi: Radians, dec: Radians): Radians {
|
|
132
|
+
return <Radians>(Math.PI + Math.atan2(Math.sin(H), Math.cos(H) * Math.sin(phi) - Math.tan(dec) * Math.cos(phi)));
|
|
133
|
+
}
|
|
134
|
+
}
|
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author Theodore Kruczek.
|
|
3
|
+
* @license MIT
|
|
4
|
+
* @copyright (c) 2022-2025 Theodore Kruczek Permission is
|
|
5
|
+
* hereby granted, free of charge, to any person obtaining a copy of this
|
|
6
|
+
* software and associated documentation files (the "Software"), to deal in the
|
|
7
|
+
* Software without restriction, including without limitation the rights to use,
|
|
8
|
+
* copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
|
9
|
+
* the Software, and to permit persons to whom the Software is furnished to do
|
|
10
|
+
* so, subject to the following conditions:
|
|
11
|
+
*
|
|
12
|
+
* The above copyright notice and this permission notice shall be included in
|
|
13
|
+
* all copies or substantial portions of the Software.
|
|
14
|
+
*
|
|
15
|
+
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
* SOFTWARE.
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
import {
|
|
25
|
+
angularDiameter,
|
|
26
|
+
AngularDiameterMethod,
|
|
27
|
+
asec2rad,
|
|
28
|
+
DataHandler,
|
|
29
|
+
DEG2RAD,
|
|
30
|
+
earthGravityParam,
|
|
31
|
+
EpochUTC,
|
|
32
|
+
evalPoly,
|
|
33
|
+
Kilometers,
|
|
34
|
+
RAD2DEG,
|
|
35
|
+
Radians,
|
|
36
|
+
RadiansPerSecond,
|
|
37
|
+
secondsPerDay,
|
|
38
|
+
secondsPerSiderealDay,
|
|
39
|
+
TAU,
|
|
40
|
+
ttasec2rad,
|
|
41
|
+
Vector3D,
|
|
42
|
+
} from '../main.js';
|
|
43
|
+
import { NutationAngles } from './NutationAngles.js';
|
|
44
|
+
import { PrecessionAngles } from './PrecessionAngles.js';
|
|
45
|
+
|
|
46
|
+
// / Earth metrics and operations.
|
|
47
|
+
export class Earth {
|
|
48
|
+
private constructor() {
|
|
49
|
+
// disable constructor
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
// / Earth gravitational parameter _(km²/s³)_.
|
|
53
|
+
static readonly mu: number = earthGravityParam;
|
|
54
|
+
|
|
55
|
+
// / Earth equatorial radius.
|
|
56
|
+
static readonly radiusEquator = 6378.1363 as Kilometers;
|
|
57
|
+
|
|
58
|
+
// / Earth coefficient of flattening _(unitless)_.
|
|
59
|
+
static readonly flattening: number = 1.0 / 298.257223563;
|
|
60
|
+
|
|
61
|
+
// / Earth polar radius.
|
|
62
|
+
static readonly radiusPolar = (Earth.radiusEquator * (1.0 - Earth.flattening)) as Kilometers;
|
|
63
|
+
|
|
64
|
+
// / Earth mean radius.
|
|
65
|
+
static readonly radiusMean = ((2.0 * Earth.radiusEquator + Earth.radiusPolar) / 3.0) as Kilometers;
|
|
66
|
+
|
|
67
|
+
// / Earth eccentricity squared _(unitless)_.
|
|
68
|
+
static readonly eccentricitySquared: number = Earth.flattening * (2.0 - Earth.flattening);
|
|
69
|
+
|
|
70
|
+
// / Earth J2 effect coefficient _(unitless)_.
|
|
71
|
+
static readonly j2: number = 1.08262668355315e-3;
|
|
72
|
+
|
|
73
|
+
// / Earth J3 effect coefficient _(unitless)_.
|
|
74
|
+
static readonly j3: number = -2.53265648533224e-6;
|
|
75
|
+
|
|
76
|
+
// / Earth J4 effect coefficient _(unitless)_.
|
|
77
|
+
static readonly j4: number = -1.619621591367e-6;
|
|
78
|
+
|
|
79
|
+
// / Earth J5 effect coefficient _(unitless)_.
|
|
80
|
+
static readonly j5: number = -2.27296082868698e-7;
|
|
81
|
+
|
|
82
|
+
// / Earth J6 effect coefficient _(unitless)_.
|
|
83
|
+
static readonly j6: number = 5.40681239107085e-7;
|
|
84
|
+
|
|
85
|
+
// / Earth rotation vector _(rad/s)_.
|
|
86
|
+
static readonly rotation = new Vector3D<RadiansPerSecond>(
|
|
87
|
+
0 as RadiansPerSecond,
|
|
88
|
+
0 as RadiansPerSecond,
|
|
89
|
+
7.292115146706979e-5 as RadiansPerSecond,
|
|
90
|
+
);
|
|
91
|
+
|
|
92
|
+
// / Calculate mean motion _(rad/s)_ from a given [semimajorAxis] _(km)_.
|
|
93
|
+
static smaToMeanMotion(semimajorAxis: Kilometers): RadiansPerSecond {
|
|
94
|
+
return Math.sqrt(Earth.mu / (semimajorAxis * semimajorAxis * semimajorAxis)) as RadiansPerSecond;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Converts revolutions per day to semi-major axis.
|
|
99
|
+
* @param rpd - The number of revolutions per day.
|
|
100
|
+
* @returns The semi-major axis value.
|
|
101
|
+
*/
|
|
102
|
+
static revsPerDayToSma(rpd: number): number {
|
|
103
|
+
return Earth.mu ** (1 / 3) / ((TAU * rpd) / secondsPerDay) ** (2 / 3);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
// / Calculate Earth [PrecessionAngles] at a given UTC [epoch].
|
|
107
|
+
static precession(epoch: EpochUTC): PrecessionAngles {
|
|
108
|
+
const t = epoch.toTT().toJulianCenturies();
|
|
109
|
+
const zeta = evalPoly(t, Earth.zetaPoly_);
|
|
110
|
+
const theta = evalPoly(t, Earth.thetaPoly_);
|
|
111
|
+
const zed = evalPoly(t, Earth.zedPoly_);
|
|
112
|
+
|
|
113
|
+
return { zeta: zeta as Radians, theta: theta as Radians, zed: zed as Radians };
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
// / Calculate Earth [NutationAngles] for a given UTC [epoch].
|
|
117
|
+
static nutation(epoch: EpochUTC): NutationAngles {
|
|
118
|
+
const t = epoch.toTT().toJulianCenturies();
|
|
119
|
+
const moonAnom = evalPoly(t, Earth.moonAnomPoly_);
|
|
120
|
+
const sunAnom = evalPoly(t, Earth.sunAnomPoly_);
|
|
121
|
+
const moonLat = evalPoly(t, Earth.moonLatPoly_);
|
|
122
|
+
const sunElong = evalPoly(t, Earth.sunElongPoly_);
|
|
123
|
+
const moonRaan = evalPoly(t, Earth.moonRaanPoly_);
|
|
124
|
+
let deltaPsi = 0.0;
|
|
125
|
+
let deltaEpsilon = 0.0;
|
|
126
|
+
const dh = DataHandler.getInstance();
|
|
127
|
+
|
|
128
|
+
for (let i = 0; i < 4; i++) {
|
|
129
|
+
const [a1, a2, a3, a4, a5, ai, bi, ci, di] = dh.getIau1980Coeffs(i);
|
|
130
|
+
const arg = a1 * moonAnom + a2 * sunAnom + a3 * moonLat + a4 * sunElong + a5 * moonRaan;
|
|
131
|
+
const sinC = ai + bi * t;
|
|
132
|
+
const cosC = ci + di * t;
|
|
133
|
+
|
|
134
|
+
deltaPsi += sinC * Math.sin(arg);
|
|
135
|
+
deltaEpsilon += cosC * Math.cos(arg);
|
|
136
|
+
}
|
|
137
|
+
deltaPsi *= ttasec2rad;
|
|
138
|
+
deltaEpsilon *= ttasec2rad;
|
|
139
|
+
const meanEpsilon = evalPoly(t, Earth.meanEpsilonPoly_);
|
|
140
|
+
const epsilon = meanEpsilon + deltaEpsilon;
|
|
141
|
+
const eqEq =
|
|
142
|
+
deltaPsi * Math.cos(meanEpsilon) +
|
|
143
|
+
0.00264 * asec2rad * Math.sin(moonRaan) +
|
|
144
|
+
0.000063 * asec2rad * Math.sin(2.0 * moonRaan);
|
|
145
|
+
const gast = epoch.gmstAngle() + eqEq;
|
|
146
|
+
|
|
147
|
+
return {
|
|
148
|
+
dPsi: deltaPsi as Radians,
|
|
149
|
+
dEps: deltaEpsilon as Radians,
|
|
150
|
+
mEps: meanEpsilon as Radians,
|
|
151
|
+
eps: epsilon as Radians,
|
|
152
|
+
eqEq: eqEq as Radians,
|
|
153
|
+
gast: gast as Radians,
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
// / Convert a [semimajorAxis] _(km)_ to an eastward drift rate _(rad/day)_.
|
|
158
|
+
static smaToDrift(semimajorAxis: number): number {
|
|
159
|
+
const t = (TAU * Math.sqrt(semimajorAxis ** 3 / Earth.mu)) / secondsPerSiderealDay;
|
|
160
|
+
|
|
161
|
+
return (1.0 - t) * TAU;
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
// / Convert a [semimajorAxis] _(km)_ to an eastward drift rate _(°/day)_.
|
|
165
|
+
static smaToDriftDegrees(semimajorAxis: number): number {
|
|
166
|
+
return Earth.smaToDrift(semimajorAxis) * RAD2DEG;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
// / Convert an eastward [driftRate] _(rad/day)_ to a semimajor-axis _(km)_.
|
|
170
|
+
static driftToSemimajorAxis(driftRate: number): number {
|
|
171
|
+
const t = (-driftRate / TAU + 1) * secondsPerSiderealDay;
|
|
172
|
+
|
|
173
|
+
return ((Earth.mu * t * t) / (4 * Math.PI * Math.PI)) ** (1 / 3);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
// / Convert an eastward [driftRate] _(°/day)_ to a semimajor-axis _(km)_.
|
|
177
|
+
static driftDegreesToSma(driftRate: number): number {
|
|
178
|
+
return Earth.driftToSemimajorAxis(DEG2RAD * driftRate);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Calculates the diameter of the Earth based on the satellite position.
|
|
183
|
+
* @param satPos The position of the satellite.
|
|
184
|
+
* @returns The diameter of the Earth.
|
|
185
|
+
*/
|
|
186
|
+
static diameter(satPos: Vector3D): number {
|
|
187
|
+
return angularDiameter(Earth.radiusEquator * 2, satPos.magnitude(), AngularDiameterMethod.Sphere);
|
|
188
|
+
}
|
|
189
|
+
|
|
190
|
+
// / Earth precession `zeta` polynomial coefficients.
|
|
191
|
+
private static readonly zetaPoly_: Float64Array = Float64Array.from([
|
|
192
|
+
0.017998 * asec2rad,
|
|
193
|
+
0.30188 * asec2rad,
|
|
194
|
+
2306.2181 * asec2rad,
|
|
195
|
+
0.0,
|
|
196
|
+
]);
|
|
197
|
+
|
|
198
|
+
// / Earth precession `theta` polynomial coefficients.
|
|
199
|
+
private static readonly thetaPoly_: Float64Array = Float64Array.from([
|
|
200
|
+
-0.041833 * asec2rad,
|
|
201
|
+
-0.42665 * asec2rad,
|
|
202
|
+
2004.3109 * asec2rad,
|
|
203
|
+
0.0,
|
|
204
|
+
]);
|
|
205
|
+
|
|
206
|
+
// / Earth precession `zed` polynomial coefficients.
|
|
207
|
+
private static readonly zedPoly_: Float64Array = Float64Array.from([
|
|
208
|
+
0.018203 * asec2rad,
|
|
209
|
+
1.09468 * asec2rad,
|
|
210
|
+
2306.2181 * asec2rad,
|
|
211
|
+
0,
|
|
212
|
+
]);
|
|
213
|
+
|
|
214
|
+
private static readonly moonAnomPoly_: Float64Array = Float64Array.from([
|
|
215
|
+
1.4343e-5 * DEG2RAD,
|
|
216
|
+
0.0088553 * DEG2RAD,
|
|
217
|
+
(1325.0 * 360.0 + 198.8675605) * DEG2RAD,
|
|
218
|
+
134.96340251 * DEG2RAD,
|
|
219
|
+
]);
|
|
220
|
+
|
|
221
|
+
// / Earth nutation Sun anomaly polynomial coefficients.
|
|
222
|
+
private static readonly sunAnomPoly_: Float64Array = Float64Array.from([
|
|
223
|
+
3.8e-8 * DEG2RAD,
|
|
224
|
+
-0.0001537 * DEG2RAD,
|
|
225
|
+
(99.0 * 360.0 + 359.0502911) * DEG2RAD,
|
|
226
|
+
357.52910918 * DEG2RAD,
|
|
227
|
+
]);
|
|
228
|
+
|
|
229
|
+
// / Earth nutation Moon latitude polynomial coefficients.
|
|
230
|
+
private static readonly moonLatPoly_: Float64Array = Float64Array.from([
|
|
231
|
+
-2.88e-7 * DEG2RAD,
|
|
232
|
+
-0.003542 * DEG2RAD,
|
|
233
|
+
(1342.0 * 360.0 + 82.0174577) * DEG2RAD,
|
|
234
|
+
93.27209062 * DEG2RAD,
|
|
235
|
+
]);
|
|
236
|
+
|
|
237
|
+
// / Earth nutation Sun elongation polynomial coefficients.
|
|
238
|
+
private static readonly sunElongPoly_: Float64Array = Float64Array.from([
|
|
239
|
+
1.831e-6 * DEG2RAD,
|
|
240
|
+
-0.0017696 * DEG2RAD,
|
|
241
|
+
(1236.0 * 360.0 + 307.1114469) * DEG2RAD,
|
|
242
|
+
297.85019547 * DEG2RAD,
|
|
243
|
+
]);
|
|
244
|
+
|
|
245
|
+
// / Earth nutation Moon right-ascension polynomial coefficients.
|
|
246
|
+
private static readonly moonRaanPoly_: Float64Array = Float64Array.from([
|
|
247
|
+
2.139e-6 * DEG2RAD,
|
|
248
|
+
0.0020756 * DEG2RAD,
|
|
249
|
+
-(5.0 * 360.0 + 134.1361851) * DEG2RAD,
|
|
250
|
+
125.04455501 * DEG2RAD,
|
|
251
|
+
]);
|
|
252
|
+
|
|
253
|
+
// / Earth nutation mean epsilon polynomial coefficients.
|
|
254
|
+
private static readonly meanEpsilonPoly_: Float64Array = Float64Array.from([
|
|
255
|
+
0.001813 * asec2rad,
|
|
256
|
+
-0.00059 * asec2rad,
|
|
257
|
+
-46.815 * asec2rad,
|
|
258
|
+
84381.448 * asec2rad,
|
|
259
|
+
]);
|
|
260
|
+
}
|