From eed8513ea867714e0261da1c12903609b233b16f Mon Sep 17 00:00:00 2001 From: "Srbinovsky, Jhan (O&A, Aspendale)" Date: Thu, 12 Dec 2024 11:33:40 +1100 Subject: [PATCH] mv froot initialization back to vegin where necessary fields are already present --- .../cable_um_init_subrs.F90 | 44 +++++++------------ 1 file changed, 16 insertions(+), 28 deletions(-) diff --git a/src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_um_init_subrs.F90 b/src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_um_init_subrs.F90 index f0feff7af..306f892a2 100644 --- a/src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_um_init_subrs.F90 +++ b/src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_um_init_subrs.F90 @@ -329,8 +329,6 @@ END SUBROUTINE initialize_veg SUBROUTINE init_veg_pars_fr_vegin( soil_zse ) -USE cable_common_module, ONLY: cable_user -USE cable_params_mod, ONLY: vegin USE cable_um_tech_mod, ONLY: veg, soil USE cable_def_types_mod, ONLY: mp, ms @@ -340,37 +338,16 @@ SUBROUTINE init_veg_pars_fr_vegin( soil_zse ) CALL init_veg_from_vegin(1, mp, veg, soil_zse) -IF (cable_user%access13roots) THEN - ! default prescribed values used in CMIP6 ACCESS-ESM1.5 - veg%froot(:,1) = 0.05 - veg%froot(:,2) = 0.20 - veg%froot(:,3) = 0.20 - veg%froot(:,4) = 0.20 - veg%froot(:,5) = 0.20 - veg%froot(:,6) = 0.15 -ELSE - ! parametrized values used in CMIP6 ACCESS-CM2 - ! calculate vegin%froot from using rootbeta and soil depth - ! (Jackson et al. 1996, Oceologica, 108:389-411) - totdepth = 0.0 - DO is = 1, ms-1 - totdepth = totdepth + soil_zse(is) * 100.0 ! unit in centimetres - veg%froot(:, is) = MIN( 1.0, 1.0-veg%rootbeta(:)**totdepth ) - END DO - veg%froot(:, ms) = 1.0 - veg%froot(:, ms-1) - DO is = ms-1, 2, -1 - veg%froot(:, is) = veg%froot(:, is)-veg%froot(:,is-1) - END DO - -ENDIF RETURN END SUBROUTINE init_veg_pars_fr_vegin SUBROUTINE init_veg_from_vegin(ifmp,fmp, veg, soil_zse ) - use cable_def_types_mod, ONLY : veg_parameter_type, ms, mp - USE cable_params_mod, ONLY : vegin + +USE cable_def_types_mod, ONLY: veg_parameter_type, ms, mp +USE cable_params_mod, ONLY: vegin +USE cable_common_module, ONLY: cable_user integer :: ifmp, & ! start local mp, # landpoints (jhan:when is this not 1 ) fmp ! local mp, # landpoints @@ -428,7 +405,16 @@ SUBROUTINE init_veg_from_vegin(ifmp,fmp, veg, soil_zse ) veg%clitt(h) = vegin%clitt(veg%iveg(h)) END DO ! over each veg patch in land point -!used in CM2 - overwritten here +IF (cable_user%access13roots) THEN + ! default prescribed values used in CMIP6 ACCESS-ESM1.5 + veg%froot(:,1) = 0.05 + veg%froot(:,2) = 0.20 + veg%froot(:,3) = 0.20 + veg%froot(:,4) = 0.20 + veg%froot(:,5) = 0.20 + veg%froot(:,6) = 0.15 +ELSE + ! parametrized values used in CMIP6 ACCESS-CM2 ! calculate vegin%froot from using rootbeta and soil depth ! (Jackson et al. 1996, Oceologica, 108:389-411) totdepth = 0.0 @@ -441,7 +427,9 @@ SUBROUTINE init_veg_from_vegin(ifmp,fmp, veg, soil_zse ) veg%froot(:, is) = veg%froot(:, is)-veg%froot(:,is-1) END DO +ENDIF +RETURN END SUBROUTINE init_veg_from_vegin