Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

changes required for ESM16 #474

1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ add_library(
src/offline/cable_site.F90
src/offline/cable_serial.F90
src/offline/cable_soil_params.F90
src/offline/cable_surface_types.F90
src/offline/cable_weathergenerator.F90
src/offline/cable_write.F90
src/offline/casa_cable.F90
Expand Down
3 changes: 2 additions & 1 deletion src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_cbm.F90
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ SUBROUTINE cbm( dels, air, bgc, canopy, met, &
USE cable_other_constants_mod, ONLY: cgauss_w => gauss_w
USE cable_math_constants_mod, ONLY: cpi => pi
USE cable_math_constants_mod, ONLY: cpi180 => pi180
USE grid_constants_mod_cbl, ONLY : ICE_SoilType, lakes_cable
USE cable_surface_types_mod, ONLY: lakes_cable
USE grid_constants_mod_cbl, ONLY: ICE_SoilType


USE cable_common_module
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Expand Down
3 changes: 2 additions & 1 deletion src/coupled/ESM1.5/CABLEfilesFromESM1.5/cable_rad_driver.F90
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@ SUBROUTINE cable_rad_driver( &
USE cable_common_module, ONLY : cable_runtime, cable_user

USE cbl_init_radiation_module, ONLY: Common_InitRad_Scalings
USE grid_constants_mod_cbl, ONLY : ICE_SoilType, lakes_cable
USE grid_constants_mod_cbl, ONLY: ICE_SoilType
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
USE cable_surface_types_mod, ONLY: lakes_cable

IMPLICIT NONE

Expand Down
35 changes: 35 additions & 0 deletions src/coupled/ESM1.5/cable_surface_types.F90
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
!******************************************************************************
! This source code is part of the Community Atmosphere Biosphere Land Exchange
! (CABLE) model. This work is licensed under the CSIRO Open Source Software
! License Agreement (variation of the BSD / MIT License).You may not use this
! this file except in compliance with this License. A copy of the License is
! available at https://trac.nci.org.au/trac/cable/wiki/license.
!******************************************************************************

MODULE cable_surface_types_mod

IMPLICIT NONE

PUBLIC

! cable_surface_type (nml) Index
INTEGER, PARAMETER :: evergreen_needleleaf = 1
INTEGER, PARAMETER :: evergreen_broadleaf = 2
INTEGER, PARAMETER :: deciduous_needleleaf = 3
INTEGER, PARAMETER :: deciduous_broadleaf = 4
INTEGER, PARAMETER :: shrub_cable = 5
INTEGER, PARAMETER :: c3_grassland = 6
INTEGER, PARAMETER :: c4_grassland = 7
INTEGER, PARAMETER :: tundra = 8
INTEGER, PARAMETER :: c3_cropland = 9
INTEGER, PARAMETER :: c4_cropland = 10
INTEGER, PARAMETER :: wetland = 11
INTEGER, PARAMETER :: empty1 = 12
INTEGER, PARAMETER :: empty2 = 13
INTEGER, PARAMETER :: barren_cable = 14
INTEGER, PARAMETER :: urban_cable = 15
INTEGER, PARAMETER :: lakes_cable = 16
INTEGER, PARAMETER :: ice_cable = 17

END MODULE cable_surface_types_mod

2 changes: 0 additions & 2 deletions src/offline/cable_surface_types.F90
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
!#define UM_CBL YES
!******************************************************************************
! This source code is part of the Community Atmosphere Biosphere Land Exchange
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
! (CABLE) model. This work is licensed under the CSIRO Open Source Software
Expand All @@ -13,7 +12,6 @@ MODULE cable_surface_types_mod

PUBLIC

!-----------------------------------------------------------------------------
! cable_surface_type (nml) Index
INTEGER, PARAMETER :: evergreen_needleleaf = 1
INTEGER, PARAMETER :: evergreen_broadleaf = 2
Expand Down
4 changes: 2 additions & 2 deletions src/offline/cbl_model_driver_offline.F90
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ SUBROUTINE cbm( ktau,dels, air, bgc, canopy, met,
USE cbl_albedo_mod, ONLY : albedo
USE sli_main_mod, ONLY : sli_main
USE snow_aging_mod, ONLY: snow_aging

!data
! scalar data USEd through modules
USE cable_other_constants_mod, ONLY: CLAI_THRESH => lai_thresh
USE cable_other_constants_mod, ONLY: Crad_thresh => rad_thresh
USE cable_other_constants_mod, ONLY: Ccoszen_tols => coszen_tols
Expand Down
1 change: 0 additions & 1 deletion src/params/grid_constants_cbl.F90
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
!#define UM_CBL YES
!******************************************************************************
! This source code is part of the Community Atmosphere Biosphere Land Exchange
! (CABLE) model. This work is licensed under the CSIRO Open Source Software
Expand Down
1 change: 0 additions & 1 deletion src/science/canopy/cbl_SurfaceWetness.F90
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ SUBROUTINE Surf_wetness_fact( cansat, canopy, ssnow,veg, met, soil, dels )

USE cable_common_module
USE cable_def_types_mod

! data
USE cable_surface_types_mod, ONLY: lakes_cable
USE cable_phys_constants_mod, ONLY: CTFRZ => TFRZ
Expand Down
6 changes: 3 additions & 3 deletions src/science/canopy/cbl_init_wetfac_mod.f90
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ SUBROUTINE initialize_wetfac( &


! Imports
USE cable_surface_types_mod, ONLY: lakes_cable
USE cable_def_types_mod, ONLY : r_2
USE cable_other_constants_mod, ONLY : wilt_limitfactor
USE cable_surface_types_mod, ONLY: lakes_cable
USE cable_def_types_mod, ONLY: r_2
USE cable_other_constants_mod, ONLY: wilt_limitfactor

IMPLICIT NONE

Expand Down
24 changes: 12 additions & 12 deletions src/science/casa-cnp/casa_variable.F90
Original file line number Diff line number Diff line change
Expand Up @@ -274,22 +274,22 @@ MODULE casavariable

! Added filename type for casaCNP (BP apr2010)
TYPE casafiles_type
CHARACTER(LEN=99) :: cnpbiome ! file for biome-specific BGC parameters
CHARACTER(LEN=99) :: cnppoint ! file for point-specific BGC inputs
CHARACTER(LEN=99) :: cnpepool ! file for end-of-run pool sizes
CHARACTER(LEN=99) :: cnpipool='' ! file for inital pool sizes
CHARACTER(LEN=99) :: cnpmetin ! met file for spin up
CHARACTER(LEN=99) :: cnpmetout ! met file for spin up
CHARACTER(LEN=99) :: ndep ! N deposition input file
CHARACTER(LEN=199) :: cnpbiome ! file for biome-specific BGC parameters
CHARACTER(LEN=199) :: cnppoint ! file for point-specific BGC inputs
CHARACTER(LEN=199) :: cnpepool ! file for end-of-run pool sizes
CHARACTER(LEN=199) :: cnpipool='' ! file for inital pool sizes
CHARACTER(LEN=199) :: cnpmetin ! met file for spin up
CHARACTER(LEN=199) :: cnpmetout ! met file for spin up
CHARACTER(LEN=199) :: ndep ! N deposition input file
! added yp wang
CHARACTER(LEN=99) :: cnpspin ! input file for spin up
CHARACTER(LEN=99) :: dump_cnpspin ! name of dump file for spinning casa-cnp
CHARACTER(LEN=199) :: cnpspin ! input file for spin up
CHARACTER(LEN=199) :: dump_cnpspin ! name of dump file for spinning casa-cnp

CHARACTER(LEN=99) :: phen ! leaf phenology datafile
CHARACTER(LEN=99) :: cnpflux ! modelled mean yearly CNP fluxes
CHARACTER(LEN=199) :: phen ! leaf phenology datafile
CHARACTER(LEN=199) :: cnpflux ! modelled mean yearly CNP fluxes
LOGICAL :: l_ndep
! added vh
CHARACTER(LEN=99) :: c2cdumppath='' ! cable2casa dump for casa spinup
CHARACTER(LEN=199) :: c2cdumppath='' ! cable2casa dump for casa spinup
END TYPE casafiles_type
TYPE(casafiles_type) :: casafile

Expand Down
3 changes: 1 addition & 2 deletions src/science/gw_hydro/cable_gw_hydro.F90
Original file line number Diff line number Diff line change
Expand Up @@ -335,8 +335,7 @@ END SUBROUTINE remove_transGW
SUBROUTINE ovrlndflx (dels, ssnow, soil,veg, canopy,sli_call )
!* Calculate surface runoff

USE cable_common_module, ONLY : gw_params,cable_user

USE cable_common_module, ONLY: gw_params,cable_user
USE cable_surface_types_mod, ONLY: lakes_cable

IMPLICIT NONE
Expand Down
11 changes: 7 additions & 4 deletions src/science/roughness/cable_roughness.F90
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,15 @@ SUBROUTINE ruff_resist(veg, rough, ssnow, canopy, LAI_pft, HGT_pft, reducedLAIdu
! (or not) using [[HgtAboveSnow]] and [[LAI_eff]]
rough%hruff = HeightAboveSnow
!why are we using veg% for LAI and height-although this is synced now
IF(cable_runtime%um_radiation .OR. cable_runtime%offline ) THEN
! LAI decreases due to snow: formerly canopy%vlaiw
call LAI_eff( mp, veg%vlai, veg%hc, HeightAboveSnow, &
IF(cable_runtime%um_radiation .OR. cable_runtime%esm15 &
JhanSrbinovsky marked this conversation as resolved.
Show resolved Hide resolved
.OR. cable_runtime%offline ) THEN

! LAI decreases due to snow: formerly canopy%vlaiw
CALL LAI_eff( mp, veg%vlai, veg%hc, HeightAboveSnow, &
reducedLAIdue2snow )

canopy%vlaiw = reducedLAIdue2snow
canopy%vlaiw = reducedLAIdue2snow

ENDIF
canopy%rghlai = canopy%vlaiw

Expand Down
2 changes: 1 addition & 1 deletion src/science/soilsnow/cbl_surfbv.F90
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
!#define UM_CBL YES
MODULE surfbv_mod

USE cbl_ssnow_data_mod
Expand All @@ -13,6 +12,7 @@ SUBROUTINE surfbv (dels, met, ssnow, soil, veg, canopy )

! data
USE cable_surface_types_mod, ONLY: lakes_cable
USE cable_common_module

USE cable_common_module

Expand Down
Loading