Clear Filters
Clear Filters

Calculating the elevation and azimuth angles of satellites with location information obtained from sp3 ephemeris files

18 views (last 30 days)
Hi, I'm trying to calculate elevation and azimuth angles of satellites for a ground GPS receiver. I downloaded the SP3 file for the day '12-01-2015'. The ephemeris files are xs1846, ys1846, zs1846 are attached.
The ground station location is lat_receiver= 37.0;%degree, lon_receiver= 35.34;%degree.
Are SP3 ephemeris files format ECEF? How can I found the elevation and azimuth angles for that station for all 32 GPS satellite? I need to find the satellittes and the times with an elevation greater than 40 degrees?
I write a code but I am not sure if this is true. Can you help me?
clear all;close all;clc;
load xs1846; load ys1846;load zs1846;
lat_receiver= 37.0;%degree
lon_receiver= 35.34;%degree
height_receiver=0;%meter
for j=1:32
for i=1:96
xss=xs(i,j); yss=ys(i,j);zss=zs(i,j);
[geosat_ENU_X,geosat_ENU_Y,geosat_ENU_Z] = ecef2enu(xss,yss,zss,...
lat_receiver,lon_receiver,height_receiver,referenceEllipsoid('wgs84','m'));
elev_receiver(i,j) = rad2deg(asin(geosat_ENU_Z/sqrt(geosat_ENU_X^2+geosat_ENU_Y^2+geosat_ENU_Z^2)));
azi_NtoE_receiver(i,j) = rad2deg(asin(geosat_ENU_X/sqrt(geosat_ENU_X^2+geosat_ENU_Y^2)));
end
end
.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!