13 #include "inc_openmp.h" 78 integer,
private,
parameter :: vmax = 8
79 integer,
private,
parameter :: i_mflx_cloudbase = 1
80 integer,
private,
parameter :: i_sflx_convrain = 2
81 integer,
private,
parameter :: i_cloudtop = 3
82 integer,
private,
parameter :: i_cloudbase = 4
83 integer,
private,
parameter :: i_cldfrac_dp = 5
84 integer,
private,
parameter :: i_cldfrac_sh = 6
85 integer,
private,
parameter :: i_kf_nca = 7
86 integer,
private,
parameter :: i_kf_w0avg = 8
88 character(len=H_SHORT),
private :: var_name(vmax)
89 character(len=H_MID),
private :: var_desc(vmax)
90 character(len=H_SHORT),
private :: var_unit(vmax)
91 integer,
private :: var_id (vmax)
92 integer,
private :: restart_fid = -1
94 data var_name /
'MFLX_cloudbase', &
102 data var_desc /
'cloud base mass flux', &
104 'cloud top height', &
105 'cloud base height', &
106 'cloud fraction (deep convection)', &
107 'cloud fraction (shallow convection)', &
108 'advection/cumulus convection timescale/dt for KF', &
109 'running mean vertical wind velocity for KF' /
110 data var_unit /
'kg/m2/s', &
120 integer,
private :: vmax_t
121 integer,
private :: i_cp_dens_t = 1
122 integer,
private :: i_cp_rhot_t = 2
124 character(len=H_SHORT),
private,
allocatable :: var_t_name(:)
125 character(len=H_MID),
private,
allocatable :: var_t_desc(:)
126 character(len=H_SHORT),
private,
allocatable :: var_t_unit(:)
127 integer,
private,
allocatable :: var_t_id (:)
140 namelist / param_atmos_phy_cp_vars / &
153 if(
io_l )
write(
io_fid_log,*)
'++++++ Module[VARS] / Categ[ATMOS PHY_CP] / Origin[SCALE-RM]' 187 allocate( var_t_name(vmax_t) )
188 allocate( var_t_desc(vmax_t) )
189 allocate( var_t_unit(vmax_t) )
190 allocate( var_t_id(vmax_t) )
192 var_t_name(i_cp_dens_t) =
'DENS_t_CP' 193 var_t_desc(i_cp_dens_t) =
'tendency DENS in CP' 194 var_t_unit(i_cp_dens_t) =
'kg/m3/s' 195 var_t_name(i_cp_rhot_t) =
'RHOT_t_CP' 196 var_t_desc(i_cp_rhot_t) =
'tendency RHOT in CP' 197 var_t_unit(i_cp_rhot_t) =
'K*kg/m3/s' 200 var_t_name(2+iq) = trim(
aq_name(iq))//
'_t_CP' 201 var_t_desc(2+iq) =
'tendency rho*'//trim(
aq_name(iq))//
'in CP' 202 var_t_unit(2+iq) =
'kg/m3/s' 207 read(
io_fid_conf,nml=param_atmos_phy_cp_vars,iostat=ierr)
209 if(
io_l )
write(
io_fid_log,*)
'*** Not found namelist. Default used.' 210 elseif( ierr > 0 )
then 211 write(*,*)
'xxx Not appropriate names in namelist PARAM_ATMOS_PHY_CP_VARS. Check!' 217 if(
io_l )
write(
io_fid_log,*)
'*** [ATMOS_PHY_CP] prognostic/diagnostic variables' 219 '*** |',
'VARNAME ',
'|',
'DESCRIPTION ',
'[',
'UNIT ',
']' 222 '*** NO.',iv,
'|',var_name(iv),
'|',var_desc(iv),
'[',var_unit(iv),
']' 228 '*** NO.',iv+vmax,
'|',var_t_name(iv),
'|',var_t_desc(iv),
'[',var_t_unit(iv),
']' 329 if(
io_l )
write(
io_fid_log,*)
'*** Input restart file (ATMOS_PHY_CP) ***' 379 if(
io_l )
write(
io_fid_log,*)
'*** restart file for ATMOS_PHY_CP is not specified.' 396 character(len=20) :: timelabel
397 character(len=H_LONG) :: basename
409 if(
io_l )
write(
io_fid_log,*)
'*** Output restart file (ATMOS_PHY_CP) ***' 451 character(len=20) :: timelabel
452 character(len=H_LONG) :: basename
462 if(
io_l )
write(
io_fid_log,*)
'*** Output restart file (ATMOS_PHY_CP) ***' 480 if ( restart_fid .NE. -1 )
then 494 if ( restart_fid .NE. -1 )
then 512 if ( restart_fid .NE. -1 )
then 514 call fileio_def_var( restart_fid, var_id(1), var_name(1), var_desc(1), &
516 call fileio_def_var( restart_fid, var_id(2), var_name(2), var_desc(2), &
518 call fileio_def_var( restart_fid, var_id(3), var_name(3), var_desc(3), &
520 call fileio_def_var( restart_fid, var_id(4), var_name(4), var_desc(4), &
522 call fileio_def_var( restart_fid, var_id(5), var_name(5), var_desc(5), &
524 call fileio_def_var( restart_fid, var_id(6), var_name(6), var_desc(6), &
526 call fileio_def_var( restart_fid, var_id(7), var_name(7), var_desc(7), &
528 call fileio_def_var( restart_fid, var_id(8), var_name(8), var_desc(8), &
531 call fileio_def_var( restart_fid, var_t_id(1), var_t_name(1), var_t_desc(1), &
533 call fileio_def_var( restart_fid, var_t_id(2), var_t_name(2), var_t_desc(2), &
537 call fileio_def_var( restart_fid, var_t_id(2+iq), var_t_name(2+iq), var_t_desc(2+iq), &
556 if ( restart_fid .NE. -1 )
then 576 var_t_name(1),
'ZXY' )
578 var_t_name(2),
'ZXY' )
581 var_t_name(2+iq),
'ZXY' )
integer, public is
start point of inner domain: x, local
subroutine, public atmos_phy_cp_vars_restart_def_var
Write restart.
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_momy_t
integer, public je
end point of inner domain: y, local
module Atmosphere / Physics Cumulus
character(len=h_mid), public atmos_phy_cp_restart_out_title
title of the output file
subroutine, public prc_mpistop
Abort MPI.
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_momx_t
character(len=h_long), public atmos_phy_cp_restart_in_basename
basename of the restart file
subroutine, public atmos_phy_cp_vars_restart_enddef
Exit netCDF define mode.
logical, public io_l
output log or not? (this process)
subroutine, public atmos_phy_cp_vars_restart_write
Write restart.
logical, public atmos_phy_cp_restart_output
output restart file?
subroutine, public atmos_phy_cp_vars_restart_write_var
Write restart.
character(len=h_long), public atmos_phy_cp_restart_out_basename
basename of the output file
integer, public ke
end point of inner domain: z, local
subroutine, public atmos_phy_cp_vars_restart_create
Create restart file.
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_dens_t
real(rp), public const_undef
real(rp), dimension(:,:,:,:), allocatable, public atmos_phy_cp_rhoq_t
subroutine, public atmos_phy_cp_vars_restart_close
Close restart file.
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_cldfrac_dp
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_kf_w0avg
subroutine, public atmos_phy_cp_vars_setup
Setup.
subroutine, public fileio_def_var(fid, vid, varname, desc, unit, axistype, datatype, timeintv)
Define a variable to file.
integer, public ia
of x whole cells (local, with HALO)
subroutine, public time_gettimelabel(timelabel)
generate time label
integer, public ka
of z whole cells (local, with HALO)
subroutine, public atmos_phy_cp_vars_fillhalo
HALO Communication.
subroutine, public fileio_create(fid, basename, title, datatype, date, subsec, append, nozcoord)
Create/open a netCDF file.
character(len=h_short), dimension(:), allocatable, public aq_name
integer, public js
start point of inner domain: y, local
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_momz_t
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_rhot_t
real(rp), dimension(:,:), allocatable, public atmos_phy_cp_cloudtop
integer, public ks
start point of inner domain: z, local
subroutine, public fileio_enddef(fid)
Exit netCDF file define mode.
integer, public ie
end point of inner domain: x, local
logical, public io_lnml
output log or not? (for namelist, this process)
subroutine, public atmos_phy_cp_vars_restart_read
Read restart.
subroutine, public fileio_close(fid)
Close a netCDF file.
integer, public io_fid_conf
Config file ID.
real(rp), dimension(:,:), allocatable, public atmos_phy_cp_mflx_cloudbase
real(rp), dimension(:,:), allocatable, public atmos_phy_cp_cloudbase
integer, public io_fid_log
Log file ID.
real(rp), dimension(:,:,:), allocatable, public atmos_phy_cp_cldfrac_sh
real(rp), dimension(:,:), allocatable, public atmos_phy_cp_sflx_rain
character(len=h_mid), public atmos_phy_cp_restart_out_dtype
REAL4 or REAL8.
real(rp), dimension(:,:), allocatable, public atmos_phy_cp_kf_nca
integer, public ja
of y whole cells (local, with HALO)