-
Notifications
You must be signed in to change notification settings - Fork 8
/
Copy pathCurve.f
executable file
·80 lines (63 loc) · 2.25 KB
/
Curve.f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
subroutine curve
c******************************************************************************
c This routine produces a curve-of-growth for a single line
c******************************************************************************
implicit real*8 (a-h,o-z)
include 'Atmos.com'
include 'Linex.com'
include 'Pstuff.com'
c*****set up the parameters
ewsynthopt = -1
ncurve = 1
dec = 10.**(rwstep)
wstart = 10.**(rwlow)*wave1(lim1)
wstop = 10.**(rwhigh)*wave1(lim1)
gf1(ncurve) = gf(lim1)
c*****increment the log(gf) value backward by rwstep and redo the calculations
c until the end (rwlow) is reached
31 call oneline (2)
if (w(ncurve) .gt. wstart) then
gf1(ncurve) = gf1(ncurve)/dec
do i=1,ntau
kapnu0(lim1,i) = kapnu0(lim1,i)/dec
enddo
go to 31
endif
go to 61
c*****increment the log(gf) value forward by rwstep and redo the calculations
c until the end (rwhigh) is reached
60 gf1(ncurve) = gf1(ncurve-1)*dec
do i=1,ntau
kapnu0(lim1,i) = kapnu0(lim1,i)*dec
enddo
61 call oneline (2)
if (w(ncurve) .lt. wstop) then
ncurve = ncurve + 1
go to 60
endif
c*****end the computations with a summary print
if (nf2out .ne. 0 .and. lim1 .eq. 1)
. write (nf2out,1001) moditle
do i=1,ncurve
w(i) = dlog10(w(i)/wave1(lim1))
gf1(i) = dlog10(gf1(i))
enddo
iatom = atom1(lim1)
if(iatom .ge. 100) iatom = 1
abund = dlog10(xabund(iatom)) + 12.
write (nf1out,1002) wave1(lim1),atom1(lim1),e(lim1,1),
. abund,ncurve
write (nf1out,1003) (gf1(i),w(i),i=1,ncurve)
if (nf2out .eq. 0) return
write (nf2out,1002) wave1(lim1),atom1(lim1),e(lim1,1),
. abund,ncurve
write (nf2out,1003) (gf1(i),w(i),i=1,ncurve)
return
c*****format statements
1001 format (a80)
1002 format(/'wavelength =', f9.3,5x, 'species =', f6.1,5x, 'ep =',
. f7.3, 'abundance =', f10.3, 5x, 'n =',i2)
1003 format(' curve of growth in (loggf,logrw) pairs'/
. (5(f7.3,',',f7.3)))
1004 format (10f7.3)
end