-
Notifications
You must be signed in to change notification settings - Fork 33
Description
This test
func Test0(t *testing.T) {
// middle of August 2022
jtime := JDay(2022, 8, 15, 12, 0, 0)
// random place near Genoa, Italy
lat := 45.0 * DEG2RAD
lon := 8.0 * DEG2RAD
// on the hill
heightInKm := 0.5
// put in struct
myLatLon := LatLong{lat, lon}
// Go to ECI
posInECI := LLAToECI(myLatLon, heightInKm, jtime)
//t.Log(posInECI)
gmst := ThetaG_JD(jtime)
altitude, _, backToLLA := ECIToLLA(posInECI, gmst)
backToLLADeg := LatLongDeg(backToLLA)
t.Log(LatLongDeg(myLatLon), heightInKm)
t.Log(backToLLADeg, altitude)
}
verifies that conversion back and forth to ECI is problematic. Altitude seems to be ignored (try to change it in 45 or 15 km) and latitude is badly converted. I think (but it is an impression) that the issue is in the forward conversion. Also ECEF conversion appears not perfect.
UPDATE 26/08 : The issue is that latlon in input to LLAToECI is assumed to be SPHERICAL, while the output of ECIToLLA responds in WGS84
Paolo