Shallow Water wave phase speed.

10 views (last 30 days)
Jeremiah Thomas
Jeremiah Thomas on 8 May 2020
  • I am working on a school assignment for a Tides and Water levels class and there is a question that says to make plots of the following:
  • Shallow water wave phase speed (m/s) for water depths from 1 m to 4000 m. Label the axes.
  • Minimum wavelength to be considered as shallow water waves for the same depth range ( 1 to 4000 meters).
  • I believe I have the first part figured out but am unsure on the second. This is what I have so far:
clear;
clf;
clc;
% Constants
g = 9.81; % gravitational acceleration in m/s^2
d =1:4000 ; % water depth in meters
% Shallow water wave phase speed
c = sqrt(g*d)
%%
plot (c,d);
grid on
ylim([1, 4000]);
xlim([0,200]);
xlabel ('m/s^2')
ylabel('Depth')
title('Shallow Water Wave Phase Speed')
%%
L = g*T^2/2/pi %deep water
L = T*sqrt(gd)%shallow water

Answers (1)

Gabriel Ruiz-Martinez
Gabriel Ruiz-Martinez on 10 Sep 2021
@Jeremiah Thomas, a solution could be this:
% Wave period (s)
T = 2:15;
% Water depths vector (m)
d = 1:4000;
% Gravitational acceleration constant (ms^-2)
g = 9.81;
% Shallow water wave phase speed $ c = sqrt{gh} $
% (ms^-1)
c = sqrt(g.*d);
% Plotting
figure;
plot(d,c,'Color','red');
ax = gca;
ax.XLim = [1 4000];
ax.YLim = [0 200];
ax.XLabel.String = 'Water depth (m)';
ax.YLabel.String = 'Wave speed (ms^-1)';
% Solving dispersion equation, using Lo aproximation **********
for i = 1 : length(T)
for j = 1 : length(d)
Lo = (g*T(i)^2)/(2*pi);
L(j) = Lo*(tanh(((2*pi)*((sqrt(d(j)/g))/T(i)))^(3/2)))^(2/3);
end
end
ld = d./L;
ldq = find(ld <= 0.04);
fprintf('Minimum wavelength to be considered as shallow waters: %5.3f m \r\n',min(L(ldq)));
I hope this script can be useful!.
Regards.

Categories

Find more on Oceanography and Hydrology in Help Center and File Exchange

Products


Release

R2019a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!