Skip to content

Commit 8479089

Browse files
authored
expose update_state!(atmos::PrescribedAtmosphere) (#590)
1 parent 8e26abd commit 8479089

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

src/OceanSeaIceModels/PrescribedAtmospheres.jl

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ using Oceananigans.TimeSteppers: Clock, tick!
1010
using Adapt
1111
using Thermodynamics.Parameters: AbstractThermodynamicsParameters
1212

13-
import Oceananigans.TimeSteppers: time_step!
13+
import Oceananigans.TimeSteppers: time_step!, update_state!
1414

1515
import Thermodynamics.Parameters:
1616
gas_constant, #
@@ -352,15 +352,21 @@ function default_atmosphere_pressure(grid, times)
352352
return pa
353353
end
354354

355-
@inline function time_step!(atmos::PrescribedAtmosphere, Δt)
356-
tick!(atmos.clock, Δt)
357355

356+
@inline function update_state!(atmos::PrescribedAtmosphere)
358357
time = Time(atmos.clock.time)
359358
ftses = extract_field_time_series(atmos)
360359

361360
for fts in ftses
362361
update_field_time_series!(fts, time)
363362
end
363+
return nothing
364+
end
365+
366+
@inline function time_step!(atmos::PrescribedAtmosphere, Δt)
367+
tick!(atmos.clock, Δt)
368+
369+
update_state!(atmos)
364370

365371
return nothing
366372
end

0 commit comments

Comments
 (0)