Piano string inharmonicity
A perfectly flexible string has harmonics at exact integer multiples. A real steel wire resists bending. Explore how that stiffness shifts its partials — and why piano octaves are often tuned wider than a simple 2:1 ratio.
Three checks on the mathematics
Dimensional dispersion
Direct Euler–Bernoulli frequency against the dimensionless stiffness formula.
Mode-shape norm
Midpoint integration of the squared sine mode against its closed-form integral.
Adjacent-mode orthogonality
Numerical overlap of neighbouring mode shapes; the ideal integral is zero.
Oscillator energy
Instantaneous kinetic plus potential energy against the conserved single-mode total.
Measure the fundamental
Sample a synthetic pickup signal at a fixed textbook sample rate, detect upward zero crossings, and compare the measured period with the model prediction.
MODEL NOTESThe science+
Governing equation
For a uniform, taut, circular wire with pinned ends, transverse displacement follows the linear Euler–Bernoulli beam-string equation:
Here μ is mass per unit length, T is axial tension, E is Young's modulus, and I = πd⁴/64 is the second moment of area. The modal frequencies are:
What the model simplifies
- The wire is uniform, circular, homogeneous and linearly elastic.
- Supports are ideal pins; real bridges, agraffes and soundboards have finite compliance.
- There is no damping, air loading, string coupling, winding, longitudinal motion or amplitude-dependent stiffness.
- Mode shapes are ideal sine functions. Display motion is slowed and enlarged; it is not a time-accurate recording.
What is illustrative
Slider values and presets are illustrative steel-wire scenarios, not specifications for a particular piano. The half-length octave comparison holds tension, diameter, modulus and density constant to isolate the stiffness effect. Actual piano scales vary wire geometry and tension across the keyboard, and tuning practice also accounts for the instrument's coupled strings and soundboard.
Reading the result
When B approaches zero, the partials approach exact integer multiples. As B grows, higher modes rise progressively farther above those multiples. The octave-stretch readout compares the fundamental of a hypothetical half-length wire with twice the current fundamental; it is a model comparison, not a universal tuning prescription.