COSMOS v7.655  COSMOSv7655
(AirShowerMC)
cmPairMFP.f File Reference

Go to the source code of this file.

Functions/Subroutines

real *8 function cmpairmfp (eg, xai)
 
real *8 function cmpairint1 (xai)
 

Function/Subroutine Documentation

◆ cmpairint1()

real*8 function cmpairint1 ( real*8  xai)

Definition at line 33 of file cmPairMFP.f.

References e.

33  implicit none
34 ! compute the integral part of Eq. (16) of Baring; Mon. Not. R.
35 ! astr.Soc. (1988) 235., i,e.
36 ! inte(0,1) dv (9-v**2)/(1-v**2)K23(y).
37 ! The numerical integration has been done by inteSpecPair.f
38 ! and the result is normalized as follows
39 !
40 ! For xai < 4: log(xai) vs ans/(7.497xai*exp(-4/3/xai)) is approximated by
41 ! a polynomial
42 ! for xai > 4: log(xai) vs ans/ xai**0.6666 is approximated by
43 ! a polynomial.
44 !
45  real*8 xai
46 !
47  real*8 ans, lxai
48 !
49  if(xai .lt. .01) then
50  ans =7.497*xai*exp(-4./3./xai)
51  elseif(xai .lt. 4.0) then
52  lxai = log(xai)
53  ans =(( -0.7211221e-03*lxai -0.1692442e-01)* lxai
54  * -0.9929865e-01 )*lxai + 0.8214562
55  ans = 7.497*xai* exp(-4./3./xai)* ans
56  elseif(xai .lt. 5000.) then
57  lxai = log(xai)
58 
59  ans = (((( 0.2210200e-03*lxai -0.8950944e-02)*lxai
60  * + 0.1461679 )*lxai -1.218747)*lxai +5.274929)*lxai
61  * + 0.1683762
62  ans = ans * xai**0.66666
63  else
64  ans = 9.8*xai**0.66666
65  endif
66  cmpairint1 = ans
dE dx *! Nuc Int sampling table e
Definition: cblkMuInt.h:130
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 cmpairint1(xai)
Definition: cmPairMFP.f:33

◆ cmpairmfp()

real*8 function cmpairmfp ( real*8  eg,
real*8  xai 
)

Definition at line 4 of file cmPairMFP.f.

References parameter().

4  implicit none
5 #include "Zglobalc.h"
6 
7  real*8 eg ! input. gamma energy in GeV
8  real*8 xai ! input. xai value = Eg/m * H/Hc/2
9 
10  real*8 alpha, cmpairint1
11  real*8 const
12  parameter(const = 3. * 1.73205 * 3.1415 )
13 
14 ! SyncConvR is in GeV/m
15  alpha = cmpairint1(xai)* syncconvr/ eg /const
16  cmpairmfp = 1./alpha
integer npitbl real *nx parameter(n=101, npitbl=46, nx=n-1) real *8 uconst
real *8 function cmpairint1(xai)
Definition: cmPairMFP.f:33
real *8 function cmpairmfp(eg, xai)
Definition: cmPairMFP.f:4
Here is the call graph for this function: