MY PROGRAMS
Sun-Moon 2.3a
PROGRAM
This program calculates the following:
-dates marking the Easter and Christmas season
-all full and new moons for the
period of a year (starting in any month)
-the times for sunrise, sunset,
moonrise, moonset at any date
and any place,
-the position, phase, and
distance of the Moon from Earth.
By default the program starts with
the latitude and longitude of
Charlotte, NC and the current
date, but you have the option
to store a different default location
in the flash memory.
(The name of the file used is
"E:geo1".)
My sources were:
- Basic Programs
published in the journal
"Astronomical Computing, Sky and
Telescope" at
www.skypub.com/resources/
software/basic/basic.html,
-I checked (and corrected) the
full moon calculations against
the book
"Astronomical Formulae for
Calculators" by Jean Meeus
-the pages on calendar systems
by Peter Meyers at
serendipity.magnet.ch/
hermetic/cal_stud.htm
-Peter Baum's date algorithms at
home.capecod.net/~pbaum/info3.htm
-Date of Easter formula from
sciastro.astronomy.net/
sci.astro.3.FAQ
-Moon phase pictures were
provided by Istvn Totka
(totka@freemail.hu)
Gbor Hetyei
ghetyei@uncc.edu
BIN_PROG_1
PFILE:BI49YFW2.BAS
=
E
=
E
=
0A(2),D(2):0M(3,3)
2Y9=((,4)):M9=((,5,2)):D9=((,2))
U+ 20
!"E:geo1"Was#1
&a#1,B9:a#1,L9:a#1,H9:"#1:+ 100
B9=35:L9=-80:H9=5
dP
nAQ2,0:`"[1] Dates marking the Easter and Christmas season"
x1Q2,1:`"[2] Full and new moons for a year"
DQ2,2:`"[3] Rise/set times for the Sun and the Moon this day"
%Q2,3:`"[4] Current moonphase"
Q2,5:`"[S] Settings"
Q121,5:`"[H] Help"
Q2,6:`"[Esc] Exit"
Q121,6:`"[C] Credits"
XA$=(1)
V(A$)=27TZ
VA$="1"T1000
VA$="2"T2000
VA$="3"T\3000
VA$="4"T)t10000
VA$="s"A$="S"T$8000
VA$="h"A$="H"T!7500
VA$="c"A$="C"T"7800
" +200
Y
-P:a"Give a year later than 1582. Year =";Y
VY<1583T1010
C=(Y/100)
N=Y-19*(Y/19):K=((C-17)/25)
I=C-(C/4)-((C-K)/3)+19*N+15
$I=I-30*(I/30)
.5I=I-(I/28)*(1-(I/28)*(29/(I+1))*((21-N)/11))
8.J=Y+(Y/4)+I+2-C+(C/4):J=J-7*(J/7):L=I-J
B$M=3+((L+40)/44):D=L+28-31*(M/4)
L0Y2=Y:M2=M:D2=D:b 86000:J=J+FJ-46:b5000:Y
V2P:Q2,0:`"Ash Wednesday:":Q121,0:b0*11000:Y
`>Y=Y2:M=M2:D=D2:Q2,1:`"Easter Sunday:":Q121,1:b0*11000:Y
jJ=J+95:b5000:Y
t+Q2,2:`"Pentecost:":Q121,2:b0*11000:Y
~EJ1=J:M=12:D=25:b 86000:W=J-J1-7*((J-J1)/7):J=J-W-21:b5000:Y
8Q2,3:`"First Sunday of Advent:":Q121,3:b0*11000:Y
9M=12:D=25:Q2,4:`"Christmas Day:":Q121,4:b0*11000:Y
b(9000:+ 100
Y
5P:b<2990:a"Year=";Y:a"Month=";M:XY=Y+(M-1)/12
Db<2990:S1=0:U=0
HY
JK0=((Y-1900)*12.3685)
LT=(Y-1900)/100
NT2=T*T:T3=T*T*T
PJ0=2415020+29*K0
RF0=.0001178*T2-.000000155*T3
TF0=F0+.75933+.53058868*K0
V.F0=F0+0.00033*(166.56+132.87*T-0.009173*T2)
XJ0=J0+(F0):F0=F0-(F0)
ZM0=K0*29.10535608
\M0=M0-(M0/360)*360+359.2242
^M0=M0-.0000333*T2
`M0=M0-.00000347*T3
bM1=K0*385.81691806
dM1=M1-(M1/360)*360+306.0253
fM1=M1+.0107306*T2
hM1=M1+.00001236*T3
jB1=K0*390.67050646
lB1=B1-(B1/360)*360+21.2964
nB1=B1-.0016528*T2
pB1=B1-.00000239*T3
rWK9=0R28
tJ=J0+14*K9:F=F0+.76529434*K9
vK=K9/2
xM5=M0+K*29.10535608
yM6=M1+K*385.81691806
zB6=B1+K*390.67050646
{