Skip to content

Commit

Permalink
Merge pull request #24 from firedrakeproject/TBendall/move_omega
Browse files Browse the repository at this point in the history
Pick up move to Omega in gusto main
  • Loading branch information
tommbendall authored Sep 2, 2024
2 parents c9cda72 + 4f0348f commit e095086
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 9 deletions.
10 changes: 4 additions & 6 deletions compressible_euler/dry_baroclinic_sphere.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,8 @@

from firedrake import (
ExtrudedMesh, SpatialCoordinate, cos, sin, pi, sqrt, exp, Constant,
Function, as_vector, acos, errornorm, norm, le, ge, conditional,
NonlinearVariationalProblem, NonlinearVariationalSolver, TestFunction,
inner, dx
Function, acos, errornorm, norm, le, ge, conditional, inner, dx,
NonlinearVariationalProblem, NonlinearVariationalSolver, TestFunction
)
from gusto import (
Domain, GeneralCubedSphereMesh, CompressibleParameters, CompressibleSolver,
Expand Down Expand Up @@ -94,10 +93,9 @@ def dry_baroclinic_sphere(
)

# Equations
params = CompressibleParameters()
omega_vec = as_vector([0, 0, Constant(omega)])
params = CompressibleParameters(Omega=omega)
eqn = CompressibleEulerEquations(
domain, params, Omega=omega_vec, u_transport_option=u_eqn_type
domain, params, u_transport_option=u_eqn_type
)

# Outputting and IO
Expand Down
5 changes: 2 additions & 3 deletions compressible_euler/moist_baroclinic_channel.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,10 @@ def moist_baroclinic_channel(
x, y, z = SpatialCoordinate(mesh)

# Equation
params = CompressibleParameters()
params = CompressibleParameters(Omega=omega*sin(phi0))
tracers = [WaterVapour(), CloudWater()]
coriolis = 2*omega*sin(phi0)*domain.k
eqns = CompressibleEulerEquations(
domain, params, active_tracers=tracers, Omega=coriolis/2,
domain, params, active_tracers=tracers,
no_normal_flow_bc_ids=[1, 2], u_transport_option=u_eqn_type
)

Expand Down

0 comments on commit e095086

Please sign in to comment.