Skyplot

This file is part of Miscellaneous Programs. Download the collection to get this file.
Date: 198x
Type: Program
Platform(s): TS 2068
Tags: Astronomy

Calculates where the Sun, Moon and planets stand in the sky for any date, local time and observer location, then plots them on a sky chart. Skyplot asks for latitude and longitude (preset to Indianapolis), the date, the time zone, the local mean time in decimal hours and which quarter of the horizon to face. It then shows each body as a letter or UDG symbol on an altitude scale running from 5° to 85° above a green zigzag horizon, with compass points along the bottom. The Moon’s symbol changes with its phase. A second mode, Find Planets, gives the right ascension and declination of a chosen planet, the Sun or the Moon and then draws it among the zodiac constellations on a star chart crossed by the ecliptic. Both modes offer a printer COPY of the screen.

The title screen credits Eric Burgess F.R.A.S. and S and T Software, with modifications by PEH Software. The program is the first item on side A of the Miscellaneous Programs tape (file 1_ST1, saved as st1), just ahead of the Constellations star quiz. A renumbered and slightly tightened version, which carries the same credits and is saved with the LKDOS form of SAVE, is st1 on the Larken PubDom #6 disk.

Program Analysis

Program Structure

  • Line 9 jumps to the setup at 8000. The tape copy is saved with LINE PI, so it autostarts at line 3 and runs on to line 9.
  • Lines 8000–8300 draw the title screen with two hexagonal frames, define the UDGs, dimension the arrays, unpack the orbital elements and offer the choice of Skyplot or Find Planets.
  • Lines 8500–8740 show the Skyplot instructions and symbol legend, then collect location, date (subroutine 7000), time zone, local time and viewing direction.
  • Lines 20–180 compute a day number and the local sidereal time. Lines 1000–1380 compute the planets, 1390–1540 the Sun and 1550–1870 the Moon.
  • Lines 190–410 draw the sky chart and place the bodies, and lines 420–480 offer Copy, New date, Stop or Rerun.
  • Lines 9000–9100 run Find Planets: a body menu, the date, then lines 2000–2380 for the coordinates table, 2400–3010 for the twelve zodiac star fields and 4000–4200 for placing the bodies on the chart.

Orbital Model

The orbital elements for Mercury through Pluto, with Earth in slot 3, are held as 81 seven-character fields in one long string, D$, which lines 8210–8240 slice up with VAL into the array P(9,9). Each body’s heliocentric longitude is its mean daily motion times the day count plus an epoch value, corrected by a single sine term for orbital eccentricity. Lines 1120–1210 then solve the Sun–Earth–planet triangle with the law of cosines and a half-perimeter formula to get the geocentric right ascension. Declination is approximated from the ecliptic longitude using the 23.44° obliquity, plus the planet’s ecliptic latitude. The hour angle from the sidereal time gives altitude and azimuth through the usual spherical-trig formulas. The Moon uses a separate short series with a mean longitude, a perigee correction and an inclined node, and its phase is taken from its elongation from the Sun.

Display

The Skyplot chart maps altitude to screen rows and a 180° slice of azimuth, chosen by the horizon setting, to columns. Bodies below 5° or above 85° are skipped. The body letters come from P$="+VOMJSUNP ". UDG a and b are the waxing and waning Moon crescents, c is the altitude-scale tick, d a degree sign, e the Sun glyph used in the legends, f a double dot and k a single dot for dim stars. In Find Planets, the chosen body’s right ascension selects one of twelve two-hour bands, from Pisces to Aquarius, and the program prints that band’s stars as k, * and X. The body and any others that fall in the same band are then placed by right ascension (column) and ecliptic latitude (row).

Notable Techniques

  • Constants are held in variables (A0, A1, P2, FD, FR), and PI stands in for 3 in PRINT AT, LINE PI and the UDG DATA. Because READ evaluates expressions, the DATA lines can contain PI, A0 and 2*PI.
  • The whole orbital-element table is one string literal decoded with VAL D$( TO 7), which avoids a long run of numeric DATA.
  • Line 240 picks the compass-label row with string AND expressions such as ("N ... S" AND HZ=A1)+(...).
  • GO TO 2350+50*CH at line 2370 jumps straight to the right constellation chart.
  • GO SUB 10 at line 9090 targets a line that doesn’t exist, so execution enters at line 20, the date routine.
  • The FOR loop at line 2310 runs NEXT only while the test is true, so it drops out with CA set to the start of the band.

Potential Issues

  • For northern latitudes, line 1840 returns before line 1870 stores the Moon’s altitude and azimuth in B(10) and Y(10). The Moon therefore appears never to be plotted on the Skyplot chart for northern observers, including the Indianapolis default.
  • Lines 1330, 1500 and 1730 are written ACS (...)/(CLA*COS (AL)). Sinclair BASIC applies ACS to the numerator only, so the azimuths appear to be computed incorrectly. The intended form is ACS ((...)/(...)).
  • Line 1720 uses ACS for the Moon’s altitude, while the planets and Sun use ASN, so the value appears to be the zenith distance rather than the altitude.
  • The Capricornus chart is at line 2950 instead of 2900. The 20–22h band (CH=11, line 2900, missing) falls through to it correctly, but the 22–24h band (CH=12) also lands on Capricornus, so the Aquarius chart at line 3000 is never shown.
  • The legends show the Sun as UDG e and the near-full Moon as o, but the plotting strings P$ and Q$ use O for both. Mars (M) is missing from the Skyplot legend.
  • Line 1070 jumps to a nonexistent line 1060, which lands on line 1068. This is harmless.

Appears On

A grab-bag of hidden gems — chat with an ELIZA therapist, play Boggle in three languages, navigate a 36-room cave to defuse a bomb, joust as a medieval knight, or generate random surreal poetry. Includes three holiday card programs.

Image Gallery

Source Code

    9 GO TO 8e3: REM REM SUB1 
   20 LET DG=365*Y+DY+((M-A1)*31)
   30 IF M>=3 THEN GO TO 50
   40 LET DG=DG+INT ((Y-A1)/4)-INT ((.75)*INT ((Y-A1)/100+A1)): GO TO 70
   50 LET DG=DG-INT (M*.4+2.3)+INT (Y/4)
   60 LET DG=DG-INT ((.75)*INT ((Y/100)+A1))
   70 LET NS=DG-722895: LET NI=DG-715875: IF CHO THEN RETURN 
   80 LET GC=12.064707: LET SG=.065711
   90 LET T2=SG*NS+GC+(((TZ+T1)/24)*SG)+T1
  100 IF T2<24 THEN GO TO 130
  110 IF T2>240 THEN LET T2=T2-240
  120 LET T2=T2-24: GO TO 100
  130 IF T2>-24 THEN GO TO 160
  140 IF T2<-240 THEN LET T2=T2+240
  150 LET T2=T2+24: GO TO 120
  160 IF T2>A0 THEN GO TO 180
  170 LET T2=T2+24
  180 GO SUB 1e3: CLS 
  190 PRINT "SKYPLOT - ";M;"-";DY;"-";Y;" AT ";T1;" LMT.,"
  200 PRINT INT (T2);" LST ";LS;" LAT. ";LO;" LONG."
  210 FOR K=85 TO A1 STEP -5
  220 PRINT "c",TAB 27;"c-";K;"d": NEXT K
  230 PLOT 16,16: INK 4: FOR F=A1 TO 16: DRAW 6,12: DRAW 6,-12: NEXT F: INK 7: PRINT AT 20,A1;
  240 PRINT ("N     NE     E     SE    S" AND HZ=A1)+("S     SW     W     NW    N" AND HZ=2)+("E     SE     S     SW    W" AND HZ=3)+("W     NW     N     NE    E" AND HZ=4)
  270 REM PRINT planets
  280 FOR j=A1 TO 10
  290 LET E(J)=ABS B(J): IF E(J)<5 OR E(J)>85 THEN GO TO 410
  300 IF HZ=A1 THEN LET Y(J)=Y(J): GO TO 370
  310 IF HZ=2 THEN LET Y(J)=Y(J)-180: GO TO 370
  320 IF HZ=3 THEN LET Y(J)=Y(J)-90: GO TO 370
  330 IF HZ=4 AND Y(J)>270 AND Y(J)<360 THEN LET Y(J)=Y(J)-270: GO TO 370
  340 IF HZ=4 AND Y(J)>A0 AND Y(J)<90 THEN LET Y(J)=Y(J)+90
  370 IF Y(J)<A0 OR Y(J)>180 THEN GO TO 410
  380 LET X1=E(J): LET Y1=Y(J)
  390 LET X2=19-INT (X1*18/90): LET Y2=INT (Y1*27/180)-A1
  400 PRINT AT X2,Y2;P$(J)
  410 NEXT J: PRINT AT 20,A0;
  415 REM SUB4 
  420 INPUT "1. COPY     2. NEW DATE","3. STOP     4. RERUN   ";D
  430 IF D=A1 THEN COPY : IF cho THEN RETURN 
  440 IF D=2 AND CHO=A0 THEN GO TO 8500
  450 IF D=2 THEN GO TO 9E3
  460 IF D=3 THEN PRINT AT 20,12; FLASH A1;"GOODBY": STOP 
  470 IF d=4 THEN RUN 
  480 GO TO 420
  500 LET W$="         "
  510 IF FD*(L(PS))<-10 THEN LET W$="Off chart bottem"
  520 IF FD*(L(PS))>10 THEN LET W$="Off chart top"
  560 PRINT AT A0,A0;P$(PS);":IN ";C$;" ";W$'"on ";M;"-";DY;"-";Y
  570 IF W$( TO PI)="Off" THEN GO TO 590
  580 PRINT AT 2,A0;"As displayed on chart below."
  590 LET w$="         ": RETURN 
 1000 LET i=A1: REM SUB2 
 1010 FOR J=A1 TO 9
 1020 LET A=NI*P(J,A1)+P(J,2)
 1030 IF A>P2 THEN LET A=((A/P2)-INT (A/P2))*P2
 1040 IF A<A0 THEN LET A=A+P2: GO TO 1030
 1050 LET C=P(J,3)*SIN (A-P(J,4)): LET A=A+C
 1068 IF A>P2 THEN LET A=A-P2
 1070 IF A<A0 THEN LET A=A+P2: GO TO 1060
 1080 LET D=P(J,5)+P(J,6)*SIN (A-P(J,7))
 1090 LET L=P(J,8)*SIN (A-P(J,9))
 1100 LET A(I)=A: LET D(I)=D: LET L(I)=L: LET I=I+A1
 1110 NEXT J
 1120 FOR I=A1 TO 9: REM SUB3 
 1130 IF I=3 THEN NEXT I
 1140 LET Z=A(3)-A(I)
 1150 IF ABS (Z)>PI AND Z<A0 THEN LET Z=Z+P2
 1160 IF ABS (Z)>PI AND Z>A0 THEN LET Z=Z-P2
 1170 LET Q=SQR (D(I)^2+D(3)^2-2*D(I)*D(3)*COS (Z))
 1180 LET P=(D(I)+D(3)+Q)/2
 1190 LET X=2*ACS (SQR (((P*(P-D(I)))/(D(3)*Q))))
 1200 IF Z<A0 THEN LET R=57.29578*(A(3)+PI-X)/15: LET V=SIN (A(3)+PI-X)*23.44194+FD*L(I)
 1210 IF Z>A0 THEN LET R=57.29578*(A(3)+PI+X)/15: LET V=SIN (A(3)+PI+X)*23.44194+FD*L(I)
 1220 IF R>24 THEN LET R=R-24: IF R>24 THEN GO TO 1220
 1230 IF R<A0 THEN LET R=R+24: IF R<A0 THEN GO TO 1230
 1240 IF CHO THEN RETURN 
 1260 LET HA=T2-R
 1270 IF HA<-12 THEN LET HA=HA+24
 1280 IF HA>12 THEN LET HA=HA-24
 1290 LET HA=PI/180*HA*15: LET V=PI/180*V
 1300 LET CLA=COS (LA): LET SLA=SIN (LA)
 1310 LET AL=ASN (SIN (V)*SLA+COS (V)*CLA*COS (HA))
 1330 LET AZ=ACS (SIN (V)-SLA*SIN (AL))/(CLA*COS (AL))
 1350 IF HA>A0 THEN LET AZ=PI*2-AZ
 1360 LET AL=180/PI*AL: LET AZ=180/PI*AZ
 1370 LET Q(I)=Q: LET R(I)=R: LET V(I)=V: IF CHO THEN NEXT I: RETURN 
 1380 LET B(I)=AL: LET Y(I)=AZ: NEXT I
 1390 REM PLACE SUN e 
 1400 LET RS=180/PI*(A(3)+PI)/15
 1410 IF RS>24 THEN LET RS=RS-24: IF RS>24 THEN GO TO 1410
 1420 IF RS<A0 THEN LET RS=RS+24: IF RS<A0 THEN GO TO 1420
 1430 LET VS=SIN (A(3)+PI)*23.44194
 1440 LET HS=T2-RS
 1450 IF HS<-12 THEN LET HS=HS+24
 1460 IF HS>12 THEN LET HS=HS-24
 1470 LET HS=PI/180*HS*15: LET VS=PI/180*VS
 1480 LET AS=ASN (SIN (VS)*SLA+COS (VS)*CLA*COS (HS))
 1500 LET ZS=ACS (SIN (VS)-SLA*SIN (AS))/(CLA*COS (AS))
 1520 IF HS>A0 THEN LET ZS=PI*2-ZS
 1530 LET AS=180/PI*AS: LET ZS=180/PI*ZS
 1540 LET B(3)=AS: LET Y(3)=ZS
 1550 REM LOCATE MOON
 1560 LET LP=255.7433: LET LZ=311.1687
 1570 LET LE=178.699
 1580 LET LM=LZ+360*NI/27.32158: LET LM=(LM/360-INT (LM/360))*360
 1590 LET PG=.111404*NI+LP: LET PG=LM-((PG/360-INT (PG/360))*360)
 1600 LET DR=P2*(SIN (PI/180*PG))
 1610 LET LM=LM+DR: LET RQ=LM: LET RM=LM/15
 1620 IF RM>24 THEN LET RM=RM-24: IF RM>24 THEN GO TO 1620
 1630 IF RM<A0 THEN LET RM=RM+24: IF RM<A0 THEN GO TO 1630
 1640 LET AL=RQ-(LE-NI*.052954)
 1650 LET AL=(AL/360-INT (AL/360))*360
 1660 LET HE=5.1333*SIN (AL*PI/180)
 1670 LET DM=HE+23.1444*SIN (RQ*PI/180): LET HD=T2-RM
 1680 IF HD<-12 THEN LET HD=HD+24
 1690 IF HD>12 THEN LET HD=HD-24
 1700 IF HD>12 OR HD<-12 THEN RETURN 
 1710 LET HA=PI/180*HD*15: LET DM=PI/180*DM
 1720 LET ML=ACS (SIN (DM)*SLA+COS (DM)*CLA*COS (HA))
 1730 LET MZ=ACS (SIN (DM)-SLA*SIN (ML))/(CLA*COS (ML))
 1740 IF HA>A0 THEN LET MZ=PI*2-MZ
 1750 LET MZ=180/PI*MZ: LET ML=180/PI*ML
 1760 IF ML>85 OR ML<5 THEN RETURN 
 1770 LET MX=MZ: LET PM=RS+12-RQ/15
 1780 IF PM>24 THEN LET PM=PM-24
 1790 IF PM>12 THEN LET PM=PM-24
 1800 IF PM>=-2 AND PM<=2 THEN LET P$(10)="O"
 1810 IF LA<A0 THEN GO TO 1850
 1820 IF PM<-2 THEN LET P$(10)="b"
 1830 IF PM>2 THEN LET P$(10)="a"
 1840 RETURN 
 1850 IF PM<-2 THEN LET P$(10)="a"
 1860 IF PM>2 THEN LET P$(10)="b"
 1870 LET B(10)=ML: LET Y(10)=MZ: RETURN 
 2000 REM PLANET FINDER
 2010 LET NM=NI-.4
 2020 LET PG=.111404*NM+255.7433
 2030 LET LMD=311.1687+360*NM/27.32158
 2040 LET PG=((LMD-PG)/360-INT ((LMD-PG)/360))*360
 2050 LET DR=P2*SIN (FR*PG)
 2060 LET LMD=((LMD+DR)/360-INT ((LMD+DR)/360))*360
 2070 LET R(10)=LMD/15
 2080 LET AL=178.699-NM*.052954
 2090 LET AL=LMD-(AL/360-INT (AL/360))*360
 2110 IF AL<A0 THEN LET AL=AL+360
 2120 IF AL>360 THEN LET AL=AL-360
 2130 LET HE=5.1454*(SIN (AL*FR))
 2140 LET L(10)=HE*FR
 2150 LET V(10)=HE+23.1444*SIN (LMD*FR)
 2160 GO SUB 1E3
 2170 LET X=57.29578*X
 2180 LET R(3)=(FD*A(3)-180)/15
 2190 IF R(3)<A0 THEN LET R(3)=R(3)+24
 2200 IF R(3)>24 THEN LET R(3)=R(3)-24
 2210 LET V(3)=(SIN (FR*(A(3)-180)))*23.44194
 2220 LET L(3)=A0: GO SUB 1370 
 2230 CLS : PRINT ''p$(ps, TO 8);"On.. ";M;"-";DY;"-";Y
 2240 PLOT A0,147: DRAW 180,A0
 2250 PRINT '"          R.A.   DEC."'"          Hrs.   Deg."
 2260 PLOT A0,123: DRAW 180,A0
 2270 PRINT 'P$(PS);
 2271 LET Len=LEN STR$ R(PS): IF Len>5 THEN LET Len=5
 2272 PRINT (STR$ (R(PS)))( TO Len);
 2273 LET Len=LEN STR$ v(PS): IF Len>5 THEN LET Len=5
 2274 PRINT ,(STR$ (V(PS)))( TO Len)
 2290 PLOT A0,107: DRAW 180,A0
 2295 INPUT "1. COPY     2. SKY VEIW   ";D: IF D=1 THEN COPY 
 2300 CLS : LET RA=R(PS)
 2310 FOR f=24 TO 2 STEP -2: IF RA<F THEN LET CA=F-2: NEXT F
 2320 LET RA=(RA-CA)*15: LET CH=(CA+2)/2
 2330 IF (RA-INT (RA))>.49 THEN LET RA=A1+INT (RA)
 2340 LET PL=31-(INT (1.1*RA))
 2350 LET CF=10-FD*L(PS)
 2360 PLOT A0,92: DRAW 255,A0
 2370 IF CH>=A1 AND CH<=12 THEN GO TO 2350+50*CH
 2380 PRINT #1;"error somewhere": PAUSE A0: STOP 
 2400 LET C$="PISCES": GO SUB 500
 2410 PRINT AT 5,7;"k";TAB 28;"*"''',"k";TAB 15;"k"''"    k"
 2420 PRINT AT 13,6;"k"''''"    k"'TAB 28;"k"
 2430 GO TO 4e3
 2450 LET C$="ARIES": GO SUB 500
 2460 PRINT AT PI,24;"X"'TAB 28;"*";TAB 28;"*"'''"   kff     k";AT 13,28;"k";TAB 22;"k";''"    *       kk"'TAB 25;"k"'',"  *     *"
 2470 GO TO 4e3
 2500 LET C$="TAURUS": GO SUB 500
 2510 PRINT AT 4,8;"*";AT 11,7;"*       k       k"'TAB 24;"k"''TAB 22;"Xf k"''''',"k";TAB 8;"k","k"
 2520 GO TO 4e3
 2550 LET C$="GEMINI": GO SUB 500
 2560 PRINT AT 4,5;"*"'TAB 7;"k"'"     k"'," *"''TAB 12;"*"''TAB 15;"k        * *";TAB 24;"k"''TAB 20;"*"'''," k"'''TAB 15;"*"
 2570 GO TO 4e3
 2600 LET C$="CANCER": GO SUB 500
 2610 PRINT AT 7,20;"k";TAB 20;"k"''''"     *"'TAB 15;"k"'''TAB 14;"* *"'TAB 20;"k  *";TAB 10;"k"," k"'TAB 15;"k"'," k"
 2620 GO TO 4E3
 2650 LET C$="LEO": GO SUB 500
 2660 PRINT AT PI,15;"*";TAB 28;"*";TAB 12;"k"'"  k";TAB 29;"k"'"      k"''TAB 11;"k   k"'"  *";TAB 22;"k     X"'''"      k"''''TAB 10;"k"
 2670 GO TO 4E3
 2700 LET C$="VIRGO": GO SUB 500
 2710 PRINT AT PI,11;"*","    *"'''',"     *"''TAB 14;"k";TAB 26;"*"'''TAB 11;"X";AT 19,19;"*"
 2720 GO TO 4E3
 2750 LET C$="LIBRA": GO SUB 500
 2760 PRINT AT 4,15;"*"'''''," *";AT 17,17;"k"
 2770 GO TO 4E3
 2800 LET C$="SCORPIO": GO SUB 500
 2810 PRINT AT PI,7;"k   k"''TAB 8;"*     *"'''TAB 28;"*"'''TAB 29;"*";TAB 23;"*";TAB 21;"X"'TAB 29;"k"
 2820 PRINT TAB 20;"*"'''',"*": GO TO 4E3
 2850 LET C$="SAGITTARIUS": GO SUB 500
 2860 PRINT AT 8,23;"k";TAB 14;"k k"'''TAB 24;"*"',;" *"',"   k"',"   *";TAB 15;"*"'''''TAB 24;"*"
 2870 GO TO 4E3
 2950 LET C$="CAPRICORNUS": GO SUB 500
 2960 PRINT AT PI,5;"*"'TAB 15;"k       *"''TAB 23;"*"'''''TAB 11;"k   *"'"     * *"'''TAB 10;"kk"
 2970 PRINT AT 16,20;"k";TAB 15;"k   k"
 2980 GO TO 4E3
 3000 LET C$="AQUARIUS": GO SUB 500
 3010 PRINT AT PI,6;"k    k";TAB 25;"*"'"    k    k","   *  *";AT 11,17;"k"'''TAB 14;"kk"'TAB 20;"*"''TAB 20;"*"'" *"
 4000 IF CF<A0 OR CF>20 THEN GO TO 4020
 4010 PRINT AT CF,PL;Q$(PS)
 4020 FOR N=A1 TO 10
 4040 IF N=PS THEN GO TO 4130
 4050 LET R2=R(N)-(CH*2-2)
 4060 IF R2<A0 OR R2>1.9999 THEN GO TO 4130
 4070 LET PL=R2*15
 4080 IF (PL-INT (PL))>.49 THEN LET PL=A1+INT (PL)
 4090 LET PL=31-INT (1.1*PL)
 4100 LET CF=10-FD*(L(N))
 4110 IF CF<A0 OR CF>20 THEN GO TO 4130
 4120 PRINT AT CF,PL;Q$(N)
 4130 NEXT N
 4140 INPUT "Do you want a  COPY ? ";D$: IF D$="" THEN GO TO 4140
 4150 IF D$(A1)="y" THEN COPY 
 4160 INPUT "Another planet (y/n)? ";D$: IF D$="" THEN GO TO 4160
 4190 IF d$(1)="y" THEN GO TO 9e3
 4200 STOP 
 7000 INPUT "Enter the Date (year eg. 1984)  ";Y: REM INPUT DATES
 7010 INPUT "Enter the Date (month eg. 6)    ";M
 7020 IF M<A1 OR M>12 THEN GO TO 7010
 7030 INPUT "Enter the Date (day eg. 20)     ";DY
 7040 IF DY<A1 OR DY>31 THEN GO TO 7030
 7050 IF M=2 AND DY>29 THEN GO TO 7030
 7060 IF fl AND NOT cho THEN GO TO 8570
 7070 RETURN 
 8000 REM SETUP
 8010 LET a0=0: LET a1=1: BORDER A0: PAPER A0: CLS : INK 7
 8020 PRINT AT PI,6;"Skyplot"',"Find Planets": PLOT 15,147: GO SUB 8300
 8030 PLOT 114,139: GO SUB 8300
 8040 PRINT '''"       An Astronomy Program"'''''"* ERIC BURGESS F.R.A.S. and","   S AND T Software"'''"* mods by ""PEH SOFTWARE"""
 8045 FOR F=A0 TO 47: READ A: POKE USR "a"+F,A: NEXT F
 8050 DATA 24,12,PI,PI,PI,PI,12,24,48,96,192,192,192,192,96,48
 8060 DATA 8,16,8,16,8,16,8,255,A0,48,72,72,48,A0,A0,A0
 8070 DATA 8,126,126,255,255,126,126,24,A0,24,24,A0,A0,24,24,A0,10
 8080 READ A: DIM U(A): DIM P(A,A): DIM A(A): DIM D(A): DIM L(A): DIM Q(A): DIM R(A): DIM V(A): DIM K(A)
 8090 DIM A$(A): DIM B(A): DIM Y(A): DIM E(A)
 8100 DATA A0,A0,A0,24,24,A0,A0,A0: FOR F=A0 TO 7: READ A: POKE USR "k"+F,A: NEXT F
 8110 DATA 2*PI,57.29578,.01745328: READ P2,FD,FR
 8120 LET D$=".071422,3.8484 ,.388301,1.34041,.3871  ,.07974 ,2.73514,.122173,.836013"
 8130 LET D$=D$+" .027962,3.02812,.013194,2.28638,.7233  ,.00506 ,3.85017,.059341,1.33168"
 8140 LET D$=D$+" .017202,1.74022,.032044,1.78547,1      ,.017   ,3.33926,0      ,0      "
 8150 LET D$=D$+" .009146,4.51234,.175301,5.85209,1.5237 ,.141704,1.04656,.03142 ,.858702"
 8160 LET D$=D$+" .00145 ,4.53364,.090478,.23911 ,5.2028 ,.249374,1.76188,.01972 ,1.74533"
 8170 LET D$=D$+" .000584,4.89884,.105558,1.61094,9.5385 ,.534156,3.1257 ,.043633,1.97746"
 8180 LET D$=D$+" .000205,2.46615,.088593,2.96706,19.182 ,.901554,4.49084,.01396 ,1.28805"
 8190 LET D$=D$+" .000104,3.78556,.016965,.773181,30.06  ,.27054 ,2.33498,.031416,2.29162"
 8200 LET D$=D$+" .000069,3.16948,.471239,3.91303,39.44  ,9.86   ,5.23114,.300197,1.91812"
 8210 FOR U=A1 TO 9
 8220 FOR K=A1 TO 9
 8230 LET P(U,K)=VAL D$( TO 7): LET D$=D$(9 TO )
 8240 NEXT K: NEXT U
 8250 PRINT AT 10,A0;"1. Skyplot plots the locations  of the planets, moon, and sun asthey appear in the sky for any  location, time, and date you    choose.",,
 8260 PRINT ''"2. Find Planets plots a planet, the sun, or moon among the      Zodiacal constellations for any date."
 8270 INPUT "CHOOSE 1 OR 2 ";CHO: LET CHO=CHO-A1: IF CHO>A1 THEN GO TO 8270
 8280 IF CHO THEN GO TO 9e3: REM FIND PLANETS
 8290 GO TO 8500: REM SKYPLOT
 8300 DRAW 24,8: DRAW 72,A0: DRAW 24,-8: DRAW -24,-8: DRAW -72,A0: DRAW -24,8: RETURN 
 8500 REM SKYPLOT DIRECTIONS
 8510 CLS : PRINT 'TAB 13;"SKYPLOT"''"Planets are identified as..."''"   Sun_______ e"'"   Mercury___ +"'"   Venus_____ V       Moon","   Jupiter___ J  Before full a"'"   Saturn____ S  Near full  o"'"   Uranus____ U  After full  b"'"   Neptune___ N"'"   Pluto_____ P"
 8520 PRINT ''"You can change Latitude and"'"Longitude when asked. Then you"'"enter the date: year, then"'"month, then day,"'"(eg. 1984, (enter) 6, (enter)"'"26 (enter))."
 8530 PRINT #A1;"Press enter TO CONTINUE ": PAUSE A0
 8540 CLS : PRINT ''"Next you entev the Time Zone and"'"the local time in Dec. Hrs."'"Finally; Select the Horizon you want to observe."
 8550 PRINT '"NOTE: If 2 planets are too closetogeather in the sky the outer  planet will overprint the inner planet."
 8570 LET P$="+VOMJSUNP ": LET FL=A0
 8590 LET LA=39.45: LET LO=86.15: IF CHO THEN RETURN  : REM INDIANAPOLIS 
 8600 PRINT '"Initial conditions are set for"''"Latitude   ";LA''"Longitude  ";LO: IF INT la=39 AND INT lo=86 THEN PRINT 'TAB 8;"( Indianapolis )"
 8610 INPUT "Want to change them? (y/n) ";D$
 8620 IF d$(A1)="n" THEN GO TO 8650
 8630 INPUT "Enter new Latitude ";LA
 8640 INPUT "Enter new Longitude ";LO: GO TO 8600
 8650 LET LS=LA: LET LA=PI/180*LA
 8660 GO SUB 7E3
 8670 INPUT "Enter Time Zone (Max -12 OR +12)";TZ
 8680 IF TZ<-12 OR TZ>12 THEN GO TO 8670
 8690 LET DS=DY: INPUT "Enter LMT (hrs) (0 TO 24) ";T1
 8700 IF T1<A0 OR T1>24 THEN GO TO 8690
 8710 PRINT '"Select the Horizon for viewing"''"EAST     0d TO 180d (1)  DEGREES"'"WEST   180d TO 360d (2)     """'"SOUTH   90d TO 270d (3)     """'"NORTH  270d TO  90d (4)     """
 8720 INPUT "ENTER no. of veiw ";HZ: IF HZ<A1 OR HZ>4 THEN GO TO 8720
 8730 CLS : PRINT '''"Please wait for the screen setup": IF CHO THEN RETURN 
 8740 GO TO 10
 9000 CLS : PRINT 'TAB 10;"FIND PLANETS": DIM p$(10,10)
 9010 PRINT ''"Because of screen resolution    limitations right ascension and declination of the chosen planetsun or moon are given before theZodiacal Star Chart is shown on the screen."
 9020 PRINT '"An ecliptic line will be drawn  across the chart.": LET FL=A0
 9030 GO SUB 7e3: GO SUB 8590: PRINT '"Longitude= ";LO;" (Indianapolis)": INPUT " INPUT LONGITUDE ";LO
 9040 LET M$="MercuryVenus  Sun    Mars   JupiterSaturn Uranus NeptunePLuto  Moon   "
 9050 FOR f=A1 TO 10: LET p$(f)=M$( TO 7): LET M$=M$(8 TO ): NEXT f
 9060 PRINT '"  (+) MERCURY  1","  (V) VENUS    2","  (e) SUN      3","  (M) MARS     4","  (J) JUPITER  5","  (S) SATURN   6","  (U) URANUS   7","  (N) NEPTUNE  8","  (P) PLUTO    9","  (a) MOON    10"
 9070 INPUT "Enter the number of your choice ";PS
 9080 IF PS<A1 OR PS>10 THEN GO TO 9070
 9090 LET Q$="+VOMJSUNPa": LET DL=DY+24/LO: GO SUB 10
 9100 GO SUB 8730: GO TO 2e3
 9999 SAVE "st1" LINE PI

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.