Skip to content

Commit 21ad375

Browse files
authored
Set last_delta_t for Reactant grids equal to regular grids (#4784)
1 parent a02649d commit 21ad375

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ext/OceananigansReactantExt/TimeSteppers.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ function Clock(::ReactantGrid)
3535
t = ConcreteRNumber(zero(FT))
3636
iter = ConcreteRNumber(0)
3737
stage = 0 #ConcreteRNumber(0)
38-
last_Δt = zero(FT)
39-
last_stage_Δt = zero(FT)
38+
last_Δt = convert(FT, Inf)
39+
last_stage_Δt = convert(FT, Inf)
4040
return Clock(; time=t, iteration=iter, stage, last_Δt, last_stage_Δt)
4141
end
4242

@@ -47,8 +47,8 @@ function Clock(grid::ShardedGrid)
4747
t = ConcreteRNumber(zero(FT), sharding=replicate)
4848
iter = ConcreteRNumber(0, sharding=replicate)
4949
stage = 0 #ConcreteRNumber(0)
50-
last_Δt = zero(FT)
51-
last_stage_Δt = zero(FT)
50+
last_Δt = convert(FT, Inf)
51+
last_stage_Δt = convert(FT, Inf)
5252
return Clock(; time=t, iteration=iter, stage, last_Δt, last_stage_Δt)
5353
end
5454

0 commit comments

Comments
 (0)