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

#include <GroundwaterDispersion.hpp>

Collaboration diagram for openswmm::twoD::dispersion::GradientFit:

Public Member Functions

void add (double x, double y, double difference)
 Accumulate one inverse-distance least-squares sample into this fit.
 
std::array< double, 2 > value () const
 Solve the accumulated planar gradient with a rank-one fallback.
 

Public Attributes

double xx = 0
 
double xy = 0
 
double yy = 0
 
double bx = 0
 
double by = 0
 

Member Function Documentation

◆ add()

void openswmm::twoD::dispersion::GradientFit::add ( double x,
double y,
double difference )
inline

Accumulate one inverse-distance least-squares sample into this fit.

Parameters
[in]xFinite neighbor-minus-center X displacement in m.
[in]yFinite neighbor-minus-center Y displacement in m.
[in]differenceFinite neighbor-minus-center scalar difference in native concentration/temperature units.
Postcondition
Adds weighted moment/RHS terms; a nonpositive/NaN squared distance is skipped. Does not validate other nonfinite inputs or allocate. Requires exclusive fit access while accumulating.
Here is the caller graph for this function:

◆ value()

std::array< double, 2 > openswmm::twoD::dispersion::GradientFit::value ( ) const
inline

Solve the accumulated planar gradient with a rank-one fallback.

Returns
Value-owned X/Y gradient in scalar units per m. Zero for nonpositive trace; full 2x2 inverse for det > 1e-12*trace^2, otherwise only the resolved rank-one direction.
Note
Read-only allocation-free arithmetic; no nonfinite/error status or explicit conditioning diagnostics. Fit must be stable during evaluation.
Here is the caller graph for this function:

Member Data Documentation

◆ bx

double openswmm::twoD::dispersion::GradientFit::bx = 0

◆ by

double openswmm::twoD::dispersion::GradientFit::by = 0

◆ xx

double openswmm::twoD::dispersion::GradientFit::xx = 0

◆ xy

double openswmm::twoD::dispersion::GradientFit::xy = 0

◆ yy

double openswmm::twoD::dispersion::GradientFit::yy = 0

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