44#ifndef OPENSWMM_ENGINE_2D_RAINFALL_INTERPOLATOR_HPP
45#define OPENSWMM_ENGINE_2D_RAINFALL_INTERPOLATOR_HPP
75 void build(
const std::vector<double>& cx,
const std::vector<double>& cy,
76 const std::vector<double>& gage_x,
const std::vector<double>& gage_y,
77 int n_gages,
double gage_scale);
80 bool ready() const noexcept {
return ready_; }
90 void apply(
const std::vector<double>& rain, std::vector<double>& out)
const;
99 std::vector<int> w_ptr_;
100 std::vector<int> w_gage_;
101 std::vector<double> w_val_;
Builds and applies static rainfall-interpolation weights for the mesh.
Definition RainfallInterpolator.hpp:60
bool ready() const noexcept
True once build() produced usable weights (≥ 1 located gage).
Definition RainfallInterpolator.hpp:80
void build(const std::vector< double > &cx, const std::vector< double > &cy, const std::vector< double > &gage_x, const std::vector< double > &gage_y, int n_gages, double gage_scale)
Precompute per-cell interpolation weights.
Definition RainfallInterpolator.cpp:240
void apply(const std::vector< double > &rain, std::vector< double > &out) const
Map per-gage values onto per-cell values: out[i] = Σ w·rain[gage].
Definition RainfallInterpolator.cpp:311
Definition NodeCoupling.cpp:16