Learn R Programming

airGR (version 1.7.6)

RunModel_GR2M: Run with the GR2M hydrological model

Description

Function which performs a single run for the GR2M monthly lumped model over the test period.

Usage

RunModel_GR2M(InputsModel, RunOptions, Param)

Value

[list] containing the function outputs organised as follows:

$DatesR [POSIXlt] series of dates
$PotEvap [numeric] series of input potential evapotranspiration [mm/month] (E)
$Precip [numeric] series of input total precipitation [mm/month] (P)
$AE [numeric] series of actual evapotranspiration [mm/month]
$Pn [numeric] series of net rainfall (P1) [mm/month]
$Ps [numeric] series of part of P filling the production store [mm/month]
$Perc [numeric] series of percolation (P2) [mm/month]
$PR [numeric] series of PR=Pn+Perc (P3) [mm/month]
$AExch [numeric] series of actual exchange between catchments [mm/month]
$Prod [numeric] series of production store level (S) [mm]
$Rout [numeric] series of routing store level (R1) [mm]
$Qsim [numeric] series of simulated discharge [mm/month] (Q)
RunOptions$WarmUpQsim[numeric] series of simulated discharge (Q) on the warm-up period [mm/month]
RunOptions$Param [numeric] parameter set parameter set used by the model
$StateEnd[numeric] states at the end of the run (production store level and routing store level) [mm]. See CreateIniStates for more details

Refer to the provided references or to the package source code for further details on these model outputs.

Arguments

InputsModel

[object of class InputsModel] see CreateInputsModel for details

RunOptions

[object of class RunOptions] see CreateRunOptions for details

Param

[numeric] vector of 2 parameters

GR2M X1production store capacity [mm]
GR2M X2groundwater exchange coefficient [-]

Author

Laurent Coron, Claude Michel, Safouane Mouelhi, Olivier Delaigue, Guillaume Thirel

Details

For further details on the model, see the references section.
For further details on the argument structures and initialisation options, see CreateRunOptions.

Figure: diagramGR4J-EN.png

References

Mouelhi S. (2003). Vers une chaîne cohérente de modèles pluie-débit conceptuels globaux aux pas de temps pluriannuel, annuel, mensuel et journalier. PhD thesis (in French), ENGREF - Cemagref Antony, France.

Mouelhi, S., Michel, C., Perrin, C. and Andréassian, V. (2006). Stepwise development of a two-parameter monthly water balance model. Journal of Hydrology, 318(1-4), 200-214, tools:::Rd_expr_doi("10.1016/j.jhydrol.2005.06.014").

See Also

CreateInputsModel, CreateRunOptions, CreateIniStates.

Examples

Run this code
library(airGR)

## loading catchment data
data(L0123001)

## preparation of the InputsModel object with daily time step data
InputsModel <- CreateInputsModel(FUN_MOD = RunModel_GR4J, DatesR = BasinObs$DatesR,
                                 Precip = BasinObs$P, PotEvap = BasinObs$E)

## conversion of InputsModel to monthly time step
InputsModel <- SeriesAggreg(InputsModel, Format = "%Y%m")

## run period selection
Ind_Run <- seq(which(format(InputsModel$DatesR, format = "%Y-%m")=="1990-01"),
               which(format(InputsModel$DatesR, format = "%Y-%m")=="1999-12"))

## preparation of the RunOptions object
RunOptions <- CreateRunOptions(FUN_MOD = RunModel_GR2M,
                               InputsModel = InputsModel, IndPeriod_Run = Ind_Run)

## simulation
Param <- c(X1 = 265.072, X2 = 1.040)
OutputsModel <- RunModel_GR2M(InputsModel = InputsModel, RunOptions = RunOptions, Param = Param)

## conversion of observed discharge to monthly time step
Qobs <- SeriesAggreg(data.frame(BasinObs$DatesR, BasinObs$Qmm),
                    Format = "%Y%m",
                    ConvertFun = "sum")
Qobs <- Qobs[Ind_Run, 2]

## results preview
plot(OutputsModel, Qobs = Qobs)

## efficiency criterion: Nash-Sutcliffe Efficiency
InputsCrit  <- CreateInputsCrit(FUN_CRIT = ErrorCrit_NSE, InputsModel = InputsModel,
                                RunOptions = RunOptions, Obs = Qobs)
OutputsCrit <- ErrorCrit_NSE(InputsCrit = InputsCrit, OutputsModel = OutputsModel)

Run the code above in your browser using DataLab