I am trying to create a plot that looks like the picture.
Wave Particle Motions under Wave
This is not homework, i'm trying to do this for experience.
I don't need the whole code.. i need to know what type of plot to use because i cant figure it out.
I have tried a few different ways and got errors every time and i searched matplotlib for info about how to plot it, but no luck.
I have the following parameters:
Plot the water particle motions under Trough (Lowest point on wave elevation profile) at water depths from 0 to 100 meters in increments of 10 m below mean water line.
A = 1 # Wave amplitude in meters
T = 10 # Time Period in secs
n_w = 1 # Number of waves
wavelength = 156 # Wavelength in meters
k = (2 * np.pi) / wavelength
w = (2 * np.pi) / T
The wave profile varying over space is 𝜂(𝑥) = 𝐴cos(𝑘x) at time = 0. Plot this wave profile first for one wave.
𝜂(𝑥) = 𝐴*cos(𝑘x) #at time = 0
Next compute vertical and horizontal particle displacements for different water depths of 0 to 100m
XDisp = -A * e**(k*z) * np.sin(-w*t)
YDisp = -A * e**(k*z) * np.cos(-w*t) # when x=0
You could use any x. Motion magnitudes don’t change. Where z is depth below mean water level. All other parameters are as defined in earlier problems above.
Do not forget to shift the horizontally particle displacement to under trough and ‘z’ below water line for vertical particle displacement.
