Home > matutils > angles > hdl2ae.m

hdl2ae

PURPOSE ^

[A,E]=hdl2ae(H,d,L)

SYNOPSIS ^

function [A,E]=hdl2ae(H,d,L)

DESCRIPTION ^

 [A,E]=hdl2ae(H,d,L)

 Transform Hour angle & Declination H,d at Latitude L
 to Azimuth, Elevation A,E according to
 TMS Eqn A4.1. Azimuth is measured from north
 through east.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [A,E]=hdl2ae(H,d,L)
0002 % [A,E]=hdl2ae(H,d,L)
0003 %
0004 % Transform Hour angle & Declination H,d at Latitude L
0005 % to Azimuth, Elevation A,E according to
0006 % TMS Eqn A4.1. Azimuth is measured from north
0007 % through east.
0008 
0009 sinH=sin(H); cosH=cos(H);
0010 sind=sin(d); cosd=cos(d);
0011 sinL=sin(L); cosL=cos(L);
0012 
0013 E=asin(sinL.*sind+cosL.*cosd.*cosH);
0014 A=atan2(-cosd.*sinH,cosL.*sind-sinL.*cosd.*cosH);
0015 
0016 return

Generated on Sun 14-Jun-2015 17:12:45 by m2html © 2005