Skip to content

Commit

Permalink
plot domain with band
Browse files Browse the repository at this point in the history
  • Loading branch information
navidcy committed Mar 8, 2024
1 parent f8c0dea commit cf1ad7b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions examples/internal_tide.jl
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,11 @@ bottom(x) = - H + hill(x)

grid = ImmersedBoundaryGrid(underlying_grid, GridFittedBottom(bottom))

# Let's see how the domain with the bathymetry looks.
# Let's see how the domain with the bathymetry is.

x = xnodes(grid, Center())
bottom_boundary = interior(grid.immersed_boundary.bottom_height, :, 1, 1)
top_boundary = 0*x

using CairoMakie

Expand All @@ -61,7 +62,7 @@ ax = Axis(fig[1, 1],
ylabel="z [m]",
limits=((-grid.Lx/2e3, grid.Lx/2e3), (-grid.Lz, 0)))

lines!(ax, x/1e3, bottom_boundary)
band!(ax, x/1e3, bottom_boundary, top_boundary, color = :mediumblue)

fig

Expand All @@ -86,7 +87,7 @@ fig
# the tidal velocity and tidal forcing amplitudes are related via:
#
# ```math
# U_{\mathrm{tidal}} = \frac{\omega_2}{\omega_2^2 - f^2}F_0
# U_{\mathrm{tidal}} = \frac{\omega_2}{\omega_2^2 - f^2} F_0
# ```
#
# Now we have the way to find the value of the tidal forcing amplitude that would correspond to a
Expand Down

0 comments on commit cf1ad7b

Please sign in to comment.