ImperialCollegeLondon / wsi

WSIMOD is a software for simulating water quality and quantity
https://imperialcollegelondon.github.io/wsi/
BSD 3-Clause "New" or "Revised" License
12 stars 2 forks source link

Refactor river biochemical processes #2

Open barneydobson opened 1 year ago

barneydobson commented 1 year ago

Currently difficult to understand and hard to test. Needs to be split into sensible functions.

barneydobson commented 4 months ago

calculate_discharge, which calls biochemical_processes, is currently commented out in the distribute function

liuly12 commented 4 months ago

In the River node, these parameters were in CatchWat for solids simulation but not used in the current version. There will be very little chance to reuse them again so removed by commit c0a192120002ad6e5ae65cf90718f641b0167e0a in #81

        self.qbank_365_days = [1e6, 1e6]  # [m3/day] store outflow in the previous year
        self.qbank = (
            1e6  # [m3/day] bankfull flow = second largest outflow in the previous year
        )
        self.qbankcorrpar = 0.001  # [-] correction coefficient for qbank flow
        self.sedexppar = 1  # [-]
        self.EPC0 = 0.05 * constants.MG_L_TO_KG_M3  # [mg/l]
        self.kd_s = 0 * constants.MG_L_TO_KG_M3  # 6 * 1e-6, # [kg/m3]
        self.kadsdes_s = 2  # 0.9, # [-]
        self.Dsed = 0.2  # [m]