expected_demand#

module wntr.metrics.hydraulic

expected_demand(wn, start_time=None, end_time=None, timestep=None, category=None)[source]#

Compute expected demand at each junction and time using base demands and demand patterns along with the demand multiplier

Parameters:
  • wn (wntr WaterNetworkModel) – Water network model. The water network model is needed to get demand timeseries at junctions and options related to duration, timestep, and demand multiplier.

  • start_time (int (optional)) – Start time in seconds, if None then value is set to 0

  • end_time (int (optional)) – End time in seconds, if None then value is set to wn.options.time.duration

  • timestep (int (optional)) – Timestep, if None then value is set to wn.options.time.report_timestep

  • category (str (optional)) – Demand category name. If None, all demand categories are used.

Return type:

A pandas DataFrame that contains expected demand in m3/s (index = times, columns = junction names).