OpenSWMM Engine  6.0.0-alpha.3
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.3)
Loading...
Searching...
No Matches
Link.hpp
Go to the documentation of this file.
1
16
17#ifndef OPENSWMM_LINK_HPP
18#define OPENSWMM_LINK_HPP
19
20#include "../data/LinkData.hpp"
21#include "XSectBatch.hpp"
22#include "Node.hpp"
23#include "Transect.hpp"
24
25#include <vector>
26
27namespace openswmm {
28
29namespace link {
30
31// ============================================================================
32// Per-element functions
33// ============================================================================
34
47double getVelocity(const XSectParams& xs, double flow, double depth, int barrels = 1);
48
60double getFroude(const XSectParams& xs, double v, double y);
61
77void computeConveyance(double roughness, double slope, double s_full,
78 double& beta, double& rough_factor, double& q_full);
79
91double getDepthFromFlow(const XSectParams& xs, double beta, double q);
92
97double getCapacity(const XSectParams& xs, double depth);
98
112double getHydPower(double flow, double head_upstream, double head_downstream);
113
126XSectParams buildXSectParams(
127 const LinkData& links, std::size_t uj,
128 const std::vector<transect::TransectData>* transects = nullptr);
129
130// ============================================================================
131// Batch functions (for routing hot loop)
132// ============================================================================
133
134// Phase 6: computeVelocities/computeFroude/computeAllConveyance removed (dead
135// code; referenced conduit fields now in ConduitData — see LinkSubtypes.hpp).
136
144int translateShape(XsectShape link_shape);
145
173void applyTabulatedXSectParams(XSectParams& xs, const transect::TransectData& td,
174 double y_full, int transect_idx);
175
176} // namespace link
177
178} // namespace openswmm
179
180#endif // OPENSWMM_LINK_HPP
Node hydraulics — volume/depth/head conversions, surface area, overflow.
Irregular transect cross-section geometry (HEC-2 style).
Cross-section geometry — unified batch + per-element API.
Definition NodeCoupling.cpp:15
XsectShape
Conduit cross-section shape code.
Definition LinkData.hpp:54
double * y
Definition odesolve.c:28