Use SGP4 Propagator for GPS #770

Merged
muellerr merged 33 commits from use-sgp4-propagator into main 2023-08-14 15:47:33 +02:00
Showing only changes of commit 93896557aa - Show all commits

View File

@ -187,8 +187,8 @@ void SensorProcessing::processSus(
double JC2000 = JD2000 / 36525.;
double meanLongitude =
sunModelParameters->omega_0 + (sunModelParameters->domega * JC2000) * PI / 180.;
double meanAnomaly = (sunModelParameters->m_0 + sunModelParameters->dm * JC2000) * PI / 180.;
sunModelParameters->omega_0 + (sunModelParameters->domega * JC2000) * M_PI / 180.;
double meanAnomaly = (sunModelParameters->m_0 + sunModelParameters->dm * JC2000) * M_PI / 180.;
double eclipticLongitude = meanLongitude + sunModelParameters->p1 * sin(meanAnomaly) +
sunModelParameters->p2 * sin(2 * meanAnomaly);
@ -546,8 +546,8 @@ void SensorProcessing::processGps(const double gpsLatitude, const double gpsLong
return;
} else if (validGps) {
// Transforming from Degree to Radians and calculation geocentric latitude from geodetic
gdLongitude = gpsLongitude * PI / 180.;
double latitudeRad = gpsLatitude * PI / 180.;
gdLongitude = gpsLongitude * M_PI / 180.;
double latitudeRad = gpsLatitude * M_PI / 180.;
double factor = 1 - pow(ECCENTRICITY_WGS84, 2);
gcLatitude = atan(factor * tan(latitudeRad));