Skip to content

small inconsistency in accounting for capac residual? #990

@gmao-rreichle

Description

@gmao-rreichle

@rdkoster:
Near the end of subroutine catchment(), we compute (total) RUNOFF as the sum of surface runoff and baseflow:


Immediately thereafter, we check for negligible amounts of CAPAC (<1e-10) and convert them into (total) RUNOFF:

Don't we also need to add CAPAC(N)/DTSTEP to RUNSRF (or, alternatively, to BFLOW) so as to maintain consistency with (total) RUNOFF?
The water amounts involved are probably so small that in practice nobody ever notices. But we go to the trouble of accounting for them in RUNOFF, so maybe it's worth to also adjust the runoff components for consistency.
Please advise, thanks

PS: Here's the full block of code for reference (lines 1271-1275 in today's version of the "develop" branch)

        RUNOFF(N) = RUNSRF(N)+BFLOW(N)
        IF(CAPAC(N).LT.1.E-10) THEN
           RUNOFF(N) = RUNOFF(N)+CAPAC(N)/DTSTEP
           CAPAC(N) = 0.0
           endif

cc: @biljanaorescanin

Metadata

Metadata

Assignees

No one assigned

    Labels

    Non 0-diffThe changes in this pull request are non-zero-diffbugSomething isn't workingquestion ❔Further information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions