From 0daf0e1a7078ed5d00739f9b23f54c82fc5bd082 Mon Sep 17 00:00:00 2001 From: Marcos Longo Date: Sun, 4 Jun 2023 19:25:04 -0700 Subject: [PATCH 1/5] Added option for light-driven phenology for drought deciduous. --- ED/build/make/include.mk.macosx | 28 ++-- ED/src/dynamics/farq_katul.f90 | 12 -- ED/src/dynamics/phenology_aux.f90 | 4 +- ED/src/dynamics/phenology_driv.f90 | 73 +++++++--- ED/src/init/ed_params.f90 | 17 ++- ED/src/memory/phenology_coms.f90 | 8 ++ diff_version.sh | 219 ++++++++++++++++++++++------- 7 files changed, 260 insertions(+), 101 deletions(-) diff --git a/ED/build/make/include.mk.macosx b/ED/build/make/include.mk.macosx index 69ed3365c..5b84b9f33 100644 --- a/ED/build/make/include.mk.macosx +++ b/ED/build/make/include.mk.macosx @@ -5,7 +5,7 @@ #----- Define make (gnu make works best). -------------------------------------------------# -MAKE=/usr/bin/make +MAKE=/usr/local/bin/make #------------------------------------------------------------------------------------------# #----- Libraries. -------------------------------------------------------------------------# @@ -20,8 +20,8 @@ BASE=$(ED_ROOT)/build/ # libraries compiled with the same compiler you set for F_COMP and C_COMP. You may still # # be able to compile without HDF5 but it will not run. # #------------------------------------------------------------------------------------------# -ZLIB_PATH=/Users/mlongo/Util/ED2_Libs/zlib-1.2.11 -HDF5_PATH=/Users/mlongo/Util/ED2_Libs/hdf5-1.10.2 +ZLIB_PATH=/usr/local +HDF5_PATH=/usr/local HDF5_INCS=-I$(HDF5_PATH)/include HDF5C_INCS=$(HDF5_INCS) HDF5_LIBS=-L$(ZLIB_PATH)/lib -lz -L$(HDF5_PATH)/lib -lhdf5_fortran -lhdf5 -lhdf5_hl @@ -51,10 +51,9 @@ USE_INTERF=1 #################################### COMPILER SETTINGS ##################################### CMACH=MAC_OS_X FC_TYPE=GNU -F_COMP=gfortran -C_COMP=gcc -LOADER=gfortran -C_LOADER=gcc +F_COMP=/usr/local/bin/gfortran-12 +C_COMP=/usr/local/bin/gcc-12 +LOADER=/usr/local/bin/gfortran-12 LIBS= MOD_EXT=mod ############################################################################################ @@ -88,20 +87,17 @@ endif ifeq ($(KIND_COMP),A) F_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=snan \ -finit-integer=-2147483648 -ffpe-trap=invalid,zero,overflow,underflow \ - -fcheck=all -frecursive -fsignaling-nans -Werror -mmacosx-version-min=10.12 \ - -fopenmp -static - C_OPTS= -O0 -DLITTLE -g -static + -fcheck=all -frecursive -fsignaling-nans -Werror -fopenmp -fbacktrace -static + C_OPTS= -O0 -DLITTLE -g -fbacktrace -static LOADER_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=snan \ -finit-integer=-2147483648 -ffpe-trap=invalid,zero,overflow,underflow \ - -fcheck=all -frecursive -fsignaling-nans -Werror \ - -mmacosx-version-min=10.12 -fopenmp + -fcheck=all -frecursive -fsignaling-nans -Werror -fopenmp -fbacktrace #---------------------------------------------------------------------------------------# endif ifeq ($(KIND_COMP),E) - F_OPTS= -O3 -ffree-line-length-none -frecursive -mmacosx-version-min=10.12 -fopenmp \ - -static - C_OPTS= -O0 -DLITTLE -g -static - LOADER_OPTS= -O3 -ffree-line-length-none -frecursive -mmacosx-version-min=10.12 -fopenmp + F_OPTS= -O3 -ffree-line-length-none -frecursive -fopenmp -fbacktrace -static + C_OPTS= -O3 -DLITTLE -g -fbacktrace -static + LOADER_OPTS= -O3 -ffree-line-length-none -frecursive -fopenmp -fbacktrace #---------------------------------------------------------------------------------------# endif #------------------------------------------------------------------------------------------# diff --git a/ED/src/dynamics/farq_katul.f90 b/ED/src/dynamics/farq_katul.f90 index 31ac9b186..529d34a04 100644 --- a/ED/src/dynamics/farq_katul.f90 +++ b/ED/src/dynamics/farq_katul.f90 @@ -409,9 +409,6 @@ subroutine optimization_solver8(ib,ipft,lambda, real(kind=8) :: test_dcidg real(kind=8) :: test_dfcdg real(kind=8) :: test_dfedg - real(kind=8) :: test_fc_light - real(kind=8) :: test_fc_rubp - real(kind=8) :: test_fc_3rd real(kind=8) :: opt_ci_light real(kind=8) :: opt_ci_rubp real(kind=8) :: opt_ci_3rd @@ -852,15 +849,6 @@ subroutine photosynthesis_stomata_solver8(ib,gsc,limit_case, real(kind=8) :: a,b,c !! Coefficients of the quadratic equation to solve ci real(kind=8) :: rad !! sqrt(b2-4ac) real(kind=8) :: dbdg,dcdg !! derivatives of b,c wrt. gsc - real(kind=8) :: ci_rubp !! ci for rubp-limited scenario - real(kind=8) :: dcidg_rubp !! derivative of ci wrt. gsc for rubp-limited scenario - real(kind=8) :: dfcdg_rubp !! derivative of fc wrt. gsc for rubp-limited scenario - real(kind=8) :: ci_light !! ci for light-limited scenario - real(kind=8) :: dcidg_light !! derivative of ci wrt. gsc for light-limited scenario - real(kind=8) :: dfcdg_light !! derivative of fc wrt. gsc for light-limited scenario - real(kind=8) :: ci_3rd !! ci for TPU/CO2-limited scenario - real(kind=8) :: dcidg_3rd !! derivative of ci wrt. gsc for TPU/CO2-limited scenario - real(kind=8) :: dfcdg_3rd !! derivative of fc wrt. gsc for TPU/CO2-limited scenario !------------------------------------------------------------------------------------! diff --git a/ED/src/dynamics/phenology_aux.f90 b/ED/src/dynamics/phenology_aux.f90 index a8abed4f4..f91e30ae5 100644 --- a/ED/src/dynamics/phenology_aux.f90 +++ b/ED/src/dynamics/phenology_aux.f90 @@ -288,7 +288,7 @@ subroutine update_turnover(cpoly, isi) !------------------------------------------------------------------------------------! sitepft_loop: do ipft=1,n_pft select case (phenology(ipft)) - case (3) + case (3,6) !------ The actual turnover amplitude is based on a running average. ----------! cpoly%turnover_amp(isi) = (1.0 - turnamp_wgt) * cpoly%turnover_amp(isi) & + turnamp_wgt * turnamp_now @@ -414,7 +414,7 @@ subroutine update_turnover(cpoly, isi) ! -modulated. ! !------------------------------------------------------------------------------! select case (phenology(ipft)) - case (3) + case (3,6) !----- Update the data set. ------------------------------------------------! cpatch%llspan(ico) = cpatch%llspan (ico) & * cpoly%llspan_toc(ipft,isi) / llspan_toc_in(ipft) diff --git a/ED/src/dynamics/phenology_driv.f90 b/ED/src/dynamics/phenology_driv.f90 index c4c6322c2..2501f3b42 100644 --- a/ED/src/dynamics/phenology_driv.f90 +++ b/ED/src/dynamics/phenology_driv.f90 @@ -46,31 +46,58 @@ subroutine phenology_driver(cgrid, doy, month, tfact,veget_dyn_on) do ipa = 1,csite%npatches csite%avg_daily_temp(ipa) = csite%avg_daily_temp(ipa) * tfact end do - + select case (iphen_scheme) case (-1,0,2) !---------------------------------------------------------------------------! - ! Default predictive scheme (Botta et al.) or the modified drought ! - ! deciduous phenology for broadleaf PFTs. ! + ! Default predictive scheme (B00) or the modified drought deciduous ! + ! phenology for broadleaf PFTs (L19). ! + ! ! + ! Botta A, Viovy N, Ciais P, Friedlingstein P , Monfray P. 2000. A global ! + ! prognostic scheme of leaf onset using satellite data. Glob. Change ! + ! Biol., 6: 709-725. doi:10.1046/j.1365-2486.2000.00362.x (2000). ! + ! ! + ! Longo M, Knox RG, Medvigy DM, Levine NM, Dietze MC, Kim Y, Swann ALS, ! + ! Zhang K, Rollinson CR, Bras RL et al. 2019. The biophysics, ecology, ! + ! and biogeochemistry of functionally diverse, vertically and ! + ! horizontally heterogeneous ecosystems: the Ecosystem Demography model, ! + ! version 2.2 -- part 1: Model description. Geosci. Model Dev., 12: ! + ! 4309-4346. doi:10.5194/gmd-12-4309-2019 (L19). !---------------------------------------------------------------------------! call update_thermal_sums(month, cpoly, isi, cgrid%lat(ipy)) call update_phenology(doy,cpoly,isi,cgrid%lat(ipy),veget_dyn_on) - + !---------------------------------------------------------------------------! + case (1) - !----- Use prescribed phenology. -------------------------------------------! + !---------------------------------------------------------------------------! + ! Use prescribed phenology (M09). ! + ! ! + ! Medvigy DM, Wofsy SC, Munger JW, Hollinger DY , Moorcroft PR. 2009. ! + ! Mechanistic scaling of ecosystem function and dynamics in space and ! + ! time: Ecosystem demography model version 2. J. Geophys. ! + ! Res.-Biogeosci., 114: G01002. doi:10.1029/2008JG000812 (M09). ! + !---------------------------------------------------------------------------! call prescribed_leaf_state(cgrid%lat(ipy), current_time%month & ,current_time%year, doy & ,cpoly%green_leaf_factor(:,isi) & ,cpoly%leaf_aging_factor(:,isi) & ,cpoly%phen_pars(isi) ) call update_phenology(doy,cpoly,isi,cgrid%lat(ipy),veget_dyn_on) - + !---------------------------------------------------------------------------! case (3,4) - !----- Light-controlled predictive phenology scheme. -----------------------! + !---------------------------------------------------------------------------! + ! Light-controlled predictive phenology scheme (K12). ! + ! ! + ! Kim Y, Knox RG, Longo M, Medvigy D, Hutyra LR, Pyle EH, Wofsy SC, ! + ! Bras RL, Moorcroft PR. 2012. Seasonal carbon dynamics and water fluxes ! + ! in an Amazon rainforest. Glob. Change Biol., 18: 1322-1334. ! + ! doi:10.1111/j.1365-2486.2011.02629.x (K12). ! + !---------------------------------------------------------------------------! call update_thermal_sums(month, cpoly, isi, cgrid%lat(ipy)) call update_turnover(cpoly,isi) call update_phenology(doy,cpoly,isi,cgrid%lat(ipy),veget_dyn_on) + !---------------------------------------------------------------------------! end select end do end do @@ -95,6 +122,7 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) use pft_coms , only : phenology & ! intent(in) , c2n_leaf & ! intent(in) , q & ! intent(in) + , leaf_psi_min & ! intent(in) , leaf_psi_tlp & ! intent(in) , high_psi_threshold & ! intent(in) , low_psi_threshold & ! intent(in) @@ -108,7 +136,8 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) , root_phen_factor & ! intent(in) , iphen_scheme & ! intent(in) , elongf_min & ! intent(in) - , elongf_flush ! ! intent(in) + , elongf_flush & ! intent(in) + , f_psi_xdry ! ! intent(in) use consts_coms , only : t3ple & ! intent(in) , cice & ! intent(in) , cliq & ! intent(in) @@ -628,7 +657,7 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) !------------------------------------------------------------------------! end if !---------------------------------------------------------------------------! - case (5) + case (5,6) !---------------------------------------------------------------------------! ! Drought deciduous driven by plant hydrodynamics. We track the number ! ! of consecutive wet days and dry days. We then modify the phenology ! @@ -664,7 +693,15 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) !----- Modify elongf and phenology_status whenever necessary. --------------! - if (cpatch%low_leaf_psi_days(ico) >= low_psi_threshold(ipft)) then + if ( cpatch%leaf_psi(ico) < ( f_psi_xdry * leaf_psi_min(ipft) ) & + .and. cpatch%wood_psi(ico) < leaf_psi_tlp(ipft) ) then + !------------------------------------------------------------------------! + ! Extremely dry conditions: leaf_psi is too low and even wood_psi is ! + ! below leaf_tlp. Shed all leaves. ! + !------------------------------------------------------------------------! + elongf_try = 0.0 + !------------------------------------------------------------------------! + else if (cpatch%low_leaf_psi_days(ico) >= low_psi_threshold(ipft)) then !----- Too many dry days, decrease elongation factor. -------------------! elongf_try = max(0., cpatch%elongf(ico) - leaf_shed_rate(ipft)) !------------------------------------------------------------------------! @@ -924,12 +961,16 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) ! Adjust root biomass in case phenology is 5 (drought-deciduous driven ! ! by hydrodynamics). ! !---------------------------------------------------------------------------! - if (phenology(ipft) == 5 .and. root_phen_factor > 0.) then - cpatch%broot(ico) = q(ipft) * (elongf_try + root_phen_factor - 1.) & - * size2bl(cpatch%dbh(ico),cpatch%hite(ico) & - ,cpatch%sla(ico),ipft) & - / root_phen_factor - end if + select case (phenology(ipft)) + case (5,6) + if (root_phen_factor > 0.) then + cpatch%broot(ico) = q(ipft) * (elongf_try + root_phen_factor - 1.) & + * size2bl(cpatch%dbh(ico),cpatch%hite(ico) & + ,cpatch%sla(ico),ipft) & + / root_phen_factor + end if + !------------------------------------------------------------------------! + end select !---------------------------------------------------------------------------! end if !------------------------------------------------------------------------------! diff --git a/ED/src/init/ed_params.f90 b/ED/src/init/ed_params.f90 index 98b14d90b..7fde108d5 100644 --- a/ED/src/init/ed_params.f90 +++ b/ED/src/init/ed_params.f90 @@ -2483,6 +2483,7 @@ subroutine init_phen_coms use phenology_coms, only : thetacrit & ! intent(in) , retained_carbon_fraction & ! intent(out) , root_phen_factor & ! intent(out) + , f_psi_xdry & ! intent(out) , elongf_min & ! intent(out) , elongf_flush & ! intent(out) , spot_phen & ! intent(out) @@ -2536,6 +2537,14 @@ subroutine init_phen_coms + !---------------------------------------------------------------------------------------! + ! Threshold for shedding all leaves when leaf water potential is very low. . ! + !---------------------------------------------------------------------------------------! + f_psi_xdry = 0.95 + !---------------------------------------------------------------------------------------! + + + !---------------------------------------------------------------------------------------! ! Minimum elongation factor before plants give up completely and shed all remain- ! ! ing leaves. ! @@ -6536,6 +6545,12 @@ subroutine init_pft_phen_params() !------------------------------------------------------------------------------! phenology(ipft) = 5 !------------------------------------------------------------------------------! + case (5) + !------------------------------------------------------------------------------! + ! Combined light and plant-hydraulics driven drought phenology. ! + !------------------------------------------------------------------------------! + phenology(ipft) = 6 + !------------------------------------------------------------------------------! end select !---------------------------------------------------------------------------------! end if @@ -8484,7 +8499,7 @@ subroutine init_derived_params_after_xml() ! both in case this simulation is not using light-controlled phenology. ! !---------------------------------------------------------------------------------------! select case (iphen_scheme) - case (3) + case (3,5) !------------------------------------------------------------------------------------! ! Light phenology is enabled. ! !------------------------------------------------------------------------------------! diff --git a/ED/src/memory/phenology_coms.f90 b/ED/src/memory/phenology_coms.f90 index 08844c07d..296412465 100644 --- a/ED/src/memory/phenology_coms.f90 +++ b/ED/src/memory/phenology_coms.f90 @@ -178,6 +178,14 @@ module phenology_coms + !---------------------------------------------------------------------------------------! + ! Threshold for shedding all leaves when leaf water potential is very low. . ! + !---------------------------------------------------------------------------------------! + real :: f_psi_xdry + !---------------------------------------------------------------------------------------! + + + !---------------------------------------------------------------------------------------! ! Minimum elongation factor before plants give up completely and shed all remain- ! ! ing leaves. ! diff --git a/diff_version.sh b/diff_version.sh index 77a083c15..d3be988ac 100755 --- a/diff_version.sh +++ b/diff_version.sh @@ -24,9 +24,11 @@ subdirs="ED BRAMS Ramspost R-utils" #------ Editor to use (I've only tested with nedit, use others at your own risk). ---------# editor="nedit" #------ Two paths with EDBRAMS (full path). -----------------------------------------------# -ours="${HOME}/EDBRAMS" -theirs="${HOME}/MainLine/EDBRAMS" -ournew=true +ours="${HOME}/Downloads/MLN-EDBRAMS" +theirs="${HOME}/Downloads/MLO-EDBRAMS" +ournew=false +#------ Working path when implementing a partial merge (otherwise, leave it blank). -------# +work="${HOME}/Models/EDBRAMS" #------------------------------------------------------------------------------------------# @@ -45,7 +47,24 @@ esac #------------------------------------------------------------------------------------------# # Remove any comparison file that may exist. # #------------------------------------------------------------------------------------------# -/bin/rm -f notthesame.* +/bin/rm -f notthesame.* \~notthesame.* +#------------------------------------------------------------------------------------------# + + +#------------------------------------------------------------------------------------------# +# Add settings for partial merge (if sought). # +#------------------------------------------------------------------------------------------# +if [[ "${work}" == "" ]] +then + #---- Disable work version (preferred method, much less messy). ------------------------# + load_work=false + work=${theirs} + #---------------------------------------------------------------------------------------# +else + #---- Enable work version (more prone to complications, be careful). -------------------# + load_work=true + #---------------------------------------------------------------------------------------# +fi #------------------------------------------------------------------------------------------# @@ -60,11 +79,11 @@ do #---------------------------------------------------------------------------------------# for ext in ${exts} do - if [ ${subdir} == "R-utils" ] && [ ${ext} == ".txt" ] + if [[ ${subdir} == "R-utils" ]] && [[ ${ext} == ".txt" ]] then srcours="${ours}/${subdir}/samap" srctheirs="${theirs}/${subdir}/samap" - elif [ ${subdir} == "R-utils" ] + elif [[ ${subdir} == "R-utils" ]] then srcours="${ours}/${subdir}" srctheirs="${theirs}/${subdir}" @@ -82,12 +101,14 @@ do for fileours in ${lookuptable} do file=$(basename ${fileours}) - newpath=$(dirname ${fileours} | sed s@${ours}@${theirs}@g) + theirpath=$(dirname ${fileours} | sed s@${ours}@${theirs}@g) + workpath=$(dirname ${fileours} | sed s@${ours}@${work}@g) case "${myos}" in Darwin|Cygwin) #---- Case-insensitive file system. ---------------------------------------------# - filetheirs="${newpath}/${file}" - alt="" + filetheirs="${theirpath}/${file}" + filework="${workpath}/${file}" + theirs_alt="" ;; #--------------------------------------------------------------------------------# *) @@ -95,64 +116,154 @@ do case "${ext}" in ".f90") alt_file=$(echo ${file} | sed s@"\\.f90"@".F90"@g) - if [ -s "${newpath}/${alt_file}" ] + if [[ -s "${theirpath}/${alt_file}" ]] then - filetheirs="${newpath}/${alt_file}" - alt=".F90" + filetheirs="${theirpath}/${alt_file}" + theirs_alt=".F90" else - filetheirs="${newpath}/${file}" - alt="" + filetheirs="${theirpath}/${file}" + theirs_alt="" fi ;; ".F90") alt_file=$(echo ${file} | sed s@"\\.F90"@".f90"@g) - if [ -s "${newpath}/${alt_file}" ] + if [[ -s "${theirpath}/${alt_file}" ]] then - filetheirs="${newpath}/${alt_file}" - alt=".f90" + filetheirs="${theirpath}/${alt_file}" + theirs_alt=".f90" else - filetheirs="${newpath}/${file}" - alt="" + filetheirs="${theirpath}/${file}" + theirs_alt="" fi ;; *) - filetheirs="${newpath}/${file}" - alt="" + filetheirs="${theirpath}/${file}" + theirs_alt="" ;; esac - ;; #--------------------------------------------------------------------------------# + + + #----- Probably Linux or Unix, assume case-sensitive file system. ---------------# + case "${ext}" in + ".f90") + alt_file=$(echo ${file} | sed s@"\\.f90"@".F90"@g) + if [[ -s "${workpath}/${alt_file}" ]] + then + filework="${workpath}/${alt_file}" + work_alt=".F90" + else + filework="${workpath}/${file}" + work_alt="" + fi + ;; + ".F90") + alt_file=$(echo ${file} | sed s@"\\.F90"@".f90"@g) + if [[ -s "${workpath}/${alt_file}" ]] + then + filework="${workpath}/${alt_file}" + work_alt=".f90" + else + filework="${workpath}/${file}" + work_alt="" + fi + ;; + *) + filework="${workpath}/${file}" + work_alt="" + ;; + esac + #--------------------------------------------------------------------------------# + + ;; esac - filetheirs="${newpath}/${file}" - if [ -s ${filetheirs} ] + + + #-----------------------------------------------------------------------------------# + # If we are doing partial merge, we must check the existence three-way, # + # otherwise we compare just the "ours" and "theirs". # + #-----------------------------------------------------------------------------------# + if [[ -s ${filetheirs} ]] then - ldif=$(diff -ibB <(grep -vE "^\s*!" ${fileours}) <(grep -vE "^\s*!" ${filetheirs}) | wc -l) - if [ ${ldif} -gt 0 ] - then - woroot=$(echo ${fileours} | sed s@"${srcours}/"@""@g) - case "${alt}" in - .f90|.F90) - echo "${woroot} has changed. New extension is ${alt}." - ;; - *) - echo "${woroot} has changed." - ;; - esac - if ${ournew} - then - diff -uibB <(grep -vE "^\s*!" ${filetheirs}) <(grep -vE "^\s*!" ${fileours})\ - > notthesame${ext} - else - diff -uibB <(grep -vE "^\s*!" ${fileours}) <(grep -vE "^\s*!" ${filetheirs})\ - > notthesame${ext} - fi - ${editor} ${fileours} ${filetheirs} notthesame${ext} 1> /dev/null 2> /dev/null - /bin/rm -f notthesame${ext} - fi + #---- Check for extension change. -----------------------------------------------# + woroot=$(echo ${fileours} | sed s@"${srcours}/"@""@g) + case "${theirs_alt}" in + .f90|.F90) + if ${ournew} + then + ext_mess="Old extension was ${theirs_alt}." + else + ext_mess="New extension is ${theirs_alt}." + fi + ;; + *) + ext_mess="" + ;; + esac + #--------------------------------------------------------------------------------# + + + + #--------------------------------------------------------------------------------# + # Check for changes (ignoring spaces and commented lines). # + #--------------------------------------------------------------------------------# + ldif=$(diff -ibB <(grep -vE "^\s*!" ${fileours}) <(grep -vE "^\s*!" ${filetheirs}) | wc -l) + if [[ ${ldif} -gt 0 ]] + then + change=true + if [[ "${ext_mess}" == "" ]] + then + echo "File ${woroot}. Code has changed." + else + echo "File ${woroot}. Code has changed. ${ext_mess}" + fi + elif [[ "${ext_mess}" == "" ]] + then + change=false + else + change=false + echo "File ${woroot}. ${ext_mess}" + fi + #--------------------------------------------------------------------------------# + + + #--------------------------------------------------------------------------------# + # If files have changes, report differences. # + #--------------------------------------------------------------------------------# + if ${change} + then + #----- Write differences to a temporary file. --------------------------------# + if ${ournew} + then + diff -uibB <(grep -vE "^\s*!" ${filetheirs}) \ + <(grep -vE "^\s*!" ${fileours}) > notthesame${ext} + else + diff -uibB <(grep -vE "^\s*!" ${fileours}) \ + <(grep -vE "^\s*!" ${filetheirs}) > notthesame${ext} + fi + #-----------------------------------------------------------------------------# + + + #----- Open editor with all files needed. ------------------------------------# + if ${load_work} && [[ -s ${filework} ]] + then + ${editor} ${filework} ${filetheirs} notthesame${ext} \ + 1> /dev/null 2> /dev/null + /bin/rm -f notthesame${ext} + elif ${load_work} + then + ${editor} ${filetheirs} notthesame${ext} 1> /dev/null 2> /dev/null + echo " ---> Working file is missing!" + else + ${editor} ${fileours} ${filetheirs} notthesame${ext} \ + 1> /dev/null 2> /dev/null + fi + #-----------------------------------------------------------------------------# + fi else - woroot=$(echo ${fileours} | sed s@"${srcours}/"@""@g) - echo "${woroot} is exclusive to ${ours} version." - fi #if [ -s ${filetheirs} ] + woroot=$(echo ${fileours} | sed s@"${srcours}/"@""@g) + echo "${woroot} is exclusive to ${ours} version." + fi #if [[ -s ${filetheirs} ]] done #for fileours in ${lookuptable} #-------------------------------------------------------------------------------------# @@ -165,13 +276,13 @@ do for filetheirs in ${lookuptable} do file=$(basename ${filetheirs}) - newpath=$(dirname ${filetheirs} | sed s@${theirs}@${ours}@g) - fileours="${newpath}/${file}" - if [ ! -s ${fileours} ] + ourpath=$(dirname ${filetheirs} | sed s@${theirs}@${ours}@g) + fileours="${ourpath}/${file}" + if [[ ! -s ${fileours} ]] then woroot=$(echo ${filetheirs} | sed s@"${srctheirs}/"@""@g) echo "${woroot} is exclusive to ${theirs} version." - fi #if [ -s ${filetheirs} ] + fi #if [[ -s ${filetheirs} ]] done #for fileours in ${lookuptable} #-------------------------------------------------------------------------------------# done #for ext in ${exts} From 27bcf5da388dce22cfaa52865d03483806b9b62b Mon Sep 17 00:00:00 2001 From: Marcos Longo Date: Tue, 6 Jun 2023 16:14:54 -0700 Subject: [PATCH 2/5] A few bug fixes in the phenology changes, specifically adding variables to the xml initialisation and updating the tests in ed_opspec.F90 to account for the new options. --- ED/src/dynamics/phenology_driv.f90 | 50 +++++++++++++++--------------- ED/src/io/ed_init_history.f90 | 2 +- ED/src/io/ed_opspec.F90 | 6 ++-- ED/src/io/ed_xml_config.f90 | 9 ++++++ diff_version.sh | 4 +-- 5 files changed, 40 insertions(+), 31 deletions(-) diff --git a/ED/src/dynamics/phenology_driv.f90 b/ED/src/dynamics/phenology_driv.f90 index 2501f3b42..a5bfbf3f1 100644 --- a/ED/src/dynamics/phenology_driv.f90 +++ b/ED/src/dynamics/phenology_driv.f90 @@ -48,26 +48,6 @@ subroutine phenology_driver(cgrid, doy, month, tfact,veget_dyn_on) end do select case (iphen_scheme) - case (-1,0,2) - !---------------------------------------------------------------------------! - ! Default predictive scheme (B00) or the modified drought deciduous ! - ! phenology for broadleaf PFTs (L19). ! - ! ! - ! Botta A, Viovy N, Ciais P, Friedlingstein P , Monfray P. 2000. A global ! - ! prognostic scheme of leaf onset using satellite data. Glob. Change ! - ! Biol., 6: 709-725. doi:10.1046/j.1365-2486.2000.00362.x (2000). ! - ! ! - ! Longo M, Knox RG, Medvigy DM, Levine NM, Dietze MC, Kim Y, Swann ALS, ! - ! Zhang K, Rollinson CR, Bras RL et al. 2019. The biophysics, ecology, ! - ! and biogeochemistry of functionally diverse, vertically and ! - ! horizontally heterogeneous ecosystems: the Ecosystem Demography model, ! - ! version 2.2 -- part 1: Model description. Geosci. Model Dev., 12: ! - ! 4309-4346. doi:10.5194/gmd-12-4309-2019 (L19). - !---------------------------------------------------------------------------! - call update_thermal_sums(month, cpoly, isi, cgrid%lat(ipy)) - call update_phenology(doy,cpoly,isi,cgrid%lat(ipy),veget_dyn_on) - !---------------------------------------------------------------------------! - case (1) !---------------------------------------------------------------------------! ! Use prescribed phenology (M09). ! @@ -85,14 +65,27 @@ subroutine phenology_driver(cgrid, doy, month, tfact,veget_dyn_on) call update_phenology(doy,cpoly,isi,cgrid%lat(ipy),veget_dyn_on) !---------------------------------------------------------------------------! - case (3,4) + case default !---------------------------------------------------------------------------! - ! Light-controlled predictive phenology scheme (K12). ! + ! Default predictive scheme (B00), the modified drought deciduous ! + ! phenology for broadleaf PFTs (L19), or the light-controlled predictive ! + ! phenology scheme (K12). ! + ! ! + ! Botta A, Viovy N, Ciais P, Friedlingstein P , Monfray P. 2000. A global ! + ! prognostic scheme of leaf onset using satellite data. Glob. Change ! + ! Biol., 6: 709-725. doi:10.1046/j.1365-2486.2000.00362.x (2000). ! ! ! ! Kim Y, Knox RG, Longo M, Medvigy D, Hutyra LR, Pyle EH, Wofsy SC, ! ! Bras RL, Moorcroft PR. 2012. Seasonal carbon dynamics and water fluxes ! ! in an Amazon rainforest. Glob. Change Biol., 18: 1322-1334. ! ! doi:10.1111/j.1365-2486.2011.02629.x (K12). ! + ! ! + ! Longo M, Knox RG, Medvigy DM, Levine NM, Dietze MC, Kim Y, Swann ALS, ! + ! Zhang K, Rollinson CR, Bras RL et al. 2019. The biophysics, ecology, ! + ! and biogeochemistry of functionally diverse, vertically and ! + ! horizontally heterogeneous ecosystems: the Ecosystem Demography model, ! + ! version 2.2 -- part 1: Model description. Geosci. Model Dev., 12: ! + ! 4309-4346. doi:10.5194/gmd-12-4309-2019 (L19). !---------------------------------------------------------------------------! call update_thermal_sums(month, cpoly, isi, cgrid%lat(ipy)) call update_turnover(cpoly,isi) @@ -300,7 +293,7 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) !------------------------------------------------------------------------------! ! Here we decide what to do depending on the phenology habit. There are ! - ! five different types: ! + ! different types: ! ! 0. Evergreen - neither cold nor drought makes these plants to drop ! ! their leaves; ! ! 1. Drought deciduous - these plants will drop all leaves when drought ! @@ -314,6 +307,13 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) ! 4. Drought deciduous - similar to one, but the threshold is compared against ! ! a 10-day running average rather than the instant- ! ! aneous value. ! + ! 5. Hydro-deciduous - similar to four, but the thresholds are based on ! + ! leaf water potential instead (and thus it requires ! + ! plant hydrodynamics). ! + ! 6. Light phenology ! + ! + Hydro-deciduous - similar to three, but the thresholds are based on ! + ! leaf water potential instead (and thus it requires ! + ! plant hydrodynamics). ! !------------------------------------------------------------------------------! select case (phenology(ipft)) case (0) @@ -958,8 +958,8 @@ subroutine update_phenology(doy, cpoly, isi, lat,veget_dyn_on) !---------------------------------------------------------------------------! - ! Adjust root biomass in case phenology is 5 (drought-deciduous driven ! - ! by hydrodynamics). ! + ! Adjust root biomass in case phenology is 5 or 6 (drought-deciduous ! + ! driven by hydrodynamics). ! !---------------------------------------------------------------------------! select case (phenology(ipft)) case (5,6) diff --git a/ED/src/io/ed_init_history.f90 b/ED/src/io/ed_init_history.f90 index f4d91cc49..b36fa907a 100644 --- a/ED/src/io/ed_init_history.f90 +++ b/ED/src/io/ed_init_history.f90 @@ -430,7 +430,7 @@ subroutine resume_from_history() !----- Load phenology in case it is prescribed (or set them with defaults). ---------! - write(unit=*,fmt='(a,i2.2)') ' Checking prescribed phenology. Node: ',mynum + write(unit=*,fmt='(a,i2.2)') ' Loading prescribed phenology. Node: ',mynum call phenology_init() return diff --git a/ED/src/io/ed_opspec.F90 b/ED/src/io/ed_opspec.F90 index 1011fcf90..8a6badd37 100644 --- a/ED/src/io/ed_opspec.F90 +++ b/ED/src/io/ed_opspec.F90 @@ -1872,9 +1872,9 @@ subroutine ed_opspec_misc end if - if (iphen_scheme < -1 .or. iphen_scheme > 4) then + if (iphen_scheme < -1 .or. iphen_scheme > 5) then write (reason,fmt='(a,1x,i4,a)') & - 'Invalid IPHEN_SCHEME, it must be between -1 and 4. Yours is set to' & + 'Invalid IPHEN_SCHEME, it must be between -1 and 5. Yours is set to' & ,iphen_scheme,'...' call opspec_fatal(reason,'opspec_misc') ifaterr = ifaterr +1 @@ -1893,7 +1893,7 @@ subroutine ed_opspec_misc ! model may be linear or log-linear. Don't bother checking if IPHEN_SCHEME is not 3. ! !---------------------------------------------------------------------------------------! select case (iphen_scheme) - case (3) + case (3,5) !----- Light-driven phenology is enabled. Check settings. --------------------------! select case (economics_scheme) case (1) diff --git a/ED/src/io/ed_xml_config.f90 b/ED/src/io/ed_xml_config.f90 index 22e741ecd..6ac5a3cbd 100644 --- a/ED/src/io/ed_xml_config.f90 +++ b/ED/src/io/ed_xml_config.f90 @@ -1472,6 +1472,12 @@ recursive subroutine read_ed_xml_config(filename) if(texist) retained_carbon_fraction = sngloff(rval,tiny_offset) call getConfigREAL ('root_phen_factor','phenology',i,rval,texist) if(texist) root_phen_factor = sngloff(rval,tiny_offset) + call getConfigREAL ('f_psi_xdry','phenology',i,rval,texist) + if(texist) f_psi_xdry = sngloff(rval,tiny_offset) + call getConfigREAL ('elongf_min','phenology',i,rval,texist) + if(texist) elongf_min = sngloff(rval,tiny_offset) + call getConfigREAL ('elongf_flush','phenology',i,rval,texist) + if(texist) elongf_flush = sngloff(rval,tiny_offset) call getConfigREAL ('theta_crit','phenology',i,rval,texist) if(texist) thetacrit= sngloff(rval,tiny_offset) call getConfigREAL ('dl_tr','phenology',i,rval,texist) @@ -2431,6 +2437,9 @@ subroutine write_ed_xml_config call libxml2f90_ll_opentag("phenology") call putConfigREAL("retained_carbon_fraction",retained_carbon_fraction) call putConfigREAL("root_phen_factor" ,root_phen_factor ) + call putConfigREAL("f_psi_xdry" ,f_psi_xdry ) + call putConfigREAL("elongf_min" ,elongf_min ) + call putConfigREAL("elongf_flush" ,elongf_flush ) call putConfigREAL("theta_crit" ,thetacrit ) call putConfigREAL("dl_tr" ,dl_tr ) call putConfigREAL("st_tr1" ,st_tr1 ) diff --git a/diff_version.sh b/diff_version.sh index d3be988ac..3e69ceee0 100755 --- a/diff_version.sh +++ b/diff_version.sh @@ -38,8 +38,8 @@ work="${HOME}/Models/EDBRAMS" # Extensions. Decide how much to check. # #------------------------------------------------------------------------------------------# case "${comptype}" in -partial) exts=".c .f90 .F90" ;; -*) exts=".c .f90 .F90 .r .txt" ;; +partial) exts=".c .F90 .f90" ;; +*) exts=".c .F90 .f90 .r .txt" ;; esac #------------------------------------------------------------------------------------------# From 2e42d08f8bff1be7bb99a0f891d7deae2114189f Mon Sep 17 00:00:00 2001 From: Marcos Longo Date: Tue, 6 Jun 2023 17:01:13 -0700 Subject: [PATCH 3/5] Updated namelist and module documentation on phenology scheme options. --- BRAMS/Template/RAMSIN | 15 +++++++ BRAMS/run/RAMSIN | 15 +++++++ ED/Template/Template/ED2IN | 15 +++++++ ED/run/ED2IN | 7 ++++ ED/src/memory/phenology_coms.f90 | 69 +++++++++++++++++++------------- 5 files changed, 94 insertions(+), 27 deletions(-) diff --git a/BRAMS/Template/RAMSIN b/BRAMS/Template/RAMSIN index 0e9b47465..2e0bc2064 100644 --- a/BRAMS/Template/RAMSIN +++ b/BRAMS/Template/RAMSIN @@ -2425,10 +2425,25 @@ $ED2_INFO ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! IPHEN_SCHEME = 2, !---------------------------------------------------------------------------------------! diff --git a/BRAMS/run/RAMSIN b/BRAMS/run/RAMSIN index dd87f6b44..5a3545fb4 100644 --- a/BRAMS/run/RAMSIN +++ b/BRAMS/run/RAMSIN @@ -2443,10 +2443,25 @@ $ED2_INFO ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! IPHEN_SCHEME = 2, !---------------------------------------------------------------------------------------! diff --git a/ED/Template/Template/ED2IN b/ED/Template/Template/ED2IN index 63504ddd5..af061c062 100644 --- a/ED/Template/Template/ED2IN +++ b/ED/Template/Template/ED2IN @@ -959,10 +959,25 @@ $ED_NL ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! NL%IPHEN_SCHEME = myiphen !---------------------------------------------------------------------------------------! diff --git a/ED/run/ED2IN b/ED/run/ED2IN index 11f752ea3..eb343a4de 100644 --- a/ED/run/ED2IN +++ b/ED/run/ED2IN @@ -976,12 +976,19 @@ $ED_NL ! tropical - drought-deciduous (light phenology); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! + ! ! ! 4: (Beta). ! ! grasses - drought-deciduous (hydraulics scheme); ! ! tropical - drought-deciduous (hydraulics scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! diff --git a/ED/src/memory/phenology_coms.f90 b/ED/src/memory/phenology_coms.f90 index 296412465..64f1816e7 100644 --- a/ED/src/memory/phenology_coms.f90 +++ b/ED/src/memory/phenology_coms.f90 @@ -22,40 +22,55 @@ module phenology_coms integer :: iphen_scheme !---------------------------------------------------------------------------------------! - !< IPHEN_SCHEME -- It controls the phenology scheme. Even within each scheme, the \n - !< actual phenology will be different depending on the PFT. \n + ! Date: Sun, 11 Jun 2023 16:01:16 -0700 Subject: [PATCH 4/5] Temporarily disabling mpi compilation from CI. --- ED/build/make/include.mk.travisci | 40 +++++++++++++++++++------------ 1 file changed, 25 insertions(+), 15 deletions(-) diff --git a/ED/build/make/include.mk.travisci b/ED/build/make/include.mk.travisci index 243995438..35ade16d0 100644 --- a/ED/build/make/include.mk.travisci +++ b/ED/build/make/include.mk.travisci @@ -39,17 +39,27 @@ USE_COLLECTIVE_MPIO=0 + +#------------------------------------------------------------------------------------------# +# This should be 1 unless you are running with -gen-interfaces. Interfaces usually # +# make the compilation to crash when the -gen-interfaces option are on, so this flag # +# bypass all interfaces in the code. # +#------------------------------------------------------------------------------------------# +USE_INTERF=1 +#------------------------------------------------------------------------------------------# + + + #################################### COMPILER SETTINGS ##################################### CMACH=TRAVISCI FC_TYPE=GNU -F_COMP=mpif90 -C_COMP=mpicc -LOADER=mpif90 +F_COMP=gfortran +C_COMP=gcc +LOADER=gfortran LIBS= MOD_EXT=mod #------------------------------------------------------------------------------------------# -USE_INTERF=1 ##################################### COMPILER OPTIONS ##################################### @@ -62,19 +72,19 @@ ifeq ($(KIND_COMP),) endif #------------------------------------------------------------------------------------------# ifeq ($(KIND_COMP),$(filter $(KIND_COMP), A B C D)) - F_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=nan \ - -ffpe-trap=invalid,zero,overflow,underflow -fbacktrace -fbounds-check \ - -frecursive - C_OPTS= -O0 -DLITTLE -g - LOADER_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=nan \ - -ffpe-trap=invalid,zero,overflow,underflow -fbacktrace -fbounds-check \ - -frecursive + F_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=snan \ + -finit-integer=-2147483648 -ffpe-trap=invalid,zero,overflow,underflow \ + -fcheck=all -frecursive -fsignaling-nans -Werror -fopenmp -fbacktrace -static + C_OPTS= -O0 -DLITTLE -g -fbacktrace -static + LOADER_OPTS= -O0 -ffree-line-length-none -g -fimplicit-none -Wall -finit-real=snan \ + -finit-integer=-2147483648 -ffpe-trap=invalid,zero,overflow,underflow \ + -fcheck=all -frecursive -fsignaling-nans -Werror -fopenmp -fbacktrace #---------------------------------------------------------------------------------------# endif ifeq ($(KIND_COMP),E) - F_OPTS= -O3 -ffree-line-length-none -frecursive -fno-whole-file -static - C_OPTS= -O0 -DLITTLE -g -static - LOADER_OPTS= -O3 -ffree-line-length-none -frecursive -fno-whole-file + F_OPTS= -O3 -ffree-line-length-none -frecursive -fopenmp -fbacktrace -static + C_OPTS= -O3 -DLITTLE -g -fbacktrace -static + LOADER_OPTS= -O3 -ffree-line-length-none -frecursive -fopenmp -fbacktrace #---------------------------------------------------------------------------------------# endif #------------------------------------------------------------------------------------------# @@ -91,7 +101,7 @@ endif MPI_PATH= PAR_INCS= PAR_LIBS= -PAR_DEFS=-DRAMS_MPI +PAR_DEFS= #------------------------------------------------------------------------------------------# From 5fa04176b9ff1962dd92ab334c2bd9401c1a0a82 Mon Sep 17 00:00:00 2001 From: Marcos Longo Date: Sun, 11 Jun 2023 17:01:19 -0700 Subject: [PATCH 5/5] Update ED2IN variable description in the CI namelists. --- EDTS/Templates/ED2IN-TEST | 15 +++++++++++++++ EDTS/Templates/ED2IN-tonzi | 29 ++++++++++++++++++++++------- EDTS/Templates/ED2IN-tonzi.harvest | 29 ++++++++++++++++++++++------- 3 files changed, 59 insertions(+), 14 deletions(-) diff --git a/EDTS/Templates/ED2IN-TEST b/EDTS/Templates/ED2IN-TEST index 64f489146..afda1e606 100644 --- a/EDTS/Templates/ED2IN-TEST +++ b/EDTS/Templates/ED2IN-TEST @@ -964,10 +964,25 @@ $ED_NL ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! NL%IPHEN_SCHEME = 2 !---------------------------------------------------------------------------------------! diff --git a/EDTS/Templates/ED2IN-tonzi b/EDTS/Templates/ED2IN-tonzi index 06ed7ff22..1ca69de05 100644 --- a/EDTS/Templates/ED2IN-tonzi +++ b/EDTS/Templates/ED2IN-tonzi @@ -848,37 +848,52 @@ $ED_NL ! IPHEN_SCHEME -- It controls the phenology scheme. Even within each scheme, the ! ! actual phenology will be different depending on the PFT. ! ! ! - ! -1: grasses - evergreen; ! + ! -1: (ED-2.2 default for evergreen tropical). ! + ! grasses - evergreen; ! ! tropical - evergreen; ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous (Botta et al.); ! ! ! - ! 0: grasses - drought-deciduous (old scheme); ! + ! 0: (Deprecated). ! + ! grasses - drought-deciduous (old scheme); ! ! tropical - drought-deciduous (old scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 1: prescribed phenology ! + ! 1: (ED-2.2 default for prescribed phenology; deprecated for tropical PFTs). ! + ! phenology is prescribed for cold-deciduous broadleaf trees. ! ! ! - ! 2: grasses - drought-deciduous (new scheme); ! + ! 2: (ED-2.2 default). ! + ! grasses - drought-deciduous (new scheme); ! ! tropical - drought-deciduous (new scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 3: grasses - drought-deciduous (new scheme); ! + ! 3: (Beta). ! + ! grasses - drought-deciduous (new scheme); ! ! tropical - drought-deciduous (light phenology); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 4: grasses - drought-deciduous (plant hydraulics); ! - ! tropical - drought-deciduous (plant hydraulics; ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! NL%IPHEN_SCHEME = 2 !---------------------------------------------------------------------------------------! diff --git a/EDTS/Templates/ED2IN-tonzi.harvest b/EDTS/Templates/ED2IN-tonzi.harvest index fed665436..8345de2ae 100644 --- a/EDTS/Templates/ED2IN-tonzi.harvest +++ b/EDTS/Templates/ED2IN-tonzi.harvest @@ -848,37 +848,52 @@ $ED_NL ! IPHEN_SCHEME -- It controls the phenology scheme. Even within each scheme, the ! ! actual phenology will be different depending on the PFT. ! ! ! - ! -1: grasses - evergreen; ! + ! -1: (ED-2.2 default for evergreen tropical). ! + ! grasses - evergreen; ! ! tropical - evergreen; ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous (Botta et al.); ! ! ! - ! 0: grasses - drought-deciduous (old scheme); ! + ! 0: (Deprecated). ! + ! grasses - drought-deciduous (old scheme); ! ! tropical - drought-deciduous (old scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 1: prescribed phenology ! + ! 1: (ED-2.2 default for prescribed phenology; deprecated for tropical PFTs). ! + ! phenology is prescribed for cold-deciduous broadleaf trees. ! ! ! - ! 2: grasses - drought-deciduous (new scheme); ! + ! 2: (ED-2.2 default). ! + ! grasses - drought-deciduous (new scheme); ! ! tropical - drought-deciduous (new scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 3: grasses - drought-deciduous (new scheme); ! + ! 3: (Beta). ! + ! grasses - drought-deciduous (new scheme); ! ! tropical - drought-deciduous (light phenology); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! - ! 4: grasses - drought-deciduous (plant hydraulics); ! - ! tropical - drought-deciduous (plant hydraulics; ! + ! 4: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme); ! ! conifers - evergreen; ! ! hardwoods - cold-deciduous; ! ! ! + ! 5: (Beta). ! + ! grasses - drought-deciduous (hydraulics scheme); ! + ! tropical - drought-deciduous (hydraulics scheme + light phenology); ! + ! conifers - evergreen; ! + ! hardwoods - cold-deciduous; ! + ! ! + ! ! ! Old scheme: plants shed their leaves once instantaneous amount of available water ! ! becomes less than a critical value. ! ! New scheme: plants shed their leaves once a 10-day running average of available ! ! water becomes less than a critical value. ! + ! Hydraulics scheme: plants shed their leaves once predawn leaf water potential is ! + ! lower than tugor loss point for 10 consecutive days ! !---------------------------------------------------------------------------------------! NL%IPHEN_SCHEME = 2 !---------------------------------------------------------------------------------------!