Skip to content

Commit ad32cff

Browse files
fix: compute quantity dt epsilon in value space
1 parent d9f56cb commit ad32cff

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/OrdinaryDiffEqCore/src/initdt.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
oneunit_tType = oneunit(t)
1616
dtmax_tdir = tdir * dtmax
1717

18-
dtmin = nextfloat(max(integrator.opts.dtmin, eps(t)))
18+
dtmin = nextfloat(max(integrator.opts.dtmin, convert(_tType, oneunit_tType * eps(DiffEqBase.value(t)))))
1919
smalldt = max(dtmin, convert(_tType, oneunit_tType * 1 // 10^(6)))
2020

2121
if integrator.isdae
@@ -315,7 +315,7 @@ end
315315
oneunit_tType = oneunit(t)
316316
dtmax_tdir = tdir * dtmax
317317

318-
dtmin = nextfloat(max(integrator.opts.dtmin, eps(t)))
318+
dtmin = nextfloat(max(integrator.opts.dtmin, convert(_tType, oneunit_tType * eps(DiffEqBase.value(t)))))
319319
smalldt = max(dtmin, convert(_tType, oneunit_tType * 1 // 10^(6)))
320320

321321
if integrator.isdae

0 commit comments

Comments
 (0)