Skip to content

Commit 1760bdd

Browse files
authored
Merge pull request #179 from jbisits/jib-patch
Fix `REFERENCE_DENSITY` T value and other `const`ant value updates
2 parents e9115ed + 279a081 commit 1760bdd

File tree

3 files changed

+15
-7
lines changed

3 files changed

+15
-7
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "TwoLayerDirectNumericalShenanigans"
22
uuid = "40aaee9f-3595-48be-b36c-f1067009652f"
33
authors = ["Josef Bisits <[email protected]>"]
4-
version = "0.6.2"
4+
version = "0.6.3"
55

66
[deps]
77
CUDA = "052768ef-5323-5732-b1bb-66c8b64840ba"

src/constants.jl

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
"""
22
const DOMAIN_EXTENT
3-
Domain extent on which the two layer simulations are run.
3+
Domain extent on which my two layer simulations are run.
44
"""
5-
const DOMAIN_EXTENT = (Lx = 0.1, Ly = 0.1, Lz = 1)
5+
const DOMAIN_EXTENT = (Lx = 0.1, Ly = 0.1, Lz = -1)
66
"""
77
const HIGH_RESOLUTION
88
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)
1515
Diffusivity estimates for the Southern Ocean.
1616
"""
1717
const SO_DIFFUSIVITIES == 1e-6, κ = (S = 1e-9, T = 1e-7))
18+
"""
19+
const EQUAL_ST_DIFFUSIVITIES
20+
Equal salinity and temperature diffusivities. The salinity diffusivity is increased to match
21+
temperature diffusivity. The viscosity and temperature diffusivities are still close to
22+
physical values.
23+
"""
24+
const EQUAL_ST_DIFFUSIVITIES == 1e-6, κ = (S = 1e-7, T = 1e-7))
1825
"""
1926
const REFERENCE_DENSITY
2027
Reference density for use in the two layer DNS. Calculated using the salinity `S₀ˡ` and
2128
temperature `T₀ˡ` of the lower layer .
2229
"""
23-
const REFERENCE_DENSITY = gsw_rho(34.7, -1.5, 0)
30+
const REFERENCE_DENSITY = gsw_rho(34.7, 0.5, 0)
2431
"""
2532
const INTERFACE_LOCATION
26-
Location of the interface (in the vertical) between the upper and lower layers.
33+
Location of the interface (in the vertical) between the upper and lower layers. This
34+
default setting is in the middle of the [`DOMAIN_EXTENT`](@ref).
2735
"""
28-
const INTERFACE_LOCATION = -0.375
36+
const INTERFACE_LOCATION = -0.5
2937
"""
3038
const SIMULATION_PATH
3139
Path to where the simulations are saved by default. If the folder does not exist it will be

src/twolayerdns.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ function DNSModel(architecture, domain_extent::NamedTuple, resolution::NamedTupl
7070

7171
Lx, Ly, Lz = domain_extent.Lx, domain_extent.Ly, domain_extent.Lz
7272
Nx, Ny, Nz = resolution.Nx, resolution.Ny, resolution.Nz
73-
zgrid = zgrid_stretching ? grid_stretching(Lz, Nz, refinement, stretching) : (-Lz, 0)
73+
zgrid = zgrid_stretching ? grid_stretching(-Lz, Nz, refinement, stretching) : (Lz, 0)
7474

7575
grid = RectilinearGrid(architecture,
7676
topology = (Periodic, Periodic, Bounded),

0 commit comments

Comments
 (0)