Skip to content

Commit

Permalink
Merge branch 'master' into rgknox-more-photo-refactors
Browse files Browse the repository at this point in the history
  • Loading branch information
rgknox committed Jan 9, 2017
2 parents ca1ac03 + d116008 commit 492c1cb
Show file tree
Hide file tree
Showing 15 changed files with 2,423 additions and 2,582 deletions.
4 changes: 2 additions & 2 deletions components/clm/src/ED/biogeochem/EDCohortDynamicsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ module EDCohortDynamicsMod
use EDGrowthFunctionsMod , only : c_area, tree_lai
use EDTypesMod , only : ed_site_type, ed_patch_type, ed_cohort_type
use EDTypesMod , only : fusetol, cp_nclmax
use EDtypesMod , only : ncwd, numcohortsperpatch, udata
use EDtypesMod , only : ncwd, maxcohortsperpatch, udata
use EDtypesMod , only : sclass_ed,nlevsclass_ed,AREA
use EDtypesMod , only : min_npm2, min_nppatch, min_n_safemath
!
Expand Down Expand Up @@ -625,7 +625,7 @@ subroutine fuse_cohorts(patchptr)
iterate = 1
fusion_took_place = 0
currentPatch => patchptr
maxcohorts = numCohortsPerPatch
maxcohorts = maxCohortsPerPatch

!---------------------------------------------------------------------!
! Keep doing this until nocohorts <= maxcohorts !
Expand Down
4 changes: 2 additions & 2 deletions components/clm/src/ED/biogeochem/EDPatchDynamicsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ module EDPatchDynamicsMod
use clm_varctl , only : iulog
use pftconMod , only : pftcon
use EDCohortDynamicsMod , only : fuse_cohorts, sort_cohorts, insert_cohort
use EDtypesMod , only : ncwd, n_dbh_bins, ntol, numpft_ed, area, dbhmax, numPatchesPerCol
use EDtypesMod , only : ncwd, n_dbh_bins, ntol, numpft_ed, area, dbhmax, maxPatchesPerCol
use EDTypesMod , only : ed_site_type, ed_patch_type, ed_cohort_type, udata
use EDTypesMod , only : min_patch_area, cp_numlevgrnd, cp_numSWb
!
Expand Down Expand Up @@ -1018,7 +1018,7 @@ subroutine fuse_patches( csite )
!---------------------------------------------------------------------

!maxpatch = 4
maxpatch = numPatchesPerCol
maxpatch = maxPatchesPerCol

currentSite => csite

Expand Down
14 changes: 7 additions & 7 deletions components/clm/src/ED/biogeophys/EDSurfaceAlbedoMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ module EDSurfaceRadiationMod

use EDtypesMod , only : ed_patch_type, ed_site_type
use EDtypesMod , only : numpft_ed
use EDtypesMod , only : numPatchesPerCol
use EDtypesMod , only : maxPatchesPerCol
use shr_kind_mod , only : r8 => shr_kind_r8
use shr_log_mod , only : errMsg => shr_log_errMsg
use FatesInterfaceMod , only : bc_in_type, &
Expand Down Expand Up @@ -74,8 +74,8 @@ subroutine ED_Norman_Radiation (nsites, sites, bc_in, bc_out )
real(r8) :: k_dir(numpft_ed) ! Direct beam extinction coefficient
real(r8) :: tr_dir_z(cp_nclmax,numpft_ed,cp_nlevcan) ! Exponential transmittance of direct beam radiation through a single layer
real(r8) :: tr_dif_z(cp_nclmax,numpft_ed,cp_nlevcan) ! Exponential transmittance of diffuse radiation through a single layer
real(r8) :: forc_dir(numPatchesPerCol,cp_maxSWb)
real(r8) :: forc_dif(numPatchesPerCol,cp_maxSWb)
real(r8) :: forc_dir(maxPatchesPerCol,cp_maxSWb)
real(r8) :: forc_dif(maxPatchesPerCol,cp_maxSWb)
real(r8) :: weighted_dir_tr(cp_nclmax)
real(r8) :: weighted_fsun(cp_nclmax)
real(r8) :: weighted_dif_ratio(cp_nclmax,cp_maxSWb)
Expand All @@ -93,8 +93,8 @@ subroutine ED_Norman_Radiation (nsites, sites, bc_in, bc_out )
real(r8) :: abs_rad(cp_maxSWb) !radiation absorbed by soil
real(r8) :: tr_soili ! Radiation transmitted to the soil surface.
real(r8) :: tr_soild ! Radiation transmitted to the soil surface.
real(r8) :: phi1b(numPatchesPerCol,numpft_ed) ! Radiation transmitted to the soil surface.
real(r8) :: phi2b(numPatchesPerCol,numpft_ed)
real(r8) :: phi1b(maxPatchesPerCol,numpft_ed) ! Radiation transmitted to the soil surface.
real(r8) :: phi2b(maxPatchesPerCol,numpft_ed)
real(r8) :: laisum ! cumulative lai+sai for canopy layer (at middle of layer)
real(r8) :: angle

Expand All @@ -107,8 +107,8 @@ subroutine ED_Norman_Radiation (nsites, sites, bc_in, bc_out )
integer :: fp,iv,s ! array indices
integer :: ib ! waveband number
real(r8) :: cosz ! 0.001 <= coszen <= 1.000
real(r8) :: chil(numPatchesPerCol) ! -0.4 <= xl <= 0.6
real(r8) :: gdir(numPatchesPerCol) ! leaf projection in solar direction (0 to 1)
real(r8) :: chil(maxPatchesPerCol) ! -0.4 <= xl <= 0.6
real(r8) :: gdir(maxPatchesPerCol) ! leaf projection in solar direction (0 to 1)

!-----------------------------------------------------------------------

Expand Down
4 changes: 0 additions & 4 deletions components/clm/src/ED/main/EDInitMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,6 @@ subroutine zero_site( site_in )
site_in%oldest_patch => null() ! pointer to oldest patch at the site
site_in%youngest_patch => null() ! pointer to yngest patch at the site

! INDICES
site_in%lat = nan
site_in%lon = nan

! DISTURBANCE
site_in%disturbance_rate = 0._r8 ! site level disturbance rates from mortality and fire.
site_in%dist_type = 0 ! disturbance dist_type id.
Expand Down
Loading

0 comments on commit 492c1cb

Please sign in to comment.