diff --git a/Project.toml b/Project.toml index d1e58cf..78c5f25 100644 --- a/Project.toml +++ b/Project.toml @@ -1,7 +1,7 @@ name = "TwoLayerDirectNumericalShenanigans" uuid = "40aaee9f-3595-48be-b36c-f1067009652f" authors = ["Josef Bisits "] -version = "0.6.2" +version = "0.6.3" [deps] CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba" diff --git a/src/constants.jl b/src/constants.jl index 0d73d6f..2b7a15f 100644 --- a/src/constants.jl +++ b/src/constants.jl @@ -1,8 +1,8 @@ """ const DOMAIN_EXTENT -Domain extent on which the two layer simulations are run. +Domain extent on which my two layer simulations are run. """ -const DOMAIN_EXTENT = (Lx = 0.1, Ly = 0.1, Lz = 1) +const DOMAIN_EXTENT = (Lx = 0.1, Ly = 0.1, Lz = -1) """ const HIGH_RESOLUTION Resolution at which to run the DNS sufficient to resolve turbulence on all scales, i.e. @@ -15,17 +15,25 @@ const HIGH_RESOLUTION = (Nx = 124, Ny = 124, Nz = 1400) Diffusivity estimates for the Southern Ocean. """ const SO_DIFFUSIVITIES = (ν = 1e-6, κ = (S = 1e-9, T = 1e-7)) +""" + const EQUAL_ST_DIFFUSIVITIES +Equal salinity and temperature diffusivities. The salinity diffusivity is increased to match +temperature diffusivity. The viscosity and temperature diffusivities are still close to +physical values. +""" +const EQUAL_ST_DIFFUSIVITIES = (ν = 1e-6, κ = (S = 1e-7, T = 1e-7)) """ const REFERENCE_DENSITY Reference density for use in the two layer DNS. Calculated using the salinity `S₀ˡ` and temperature `T₀ˡ` of the lower layer . """ -const REFERENCE_DENSITY = gsw_rho(34.7, -1.5, 0) +const REFERENCE_DENSITY = gsw_rho(34.7, 0.5, 0) """ const INTERFACE_LOCATION -Location of the interface (in the vertical) between the upper and lower layers. +Location of the interface (in the vertical) between the upper and lower layers. This +default setting is in the middle of the [`DOMAIN_EXTENT`](@ref). """ -const INTERFACE_LOCATION = -0.375 +const INTERFACE_LOCATION = -0.5 """ const SIMULATION_PATH Path to where the simulations are saved by default. If the folder does not exist it will be diff --git a/src/twolayerdns.jl b/src/twolayerdns.jl index ededa11..ec7ef26 100644 --- a/src/twolayerdns.jl +++ b/src/twolayerdns.jl @@ -70,7 +70,7 @@ function DNSModel(architecture, domain_extent::NamedTuple, resolution::NamedTupl Lx, Ly, Lz = domain_extent.Lx, domain_extent.Ly, domain_extent.Lz Nx, Ny, Nz = resolution.Nx, resolution.Ny, resolution.Nz - zgrid = zgrid_stretching ? grid_stretching(Lz, Nz, refinement, stretching) : (-Lz, 0) + zgrid = zgrid_stretching ? grid_stretching(-Lz, Nz, refinement, stretching) : (Lz, 0) grid = RectilinearGrid(architecture, topology = (Periodic, Periodic, Bounded),