 # Representing Sound in a computer Analogue  Analogue sound is produced by being picked up by a transducer (microphone) and converted in an electrical current.

## Presentation on theme: "Representing Sound in a computer Analogue  Analogue sound is produced by being picked up by a transducer (microphone) and converted in an electrical current."— Presentation transcript:

Representing Sound in a computer Analogue  Analogue sound is produced by being picked up by a transducer (microphone) and converted in an electrical current or voltage that is dependant on the pressure of the sound waves that are incoming.  To hear analogue sound the electric current is used to create sound by vibrating a mechanical surface in a speaker or earphone reproducing the original sound wave. The higher the pitch the more rapids the vibrations.  Digital sound is where the electrical signal from a transducer is converted into a sequence of numerical values proportional to the strength of the signal.

Representing Sound in a computer Analogue to Digital Conversion Below is a diagram on how we receive sound – as waves

Representing Sound in a computer Analogue to Digital Conversion When you sample the wave with an analogue-to-digital converter, you have control over two variables:  The sampling rate - Controls how many samples are taken per second  The sampling precision - Controls how many different gradations (quantization levels) are possible when taking the sample In the following figure, let's assume that the sampling rate is 1,000 per second and the precision is 10:

Representing Sound in a computer Analogue to Digital Conversion The green rectangles represent samples. Every one-thousandth of a second, the ADC looks at the wave and picks the closest number between 0 and 9. The number chosen is shown along the bottom of the figure. These numbers are a digital representation of the original wave. You can see that the blue line lost quite a bit of the detail originally found in the red line, and that means the fidelity of the reproduced wave is not very good. This is the sampling error.

Representing Sound in a computer Analogue to Digital Conversion In the following figure, both the rate and the precision have been improved by a factor of 2 (20 gradations at a rate of 2,000 samples per second):

Representing Sound in a computer Analogue to Digital Conversion In the following figure, the rate and the precision have been doubled again (40 gradations at 4,000 samples per second): You can see that as the rate and precision increase, the fidelity (the similarity between the original wave and the DAC's output) improves. In the case of CD sound, fidelity is an important goal, so the sampling rate is 44,100 samples per second and the number of gradations is 65,536. At this level, the output of the DAC so closely matches the original waveform that the sound is essentially "perfect" to most human ears.

Representing Sound in a computer Analogue to Digital Conversion CD-DA, the standard audio CD, is said to have a data rate of 44.1 kHz/16, meaning that the audio data was sampled 44,100 times per second and with a bit depth of 16. CD-DA is also stereo, using a left and right channel, so the amount of audio data per second is double that of mono, where only a single channel is used. stereochannel The bit rate of PCM audio data can be calculated with the following formula: For example, the bit rate of a CD-DA recording (44.1 kHz sampling rate, 16 bits per sample and 2 channels) can be calculated as follows

Representing Sound in a computer Analogue to Digital Conversion The cumulative size of a length of audio data (excluding a file header or other metadata) can be calculated using the following formula:headermetadata The cumulative size in bytes can be found by dividing the file size in bits by the number of bits in a byte, which is 8: Therefore, 80 minutes (4,800 seconds) of CD-DA data requires 846,720,000 bytes of storage:

Representing Sound in a computer 1)Investigate what the process of converting to mp3 does to a sound track. 2)What does lossless mean? 3)What does lossy mean? 4)Read page 84 – 86 in your text books. 5)Answer the questions on page 86.

Download ppt "Representing Sound in a computer Analogue  Analogue sound is produced by being picked up by a transducer (microphone) and converted in an electrical current."

Similar presentations