% make figure for gps exercise


t=0:pi/20:2*pi;
z = zeros(size(t));
plot3(cos(t),z,sin(t),'k')
hold on

plot3(cos(t),sin(t),z,'r')

a = pi/4;

plot3(cos(t), cos(a)*sin(t), sin(a)*sin(t))

plot3(cos(t), -sin(a)*sin(t), cos(a)*sin(t),'g')

plot3(cos(a)*cos(t), sin(a)*cos(t), cos(a)*sin(t), 'k:')

% phiC=41.8781*pi/180;
% thetaC = -87.6298*pi/180;
% C = [cos(phiC)*cos(thetaC); cos(phiC)*sin(thetaC); sin(phiC)];
% plot3(C(1),C(2),C(3),'s','markersize',10)
% 
% phiH=-17.8282*pi/180;
% thetaH = 31.0335*pi/180;
% H = [cos(phiH)*cos(thetaH); cos(phiH)*sin(thetaH); sin(phiH)];
% plot3(H(1),H(2),H(3),'s','markersize',10)
% 
% tp = linspace(phiH,phiC,20);
% tt = linspace(
% plot3(


axis equal
hold off
