% ECE 6390 Radiolocation Scavenger Hunt 3 (Fall 2006)
% The DeterminAtors

% Helper script that computes some variables and performs some conversions
% for use in our Maple solving routine.

% speed of light
c = 299860; % m/s
% mean radius of earth
Ratl = 6380 + 0.308; % atlanta is 308m above sea level on average
% altitude of GPS
Rgps = 20200 + Rearth;

% latitudes of the satellites 
Lats = [7.8520;45.1053;29.7834]; % [degrees]
Lats = 2*pi*Lats*(1/360);        % [radians]
% longitudes of the satellites
Lons = [-62.3256;-85.2234;-92.8388]; % [degrees]
Lons = 2*pi*Lons*(1/360);            % [radians]
% pseudoranges of the satellites
PRs = [0,-0.003817986,-0.004077077]*c; % [m]

% cartesian coordinates of our satellites
Xs = Rgps*cos(Lons).*cos(Lats);
Ys = Rgps*sin(Lons).*cos(Lats);
Zs = Rgps*sin(Lats);

% Initial guess is Van Leer
LatAtl = (33 + 46/60 + 33.24/3600) * (2*pi) / 360; % 33o46'33.24'' N
LonAtl = - (84 + 23/60 + 50.1/3600) * (2*pi) / 360; % 84o23'50.1'' W
