|
Running problems - with swmm 4.31 dos
Hello SWMM users
I have just put a dos version 4.31 onto my computer and am having problems running the runoff block for extended periods.
During a model run the model will crash giving the error message
Error SQRT argument negative
in gutnr at line 141
called by gutter at line 189
called by hydro at line 363
called by runoff at line 258
called by swmm43 at line 284
The model does run for short periods of time and will produce credible numbers however it does not run for long periods.
Has any-one encountered the same problem and if so how do you overcome it
A copy of the gutnr subprogram code is below with line 141 marked it appears that the program is calculating d0 as negative and it is interesting to note that there is an if statement making the D1 equal to 0.01 if it falls below 0. Could a similar statement for d0 solve the problem?
C PARABOLIC CHANNEL
C===
IF(NPG.EQ.4) THEN
IF(D1.LE.0.0) THEN
IFLAG2 = IFLAG2 + 1
D1 = 0.001
DELD = -GDEPTH + 0.001
ENDIF
*line 141* WID0 = GWIDTH*SQRT(D0/DFULL)
WID1 = GWIDTH*SQRT(D1/DFULL)
DELV = 0.66666667*GLEN/DELT*(D1*WID1 - D0*WID0)
DDELV = 0.66666667*GLEN/DELT*1.50*WID1
AX = 0.66666667*WID1*D1
DAX = 0.66666667*WID1*1.50
X = WID1/2.0
A2 = GWIDTH**4.0/(64.0*DFULL**2.0)
WP = 8.0*DFULL/GWIDTH**2.0*(X*SQRT(A2+X**2.0) +
+ A2*LOG(X+SQRT(A2+X**2.0)) -
+ A2*LOG(SQRT(A2)))
DX = 0.0
IF(D1.GT.0.0) DX = 0.25*GWIDTH/SQRT(D1*DFULL)
DXX = 0.25*GWIDTH**2.0/DFULL
DWP = 8.0*DFULL/GWIDTH**2.0*(DX*SQRT(A2+X**2.0) +
+ 0.5*X*DXX/SQRT(A2+X**2.0) +
+ (DX+0.5*DXX/SQRT(A2+X**2.0))/(LOG(X+SQRT(A2+X**2.0))))
ENDIF
|