39 use constants_mod
, only: rdgas, rvgas, cp_air
41 use mpp_mod
, only: stdlog, input_nml_file
42 use fms_mod
, only: check_nml_error, open_namelist_file, close_file
50 real,
allocatable ::
ri(:)
51 real,
allocatable ::
cpi(:)
52 real,
allocatable ::
vir(:)
53 real,
allocatable ::
vicp(:)
54 real,
allocatable ::
vicv(:)
82 integer,
intent(in):: ngas, nwat
87 logical :: default_gas=.false.
96 if (
num_gas.eq.1 ) default_gas=.true.
101 cv_air = cp_air - rdgas
103 cvi(n) =
cpi(n) -
ri(n)
108 vicv(0) = cvi(0)/cv_air
109 if( default_gas )
then 116 if(
ri(n).gt.0.0 )
vir(n) =
ri(n)/rdgas -
vir(0)
120 if( cvi(n).gt.0.0 )
vicv(n) = cvi(n)/cv_air -
vicv(0)
123 if( is_master() )
then 124 write(*,*)
' multi_gases_init with ind_gas=',
ind_gas 125 write(*,*)
' multi_gases_init with num_gas=',
num_gas 126 write(*,*)
' multi_gases_init with vir =',
vir 127 write(*,*)
' multi_gases_init with vicp=',
vicp 128 write(*,*)
' multi_gases_init with vicv=',
vicv 135 character(*),
intent(IN) :: nml_filename
136 integer,
intent(IN) :: ncnst, nwat
137 integer :: ierr, f_unit, unit, ios
139 namelist /multi_gases_nml/
ri,
cpi 143 allocate (
ri(0:ncnst))
144 allocate (
cpi(0:ncnst))
152 #ifdef INTERNAL_FILE_NML 155 read (input_nml_file,multi_gases_nml,iostat=ios)
156 ierr = check_nml_error(ios,
'multi_gases_nml')
160 f_unit = open_namelist_file(nml_filename)
163 read (f_unit,multi_gases_nml,iostat=ios)
164 ierr = check_nml_error(ios,
'multi_gases_nml')
165 call close_file(f_unit)
167 write(unit, nml=multi_gases_nml)
177 pure real function virq(q)
216 pure real function virq_max(q, qmin)
222 real,
intent(in) :: qmin
244 real,
intent(in) :: qpz
260 pure real function virqd(q)
280 pure real function vicpqd(q)
306 real,
intent(in) :: qpz
321 pure real function vicvqd(q)
347 real,
intent(in) :: qpz
real, dimension(:), allocatable, public vir
pure real function, public vicpqd(q)
The module 'fv_mp_mod' is a single program multiple data (SPMD) parallel decompostion/communication m...
The module 'multi_gases' peforms multi constitutents computations.
pure real function, public vicvqd_qpz(q, qpz)
pure real function, public virq_max(q, qmin)
subroutine, public read_namelist_multi_gases_nml(nml_filename, ncnst, nwat)
pure real function, public virq_qpz(q, qpz)
real, dimension(:), allocatable ri
pure real function, public virqd(q)
pure real function, public virq_nodq(q)
pure real function, public virq(q)
subroutine, public multi_gases_init(ngas, nwat)
real, dimension(:), allocatable cpi
real, dimension(:), allocatable, public vicv
real, dimension(:), allocatable, public vicp
pure real function, public vicpqd_qpz(q, qpz)
pure real function, public vicvqd(q)