Skip to content
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

Modifies respiration diag #52

Merged
merged 1 commit into from
Mar 7, 2022

Conversation

MichaelBarryBMT
Copy link
Contributor

Hi Matt

This is similar to #51.

The new respiration diags for C, N and P all use the variables "phy", "INi" and "IPi". These change with phyto group but the location of the diag writing for diags id_PhyRSPc, id_PhyRSPn and id_PhyRSPp mean that the values of phy, INi and IPi from the last phyto group were being used to compute and write these respiration diags. This meant that if simulating two phyto groups, both were recording the same respiration diag data (i.e. that of the second phyto group) because phy, INi and IPi were the values left over from the previous loop on num_phy. Mass balance calculations were affected and the diags were difficult to interpret.

This suggestion reloads the correct phyto group by phyto group values of phy, INi and IPi before calculating and recording the respiration diagnostics. I have run the revised code and this fixes the mass balance issues.

MB

@matthipsey matthipsey merged commit 0d35fc4 into AquaticEcoDynamics:master Mar 7, 2022
@MichaelBarryBMT MichaelBarryBMT deleted the Resp-diags branch March 7, 2022 22:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants