Skip to content

Commit

Permalink
Added in Coriolis terms.
Browse files Browse the repository at this point in the history
  • Loading branch information
ali-ramadhan committed Feb 9, 2019
1 parent aa8b340 commit 1b07df1
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions src/time_steppers.jl
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ function time_step!(model::Model; Nt, Δt)
u∇u!(g, U, u∇u, otmp)
@. G.Gu.data = -u∇u.data

avg_x_v = stmp.fC1
avg_xy_v = stmp.fFX
avgx!(g, U.v, avg_x_v)
avgy!(g, avg_x_v, avg_xy_v)
@. G.Gu.data += c.f * avg_xy_v.data

∂xpHY′ = stmp.fFX
δx!(g, pr.pHY′, ∂xpHY′)
@. ∂xpHY′.data = ∂xpHY′.data / (g.Δx * eos.ρ₀)
Expand All @@ -64,6 +70,12 @@ function time_step!(model::Model; Nt, Δt)
u∇v!(g, U, u∇v, otmp)
@. G.Gv.data = -u∇v.data

avg_y_u = stmp.fC1
avg_xy_u = stmp.fFY
avgy!(g, U.u, avg_y_u)
avgx!(g, avg_y_u, avg_xy_u)
@. G.Gv.data += - c.f * avg_xy_u.data

∂ypHY′ = stmp.fFY
δy!(g, pr.pHY′, ∂ypHY′)
@. ∂ypHY′.data = ∂ypHY′.data / (g.Δy * eos.ρ₀)
Expand Down

0 comments on commit 1b07df1

Please sign in to comment.