-
Notifications
You must be signed in to change notification settings - Fork 92
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
change cohort fusion to conserve crown area #447
change cohort fusion to conserve crown area #447
Conversation
I know I'm on the margins of FATES development, but switching fusion from conserving biomass to conserving canopy area sounds like its going to have unintended consequences for a lot of users and applications, which often are explicitly focused on carbon budgets (and thus need to conserve mass). |
Hi @mdietze -- sorry, I was unclear. Biomass is still absolutely conserved. What is temporarily not conserved (until the subsequent timestep) is the biomass-to-dbh allometric relationship. The allometry scheme is happy for the biomass to be below allometry, but doesn't know what to do during growth if the biomass is above allometry, so when a cohort that is above its allometric biomass target tries to grow, the first step is to increment the dbh to put it back on the allometric curve. One aspect of this PR is that this putting-a-cohort-back-on-allometry step only happens during growth, not as part of the fusion process. |
biogeochem/EDCohortDynamicsMod.F90
Outdated
call StructureResetOfDH( currentCohort%prt%GetState(struct_organ,all_carbon_elements), currentCohort%pft, & | ||
currentCohort%canopy_trim, currentCohort%dbh, currentCohort%hite ) | ||
end if | ||
if (dbh .eq. fates_unset_r8) then |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is fates_unset_r8?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah, i see, it means it's not set. Fair enough. Maybe add a comment so one doesn't need to go and look up the definition to understand this bit?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there's a comment on line 749 of EDcohortdynamics which needs changing to reflect the new logic. Otherwise I checked this and it all makes sense...
Good to know you're keeping an eye on FATES @mdietze :) |
1 similar comment
Good to know you're keeping an eye on FATES @mdietze :) |
…mization to inverse crown area allometry. Implemented safer logic against a real.
…ster integrate minor updates to crown-conservation
@rgknox Yes, I think we should run this through the full baseline check to make sure it doesn't change things in any appreciable way. |
sounds good. I will to a multi-decade run at BCI and see how things compare to master. |
Late to the party as usual. Just been chatting with @ckoven and @rosiealice and it seems I have a controversial suggestion for an alternative conservation scheme in the cohort fusion process. Canopy area, biomass, population weighted dbh, the canopy area to dbh allometry AND the biomass to dbh allometry can all be conserved if the number density is adjusted. This would change the number individuals when the two cohorts are fused, which is the controversial bit, but mass, canopy area, and allometries would all be conserved. These three variables are more integrated in the mechanics of the model processes than is the number of individuals. I would expect this to make cohort fusion a smoother process. The argument against this is that the number of individuals in a forest is measurable and so varying individual number during fusion would mess with our ability to compare against observations. I don't have a good sense of how large the change in individuals will be but I imagine that it would be small, perhaps even in the fractions of an individual which wouldn't affect our comparison to observations. In itself, that fractions of an individual can be represented suggests that we are not strict about preserving the realism of individuals. @ckoven suggested that this would be worth testing and that he would add switch to this pull request to select alternative fusion cases. I can try to add this third case of flexible individual number. Would be interested to hear further thoughts from those more familiar with ED: @mdietze @rgknox @tompowell9 |
an update on this PR: @rgknox ran tests a while ago, and it was not as close to master as we had hoped. So I've re-written the logic to allow either the old behavior (conservation of DBH) or the modified behavior (conservation of crown area) based on a switch. Currently the switch is hard-coded but maybe we should move it to the parameter file. In discussion with @walkeranthonyp last week, he had suggested a third option which he describes above, which I am happy to explore too. So, @walkeranthonyp, the code should now be ready for you to add your third option into. I suggest we may need to investigate further here to see what the effect of the cohort fusion logic is on model behavior. I think this may call for an experiment using prescribed physiology mode, where we create a sort of benchmark case with tiny tolerances for cohort fusion and thus lots of cohorts, and then compare that to the various logic options here with more tractable cohort fusion parameters. |
@ckoven assignment noted. This is a good reason for me to get set up running FATES. It's prob going to take me a bit to get things working so let me know if I'm holding things up. |
@walkeranthonyp great, thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From what my testing has shown, this set of changes is important in reducing error during plant promotion/demotion. I've gone through these changes in some detail myself.
Note there was a compile-time error that needed to be tracked down, but it was trivial.
Hey folks, there is a critical batch of bug-fixes coming down the pipe. These bug fixes partially require this set of changes. I'm going to set this PR to high priority to prepare for that next PR. |
@ckoven , is the "not ready" label still required? |
Hi @rgknox incorporating this PR is fine with me if it is important for overall numerical stability. We can bring @walkeranthonyp's proposed changes in as a different PR. |
@walkeranthonyp I was re-visiting this closed PR, and wanted to ask about your idea to alter number density in fusion and conserve other parameters. Perhaps we open a separate issue on that idea to keep it in the forefront? |
This PR slightly revises the cohort fusion routine, so that it conserves crown area during the fusion timestep instead of conserving total stem diameter.
Description:
Currently, when cohorts fuse, the resulting cohort tries to conserve total diameter of the two fusing cohorts. I ran into an issue where, when cohorts get really big, the numerical errors in crown area conservation get big enough to crash things. This got me thinking that the way we do cohort fusion might be leading to more numerical errors than needed, because of the lack of crown area conservation during cohort fusion, which is itself typically a part of canopy structuring. What happens in a typical canopy structure loop is that we split the cohorts between the canopy and the understory, which in general this causes some cohort to get moved between strata. But upon arrival in the new strata, the small cohort will typically find a similarly sized cohort already there, and will get fused. But because we don't conserve crown are during fusion, the total post-fusion crown area has changed, and thus the canopy structure logic isn't what it thought it was.
So what this PR does is, when fusing cohorts, to calculate the DBH of the newly fused cohort as being that DBH which conserves total crown area and the dbh-crown area allometry. further, in the event that dbh is to be incremented based on the biomass allometry to put it back on the biomass allometry, instead of immediately recalculating the dbh, it waits until the next growth step to do that. that way, if the fusion happens during the canopy structure logic, it conserves crown area during that timestep, even if doing so causes it to be above its biomass allometry, and then resets the dbh to go back onto allometry at the start of the next growth timestep.
Fixes #442.
Collaborators:
Discussions with @rgknox and @rosiealice
Expectation of Answer Changes:
This should be answer changing but at the level of noise, except for the weird edge cases that gave rise to #442. Possibly by better conserving crown area during canopy structure it might reduce radiation numerical error.
Checklist:
Test Results:
Not formally tested yet. hold until tests done.