|
- 10 REM VERTICAL SUNDIALS
- 11 INPUT "LAT, LONG ";B,L
- 12 IF B<0 THEN 11
- 13 INPUT "TIME-ZONE MERIDIAN";L0
- 14 INPUT "AZIMUTH DIAL FACES";F
- 15 IF F<=90 OR F>=270 THEN 14
- 16 P1=3.14159265: R1=P1/180
- 17 B1=B*R1: S=0
- 18 INPUT "SUN E OR W";S$
- 19 IF S$="E" THEN S=-1
- 20 IF S$="W" THEN S=1
- 21 IF S=0 THEN 18
- 22 INPUT "DIAL HEIGHT";H5
- 23 INPUT "WIDTH OF THIS PART";W5
- 24 INPUT "STEP SIZE IN MIN";G
- 25 F1=P1/2+S*R1*(180-F): PRINT
- 26 R5=W5/H5: Z5=S*R1*(L0-L)
- 27 PRINT "LAT: ";B;" LONG: ";L;
- 28 PRINT " MERID: ";L0
- 29 PRINT "DIAL FACES AZIMUTH ";F
- 30 GOSUB 73
- 31 PRINT "SUN ";S$;" ";W5;
- 32 PRINT "WIDE BY";H5;"HIGH"
- 33 PRINT: H=12-S: G=S*G/60
- 34 REM
- 35 REM CALCULATING LOOP
- 36 Q=Z5+S*P1*(H-12)/12
- 37 IF Q<0 THEN 47
- 38 IF H<4 OR H>20 THEN 48
- 39 IF Q<>0 THEN 41
- 40 K=0: GOTO 45
- 41 K0=SIN(F1)*TAN(P1/2-Q)
- 42 K1=COS(F1)*SIN(B1)+K0
- 43 IF K1=0 THEN K1=1E-10
- 44 K=COS(B1)/K1
- 45 GOSUB 52
- 46 IF K>=0 THEN GOSUB 57
- 47 H=H+G: GOTO 35
- 48 PRINT
- 49 INPUT "AGAIN (Y OR N)";Q$
- 50 S=0: IF Q$="Y" THEN 18
- 51 END
- 52 REM DECIDE X OR Y
- 53 D=S*K*H5: D$=" X="
- 54 IF K<R5 THEN 56
- 55 D=-W5/K: D$=" *Y="
- 56 RETURN
- 57 REM PRINT A LINE
- 58 H0=H+0.002
- 59 H1=INT(H0): M1=INT(60*(H0-H1))
- 60 M1$=STR$(100+M1)
- 61 M1$=":"+RIGHT$(M1$,2)
- 62 P$=" PM "
- 63 IF H1<12 THEN P$=" AM "
- 64 IF H1<>12 THEN 66
- 65 IF M1=0 THEN P$=" NOON"
- 66 IF H1>12 THEN H1=H1-12
- 67 H1$=STR$(H1)
- 68 IF H1<10 THEN H1$=" "+H1$
- 69 D=INT(D*1000+0.5)/1000
- 70 PRINT H1$;M1$;P$;
- 71 PRINT TAB(15);D$;D
- 72 RETURN
- 73 REM COMPUTE END OF STYLE
- 74 P5=TAN(P1/2-B1)*H5
- 75 Z=SIN(F1)*P5
- 76 Z=INT(Z*1000+0.5)/1000
- 77 X=S*TAN(P1/2-F1)*Z
- 78 X=INT(X*1000+0.5)/1000
- 79 Y=-H5
- 80 PRINT "STYLE END COORDINATES:"
- 81 PRINT "X=";X;", Y=";Y;", Z=";Z
- 82 RETURN
- 83 REM *************************
- 84 REM FROM "ASTRONOMICAL COM-
- 85 REM PUTING," SKY & TELESCOPE
- 86 REM DECEMEBR, 1987
- 87 REM *************************
|