Calculations are incorrect unless timezone = 0
When running this program using the default sample code and comparing it with Orbitoron, the calculations were incorrect unless the timezone was set to UTC 0.
Steps taken:
- Left the sat.site set to the default location of Naoero.
- Replaced the unixtime by retrieving the current time externally and updating it accordingly.
- Obtained and updated the TLE for the ISS (Zarya) from Celestrak.
Following these steps, the calculations were off by about 30 minutes.
Setting timezone = 0 resolved the issue.
@Nero-198 Did you find another solution? even if you are not in timezone 0, do you have an issue? Seems that the timezone is for the predictor example and he forgot to remove it? In the calculations it is added to the Jd, which should the time we want to know isn't?
The ISS goes around the world every 90 mins, so if the calculations are about 45mins off, this make sense.
Not sure if it is an error or was simply not correctly explained.
cpp``` int leapyrs; double days, tu, temp;
**jd += (double)timezone / 24.0;**
/* --------------- find year and days of the year --------------- */
temp = jd - 2415019.5;
tu = temp / 365.25;
year = 1900 + (int)floor(tu);
leapyrs = (int)floor((year - 1901) * 0.25);
// optional nudge by 8.64x10-7 sec to get even outputs
days = temp - ((year - 1900) * 365.0 + leapyrs) + 0.00000000001;