-
Notifications
You must be signed in to change notification settings - Fork 3
Description
Dear Igor,
First of all thank you very much for your development that helped me a lot to quickly calculate link budget.
I found wrong pointing values when using a NGSO satellite Cartesian coordinates and so distance from my antenna were affected also.
So I took the liberty of modifying your function look_angles to make it works properly with this kind of satellite position.
I have already seen the previous Issue addressing this problem but apparently not solving at the end.
Then I performed a check here to see further.
3975f78
Actually the problem is conserving 0 value in the Z plan addresses automatically a satellite on equatorial plan.
The formula is okay for the antenna position and should be the same for the satellite.
(here is a reference to coordinates conversion I use : https://gssc.esa.int/navipedia/index.php/Ellipsoidal_and_Cartesian_Coordinates_Conversion)
So here is what I propose to you as a working fine modification :
(I am sorry I am not used yet to Git usage so I put here my modification if you don't mind.)
First I add radians conversion for sat-lat
sat_lat = radians(sat_lat)
Then just change this :
z_s = 0
to this :
z_s = (N * (1 - e_sq) + sat_alt) * sin(sat_lat)
Then the following steps for pointing calculation remain okay.
Now simulation looks good for all satellite Cartesian coordinates (GSO or NGSO).
Thank you again for this tool !
Kind regards from French Guiana neighbor ;)