Skip to content

Commit 5ac5bb8

Browse files
Merge pull request #67 from SciML/dtmax_error
Insert a safety error for lack of fixed point iteration
2 parents de06563 + c5e9347 commit 5ac5bb8

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/solve.jl

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -513,6 +513,10 @@ function DiffEqBase.solve!(integrator::SDDEIntegrator)
513513
if DiffEqBase.check_error!(integrator) != ReturnCode.Success
514514
return integrator.sol
515515
end
516+
if integrator.dt > minimum(integrator.sol.prob.constant_lags) &&
517+
!(integrator.alg <: StochasticDiffEq.EM)
518+
error("dt > minimum(constant_lags). This is not allowed by the integrator. Please dt `dtmax` less than the minimum lag or use `EM`.")
519+
end
516520
StochasticDiffEq.perform_step!(integrator, integrator.cache)
517521
loopfooter!(integrator)
518522
if isempty(integrator.opts.tstops)

0 commit comments

Comments
 (0)