Helmholtz Resonator Calculator

Resonance of a cavity with a neck, pitch and design.

  • Frequency and note
  • End correction
  • Size for a pitch
A small rounded clay table holding a soft clay round vessel with a short neck, rounded waves widening in an arch above the neck, and a few loose beads, in soft daylight.

The guide

A bottle hums because its neck is a mass and its belly is a spring

A cavity with a short neck has one preferred pitch, set by three sizes and the speed of sound, and the neck always acts a little longer than it is.

  • 161.26 Hz 1 litre cavity, 20 mm neck, 30 mm long
  • 36 mm equivalent length of that 30 mm neck
  • 9.54 percent pitch error from leaving out the end correction
  • 37.7 cents flat offset from the nearest note, E3
  • 2.149 L cavity that brings that neck to 110 Hz
Read the full guide Fold the guide 7 min · 12 sources

Blow across the mouth of an empty bottle and it hums. Nothing in the bottle moves except air, yet the note is steady and it changes when you pour in water. The pitch is not a property of your breath. It belongs to the bottle.

Hermann von Helmholtz described an apparatus of this kind in 1863, a rigid container with a small neck that picks one frequency out of a complex sound. The name stuck, and the same arrangement now shows up in car exhausts, in aircraft engine liners and in rooms, where a resonator tuned to a problem frequency can reduce unwanted low sound. One formula covers all of them, as long as you respect its limits.

A mass on a spring made of air

A Helmholtz resonator is two parts: a cavity and a neck. The air plug in the neck behaves like a mass. The air shut in the cavity behaves like a spring, because squeezing it raises its pressure and that pressure pushes back.

Push the plug in and the cavity air is compressed. Let go and the higher pressure drives the plug out. Its inertia carries it past the starting point, the cavity pressure drops below the outside, and the plug is drawn back. The cycle repeats at one natural rate.

That is the whole mechanism of a mass on a spring, where the restoring force grows with the displacement and the frequency depends on the stiffness and the mass. Here the stiffness comes from the cavity volume and the mass from the neck, so every size in the formula has a plain reading.

The angular frequency is the speed of sound times the square root of the neck area divided by the product of the cavity volume and the equivalent neck length. Divide by two pi and you have hertz. A second form, built from the adiabatic index of 1.4 for air, the static pressure, the cavity volume and the mass of air in the neck, gives exactly the same number, because the speed of sound squared is the adiabatic index times the pressure over the density.

Read the formula from the bottom. The cavity volume sits in the denominator because a larger cavity is a softer spring. The neck length sits there because a longer plug carries more inertia. A wider neck helps twice over, since it moves more air but also moves it more slowly, and the net effect is that the frequency grows as the square root of the area.

The neck always acts longer than it is

Here is the detail that people leave out. Air does not stop dead at the ends of the neck. It drags a little more air along with it on both sides, so the moving plug is longer than the tube. Acousticians fold that extra air into an equivalent length, the real length plus 0.3 times the hydraulic diameter of the neck.

The hydraulic diameter is four times the area divided by the wetted perimeter. For a round neck it is simply the diameter. For a slot it is smaller than the diameter of a round hole with the same area, a fact the calculator uses to refuse an impossible pair of numbers.

The correction is not a trim. It is large when the neck is short. For a neck 20 mm wide and 30 mm long, the equivalent length is 36 mm, a fifth longer than the tube. Leaving it out raises the computed pitch by 9.54 percent, which is more than a semitone and enough to hear.

The end correction page of the same encyclopedia is candid about the number. It gives 0.6 times the radius, which is 0.3 diameters, for a closed pipe with one opening, and adds that the exact figure depends on the geometry. Published values quoted there run from 0.576 to 0.66 times the radius, and a calculated figure of 0.6133 for an ideal cylindrical tube.

Swap those alternatives into the worked example below and the answer moves between plus 0.34 percent and minus 0.82 percent. That is a useful size for the uncertainty, and it is the reason this page quotes one correction and tells you so rather than pretending to a precision it cannot back.

A worked example you can repeat

Take a cavity of 1 litre, which is 0.001 cubic metres, a round neck 20 mm in diameter and 30 mm long, and a speed of sound of 343 metres per second. The neck area is pi times the diameter squared over four, 314.16 square millimetres. Using pi times the diameter squared by mistake quadruples it and doubles the answer.

The equivalent length is 30 mm plus 6 mm, which is the 36 mm already mentioned. Put the numbers in and the resonant frequency is 161.26 Hz, with an angular frequency of 1013.25 radians per second. Those two numbers differ by a factor of two pi, and quoting the second as hertz is a common slip.

Convert the pitch with the standard note-number formula, 69 plus 12 times the base-2 logarithm of the frequency over 440. The result is 51.62, so the nearest note is number 52, which is E3, and the tone sits 37.7 cents flat of it. A cent is a hundredth of an equal-tempered semitone, and an octave is 1200 of them.

Now check the answer in a way that does not reuse the formula. The reference figures for this page were first worked out in 80-digit decimal arithmetic outside the page. Treat the neck air as a lump of 13.64 milligrams, which is the density 1.2057 kilograms per cubic metre times the neck area and the equivalent length, on an adiabatic spring. Step that system forward in time with a fourth-order Runge-Kutta scheme, measure its period, and invert it.

The simulation lands on the same frequency to about one part in a trillion. That agreement says the algebra is right and the small-motion approximation is sound. It says nothing about a real bottle, which has walls and friction and a shape that the model has never seen.

Doubling the cavity to 2 litres multiplies the frequency by one over the square root of two, to 114.03 Hz. Doubling the neck width to 40 mm lifts it to 298.60 Hz, because the area quadruples while the end correction grows from 6 to 12 mm. Doubling the neck length to 60 mm brings it down only to 119.10 Hz, nowhere near half, because the correction is a fixed extra length that does not scale.

Designing for a pitch, and where the formula gives out

Turn the formula around and it becomes a design rule. For a target of 110 Hz with the same neck, the cavity must hold 2.149 L, or 0.002149 cubic metres. With the 1 litre cavity kept, the neck must instead be 71.37 mm long, which is an equivalent length of 77.37 mm.

Some requests have no answer. Ask a small cavity with a wide neck for a very low pitch and the neck length that results can be zero or negative, because the 0.3 times the diameter correction alone already exceeds the length the pitch calls for. The calculator says so in words and does not invent a neck.

The formula also assumes that the whole cavity breathes as one lump. That needs the wavelength to be long compared with the cavity. At 161.26 Hz the wavelength is 2.127 metres against a cavity whose cube root is 0.1 metre, a ratio above twenty. The page cautions below a ratio of ten, a rule of thumb of its own and not a figure from any source.

The source article states the other limits plainly. The formula has limitations that depend on the exact shape of the hole, the thickness of the wall relative to the hole and the size of the cavity. If the mean airflow over the resonator is high, with a Mach number above about 0.3, corrections apply. More careful formulae exist and carry similar physical pictures.

Several things are out of scope altogether: resonators with more than one neck, perforated panels that absorb sound, losses that broaden and lower the peak, and cavities that are not compact. A real bass trap or intake chamber needs measurement. Treat the result here as a first estimate and a way to see how each size pulls the pitch.

The speed of sound in a gas depends on the gas and on its temperature, which is why it is typed in here and not derived. The standard atmosphere, 101325 pascals, enters only the simulation, and it cancels out of the frequency. If you need the speed from a temperature, the Speed of Sound Calculator linked below gives it, and the speed then goes back into this page as a plain number. The simulation runs in a separate worker so typing never stalls, and every figure is formatted by the browser’s own number formatter.

Sources

Every source consulted for this guide. Links checked November 11, 2026.

  1. Helmholtz resonance Wikipedia (CC BY-SA 4.0)
  2. Hydraulic diameter Wikipedia (CC BY-SA 4.0)
  3. End correction Wikipedia (CC BY-SA 4.0)
  4. Harmonic oscillator Wikipedia (CC BY-SA 4.0)
  5. Runge-Kutta methods Wikipedia (CC BY-SA 4.0)
  6. MIDI tuning standard Wikipedia (CC BY-SA 4.0)
  7. Cent (music) Wikipedia (CC BY-SA 4.0)
  8. CODATA Value: standard atmosphere National Institute of Standards and Technology
  9. Speed of Sound Interactive NASA Glenn Research Center
  10. decimal - Decimal fixed-point and floating-point arithmetic Python Software Foundation
  11. Web Workers API MDN Web Docs (CC BY-SA)
  12. Intl.NumberFormat - JavaScript MDN Web Docs (CC BY-SA)