6 subroutine chookbgrunas
30 open(13, file=
'cs', status=
'OLD')
37 read(13, *) noofcomps, ndepthcomp, e0comp
39 if(noofcomps .gt. ncs)
then 40 write(0, *)
'too many comp showers ' 44 * (depthcomp(
i),
i = 1, ndepthcomp)
47 read(13,*) (elecsizecomp(
i,
j),
j=1,ndepthcomp)
48 read(13,*) (elecagecomp(
i,
j),
j=1,ndepthcomp)
55 subroutine chooknepinta
75 integer i, recn, ios,
j 79 real*8 esizetemp(ndepthcompm), depstep, depfirst, dep
80 real*8 eagetemp(ndepthcompm)
94 recn = u* noofcomps + 1
100 depfirst = depthcomp(1)
101 depstep = depthcomp(2) - depthcomp(1)
106 esizetemp(
j) = elecsizecomp(recn,
j)
107 eagetemp(
j) = elecagecomp(recn,
j)
113 do j = 1, noofassites
114 zobs = asobssites(
j).pos.
depth 117 dep = zobs - movedtrack.pos.
depth 119 if(abs(cosz) .gt. 0.5)
then 134 dep =
t + firstcoldep
137 call kintp3(esizetemp, 1, ndepthcomp, depfirst,
143 call kintp3(eagetemp, 1, ndepthcomp, depfirst,
148 eno = 10.**
ans * movedtrack.
wgt 150 asobssites(
j).esize = asobssites(
j).esize + eno
153 asobssites(
j).age = asobssites(
j).age +
164 eno = 10.**
ans * movedtrack.
wgt 165 asobssites(
j).esize = asobssites(
j).esize + eno
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p *Zfirst pos xyz Zfirst pos xyz *Zfirst pos *Zfirst pos depth
subroutine cqinteptcl(ptclA, num)
atmos%rho(atmos%nodes) **exp(-(z-atmos%z(atmos%nodes))/Hinf) elseif(z .lt. atmos%z(1)) then ans=atmos%rho(1) **exp((atmos%z(1) -z)/atmos%H(1)) else call kdwhereis(z, atmos%nodes, atmos%z, 1, i) a=atmos%a(i) if(a .ne. 0.d0) then ans=atmos%rho(i) **(1+a *(z-atmos%z(i))/atmos%H(i)) **(-1.0d0-1.d0/a) else ans=*atmos%rho(i) *exp(-(z-atmos%z(i))/atmos%H(i)) endif endif ! zsave=z ! endif cvh2den=ans end ! ---------------------------------- real *8 function cvh2temp(z) implicit none ! vettical height to temperatur(Kelvin) real *8 z ! input. vertical height in m ! output is temperature of the atmospher in Kelvin real *8 ans integer i if(z .gt. atmos%z(atmos%nodes)) then ans=atmos%T(atmos%nodes) elseif(z .lt. atmos%z(1)) then ans=atmos%T(1)+atmos%b(1) *(z - atmos%z(1)) else call kdwhereis(z, atmos%nodes, atmos%z, 1, i) ans=atmos%T(i)+atmos%b(i) *(z-atmos%z(i)) endif cvh2temp=ans end !--------------------------------------------- real *8 function cthick2h(t) implicit none real *8 t ! input. air thickness in kg/m^2 real *8 logt, ans integer i real *8 dod0, fd, a logt=log(t) if(t .ge. atmos%cumd(1)) then ans=atmos%z(1) - *(logt - atmos%logcumd(1)) *atmos%H(1) elseif(t .le. atmos%cumd(atmos%nodes)) then ans=atmos%z(atmos%nodes) - *Hinf *log(t/atmos%cumd(atmos%nodes)) else call kdwhereis(t, atmos%nodes, atmos%cumd, 1, i) ! i is such that X(i) > x >=x(i+1) ans
real *8 function clen2thick(z, cosz, leng)
real *8 function clenbetween2h(h1, h2, cost)
********************block data cblkHeavy ********************integer j data *HeavyG2symbol *data *HeavyG2code kiron data j
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p *Zfirst pos xyz Zfirst pos xyz *Zfirst pos *Zfirst pos Zfirst pos height
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p *Zfirst pos xyz Zfirst pos xyz *Zfirst pos *Zfirst pos Zfirst pos *Zfirst pos *Zfirst Zfirst vec w *Zfirst vec w Zfirst vec coszenith
subroutine kintp3(f, intv, n, x1, h, x, ans)
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p *Zfirst pos xyz Zfirst pos xyz *Zfirst pos *Zfirst pos Zfirst pos *Zfirst pos *Zfirst Zfirst vec w *Zfirst vec w Zfirst vec *Zfirst wgt
*Zfirst p fm *Zfirst p Zfirst p Zfirst p *Zfirst p *Zfirst pos xyz Zfirst pos xyz *Zfirst pos radiallen