ootk 4.0.0-0 → 4.0.0-2
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 +142 -31
- package/{lib → dist}/coordinate/Hill.d.ts +17 -18
- package/{lib → dist}/coordinate/Hill.js +44 -36
- package/dist/coordinate/Hill.js.map +1 -0
- package/{lib → dist}/covariance/CovarianceSample.d.ts +6 -7
- package/{lib → dist}/covariance/CovarianceSample.js +29 -28
- package/dist/covariance/CovarianceSample.js.map +1 -0
- package/{lib → dist}/covariance/StateCovariance.d.ts +4 -3
- package/{lib → dist}/covariance/StateCovariance.js +8 -5
- package/dist/covariance/StateCovariance.js.map +1 -0
- package/{lib → dist}/force/AtmosphericDrag.d.ts +1 -2
- package/{lib → dist}/force/AtmosphericDrag.js +13 -6
- package/dist/force/AtmosphericDrag.js.map +1 -0
- package/{lib → dist}/force/EarthGravity.d.ts +1 -2
- package/{lib → dist}/force/EarthGravity.js +4 -2
- package/dist/force/EarthGravity.js.map +1 -0
- package/{lib → dist}/force/Force.d.ts +3 -2
- package/{lib → dist}/force/Force.js +3 -2
- package/dist/force/Force.js.map +1 -0
- package/{lib → dist}/force/ForceModel.d.ts +4 -5
- package/{lib → dist}/force/ForceModel.js +6 -2
- package/dist/force/ForceModel.js.map +1 -0
- package/{lib → dist}/force/Gravity.d.ts +1 -4
- package/{lib → dist}/force/Gravity.js +3 -4
- package/dist/force/Gravity.js.map +1 -0
- package/{lib → dist}/force/SolarRadiationPressure.d.ts +1 -2
- package/{lib → dist}/force/SolarRadiationPressure.js +6 -4
- package/dist/force/SolarRadiationPressure.js.map +1 -0
- package/{lib → dist}/force/ThirdBodyGravity.d.ts +1 -2
- package/{lib → dist}/force/ThirdBodyGravity.js +4 -3
- package/dist/force/ThirdBodyGravity.js.map +1 -0
- package/{lib → dist}/force/Thrust.d.ts +10 -11
- package/{lib → dist}/force/Thrust.js +8 -3
- package/dist/force/Thrust.js.map +1 -0
- package/dist/interfaces/RfSensorParams.d.ts +28 -0
- package/dist/interfaces/RfSensorParams.js +24 -0
- package/dist/interfaces/RfSensorParams.js.map +1 -0
- package/dist/interfaces/index.d.ts +1 -0
- package/dist/interfaces/index.js +2 -0
- package/dist/interfaces/index.js.map +1 -0
- package/{lib → dist}/interpolator/ChebyshevCoefficients.d.ts +11 -15
- package/{lib → dist}/interpolator/ChebyshevCoefficients.js +19 -15
- package/dist/interpolator/ChebyshevCoefficients.js.map +1 -0
- package/{lib → dist}/interpolator/ChebyshevInterpolator.d.ts +1 -2
- package/{lib → dist}/interpolator/ChebyshevInterpolator.js +2 -2
- package/dist/interpolator/ChebyshevInterpolator.js.map +1 -0
- package/{lib → dist}/interpolator/CubicSpline.d.ts +8 -9
- package/{lib → dist}/interpolator/CubicSpline.js +10 -5
- package/dist/interpolator/CubicSpline.js.map +1 -0
- package/{lib → dist}/interpolator/CubicSplineInterpolator.d.ts +2 -3
- package/{lib → dist}/interpolator/CubicSplineInterpolator.js +6 -4
- package/dist/interpolator/CubicSplineInterpolator.js.map +1 -0
- package/{lib → dist}/interpolator/FieldInterpolator.d.ts +7 -5
- package/{lib → dist}/interpolator/FieldInterpolator.js +6 -3
- package/dist/interpolator/FieldInterpolator.js.map +1 -0
- package/{lib → dist}/interpolator/Interpolator.d.ts +1 -2
- package/{lib → dist}/interpolator/Interpolator.js +1 -2
- package/dist/interpolator/Interpolator.js.map +1 -0
- package/{lib → dist}/interpolator/LagrangeInterpolator.d.ts +8 -10
- package/{lib → dist}/interpolator/LagrangeInterpolator.js +32 -29
- package/dist/interpolator/LagrangeInterpolator.js.map +1 -0
- package/{lib → dist}/interpolator/StateInterpolator.d.ts +2 -4
- package/{lib → dist}/interpolator/StateInterpolator.js +2 -4
- package/dist/interpolator/StateInterpolator.js.map +1 -0
- package/{lib → dist}/interpolator/VerletBlendInterpolator.d.ts +4 -5
- package/{lib → dist}/interpolator/VerletBlendInterpolator.js +16 -13
- package/dist/interpolator/VerletBlendInterpolator.js.map +1 -0
- package/{lib/ootk.d.ts → dist/main.d.ts} +4 -2
- package/dist/main.js +32 -0
- package/dist/main.js.map +1 -0
- package/{lib → dist}/maneuver/TwoBurnOrbitTransfer.d.ts +5 -7
- package/{lib → dist}/maneuver/TwoBurnOrbitTransfer.js +6 -3
- package/dist/maneuver/TwoBurnOrbitTransfer.js.map +1 -0
- package/{lib → dist}/maneuver/Waypoint.d.ts +30 -5
- package/{lib → dist}/maneuver/Waypoint.js +31 -4
- package/dist/maneuver/Waypoint.js.map +1 -0
- package/{lib → dist}/objects/DetailedSatellite.d.ts +7 -31
- package/{lib → dist}/objects/DetailedSatellite.js +68 -72
- package/dist/objects/DetailedSatellite.js.map +1 -0
- package/{lib → dist}/objects/DetailedSensor.d.ts +1 -2
- package/{lib → dist}/objects/DetailedSensor.js +22 -2
- package/dist/objects/DetailedSensor.js.map +1 -0
- package/{lib → dist}/objects/LandObject.d.ts +3 -6
- package/{lib → dist}/objects/LandObject.js +9 -3
- package/dist/objects/LandObject.js.map +1 -0
- package/{lib → dist}/objects/Marker.d.ts +1 -2
- package/{lib → dist}/objects/Marker.js +1 -2
- package/dist/objects/Marker.js.map +1 -0
- package/dist/objects/RfSensor.d.ts +41 -0
- package/dist/objects/RfSensor.js +67 -0
- package/dist/objects/RfSensor.js.map +1 -0
- package/{lib → dist}/objects/index.d.ts +1 -1
- package/{lib → dist}/objects/index.js +1 -1
- package/dist/objects/index.js.map +1 -0
- package/{lib → dist}/observation/Observation.d.ts +42 -4
- package/{lib → dist}/observation/Observation.js +41 -10
- package/dist/observation/Observation.js.map +1 -0
- package/{lib → dist}/observation/ObservationOptical.d.ts +7 -6
- package/{lib → dist}/observation/ObservationOptical.js +19 -15
- package/dist/observation/ObservationOptical.js.map +1 -0
- package/{lib → dist}/observation/ObservationRadar.d.ts +7 -4
- package/{lib → dist}/observation/ObservationRadar.js +25 -19
- package/dist/observation/ObservationRadar.js.map +1 -0
- package/{lib → dist}/observation/ObservationUtils.d.ts +1 -2
- package/{lib → dist}/observation/ObservationUtils.js +1 -2
- package/dist/observation/ObservationUtils.js.map +1 -0
- package/{lib → dist}/observation/PropagatorPairs.d.ts +3 -2
- package/{lib → dist}/observation/PropagatorPairs.js +7 -4
- package/dist/observation/PropagatorPairs.js.map +1 -0
- package/{lib → dist}/operations/BoxMuller.d.ts +7 -2
- package/{lib → dist}/operations/BoxMuller.js +15 -4
- package/dist/operations/BoxMuller.js.map +1 -0
- package/dist/operations/EulerAngles.d.ts +105 -0
- package/{lib → dist}/operations/EulerAngles.js +72 -22
- package/dist/operations/EulerAngles.js.map +1 -0
- package/{lib → dist}/operations/Quaternion.d.ts +5 -6
- package/{lib → dist}/operations/Quaternion.js +12 -9
- package/dist/operations/Quaternion.js.map +1 -0
- package/{lib → dist}/operations/RandomGaussianSource.d.ts +1 -2
- package/{lib → dist}/operations/RandomGaussianSource.js +3 -3
- package/dist/operations/RandomGaussianSource.js.map +1 -0
- package/{lib → dist}/optimize/ChebyshevCompressor.d.ts +3 -2
- package/{lib → dist}/optimize/ChebyshevCompressor.js +7 -4
- package/dist/optimize/ChebyshevCompressor.js.map +1 -0
- package/{lib → dist}/optimize/DownhillSimplex.d.ts +16 -2
- package/{lib → dist}/optimize/DownhillSimplex.js +16 -2
- package/dist/optimize/DownhillSimplex.js.map +1 -0
- package/{lib → dist}/optimize/GoldenSection.d.ts +9 -3
- package/{lib → dist}/optimize/GoldenSection.js +9 -3
- package/dist/optimize/GoldenSection.js.map +1 -0
- package/{lib → dist}/optimize/PolynomialRegression.d.ts +14 -2
- package/{lib → dist}/optimize/PolynomialRegression.js +19 -2
- package/dist/optimize/PolynomialRegression.js.map +1 -0
- package/{lib → dist}/optimize/PolynomicalRegressionResult.d.ts +5 -2
- package/{lib → dist}/optimize/PolynomicalRegressionResult.js +8 -2
- package/dist/optimize/PolynomicalRegressionResult.js.map +1 -0
- package/{lib → dist}/optimize/SimpleLinearRegression.d.ts +5 -2
- package/{lib → dist}/optimize/SimpleLinearRegression.js +12 -7
- package/dist/optimize/SimpleLinearRegression.js.map +1 -0
- package/{lib → dist}/optimize/SimplexEntry.d.ts +1 -2
- package/{lib → dist}/optimize/SimplexEntry.js +5 -2
- package/dist/optimize/SimplexEntry.js.map +1 -0
- package/{lib → dist}/orbit_determination/BatchLeastSquaresOD.d.ts +14 -3
- package/{lib → dist}/orbit_determination/BatchLeastSquaresOD.js +29 -4
- package/dist/orbit_determination/BatchLeastSquaresOD.js.map +1 -0
- package/{lib → dist}/orbit_determination/BatchLeastSquaresResult.d.ts +4 -2
- package/{lib → dist}/orbit_determination/BatchLeastSquaresResult.js +7 -2
- package/dist/orbit_determination/BatchLeastSquaresResult.js.map +1 -0
- package/{lib → dist}/orbit_determination/GibbsIOD.d.ts +9 -4
- package/{lib → dist}/orbit_determination/GibbsIOD.js +11 -5
- package/dist/orbit_determination/GibbsIOD.js.map +1 -0
- package/{lib → dist}/orbit_determination/GoodingIOD.d.ts +21 -22
- package/{lib → dist}/orbit_determination/GoodingIOD.js +74 -71
- package/dist/orbit_determination/GoodingIOD.js.map +1 -0
- package/{lib → dist}/orbit_determination/HerrickGibbsIOD.d.ts +4 -4
- package/{lib → dist}/orbit_determination/HerrickGibbsIOD.js +3 -2
- package/dist/orbit_determination/HerrickGibbsIOD.js.map +1 -0
- package/{lib → dist}/orbit_determination/LambertIOD.d.ts +21 -8
- package/{lib → dist}/orbit_determination/LambertIOD.js +20 -6
- package/dist/orbit_determination/LambertIOD.js.map +1 -0
- package/{lib → dist}/orbit_determination/ModifiedGoodingIOD.d.ts +6 -7
- package/{lib → dist}/orbit_determination/ModifiedGoodingIOD.js +12 -11
- package/dist/orbit_determination/ModifiedGoodingIOD.js.map +1 -0
- package/{lib → dist}/propagator/DormandPrince54Propagator.d.ts +1 -2
- package/dist/propagator/DormandPrince54Propagator.js +64 -0
- package/dist/propagator/DormandPrince54Propagator.js.map +1 -0
- package/{lib → dist}/propagator/KeplerPropagator.d.ts +1 -2
- package/{lib → dist}/propagator/KeplerPropagator.js +5 -2
- package/{lib → dist}/propagator/KeplerPropagator.js.map +1 -1
- package/{lib → dist}/propagator/Propagator.d.ts +5 -6
- package/{lib → dist}/propagator/Propagator.js +5 -6
- package/dist/propagator/Propagator.js.map +1 -0
- package/{lib → dist}/propagator/RkCheckpoint.d.ts +1 -2
- package/{lib → dist}/propagator/RkCheckpoint.js +3 -2
- package/dist/propagator/RkCheckpoint.js.map +1 -0
- package/{lib → dist}/propagator/RkResult.d.ts +1 -2
- package/{lib → dist}/propagator/RkResult.js +4 -2
- package/dist/propagator/RkResult.js.map +1 -0
- package/{lib → dist}/propagator/RungeKutta4Propagator.d.ts +14 -10
- package/{lib → dist}/propagator/RungeKutta4Propagator.js +45 -36
- package/dist/propagator/RungeKutta4Propagator.js.map +1 -0
- package/{lib → dist}/propagator/RungeKutta89Propagator.d.ts +1 -2
- package/dist/propagator/RungeKutta89Propagator.js +126 -0
- package/dist/propagator/RungeKutta89Propagator.js.map +1 -0
- package/{lib → dist}/propagator/RungeKuttaAdaptive.d.ts +13 -11
- package/{lib → dist}/propagator/RungeKuttaAdaptive.js +31 -24
- package/dist/propagator/RungeKuttaAdaptive.js.map +1 -0
- package/{lib → dist}/propagator/Sgp4Propagator.d.ts +3 -4
- package/{lib → dist}/propagator/Sgp4Propagator.js +4 -3
- package/dist/propagator/Sgp4Propagator.js.map +1 -0
- package/{lib → dist}/smoothing/ExponentialSmoothing.d.ts +1 -2
- package/{lib → dist}/smoothing/ExponentialSmoothing.js +1 -2
- package/dist/smoothing/ExponentialSmoothing.js.map +1 -0
- package/dist/transforms/index.d.ts +1 -0
- package/dist/transforms/index.js +2 -0
- package/dist/transforms/index.js.map +1 -0
- package/dist/transforms/transforms.d.ts +58 -0
- package/dist/transforms/transforms.js +94 -0
- package/dist/transforms/transforms.js.map +1 -0
- package/{lib → dist}/types/types.d.ts +44 -4
- package/{lib → dist}/types/types.js +1 -2
- package/dist/types/types.js.map +1 -0
- package/dist/utils/functions.d.ts +8 -0
- package/dist/utils/functions.js +18 -0
- package/dist/utils/functions.js.map +1 -0
- package/dist/utils/index.d.ts +2 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/jacobian.d.ts +11 -0
- package/dist/utils/jacobian.js +29 -0
- package/dist/utils/jacobian.js.map +1 -0
- package/package.json +32 -42
- package/src/coordinate/Hill.ts +326 -0
- package/src/coordinate/index.ts +1 -0
- package/src/covariance/CovarianceSample.ts +194 -0
- package/src/covariance/StateCovariance.ts +69 -0
- package/src/force/AtmosphericDrag.ts +101 -0
- package/src/force/EarthGravity.ts +157 -0
- package/src/force/Force.ts +33 -0
- package/src/force/ForceModel.ts +91 -0
- package/src/force/Gravity.ts +53 -0
- package/src/force/SolarRadiationPressure.ts +42 -0
- package/src/force/ThirdBodyGravity.ts +62 -0
- package/src/force/Thrust.ts +83 -0
- package/src/interfaces/RfSensorParams.ts +30 -0
- package/src/interfaces/index.ts +1 -0
- package/src/interpolator/ChebyshevCoefficients.ts +109 -0
- package/src/interpolator/ChebyshevInterpolator.ts +87 -0
- package/src/interpolator/CubicSpline.ts +72 -0
- package/src/interpolator/CubicSplineInterpolator.ts +90 -0
- package/src/interpolator/FieldInterpolator.ts +37 -0
- package/src/interpolator/Interpolator.ts +56 -0
- package/src/interpolator/LagrangeInterpolator.ts +192 -0
- package/src/interpolator/StateInterpolator.ts +39 -0
- package/src/interpolator/VerletBlendInterpolator.ts +146 -0
- package/{lib/ootk.js → src/main.ts} +7 -3
- package/src/maneuver/TwoBurnOrbitTransfer.ts +79 -0
- package/src/maneuver/Waypoint.ts +267 -0
- package/src/objects/DetailedSatellite.ts +159 -0
- package/src/objects/DetailedSensor.ts +68 -0
- package/src/objects/LandObject.ts +46 -0
- package/src/objects/Marker.ts +25 -0
- package/src/objects/RfSensor.ts +78 -0
- package/src/objects/index.ts +5 -0
- package/src/observation/Observation.ts +125 -0
- package/src/observation/ObservationOptical.ts +146 -0
- package/src/observation/ObservationRadar.ts +131 -0
- package/src/observation/ObservationUtils.ts +40 -0
- package/src/observation/PropagatorPairs.ts +45 -0
- package/src/operations/BoxMuller.ts +87 -0
- package/src/operations/EulerAngles.ts +183 -0
- package/src/operations/Quaternion.ts +222 -0
- package/src/operations/RandomGaussianSource.ts +51 -0
- package/src/operations/index.ts +4 -0
- package/src/optimize/ChebyshevCompressor.ts +96 -0
- package/src/optimize/DownhillSimplex.ts +212 -0
- package/src/optimize/GoldenSection.ts +71 -0
- package/src/optimize/PolynomialRegression.ts +109 -0
- package/src/optimize/PolynomicalRegressionResult.ts +32 -0
- package/src/optimize/SimpleLinearRegression.ts +127 -0
- package/src/optimize/SimplexEntry.ts +50 -0
- package/src/orbit_determination/BatchLeastSquaresOD.ts +174 -0
- package/src/orbit_determination/BatchLeastSquaresResult.ts +33 -0
- package/src/orbit_determination/GibbsIOD.ts +95 -0
- package/src/orbit_determination/GoodingIOD.ts +380 -0
- package/src/orbit_determination/HerrickGibbsIOD.ts +51 -0
- package/src/orbit_determination/LambertIOD.ts +260 -0
- package/src/orbit_determination/ModifiedGoodingIOD.ts +133 -0
- package/src/propagator/DormandPrince54Propagator.ts +73 -0
- package/src/propagator/KeplerPropagator.ts +102 -0
- package/src/propagator/Propagator.ts +253 -0
- package/src/propagator/RkCheckpoint.ts +25 -0
- package/src/propagator/RkResult.ts +26 -0
- package/src/propagator/RungeKutta4Propagator.ts +179 -0
- package/src/propagator/RungeKutta89Propagator.ts +132 -0
- package/src/propagator/RungeKuttaAdaptive.ts +232 -0
- package/src/propagator/Sgp4Propagator.ts +71 -0
- package/src/smoothing/ExponentialSmoothing.ts +90 -0
- package/src/transforms/index.ts +1 -0
- package/src/transforms/transforms.ts +117 -0
- package/src/types/types.ts +135 -0
- package/src/utils/functions.ts +21 -0
- package/src/utils/index.ts +2 -0
- package/src/utils/jacobian.ts +38 -0
- package/.eslintrc.json +0 -244
- package/jest.config.ts +0 -30
- package/lib/coordinate/Hill.js.map +0 -1
- package/lib/covariance/CovarianceSample.js.map +0 -1
- package/lib/covariance/StateCovariance.js.map +0 -1
- package/lib/force/AtmosphericDrag.js.map +0 -1
- package/lib/force/EarthGravity.js.map +0 -1
- package/lib/force/Force.js.map +0 -1
- package/lib/force/ForceModel.js.map +0 -1
- package/lib/force/Gravity.js.map +0 -1
- package/lib/force/SolarRadiationPressure.js.map +0 -1
- package/lib/force/ThirdBodyGravity.js.map +0 -1
- package/lib/force/Thrust.js.map +0 -1
- package/lib/interpolator/ChebyshevCoefficients.js.map +0 -1
- package/lib/interpolator/ChebyshevInterpolator.js.map +0 -1
- package/lib/interpolator/CubicSpline.js.map +0 -1
- package/lib/interpolator/CubicSplineInterpolator.js.map +0 -1
- package/lib/interpolator/FieldInterpolator.js.map +0 -1
- package/lib/interpolator/Interpolator.js.map +0 -1
- package/lib/interpolator/LagrangeInterpolator.js.map +0 -1
- package/lib/interpolator/StateInterpolator.js.map +0 -1
- package/lib/interpolator/VerletBlendInterpolator.js.map +0 -1
- package/lib/maneuver/TwoBurnOrbitTransfer.js.map +0 -1
- package/lib/maneuver/Waypoint.js.map +0 -1
- package/lib/objects/DetailedSatellite.js.map +0 -1
- package/lib/objects/DetailedSensor.js.map +0 -1
- package/lib/objects/LandObject.js.map +0 -1
- package/lib/objects/Marker.js.map +0 -1
- package/lib/objects/index.js.map +0 -1
- package/lib/observation/Observation.js.map +0 -1
- package/lib/observation/ObservationOptical.js.map +0 -1
- package/lib/observation/ObservationRadar.js.map +0 -1
- package/lib/observation/ObservationUtils.js.map +0 -1
- package/lib/observation/PropagatorPairs.js.map +0 -1
- package/lib/ootk.js.map +0 -1
- package/lib/operations/BoxMuller.js.map +0 -1
- package/lib/operations/EulerAngles.d.ts +0 -50
- package/lib/operations/EulerAngles.js.map +0 -1
- package/lib/operations/Quaternion.js.map +0 -1
- package/lib/operations/RandomGaussianSource.js.map +0 -1
- package/lib/optimize/ChebyshevCompressor.js.map +0 -1
- package/lib/optimize/DownhillSimplex.js.map +0 -1
- package/lib/optimize/GoldenSection.js.map +0 -1
- package/lib/optimize/PolynomialRegression.js.map +0 -1
- package/lib/optimize/PolynomicalRegressionResult.js.map +0 -1
- package/lib/optimize/SimpleLinearRegression.js.map +0 -1
- package/lib/optimize/SimplexEntry.js.map +0 -1
- package/lib/orbit_determination/BatchLeastSquaresOD.js.map +0 -1
- package/lib/orbit_determination/BatchLeastSquaresResult.js.map +0 -1
- package/lib/orbit_determination/GibbsIOD.js.map +0 -1
- package/lib/orbit_determination/GoodingIOD.js.map +0 -1
- package/lib/orbit_determination/HerrickGibbsIOD.js.map +0 -1
- package/lib/orbit_determination/LambertIOD.js.map +0 -1
- package/lib/orbit_determination/ModifiedGoodingIOD.js.map +0 -1
- package/lib/propagator/DormandPrince54Propagator.js +0 -68
- package/lib/propagator/DormandPrince54Propagator.js.map +0 -1
- package/lib/propagator/Propagator.js.map +0 -1
- package/lib/propagator/RkCheckpoint.js.map +0 -1
- package/lib/propagator/RkResult.js.map +0 -1
- package/lib/propagator/RungeKutta4Propagator.js.map +0 -1
- package/lib/propagator/RungeKutta89Propagator.js +0 -130
- package/lib/propagator/RungeKutta89Propagator.js.map +0 -1
- package/lib/propagator/RungeKuttaAdaptive.js.map +0 -1
- package/lib/propagator/Sgp4Propagator.js.map +0 -1
- package/lib/smoothing/ExponentialSmoothing.js.map +0 -1
- package/lib/types/types.js.map +0 -1
- /package/{lib → dist}/coordinate/index.d.ts +0 -0
- /package/{lib → dist}/coordinate/index.js +0 -0
- /package/{lib → dist}/coordinate/index.js.map +0 -0
- /package/{lib → dist}/operations/index.d.ts +0 -0
- /package/{lib → dist}/operations/index.js +0 -0
- /package/{lib → dist}/operations/index.js.map +0 -0
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { BaseObjectParams, Degrees, Milliseconds, Radians, Sensor, SensorParams } from 'ootk-core';
|
|
19
|
+
import { DetailedSensorParams, ZoomValue } from '../types/types';
|
|
20
|
+
|
|
21
|
+
export class DetailedSensor extends Sensor {
|
|
22
|
+
country?: string;
|
|
23
|
+
latRad: Radians;
|
|
24
|
+
lonRad: Radians;
|
|
25
|
+
shortName?: string;
|
|
26
|
+
beamwidth?: Degrees;
|
|
27
|
+
changeObjectInterval?: Milliseconds;
|
|
28
|
+
linkAehf?: boolean;
|
|
29
|
+
linkGalileo?: boolean;
|
|
30
|
+
linkIridium?: boolean;
|
|
31
|
+
linkStarlink?: boolean;
|
|
32
|
+
linkWgs?: boolean;
|
|
33
|
+
static?: boolean;
|
|
34
|
+
sensorId?: number;
|
|
35
|
+
url?: string;
|
|
36
|
+
volume?: boolean;
|
|
37
|
+
zoom: ZoomValue;
|
|
38
|
+
band?: string;
|
|
39
|
+
objName?: string;
|
|
40
|
+
uiName?: string;
|
|
41
|
+
system?: string;
|
|
42
|
+
operator?: string;
|
|
43
|
+
|
|
44
|
+
constructor(info: DetailedSensorParams & SensorParams & BaseObjectParams) {
|
|
45
|
+
super(info);
|
|
46
|
+
this.country = info.country;
|
|
47
|
+
this.latRad = (info.lat * (Math.PI / 180)) as Radians;
|
|
48
|
+
this.lonRad = (info.lon * (Math.PI / 180)) as Radians;
|
|
49
|
+
this.shortName = info.shortName;
|
|
50
|
+
this.beamwidth = info.beamwidth;
|
|
51
|
+
this.changeObjectInterval = info.changeObjectInterval;
|
|
52
|
+
this.linkAehf = info.linkAehf;
|
|
53
|
+
this.linkGalileo = info.linkGalileo;
|
|
54
|
+
this.linkIridium = info.linkIridium;
|
|
55
|
+
this.linkStarlink = info.linkStarlink;
|
|
56
|
+
this.linkWgs = info.linkWgs;
|
|
57
|
+
this.static = info.static;
|
|
58
|
+
this.sensorId = info.sensorId;
|
|
59
|
+
this.url = info.url;
|
|
60
|
+
this.volume = info.volume;
|
|
61
|
+
this.zoom = info.zoom;
|
|
62
|
+
this.band = info.band;
|
|
63
|
+
this.objName = info.objName;
|
|
64
|
+
this.uiName = info.uiName;
|
|
65
|
+
this.system = info.system;
|
|
66
|
+
this.operator = info.operator;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { BaseObject, BaseObjectParams, Degrees, Kilometers } from 'ootk-core';
|
|
19
|
+
/* eslint-disable class-methods-use-this */
|
|
20
|
+
|
|
21
|
+
export interface LandObjectParams extends BaseObjectParams {
|
|
22
|
+
lat: Degrees;
|
|
23
|
+
lon: Degrees;
|
|
24
|
+
alt: Kilometers;
|
|
25
|
+
country?: string;
|
|
26
|
+
Code?: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export class LandObject extends BaseObject {
|
|
30
|
+
lat: Degrees;
|
|
31
|
+
lon: Degrees;
|
|
32
|
+
alt: Kilometers;
|
|
33
|
+
country?: string;
|
|
34
|
+
Code?: string;
|
|
35
|
+
|
|
36
|
+
constructor(info: LandObjectParams) {
|
|
37
|
+
super(info);
|
|
38
|
+
this.lat = info.lat;
|
|
39
|
+
this.lon = info.lon;
|
|
40
|
+
this.alt = info.alt;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
isLandObject() {
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { BaseObject } from 'ootk-core';
|
|
19
|
+
/* eslint-disable class-methods-use-this */
|
|
20
|
+
|
|
21
|
+
export class Marker extends BaseObject {
|
|
22
|
+
isMarker() {
|
|
23
|
+
return true;
|
|
24
|
+
}
|
|
25
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author Theodore Kruczek.
|
|
3
|
+
* @license MIT
|
|
4
|
+
* @copyright (c) 2022-2024 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 { DEG2RAD, Degrees, RAD2DEG, Radians, Sensor, SpaceObjectType } from 'ootk-core';
|
|
25
|
+
import { azel2uv, uv2azel, RfSensorParams } from '../main';
|
|
26
|
+
|
|
27
|
+
export class RfSensor extends Sensor {
|
|
28
|
+
coneHalfAngle: Degrees;
|
|
29
|
+
boresightAz: Degrees;
|
|
30
|
+
boresightEl: Degrees;
|
|
31
|
+
|
|
32
|
+
constructor(info: RfSensorParams) {
|
|
33
|
+
super(info);
|
|
34
|
+
|
|
35
|
+
switch (info.type) {
|
|
36
|
+
case SpaceObjectType.BISTATIC_RADIO_TELESCOPE:
|
|
37
|
+
case SpaceObjectType.MECHANICAL:
|
|
38
|
+
case SpaceObjectType.PHASED_ARRAY_RADAR:
|
|
39
|
+
break;
|
|
40
|
+
default:
|
|
41
|
+
throw new Error('Invalid sensor type');
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
this.coneHalfAngle = info.coneHalfAngle;
|
|
45
|
+
this.boresightAz = info.boresightAz;
|
|
46
|
+
this.boresightEl = info.boresightEl;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
uvFromAzEl(az: Degrees, el: Degrees) {
|
|
50
|
+
const azRad = (az * DEG2RAD) as Radians;
|
|
51
|
+
const elRad = (el * DEG2RAD) as Radians;
|
|
52
|
+
const azDiff = (azRad - this.boresightAzRad) as Radians;
|
|
53
|
+
const elDiff = (elRad - this.boresightElRad) as Radians;
|
|
54
|
+
|
|
55
|
+
return azel2uv(azDiff, elDiff, this.coneHalfAngleRad);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
azElFromUV(u: number, v: number) {
|
|
59
|
+
const { az, el } = uv2azel(u, v, this.coneHalfAngleRad);
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
az: ((az + this.boresightAz) * RAD2DEG) as Degrees,
|
|
63
|
+
el: ((el + this.boresightEl) * RAD2DEG) as Degrees,
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
get boresightAzRad() {
|
|
68
|
+
return (this.boresightAz * DEG2RAD) as Radians;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
get boresightElRad() {
|
|
72
|
+
return (this.boresightEl * DEG2RAD) as Radians;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
get coneHalfAngleRad() {
|
|
76
|
+
return (this.coneHalfAngle * DEG2RAD) as Radians;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { EpochUTC, J2000, Matrix, Vector, Vector3D } from 'ootk-core';
|
|
19
|
+
import { Propagator } from '../propagator/Propagator';
|
|
20
|
+
import { RandomGaussianSource } from './../operations/RandomGaussianSource';
|
|
21
|
+
import { PropagatorPairs } from './PropagatorPairs';
|
|
22
|
+
|
|
23
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
24
|
+
/**
|
|
25
|
+
* Observation data.
|
|
26
|
+
*/
|
|
27
|
+
export abstract class Observation {
|
|
28
|
+
/** Observation epoch. */
|
|
29
|
+
abstract get epoch(): EpochUTC;
|
|
30
|
+
|
|
31
|
+
/** Inertial observer location. */
|
|
32
|
+
abstract get site(): J2000;
|
|
33
|
+
|
|
34
|
+
/** Observation noise matrix. */
|
|
35
|
+
abstract get noise(): Matrix;
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Return range-normalized cross line-of-sight residual for the observation
|
|
39
|
+
* when compared against a nominal state propagator.
|
|
40
|
+
* @param propagator Propagator to compare against.
|
|
41
|
+
* @throws Not implemented.
|
|
42
|
+
*/
|
|
43
|
+
clos(propagator: Propagator): number {
|
|
44
|
+
throw new Error('Not implemented');
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Return relative state residual for the observation when compared against
|
|
49
|
+
* a nominal state propagator.
|
|
50
|
+
* @param propagator Propagator to compare against.
|
|
51
|
+
* @throws Not implemented.
|
|
52
|
+
*/
|
|
53
|
+
ricDiff(propagator: Propagator): Vector3D {
|
|
54
|
+
throw new Error('Not implemented');
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Convert this observation to vector form.
|
|
59
|
+
* @throws Not implemented.
|
|
60
|
+
*/
|
|
61
|
+
toVector(): Vector {
|
|
62
|
+
throw new Error('Not implemented');
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
/**
|
|
66
|
+
* Compute the state derivative matrix for this observation.
|
|
67
|
+
* @param propPairs Propagator pairs to compare against.
|
|
68
|
+
* @throws Not implemented.
|
|
69
|
+
*/
|
|
70
|
+
jacobian(propPairs: PropagatorPairs): Matrix {
|
|
71
|
+
throw new Error('Not implemented');
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Compute the state residual matrix for this observation.
|
|
76
|
+
* @param propagator Propagator to compare against.
|
|
77
|
+
* @throws Not implemented.
|
|
78
|
+
*/
|
|
79
|
+
residual(propagator: Propagator): Matrix {
|
|
80
|
+
throw new Error('Not implemented');
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Convert this observation's noise matrix into a covariance matrix.
|
|
85
|
+
* @returns A matrix representing the noise covariance.
|
|
86
|
+
*/
|
|
87
|
+
noiseCovariance(): Matrix {
|
|
88
|
+
return this.noise.reciprocal();
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Generates a noise sample from the noise covariance matrix.
|
|
93
|
+
* @param sigma - The scaling factor for the noise covariance matrix.
|
|
94
|
+
* @returns A matrix representing the noise sample.
|
|
95
|
+
*/
|
|
96
|
+
noiseSample_(sigma: number): Matrix {
|
|
97
|
+
return this.noiseCovariance().scale(sigma).cholesky();
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* Randomly sample this observation in vector form within the
|
|
102
|
+
* observation noise.
|
|
103
|
+
* @param random Random number generator.
|
|
104
|
+
* @param sigma Sigma value to scale the noise by.
|
|
105
|
+
* @returns Sampled observation.
|
|
106
|
+
*/
|
|
107
|
+
sampleVector(random: RandomGaussianSource, sigma: number): Vector {
|
|
108
|
+
const chol = this.noiseSample_(sigma);
|
|
109
|
+
const gauss = random.gaussVector(this.noise.columns);
|
|
110
|
+
const meas = this.toVector();
|
|
111
|
+
|
|
112
|
+
return meas.add(chol.multiplyVector(gauss));
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* Randomly sample this observation within the observation noise, scaled to
|
|
117
|
+
* the provided sigma value.
|
|
118
|
+
* @param random Random number generator.
|
|
119
|
+
* @param sigma Sigma value to scale the noise by.
|
|
120
|
+
* @throws Not implemented.
|
|
121
|
+
*/
|
|
122
|
+
sample(random: RandomGaussianSource, sigma = 1.0): Observation {
|
|
123
|
+
throw new Error('Not implemented');
|
|
124
|
+
}
|
|
125
|
+
}
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import {
|
|
19
|
+
array2d,
|
|
20
|
+
DEG2RAD,
|
|
21
|
+
EpochUTC,
|
|
22
|
+
J2000,
|
|
23
|
+
KilometersPerSecond,
|
|
24
|
+
Matrix,
|
|
25
|
+
RadecTopocentric,
|
|
26
|
+
Radians,
|
|
27
|
+
RIC,
|
|
28
|
+
Vector,
|
|
29
|
+
Vector3D,
|
|
30
|
+
} from 'ootk-core';
|
|
31
|
+
import { RandomGaussianSource } from '../operations/RandomGaussianSource';
|
|
32
|
+
import { Propagator } from '../propagator/Propagator';
|
|
33
|
+
import { Observation } from './Observation';
|
|
34
|
+
import { normalizeAngle, observationDerivative, observationNoiseFromSigmas } from './ObservationUtils';
|
|
35
|
+
import { PropagatorPairs } from './PropagatorPairs';
|
|
36
|
+
|
|
37
|
+
// / Optical observation data.
|
|
38
|
+
export class ObservationOptical extends Observation {
|
|
39
|
+
// / Create a new [ObservationOptical] object.
|
|
40
|
+
constructor(
|
|
41
|
+
private _site: J2000,
|
|
42
|
+
public observation: RadecTopocentric,
|
|
43
|
+
private _noise: Matrix = ObservationOptical.defaultNoise,
|
|
44
|
+
) {
|
|
45
|
+
super();
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
// / Inertial site location.
|
|
49
|
+
get site(): J2000 {
|
|
50
|
+
return this._site;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// / Noise matrix.
|
|
54
|
+
get noise(): Matrix {
|
|
55
|
+
return this._noise;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Default noise matrix _(right-ascension, declination)_.
|
|
60
|
+
* Based on the Maui Optical Site noise model.
|
|
61
|
+
*/
|
|
62
|
+
static defaultNoise: Matrix = ObservationOptical.noiseFromSigmas(
|
|
63
|
+
0.0037 * DEG2RAD as Radians,
|
|
64
|
+
0.003 * DEG2RAD as Radians,
|
|
65
|
+
);
|
|
66
|
+
|
|
67
|
+
get epoch(): EpochUTC {
|
|
68
|
+
return this.observation.epoch;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
toVector(): Vector {
|
|
72
|
+
return Vector.fromList([this.observation.rightAscension, this.observation.declination]);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
clos(propagator: Propagator): number {
|
|
76
|
+
const position = propagator.propagate(this.epoch).position;
|
|
77
|
+
const offset = position.subtract(this.site.position);
|
|
78
|
+
const actual = this.observation.lineOfSight().normalize();
|
|
79
|
+
const expected = offset.normalize();
|
|
80
|
+
const slantRange = offset.magnitude();
|
|
81
|
+
const theta = actual.angle(expected);
|
|
82
|
+
|
|
83
|
+
if (isNaN(theta)) {
|
|
84
|
+
return 0.0;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
return 2.0 * slantRange * Math.sin(theta * 0.5);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
ricDiff(propagator: Propagator): Vector3D {
|
|
91
|
+
const r0 = this.site;
|
|
92
|
+
const r1 = propagator.propagate(this.epoch);
|
|
93
|
+
const r2 = this.observation.position(this.site, r1.position.distance(r0.position));
|
|
94
|
+
|
|
95
|
+
return RIC.fromJ2000(new J2000(this.epoch, r2, Vector3D.origin as Vector3D<KilometersPerSecond>), r1).position;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
sample(random: RandomGaussianSource, sigma = 1.0): Observation {
|
|
99
|
+
const resultEl = this.sampleVector(random, sigma).elements as Radians[];
|
|
100
|
+
|
|
101
|
+
return new ObservationOptical(
|
|
102
|
+
this.site,
|
|
103
|
+
new RadecTopocentric(this.epoch, resultEl[0], resultEl[1]),
|
|
104
|
+
this.noise,
|
|
105
|
+
);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
jacobian(propPairs: PropagatorPairs): Matrix {
|
|
109
|
+
const result = array2d(2, 6, 0.0);
|
|
110
|
+
|
|
111
|
+
for (let i = 0; i < 6; i++) {
|
|
112
|
+
const step = propPairs.step(i);
|
|
113
|
+
const [high, low] = propPairs.get(i);
|
|
114
|
+
const sl = low.propagate(this.epoch);
|
|
115
|
+
const sh = high.propagate(this.epoch);
|
|
116
|
+
const ol = RadecTopocentric.fromStateVector(sl, this.site);
|
|
117
|
+
const oh = RadecTopocentric.fromStateVector(sh, this.site);
|
|
118
|
+
|
|
119
|
+
result[0][i] = observationDerivative(oh.rightAscension, ol.rightAscension, step, true);
|
|
120
|
+
result[1][i] = observationDerivative(oh.declination, ol.declination, step, true);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
return new Matrix(result);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
residual(propagator: Propagator): Matrix {
|
|
127
|
+
const result = array2d(2, 1, 0.0);
|
|
128
|
+
const state = propagator.propagate(this.epoch);
|
|
129
|
+
const radec = RadecTopocentric.fromStateVector(state, this.site);
|
|
130
|
+
|
|
131
|
+
result[0][0] = normalizeAngle(this.observation.rightAscension, radec.rightAscension);
|
|
132
|
+
result[1][0] = normalizeAngle(this.observation.declination, radec.declination);
|
|
133
|
+
|
|
134
|
+
return new Matrix(result);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* Create a noise matrix from right ascension and declination standard deviantions.
|
|
139
|
+
* @param raSigma Right ascension standard deviation
|
|
140
|
+
* @param decSigma Declination standard deviation
|
|
141
|
+
* @returns Noise matrix
|
|
142
|
+
*/
|
|
143
|
+
static noiseFromSigmas(raSigma: Radians, decSigma: Radians): Matrix {
|
|
144
|
+
return observationNoiseFromSigmas([raSigma, decSigma]);
|
|
145
|
+
}
|
|
146
|
+
}
|
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import {
|
|
19
|
+
array2d,
|
|
20
|
+
DEG2RAD,
|
|
21
|
+
EpochUTC,
|
|
22
|
+
J2000,
|
|
23
|
+
Kilometers,
|
|
24
|
+
KilometersPerSecond,
|
|
25
|
+
Matrix,
|
|
26
|
+
Radians,
|
|
27
|
+
RAE,
|
|
28
|
+
RIC,
|
|
29
|
+
Vector,
|
|
30
|
+
Vector3D,
|
|
31
|
+
} from 'ootk-core';
|
|
32
|
+
import { RandomGaussianSource } from '../operations/RandomGaussianSource';
|
|
33
|
+
import { Propagator } from '../propagator/Propagator';
|
|
34
|
+
import { Observation } from './Observation';
|
|
35
|
+
import { normalizeAngle, observationDerivative, observationNoiseFromSigmas } from './ObservationUtils';
|
|
36
|
+
import { PropagatorPairs } from './PropagatorPairs';
|
|
37
|
+
|
|
38
|
+
// / Radar observation data.
|
|
39
|
+
export class ObservationRadar extends Observation {
|
|
40
|
+
// / Create a new [ObservationRadar] object.
|
|
41
|
+
constructor(private _site: J2000, public observation: RAE, private _noise: Matrix = ObservationRadar.defaultNoise) {
|
|
42
|
+
super();
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// / Default noise matrix.
|
|
46
|
+
private static defaultNoise: Matrix =
|
|
47
|
+
ObservationRadar.noiseFromSigmas(0.32 as Kilometers, 0.015 * DEG2RAD as Radians, 0.015 * DEG2RAD as Radians);
|
|
48
|
+
|
|
49
|
+
get epoch(): EpochUTC {
|
|
50
|
+
return this.observation.epoch;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
get site(): J2000 {
|
|
54
|
+
return this._site;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
get noise(): Matrix {
|
|
58
|
+
return this._noise;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
toVector(): Vector {
|
|
62
|
+
return Vector.fromList([this.observation.rng, this.observation.azRad, this.observation.elRad]);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
clos(propagator: Propagator): number {
|
|
66
|
+
const ri = propagator.propagate(this.epoch).position.subtract(this.site.position);
|
|
67
|
+
|
|
68
|
+
return Math.abs(this.observation.rng - ri.magnitude());
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
ricDiff(propagator: Propagator): Vector3D {
|
|
72
|
+
const r0 = propagator.propagate(this.epoch);
|
|
73
|
+
const r1 = RAE.fromStateVector(r0, this.site);
|
|
74
|
+
const r2 = this.observation.position(this.site, r1.azRad, r1.elRad);
|
|
75
|
+
|
|
76
|
+
return RIC.fromJ2000(new J2000(this.epoch, r2, Vector3D.origin as Vector3D<KilometersPerSecond>), r0).position;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
sample(random: RandomGaussianSource, sigma = 1.0): Observation {
|
|
80
|
+
const result = this.sampleVector(random, sigma).elements;
|
|
81
|
+
|
|
82
|
+
return new ObservationRadar(
|
|
83
|
+
this.site,
|
|
84
|
+
new RAE(this.observation.epoch, result[0] as Kilometers, result[1] as Radians, result[2] as Radians),
|
|
85
|
+
this.noise,
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
jacobian(propPairs: PropagatorPairs): Matrix {
|
|
90
|
+
const result = array2d(3, 6, 0.0);
|
|
91
|
+
|
|
92
|
+
for (let i = 0; i < 6; i++) {
|
|
93
|
+
const step = propPairs.step(i);
|
|
94
|
+
const [high, low] = propPairs.get(i);
|
|
95
|
+
const sl = low.propagate(this.epoch);
|
|
96
|
+
const sh = high.propagate(this.epoch);
|
|
97
|
+
const ol = RAE.fromStateVector(sl, this.site);
|
|
98
|
+
const oh = RAE.fromStateVector(sh, this.site);
|
|
99
|
+
|
|
100
|
+
result[0][i] = observationDerivative(oh.rng, ol.rng, step);
|
|
101
|
+
result[1][i] = observationDerivative(oh.azRad, ol.azRad, step, true);
|
|
102
|
+
result[2][i] = observationDerivative(oh.elRad, ol.elRad, step, true);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
return new Matrix(result);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
residual(propagator: Propagator): Matrix {
|
|
109
|
+
const result = array2d(3, 1, 0.0);
|
|
110
|
+
const state = propagator.propagate(this.epoch);
|
|
111
|
+
const razel = RAE.fromStateVector(state, this.site);
|
|
112
|
+
|
|
113
|
+
result[0][0] = this.observation.rng - razel.rng;
|
|
114
|
+
result[1][0] = normalizeAngle(this.observation.azRad, razel.azRad);
|
|
115
|
+
result[2][0] = normalizeAngle(this.observation.elRad, razel.elRad);
|
|
116
|
+
|
|
117
|
+
return new Matrix(result);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/**
|
|
121
|
+
* Create a noise matrix from the range, azimuth, and elevation standard
|
|
122
|
+
* deviations _(kilometers/radians)_.
|
|
123
|
+
* @param rngSigma - The range standard deviation _(kilometers)_.
|
|
124
|
+
* @param azSigma - The azimuth standard deviation _(radians)_.
|
|
125
|
+
* @param elSigma - The elevation standard deviation _(radians)_.
|
|
126
|
+
* @returns The noise matrix.
|
|
127
|
+
*/
|
|
128
|
+
static noiseFromSigmas(rngSigma: Kilometers, azSigma: Radians, elSigma: Radians): Matrix {
|
|
129
|
+
return observationNoiseFromSigmas([rngSigma, azSigma, elSigma]);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author @thkruz Theodore Kruczek
|
|
3
|
+
* @license AGPL-3.0-or-later
|
|
4
|
+
* @copyright (c) 2020-2024 Theodore Kruczek
|
|
5
|
+
*
|
|
6
|
+
* Orbital Object ToolKit is free software: you can redistribute it and/or modify it under the
|
|
7
|
+
* terms of the GNU Affero General Public License as published by the Free Software
|
|
8
|
+
* Foundation, either version 3 of the License, or (at your option) any later version.
|
|
9
|
+
*
|
|
10
|
+
* Orbital Object ToolKit is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
|
11
|
+
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
12
|
+
* See the GNU Affero General Public License for more details.
|
|
13
|
+
*
|
|
14
|
+
* You should have received a copy of the GNU Affero General Public License along with
|
|
15
|
+
* Orbital Object ToolKit. If not, see <http://www.gnu.org/licenses/>.
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { Matrix } from 'ootk-core';
|
|
19
|
+
|
|
20
|
+
export const normalizeAngle = (a: number, b: number): number => {
|
|
21
|
+
const x = a - b;
|
|
22
|
+
|
|
23
|
+
return Math.atan2(Math.sin(x), Math.cos(x));
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export const observationDerivative = (xh: number, xl: number, step: number, isAngle = false): number =>
|
|
27
|
+
(isAngle ? normalizeAngle(xh, xl) : xh - xl) / step;
|
|
28
|
+
|
|
29
|
+
export const observationNoiseFromSigmas = (sigmas: number[]): Matrix => {
|
|
30
|
+
const n = sigmas.length;
|
|
31
|
+
const result = Array.from({ length: n }, () => Array(n).fill(0.0));
|
|
32
|
+
|
|
33
|
+
for (let i = 0; i < n; i++) {
|
|
34
|
+
const s = sigmas[i];
|
|
35
|
+
|
|
36
|
+
result[i][i] = 1 / (s * s);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
return new Matrix(result);
|
|
40
|
+
};
|