rainrun

package
v0.0.0-...-04dc3de Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 3, 2023 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DOY []int

DOY hold day of year

View Source
var DT []time.Time

DT holds dates

View Source
var FRC [][]float64

FRC holds forcing data

HDR holds header info

View Source
var Loc []float64

Loc contains location info (coordinates, catchment properties, etc.)

View Source
var Ndt int

Ndt number of timesteps

View Source
var Timestep float64

Timestep timestep in seconds

Functions

func EvalPNG

func EvalPNG(m Lumper) string

EvalPNG prints model output to a png

func LoadMET

func LoadMET(fp string, print bool)

LoadMET collect the climate data, set to a global variable

func SumHydrograph

func SumHydrograph(o, s, g []float64)

func SumMonthly

func SumMonthly(dt []time.Time, o, s []float64, ts, ca float64)

Types

type Atkinson

type Atkinson struct {
	// contains filtered or unexported fields
}

Atkinson simple storage model, meant for hourly timesteps based on formulation given in: Atkinson, S.E., M. Sivapalan, N.R. Viney, R.A. Woods, 2003. Predicting space-time variability of hourly streamflow and the role of climate seasonality: Mahurangi Catchment, New Zealand. Hydrological Processes 17. pp. 2171-2193. original ref: Atkinson S.E., R.A. Woods, M. Sivapalan, 2002. Climate and landscape controls on water balance model complexity over changing timescales. Water Resource Research 38(12): 1314. additional ref: Wittenberg H., M. Sivapalan, 1999. Watershed groundwater balance equation using streamflow recession analysis and baseflow separation. Journal of Hydrology 219, pp.20-33. sto: current storage; sint current interception storage; cov: fractional forest cover; kb = 1/Tcbf

func (*Atkinson) New

func (m *Atkinson) New(p ...float64)

New Atkinson constructor [sbc, sfc, coverdense, intcap, kb, a, b]

func (*Atkinson) Storage

func (m *Atkinson) Storage() float64

Storage returns total storage

func (*Atkinson) Update

func (m *Atkinson) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

func (*Atkinson) UpdateHourly

func (m *Atkinson) UpdateHourly(p, ep float64) (float64, float64, float64)

UpdateHourly update state at the intended hourly interval

type CCFGR4J

type CCFGR4J struct {
	GR4J
	SP snowpack.CCF
	SI *solirrad.SolIrad
}

CCFGR4J model Perrin C., C. Michel, V. Andreassian, 2003. Improvement of a parsimonious model for streamflow simulation. Journal of Hydrology 279. pp. 275-289.

func (*CCFGR4J) New

func (m *CCFGR4J) New(p ...float64)

New CCFGR4J contructor [stocap, gwstocap, x4, unitHydrographPartition, x2] [tindex, ddfc, baseT, tsf]

func (*CCFGR4J) Update

func (m *CCFGR4J) Update(v []float64, doy int) (y, a, r, g float64)

Update state for daily inputs

type CCFHBV

type CCFHBV struct {
	HBV
	SP snowpack.CCF
	SI *solirrad.SolIrad
}

CCFHBV model Bergström, S., 1976. Development and application of a conceptual runoff model for Scandinavian catchments. SMHI RHO 7. Norrköping. 134 pp. Bergström, S., 1992. The HBV model - its structure and applications. SMHI RH No 4. Norrköping. 35 pp

func (*CCFHBV) New

func (m *CCFHBV) New(p ...float64)

New CCFHBV constructor [fc, lp, beta, uzl, k0, k1, k2, ksat, maxbas, lakeCoverFrac, tindex, ddfc, baseT, tsf]

func (*CCFHBV) Update

func (m *CCFHBV) Update(v []float64, doy int) (y, a, r, g float64)

Update state

type DawdyODonnell

type DawdyODonnell struct {
	// contains filtered or unexported fields
}

DawdyODonnell model ref: Dawdy, D.R., and T. O'Donnell, 1965. Mathematical Models of Catchment Behavior. Journal of Hydraulics Division, ASCE, Vol. 91, No. HY4, pp. 123-137. see: pg.34 in Dooge and O'Kane (2003)

func (*DawdyODonnell) New

func (m *DawdyODonnell) New(p ...float64)

New DawdyODonnell constructor [ksat, depintCap, upszCap, gwCap, olfk, bfk]

func (*DawdyODonnell) Storage

func (m *DawdyODonnell) Storage() float64

Storage returns total storage

func (*DawdyODonnell) Update

func (m *DawdyODonnell) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type GR4J

type GR4J struct {
	// contains filtered or unexported fields
}

GR4J model Perrin C., C. Michel, V. Andreassian, 2003. Improvement of a parsimonious model for streamflow simulation. Journal of Hydrology 279. pp. 275-289.

func (*GR4J) New

func (m *GR4J) New(p ...float64)

New GR4J constructor

func (*GR4J) Storage

func (m *GR4J) Storage() float64

Storage returns total storage

func (*GR4J) Update

func (m *GR4J) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type HBV

type HBV struct {
	// contains filtered or unexported fields
}

HBV model Bergström, S., 1976. Development and application of a conceptual runoff model for Scandinavian catchments. SMHI RHO 7. Norrköping. 134 pp. Bergström, S., 1992. The HBV model - its structure and applications. SMHI RH No 4. Norrköping. 35 pp

func (*HBV) New

func (m *HBV) New(p ...float64)

New HBV constructor [fc, lp, beta, uzl, k0, k1, k2, ksat, maxbas, lakeCoverFrac]

func (*HBV) Storage

func (m *HBV) Storage() float64

Storage returns total storage

func (*HBV) Update

func (m *HBV) Update(pn, ep float64) (float64, float64, float64)

Update state for daily inputs

type Lumper

type Lumper interface {
	New(p ...float64)
	Update(p, ep float64) (float64, float64, float64)
	Storage() float64
}

Lumper : interface to lumped rainfall-runoff models

type MakkinkCCFGR4J

type MakkinkCCFGR4J struct {
	GR4J
	SP            snowpack.CCF
	SI            *solirrad.SolIrad
	Palpha, Pbeta float64
}

MakkinkCCFGR4J model Perrin C., C. Michel, V. Andreassian, 2003. Improvement of a parsimonious model for streamflow simulation. Journal of Hydrology 279. pp. 275-289. with CCF snowmelt model and Makkink PET

func (*MakkinkCCFGR4J) New

func (m *MakkinkCCFGR4J) New(p ...float64)

New CCFGR4J contructor [stocap, gwstocap, x4, unitHydrographPartition, x2] [tindex, ddfc, baseT, tsf] [b, c, alpha, beta]

func (*MakkinkCCFGR4J) Update

func (m *MakkinkCCFGR4J) Update(v []float64, doy int) (y, a, r, g float64)

Update state for daily inputs

type ManabeGW

type ManabeGW struct {
	// contains filtered or unexported fields
}

ManabeGW manabe reserveroir with an added exponential decay reservoir

func (*ManabeGW) New

func (m *ManabeGW) New(p ...float64)

New ManabeGW constructor [capacity, fexposed, minSto, perc, kbf]

func (*ManabeGW) Storage

func (m *ManabeGW) Storage() float64

Storage returns manabe storage

func (*ManabeGW) Update

func (m *ManabeGW) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type MultiLayerCapacitance

type MultiLayerCapacitance struct {
	// contains filtered or unexported fields
}

MultiLayerCapacitance model ref: Struthers, I., C. Hinz, M. Sivapalan, G. Deutschmann, F. Beese, R. Meissner, 2003. Modelling the water balance of a free-draining lysimeter using the downward approach. Hydrological Processes (17). pp. 2151-2169. modification here: _runoff = lateral flow (runoff & subsurface)

func (*MultiLayerCapacitance) New

func (m *MultiLayerCapacitance) New(p ...float64)

New MultiLayerCapacitance constructor [coverDens, szDepth, porosity, fc, a, b, l1, l2, l3]

func (*MultiLayerCapacitance) Storage

func (m *MultiLayerCapacitance) Storage() float64

Storage returns total storage

func (*MultiLayerCapacitance) Update

func (m *MultiLayerCapacitance) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type Quinn

type Quinn struct {
	Zwt float64
	// contains filtered or unexported fields
}

Quinn simple storage model ref: Quinn P.F., K.J. Beven, 1993. Spatial and temporal predictions of soil moisture dynamics, runoff, variable source areas and evapotranspiration for Plynlimon, mid-Wales. Hydrological Processes 7. pp.425-448. used in early formulations of TOPMODEL, neglecting capillary fringe

func (*Quinn) New

func (m *Quinn) New(p ...float64)

New Quinn constructor [intercepCap, impStoCap, gwCap, fImp, ksat, rootZoneDepth, porosity, fieldCap, f, alpha, zwt]

func (*Quinn) Storage

func (m *Quinn) Storage() float64

Storage returns total storage

func (*Quinn) Update

func (m *Quinn) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type SIXPAR

type SIXPAR struct {
	// contains filtered or unexported fields
}

SIXPAR model ref: Gupta V.K., S. Sorooshian, 1983. Uniqueness and Observability of Conceptual Rainfall-Runoff Model Parameters: The Percolation Process Examined. Water Resources Research 19(1). pp.269-276. also see: Duan, Q., S. Sorooshian, V. Gupta, 1992. Effective and Efficient Global Optimization for Conceptual Rainfall-Runoff Models. Water Resources Research 28(4). pp.1015-1031.

func (*SIXPAR) New

func (m *SIXPAR) New(p ...float64)

New SIXPAR constructor [upCap, lowCap, upK, lowK, z, x]

func (*SIXPAR) Storage

func (m *SIXPAR) Storage() float64

Storage returns total storage

func (*SIXPAR) Update

func (m *SIXPAR) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs

type SPLR

type SPLR struct {
	// contains filtered or unexported fields
}

SPLR : Simple Parallel Linear Reservoir Buytaert, W., and K. Beven, 2011. Models as multiple working hypotheses hydrological simulation of tropical alpine. Hydrological Processes 25. pp. 1784–1799. 3-reservoir Tank model

func (*SPLR) New

func (m *SPLR) New(p ...float64)

New SPLR constructor [r12, r23, k1, k2, k3]

func (*SPLR) Storage

func (m *SPLR) Storage() float64

Storage returns total storage

func (*SPLR) Update

func (m *SPLR) Update(p, ep float64) (float64, float64, float64)

Update state for daily inputs, returns excess

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL