Clarify SIPNET wood-storage bookkeeping around harvest and outputs
Maintainers usually reply within 2 days
Assessment
This issue has not been assessed yet.
Description
Summary
SIPNET tracks wood carbon in two pieces:
structural wood = envi.plantWoodC
storage delta = envi.plantWoodCStorageDelta
reported wood = structural wood + storage delta
storage delta can be negative because it is a bookkeeping. But SIPNET does not clearly define or test what should happen when this storage term interacts with harvest, turnover, respiration, and output reporting.
Related:
- #325
- #324
Potential Issues
Harvest calculates affected wood using:
woodC = envi.plantWoodC + envi.plantWoodCStorageDelta;
but the event update applies the wood change only to:
envi.plantWoodC
and does not update envi.plantWoodCStorageDelta.
That means a full aboveground harvest can remove more wood than exists in the structural pool, after which structural wood is clamped to zero while positive storage remains. The result is that sipnet.out can still report positive plantWoodC after a harvest that appears intended to remove all aboveground wood.
Negative storage is allowed, but if:
envi.plantWoodC + envi.plantWoodCStorageDelta < 0
then wood respiration and wood turnover can become negative because they use this sum directly.
Suggested fix
Make the intended functionality explicit and add focused tests:
- Decide whether harvest acts on structural wood, reported/effective wood, or both.
- Prevent negative effective wood from creating negative respiration or turnover fluxes.
- Update the output docs for
plantWoodCandnppStorage. - Add tests for harvest with positive and negative storage.
- Dominant language
- C
- Stars
- 42
- Forks
- 38
- Avg merge
- 3d 21h
- Merged PRs (30d)
- 10
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from PecanProject/sipnet
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
PecanProject/sipnet#435 · 1 comment ·
Maintainers usually reply within 2 days
-
Make sure that documentation of sipnet.out header reflects implementationMay be free again @ANAMASGARD claimed this 153 days ago, and no pull request is open. Opendocumentation good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
PecanProject/sipnet#345 · 8 comments · 1 reaction ·
Maintainers usually reply within 2 days
-
Remove unused `Tracker` fieldsMay be free again @ANAMASGARD claimed this 11 days ago, and no pull request is open. Opengood first issue on hold
Difficulty 4/5 3-5 days Newbie friendliness 45/100
PecanProject/sipnet#430 · 1 comment · 1 reaction ·
Maintainers usually reply within 2 days
-
Event checks ignore every events.in record after the firstPossibly taken @ANAMASGARD claimed this 11 days ago. Open
Difficulty 3/5 1-2 days Newbie friendliness 70/100
PecanProject/sipnet#429 · 3 comments · 1 assignee ·
Maintainers usually reply within 2 days
-
Events: revamp handling of "big delta" events to post-pool-updatePossibly taken @Alomir claimed this 13 days ago. Open
PecanProject/sipnet#423 · 1 assignee ·
Maintainers usually reply within 2 days
All issues in PecanProject/sipnet
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
follow-up Prio 📌
Difficulty 1/5 Under an hour Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
area: test kind: bug preview-effort: small priority: low
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
libsdl-org/SDL#16684 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100