Skip to content

Commit

Permalink
defined new ice wedge polygon land unit types and microtopographic pa…
Browse files Browse the repository at this point in the history
…rameters
  • Loading branch information
chuckaustin committed May 6, 2024
1 parent 86671b1 commit 735b5b2
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 1 deletion.
3 changes: 3 additions & 0 deletions components/elm/src/data_types/ColumnType.F90
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ module ColumnType
real(r8), pointer :: hslp_p10 (:,:) => null() ! hillslope slope percentiles (unitless)
integer, pointer :: nlevbed (:) => null() ! number of layers to bedrock
real(r8), pointer :: zibed (:) => null() ! bedrock depth in model (interface level at nlevbed)
real(r8), pointer :: iwp_microrel (:) => null() ! ice wedge polygon microtopographic relief (m)
real(r8), pointer :: iwp_exclvol (:) => null() ! ice wedge polygon excluded volume (m)
real(r8), pointer :: iwp_ddep (:) => null() ! ice wedge polygon depression depth (m)

! vertical levels
integer , pointer :: snl (:) => null() ! number of snow layers
Expand Down
6 changes: 6 additions & 0 deletions components/elm/src/data_types/LandunitType.F90
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ module LandunitType
logical , pointer :: urbpoi (:) => null() ! true=>urban point
logical , pointer :: glcmecpoi (:) => null() ! true=>glacier_mec point
logical , pointer :: active (:) => null() ! true=>do computations on this landunit
logical , pointer :: ispolygon (:) => null() ! true=>is polygonal tundra
integer , pointer :: polygontype (:) => null() ! ice wedge polygon initial condition (LCP, FCP, or HCP)

! urban properties
real(r8), pointer :: canyon_hwr (:) => null() ! urban landunit canyon height to width ratio (-)
Expand Down Expand Up @@ -93,6 +95,8 @@ subroutine lun_pp_Init(this, begl, endl)
allocate(this%lakpoi (begl:endl)); this%lakpoi (:) = .false.
allocate(this%urbpoi (begl:endl)); this%urbpoi (:) = .false.
allocate(this%glcmecpoi (begl:endl)); this%glcmecpoi (:) = .false.
allocate(this%ispolygon (begl:endl)); this%ispolygon (:) = .false.
allocate(this%polygontype (begl:endl)); this%polygontype(:) = ispval

! The following is initialized in routine setActive in module reweightMod
allocate(this%active (begl:endl))
Expand Down Expand Up @@ -129,6 +133,8 @@ subroutine lun_pp_clean(this)
deallocate(this%lakpoi )
deallocate(this%urbpoi )
deallocate(this%glcmecpoi )
deallocate(this%ispolygon )
deallocate(this%polygontype )
deallocate(this%active )
deallocate(this%canyon_hwr )
deallocate(this%wtroad_perv )
Expand Down
32 changes: 31 additions & 1 deletion components/elm/src/main/landunit_varcon.F90
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,12 @@ module landunit_varcon

integer, parameter, public :: landunit_name_length = 40 ! max length of landunit names
character(len=landunit_name_length), public :: landunit_names(max_lunit) ! name of each landunit type


! land unit polygonal ground types
integer, parameter, public :: ilowcenpoly = 1 ! low-centered polygons
integer, parameter, public :: iflatcenpoly = 2 ! flat-centered polygons
integer, parameter, public :: ihighcenpoly = 3 ! high-centered polygons

! parameters that depend on the above constants

integer, parameter, public :: numurbl = isturb_MAX - isturb_MIN + 1 ! number of urban landunits
Expand All @@ -48,6 +53,7 @@ module landunit_varcon
!
! !PRIVATE MEMBER FUNCTIONS:
private :: set_landunit_names ! set the landunit_names vector
private :: set_polygon_names ! set the polygon_names vector
!-----------------------------------------------------------------------

contains
Expand Down Expand Up @@ -98,6 +104,30 @@ function landunit_is_special(ltype) result(is_special)

end function landunit_is_special

subroutine set_polygon_names
!
! !DESCRIPTION:
! Set the polygon_names vector
!
! !USES:
use shr_sys_mod, only : shr_sys_abort
!
character(len=*), parameter :: not_set = 'NOT_SET'
character(len=*), parameter :: subname = 'set_polygon_names'
!-----------------------------------------------------------------------

polygon_names(:) = not_set

polygon_names(ilowcenpoly) = 'low_centered_polygons'
polygon_names(iflatcenpoly) = 'flat_centered_polygons'
polygon_names(ihighcenpoly) = 'high_centered_polygons'

if (any(polygon_names == not_set)) then
call shr_sys_abort(trim(subname)//': Not all polygon names set')
end if

end subroutine set_polygon_names

!-----------------------------------------------------------------------
subroutine set_landunit_names
!
Expand Down

0 comments on commit 735b5b2

Please sign in to comment.