Example #1
0
class QAb2(hland_sequences.Flux1DSequence):
    """Interflow [mm/T].

    Note that COSERO uses the abbreviation `QAB2ZON` instead.
    """

    mask = hland_masks.UpperZone()
Example #2
0
class QVs2(hland_sequences.Flux1DSequence):
    """Percolation from the interflow reservoir [mm/T].

    Note that COSERO uses the abbreviation `QVS2ZON` instead.
    """

    mask = hland_masks.UpperZone()
Example #3
0
class BW2(hland_sequences.State1DSequence):
    """Water stored in the interflow reservoir [mm].

    Note that COSERO uses the abbreviation `BW2ZON` instead.
    """

    SPAN = (0.0, None)
    mask = hland_masks.UpperZone()
Example #4
0
class DP(hland_sequences.Flux1DSequence):
    """Deep percolation rate [mm/T].

    Note that PREVAH uses the abbreviation `Perc`, which is also the abbreviation used
    by HBV96.  However, |Perc| is 0-dimensional while |DP| is 1-dimensional, which is
    why we need to define separate sequence classes with different names.
    """

    mask = hland_masks.UpperZone()
Example #5
0
class SG1(hland_sequences.State1DSequence):
    """Fast response groundwater reservoir [mm]."""

    SPAN = (0.0, None)

    CONTROLPARAMETERS = (hland_control.SG1Max, )
    mask = hland_masks.UpperZone()

    def trim(self, lower=None, upper=None):
        r"""Trim |SG1| following :math:`0  \leq SG1 \leq SG1Max`.

        >>> from hydpy.models.hland import *
        >>> parameterstep("1d")
        >>> nmbzones(5)
        >>> sg1max(100.0)
        >>> states.sg1(-50.0, 0.0, 50.0, 100.0, 150.0)
        >>> states.sg1
        sg1(0.0, 0.0, 50.0, 100.0, 100.0)
        """
        if upper is None:
            upper = self.subseqs.seqs.model.parameters.control.sg1max
        super().trim(lower, upper)
Example #6
0
class ParameterUpperZone(ParameterComplete):
    """Base class for 1-dimensional parameters relevant for |FIELD|, |FOREST|, and
    |GLACIER| zones.

    |ParameterLand| works similar to |ParameterComplete|.  Some examples based on
    parameter |H1|:

    >>> from hydpy.models.hland import *
    >>> parameterstep()
    >>> nmbzones(6)
    >>> zonetype(FIELD, FOREST, GLACIER, ILAKE, FIELD, SEALED)
    >>> h1(field=2.0, forest=1.0, glacier=4.0, ilake=3.0, sealed=5.0)
    >>> h1
    h1(field=2.0, forest=1.0, glacier=4.0)
    >>> h1(field=2.0, default=9.0)
    >>> h1
    h1(field=2.0, forest=9.0, glacier=9.0)
    >>> zonearea.values = 1.0, 1.0, 1.0, nan, 1.0, nan
    >>> from hydpy import round_
    >>> round_(h1.average_values())
    5.5
    """

    mask = hland_masks.UpperZone()
Example #7
0
class RG1(hland_sequences.Flux1DSequence):
    """Discharge from the fast response groundwater reservoir [mm/T]."""

    mask = hland_masks.UpperZone()
Example #8
0
class GR1(hland_sequences.Flux1DSequence):
    """Recharge into the fast response groundwater reservoir [mm/T]."""

    mask = hland_masks.UpperZone()
Example #9
0
class RI(hland_sequences.Flux1DSequence):
    """Interflow [mm/T]."""

    mask = hland_masks.UpperZone()
Example #10
0
class RS(hland_sequences.Flux1DSequence):
    """Surface runoff [mm/T]."""

    mask = hland_masks.UpperZone()