COSMOS v7.655  COSMOSv7655
(AirShowerMC)
cllh2eCent.f
Go to the documentation of this file.
1  subroutine cllh2ecent(llh, xyz)
2 ! llh: /coord/ structure. input. containing data in latitude,
3 ! longitude, height.
4 ! xyz: /coord/ structue. output. The coordinate system is
5 ! such that the origin is at the center of the earth
6 ! x-axis is directed to (0, 0) latitude and longitude.
7 ! y-axis is directed to (0, 90) latitude and longitude.
8 ! z-axsi is directed to the north pole.
9 !
10 ! xyz.r(1) is x coordinate value in m
11 ! xyz.r(2) is y
12 ! xyz.r(3) is z
13 ! *** note ***
14 ! xyz can be the same as llh. time component is unchanged
15 !
16  implicit none
17 #include "Zglobalc.h"
18 
19 #include "Zcoord.h"
20 #include "Zearth.h"
21  type(coord)::llh
22  type(coord)::xyz
23  type(coord)::temp
24 !
25  real*8 nh
26 #include "Zcoordtype.h"
27 ! ecentricity =0
28 #ifdef UNIONMAP
29  nh = eradius + llh%h
30  temp%x = nh * cos(llh%lat*torad)* cos(llh%long*torad)
31  temp%y = nh * cos(llh%lat*torad)* sin(llh%long*torad)
32  xyz%r(3) = nh * sin(llh%lat * torad)
33  xyz%r(1) = temp%x
34  xyz%r(2) = temp%y
35 #else
36  nh = eradius + llh%r(3)
37  temp%r(1) = nh * cos(llh%r(1)*torad)* cos(llh%r(2)*torad)
38  temp%r(2) = nh * cos(llh%r(1)*torad)* sin(llh%r(2)*torad)
39  xyz%r(3) = nh * sin(llh%r(1) * torad)
40  xyz%r(1) = temp%r(1)
41  xyz%r(2) = temp%r(2)
42 #endif
43  xyz%sys = coord_types(1)
44  end
subroutine cllh2ecent(llh, xyz)
! for length to thickness conversion or v v ! integer maxnodes real Hinf ! This is used when making table for dim simulation ! The slant length for vertical height to km is ! divided by LenStep m steps ! It can cover the slant length of about km for cos
Definition: Zatmos.h:8
integer max_coord_types * coord_types(2)/'llh'/
Definition: Zcoord.h:43