Chapter 5 Coastal Engineering: Wave Transformation (Shoaling, Refraction and Diffraction)#
1. Introduction#
Wave Diffraction in Coastal Engineering#
Wave diffraction refers to the process where wave energy bends and spreads into the sheltered region behind structures like breakwaters, headlands, or artificial islands. It’s a key factor in designing maritime infrastructure, reducing wave agitation in harbors, and predicting shoreline changes.
Analytical Framework#
The behavior of wave diffraction in gently sloping coastal zones is governed by the Mild-Slope Equation (MSE):
Where:
\(( \eta \)): surface elevation due to wave motion
\(( C \)): phase velocity
\(( C_g \)): group velocity
\(( k \)): wave number \(( = \dfrac{2\pi}{L} \))
\(( L \)): wavelength
\(( \nabla \)): horizontal gradient operator
For simplified cases—such as wave diffraction behind a semi-infinite breakwater—the diffraction coefficient \(( K_d \)) is approximated as:
Where:
\(( r \)): radial distance from the structure
\(( \theta \)): observation angle
\(( \theta_0 \)): wave approach angle
\(( k = \dfrac{2\pi}{L} \)): wave number
\(( F(\sigma) \)): Fresnel integral approximation
Fresnel parameters: $\( \sigma_1 = 2 \sqrt{\dfrac{k r}{\pi}} \sin \left( \dfrac{\theta - \theta_0}{2} \right), \quad \sigma_2 = -2 \sqrt{\dfrac{k r}{\pi}} \sin \left( \dfrac{\theta + \theta_0}{2} \right) \)$
Engineering Significance#
Wave diffraction modeling is essential for:
Harbor Design: Ensuring calm zones for vessel mooring
Shoreline Protection: Shielding coastal areas from excess wave energy
Sediment Management: Understanding longshore transport mechanisms
Your simulation visualizes how wave energy distributes behind an idealized breakwater using diffraction coefficients.
Challenges in Diffraction Modeling#
Realistic Geometry: Most structures aren’t infinite or straight
Multidirectional Waves: Natural wave fields require spectrum-based modeling
Coupled Dynamics: Must consider refraction, reflection, and shoaling
Computational Demand: High resolution simulations can be intensive
Diffraction Model Behind Finite Breakwater (Bettess Method)#
This Jupyter Notebook cell simulates the spatial variation of wave diffraction behind a finite breakwater using the Bettess et al. (1984) method. It calculates the diffraction coefficient ( K_d(x, y) ) at each point in a 2D domain, accounting for:
Wave wavelength
Breakwater length
Wave approach angle
Spatial resolution and domain size
Methodology#
The diffraction coefficient is computed using complex Fresnel-type integrals and exponential phase terms.
The model accounts for diffraction from both breakwater tips, using superposition.
The wave approach angle ( \beta ) rotates the incident wave direction, affecting the diffraction pattern asymmetrically.
Key Functions#
fresnel_ff(sigma)
: Computes Fresnel-type integrals used in the Bettess formulation.kd_bettess(r, θ, L, β)
: Calculates the diffraction coefficient from a single breakwater tip.plot_finite_breakwater_diffraction(...)
: Generates the full spatial field by summing contributions from both tips.
Interactive Controls#
Parameter |
Description |
---|---|
|
Incident wave wavelength |
|
Size of the simulation grid |
|
Grid resolution (number of points) |
|
Total length of the breakwater |
|
Angle of wave approach (from x-axis) |
Visualization Features#
Contour plot of ( K_d(x, y) ) showing energy distribution
Black line representing the breakwater
Red arrow indicating wave approach direction
Colorbar showing magnitude of diffraction coefficient
Physical Interpretation#
Transmission zone (aligned with wave direction): ( K_d \approx 1 )
Shadow zone (behind breakwater): ( K_d < 1 ), decreasing with distance
Oblique wave incidence causes asymmetry in the diffraction field
📘 Wave Shoaling#
Wave shoaling refers to the increase in wave height as ocean waves travel from deep to shallow water. As depth decreases, wave speed slows and wave energy becomes concentrated, causing wave height to rise.
Shoaling Coefficient Equation#
Where:
\(( C_0 \)): deep-water wave celerity
\(( C \)): wave celerity in shallow water
\(( n_0 \)), \(( n \)): group velocity factors (e.g., \(( n_0 \approx 0.5 \)) in deep water)
Simplified for small amplitude waves:
Physical Interpretation#
As depth decreases, wave speed decreases.
To conserve energy flux, wave height increases.
Wave Refraction#
Wave refraction occurs when wave crests bend as different parts of the wave travel through varying depths (and thus different speeds). This leads to wave rays converging or diverging.
Snell’s Law for Waves#
Where:
\(( \theta \)): angle between wave crest and depth contour
\(( C \)): wave celerity
Refraction Coefficient Equation#
Where:
\(( \theta_0 \)): deep-water wave angle
\(( \theta \)): wave angle in shallow water
Physical Interpretation#
Wave angle decreases as wave slows down.
Waves bend toward the shore or around features (headlands, shoals).
Why These Matter#
Shoaling and refraction are critical in:
📐 Coastal engineering
🏖️ Beach erosion studies
🌀 Surf forecasting
🧭 Sediment transport modeling
They affect wave height, energy concentration, and nearshore wave direction.
U.S. Coastline Examples#
East Coast (e.g., Outer Banks, NC):
Gentle slope → strong shoaling
Refraction intensifies erosion near inlets
West Coast (e.g., California):
Steep slope → rapid shoaling
Refraction around canyons like La Jolla spreads energy
Gulf Coast (e.g., Florida Panhandle):
Wide continental shelf → gradual shoaling
Refraction influences barrier island formation
Typical shoaling coefficients: \(( K_s \approx 1.5 \text{ to } 2.5 \))
Refraction impact: 20–50% variation in wave height depending on bathymetry
Reference#
[Bettess et al., 1984] presents a finite element approach to modeling wave diffraction around breakwaters using Berkhoff’s mild-slope equation, a governing equation that accounts for both refraction and diffraction in varying bathymetry. [U.S. Army Coastal Engineering Research Center, 1984] uses the diffraction coefficient (derived for a semi-infinite impermeable breakwater) defined as the ratio of diffracted wave height to incident wave height. The diffraction diagrams in the Shore Protection Manual are derived from a Fresnel-type solution (simplified and adapted for practical coastal engineering use) for semi-infinite breakwaters.
2. Simulation#
🌊 Finite Breakwater Diffraction Simulator (Bettess Method)#
This interactive Jupyter-based tool calculates and visualizes wave diffraction fields behind a finite breakwater using the Bettess (1980) Fresnel integral approach.
🧠 What It Does#
Uses Fresnel-type integrals to simulate wave diffraction from each breakwater tip
Computes total diffraction coefficient (\(K_d\)) by superposing both tip contributions
Visualizes 2D spatial field of \(K_d(x, y)\) across a user-defined domain
Updates dynamically using slider-based widgets
🎛️ Inputs (Slider Controls)#
Parameter |
Description |
---|---|
|
Incoming wave wavelength (m) |
|
Horizontal span of the simulation grid (m) |
|
Grid density (# of steps per axis) |
|
Physical breakwater extent (m) |
|
Incident wave angle from shore-normal (°) |
📊 Outputs#
Contour plot of \(K_d(x, y)\) showing diffraction zones
Breakwater geometry and wave approach direction rendered
Color scale visualizes relative energy transmission (e.g. \(K_d = 0\) = full shadow; \(K_d = 1\) = no shadow)
🧭 How to Interpret the Plot#
High \(K_d\) values indicate areas where waves are transmitted or diffracted strongly
Low \(K_d\) zones suggest sheltered areas with reduced wave energy
Use these maps for:
Breakwater design evaluations
Harbor tranquility analysis
Sediment transport and mooring safety considerations
This tool links Fresnel theory with coastal engineering practice—making wave diffraction visible, scalable, and interactive.
# 📌 Run this cell in a Jupyter Notebook
import numpy as np
import matplotlib.pyplot as plt
from scipy.integrate import quad
import ipywidgets as widgets
from IPython.display import display, clear_output
# 📐 Fresnel-type integrals used in Bettess method
def fresnel_ff(sigma):
Mf = lambda t: np.cos(np.pi * t**2 / 2)
Nf = lambda t: np.sin(np.pi * t**2 / 2)
M, _ = quad(Mf, 0, sigma)
N, _ = quad(Nf, 0, sigma)
i = 1j
ff = (1 + i)/2 * ((1 - i)/2 + M - i * N)
return ff
# 📐 Diffraction coefficient from one breakwater tip
def kd_bettess(r, theta_deg, L, beta_deg):
theta0 = np.radians(90)
theta = np.radians(theta_deg - beta_deg) # relative to wave direction
k = 2 * np.pi / L
sigma1 = 2 * np.sqrt(k * r / np.pi) * np.sin(0.5 * (theta - theta0))
sigma2 = -2 * np.sqrt(k * r / np.pi) * np.sin(0.5 * (theta + theta0))
term1 = fresnel_ff(sigma1) * np.exp(-1j * k * r * np.cos(theta - theta0))
term2 = fresnel_ff(sigma2) * np.exp(-1j * k * r * np.cos(theta + theta0))
kd = np.abs(term1 + term2)
return kd
# 📐 Interactive spatial field generator
def plot_finite_breakwater_diffraction(L, domain_size, resolution, breakwater_length, wave_angle):
clear_output(wait=True)
x = np.linspace(0.1, domain_size, resolution)
y = np.linspace(-domain_size, domain_size, resolution)
X, Y = np.meshgrid(x, y)
Kd = np.zeros_like(X)
# Breakwater tip coordinates
tip1 = np.array([0, -breakwater_length / 2])
tip2 = np.array([0, +breakwater_length / 2])
# Compute diffraction from both tips
for i in range(X.shape[0]):
for j in range(X.shape[1]):
px = X[i, j]
py = Y[i, j]
# Distance and angle from tip 1
r1 = np.sqrt((px - tip1[0])**2 + (py - tip1[1])**2)
theta1 = np.degrees(np.arctan2(py - tip1[1], px - tip1[0]))
# Distance and angle from tip 2
r2 = np.sqrt((px - tip2[0])**2 + (py - tip2[1])**2)
theta2 = np.degrees(np.arctan2(py - tip2[1], px - tip2[0]))
# Total diffraction coefficient (superposition)
kd1 = kd_bettess(r1, theta1, L, wave_angle)
kd2 = kd_bettess(r2, theta2, L, wave_angle)
Kd[i, j] = min(kd1 + kd2, 1.5)
# 🖼️ Plot
plt.figure(figsize=(10, 6))
contour = plt.contourf(X, Y, Kd, levels=50, cmap='viridis')
plt.colorbar(contour, label='Diffraction Coefficient $K_d(x, y)$')
plt.xlabel('Distance Offshore (m)')
plt.ylabel('Distance Along Breakwater (m)')
plt.title(f'Diffraction Field (λ = {L:.1f} m, Breakwater = {breakwater_length:.1f} m, Wave Angle = {wave_angle:.0f}°)')
# Draw breakwater
plt.plot([0, 0], [-breakwater_length / 2, breakwater_length / 2], color='black', linewidth=3, label='Breakwater')
# Draw wave approach arrow
arrow_length = domain_size * 0.4
beta_rad = np.radians(wave_angle)
dx = arrow_length * np.cos(beta_rad)
dy = arrow_length * np.sin(beta_rad)
plt.arrow(-domain_size * 0.6, 0, dx, dy, color='red', width=0.5, head_width=2, head_length=3)
plt.text(-domain_size * 0.6 + dx * 0.6, dy * 0.6, 'Wave Approach', color='red', fontsize=10)
plt.axhline(0, color='gray', linestyle=':', linewidth=1)
plt.legend()
plt.tight_layout()
plt.show()
# 🎚️ Widgets
L_slider = widgets.FloatSlider(value=10.0, min=5.0, max=30.0, step=1.0, description='Wavelength (m)')
domain_slider = widgets.FloatSlider(value=50.0, min=20.0, max=100.0, step=5.0, description='Domain Size (m)')
resolution_slider = widgets.IntSlider(value=100, min=50, max=200, step=25, description='Resolution')
breakwater_slider = widgets.FloatSlider(value=20.0, min=5.0, max=50.0, step=1.0, description='Breakwater Length (m)')
wave_angle_slider = widgets.FloatSlider(value=0.0, min=-60.0, max=60.0, step=5.0, description='Wave Angle β (°)')
# 🔄 Display interactive plot
interactive_plot = widgets.interactive(
plot_finite_breakwater_diffraction,
L=L_slider,
domain_size=domain_slider,
resolution=resolution_slider,
breakwater_length=breakwater_slider,
wave_angle=wave_angle_slider
)
display(interactive_plot)
3. Simulation#
🌊 Interactive Wave Transformation Explorer — Shoaling & Refraction Coefficients#
This Python-based Jupyter widget tool visualizes how wave energy changes as waves move into shallower water, using principles of shoaling and refraction.
Wave refraction and shoaling are thoroughly described in the [] (Volume 1). The wave refraction is modeled based on Snell’s Law and conservation of energy. For shoaling transformation, the manual uses the shoaling coefficient tables for various depths and wave periods. The combined refraction-shaling nomograms are available for rapid estimation.
🧠 What It Does#
Computes:
Wave celerity (\(C\)): speed of wave propagation at varying depths
Shoaling coefficient (\(K_s\)): change in wave height due to depth-induced slowing
Refraction coefficient (\(K_r\)): angular redistribution of wave energy due to changing wave direction in shallower depths
Produces dynamic plots of \(K_s\) and \(K_r\) vs. water depth
Provides real-time control via sliders for wave period and wave angle
🎛️ User Inputs#
Parameter |
Description |
---|---|
|
Time between wave crests (s) |
|
Incident angle of incoming wave (°) |
📊 Outputs#
Plots showing:
Shoaling coefficient \(K_s\) — increases as depth decreases, amplifying wave height
Refraction coefficient \(K_r\) — varies with wave angle, showing energy focusing or dispersion
Both coefficients plotted against water depth from 30m to 1m
Depth axis reversed to emphasize shoreline approach
🧭 How to Interpret#
High \(K_s\) at shallow depths → wave height increases, stronger surf
Variable \(K_r\) → shows influence of wave angle on energy concentration
Tool helps explore coastal wave transformations relevant to beach design, sediment transport, and surf forecasting
This tool brings textbook theory to life—ideal for visualizing nearshore wave dynamics and their impact on coastal morphology.
import numpy as np
import matplotlib.pyplot as plt
import ipywidgets as widgets
from IPython.display import display, clear_output
# 🌊 Wave celerity function
def wave_celerity(T, h, g=9.81):
kh = (2 * np.pi / T) * np.sqrt(h / g)
C = np.sqrt(g * h) * np.sqrt(np.tanh(kh))
return C
# 🎯 Shoaling coefficient
def shoaling_coefficient(C0, C):
return np.sqrt(C0 / C)
# 🎯 Refraction coefficient
def refraction_coefficient(theta0_rad, C0, C):
sin_theta = (C / C0) * np.sin(theta0_rad)
theta_rad = np.arcsin(np.clip(sin_theta, -1, 1))
return np.sqrt(np.cos(theta0_rad) / np.cos(theta_rad))
# 📊 Update function for widgets
def plot_coefficients(T, theta0_deg):
clear_output(wait=True)
theta0_rad = np.radians(theta0_deg)
h_vals = np.linspace(30, 1, 100)
h0 = h_vals[0]
C0 = wave_celerity(T, h0)
C_vals = wave_celerity(T, h_vals)
Ks_vals = shoaling_coefficient(C0, C_vals)
Kr_vals = refraction_coefficient(theta0_rad, C0, C_vals)
plt.figure(figsize=(10, 6))
plt.plot(h_vals, Ks_vals, label='Shoaling Coefficient $K_s$', color='dodgerblue')
plt.plot(h_vals, Kr_vals, label='Refraction Coefficient $K_r$', color='darkorange')
plt.gca().invert_xaxis()
plt.xlabel('Water Depth (m)')
plt.ylabel('Coefficient Value')
plt.title(f'Wave Transformation: T = {T:.1f}s, Angle = {theta0_deg:.0f}°')
plt.legend()
plt.grid(True)
plt.tight_layout()
plt.show()
# 🎚️ Interactive widgets
T_slider = widgets.FloatSlider(value=8.0, min=4.0, max=20.0, step=0.5, description='Wave Period (s)')
theta_slider = widgets.IntSlider(value=30, min=0, max=90, step=5, description='Wave Angle (°)')
interactive_plot = widgets.interactive(
plot_coefficients,
T=T_slider,
theta0_deg=theta_slider
)
display(interactive_plot)
4. Self-Assessment#
📘 Conceptual Questions#
What physical processes are represented by the shoaling coefficient ( K_s ) and the refraction coefficient ( K_r )? How do they affect wave height as waves approach shore?
Why does wave celerity decrease with decreasing water depth, and how does this influence both shoaling and refraction?
In the diffraction model, why is the wave energy behind the breakwater lower than in the transmission zone? What causes the spatial decay of the diffraction coefficient \(( K_d \))?
How does the wave approach angle \(( \beta \)) influence the symmetry of the diffraction field? What happens when waves approach obliquely versus perpendicularly?
Why is the diffraction coefficient computed using contributions from both breakwater tips in the finite breakwater model? What would change if only one tip were considered?
Reflective Questions#
When adjusting wave period \(( T \)) in the shoaling/refraction model, how do the coefficients change? What does this tell you about wave transformation for long-period swell versus short-period wind waves?
In the diffraction model, how does increasing the breakwater length affect the size and shape of the shadow zone?
What are the limitations of using linear wave theory and Fresnel-type integrals in modeling real-world diffraction? How might nonlinear effects or wave breaking alter the results?
If you were designing a harbor entrance, how would you use these models to optimize wave sheltering while maintaining navigability?
How would sediment transport patterns be influenced by the diffraction field behind a breakwater? Where would you expect erosion or deposition to occur?
Quiz Questions (Click to Reveal Answers)#
1. What happens to the shoaling coefficient ( K_s ) as water depth decreases?#
A) It decreases
B) It increases
C) It remains constant
D) It oscillates
✅ Show Answer
**Answer: B — It increases** Shoaling causes wave height to increase as waves slow down in shallower water.2. Which coefficient accounts for wave direction change due to depth variation?#
A) Shoaling coefficient
B) Refraction coefficient
C) Diffraction coefficient
D) Celerity coefficient
✅ Show Answer
**Answer: B — Refraction coefficient** Refraction bends wave rays due to depth-dependent celerity.3. In the diffraction model, what does a value of ( K_d \approx 1 ) indicate?#
A) Complete wave blocking
B) Maximum diffraction
C) Full transmission
D) Wave breaking
✅ Show Answer
**Answer: C — Full transmission** This occurs in the transmission zone, aligned with the wave direction.4. Which parameter most directly controls the symmetry of the diffraction field?#
A) Wavelength
B) Breakwater length
C) Wave angle ( \beta )
D) Domain size
✅ Show Answer
**Answer: C — Wave angle \( \beta \)** Oblique wave incidence causes asymmetry in the diffraction pattern.5. What is the primary reason for computing diffraction from both breakwater tips?#
A) To simulate wave breaking
B) To model sediment transport
C) To capture interference and shadowing
D) To calculate wave runup