SWMM Version
EPA SWMM 5.2, Build 5.2.4 (dwflow.c, 06/12/23). Present since Build 5.1.013, where the Preissmann slot surcharge option was introduced; also present in 5.3.x.
Desktop (please complete the following information):
Platform-independent — this is a formulation issue in the routing kernel, not a platform or build defect.
Describe the bug
Under SURCHARGE_METHOD SLOT, the flow area used to form the advective velocity in the conduit momentum equation includes the Preissmann slot. The hydraulic radius in the same equation does not. The result is that a single term evaluates A and R from two different cross-sections.
In dwflow_findConduitFlow():
// dwflow.c:147-157 — all three areas pass through getArea(), which adds the slot
wSlot = getSlotWidth(xsect, y1); a1 = getArea(xsect, y1, wSlot);
wSlot = getSlotWidth(xsect, y2); a2 = getArea(xsect, y2, wSlot);
wSlot = getSlotWidth(xsect, yMid); aMid = getArea(xsect, yMid, wSlot);
// dwflow.c:187 — velocity formed from the slot-inflated midpoint area
v = qLast / aMid;
// dwflow.c:218 — friction term: R excludes the slot, v does not
dq1 = dt * Conduit[k].roughFactor / pow(rWtd, 1.33333) * fabs(v);
where
// dwflow.c:665-674
double getArea(TXsect* xsect, double y, double wSlot)
{
if ( y >= xsect->yFull ) return xsect->aFull + (y - xsect->yFull) * wSlot;
return xsect_getAofY(xsect, y);
}
// dwflow.c:679-688
double getHydRad(TXsect* xsect, double y)
{
if (y >= xsect->yFull) return xsect->rFull; // slot deliberately excluded
return xsect_getRofY(xsect, y);
}
getHydRad() clamps to rFull on the (correct) reasoning that the slot is a fictitious gap and must not contribute wetted perimeter. The same reasoning applies to the conveyance area and is not applied in getArea().
Expected behavior
The Preissmann slot is a numerical device: a narrow fictitious gap above the crown whose only purpose is to supply a finite free-surface top width, so the Saint-Venant system stays hyperbolic after pressurization and the slot width sets the acoustic celerity c = sqrt(gA/T). It is a storage/compliance term. It conveys no discharge.
In the momentum equation, A is the conveyance area — it appears in the convective term d(Q^2/A)/dx and in the friction closure Sf = n^2|v|v / R^(4/3). For a pressurized pipe the conveyance area is A_full by definition; the pipe is full and its cross-section cannot grow. The velocity used in the momentum equation should therefore be
v = qLast / MIN(aMid, xsect->aFull)
so that A and R are drawn from the same section.
Suggested fix
Clamp the conveyance area at the velocity site only:
// dwflow.c:187
v = qLast / MIN(aMid, xsect->aFull);
This leaves a1, a2, aMid, node surface areas, and dqdh untouched, so the slot continues to do its actual job (supplying free-surface width to the node continuity equation). Only the momentum velocity is corrected.
SWMM Version
EPA SWMM 5.2, Build 5.2.4 (dwflow.c, 06/12/23). Present since Build 5.1.013, where the Preissmann slot surcharge option was introduced; also present in 5.3.x.
Desktop (please complete the following information):
Platform-independent — this is a formulation issue in the routing kernel, not a platform or build defect.
Describe the bug
Under SURCHARGE_METHOD SLOT, the flow area used to form the advective velocity in the conduit momentum equation includes the Preissmann slot. The hydraulic radius in the same equation does not. The result is that a single term evaluates A and R from two different cross-sections.
In dwflow_findConduitFlow():
where
getHydRad() clamps to rFull on the (correct) reasoning that the slot is a fictitious gap and must not contribute wetted perimeter. The same reasoning applies to the conveyance area and is not applied in getArea().
Expected behavior
The Preissmann slot is a numerical device: a narrow fictitious gap above the crown whose only purpose is to supply a finite free-surface top width, so the Saint-Venant system stays hyperbolic after pressurization and the slot width sets the acoustic celerity c = sqrt(gA/T). It is a storage/compliance term. It conveys no discharge.
In the momentum equation, A is the conveyance area — it appears in the convective term d(Q^2/A)/dx and in the friction closure Sf = n^2|v|v / R^(4/3). For a pressurized pipe the conveyance area is A_full by definition; the pipe is full and its cross-section cannot grow. The velocity used in the momentum equation should therefore be
so that A and R are drawn from the same section.
Suggested fix
Clamp the conveyance area at the velocity site only:
This leaves a1, a2, aMid, node surface areas, and dqdh untouched, so the slot continues to do its actual job (supplying free-surface width to the node continuity equation). Only the momentum velocity is corrected.