MP3 Audio Compression

Teach any GCSE Computer Science class

We have put together a full GCSE Computer Science curriculum that will give you all the teaching materials you need to teach any topic.

Whether you’re a brand new Computer Science teacher, or you’ve been teaching ICT for years, our resources will save you hours and hours of lesson preparation every single week.

View the resources →

The MP3 is a relatively fresh discovery in digital music and sound.  Before MP3, there was only the compact disc (CD).  The audio on a CD is translated from an analog source like a master tape, but nowadays most audio is saved directly in a digital format.

The MP3 process removes those sounds we can’t hear in order to simplify the data stream, making it more compressible.  The idea is to alter things so that the removed data does not affect the quality of the audio.

MP3 Audio Compression Image 1

MP3 cannot create CD quality audio since it removes data from the data stream.  Instead, it is known as near-CD quality or FM quality, but the compression ratio attained is what really makes it stand out.

The MP3 process allows us to identify how much data is removed.  For some, it’s fine to expand the lossy part of compression, since they listen to MP3s in a noisy environment, like in a car or in the office.  In such environs, you won’t hear the most delicate sounds, so it makes sense to optimise for file size rather than audio quality.

If you’re listening to music in a quiet environment, like your living room, you may be more conscious of the loss of quality, and may similarly find yourself unbothered by file size.

The lossy process tuning knob is known as the bit rate.  Bit rates are quantified in bits per second.  MP3 ranges from 96kbps to 320kbps.  At the low end of the scale, 96kbps or 128kbps is comparable to FM radio, whereas at the high end of the scale, 256kbps to 320kbps is comparable to a CD.

 A CD transmits data at a rate of 176KB/s, or 1,400kbps.  This means that a song recorded at the 96kbps bit rate is about 1/14 of the size of a CD track. By way of comparison, at the 256kbps bit rate files are roughly 1/5 of the size.

MP3 Audio Compression Image 2

For example, if a car’s CD player can play MP3 CDs or data CDs with MP3s, you can fit five times as many 256kbps bit rate MP3 tracks on the CD as you could on a standard audio CD.

Several experiments have been carried out and it revealed that, in general, people can’t tell the difference between an audio track encoded as a 256kbps MP3 and a track from a CD.  The only meaningful statistic is that if you know a particular track very well from CD, you’re more likely to spot an MP3-encoded version of it than if you’re listening to a track you’ve never heard before.

However, MP3 file format was intended to hold more than just the lossy-compressed audio data.  The file consists of a set of MP3 frames, each of which contains a header and corresponding data.

A set of frames may be inserted in a tag to specify that the frames are describing something special, like metadata about the MP3 track. Examples of such metadata include the artist’s name, title, album, track number, musical genre, album art, and so on.

 On playback, the metadata tags are read by the audio player, and relevant information is displayed for the user.  Although many CD rippers create metadata for your tracks and set them in the MP3 files, there are MP3 tag editors that let you alter the metadata at a finer level, as well as in a block mode, suitable for changing large amounts of data at once.

MP3s have changed the music environment for good.  Although you can still buy CDs—and even vinyl, has been enjoying a recent comeback—most people consume their music through MP3.

Online sellers like Amazon and iTunes allow you to buy MP3s for immediate download and enjoyment.  Online radio stations allow you to listen to lossy-compressed, streamed tracks, without the need for purchase.

Applications like iTunes and Windows Media Player allow you to rip your CDs as MP3s onto your hard disk for later listening, whereas audio players such as the iPod allows you to listen to your MP3-encoded music wherever and whenever you want to.  One thing is for certain, though: MP3s are here to stay.