home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Starbase One Astronomy & Space Collection
/
STARBASE_ONE.ISO
/
a94
/
disk16
/
exposure.exe
/
EXPOSSRC.BAS
next >
Wrap
BASIC Source File
|
1989-11-09
|
3KB
|
125 lines
10 cls
20 print "Astrophotographic Exposure Program."
30 print "-----------------------------------"
40 print
50 dim s(12),s$(12),p(3)
60 REM - Standard Shutter Speeds
70 data 0.0005,"1/2000",0.001,"1/1000",0.002,"1/500"
80 data 0.004,"1/250",0.008, "1/125"
90 data 0.016667,"1/60", 0.0333333,"1/30",0.0666667,"1/15"
100 data 0.125,"1/8",0.25,"1/4"
110 data 0.5,"1/2",1,"1"
120 rem shutter speeds are compared logarithmmically.
130 rem Base 10 or Base e equally OK.
160 for i=1 to 12
170 read s(i),s$(i)
180 let s(i)=log(s(i))
190 next i
200 rem List of objects and B values:
210 data "Moon (Thin Crescent)...",10
220 data "Moon (Wide Crescent)...",20
230 data "Moon (Quarter).........",40
240 data "Moon (Gibbous).........",80
250 data "Moon (Full)............",200
260 data "Mercury................",60
270 data "Venus..................",400
280 data "Mars...................",60
290 data "Jupiter................",30
300 data "Saturn.................",10
310 data "END"
320 rem You may add more objects, but the word 'END' must be last
325 rem and in CAPITAL letters.
330 rem - Obtain Parameters for this run:
340 print
350 print "System F-Ratio?"
360 input f
370 print
380 print "What is the speed of your film (ISO/ASA)?"
390 input a
400 print
410 print "What type of reciprocity correction is required?"
420 print
430 print "1. Typical fast film (eg Tri-X)"
440 print "2. Typical slow film (eg 2415)"
450 print "3. No correction (eg Hypersensitised or spectroscopic film)"
460 print
470 print "Please enter 1,2 or 3."
490 print
500 input c
510 if c>3 then 420
520 if c<1 then 420
525 rem p(c) is the schwartzchild exponent
530 let p(1)=.65
540 let p(2)=.8
550 let p(3)=1
560 print
570 print "Will you be using a filter? (Y/N)"
580 input r$
585 if len(r$)=0 then 570
588 let f1=1
590 if r$="n" then 670
600 if r$="N" then 670
610 if r$="no" then 670
620 if r$="NO" then 670
640 print
650 print "What is the filter factor?"
660 input f1
670 rem set up exposure table:
680 cls
883 print "Calculated exposure table for the following setup:"
887 print "--------------------------------------------------"
888 print
690 print "Film Speed is: ";a;" ISO."
700 print "F-Ratio is: ";F
710 print "Filter Factor is: ";f1
720 print
730 rem apply filter factor:
740 let a=a/f1
750 rem Main Loop
760 read n$
770 if n$="END" then 1060
780 print n$;
790 read b
800 rem exposure formula
810 let t=(f*f)/(a*b)
820 REM reciprocity correction
830 let t=(t+1)^(1/p(c))-1
840 rem Warn if estimated exposure is over 5 minutes
850 if t<300 then 890
860 Print "Over 5 minutes."
870 goto 750
880 rem if over 1.4 seconds then round and print it.
890 if t<1.4 then 930
900 print int (t+.5);" seconds."
910 goto 750
920 REM If under 1/2000 second then give a warning.
930 if t> 0.0005 then 960
940 Print "Under 1/2000 of a second."
950 goto 750
960 rem Find nearest standard shutter speed.
970 rem (on a logarithmic scale)
980 let l=log(t)
990 let s7=1
1000 for s9=2 to 12
1010 if abs(s(s9)-l)>abs(s(s7)-l) then 1030
1020 let s7=s9
1030 next s9
1040 print s$(s7);" second."
1050 goto 750
1060 rem termination:
1070 print
1080 print "Do you wish to run this program again? (Y/N)"
1090 input r$
1100 if r$="Y" then 1160
1110 if r$="y" then 1160
1140 end
1150 goto 1190
1160 cls
1170 restore
1180 goto 60
1190 end