diversionRouting {WRSS} | R Documentation |
base function for diversion simulation
Description
Given a sort of demand(s), diversionRouting
function enable us to simulate the performance and effect of a diversion dam under a givn recharge time series, inflow
, on the drainage network.
Usage
diversionRouting(demand=NA, priority = NA,
capacity, inflow, simulation)
Arguments
demand |
A matrix: is column-wise matrix of demands, at which the rows presents demands for each time step and columns are for different individual demand sites (MCM). |
priority |
A vector: is a vector of priorities associated to |
capacity |
The maximum capacity of diversion dam (CMS). |
inflow |
A vector : a vector of water flowing into the diversion (MCM) |
simulation |
A list: |
Value
the diversionRouting
function returns a list of features given as below:
-
release
: a matrix of release(s) equivalant to eachdemand
(MCM) -
diverted
: a vector of diverted volumes (MCM), release(s) are included -
overflow
: a vector of overflow passing through the diversion (MCM)
Author(s)
Rezgar Arabzadeh
See Also
Examples
demand <-matrix(rnorm(480,10,3),120)
priority <-sample(1:3,4,replace=TRUE)
capacity <-12
inflow <-rlnorm(120,log(50),log(4))
simulation <-list(start='2000-01-01',end='2009-12-29',interval='month')
res<-diversionRouting(demand=demand,
priority=priority,
capacity=capacity,
inflow=inflow,
simulation=simulation)
plot(ecdf(res$diverted$diverted),xlab='cms',ylab='exceedance probability')