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

Go to the source code of this file.

Functions/Subroutines

subroutine csetpos (location)
 
subroutine csetpos2 (h, d, location)
 

Function/Subroutine Documentation

◆ csetpos()

subroutine csetpos ( type(position location)

Definition at line 8 of file csetPos.f.

References cerrormsg().

Referenced by cmkinc(), cmkinc2(), cmovestreight(), and cputdeflection().

8 !
9  implicit none
10 #include "Zobs.h"
11 #include "Zcoord.h"
12 #include "Zpos.h"
13 #include "Zearth.h"
14 !
15  type(position)::location
16  real*8 cvh2thick
17  character*70 msg
18 !
19  if(location%xyz%sys .ne. 'xyz') then
20  write(msg, *) ' error coord. sys to csetPos=', location%xyz%sys
21  call cerrormsg(msg, 0)
22  endif
23  location%radiallen =
24  * sqrt(location%xyz%r(1)**2 + location%xyz%r(2)**2 +
25  * location%xyz%r(3)**2)
26  location%height = location%radiallen - eradius
27  location%depth = cvh2thick(location%height)
subroutine cerrormsg(msg, needrtn)
Definition: cerrorMsg.f:4
Definition: Zpos.h:16
real *8 function cvh2thick(z)
Definition: ciniSegAtoms.f:93
Here is the call graph for this function:
Here is the caller graph for this function:

◆ csetpos2()

subroutine csetpos2 ( real*8  h,
real*8  d,
type(position location 
)

Definition at line 31 of file csetPos.f.

Referenced by cinitobs().

31 ! --------------------------------------
32 !
33  implicit none
34 !---- include 'Zobs.h'
35 #include "Zobs.h"
36 !---- include 'Zcoord.h'
37 #include "Zcoord.h"
38 #include "Zpos.h"
39 !---- include './Atmosphere/Zearth.h'
40 #include "Zearth.h"
41 !
42  real*8 h, d
43  type(position)::location
44 !
45  location%height = h
46  location%radiallen = h + eradius
47  location%depth = d
real(4), dimension(:), allocatable, save h
Definition: cNRLAtmos.f:28
dE dx *! Nuc Int sampling table d
Definition: cblkMuInt.h:130
Definition: Zpos.h:16
Here is the caller graph for this function: