[1523] | 1 | MODULE iniphysiq_mod |
---|
| 2 | |
---|
| 3 | CONTAINS |
---|
| 4 | |
---|
[1543] | 5 | subroutine iniphysiq(ii,jj,nlayer, & |
---|
| 6 | nbp, communicator, & |
---|
| 7 | punjours, pdayref,ptimestep, & |
---|
| 8 | rlatudyn,rlatvdyn,rlonudyn,rlonvdyn, & |
---|
| 9 | airedyn,cudyn,cvdyn, & |
---|
[1216] | 10 | prad,pg,pr,pcpp,iflag_phys) |
---|
| 11 | |
---|
[1525] | 12 | use control_mod, only: nday |
---|
[1529] | 13 | use surf_heat_transp_mod, only: ini_surf_heat_transp |
---|
[1216] | 14 | use infotrac, only : nqtot ! number of advected tracers |
---|
[1308] | 15 | use planete_mod, only: ini_planete_mod |
---|
[1422] | 16 | USE comvert_mod, ONLY: ap,bp,preff |
---|
[1524] | 17 | use inifis_mod, only: inifis |
---|
[1529] | 18 | use ioipsl_getin_p_mod, only: getin_p |
---|
[1216] | 19 | |
---|
[1564] | 20 | use inigeomphy_mod, only: inigeomphy |
---|
[1563] | 21 | use geometry_mod, only: cell_area, & ! physics grid area (m2) |
---|
| 22 | longitude, & ! longitudes (rad) |
---|
| 23 | latitude ! latitudes (rad) |
---|
| 24 | ! necessary to get klon_omp |
---|
| 25 | USE mod_phys_lmdz_para, ONLY: klon_omp ! number of columns (on local omp grid) |
---|
[1573] | 26 | USE dimphy, ONLY: init_dimphy |
---|
[1563] | 27 | |
---|
[1216] | 28 | implicit none |
---|
[1308] | 29 | include "dimensions.h" |
---|
[1529] | 30 | include "paramet.h" |
---|
| 31 | include "comgeom.h" |
---|
[1395] | 32 | include "iniprint.h" |
---|
[1216] | 33 | |
---|
| 34 | real,intent(in) :: prad ! radius of the planet (m) |
---|
| 35 | real,intent(in) :: pg ! gravitational acceleration (m/s2) |
---|
| 36 | real,intent(in) :: pr ! ! reduced gas constant R/mu |
---|
| 37 | real,intent(in) :: pcpp ! specific heat Cp |
---|
| 38 | real,intent(in) :: punjours ! length (in s) of a standard day |
---|
| 39 | integer,intent(in) :: nlayer ! number of atmospheric layers |
---|
[1395] | 40 | integer,intent(in) :: ii ! number of atmospheric coulumns along longitudes |
---|
| 41 | integer,intent(in) :: jj ! number of atompsheric columns along latitudes |
---|
[1543] | 42 | integer,intent(in) :: nbp ! number of physics columns for this MPI process |
---|
| 43 | integer,intent(in) :: communicator ! MPI communicator |
---|
[1529] | 44 | real,intent(in) :: rlatudyn(jj+1) ! latitudes of the physics grid |
---|
| 45 | real,intent(in) :: rlatvdyn(jj) ! latitude boundaries of the physics grid |
---|
| 46 | real,intent(in) :: rlonvdyn(ii+1) ! longitudes of the physics grid |
---|
| 47 | real,intent(in) :: rlonudyn(ii+1) ! longitude boundaries of the physics grid |
---|
| 48 | real,intent(in) :: airedyn(ii+1,jj+1) ! area of the dynamics grid (m2) |
---|
| 49 | real,intent(in) :: cudyn((ii+1)*(jj+1)) ! cu coeff. (u_covariant = cu * u) |
---|
| 50 | real,intent(in) :: cvdyn((ii+1)*jj) ! cv coeff. (v_covariant = cv * v) |
---|
[1216] | 51 | integer,intent(in) :: pdayref ! reference day of for the simulation |
---|
| 52 | real,intent(in) :: ptimestep !physics time step (s) |
---|
| 53 | integer,intent(in) :: iflag_phys ! type of physics to be called |
---|
| 54 | |
---|
[1529] | 55 | logical :: ok_slab_ocean |
---|
[1216] | 56 | |
---|
[1563] | 57 | ! the common part for all planetary physics |
---|
| 58 | !------------------------------------------ |
---|
| 59 | ! --> initialize physics distribution, global fields and geometry |
---|
[1573] | 60 | ! (i.e. things in phy_common or dynphy_lonlat) |
---|
[1564] | 61 | CALL inigeomphy(ii,jj,nlayer, & |
---|
[1563] | 62 | nbp, communicator, & |
---|
| 63 | rlatudyn,rlatvdyn, & |
---|
| 64 | rlonudyn,rlonvdyn, & |
---|
| 65 | airedyn,cudyn,cvdyn) |
---|
[1395] | 66 | |
---|
[1573] | 67 | ! the distinct part for all planetary physics (ie. things in phystd) |
---|
[1563] | 68 | !------------------------------------------ |
---|
[1395] | 69 | |
---|
[1563] | 70 | !$OMP PARALLEL |
---|
[1543] | 71 | |
---|
[1563] | 72 | ! copy some fundamental parameters to physics |
---|
| 73 | ! and do some initializations |
---|
[1523] | 74 | |
---|
[1682] | 75 | ! Initialize dimphy module => Now done in physics_distribution_mod |
---|
| 76 | ! call init_dimphy(klon_omp,nlayer) |
---|
[1573] | 77 | |
---|
[1308] | 78 | ! copy over preff , ap() and bp() |
---|
| 79 | call ini_planete_mod(nlayer,preff,ap,bp) |
---|
| 80 | |
---|
[1529] | 81 | ! for slab ocean, copy over some arrays |
---|
| 82 | ok_slab_ocean=.false. ! default value |
---|
| 83 | call getin_p("ok_slab_ocean",ok_slab_ocean) |
---|
| 84 | if (ok_slab_ocean) then |
---|
| 85 | call ini_surf_heat_transp(ip1jm,ip1jmp1,unsairez,fext,unsaire, & |
---|
| 86 | cu,cuvsurcv,cv,cvusurcu,aire,apoln,apols, & |
---|
| 87 | aireu,airev) |
---|
| 88 | endif |
---|
| 89 | |
---|
[1525] | 90 | call inifis(klon_omp,nlayer,nqtot,pdayref,punjours,nday,ptimestep, & |
---|
[1542] | 91 | latitude,longitude,cell_area,prad,pg,pr,pcpp) |
---|
[1216] | 92 | |
---|
[1563] | 93 | |
---|
[1216] | 94 | !$OMP END PARALLEL |
---|
| 95 | |
---|
| 96 | end subroutine iniphysiq |
---|
[1523] | 97 | |
---|
| 98 | |
---|
| 99 | END MODULE iniphysiq_mod |
---|