Acoustic impedance Z = ρ·c is the product of a medium's density ρ and its sound speed c. When a pressure wave crosses a boundary between two media of impedance Z₁ and Z₂, part of it reflects and part transmits, with pressure coefficients R = (Z₂−Z₁)/(Z₂+Z₁) and T = 2Z₂/(Z₁+Z₂). The power carried is proportional to p²/Z, so the reflected power fraction is exactly R² and the transmitted power fraction is (Z₁/Z₂)·T² = 1−R² — energy is always conserved.
The wave itself is not faked: a staggered-grid pressure–velocity solver integrates ∂u/∂t = −(1/ρ)∂p/∂x and ∂p/∂t = −ρc²∂u/∂x on a grid whose ρ and c actually change at the boundary, so the reflected and transmitted pulses you see emerge from the same physics used for real acoustic and ultrasound modelling — they are not scaled by hand.
- Z₂ > Z₁ (into a "harder" medium): R > 0, reflected pulse keeps the same phase.
- Z₂ < Z₁ (into a "softer" medium): R < 0, reflected pulse is inverted 180°.
- Z₁ = Z₂: no reflection at all — the pulse passes through untouched.
Honest simplifications. The solver is 1D (plane waves, normal incidence), lossless (no viscous or thermal absorption) and the two half-spaces are semi-infinite (sponge layers at both edges). Playback uses c divided by one common factor, which slows the motion but keeps the Z₁/Z₂ ratio, and therefore R, T and the energy split, exact. The solver check runs a hidden copy of the same grid for the media you picked, waits until the reflected pulse has left the boundary and compares its peak pressure with |R|·amplitude; a few percent of difference is grid dispersion. The material pictures are Blender 5.2 renders used only as decoration.
This is the flat 2D companion to the 3D acoustic-impedance simulation: the same reflection/transmission physics, shown here as a single 1D pressure trace so the split into reflected and transmitted pulses is visible at a glance.