Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ECI conversion not precise on LAT and ALTITUDE #17

Open
canupe opened this issue Aug 15, 2022 · 0 comments
Open

ECI conversion not precise on LAT and ALTITUDE #17

canupe opened this issue Aug 15, 2022 · 0 comments

Comments

@canupe
Copy link

canupe commented Aug 15, 2022

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant