<<<<<<<< HEAD:docs/classcmf_1_1water_1_1_constraint_linear_storage_connection.html
1.6.0
========
2.0.0b10
>>>>>>>> cmf2:docs/classcmf_1_1water_1_1_constraint_linear_storage_flux.html
catchment modelling framework
Loading...
Searching...
No Matches
ConstraintLinearStorageFlux Class Reference

Calculates flux out of a storage as a linear function of its volume, constraint by the volume stored in the target storage. More...

+ Inheritance diagram for ConstraintLinearStorageFlux:
+ Collaboration diagram for ConstraintLinearStorageFlux:

Detailed Description

Calculates flux out of a storage as a linear function of its volume, constraint by the volume stored in the target storage.

\[ q = \frac {1}{t_r} \left({V_{l} - V_{l,min}}\right) \cdot \left(\frac{V_{r,max}-V_{r}}{V_{r,max}}\right)\]

where:

  • \(V_l\) The actual volume stored by the left water storage
  • \(V_{l,min} [m^3]\) The volume of water not flowing out (default = 0)
  • \(\beta\) A parameter to shape the response curve. In case of \(\beta \neq 1\), \(t_r\) is not a residence time, but just a parameter.
  • \(t_r [days]\) The residence time of the water in this storage in days
  • \(V_{r,max}\) The capacity of the right water storage in m3
  • \(V_{r}\) The actual volume of the right water storage
  • \(\gamma\) A shape parameter for the target capacity constriction

Public Member Functions

 ConstraintLinearStorageFlux (WaterStorage::ptr source, WaterStorage::ptr target, real residencetime=1.0, real Vlmin=0.0, real Vrmax=1.0)
 Creates a linear storage connection, constrained by the fill level of the source.
 
real conc (cmf::math::Time t, const cmf::water::solute &_Solute)
 Returns the concentration of the flux.
 
flux_node::ptr get_target (const flux_node &inquirer)
 Returns the other end of a connection than the asking end.
 
flux_node::ptr get_target (int index) const
 With index 0, the left node is returned, with index 1 the right node of the connection.
 
real get_tracer_filter ()
 A value ranging from 0 to 1 to filter tracers out of the water flux.
 
real get_tracer_filter (solute S)
 A value ranging from 0 to 1 to filter tracers out of the water flux.
 
bool kill_me ()
 Deregisters this connection from its nodes. Returns true if only one reference is left.
 
flux_node::ptr left_node () const
 Returns the left node of this connection.
 
real q (const flux_node &inquirer, cmf::math::Time t)
 Returns the current flux through a connection. Negative signs mean out of the inquirer, positive are inflows to the inquirer.
 
void refresh (cmf::math::Time t)
 Performes a new calculation of the flux.
 
flux_node::ptr right_node () const
 returns the right node of this connection
 
void set_tracer_filter (real value)
 A value ranging from 0 to 1 to filter tracers out of the water flux.
 

Public Attributes

real residencetime
 Linear flow parameter traveltime in days.
 
const std::string type
 A string describing the type of the connection.
 
real Vlmin
 residual volume \(V_{l,min}\) in left storage
 
real Vrmax
 Target capacity \(V_{r,max}\).
 

Constructor & Destructor Documentation

◆ ConstraintLinearStorageFlux()

ConstraintLinearStorageFlux ( WaterStorage::ptr source,
WaterStorage::ptr target,
real residencetime = 1.0,
real Vlmin = 0.0,
real Vrmax = 1.0 )

Creates a linear storage connection, constrained by the fill level of the source.

\[ q = \frac 1 {t_r} {\left(\frac{V - V_{residual}}{V_0} \right)^\beta} \]

Parameters
sourceWater storage from which the water flows out. Flux is a function of source.volume
targetTarget node (boundary condition or storage). Does not influence the strength of the flow
residencetime\(t_r [days]\) The residence time of the water in this storage
Vlmin\(V_{l,min} [m^3]\) The volume of water not flowing out (default = 0)
Vrmax\(V_{r,max}\) Capacity of the target water storage in m3

Member Function Documentation

◆ conc()

real conc ( cmf::math::Time t,
const cmf::water::solute & _Solute )
inherited

Returns the concentration of the flux.


If not overridden, it returns the concentration of the source of the flux (direction depending)

◆ get_tracer_filter()

real get_tracer_filter ( )
inherited

A value ranging from 0 to 1 to filter tracers out of the water flux.

1.0 is no filter and 0.0 means no solute is crossing this connection

◆ set_tracer_filter()

void set_tracer_filter ( real value)
inherited

A value ranging from 0 to 1 to filter tracers out of the water flux.

1.0 is no filter and 0.0 means no solute is crossing this connection