Skip to content

Fix wetland yearly and average annual outputs#181

Open
leonard-bernard-jannin wants to merge 2 commits intoswat-model:mainfrom
leonard-bernard-jannin:main
Open

Fix wetland yearly and average annual outputs#181
leonard-bernard-jannin wants to merge 2 commits intoswat-model:mainfrom
leonard-bernard-jannin:main

Conversation

@leonard-bernard-jannin
Copy link

Two bugs in wetland_output.f90 caused incorrect flo_in and flo_out values in the yearly (wetland_yr) and average annual (wetland_aa) outputs:

  1. Yearly output (wetland_yr): flo_in and flo_out were incorrectly divided by 12 before being written. Additionally, the yearly accumulators (wet_in_y, wet_out_y, wet_wat_y) were not reset after writing, causing values to carry over into subsequent years.

  2. Average annual output (wetland_aa): flo_in and flo_out were averaged using the yearly accumulator (wet_in_y, wet_out_y) instead of the simulation-long accumulator (wet_in_a, wet_out_a), producing wrong average annual values.

@tugraskan
Copy link
Collaborator

Looks good to me.

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.

2 participants