Skip to content

Commit

Permalink
Merge pull request #171 from FourierFlows/ncc/MultilayerQG-to-MultiLa…
Browse files Browse the repository at this point in the history
…yerQG

MultilayerQG -> MultiLayerQG
  • Loading branch information
navidcy authored Dec 27, 2020
2 parents a945065 + 336da92 commit c363e4c
Show file tree
Hide file tree
Showing 9 changed files with 64 additions and 64 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ All modules provide solvers on two-dimensional domains. We currently provide
* `TwoDNavierStokes`: the two-dimensional vorticity equation.
* `SingleLayerQG`: the barotropic or equivalent-barotropic quasi-geostrophic equation, which generalizes `TwoDNavierStokes` to cases with topography, Coriolis parameters of the form `f = f₀ + βy`, and finite Rossby radius of deformation.
* `BarotropicQGQL`: the quasi-linear barotropic quasi-geostrophic equation.
* `MultilayerQG`: a multi-layer quasi-geostrophic model over topography and with the ability to impose a zonal flow `U_n(y)` in each layer.
* `MultiLayerQG`: a multi-layer quasi-geostrophic model over topography and with the ability to impose a zonal flow `U_n(y)` in each layer.
* `SurfaceQG`: a surface quasi-geostrophic model.


Expand Down
2 changes: 1 addition & 1 deletion docs/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ sitename = "GeophysicalFlows.jl",
"BarotropicQGQL" => Any[
"generated/barotropicqgql_betaforced.md",
],
"MultilayerQG" => Any[
"MultiLayerQG" => Any[
"generated/multilayerqg_2layer.md"
],
"SurfaceQG" => Any[
Expand Down
4 changes: 2 additions & 2 deletions docs/src/man/functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,10 +33,10 @@ Private = false
Order = [:function]
```

## Functions exported from `MultilayerQG`:
## Functions exported from `MultiLayerQG`:

```@autodocs
Modules = [GeophysicalFlows.MultilayerQG]
Modules = [GeophysicalFlows.MultiLayerQG]
Private = false
Order = [:function]
```
Expand Down
4 changes: 2 additions & 2 deletions docs/src/man/types.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ Public = false
Order = [:type]
```

## Private types in module `MultilayerQG`:
## Private types in module `MultiLayerQG`:

```@autodocs
Modules = [GeophysicalFlows.MultilayerQG]
Modules = [GeophysicalFlows.MultiLayerQG]
Public = false
Order = [:type]
```
Expand Down
6 changes: 3 additions & 3 deletions docs/src/modules/multilayerqg.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# MultilayerQG Module
# MultiLayerQG Module

### Basic Equations

Expand Down Expand Up @@ -67,14 +67,14 @@ The eddy kinetic energy in each layer and the eddy potential energy that corresp
fluid interface is computed via `energies()`:

```@docs
GeophysicalFlows.MultilayerQG.energies
GeophysicalFlows.MultiLayerQG.energies
```

The lateral eddy fluxes in each layer and the vertical fluxes across fluid interfaces are
computed via `fluxes()`:

```@docs
GeophysicalFlows.MultilayerQG.fluxes
GeophysicalFlows.MultiLayerQG.fluxes
```

### Implementation
Expand Down
10 changes: 5 additions & 5 deletions examples/multilayerqg_2layer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ using FourierFlows, Plots, Printf

using FFTW: rfft, irfft
using Random: seed!
import GeophysicalFlows.MultilayerQG
import GeophysicalFlows.MultilayerQG: energies
import GeophysicalFlows.MultiLayerQG
import GeophysicalFlows.MultiLayerQG: energies


# ## Choosing a device: CPU or GPU
Expand Down Expand Up @@ -49,7 +49,7 @@ nothing # hide

# ## Problem setup
# We initialize a `Problem` by providing a set of keyword arguments,
prob = MultilayerQG.Problem(nlayers, dev; nx=n, Lx=L, f₀=f₀, g=g, H=H, ρ=ρ, U=U, dt=dt, stepper=stepper, μ=μ, β=β)
prob = MultiLayerQG.Problem(nlayers, dev; nx=n, Lx=L, f₀=f₀, g=g, H=H, ρ=ρ, U=U, dt=dt, stepper=stepper, μ=μ, β=β)
nothing # hide

# and define some shortcuts.
Expand All @@ -68,7 +68,7 @@ q_i = 4e-3randn((grid.nx, grid.ny, nlayers))
qh_i = prob.timestepper.filter .* rfft(q_i, (1, 2)) # only apply rfft in dims=1, 2
q_i = irfft(qh_i, grid.nx, (1, 2)) # only apply irfft in dims=1, 2

MultilayerQG.set_q!(prob, q_i)
MultiLayerQG.set_q!(prob, q_i)
nothing # hide


Expand Down Expand Up @@ -209,7 +209,7 @@ anim = @animate for j = 0:round(Int, nsteps / nsubs)
push!(p[6][1], μ * E.t[E.i], E.data[E.i][2][1])

stepforward!(prob, diags, nsubs)
MultilayerQG.updatevars!(prob)
MultiLayerQG.updatevars!(prob)
end

gif(anim, "multilayerqg_2layer.gif", fps=18)
Expand Down
2 changes: 1 addition & 1 deletion src/multilayerqg.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module MultilayerQG
module MultiLayerQG

export
fwdtransform!,
Expand Down
6 changes: 3 additions & 3 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import # use 'import' rather than 'using' for submodules to keep namespace clean
GeophysicalFlows.TwoDNavierStokes,
GeophysicalFlows.SingleLayerQG,
GeophysicalFlows.BarotropicQGQL,
GeophysicalFlows.MultilayerQG,
GeophysicalFlows.MultiLayerQG,
GeophysicalFlows.SurfaceQG

using FourierFlows: parsevalsum
Expand Down Expand Up @@ -118,7 +118,7 @@ for dev in devices
@test SurfaceQG.nothingfunction() == nothing
end

@testset "MultilayerQG" begin
@testset "MultiLayerQG" begin
include("test_multilayerqg.jl")

@test test_pvtofromstreamfunction_2layer(dev)
Expand All @@ -134,7 +134,7 @@ for dev in devices
@test test_mqg_paramsconstructor(dev)
@test test_mqg_stochasticforcedproblemconstructor(dev)
@test test_mqg_problemtype(dev, Float32)
@test MultilayerQG.nothingfunction() == nothing
@test MultiLayerQG.nothingfunction() == nothing
end
end
end # time
Expand Down
Loading

0 comments on commit c363e4c

Please sign in to comment.