source: trunk/WRF.COMMON/INTERFACES/dynphy_wrf_mars_lmd/callphysiq_mod.F @ 3430

Last change on this file since 3430 was 1755, checked in by aslmd, 7 years ago

MESOSCALE MARS and VENUS. moved the interface arrays in a module named variables_mod.F in dynphy_wrf to get a greater flexibility for the various planets (regarding e.g. REAL 4 or 8). incidentally this makes module_lmd_driver being more modular and the interfacing between dynamics and physics is further simplified by the fields shared in variables_mod. compilation was checked on Mars but not on Venus

File size: 2.4 KB
Line 
1!
2! $Id: $
3!
4MODULE callphysiq_mod
5
6IMPLICIT NONE
7
8 !! ----------------------------------------------------------
9 !! ---- CALL TO MARS PHYSICS
10 !! ----------------------------------------------------------
11
12CONTAINS
13
14SUBROUTINE call_physiq(planet_type, klon,llm,nqtot,                       &
15                       debut_split,lafin_split)
16
17  USE variables_mod
18  USE physiq_mod, ONLY: physiq
19  IMPLICIT NONE
20
21  character(len=10),INTENT(IN) :: planet_type ! planet type ('earth','mars',...)
22
23  INTEGER,INTENT(IN) :: klon ! (local) number of atmospheric columns
24  INTEGER,INTENT(IN) :: llm  ! number of atmospheric layers
25  INTEGER,INTENT(IN) :: nqtot ! number of tracers
26  LOGICAL,INTENT(IN) :: debut_split ! .true. if very first call to physics
27  LOGICAL,INTENT(IN) :: lafin_split ! .true. if last call to physics
28
29!  ! Local variables
30!  CHARACTER(len=11) :: modname="call_physiq"
31!  LOGICAL,SAVE :: firstcall=.true.
32!!$OMP THREADPRIVATE(firstcall)
33!
34!! Sanity check on physics package type
35!  IF (firstcall) THEN
36!    IF (planet_type.ne."mars") THEN
37!      CALL abort_gcm(modname,"wrong planet_type for this physics package",1)
38!    ENDIF
39!    firstcall=.false.
40!  ENDIF
41
42! Sanity check on physics package type
43 IF (debut_split) THEN
44   IF (planet_type.ne."mars") THEN
45     PRINT*,"wrong planet_type for this physics package"
46     STOP
47   ENDIF
48 ENDIF
49
50! Set dummy variables for Mars to zero (additional and prob useless security)
51  zpk_omp(:,:)=0.
52  zphis_omp(:)=0.
53  presnivs_omp(:)=0.
54  zrfi_omp(:,:)=0.
55 
56! Call physics package with required inputs/outputs
57  CALL physiq(klon,           & ! ngrid
58              llm,            & ! nlayer
59              nqtot,          & ! nq
60              debut_split,    & ! firstcall
61              lafin_split,    & ! lastcall
62              jD_cur,         & ! pday
63              jH_cur_split,   & ! ptime
64              zdt_split,      & ! ptimestep
65              zplev_omp,      & ! pplev
66              zplay_omp,      & ! pplay
67              zphi_omp,       & ! pphi
68              zufi_omp,       & ! pu
69              zvfi_omp,       & ! pv
70              ztfi_omp,       & ! pt
71              zqfi_omp,       & ! pq
72              flxwfi_omp,     & ! flxw
73              zdufi_omp,      & ! pdu
74              zdvfi_omp,      & ! pdv
75              zdtfi_omp,      & ! pdt
76              zdqfi_omp,      & ! pdq
77              zdpsrf_omp)       ! pdpsrf
78
79
80END SUBROUTINE call_physiq
81
82END MODULE callphysiq_mod
Note: See TracBrowser for help on using the repository browser.