source: trunk/LMDZ.GENERIC/libf/phystd/planete_mod.F90 @ 1351

Last change on this file since 1351 was 1315, checked in by milmd, 10 years ago

LMDZ.GENERIC. OpenMP directives added in generic physic. When running in pure OpenMP or hybrid OpenMP/MPI, may have some bugs with condense_cloud and wstats routines.

File size: 1.3 KB
Line 
1MODULE planete_mod
2  IMPLICIT NONE
3 
4  REAL :: apoastr ! maximum star-planet distance (AU)
5  REAL :: periastr ! minimum star-planet distance (AU)
6  REAL :: year_day ! length of year (sols)
7  REAL :: peri_day ! date of periastron (sols since N. spring)
8  REAL :: obliquit ! Obliquity of the planet (deg)
9  REAL :: nres ! tidal resonance ratio
10  REAL :: z0 ! surface roughness (m)
11  REAL :: lmixmin ! mixing length
12  REAL :: emin_turb ! minimal energy
13  REAL :: coefvis
14  REAL :: coefir
15  REAL :: timeperi
16  REAL :: e_elips
17  REAL :: p_elips
18 
19  REAL :: preff ! reference surface pressure (Pa)       !read by master
20  REAL,ALLOCATABLE :: ap(:) ! hybrid coordinate at layer interface      !read by master
21  REAL,ALLOCATABLE :: bp(:) ! hybrid coordinate at layer interface      !read by master
22 
23  CONTAINS
24 
25  subroutine ini_planete_mod(nlayer,preff_dyn,ap_dyn,bp_dyn)
26 
27  implicit none
28  integer,intent(in) :: nlayer ! number of atmospheric layers
29  real,intent(in) :: preff_dyn ! reference surface pressure (Pa)
30  real,intent(in) :: ap_dyn(nlayer+1) ! hybrid coordinate at interfaces
31  real,intent(in) :: bp_dyn(nlayer+1) ! hybrid coordinate at interfaces
32 
33!$OMP MASTER
34  allocate(ap(nlayer+1))
35  allocate(bp(nlayer+1))
36 
37  preff=preff_dyn
38  ap(:)=ap_dyn(:)
39  bp(:)=bp_dyn(:)
40!$OMP END MASTER
41!$OMP BARRIER
42 
43  end subroutine ini_planete_mod
44 
45END MODULE planete_mod
Note: See TracBrowser for help on using the repository browser.