Mp3, how it compresses the sound and why it needs to be normalized


Free Download Mp4Gain
picture

The mp3 bases its effectiveness on that it is based on human hearing. That is, from knowing the limitations and behaviors of the human ear, it is that they have managed to eliminate information without this fact affecting the quality, if other values, such as bitrate and sample rate, are kept at adequate levels.

Sound perception
Characteristics of human hearing

Human hearing is not perfect. In addition to the physical limitations of the ear, sound has to travel through the nerves to the auditory cortex of the brain, where it is transformed into different perceptions of which we are aware.

sound perception mp3
Volume:

Two sounds with the same amplitude can be perceived with different intensity depending on the frequencies they have. The perception of the intensity of a sound is not constant with frequency. The human ear has a greater sensitivity to sound between 1000 and 5000 Hz. All the points of the curve are perceived with the same volume (volume), but the necessary sound pressure is not the same.


Frequency range

Human beings can perceive sounds in the frequency range of 20 Hz to 20 kHz due to the physical limitations of the ear. The frequency range changes with age, we lose the ability to hear the higher frequencies as we age.


Dynamic range

The smallest variation in air pressure that a human can detect (20 micropascals) measured at the frequencies where we are most sensitive, is used as a reference (0 dB) to measure the intensity of other sounds.

Power in dB (decibels) =, where P is the power considered and is the power corresponding to 20 micropascals.

A normal conversation is between 50-60 dB and the sound of car traffic is approximately 80 dB. The maximum sound that the ear can tolerate is 130 dB, which provides a dynamic range of 0 to 130 dB.


Auditory masking

Hearing masking is defined as the “decreased audibility of one sound due to the presence of another.” Auditory masking consists of frequency masking and temporal masking:


Frequency masking:

Also called simultaneous masking, it is best explained with an example. If you have a loud sound with a frequency of 1000 Hz, and also a sound at the 1100 Hz frequency that is 18 dB below the above, the 1100 Hz sound cannot be heard because it is being masked by the louder sound of 1000 Hz. This is because the 1000 Hz sound is louder and has a close frequency. The closer they are in frequency, the louder the sounds that can be masked by the louder sound. (Figure 2)

Temporary masking: occurs before and after a loud sound. If a sound is masked after a louder sound, it is called post-masking, and if it is masked in advance it is called pre-masking. Previous masking only exists for a brief moment (20 ms). Subsequent masking takes effect up to 200 ms. (Figure 3).

By exploring both masks (in frequency and time) it is possible to substantially reduce the audio information, without an audible change.

That is, there are at least four facts that allow the information to be reduced without the ear detecting it.

1.- The human ear does not detect the stereo in the low frequencies.

2.- If two or more sounds occur at nearby frequencies, the human ear will only listen to the loudest sound.

3.- The sounds before and especially after a loud sound are also masked or “covered” by the loudest sound.

4.- The ear does not receive the same volume at all frequencies.

All this allows the mp3 to discard information, a lot of information, that the human ear will not detect, if a suitable bitrate and samplerate are used.

Waveform and perceptual encoders

There are two types of audio encoders. First we have the waveform encoders, which try to reconstruct the signal as exactly as possible after encoding and decoding.

Perceptual encoders do not attempt to keep the signal exactly as it was before the encoding and decoding step. They seek to ensure that the human ear perceives the output as the original. Taking advantage of knowledge about the properties of hearing and the limitations of human hearing, the perceptual encoder removes part of the signal that we cannot perceive.

Almost all perceptual encoders transform the sound from the time domain to the frequency domain, and they soon separated the different frequencies into subbands. Then he uses his knowledge of how the ear works to remove unnecessary information. The chewing effect is the most commonly explored hearing phenomenon.


Free Download Mp4Gain
picture


Mp4Gain Main Window
picture


Mp4Gain Features
picture


Free Download Mp4Gain
picture

Sound perception

Up to 20 years if you have not abused headphones and concerts, the ability to perceive frequencies is maximum. Or approximately 20Hz to 20,000Hz. 1 Hertz is written Hz, = one oscillation per second.

The louder the sound, the more directional it is in space like a laser beam. That is why it is advisable to have tweeters at ear level, but treble stops quickly due to obstacles.

The lower the sound, the more it radiates in all directions and crosses many obstacles such as walls and ceilings.

A church organ can drop to 16Hz. The bass of a 26.7Hz grand piano, the electric basses are between 40 and 50Hz. The lowest frequencies are vibrations that we can pick up. Higher frequencies, if not directly audible, can influence the audible frequencies through the harmonic set. These harmonics are multiples or submultiples of the fundamental frequencies. They characterize the timbre of a voice or an instrument or a microphone.

The most common audio formats.

.MP3 called MPEG 1 and 2 layer 3 (since 1992)
The evolution of the format recently stopped, it is a compressed format. There are 56 different 56Khz qualities, enough to listen to a dictated text. 128kilo bits per second is fine for electric music or 320KBPS, the highest quality in MP3. It exists in medium quality with a variable bit rate VBR = variable bit rate. The quality of the transmission varies in real time according to the variations of the audio file.

.WMA Windows Media Audio (since 1999)
Compressed format used by Microsoft Windows software with variable quality, in some cases lower or higher than MP3. In 8 or 16 bits, sampled from 8Hz to 48KHz, mono or stereo with a data stream of 5 to 192KHz. With a quality roughly equal to MP3 128KPPS, the 96KHz WMA file takes 25% less space than MP3.

.OGG Vorbis (since 1993)
Less common format. It is a compressed audio format that comes from the free Linux environment. Slightly higher than MP3 and WMA format suitable for 8 to 48KHz 16-24 bit surround sound and transmission, with an audio data stream of 16 to 512KBPS, often 128 to 320KBPS. It exists in medium quality with a variable bit rate VBR = variable bit rate. The quality of the transmission varies in real time according to the variations of the audio file.

AAC Advanced Audio Coding (since 1997)
The compressed format allows better quality than MP3. An upgraded version HE-AAC or eAAC + (MPEG 4) is used for DAB (Digital Audio Broadcasting) digital radio transmission.

.M4a (audio) and .MP4 (audio or video)
Compressed formats. They are used for APPLE products and are of very good quality.

.WAV
It is a very good quality uncompressed format. By default, high-quality recording in dictaphone. For an audio CD (700Mo), these are 16-bit packets extracted or read 44100 times per second = 44.1KHz with a flow of 1411KBPS = Kilo bits per second. Which is much higher than the MP3 which has a 320KBPS limit.