File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ function sea_ice_simulation(grid, ocean=nothing;
3232 ice_density = 900 , # kg m⁻³
3333 dynamics = sea_ice_dynamics (grid, ocean),
3434 bottom_heat_boundary_condition = nothing ,
35+ top_heat_boundary_condition = nothing ,
3536 phase_transitions = PhaseTransitions (; ice_heat_capacity, ice_density),
3637 conductivity = 2 , # kg m s⁻³ K⁻¹
3738 internal_heat_flux = ConductiveFlux (; conductivity))
@@ -40,8 +41,10 @@ function sea_ice_simulation(grid, ocean=nothing;
4041 # - bottom -> flux boundary condition
4142 # - top -> prescribed temperature boundary condition (calculated in the flux computation)
4243
43- top_surface_temperature = Field {Center, Center, Nothing} (grid)
44- top_heat_boundary_condition = PrescribedTemperature (top_surface_temperature)
44+ if isnothing (top_heat_boundary_condition)
45+ top_surface_temperature = Field {Center, Center, Nothing} (grid)
46+ top_heat_boundary_condition = PrescribedTemperature (top_surface_temperature)
47+ end
4548
4649 if isnothing (bottom_heat_boundary_condition)
4750 if isnothing (ocean)
You can’t perform that action at this time.
0 commit comments