Reservoir operators
- class ReservoirOperators(model, agents)[source]
This class is used to simulate the government.
- Parameters:
model – The GEB model.
agents – The class that includes all agent types (allowing easier communication between agents).
- get_flood_control_reservoir_release(cpa, cond_ppose, qin, S_begin_yr, mtifl, alpha)[source]
Computes release from flood control reservoirs.
cpa = reservoir capacity (m^3) cond_ppose = array containing irrigation reservoir cells based on selection mask qin = inflow (m^3/s) Sini = initial storage (m^3) mtifl = annual mean total annual inflow (m^3/s) alpha = reservoir capacity reduction factor (dimensionless).
- get_irrigation_reservoir_release(capacity, storage_year_start, long_term_monthly_inflow_m3, long_term_monthly_inflow_this_month_m3, current_irrigation_demand_m3, long_term_monthly_irrigation_demand_m3, alpha, n_monthly_substeps)[source]
- get_maximum_abstraction_m3_by_farmer(farmer_command_areas, gross_irrigation_demand_m3_per_farmer)[source]
Get the maximum abstraction from reservoirs for each farmer.
If the configuration is set to equal abstraction, the maxmimum abstraction per farmer is calculated based on the irrigation demand of the farmers.
- Parameters:
farmer_command_areas (
ndarray
[tuple
[int
,...
],dtype
[float32
]]) – The command areas of the farmers in m2.gross_irrigation_demand_m3_per_farmer (
ndarray
[tuple
[int
,...
],dtype
[float32
]]) – The gross irrigation demand per farmer in m3.
- Returns:
The maximum abstraction from reservoirs for each farmer in m3.
- Return type:
ndarray
[tuple
[int
,...
],dtype
[float32
]]
- track_inflow(inflow_m3)[source]
Track the inflow to the reservoirs. Is called from the routing module every time step.
- Parameters:
inflow_m3 (
ndarray
[tuple
[int
,...
],dtype
[float32
]]) – The inflow to the reservoirs in m3.- Return type:
None
- property yearly_usuable_release_m3: ndarray[tuple[int, ...], dtype[float32]]
Get the yearly usable release in m3.
We do not use the current year, as it may not be complete yet, and we only use up to the history fill index, because earlier years are not yet run and thus contain no data.