zero outgoing flow set water body pointer to res initialize variables for wetland daily simulation add precipitation - mmha10.=m3 (used same area for infiltration and soil evap) add irrigation water to the paddy/wetland storage update wetland surface area - solve quadratic to find new depth infiltration of the standing water to the topsoil layer. Any excess infiltration volume estimated here is reverted (back to waterbody) in swr_satexcess. compute depth and set weir_hgt wetland outflow using weir equation or decision table weir discharge by manual operation Jaehak 2025 discharge (ht2) by decision tables subtract outflow from wetland storage (similar to res_control) surface runoff from wetland is discharge (outflow) ht2 daily total runoff compute sediment deposition perform reservoir nutrient balance perform salt ion constituent balance perform wetland constituent balance perform reservoir pesticide transformations
set values for routing variables undefined
set inflow and outflow variables for reservoir_output