Skip to content

Commit

Permalink
Apply fates_ namespace to fates parameters.
Browse files Browse the repository at this point in the history
Fates parameters and dimensions have are now namespaced with 'fates_'
in the input parameter file. This allows fates and clm to share an
input file without name collisions. Update to new default parameter
file with proper namespace.

User interface changes?: yes, all fates input via the netcdf input
parameter file must be namespaced with 'fates_' for both parameter and
dimension names.

Test suite: ed - yellowstone gnu, intel, pgi
               - hobart nag
Test baseline: a651a4f
Test namelist changes: yes, add fates_paramfile
Test answer changes: bit for bit
Test summary: all tests pass

Test suite: clm_short - yellowstone gnu, intel, pgi
Test baseline: clm4_5_12_r195
Test namelist changes: none
Test answer changes: bit for bit
Test summary: all tests pass
  • Loading branch information
bandre-ucar committed Feb 10, 2017
1 parent 87cf419 commit 509fafa
Show file tree
Hide file tree
Showing 6 changed files with 156 additions and 158 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ attributes from the config_cache.xml file (with keys converted to upper-case).
<paramfile phys="clm5_0">lnd/clm2/paramdata/clm5_params.c160713.nc</paramfile>
<paramfile phys="clm4_5">lnd/clm2/paramdata/clm_params.c160713.nc</paramfile>

<fates_paramfile phys="clm4_5">lnd/clm2/paramdata/clm_params_ed.c170112.nc</fates_paramfile>
<fates_paramfile phys="clm4_5">lnd/clm2/paramdata/fates_params.c170209.nc</fates_paramfile>

<!-- ======================================================================================== -->
<!-- clm 5.0 BGC nitrogen model -->
Expand Down
4 changes: 2 additions & 2 deletions components/clm/src/ED/biogeochem/EDSharedParamsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -84,14 +84,14 @@ subroutine RegisterParamsScalar(this, fates_params)
! that need to be synced with host values.

use FatesParametersInterface, only : fates_parameters_type, param_string_length
use FatesParametersInterface, only : dimension_name_allpfts, dimension_shape_1d
use FatesParametersInterface, only : dimension_name_host_allpfts, dimension_shape_1d

implicit none

class(EDParamsShareType), intent(inout) :: this
class(fates_parameters_type), intent(inout) :: fates_params

character(len=param_string_length), parameter :: dim_names(1) = (/dimension_name_allpfts/)
character(len=param_string_length), parameter :: dim_names(1) = (/dimension_name_host_allpfts/)
character(len=param_string_length) :: name

call this%Init()
Expand Down
42 changes: 21 additions & 21 deletions components/clm/src/ED/fire/SFParamsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -39,27 +39,27 @@ module SFParamsMod
real(r8),protected :: SF_val_mid_moisture_C(NFSC)
real(r8),protected :: SF_val_mid_moisture_S(NFSC)

character(len=param_string_length),parameter :: SF_name_fdi_a = "fdi_a"
character(len=param_string_length),parameter :: SF_name_fdi_b = "fdi_b"
character(len=param_string_length),parameter :: SF_name_fdi_alpha = "fdi_alpha"
character(len=param_string_length),parameter :: SF_name_miner_total = "miner_total"
character(len=param_string_length),parameter :: SF_name_fuel_energy = "fuel_energy"
character(len=param_string_length),parameter :: SF_name_part_dens = "part_dens"
character(len=param_string_length),parameter :: SF_name_miner_damp = "miner_damp"
character(len=param_string_length),parameter :: SF_name_max_durat = "max_durat"
character(len=param_string_length),parameter :: SF_name_durat_slope = "durat_slope"
character(len=param_string_length),parameter :: SF_name_alpha_SH = "alpha_SH"
character(len=param_string_length),parameter :: SF_name_alpha_FMC = "alpha_FMC"
character(len=param_string_length),parameter :: SF_name_CWD_frac = "CWD_frac"
character(len=param_string_length),parameter :: SF_name_max_decomp = "max_decomp"
character(len=param_string_length),parameter :: SF_name_SAV = "SAV"
character(len=param_string_length),parameter :: SF_name_FBD = "FBD"
character(len=param_string_length),parameter :: SF_name_min_moisture = "min_moisture"
character(len=param_string_length),parameter :: SF_name_mid_moisture = "mid_moisture"
character(len=param_string_length),parameter :: SF_name_low_moisture_C = "low_moisture_C"
character(len=param_string_length),parameter :: SF_name_low_moisture_S = "low_moisture_S"
character(len=param_string_length),parameter :: SF_name_mid_moisture_C = "mid_moisture_C"
character(len=param_string_length),parameter :: SF_name_mid_moisture_S = "mid_moisture_S"
character(len=param_string_length),parameter :: SF_name_fdi_a = "fates_fdi_a"
character(len=param_string_length),parameter :: SF_name_fdi_b = "fates_fdi_b"
character(len=param_string_length),parameter :: SF_name_fdi_alpha = "fates_fdi_alpha"
character(len=param_string_length),parameter :: SF_name_miner_total = "fates_miner_total"
character(len=param_string_length),parameter :: SF_name_fuel_energy = "fates_fuel_energy"
character(len=param_string_length),parameter :: SF_name_part_dens = "fates_part_dens"
character(len=param_string_length),parameter :: SF_name_miner_damp = "fates_miner_damp"
character(len=param_string_length),parameter :: SF_name_max_durat = "fates_max_durat"
character(len=param_string_length),parameter :: SF_name_durat_slope = "fates_durat_slope"
character(len=param_string_length),parameter :: SF_name_alpha_SH = "fates_alpha_SH"
character(len=param_string_length),parameter :: SF_name_alpha_FMC = "fates_alpha_FMC"
character(len=param_string_length),parameter :: SF_name_CWD_frac = "fates_CWD_frac"
character(len=param_string_length),parameter :: SF_name_max_decomp = "fates_max_decomp"
character(len=param_string_length),parameter :: SF_name_SAV = "fates_SAV"
character(len=param_string_length),parameter :: SF_name_FBD = "fates_FBD"
character(len=param_string_length),parameter :: SF_name_min_moisture = "fates_min_moisture"
character(len=param_string_length),parameter :: SF_name_mid_moisture = "fates_mid_moisture"
character(len=param_string_length),parameter :: SF_name_low_moisture_C = "fates_low_moisture_C"
character(len=param_string_length),parameter :: SF_name_low_moisture_S = "fates_low_moisture_S"
character(len=param_string_length),parameter :: SF_name_mid_moisture_C = "fates_mid_moisture_C"
character(len=param_string_length),parameter :: SF_name_mid_moisture_S = "fates_mid_moisture_S"

public :: SpitFireRegisterParams
public :: SpitFireReceiveParams
Expand Down
22 changes: 11 additions & 11 deletions components/clm/src/ED/main/EDParamsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,17 @@ module EDParamsMod
real(r8),protected :: ED_val_profile_tol
real(r8),protected :: ED_val_ag_biomass

character(len=param_string_length),parameter :: ED_name_grass_spread = "grass_spread"
character(len=param_string_length),parameter :: ED_name_comp_excln = "comp_excln"
character(len=param_string_length),parameter :: ED_name_stress_mort = "stress_mort"
character(len=param_string_length),parameter :: ED_name_dispersal = "dispersal"
character(len=param_string_length),parameter :: ED_name_maxspread = "maxspread"
character(len=param_string_length),parameter :: ED_name_minspread = "minspread"
character(len=param_string_length),parameter :: ED_name_init_litter = "init_litter"
character(len=param_string_length),parameter :: ED_name_nfires = "nfires"
character(len=param_string_length),parameter :: ED_name_understorey_death = "understorey_death"
character(len=param_string_length),parameter :: ED_name_profile_tol = "profile_tol"
character(len=param_string_length),parameter :: ED_name_ag_biomass= "ag_biomass"
character(len=param_string_length),parameter :: ED_name_grass_spread = "fates_grass_spread"
character(len=param_string_length),parameter :: ED_name_comp_excln = "fates_comp_excln"
character(len=param_string_length),parameter :: ED_name_stress_mort = "fates_stress_mort"
character(len=param_string_length),parameter :: ED_name_dispersal = "fates_dispersal"
character(len=param_string_length),parameter :: ED_name_maxspread = "fates_maxspread"
character(len=param_string_length),parameter :: ED_name_minspread = "fates_minspread"
character(len=param_string_length),parameter :: ED_name_init_litter = "fates_init_litter"
character(len=param_string_length),parameter :: ED_name_nfires = "fates_nfires"
character(len=param_string_length),parameter :: ED_name_understorey_death = "fates_understorey_death"
character(len=param_string_length),parameter :: ED_name_profile_tol = "fates_profile_tol"
character(len=param_string_length),parameter :: ED_name_ag_biomass= "fates_ag_biomass"

public :: FatesParamsInit
public :: FatesRegisterParams
Expand Down
Loading

0 comments on commit 509fafa

Please sign in to comment.