Skip to content

Commit

Permalink
fixed some issues that rgknox pointed out in PR
Browse files Browse the repository at this point in the history
  • Loading branch information
ckoven committed Jan 21, 2017
1 parent f01774b commit 19a7bce
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion components/clm/src/ED/biogeochem/EDPatchDynamicsMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1170,7 +1170,7 @@ subroutine fuse_2_patches(dp, rp)

!area weighted average of ages & litter
rp%age = (dp%age * dp%area + rp%age * rp%area)/(dp%area + rp%area)
rp%age_class = max(1,count(rp%age-ageclass_ed.ge.0.0_r8))
rp%age_class = count(rp%age-ageclass_ed.ge.0.0_r8)

do p = 1,numpft_ed
rp%seeds_in(p) = (rp%seeds_in(p)*rp%area + dp%seeds_in(p)*dp%area)/(rp%area + dp%area)
Expand Down
10 changes: 5 additions & 5 deletions components/clm/src/ED/main/FatesHistoryInterfaceMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1343,22 +1343,22 @@ subroutine define_history_vars(this, initialize_variables)
avgflag='A', vtype=patch_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_canopy_spread_pa)

call this%set_history_var(vname='PFTbiomass', units='gC/m2', &
call this%set_history_var(vname='PFT_BIOMASS', units='gC/m2', &
long='total PFT level biomass', use_default='active', &
avgflag='A', vtype=site_pft_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_biomass_si_pft )

call this%set_history_var(vname='PFTleafbiomass', units='gC/m2', &
call this%set_history_var(vname='PFT_LEAF_BIOMASS', units='gC/m2', &
long='total PFT level leaf biomass', use_default='active', &
avgflag='A', vtype=site_pft_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_leafbiomass_si_pft )

call this%set_history_var(vname='PFTstorebiomass', units='gC/m2', &
call this%set_history_var(vname='PFT_STORE_BIOMASS', units='gC/m2', &
long='total PFT level stored biomass', use_default='active', &
avgflag='A', vtype=site_pft_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_storebiomass_si_pft )

call this%set_history_var(vname='PFTnindivs', units='indiv / m2', &
call this%set_history_var(vname='PFT_N_INDIVS', units='indiv / m2', &
long='total PFT level number of individuals', use_default='active', &
avgflag='A', vtype=site_pft_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_nindivs_si_pft )
Expand All @@ -1380,7 +1380,7 @@ subroutine define_history_vars(this, initialize_variables)
ivar=ivar, initialize=initialize_variables, index = ih_canopy_area_si_age )

call this%set_history_var(vname='NCL_BY_AGE', units='--', &
long='number of canopy levels by age bin', use_default='active', &
long='number of canopy levels by age bin', use_default='inactive', &
avgflag='A', vtype=site_age_r8, hlms='CLM:ALM', flushval=0.0_r8, upfreq=1, &
ivar=ivar, initialize=initialize_variables, index = ih_ncl_si_age )

Expand Down
10 changes: 5 additions & 5 deletions components/clm/src/main/histFileMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2321,15 +2321,15 @@ subroutine htape_timeconst(t, mode)

if(use_ed)then
call ncd_defvar(varname='levscls', xtype=tape(t)%ncprec, dim1name='levscls', &
long_name='diameter size class lower bound', units='cm', ncid=nfid(t))
long_name='FATES diameter size class lower bound', units='cm', ncid=nfid(t))
call ncd_defvar(varname='pft_levscpf',xtype=ncd_int, dim1name='levscpf', &
long_name='pft index of the combined pft-size class dimension', units='-', ncid=nfid(t))
long_name='FATES pft index of the combined pft-size class dimension', units='-', ncid=nfid(t))
call ncd_defvar(varname='scls_levscpf',xtype=ncd_int, dim1name='levscpf', &
long_name='size index of the combined pft-size class dimension', units='-', ncid=nfid(t))
long_name='FATES size index of the combined pft-size class dimension', units='-', ncid=nfid(t))
call ncd_defvar(varname='levage',xtype=tape(t)%ncprec, dim1name='levage', &
long_name='patch age (yr)', ncid=nfid(t))
long_name='FATES patch age (yr)', ncid=nfid(t))
call ncd_defvar(varname='levpft',xtype=ncd_int, dim1name='levpft', &
long_name='pft number', ncid=nfid(t))
long_name='FATES pft number', ncid=nfid(t))
end if

elseif (mode == 'write') then
Expand Down

0 comments on commit 19a7bce

Please sign in to comment.