OpenSWMM Engine  6.0.0-alpha.4
Data-oriented, plugin-extensible SWMM Engine (6.0.0-alpha.4)
Loading...
Searching...
No Matches
LID.hpp
Go to the documentation of this file.
1// SPDX-License-Identifier: Apache-2.0
2//
3// Copyright 2026 Caleb Buahin
4//
5// Licensed under the Apache License, Version 2.0 (the "License");
6// you may not use this file except in compliance with the License.
7// You may obtain a copy of the License at
8//
9// http://www.apache.org/licenses/LICENSE-2.0
10//
11// Unless required by applicable law or agreed to in writing, software
12// distributed under the License is distributed on an "AS IS" BASIS,
13// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14// See the License for the specific language governing permissions and
15// limitations under the License.
16
41
42#ifndef OPENSWMM_LID_HPP
43#define OPENSWMM_LID_HPP
44
45#include "Infiltration.hpp"
46#include <utility>
47#include <vector>
48#include <cstddef>
49#include <cstdint>
50#include <string>
51#include <fstream>
52#include <map>
53#include <memory>
54
55namespace openswmm::detail {
57}
58
59namespace openswmm {
60
62
63namespace lid {
64
65// ============================================================================
66// LID type codes
67// ============================================================================
68
79
90inline bool hasNativeBottom(LIDType type, double storage_thickness, double storage_ksat) {
91 if (type == LIDType::VEG_SWALE)
92 return true;
93 if (type != LIDType::BIO_CELL && type != LIDType::RAIN_GARDEN &&
95 return false;
96 return storage_thickness <= 0 || storage_ksat > 0;
97}
98
107inline bool hasNativeBottom(const std::string& type, double thickness, double ksat) {
108 if (type == "VS")
109 return true;
110 return (type == "BC" || type == "RG" || type == "IT" || type == "PP") &&
111 (thickness <= 0 || ksat > 0);
112}
113
114// ============================================================================
115// Layer state (per LID unit)
116// ============================================================================
117
118constexpr int SURF = 0;
119constexpr int SOIL = 1;
120constexpr int STOR = 2;
121constexpr int PAVE = 3;
122constexpr int N_LAYERS = 4;
123
124// ============================================================================
125// LID unit parameters (SoA for batch processing)
126// ============================================================================
127
130 int count = 0;
131
132 // Unit-conversion factors for the model's flow units (legacy UCF()).
133 // Layer parameters are converted to internal ft / ft-per-sec at init();
134 // these two factors also drive the underdrain head/rate conversion in
135 // getDrainRate(). Defaults are the US-customary values (issue #102).
136 double ucf_raindepth = 12.0;
137 double ucf_rainfall = 43200.0;
138
139 std::vector<int> subcatch_idx;
140 std::vector<int> control_idx;
141 std::vector<double> area;
142 std::vector<double> from_imperv;
143 std::vector<double> from_perv;
144 std::vector<int> to_perv;
145 std::vector<int> drain_node;
146 std::vector<int> drain_subcatch;
147 std::vector<double> inflow;
148 std::vector<double>
150 std::vector<double>
152 std::vector<std::string>
154 // Per-step kernel rates staged for the LID report file (ft/s). Legacy
155 // lidproc_saveResults reads these straight from lidproc.c's static flux
156 // variables; the kernel here is per-call, so runUnitLegacy stages them.
157 std::vector<double> rpt_surf_infil;
158 std::vector<double> rpt_pave_perc;
159 std::vector<double> rpt_soil_perc;
160
161 // Surface layer
162 std::vector<double> surf_store;
163 std::vector<double> surf_rough;
164 std::vector<double> surf_slope;
165
166 // Soil layer
167 std::vector<double> soil_thick;
168 std::vector<double> soil_poros;
169 std::vector<double> soil_fc;
170 std::vector<double> soil_wp;
171 std::vector<double> soil_ksat;
172 std::vector<double> soil_kslope;
173 std::vector<double> soil_suction;
174
175 // Storage layer
176 std::vector<double> stor_thick;
177 std::vector<double> stor_void;
178 std::vector<double> stor_ksat;
179 std::vector<double> stor_clog;
180 std::vector<int> stor_covered;
181
182 // Drain
183 std::vector<double> drain_coeff;
184 std::vector<double> drain_expon;
185 std::vector<double> drain_offset;
186 std::vector<double> drain_delay;
187 std::vector<double> drain_hopen;
188 std::vector<double> drain_hclose;
189 std::vector<int> drain_open;
190
191 // Pavement layer (PERM_PAVEMENT)
192 std::vector<double> pave_thick;
193 std::vector<double> pave_void;
194 std::vector<double> pave_imperv_frac;
195 std::vector<double> pave_ksat;
196 std::vector<double> pave_clog_factor;
197 std::vector<double> pave_regen_days;
198 std::vector<double> pave_regen_deg;
199 std::vector<double> next_regen_day;
200
201 // Drainage mat layer (GREEN_ROOF)
202 std::vector<double> drainmat_thick;
203 std::vector<double> drainmat_void;
204 std::vector<double> drainmat_rough;
205
206 // Surface geometry (for Manning's outflow)
207 std::vector<double> surf_void_frac;
208 std::vector<double> surf_alpha;
209 std::vector<double> surf_side_slope;
210 std::vector<double> full_width;
211 std::vector<double> unit_area;
212 std::vector<double> unit_width;
213 std::vector<double> dry_time;
214
215 // State variables (updated each step)
216 std::vector<double> surf_depth;
217 std::vector<double> soil_moist;
218 std::vector<double> stor_depth;
219 std::vector<double> pave_depth;
220
221 // Legacy lidproc.c per-unit state the kernel needs beyond the layer
222 // depths (lid.c TLidUnit): the unit's own Green-Ampt infiltration
223 // state for the soil layer (soilInfil), the drain flow the previous
224 // step delivered (oldDrainFlow, the underdrain's hOpen/hClose
225 // hysteresis memory), and the process's canOverflow flag
226 // (validateLidProc: false for a roof disconnection and for a
227 // bio-cell / rain garden / trench / pavement / green roof whose surface
228 // has a Manning alpha).
229 std::vector<GreenAmptState> soil_infil;
230 std::vector<double> old_drain_flow;
231 std::vector<uint8_t>
233 std::vector<uint8_t> can_overflow;
234 std::vector<double>
236
237 // Outputs (per unit)
238 std::vector<double> surface_runoff;
239 std::vector<double> drain_flow;
240 std::vector<double> evap_loss;
241 std::vector<double> infil_loss;
242
243 // Pollutant drain removal fractions: drain_rmvl[unit * n_pollutants + pollutant]
244 std::vector<double> drain_rmvl;
245 int n_pollutants = 0;
246
247 // ---- A4: per-layer INFLOW rates (ft/sec of water per unit area) ----
248 // Each layer receives from exactly one place: the layer above it in the
249 // present stack, or externally for the topmost present layer. Every
250 // batch*Flux routine already computes these as locals (soil_infil,
251 // soil_perc, pavePerc, storageInflow, ...); they are published here
252 // because a complete-mix age needs the INFLOW and nothing else — the
253 // outflow leaves at the layer's own age.
254 //
255 // These are NOT the `f_old_*` below. Those are the Modified Puls
256 // time-weighting term: `f_old_surf` is the NET dx/dt of the surface
257 // layer, and the other three are never written at all. A net rate of
258 // change is exactly the quantity that made phase A3 report elapsed time
259 // instead of age.
260 std::vector<double> in_surf;
261 std::vector<double> in_pave;
262 std::vector<double> in_soil;
263 std::vector<double> in_stor;
266 std::vector<double> evap_surf, evap_pave, evap_soil, evap_stor;
267
268 // Previous flux rates (for Modified Puls time weighting)
269 std::vector<double> f_old_surf;
270 std::vector<double> f_old_soil;
271 std::vector<double> f_old_stor;
272 std::vector<double> f_old_pave;
273
274 // Water balance tracking (cumulative per unit)
275 std::vector<double> wb_inflow;
276 std::vector<double> wb_evap;
279 std::vector<double> wb_infil;
280 std::vector<double> wb_surf_flow;
281 std::vector<double> wb_drain_flow;
282 std::vector<double> wb_init_vol;
283 std::vector<double> wb_final_vol;
284 std::vector<double> vol_treated;
285
296 void resize(int n);
297};
298
310double completedUnitStorage(const LIDGroupSoA& g, int unit);
311
312// ============================================================================
313// LID solver
314// ============================================================================
315
317public:
331 void init(SimulationContext& ctx);
332
334 int type = -1, unit = -1;
335 double inflow = 0.0, rain = 0.0, pet = 0.0;
336 double native_infil = 0.0, max_native_infil = 1.0e10, infil_factor = 1.0;
337 // Negative fraction retains ordinary completed-kernel arithmetic.
338 double spatial_fraction = -1.0, spatial_max_infil = 1.0e10;
339 };
340
347 LIDSolver waterTrial() const;
366 void executeCompleted(double dt, double start, double recovery_factor,
367 const std::vector<CompletedUnitInput>& inputs);
368
376 LIDGroupSoA& group(int type_index) { return groups_[static_cast<size_t>(type_index)]; }
384 const LIDGroupSoA& group(int type_index) const {
385 return groups_[static_cast<size_t>(type_index)];
386 }
387
391 int numGroups() const { return static_cast<int>(groups_.size()); }
392
402 const std::vector<std::pair<int, int>>& usageOrder() const { return usage_order_; }
403
413 double storedVolume(const std::vector<int>* source_owners = nullptr) const;
428 void checkpoint(detail::CompletedSourceArchive& a, bool model,
429 bool lazy_buffers = false); // internal accepted-boundary IO
444 void validateCheckpoint(const LIDSolver& model, std::size_t runoff_count) const;
445
451 double totalStoredVolume() const;
457 double totalInitVolume() const;
463 double totalInfilVolume() const;
469 double totalEvapVolume() const;
470
490 void execute(SimulationContext& ctx, double dt, double rainfall, double evap_rate,
491 const std::vector<int>* source_owners = nullptr);
492
499 void setRunoffTime(double old_runoff_sec) { old_runoff_sec_ = old_runoff_sec; }
500
512 void setNativeInfil(std::vector<double> native, std::vector<double> max_native) {
513 native_infil_ = std::move(native);
514 max_native_infil_ = std::move(max_native);
515 }
516
525 void setInfilFactors(std::vector<double> infil_factor, double recovery_factor) {
526 infil_factor_ = std::move(infil_factor);
527 recovery_factor_ = recovery_factor;
528 }
529
538 bool anyWet(const std::vector<int>* source_owners = nullptr) const;
539
557 static void batchBioCellFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate,
558 double dt);
559
575 static void batchBarrelFlux(LIDGroupSoA& g, double rainfall, double dt);
576
594 static void batchSwaleFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate, double dt);
595
613 static void batchGreenRoofFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate,
614 double dt);
615
633 static void batchInfilTrenchFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate,
634 double dt);
635
653 static void batchPavementFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate,
654 double dt);
655
673 static void batchRoofDisconFlux(LIDGroupSoA& g, double rainfall, const double* evap_rate,
674 double dt);
675
693 static void batchSwaleModPuls(LIDGroupSoA& g, double rainfall, const double* evap_rate,
694 double dt);
695
696private:
697 std::vector<LIDGroupSoA> groups_;
698 std::vector<std::pair<int, int>> usage_order_;
699 double old_runoff_sec_ = 0.0;
700
706 struct LidRptFile {
707 std::ofstream f;
708 int was_dry = 1;
709 std::string held;
710 bool failed = false;
711 };
712 std::map<std::pair<int, int>, std::unique_ptr<LidRptFile>> rpt_files_;
730 void saveLidReport(SimulationContext& ctx, int gi, LIDGroupSoA& g, std::size_t u, double dt);
731 double recovery_factor_ = 1.0;
732 std::vector<double> native_infil_;
733 std::vector<double> max_native_infil_;
734 std::vector<double> infil_factor_;
735};
736
737} // namespace lid
738} // namespace openswmm
739
740#endif // OPENSWMM_LID_HPP
Infiltration models — Horton, Green-Ampt, SCS Curve Number.
Definition CompletedSourceArchive.hpp:25
Definition LID.hpp:316
static void batchGreenRoofFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone green-roof group through the shared legacy kernel.
Definition LID.cpp:1907
int numGroups() const
Return the number of currently allocated type groups.
Definition LID.hpp:391
const std::vector< std::pair< int, int > > & usageOrder() const
Borrow the deterministic legacy accumulation order for usage rows.
Definition LID.hpp:402
void executeCompleted(double dt, double start, double recovery_factor, const std::vector< CompletedUnitInput > &inputs)
Advance selected units with already-resolved completed-source forcing.
Definition LID.cpp:1984
static void batchPavementFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone permeable-pavement group through the shared legacy kernel.
Definition LID.cpp:1911
LIDSolver waterTrial() const
Copy water parameters, runtime state and ledgers for an independent trial.
Definition LID.cpp:1972
bool anyWet(const std::vector< int > *source_owners=nullptr) const
Test the last evaluated wet flags of included units.
Definition LID.cpp:2236
static void batchSwaleFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone vegetative-swale group through the shared legacy kernel.
Definition LID.cpp:1899
static void batchSwaleModPuls(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone Modified Puls swale group through the shared legacy kernel.
Definition LID.cpp:1903
void checkpoint(detail::CompletedSourceArchive &a, bool model, bool lazy_buffers=false)
Visit LID model identity or accepted-boundary water state in archive order.
Definition LIDCheckpoint.cpp:16
LIDGroupSoA & group(int type_index)
Borrow mutable parameters and water state for a type group.
Definition LID.hpp:376
const LIDGroupSoA & group(int type_index) const
Borrow read-only parameters and water state for a type group.
Definition LID.hpp:384
double storedVolume(const std::vector< int > *source_owners=nullptr) const
Sum current planar, void-weighted layer storage for ordinary runoff continuity.
Definition LID.cpp:611
void setNativeInfil(std::vector< double > native, std::vector< double > max_native)
Take ownership of per-subcatchment native-soil rates for subsequent ordinary steps.
Definition LID.hpp:512
static void batchInfilTrenchFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone infiltration-trench group through the shared legacy kernel.
Definition LID.cpp:1895
void setInfilFactors(std::vector< double > infil_factor, double recovery_factor)
Take ownership of infiltration multipliers and set the evaporation recovery factor.
Definition LID.hpp:525
void execute(SimulationContext &ctx, double dt, double rainfall, double evap_rate, const std::vector< int > *source_owners=nullptr)
Advance ordinary LID units with staged inflow and context-resolved evaporation.
Definition LID.cpp:2024
double totalInfilVolume() const
Sum cumulative native plus spatial bottom exfiltration over all unit footprints.
Definition LID.cpp:1946
void init(SimulationContext &ctx)
Build eight type groups and initialize water state from resolved LID controls and usage.
Definition LID.cpp:180
void validateCheckpoint(const LIDSolver &model, std::size_t runoff_count) const
Check restored LID water state against an initialized model.
Definition LIDCheckpoint.cpp:72
static void batchBioCellFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone biocell/rain-garden group through the shared legacy kernel.
Definition LID.cpp:1888
void setRunoffTime(double old_runoff_sec)
Set the old runoff clock used by regeneration and report timestamps.
Definition LID.hpp:499
double totalInitVolume() const
Sum the initialized water-balance store ledger over all unit footprints.
Definition LID.cpp:1935
static void batchBarrelFlux(LIDGroupSoA &g, double rainfall, double dt)
Advance a standalone rain-barrel group through the shared legacy kernel.
Definition LID.cpp:1892
double totalEvapVolume() const
Sum cumulative evaporation over all unit footprints.
Definition LID.cpp:1957
double totalStoredVolume() const
Sum the latest kernel water-balance final-store ledger over all unit footprints.
Definition LID.cpp:1924
static void batchRoofDisconFlux(LIDGroupSoA &g, double rainfall, const double *evap_rate, double dt)
Advance a standalone roof-disconnection group through the shared legacy kernel.
Definition LID.cpp:1915
Definition OutfallExchange.hpp:17
Definition LID.cpp:39
constexpr int STOR
Definition LID.hpp:120
constexpr int SOIL
Definition LID.hpp:119
constexpr int N_LAYERS
Definition LID.hpp:122
LIDType
Definition LID.hpp:69
@ ROOF_DISCON
Definition LID.hpp:77
@ INFIL_TRENCH
Definition LID.hpp:73
@ VEG_SWALE
Definition LID.hpp:76
@ RAIN_BARREL
Definition LID.hpp:75
@ BIO_CELL
Definition LID.hpp:70
@ RAIN_GARDEN
Definition LID.hpp:71
@ GREEN_ROOF
Definition LID.hpp:72
@ PERM_PAVEMENT
Definition LID.hpp:74
double completedUnitStorage(const LIDGroupSoA &g, int u)
Measure one completed-source unit using its physical layer geometry.
Definition LID.cpp:594
bool hasNativeBottom(LIDType type, double storage_thickness, double storage_ksat)
Classify whether an enumerated LID has an infiltrating native-soil bottom.
Definition LID.hpp:90
constexpr int PAVE
Definition LID.hpp:121
constexpr int SURF
Definition LID.hpp:118
Definition ExchangeLaw.hpp:60
Central, reentrant simulation context.
Definition SimulationContext.hpp:390
Definition LID.hpp:128
std::vector< double > soil_wp
Soil wilting point.
Definition LID.hpp:170
double ucf_rainfall
ft/sec → in/hr|mm/hr (RAINFALL)
Definition LID.hpp:137
std::vector< double > pave_void
Pavement void fraction.
Definition LID.hpp:193
std::vector< double > pave_imperv_frac
Impervious fraction of pavement.
Definition LID.hpp:194
std::vector< double > surface_runoff
Definition LID.hpp:238
std::vector< double > soil_thick
Soil thickness (ft)
Definition LID.hpp:167
std::vector< double > wb_evap
Definition LID.hpp:276
std::vector< int > control_idx
LID control index (into ctx.lid_controls)
Definition LID.hpp:140
std::vector< double > surf_alpha
Surface Manning alpha = sqrt(slope)/n.
Definition LID.hpp:208
std::vector< double > in_surf
External inflow onto the surface.
Definition LID.hpp:260
std::vector< double > pave_regen_days
Pavement regeneration interval (days)
Definition LID.hpp:197
std::vector< double > evap_surf
Definition LID.hpp:266
std::vector< double > drainmat_alpha
legacy drainMat.alpha = PHI / roughness * sqrt(surfSlope)
Definition LID.hpp:235
std::vector< int > drain_subcatch
Resolved drain-to subcatch index (-1=none)
Definition LID.hpp:146
std::vector< double > drain_coeff
Drain coefficient.
Definition LID.hpp:183
std::vector< std::string > rpt_path
Per-unit LID report file ([LID_USAGE] col 9); empty = none.
Definition LID.hpp:153
std::vector< double > drain_hopen
Head to open drain valve (ft)
Definition LID.hpp:187
std::vector< int > drain_node
Resolved drain-to node index (-1=none)
Definition LID.hpp:145
std::vector< double > inflow
Per-unit inflow rate (ft/sec) — set before execute()
Definition LID.hpp:147
std::vector< int > drain_open
Current drain valve state (1=open, 0=closed)
Definition LID.hpp:189
std::vector< double > f_old_stor
Previous storage flux rate.
Definition LID.hpp:271
std::vector< double > drain_hclose
Head to close drain valve (ft)
Definition LID.hpp:188
std::vector< double > drain_expon
Drain exponent.
Definition LID.hpp:184
std::vector< double > wb_surf_flow
Total surface outflow volume (ft)
Definition LID.hpp:280
std::vector< double > pave_thick
Pavement thickness (ft)
Definition LID.hpp:192
std::vector< double > surf_depth
Current surface ponded depth.
Definition LID.hpp:216
std::vector< double > pave_ksat
Pavement saturated K (ft/sec)
Definition LID.hpp:195
std::vector< double > stor_ksat
Storage exfiltration K (ft/sec)
Definition LID.hpp:178
std::vector< double > surf_slope
Surface slope.
Definition LID.hpp:164
std::vector< double > stor_void
Storage void fraction.
Definition LID.hpp:177
std::vector< double > wb_final_vol
Final stored volume (ft)
Definition LID.hpp:283
std::vector< double > subcatch_rain
Parent subcatchment rainfall (ft/sec) — for the rain-barrel dry-time reset (legacy lid....
Definition LID.hpp:151
std::vector< double > soil_kslope
Conductivity slope.
Definition LID.hpp:172
int n_pollutants
Number of pollutants (for indexing drain_rmvl)
Definition LID.hpp:245
std::vector< double > soil_poros
Soil porosity.
Definition LID.hpp:168
std::vector< double > dry_time
Seconds since last rainfall.
Definition LID.hpp:213
std::vector< double > stor_thick
Storage thickness (ft)
Definition LID.hpp:176
std::vector< GreenAmptState > soil_infil
Definition LID.hpp:229
std::vector< double > surf_store
Surface storage depth (ft)
Definition LID.hpp:162
std::vector< double > wb_spatial_infil
Definition LID.hpp:278
std::vector< double > drainmat_thick
Drainage mat thickness (ft)
Definition LID.hpp:202
std::vector< double > rpt_surf_infil
SurfaceInfil this step.
Definition LID.hpp:157
std::vector< double > soil_ksat
Soil saturated K (ft/sec)
Definition LID.hpp:171
std::vector< double > f_old_surf
Previous surface flux rate.
Definition LID.hpp:269
std::vector< double > drain_flow
Definition LID.hpp:239
std::vector< double > in_stor
Definition LID.hpp:263
void resize(int n)
Reset a type group to default per-unit arrays.
Definition LID.cpp:43
std::vector< double > wb_infil
Total exfiltration volume (ft)
Definition LID.hpp:279
std::vector< double > wb_init_vol
Initial stored volume (ft)
Definition LID.hpp:282
std::vector< double > f_old_pave
Previous pavement flux rate.
Definition LID.hpp:272
std::vector< double > surf_rough
Surface Manning's n.
Definition LID.hpp:163
std::vector< double > soil_suction
Suction head for Green-Ampt (ft)
Definition LID.hpp:173
std::vector< double > pave_regen_deg
Pavement regeneration degree (0-1)
Definition LID.hpp:198
std::vector< double > full_width
Full width for Manning's flow (ft)
Definition LID.hpp:210
std::vector< double > wb_inflow
Total inflow volume (ft)
Definition LID.hpp:275
std::vector< double > f_old_soil
Previous soil flux rate.
Definition LID.hpp:270
std::vector< double > evap_soil
Definition LID.hpp:266
std::vector< double > pave_clog_factor
Pavement clog factor (ft of treated volume)
Definition LID.hpp:196
std::vector< int > stor_covered
1 if rain barrel is covered (blocks rainfall)
Definition LID.hpp:180
std::vector< double > wb_drain_flow
Total drain outflow volume (ft)
Definition LID.hpp:281
std::vector< double > drainmat_rough
Drainage mat Manning's roughness.
Definition LID.hpp:204
std::vector< int > subcatch_idx
Which subcatchment this unit belongs to.
Definition LID.hpp:139
std::vector< double > pave_depth
Current pavement depth.
Definition LID.hpp:219
std::vector< double > rpt_soil_perc
SoilPerc this step.
Definition LID.hpp:159
std::vector< double > spatial_infil_loss
Completed spatial bottom water, ft over the full unit footprint.
Definition LID.hpp:278
std::vector< double > stor_depth
Current storage depth.
Definition LID.hpp:218
double ucf_raindepth
ft → in|mm (RAINDEPTH)
Definition LID.hpp:136
std::vector< double > infil_loss
Native infiltration loss this step (ft)
Definition LID.hpp:241
std::vector< double > surf_void_frac
Surface void fraction (default 1.0)
Definition LID.hpp:207
LIDType type
Definition LID.hpp:129
std::vector< double > evap_rate_unit
Per-unit effective PET rate (ft/sec) — filled by execute()
Definition LID.hpp:149
std::vector< double > in_pave
Surface → pavement.
Definition LID.hpp:261
std::vector< double > unit_area
ONE unit's area (ft2) — legacy lidUnit->area.
Definition LID.hpp:211
std::vector< int > to_perv
Route surface outflow to pervious area (1=yes)
Definition LID.hpp:144
std::vector< double > evap_pave
Definition LID.hpp:266
std::vector< double > drain_delay
Drain delay time (sec, rain barrel)
Definition LID.hpp:186
std::vector< double > old_drain_flow
Definition LID.hpp:230
std::vector< double > area
Unit area (ft2)
Definition LID.hpp:141
std::vector< uint8_t > is_wet
legacy lidproc_saveResults isDry == FALSE this step (HasWetLids)
Definition LID.hpp:232
std::vector< double > evap_stor
Definition LID.hpp:266
std::vector< double > evap_loss
Evaporation loss this step (ft of depth)
Definition LID.hpp:240
std::vector< double > unit_width
ONE unit's width (ft) — legacy lidUnit->fullWidth.
Definition LID.hpp:212
int count
Definition LID.hpp:130
std::vector< double > from_perv
Fraction of pervious runoff treated (0-1)
Definition LID.hpp:143
std::vector< double > stor_clog
Storage clogging factor (ft)
Definition LID.hpp:179
std::vector< double > next_regen_day
Next day for pavement regeneration (OADate)
Definition LID.hpp:199
std::vector< double > soil_fc
Soil field capacity.
Definition LID.hpp:169
std::vector< double > in_soil
Layer above → soil.
Definition LID.hpp:262
std::vector< double > surf_side_slope
Swale side slope (run/rise)
Definition LID.hpp:209
std::vector< double > vol_treated
Cumulative volume treated (ft, for clog model)
Definition LID.hpp:284
std::vector< double > drainmat_void
Drainage mat void fraction.
Definition LID.hpp:203
std::vector< double > from_imperv
Fraction of impervious runoff treated (0-1)
Definition LID.hpp:142
std::vector< double > drain_rmvl
Removal fraction per unit per pollutant.
Definition LID.hpp:244
std::vector< uint8_t > can_overflow
Definition LID.hpp:233
std::vector< double > drain_offset
Drain offset depth (ft)
Definition LID.hpp:185
std::vector< double > rpt_pave_perc
PavePerc this step.
Definition LID.hpp:158
std::vector< double > soil_moist
Current soil moisture (0-porosity)
Definition LID.hpp:217
double max_native_infil
Definition LID.hpp:336
double spatial_fraction
Definition LID.hpp:338
double native_infil
Definition LID.hpp:336
double infil_factor
Definition LID.hpp:336
double inflow
Definition LID.hpp:335
double spatial_max_infil
Definition LID.hpp:338