BEAMHEAD Compute ham radio beam heading and distance. ----begin documentation---- Program: BEAMHEAD Author: John P. Powers (jpp@cpdvax.csc.ti.com) Date: December 1992 This program computes the direction to point your ham radio antenna to get best reception of a distant ham radio. Given your longitude and latitude and the longitude and latitude of another location this program computes the compass direction and distance in miles of the distant location. Answer the program's prompts for latitude and longitude as a pair of numbers in parentheses. For example, the latitude and longitude of Fairbanks, Alaska (65 degrees north, 147 degrees west) would be entered as (65,147). Southern latitudes and eastern longitudes are entered as negative angles. Store the latitudes and longitudes in variables to build up a data base of city, country, and ham radio call sign locations. For example: (33,97)->Dallas (65,147)->Fairbank (47,71)->Quebec The variable name of the location may then be entered at the prompt for a location. Example: Compute the direction and distance from Dallas to Fairbanks. BEAMHEAD Origin (lat,long): Dallas --Use [VARS] to quickly Dest (lat,long): Fairbank --look up and enter the city names. Dist= 3026.08610281 Bearing= 332o7'36.687" The great circle distance from Dallas to Fairbanks is 3026 miles with a bearing of 332 degrees. ----end documentation---- ----begin ascii---- \START\ \COMMENT=Distance and direction between cities \NAME=BEAMHEAD \FILE=beamhead.85P Degree Input "Origin (lat,long): ",ORIG Input "Dest (lat,long): ",DEST real ORIG\->\OLAT imag ORIG\->\OLNG real DEST\->\DLAT imag DEST\->\DLNG (\cos^-1\ (sin OLAT*sin DLAT+cos OLAT*cos DLAT*cos (DLNG-OLNG))*60) nmi\#\ le\>\mile\->\DIST Disp "Dist=",DIST OLNG-DLNG\->\LNG \tan^-1\ (cos LNG/tan DLAT)\->\AA \tan^-1\ (1/((cos (OLAT+AA)/tan LNG)/sin AA))\->\AZ If AZ<0:AZ+360\->\AZ Disp "Bearing=",AZ\>DMS\ \STOP\ ----end ascii---- ----begin uue---- begin 644 beamhead.85p M*BI423@U*BH:#`!$:7-T86YC92!A;F0@9&ER96-T:6]N(&)E='=E96X@8VET M:65S("`@("!V`0P`9@$2"$)%04U(14%$9@%D`0!$96=R967626YP=70@(D]R M:6=I;B`H;&%T+&QO;F