ESCOMP / CTSM

Community Terrestrial Systems Model (includes the Community Land Model of CESM)
http://www.cesm.ucar.edu/models/cesm2.0/land/
Other
302 stars 307 forks source link

FATES doesn't work with new biomass heat storage option added into clm5_1 physics needs stem/leaf biomass (and move biomass calc to veg model) #1247

Open ekluzek opened 3 years ago

ekluzek commented 3 years ago

FATES doesn't work with the new biomass heat storage (BHS) option which is turned on for clm5_1 physics. The missing bit is that FATES needs to tell CTSM as HLM what the stem and leaf biomass is. It already tells it LAI and SAI and HTOP which are also needed. BHS was added in with ctsm5.1.dev021.

NOTE: BHS is only turned on for trees and shrubs.

The calculation of biomass heat storage is in CanopyFluxes. Inputs to the calculation are:

esai, elai, htop. -- These are already provided --- These will need to be set for FATES stem_biomass leaf_biomass

parameters on the parameter file are: fbw (fraction of biomass that's water), wood_density for the SP version: dbh_param (diameter at breast height)

For the big-leaf version nstem (stem number density) is on the parameter file as well. Does FATES calculate this?

Here's a section that will likely need a FATES option that currently only has a BGC option or SP option. It's possible that FATES could use the BGC option if it sets stem_biomass and it's ok to use nstem from the parameter file.

            ! if using Satellite Phenology mode, use values in parameter file
            ! otherwise calculate dbh from stem biomass
            if(use_cn) then
               if(stem_biomass(p) > 0._r8) then
                  dbh(p) = 2._r8 * sqrt(stem_biomass(p) * (1._r8 - fbw(patch%itype(p))) &
                       / ( shr_const_pi * htop(p) * k_cyl_vol &
                       * nstem(patch%itype(p)) *  wood_density(patch%itype(p))))
               else
                  dbh(p) = 0._r8
               endif
            else
               dbh(p) = dbh_param(patch%itype(p))
            endif

Also as noted below we should move the biomass calculations to inside of their source veg model (BGC code, SP code, or FATES code).

ekluzek commented 3 years ago

The way BGC calculates biomass is as follows in CNVegStructUpdate:

                  ! Assumes fbw (fraction of biomass that is water) is the same for leaves and stems
                  leaf_biomass(p) = max(0.0025_r8,leafc(p)) &
                       * c_to_b * 1.e-3_r8 / (1._r8 - fbw(ivt(p)))

                  stem_biomass(p) = (spinup_factor_deadwood*deadstemc(p) + livestemc(p)) &
                       * c_to_b * 1.e-3_r8 / (1._r8 - fbw(ivt(p)))

For SP it calculates it as (in CanopyFluxes):

               ! boreal needleleaf lma*c2b ~ 0.25 kg dry mass/m2(leaf)
               leaf_biomass(p) = 0.25_r8 * max(0.01_r8, sa_leaf(p)) &
                    / (1.-fbw(patch%itype(p)))
               stem_biomass(p) = carea_stem * htop(p) * k_cyl_vol &
                    * nstem(patch%itype(p)) * wood_density(patch%itype(p)) &
                    /(1.-fbw(patch%itype(p)))
ekluzek commented 3 years ago

Moving a conversation from the PR to here:

https://github.com/ESCOMP/CTSM/pull/1016#pullrequestreview-564388250

swensosc commented 3 years ago

So can we move the canopyfluxes calculation to CNVegStructUpdate?

swensosc commented 3 years ago

It looks like we may be able to remove the hard-coded value of 0.25 in the leaf biomass calculation and use the existing slatop parameter:

               ! 2gbiomass/gC * (1/SLA) * 1e-3 = kg dry mass/m2(leaf)
               leaf_biomass(p) = (1.e-3_r8*c_to_b/slatop(patch%itype(p))) &
                    * max(0.01_r8, 0.5_r8*sa_leaf(p)) &
                    / (1.-fbw(patch%itype(p)))
               ! cross-sectional area of stems
               carea_stem = shr_const_pi * (dbh(p)*0.5)**2
               stem_biomass(p) = carea_stem * htop(p) * k_cyl_vol &
                    * nstem(patch%itype(p)) * wood_density(patch%itype(p)) &
                    /(1.-fbw(patch%itype(p)))

Note I've moved carea_stem inside the if-block, and used c_to_b from clm_varcon.

ekluzek commented 3 years ago

Note, as stated in PR #1016 a refactoring we should do is to lift the calculation of stem_biomass and leaf_biomass out of CanopyFluxes and put it in a higher level that's done for either: SP, FATES, or BGC. This would remove the need for CanopyFluxes to know what veg model is underneath it.

And yes @swensosc I think that's the answer to your question. We should remove the use_cn calculation of biomass inside of CanopyFluxes and put it in CNVegStrucUpdate. The SP calculation should be done in the relevant SP code. And likely FATES will set it in clmfates_interfaceMod.F90.

ekluzek commented 3 years ago

@rgknox here you go.