OpenSWMM Engine  6.0.0-alpha.4
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
openswmm::SimulationContext::RoutingStepStats Struct Reference

#include <SimulationContext.hpp>

Collaboration diagram for openswmm::SimulationContext::RoutingStepStats:

Public Member Functions

void update (double dt)
 
void update_iterations (int iters, bool converged)
 Record iteration count for a routing step.
 
void init_histogram (double route_step, double min_route_step)
 
void build_histogram ()
 
void record_step_bin (double dt)
 Add a step to the histogram (call during simulation or post-process)
 
double avg_step () const
 
double pct_non_converged () const
 
double computed_avg_iterations () const
 

Public Attributes

double min_step = 1.0e30
 Minimum routing time step used (sec)
 
double max_step = 0.0
 Maximum routing time step used (sec)
 
double sum_step = 0.0
 Sum of all routing time steps (sec)
 
long n_steps = 0
 Total number of routing steps.
 
double steady_pct = 0.0
 Percent of time in steady state.
 
long step_counts [N_TIME_BINS+1] = {}
 Histogram bin counts.
 
double step_intervals [N_TIME_BINS+1] = {}
 Histogram bin edges.
 
long n_non_converged = 0
 Non-convergence and iteration tracking.
 
double sum_iterations = 0.0
 Sum of iterations for averaging.
 
double max_courant = 0.0
 Maximum Courant number observed.
 
double slot_peak_share = 0.0
 
double slot_time_above_s = 0.0
 
long fv_nsteps = -1
 explicit substeps over the run
 
long fv_nflux = 0
 face flux evaluations
 
double fv_avg_h = 0.0
 mean substep (s)
 
double fv_last_h = 0.0
 last substep (s)
 
double fv_min_h = 0.0
 smallest substep taken (s)
 
double fv_active_min = -1.0
 min active-face fraction
 
double fv_active_mean = -1.0
 mean active-face fraction
 
double fv_active_max = -1.0
 max active-face fraction
 
long fv_tier_cells [8] = {0}
 rebuild-sampled cells per LTS tier
 
int fv_n_tiers = 0
 populated tier count
 
long fv_dt_argmin_pressurized = 0
 
long fv_dt_argmin_band = 0
 
long fv_dt_argmin_free = 0
 
long fv_dt_argmin_node = 0
 

Static Public Attributes

static constexpr int N_TIME_BINS = 5
 Number of time step histogram bins (matching legacy TIMELEVELS=5).
 

Member Function Documentation

◆ avg_step()

double openswmm::SimulationContext::RoutingStepStats::avg_step ( ) const
inline

◆ build_histogram()

void openswmm::SimulationContext::RoutingStepStats::build_histogram ( )
inline

Build histogram bin edges post-hoc from observed min/max (fallback if init_histogram was not called).

Here is the call graph for this function:

◆ computed_avg_iterations()

double openswmm::SimulationContext::RoutingStepStats::computed_avg_iterations ( ) const
inline

◆ init_histogram()

void openswmm::SimulationContext::RoutingStepStats::init_histogram ( double route_step,
double min_route_step )
inline

Initialize histogram bin edges using log-scale between max and min routing steps. Call once at simulation start (matching legacy stats.c stats_open: intervals from RouteStep down to MinRouteStep).

Here is the caller graph for this function:

◆ pct_non_converged()

double openswmm::SimulationContext::RoutingStepStats::pct_non_converged ( ) const
inline

◆ record_step_bin()

void openswmm::SimulationContext::RoutingStepStats::record_step_bin ( double dt)
inline

Add a step to the histogram (call during simulation or post-process)

◆ update()

void openswmm::SimulationContext::RoutingStepStats::update ( double dt)
inline

◆ update_iterations()

void openswmm::SimulationContext::RoutingStepStats::update_iterations ( int iters,
bool converged )
inline

Record iteration count for a routing step.

Member Data Documentation

◆ fv_active_max

double openswmm::SimulationContext::RoutingStepStats::fv_active_max = -1.0

max active-face fraction

◆ fv_active_mean

double openswmm::SimulationContext::RoutingStepStats::fv_active_mean = -1.0

mean active-face fraction

◆ fv_active_min

double openswmm::SimulationContext::RoutingStepStats::fv_active_min = -1.0

min active-face fraction

◆ fv_avg_h

double openswmm::SimulationContext::RoutingStepStats::fv_avg_h = 0.0

mean substep (s)

◆ fv_dt_argmin_band

long openswmm::SimulationContext::RoutingStepStats::fv_dt_argmin_band = 0

◆ fv_dt_argmin_free

long openswmm::SimulationContext::RoutingStepStats::fv_dt_argmin_free = 0

◆ fv_dt_argmin_node

long openswmm::SimulationContext::RoutingStepStats::fv_dt_argmin_node = 0

◆ fv_dt_argmin_pressurized

long openswmm::SimulationContext::RoutingStepStats::fv_dt_argmin_pressurized = 0

◆ fv_last_h

double openswmm::SimulationContext::RoutingStepStats::fv_last_h = 0.0

last substep (s)

◆ fv_min_h

double openswmm::SimulationContext::RoutingStepStats::fv_min_h = 0.0

smallest substep taken (s)

◆ fv_n_tiers

int openswmm::SimulationContext::RoutingStepStats::fv_n_tiers = 0

populated tier count

◆ fv_nflux

long openswmm::SimulationContext::RoutingStepStats::fv_nflux = 0

face flux evaluations

◆ fv_nsteps

long openswmm::SimulationContext::RoutingStepStats::fv_nsteps = -1

explicit substeps over the run

◆ fv_tier_cells

long openswmm::SimulationContext::RoutingStepStats::fv_tier_cells[8] = {0}

rebuild-sampled cells per LTS tier

◆ max_courant

double openswmm::SimulationContext::RoutingStepStats::max_courant = 0.0

Maximum Courant number observed.

◆ max_step

double openswmm::SimulationContext::RoutingStepStats::max_step = 0.0

Maximum routing time step used (sec)

◆ min_step

double openswmm::SimulationContext::RoutingStepStats::min_step = 1.0e30

Minimum routing time step used (sec)

◆ n_non_converged

long openswmm::SimulationContext::RoutingStepStats::n_non_converged = 0

Non-convergence and iteration tracking.

Steps that didn't converge

◆ n_steps

long openswmm::SimulationContext::RoutingStepStats::n_steps = 0

Total number of routing steps.

◆ N_TIME_BINS

int openswmm::SimulationContext::RoutingStepStats::N_TIME_BINS = 5
staticconstexpr

Number of time step histogram bins (matching legacy TIMELEVELS=5).

◆ slot_peak_share

double openswmm::SimulationContext::RoutingStepStats::slot_peak_share = 0.0

◆ slot_time_above_s

double openswmm::SimulationContext::RoutingStepStats::slot_time_above_s = 0.0

◆ steady_pct

double openswmm::SimulationContext::RoutingStepStats::steady_pct = 0.0

Percent of time in steady state.

◆ step_counts

long openswmm::SimulationContext::RoutingStepStats::step_counts[N_TIME_BINS+1] = {}

Histogram bin counts.

◆ step_intervals

double openswmm::SimulationContext::RoutingStepStats::step_intervals[N_TIME_BINS+1] = {}

Histogram bin edges.

◆ sum_iterations

double openswmm::SimulationContext::RoutingStepStats::sum_iterations = 0.0

Sum of iterations for averaging.

◆ sum_step

double openswmm::SimulationContext::RoutingStepStats::sum_step = 0.0

Sum of all routing time steps (sec)


The documentation for this struct was generated from the following file: