NavList:
A Community Devoted to the Preservation and Practice of Celestial Navigation and Other Methods of Traditional Wayfinding
Re: Nautical Almanac Moon Correction Tables
From: Frank Reed CT
Date: 2006 Jul 26, 18:42 -0500
I found a slightly shorter approach to this calculation. If you do the SD
correction after the parallax, the augmentation cancels out. Here's the code:
----------------------------------------------
kk = 180 / 3.141593
'Mean Horizontal Parallax:
HP0 = 57.7
'Ratio of Moon's mean SD to HP0. Again, 0.2724 would probably
'be more acurate but this matches the tables:
SDcon = .2711
'SD0 is the semi-diameter at the mean Horizontal Parallax, HP0:
SD0 = SDcon * HP0
INPUT "HP:", HP
FOR h1 = 0 TO 89 STEP 1
PRINT h1
'The observed altitude, h1, determines the refraction
h2 = h1 - refr0(h1 / kk) / 60
'Add in parallax and mean semi-diameter
h3 = h2 + HP0 * COS(h2 / kk) / 60 + SD0 / 60
'The Lower Table uses the average altitude from the upper column:
havg = 2.5 + 5 * INT(h1 / 5)
'h4 (LL/UL) is the increment in the Moon's semi-diameter and
'its parallax for the difference between the actual HP and the mean
'Horizontal Parallax, HP0.
dHP = (HP - HP0) / 60
dSD = SDcon * dHP
h4 = h3 + dHP * COS(havg / kk)
h4LL = h4 + dSD
h4UL = h4 - dSD
'To keep the Lower Table corrections always positive, add
'5 minutes to the LL correction and 35 to the UL correction.
'To compensate, subtract 5 minutes from the Upper Table.
'Also subtract twice the mean semi-diameter for the UL.
UTcorr = 60 * (h3 - h1) - 5
LTcorrLL = 60 * (h4LL - h3) + 5
LTcorrUL = 60 * (h4UL - h3) - 2 * SD0 + 35
'output the results:
PRINT "Upper Table Correction: ";
PRINT USING "###.##"; UTcorr
PRINT "Lower Table LL Correction: ";
PRINT USING "###.##"; LTcorrLL
PRINT "Lower Table UL Correction: ";
PRINT USING "###.##"; LTcorrUL
IF LEN(INKEY$) THEN EXIT FOR
SLEEP
NEXT
---------------------------------------
-FER
42.0N 87.7W, or 41.4N 72.1W.
www.HistoricalAtlas.com/lunars
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to NavList@fer3.com
To , send email to NavList-@fer3.com
-~----------~----~----~----~------~----~------~--~---
From: Frank Reed CT
Date: 2006 Jul 26, 18:42 -0500
I found a slightly shorter approach to this calculation. If you do the SD
correction after the parallax, the augmentation cancels out. Here's the code:
----------------------------------------------
kk = 180 / 3.141593
'Mean Horizontal Parallax:
HP0 = 57.7
'Ratio of Moon's mean SD to HP0. Again, 0.2724 would probably
'be more acurate but this matches the tables:
SDcon = .2711
'SD0 is the semi-diameter at the mean Horizontal Parallax, HP0:
SD0 = SDcon * HP0
INPUT "HP:", HP
FOR h1 = 0 TO 89 STEP 1
PRINT h1
'The observed altitude, h1, determines the refraction
h2 = h1 - refr0(h1 / kk) / 60
'Add in parallax and mean semi-diameter
h3 = h2 + HP0 * COS(h2 / kk) / 60 + SD0 / 60
'The Lower Table uses the average altitude from the upper column:
havg = 2.5 + 5 * INT(h1 / 5)
'h4 (LL/UL) is the increment in the Moon's semi-diameter and
'its parallax for the difference between the actual HP and the mean
'Horizontal Parallax, HP0.
dHP = (HP - HP0) / 60
dSD = SDcon * dHP
h4 = h3 + dHP * COS(havg / kk)
h4LL = h4 + dSD
h4UL = h4 - dSD
'To keep the Lower Table corrections always positive, add
'5 minutes to the LL correction and 35 to the UL correction.
'To compensate, subtract 5 minutes from the Upper Table.
'Also subtract twice the mean semi-diameter for the UL.
UTcorr = 60 * (h3 - h1) - 5
LTcorrLL = 60 * (h4LL - h3) + 5
LTcorrUL = 60 * (h4UL - h3) - 2 * SD0 + 35
'output the results:
PRINT "Upper Table Correction: ";
PRINT USING "###.##"; UTcorr
PRINT "Lower Table LL Correction: ";
PRINT USING "###.##"; LTcorrLL
PRINT "Lower Table UL Correction: ";
PRINT USING "###.##"; LTcorrUL
IF LEN(INKEY$) THEN EXIT FOR
SLEEP
NEXT
---------------------------------------
-FER
42.0N 87.7W, or 41.4N 72.1W.
www.HistoricalAtlas.com/lunars
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to NavList@fer3.com
To , send email to NavList-@fer3.com
-~----------~----~----~----~------~----~------~--~---