-
Notifications
You must be signed in to change notification settings - Fork 32
[339] Rename plantWoodCStorageDelta to plantWoodCAccountingDelta #344
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
Open
ANAMASGARD
wants to merge
4
commits into
PecanProject:master
Choose a base branch
from
ANAMASGARD:rename/plantWoodCAccountingDelta-closes-339
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
a10c4b7
[339] Rename plantWoodCStorageDelta to plantWoodCAccountingDelta
ANAMASGARD a03a481
[339] Drop legacy restart key for plantWoodCAccountingDelta
ANAMASGARD 8af1cf5
[339] Address review: rename debug column to cnDelta and update docs
ANAMASGARD 97b395e
Merge branch 'master' into rename/plantWoodCAccountingDelta-closes-339
ANAMASGARD File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -439,8 +439,8 @@ void outputHeader(FILE *out) { | |
| "rRoot ra rh rtot evapotranspiration "); | ||
| fprintf(out, | ||
| "fluxestranspiration minN soilOrgN litterN " | ||
| "plantStorageN n2o nLeaching nFixation nUptake ch4 " | ||
| "nppStorage\n"); | ||
| "plantStorageN n2o nLeaching nFixation nUptake ch4 " | ||
| "cnDelta\n"); | ||
| } | ||
|
|
||
| /*! | ||
|
|
@@ -453,7 +453,7 @@ void outputHeader(FILE *out) { | |
| void outputState(FILE *out, int year, int day, double time) { | ||
|
|
||
| fprintf(out, "%4d %3d %5.2f %10.2f %10.2f %12.2f ", year, day, time, | ||
| (envi.plantWoodC + envi.plantWoodCStorageDelta), envi.plantLeafC, | ||
| (envi.plantWoodC + envi.plantWoodCAccountingDelta), envi.plantLeafC, | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. For legacy reasons, I think we want to leave that column named As for |
||
| trackers.woodCreation); | ||
| fprintf(out, "%8.2f ", envi.soilC); | ||
| fprintf(out, "%11.2f %9.2f ", envi.coarseRootC, envi.fineRootC); | ||
|
|
@@ -467,10 +467,10 @@ void outputState(FILE *out, int year, int day, double time) { | |
| trackers.rh, trackers.rtot, trackers.evapotranspiration); | ||
| fprintf(out, "%19.4f %8.4f %9.4f %10.4f %14.4f ", fluxes.transpiration, | ||
| envi.minN, envi.soilOrgN, envi.litterN, envi.plantStorageN); | ||
| fprintf(out, "%9.6f %9.4f %10.4f %8.4f %8.4f", trackers.n2o, | ||
| fprintf(out, "%9.6f %9.4f %10.4f %8.4f %8.4f ", trackers.n2o, | ||
| trackers.nLeaching, trackers.nFixation, trackers.nUptake, | ||
| trackers.methane); | ||
| fprintf(out, "%12.4f\n", envi.plantWoodCStorageDelta); | ||
| fprintf(out, "%9.4f\n", envi.plantWoodCAccountingDelta); | ||
| } | ||
|
|
||
| // de-allocate space used for climate linked list | ||
|
|
@@ -1075,7 +1075,7 @@ void vegResp(double *folResp, double *woodResp, double baseFolResp) { | |
|
|
||
| // :: from [1], eq (A19) | ||
| *woodResp = params.baseVegResp * | ||
| (envi.plantWoodC + envi.plantWoodCStorageDelta) * | ||
| (envi.plantWoodC + envi.plantWoodCAccountingDelta) * | ||
| pow(params.vegRespQ10, climate->tair / 10.0); | ||
| } | ||
|
|
||
|
|
@@ -1103,7 +1103,7 @@ void vegResp2(double *folResp, double *woodResp, double *growthResp, | |
| // by a given fraction in winter | ||
| } | ||
| *woodResp = params.baseVegResp * | ||
| (envi.plantWoodC + envi.plantWoodCStorageDelta) * | ||
| (envi.plantWoodC + envi.plantWoodCAccountingDelta) * | ||
| pow(params.vegRespQ10, climate->tair / 10.0); | ||
|
|
||
| // Rg is a fraction of the recent mean NPP | ||
|
|
@@ -1206,8 +1206,8 @@ void calcRootAndWoodFluxes(void) { | |
|
|
||
| // Wood litter, in g C * m^-2 ground area * day^-1 | ||
| // turnover rate is fraction lost per day | ||
| fluxes.woodLitter = | ||
| (envi.plantWoodC + envi.plantWoodCStorageDelta) * params.woodTurnoverRate; | ||
| fluxes.woodLitter = (envi.plantWoodC + envi.plantWoodCAccountingDelta) * | ||
| params.woodTurnoverRate; | ||
|
|
||
| // :: from [3], root model description | ||
| calcRootResp(&fluxes.rCoarseRoot, params.coarseRootQ10, | ||
|
|
@@ -1611,7 +1611,7 @@ void updateMainPools(void) { | |
| double r_a = fluxes.rVeg + fluxes.rFineRoot + fluxes.rCoarseRoot; | ||
| double nppAllocations = fluxes.leafCreation + fluxes.woodCreation + | ||
| fluxes.fineRootCreation + fluxes.coarseRootCreation; | ||
| envi.plantWoodCStorageDelta += | ||
| envi.plantWoodCAccountingDelta += | ||
| ((fluxes.photosynthesis - r_a) - nppAllocations) * climate->length; | ||
| envi.plantWoodC += (fluxes.woodCreation - fluxes.woodLitter - | ||
| fluxes.leafOnCreationFromWood) * | ||
|
|
@@ -1806,7 +1806,7 @@ void setupModel(void) { | |
|
|
||
| envi.plantWoodC = | ||
| (1 - params.coarseRootFrac - params.fineRootFrac) * params.plantWoodInit; | ||
| envi.plantWoodCStorageDelta = 0.0; | ||
| envi.plantWoodCAccountingDelta = 0.0; | ||
| envi.plantLeafC = params.laiInit * params.leafCSpWt; | ||
|
|
||
| if (ctx.litterPool) { | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I don't think we want to support the legacy key
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.
Agreed, it has not been around long enough (and is an internal detail)