|
hydrobricks
|
#include <ProcessRoutingGR4J.h>
Public Member Functions | |
| ProcessRoutingGR4J (WaterContainer *container) | |
| void | SetParameters (const ProcessSettings &processSettings) override |
| void | Reset () override |
| void | Finalize () override |
| double * | GetValuePointer (std::string_view name) override |
Public Member Functions inherited from ProcessOutflow | |
| ProcessOutflow (WaterContainer *container) | |
| bool | IsValid () const override |
| int | GetConnectionCount () const override |
Public Member Functions inherited from Process | |
| Process (WaterContainer *container) | |
| virtual void | Validate () const |
| virtual void | SetHydroUnitProperties (HydroUnit *unit, Brick *brick) |
| virtual void | AttachForcing (Forcing *) |
| void | AttachFluxOut (std::unique_ptr< Flux > flux) |
| int | GetOutputFluxCount () const |
| Flux * | GetOutputFlux (size_t index) const |
| virtual bool | ToAtmosphere () const |
| virtual bool | NeedsTargetBrickLinking () const |
| virtual vecDouble | GetChangeRates () |
| virtual void | StoreInOutgoingFlux (double *rate, int index) |
| void | ApplyChange (int connectionIndex, double rate, double timeStepInDays) |
| virtual vecDoublePt | GetStateVariables () |
| const string & | GetName () const |
| void | SetName (const string &name) |
| void | SetTimeMachine (TimeMachine *timeMachine) |
| WaterContainer * | GetWaterContainer () const |
| virtual void | SetTargetBrick (Brick *) |
| virtual bool | IsLateralProcess () const noexcept |
| bool | HasOutputFluxes () const noexcept |
| bool | HasWaterContainer () const noexcept |
Static Public Member Functions | |
| static void | RegisterProcessSettings (SettingsModel *modelSettings) |
Static Public Member Functions inherited from ProcessOutflow | |
| static void | RegisterProcessSettings (SettingsModel *modelSettings) |
Static Public Member Functions inherited from Process | |
| static std::unique_ptr< Process > | Factory (const ProcessSettings &processSettings, Brick *brick) |
| static bool | RegisterSettings (SettingsModel *modelSettings, const string &processType) |
| static bool | HasParameter (const ProcessSettings &processSettings, std::string_view name) |
| static const float * | GetParameterValuePointer (const ProcessSettings &processSettings, std::string_view name) |
Protected Member Functions | |
| vecDouble | GetRates () override |
| void | _recomputeUH () |
Protected Member Functions inherited from Process | |
| double | GetSumChangeRatesOtherProcesses () const |
Static Protected Member Functions | |
| static double | _sh1 (double t, double x4) |
| static double | _sh2 (double t, double x4) |
Protected Attributes | |
| const float * | _exchangeFactor |
| const float * | _routingCapacity |
| const float * | _uhBaseTime |
| vecDouble | _stuh1 |
| vecDouble | _stuh2 |
| vecDouble | _uh1Ord |
| vecDouble | _uh2Ord |
| double | _r |
| double | _qr |
| double | _qd |
| double | _processStorage |
Protected Attributes inherited from Process | |
| string | _name |
| WaterContainer * | _container |
| TimeMachine * | _timeMachine {nullptr} |
| std::vector< std::unique_ptr< Flux > > | _outputs |
GR4J routing: unit-hydrograph convolution + non-linear routing store.
The uh_input brick accumulates PR = (Pn − Ps) + Perc each timestep. GetRates() computes Q in a read-only fashion (no buffer mutation) so the Heun solver can call it multiple times without corrupting state. The UH buffers and routing store are advanced exactly once per timestep in Finalize(), using the final inflow amounts.
|
protected |
Recompute UH ordinates and resize buffers based on current X4.
|
overridevirtual |
Advance UH buffers and routing store once per timestep.
Reimplemented from Process.
|
overrideprotectedvirtual |
Get the rates of the process.
Read-only: computes Q from current buffer state without modifying it. Buffer advancement happens in Finalize() exactly once per timestep.
Implements Process.
|
overridevirtual |
Get the value pointer for a given element.
| name | name of the element to get. |
Reimplemented from ProcessOutflow.
|
static |
Register the process settings (parameters, forcing, and logging defaults) in the settings model.
|
overridevirtual |
Reset all the fluxes connected to the process.
Reimplemented from Process.
|
overridevirtual |
Assign the parameters to the process.
| processSettings | settings of the process containing the parameters. |
Reimplemented from Process.