67 real(RP),
public,
allocatable ::
snow_swe (:,:)
88 real(RP),
public,
allocatable ::
land_u10 (:,:)
89 real(RP),
public,
allocatable ::
land_v10 (:,:)
90 real(RP),
public,
allocatable ::
land_t2 (:,:)
91 real(RP),
public,
allocatable ::
land_q2 (:,:)
96 real(RP),
public,
allocatable ::
atmos_w (:,:)
97 real(RP),
public,
allocatable ::
atmos_u (:,:)
98 real(RP),
public,
allocatable ::
atmos_v (:,:)
122 integer,
public,
parameter ::
i_z0m = 9
123 integer,
public,
parameter ::
i_z0h = 10
124 integer,
public,
parameter ::
i_z0e = 11
130 private :: land_param_read
136 logical,
private :: land_vars_checkrange = .false.
138 integer,
private,
parameter :: vmax = 19
139 integer,
private,
parameter :: i_temp = 1
140 integer,
private,
parameter :: i_water = 2
141 integer,
private,
parameter :: i_waterds = 3
142 integer,
private,
parameter :: i_sfc_temp = 4
143 integer,
private,
parameter :: i_sfc_alb_ir_dir = 5
144 integer,
private,
parameter :: i_sfc_alb_ir_dif = 6
145 integer,
private,
parameter :: i_sfc_alb_nir_dir = 7
146 integer,
private,
parameter :: i_sfc_alb_nir_dif = 8
147 integer,
private,
parameter :: i_sfc_alb_vis_dir = 9
148 integer,
private,
parameter :: i_sfc_alb_vis_dif = 10
149 integer,
private,
parameter :: i_sflx_mw = 11
150 integer,
private,
parameter :: i_sflx_mu = 12
151 integer,
private,
parameter :: i_sflx_mv = 13
152 integer,
private,
parameter :: i_sflx_sh = 14
153 integer,
private,
parameter :: i_sflx_lh = 15
154 integer,
private,
parameter :: i_sflx_evap = 16
155 integer,
private,
parameter :: i_sflx_gh = 17
156 integer,
private,
parameter :: i_sflx_water = 18
157 integer,
private,
parameter :: i_sflx_ice = 19
159 character(len=H_SHORT),
private :: var_name(vmax)
160 character(len=H_MID),
private :: var_desc(vmax)
161 character(len=H_MID),
private :: var_stdn(vmax)
162 character(len=H_SHORT),
private :: var_unit(vmax)
163 integer,
private :: var_id(vmax)
164 integer,
private :: restart_fid = -1
166 data var_name /
'LAND_TEMP', &
170 'LAND_SFC_ALB_IR_dir', &
171 'LAND_SFC_ALB_IR_dif', &
172 'LAND_SFC_ALB_NIR_dir', &
173 'LAND_SFC_ALB_NIR_dif', &
174 'LAND_SFC_ALB_VIS_dir', &
175 'LAND_SFC_ALB_VIS_dif', &
185 data var_desc /
'temperature at each soil layer', &
186 'moisture at each soil layer', &
187 'degree of saturation at each soil layer', &
188 'land surface skin temperature', &
189 'land surface albedo for IR (direct)', &
190 'land surface albedo for IR (diffuse)', &
191 'land surface albedo for NIR (direct)', &
192 'land surface albedo for NIR (diffuse)', &
193 'land surface albedo for VIS (direct)', &
194 'land surface albedo for VIS (diffuse)', &
195 'land surface w-momentum flux (upward)', &
196 'land surface u-momentum flux (upward)', &
197 'land surface v-momentum flux (upward)', &
198 'land surface sensible heat flux (upward)', &
199 'land surface latent heat flux (upward)', &
200 'land surface water vapor flux (upward)', &
201 'land subsurface heat flux (downward)', &
202 'land surface liquid water flux (downward)', &
203 'land surface ice water flux (downward)' /
204 data var_stdn /
'soil_temperature', &
205 'volume_fraction_of_condensed_water_in_soil', &
206 'volume_fraction_of_condensed_water_in_soil_at_field_capacity', &
207 'surface_temperature_where_land', &
223 data var_unit /
'K', &
243 real(RP),
private,
allocatable :: land_property_table(:,:)
245 logical,
private :: land_restart_in_check_coordinates = .true.
265 namelist / param_land_vars / &
269 land_restart_in_check_coordinates, &
279 integer :: i, j, iv, p
283 log_info(
"LAND_vars_setup",*)
'Setup' 371 log_info(
"LAND_vars_setup",*)
'Not found namelist. Default used.' 372 elseif( ierr > 0 )
then 373 log_error(
"LAND_vars_setup",*)
'Not appropriate names in namelist PARAM_LAND_VARS. Check!' 376 log_nml(param_land_vars)
379 log_info(
"LAND_vars_setup",*)
'List of prognostic variables (LAND) ' 380 log_info_cont(
'(1x,A,A24,A,A48,A,A12,A)') &
381 ' |',
'VARNAME ',
'|', &
382 'DESCRIPTION ',
'[',
'UNIT ',
']' 384 log_info_cont(
'(1x,A,I3,A,A24,A,A48,A,A12,A)') &
385 'NO.',iv,
'|',var_name(iv),
'|',var_desc(iv),
'[',var_unit(iv),
']' 393 log_info(
"LAND_vars_setup",*)
'Restart input? : NO' 400 log_info(
"LAND_vars_setup",*)
'Restart output? : NO' 406 land_property_table(:,:) = undef
439 file_cartesc_check_coordinates
444 character(len=19) :: timelabel
445 character(len=H_LONG) :: basename
449 log_info(
"LAND_vars_restart_open",*)
'Open restart file (LAND) ' 460 log_info(
"LAND_vars_restart_open",*)
'basename: ', trim(basename)
464 if ( land_restart_in_check_coordinates )
then 465 call file_cartesc_check_coordinates( restart_fid, land=.true. )
469 log_info(
"LAND_vars_restart_open",*)
'restart file for land is not specified.' 488 if ( restart_fid /= -1 )
then 490 log_info(
"LAND_vars_restart_read",*)
'Read from restart file (LAND) ' 492 call file_cartesc_read( restart_fid, var_name(i_temp),
'LXY', &
494 call file_cartesc_read( restart_fid, var_name(i_water),
'LXY', &
496 call file_cartesc_read( restart_fid, var_name(i_sfc_temp),
'XY', &
498 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_ir_dir),
'XY', &
500 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_ir_dif),
'XY', &
502 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_nir_dir),
'XY', &
504 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_nir_dif),
'XY', &
506 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_vis_dir),
'XY', &
508 call file_cartesc_read( restart_fid, var_name(i_sfc_alb_vis_dif),
'XY', &
533 log_error(
"LAND_vars_restart_read",*)
'invalid restart file ID for land.' 556 if ( land_vars_checkrange )
then 558 var_name(i_temp), __file__, __line__ )
560 var_name(i_water), __file__, __line__ )
562 var_name(i_sfc_temp), __file__, __line__ )
564 var_name(i_sfc_alb_ir_dir ), __file__, __line__ )
566 var_name(i_sfc_alb_ir_dif ), __file__, __line__ )
568 var_name(i_sfc_alb_nir_dir), __file__, __line__ )
570 var_name(i_sfc_alb_nir_dif), __file__, __line__ )
572 var_name(i_sfc_alb_vis_dir), __file__, __line__ )
574 var_name(i_sfc_alb_vis_dif), __file__, __line__ )
586 call file_history_in(
land_temp(:,:,:), var_name(i_temp), var_desc(i_temp), var_unit(i_temp), dim_type=
'LXY', standard_name=var_stdn(i_temp) )
587 call file_history_in(
land_water(:,:,:), var_name(i_water), var_desc(i_water), var_unit(i_water), dim_type=
'LXY', standard_name=var_stdn(i_water) )
595 call file_history_in( land_waterds(:,:,:), var_name(i_waterds), var_desc(i_waterds), var_unit(i_waterds), dim_type=
'LXY', fill_halo=.true., standard_name=var_stdn(i_waterds) )
598 call file_history_in(
land_sfc_temp(:,:), var_name(i_sfc_temp), &
599 var_desc(i_sfc_temp), var_unit(i_sfc_temp), standard_name=var_stdn(i_sfc_temp) )
601 var_desc(i_sfc_alb_ir_dir), var_unit(i_sfc_alb_ir_dir), standard_name=var_stdn(i_sfc_alb_ir_dir) )
603 var_desc(i_sfc_alb_ir_dif), var_unit(i_sfc_alb_ir_dif), standard_name=var_stdn(i_sfc_alb_ir_dif) )
605 var_desc(i_sfc_alb_nir_dir), var_unit(i_sfc_alb_nir_dir), standard_name=var_stdn(i_sfc_alb_nir_dir) )
607 var_desc(i_sfc_alb_nir_dif), var_unit(i_sfc_alb_nir_dif), standard_name=var_stdn(i_sfc_alb_nir_dif) )
609 var_desc(i_sfc_alb_vis_dir), var_unit(i_sfc_alb_vis_dir), standard_name=var_stdn(i_sfc_alb_vis_dir) )
611 var_desc(i_sfc_alb_vis_dif), var_unit(i_sfc_alb_vis_dif), standard_name=var_stdn(i_sfc_alb_vis_dif) )
613 call file_history_in(
land_sflx_mw(:,:), var_name(i_sflx_mw), &
614 var_desc(i_sflx_mw), var_unit(i_sflx_mw), standard_name=var_stdn(i_sflx_mw) )
615 call file_history_in(
land_sflx_mu(:,:), var_name(i_sflx_mu), &
616 var_desc(i_sflx_mu), var_unit(i_sflx_mu), standard_name=var_stdn(i_sflx_mu) )
617 call file_history_in(
land_sflx_mv(:,:), var_name(i_sflx_mv), &
618 var_desc(i_sflx_mv), var_unit(i_sflx_mv), standard_name=var_stdn(i_sflx_mv) )
619 call file_history_in(
land_sflx_sh(:,:), var_name(i_sflx_sh), &
620 var_desc(i_sflx_sh), var_unit(i_sflx_sh), standard_name=var_stdn(i_sflx_sh) )
621 call file_history_in(
land_sflx_lh(:,:), var_name(i_sflx_lh), &
622 var_desc(i_sflx_lh), var_unit(i_sflx_lh), standard_name=var_stdn(i_sflx_lh) )
625 var_desc(i_sflx_evap), var_unit(i_sflx_evap), standard_name=var_stdn(i_sflx_evap) )
627 call file_history_in(
land_sflx_gh(:,:), var_name(i_sflx_gh), &
628 var_desc(i_sflx_gh), var_unit(i_sflx_gh), standard_name=var_stdn(i_sflx_gh) )
630 var_desc(i_sflx_water), var_unit(i_sflx_water), standard_name=var_stdn(i_sflx_water) )
631 call file_history_in(
land_sflx_ice(:,:), var_name(i_sflx_ice), &
632 var_desc(i_sflx_ice), var_unit(i_sflx_ice), standard_name=var_stdn(i_sflx_ice) )
635 call file_history_in(
snow_sfc_temp(:,:),
'SNOW_SFC_TEMP',
'Snow surface temperature',
'K' )
636 call file_history_in(
snow_swe(:,:),
'SNOW_SWE',
'Snow water equivalent',
'kg/m2' )
637 call file_history_in(
snow_depth(:,:),
'SNOW_Depth',
'Snow depth',
'm' )
638 call file_history_in(
snow_dzero(:,:),
'SNOW_Dzero',
'Snow depth at melting point',
'm' )
639 call file_history_in(
snow_nosnowsec(:,:),
'SNOW_nosnowsec',
'Time duration without snow',
's' )
726 subroutine land_param_read
735 character(len=H_MID) :: description
748 namelist / param_land_property / &
751 namelist / param_land_data / &
769 integer :: IO_FID_LAND_PROPERTY
774 read(
io_fid_conf,nml=param_land_property,iostat=ierr)
776 log_info(
"LAND_param_read",*)
'Not found namelist. Default used.' 777 elseif( ierr > 0 )
then 778 log_error(
"LAND_param_read",*)
'Not appropriate names in namelist PARAM_LAND_PROPERTY. Check!' 781 log_nml(param_land_property)
786 open( io_fid_land_property, &
788 form =
'formatted', &
792 if ( ierr /= 0 )
then 793 log_error(
"LAND_param_read",*)
'Failed to open land parameter file! :', &
798 log_info(
"LAND_param_read",*)
'Properties for each plant functional type (PFT)' 799 log_info_cont(
'(12(1x,A))')
' PFT DESCRIPTION', &
813 rewind(io_fid_land_property)
830 read(io_fid_land_property,nml=param_land_data,iostat=ierr)
833 elseif( ierr > 0 )
then 834 log_error(
"LAND_param_read",*)
'Not appropriate names in namelist PARAM_LAND_DATA. Check!' 838 if( z0h < 0.0_rp )
then 841 if( z0e < 0.0_rp )
then 851 land_property_table(index,
i_alblw ) = alblw
852 land_property_table(index,
i_albsw ) = albsw
853 land_property_table(index,
i_z0m ) = z0m
854 land_property_table(index,
i_z0h ) = z0h
855 land_property_table(index,
i_z0e ) = z0e
857 log_info_cont(
'(1x,A4,I4.3,1x,A32,4(1x,F7.3),2(1x,ES7.1),5(1x,F6.3))') &
875 close( io_fid_land_property )
880 end subroutine land_param_read
887 real(RP),
intent(in) :: WS(
lia,
lja)
888 logical,
intent(in) :: critical
922 character(len=19) :: timelabel
923 character(len=H_LONG) :: basename
929 log_info(
"LAND_vars_restart_create",*)
'Create restart file (LAND) ' 938 log_info(
"LAND_vars_restart_create",*)
'basename: ', trim(basename)
957 if ( restart_fid /= -1 )
then 972 if ( restart_fid /= -1 )
then 974 log_info(
"LAND_vars_restart_close",*)
'Close restart file (LAND) ' 993 if ( restart_fid /= -1 )
then 995 do i = i_temp, i_water
996 if ( i == i_waterds ) cycle
998 var_name(i), var_desc(i), var_unit(i), &
1001 standard_name=var_stdn(i) )
1003 do i = i_sfc_temp, i_sfc_alb_vis_dif
1005 var_name(i), var_desc(i), var_unit(i), &
1008 standard_name=var_stdn(i) )
1031 file_cartesc_write_var
1035 if ( restart_fid /= -1 )
then 1039 call file_cartesc_write_var( restart_fid, var_id(i_temp), &
1041 var_name(i_temp),
'LXY', fill_halo=.true. )
1042 call file_cartesc_write_var( restart_fid, var_id(i_water), &
1044 var_name(i_water),
'LXY', fill_halo=.true. )
1045 call file_cartesc_write_var( restart_fid, var_id(i_sfc_temp), &
1047 var_name(i_sfc_temp),
'XY', fill_halo=.true. )
1048 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_ir_dir), &
1050 var_name(i_sfc_alb_ir_dir),
'XY', fill_halo=.true. )
1051 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_ir_dif), &
1053 var_name(i_sfc_alb_ir_dif),
'XY', fill_halo=.true. )
1054 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_nir_dir), &
1056 var_name(i_sfc_alb_nir_dir),
'XY', fill_halo=.true. )
1057 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_nir_dif), &
1059 var_name(i_sfc_alb_nir_dif),
'XY', fill_halo=.true. )
1060 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_vis_dir), &
1062 var_name(i_sfc_alb_vis_dir),
'XY', fill_halo=.true. )
1063 call file_cartesc_write_var( restart_fid, var_id(i_sfc_alb_vis_dif), &
1065 var_name(i_sfc_alb_vis_dif),
'XY', fill_halo=.true. )
real(rp), dimension(:,:), allocatable, public snow_swe
snow water equivalent [kg/m2]
logical, public land_restart_out_aggregate
Switch to use aggregate file.
real(rp), dimension(:,:), allocatable, public land_sflx_water
land surface water flux [kg/m2/s]
real(rp), dimension(:,:), allocatable, public atmos_pres
subroutine, public land_vars_restart_close
Close restart file.
real(rp), dimension(:,:), allocatable, public land_sflx_ice
land surface ice flux [kg/m2/s]
logical, public land_restart_output
Output restart file?
module coupler / surface-atmospehre
integer, parameter, public i_heatcapacity
integer, parameter, public i_waterlimit
real(rp), dimension(:,:), allocatable, public atmos_dens
real(rp) function, dimension(lia, lja), public convert_ws2vwc(WS, critical)
conversion from water saturation [fraction] to volumetric water content [m3/m3]
module land / grid / cartesianC / real
real(rp), dimension(:,:,:), allocatable, public land_property
land surface property
integer, parameter, public i_r_vis
module land / grid / cartesianC / index
real(rp), dimension(:,:), allocatable, public snow_sfc_temp
snow surface temperature [K]
subroutine, public land_vars_setup
Setup.
integer, parameter, public i_watercritical
real(rp), dimension(:,:), allocatable, public atmos_sfc_dens
real(rp), dimension(:,:), allocatable, public atmos_v
integer, public io_fid_conf
Config file ID.
integer, parameter, public n_rad_dir
integer, parameter, public n_rad_rgn
real(rp), dimension(:,:), allocatable, public atmos_sflx_snow
subroutine, public land_vars_restart_enddef
Exit netCDF define mode.
real(rp), dimension(:,:), allocatable, public land_q2
land surface water vapor at 2m [kg/kg]
character(len=h_long), public land_restart_in_basename
Basename of the input file.
character(len=h_short), public land_restart_out_dtype
REAL4 or REAL8.
real(rp), dimension(:,:), allocatable, public snow_depth
snow depth [m]
integer, parameter, public i_z0h
logical, public statistics_checktotal
calc&report variable totals to logfile?
integer, parameter, public i_z0e
real(rp), dimension(:,:,:), allocatable, public land_sflx_qtrc
land surface tracer flux [kg/m2/s]
real(rp), dimension(:,:), allocatable, public land_sflx_mu
land surface u-momentum flux [kg/m2/s]
integer, parameter, public landuse_pft_nmin
minimum number of PFT type
real(rp), public const_undef
real(rp), dimension(:,:), allocatable, public snow_nosnowsec
sec while no snow [s]
subroutine, public land_vars_restart_create
Create land restart file.
real(rp), dimension(:,:), allocatable, public atmos_temp
subroutine, public land_vars_restart_read
Read land restart.
real(rp), dimension(:,:), allocatable, public land_sfc_temp
land surface skin temperature [K]
real(rp), dimension(:,:), allocatable, public atmos_sflx_rain
subroutine, public file_cartesc_create(basename, title, datatype, fid, date, subsec, haszcoord, append, aggregate, single)
Create/open a netCDF file.
real(rp), dimension(:,:), allocatable, public land_v10
land surface velocity v at 10m [m/s]
real(rp), dimension(:,:), allocatable, public atmos_pbl
module atmosphere / hydrometeor
real(rp), dimension(:,:,:,:), allocatable, public land_sfc_albedo
land surface albedo (direct/diffuse,IR/near-IR/VIS) (0-1)
subroutine, public time_gettimelabel(timelabel)
generate time label
real(rp), dimension(:,:), allocatable, public land_t2
land surface temperature at 2m [K]
logical, public land_restart_in_postfix_timelabel
Add timelabel to the basename of input file?
integer function, public io_get_available_fid()
search & get available file ID
character(len=h_long), public land_restart_out_basename
Basename of the output file.
real(rp), dimension(:,:), allocatable, public land_grid_cartesc_real_area
area of grid cell
real(rp), dimension(:,:,:), allocatable, public land_water_t
tendency of LAND_WATER
subroutine, public land_vars_restart_def_var
Define land variables in restart file.
real(rp), dimension(:,:,:), allocatable, public land_temp
temperature of each soil layer [K]
real(rp), dimension(:,:), allocatable, public land_sflx_lh
land surface latent heat flux [J/m2/s]
logical, public land_restart_in_aggregate
Switch to use aggregate file.
subroutine, public file_cartesc_enddef(fid)
Exit netCDF file define mode.
real(rp), public land_grid_cartesc_real_totarea
total area
real(rp), dimension(:,:), allocatable, public atmos_qv
integer, parameter, public i_stomataresist
integer, dimension(:,:,:), allocatable, public landuse_index_pft
index of PFT for each mosaic
real(rp), dimension(:,:), allocatable, public land_u10
land surface velocity u at 10m [m/s]
subroutine, public prc_abort
Abort Process.
real(rp), dimension(:,:,:), allocatable, public land_temp_t
tendency of LAND_TEMP
integer, parameter, public i_r_direct
subroutine, public file_cartesc_def_var(fid, varname, desc, unit, dim_type, datatype, vid, standard_name, timeintv, nsteps, cell_measures)
Define a variable to file.
real(rp), dimension(:,:), allocatable, public land_sflx_gh
land surface heat flux [J/m2/s]
logical function, public file_get_aggregate(fid)
real(rp), dimension(:,:), allocatable, public snow_dzero
snow depth at melting point [m]
subroutine, public prof_rapstart(rapname_base, level)
Start raptime.
real(rp), dimension(:,:,:), allocatable, public land_water
moisture of each soil layer [m3/m3]
logical, public land_restart_out_postfix_timelabel
Add timelabel to the basename of output file?
real(rp), dimension(:,:), allocatable, public atmos_u
subroutine, public land_vars_total
Budget monitor for land.
character(len=h_mid), public land_restart_out_title
Title of the output file.
real(rp), dimension(:,:), allocatable, public atmos_sfc_pres
real(rp), dimension(:,:), allocatable, public atmos_cossza
integer, parameter, public i_r_nir
integer, parameter, public i_z0m
real(rp), dimension(:,:,:,:), allocatable, public atmos_sflx_rad_dn
character(len=h_long), public land_property_in_filename
the file of land parameter table
real(rp), dimension(:,:), allocatable, public land_sflx_mw
land surface w-momentum flux [kg/m2/s]
real(rp), dimension(:,:), allocatable, public land_sflx_mv
land surface v-momentum flux [kg/m2/s]
subroutine, public land_vars_history
History output set for land variables.
integer, public landuse_pft_nmax
number of plant functional type(PFT)
subroutine, public land_vars_restart_open
Open land restart file for read.
integer, parameter, public i_alblw
integer, parameter, public i_r_ir
integer, parameter, public land_property_nmax
real(rp), dimension(:,:), allocatable, public land_sflx_sh
land surface sensible heat flux [J/m2/s]
integer, parameter, public i_albsw
real(rp), dimension(:,:), allocatable, public atmos_w
integer, parameter, public i_r_diffuse
subroutine, public file_cartesc_flush(fid)
Flush all pending requests to a netCDF file (PnetCDF only)
subroutine, public land_vars_restart_write
Write land variables to restart file.
integer, parameter, public i_thermalcond
subroutine, public prof_rapend(rapname_base, level)
Save raptime.
subroutine, public file_cartesc_open(basename, fid, aggregate)
open a netCDF file for read
real(rp), public land_grid_cartesc_real_totvol
total volume
integer, parameter, public i_waterdiff
real(rp), dimension(:,:,:), allocatable, public land_grid_cartesc_real_vol
volume of grid cell
subroutine, public file_cartesc_close(fid)
Close a netCDF file.