Skip to content

Commit

Permalink
Accumulated stress decreases when no interactions
Browse files Browse the repository at this point in the history
  • Loading branch information
skygering committed Jun 27, 2024
1 parent 4df98b9 commit 2f6b16b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/physical_processes/types.jl
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Fields:
that stress_accum = stress_accum(1-λ) + stress_instant(λ)
α <AbstractFloat> Adjusts ellipse in stress space by raising area ratio to the α
Note:
τ is used in calc_stress!, whereas α is used in determine_fractures.
λ is used in calc_stress!, whereas α is used in determine_fractures.
"""
@kwdef struct DecayAreaScaledCalculator{FT<:AbstractFloat} <: AbstractStressCalculator{FT}
λ::FT = 0.2
Expand Down
5 changes: 2 additions & 3 deletions src/physical_processes/update_floe.jl
Original file line number Diff line number Diff line change
Expand Up @@ -500,9 +500,8 @@ function timestep_floe_properties!(
cforce = floes.collision_force[i]
ctrq = floes.collision_trq[i]
# Update stress
if floes.num_inters[i] > 0
calc_stress!(get_floe(floes, i), floe_settings, Δt)
end
calc_stress!(get_floe(floes, i), floe_settings, Δt)

# Ensure no extreem values due to model instability
if floes.height[i] > floe_settings.max_floe_height
@warn "Reducing height to $(floe_settings.max_floe_height) m"
Expand Down

0 comments on commit 2f6b16b

Please sign in to comment.