Music Theory, Audio Engineering & Instruments Pitch, Tuning & Theory 12-tone equal temperament; A4 = 440 Hz per ISO 16

Note to Frequency Calculator (Equal Temperament)

Every note in twelve-tone equal temperament is the reference pitch multiplied by a power of the twelfth root of two. Give this calculator a note name and an octave and it returns the exact frequency, the MIDI note number, the period of one cycle and the wavelength in air. Run it the other way and it names the nearest note to any frequency you measure and tells you how many cents sharp or flat you are. The reference pitch is yours to set, so it works equally well at A440, at the baroque A415, or at whatever your ensemble has settled on.

Calculator

This calculator runs in your browser. Enable JavaScript for live results — the inputs, formula and worked example below remain fully readable without it.

Inputs this calculator takes, with typical values
InputWhat to enterExample
NoteThe pitch class you want. Enharmonic pairs are identical in equal temperament.A
Octave (scientific pitch notation)Octaves start at C, so middle C is C4 and the A above it is A4. A piano runs A0 to C8.4
Reference pitch for A4440 Hz is the ISO 16 standard. Use 415 for baroque pitch, 442 or 443 for many European orchestras.440 Hz
DetuneApplied on top of the note, 100 cents to the semitone. Leave at zero for exact equal temperament.0 cents
Frequency to identifyA measured or tuner-reported frequency; the calculator names the nearest note and the cents error.261.63 Hz
Air temperatureOnly affects the wavelength, through the speed of sound in dry air.20 degC

It returns

  • Frequency — The exact equal-tempered frequency at your reference pitch, including any detune.
  • MIDI note number
  • Period of one cycle
  • Wavelength in air
  • Nearest note to the frequency entered
  • Cents from that note

The formula

f=fref2n6912
n=69+12log2(ffref)
λ=cf,c=331.31+T273.15

In plain text: f = f_ref x 2^((n - 69) / 12)

  • fFrequency of the note (Hz)
  • f_refReference frequency of A4, 440 Hz by ISO 16 (Hz)
  • nMIDI note number: (octave + 1) x 12 + pitch class, so A4 = 69 (semitones)

Twelve-tone equal temperament divides the octave into twelve equal frequency ratios, each of 2^(1/12) = 1.059463. Every note is therefore a power of that ratio away from the reference.

Updated Category Pitch, Tuning & Theory Verified against published test cases Reading time 11 min

What sets a note's frequency

A note name is a position in a repeating pattern; a frequency is a physical rate. Equal temperament is the rule that connects them, and it is deliberately simple: the octave is a doubling of frequency, and it is cut into twelve steps that are equal in ratio rather than in hertz. Each semitone therefore multiplies frequency by the twelfth root of two, 1.0594631. Twelve of those multiplications compound to exactly 2, which is the octave.

That single decision fixes everything else. Once you anchor the system at one pitch, every other pitch follows. The anchor is A4, standardised at 440 Hz by ISO 16, and the MIDI specification numbers that same note 69. So the frequency of any note is 440 Hz times two raised to the power of (its MIDI number minus 69) over twelve.

The consequences are worth noticing. Semitones near the bottom of the range are tiny in hertz - the step from A0 at 27.5 Hz to A#0 is about 1.6 Hz - while the same musical interval at the top of a piano spans nearly 250 Hz. Pitch perception is logarithmic, so those two intervals sound the same size. It is also why a tuner reports error in cents rather than hertz: a 1 Hz error is inaudible at the top of the keyboard and glaring at the bottom.

Reading the formula in both directions

Start with the MIDI number, because it removes all ambiguity about octaves. Scientific pitch notation starts each octave at C, so middle C is C4 and the A above it is A4. The MIDI number is n = (octave + 1) x 12 + pitch class, with C = 0 through B = 11. Middle C gives (4 + 1) x 12 + 0 = 60, and A4 gives (4 + 1) x 12 + 9 = 69, which is the anchor.

Forward, you subtract 69 to get the number of semitones above or below the reference, divide by twelve to turn semitones into octaves, and raise two to that power. Multiply by the reference frequency and you have the answer. Backward, you invert the same chain: divide the measured frequency by the reference, take the base-2 logarithm, multiply by twelve, and add 69. The result is almost never a whole number, and the fractional part multiplied by 100 is exactly the error in cents.

Changing the reference pitch scales the whole system. Set A4 to 415 Hz - roughly the baroque convention used by many period ensembles - and every frequency drops by the factor 415/440 = 0.943182, which is 1200 x log2(0.943182) = −101.27 cents, a hair over a semitone. Set it to 442 Hz, as many European orchestras do, and everything rises by 7.85 cents. The note names and MIDI numbers do not move; only the physical frequencies do.

Wavelength is a separate physical step and depends on air, not on music. The speed of sound in dry air is about 331.3 m/s at 0 degrees C and rises with the square root of absolute temperature, giving 343.2 m/s at 20 degrees C. Divide that by the frequency and you have the wavelength, which is what matters when you are placing a microphone, predicting a room mode, or working out why a bass note vanishes at one seat.

Worked example: the frequency of E2, the low E on a guitar

Take the bottom string of a guitar in standard tuning, E2, at a reference of A4 = 440 Hz and a room at 20 degrees C.

  1. MIDI number. E is pitch class 4, and the octave is 2, so n = (2 + 1) x 12 + 4 = 36 + 4 = 40.
  2. Semitones from the reference. 40 − 69 = −29. The note is 29 semitones below A4.
  3. Convert to octaves. −29 / 12 = −2.41667 octaves.
  4. Raise two to that power. 2−2.41667 = 0.187288.
  5. Multiply by the reference. 440 x 0.187288 = 82.4069 Hz, which is the published value for E2 in equal temperament.
  6. Period. 1 / 82.4069 = 0.0121349 s, or 12.135 ms per cycle.
  7. Wavelength. The speed of sound is 331.3 x sqrt(293.15 / 273.15) = 331.3 x 1.035963 = 343.21 m/s. Divide: 343.21 / 82.4069 = 4.165 m. That is longer than most home studios, which is precisely why low E is the hardest note in a small room to hear evenly.

Now run it backwards. Suppose a tuner reads 82.00 Hz on that string. Then n = 69 + 12 x log2(82.00 / 440) = 69 + 12 x log2(0.1863636) = 69 + 12 x (−2.423797) = 69 − 29.08556 = 39.9144. The nearest whole number is 40, which is E2, and the fractional part is −0.0856, so the string is 8.57 cents flat. Five cents is the usual threshold at which a sustained note is heard as out of tune against another instrument, so that is worth correcting.

How to read the cents figure

Cents are the currency of tuning accuracy because they are logarithmic, like hearing. One hundred cents is a semitone anywhere in the range, whether that is 1.6 Hz at the bottom of a piano or 240 Hz at the top. Below roughly five cents, a discrepancy on a sustained pure tone is inaudible to most listeners. Between five and fifteen cents it is audible as beating when two instruments play together, even when neither sounds wrong alone. Above about twenty cents most listeners describe the note as out of tune.

A deviation near fifty cents means the calculator has no useful answer to give you, because the frequency sits halfway between two semitones and the nearest-note label becomes arbitrary. The calculator warns you above forty cents for this reason. If you get that reading from a tuner on a real instrument, suspect that you are measuring an overtone rather than the fundamental, or that the note is genuinely between two pitches.

Real instruments are not exactly equal-tempered, and that is not a fault. Piano tuners deliberately stretch the octaves - sharpening the treble and flattening the bass, often by 30 cents or more at the extremes - because piano strings are stiff enough that their overtones sit sharp of exact harmonics, and octaves tuned pure to the fundamental sound flat. The harmonic series calculator shows where those overtones fall and by how much they deviate. Brass players lip notes into place, string players adjust by ear, and singers lean intervals toward just intonation when the harmony allows it. Use the cents and interval calculator to see how far equal temperament sits from those just ratios.

Reference frequencies for A in every octave, and the octave around middle C

Equal temperament at A4 = 440 Hz. Every A is an exact power-of-two multiple of 27.5 Hz, which is why the A column is free of rounding.
NoteMIDIFrequency (Hz)Wavelength at 20 C (m)
A0 (lowest piano note)2127.50012.48
A13355.0006.24
E2 (guitar low E)4082.4074.16
A245110.0003.12
A357220.0001.56
C4 (middle C)60261.6261.312
E4 (guitar high E)64329.6281.041
A4 (reference)69440.0000.780
C572523.2510.656
A581880.0000.390
A6931760.0000.195
C8 (highest piano note)1084186.0090.082

Wavelengths use a speed of sound of 343.21 m/s, from 331.3 x sqrt(293.15/273.15). Frequencies are the equal-tempered values from the formula above, rounded to three decimals.

Pitfalls and limits

  • Octave numbering conventions differ. This calculator uses scientific pitch notation, where middle C is C4 and MIDI 60. Yamaha instruments have historically called that same note C3. Check which convention your device uses before blaming the arithmetic.
  • Equal temperament is a compromise, not a description of a real instrument. No acoustic instrument produces exactly these frequencies, and pianos are deliberately stretched away from them.
  • A tuner may be locking to an overtone. If a reading is roughly 700, 1200 or 1900 cents away from what you expect, you are measuring the second, third or fourth partial rather than the fundamental.
  • Wavelength depends on temperature, not on humidity to any useful degree. Going from 0 to 30 degrees C raises the speed of sound by about 5.5%, which shifts room modes noticeably; humidity moves it by well under 1% over normal indoor conditions.
  • MIDI 1.0 carries only notes 0 to 127, which is C-1 to G9. Pitches outside that have frequencies but no note number in a standard MIDI message.
  • Detuning in cents is multiplicative, not additive. Adding 50 cents to a note does not add a fixed number of hertz; it multiplies the frequency by 2^(50/1200) = 1.02930.

Where 440 came from, and what else is used

Concert pitch has not always been 440 Hz, and it is not universally 440 now. Surviving instruments show that eighteenth-century pitch varied by more than a semitone between cities. Nineteenth-century orchestras drifted steadily upward as brighter, louder ensembles competed, until an international conference in the twentieth century settled on 440 Hz for A4; ISO 16 records that standard. Many European orchestras today tune to 442 or 443 Hz, which is 8 to 12 cents sharp of the standard - enough that a visiting soloist notices, and enough to matter to a wind instrument whose length is fixed.

Historically informed performance goes the other way, using A415 for baroque repertoire, almost exactly a semitone below A440, which conveniently lets a harpsichord be transposed by a whole key rather than retuned. A392 appears for French baroque music and A430 for classical-era work. None of these is more correct than another; they are conventions attached to repertoire.

Equal temperament itself is one option among many. Just intonation tunes intervals to small whole-number ratios, so a major third is exactly 5:4 - 386.31 cents - rather than the equal-tempered 400 cents, and it sounds noticeably purer in one key. Meantone and well temperaments distribute the compromise unevenly so that common keys sound better than remote ones. Equal temperament makes every key equally usable and every key equally impure, which is what made unrestricted modulation possible. When you need to know the size of that impurity, the cents and interval calculator quantifies it, and the transposition calculator handles the key arithmetic that equal temperament makes safe.

Frequency also feeds directly into instrument setup. String tension goes as the square of frequency, so a change of reference pitch or a drop tuning changes the load on the neck; the string tension calculator works that out from gauge, scale length and target pitch.

Frequently asked questions

What is the frequency of middle C?

261.626 Hz in equal temperament with A4 at 440 Hz. Middle C is C4 in scientific pitch notation and MIDI note 60, nine semitones below A4. Working it through: 60 − 69 = −9 semitones, 2 raised to −9/12 is 0.594604, and 440 x 0.594604 = 261.626 Hz. If your ensemble tunes to 442 Hz, middle C becomes 262.815 Hz.

How do I convert a MIDI note number to frequency?

Use f = 440 x 2^((n − 69) / 12), where n is the MIDI number. The formula works because MIDI numbers count semitones and note 69 is defined as A4. MIDI 60 gives 261.626 Hz, MIDI 69 gives 440 Hz, and MIDI 81 gives 880 Hz. Adding 12 to the note number always doubles the frequency, since twelve semitones is an octave.

How many cents off is audible?

Around five cents on a sustained note played alongside another instrument, and closer to ten to fifteen cents for a note heard alone. Beating between two nearly identical pitches is far easier to detect than absolute pitch error, which is why unison and octave tuning is done by listening for the beat rate. Above twenty cents most listeners simply hear the note as wrong.

Why do some orchestras tune to 442 Hz instead of 440?

Because a slightly higher pitch sounds marginally brighter and more brilliant, and the practice has accumulated by tradition. 442 Hz is 7.85 cents above 440 Hz. It matters most to wind and brass players, whose instruments have a fixed length and can only be pulled or pushed so far, and to keyboards that must be physically retuned. Strings simply adjust.

What is scientific pitch notation and why does middle C sometimes appear as C3?

Scientific pitch notation numbers each octave from C upward, making middle C into C4 and MIDI note 60. Some manufacturers, Yamaha most prominently, label MIDI 60 as C3 instead, shifting every octave number down by one. The frequencies and MIDI numbers are identical; only the label differs. Check your device's manual if a note is exactly an octave away from what you expect.

Does temperature change the pitch of an instrument?

It changes wind instruments substantially and string instruments less directly. A wind instrument's pitch depends on the speed of sound inside it, which rises about 0.17% per degree C, so a flute warms sharp by roughly 3 cents per degree. Strings go flat as they warm because the string lengthens and tension drops. This calculator's temperature input affects only the wavelength, which is a property of the air rather than the instrument.

How do I find the wavelength of a note?

Divide the speed of sound by the frequency. At 20 degrees C the speed is 343.2 m/s, so A4 at 440 Hz has a wavelength of 0.78 m and low E on a bass guitar at 41.2 Hz has a wavelength of 8.3 m. Wavelength governs how sound interacts with a room: a wall spacing near half a wavelength creates a standing wave, and a microphone moved a quarter wavelength changes phase by 90 degrees.

Can I use this for a tuning other than equal temperament?

Only by entering the deviation yourself in the detune field. The calculator implements twelve-tone equal temperament exactly. To reach a just-intonation pitch, look up the interval's deviation in cents and enter it - a just major third sits 13.69 cents below the equal-tempered one, so a just E above C4 is E4 detuned by −13.69 cents.

References