Unable to open this exercise
Natural sound is continuous and analogue. When a person speaks or an instrument vibrates, it creates physical pressure waves that travel through the air. Computers, however, can only store and process discrete digital binary numbers (0s and 1s).
To record sound digitally, an Analogue-to-Digital Converter (ADC) must convert continuous sound waves into discrete binary values through a process known as sampling.
Learning Objectives
- Explain how analogue sound waves are sampled and converted to digital form.
- Define and distinguish between sampling rate and sample resolution (bit depth).
- Calculate uncompressed digital audio file sizes using standard parameters.
- Analyze the trade-offs between audio quality, file size, and network transmission requirements.
The Sampling Process
An analogue sound wave is continuous in both time and amplitude. Sampling converts this continuous wave into digital form through three main steps:
- Measurement at Regular Intervals: A microphone converts physical sound vibrations into an analogue electrical voltage signal.
- Quantization: An ADC measures the amplitude (height) of the electrical signal at regular, fixed time intervals.
- Binary Encoding: Each measured amplitude value is mapped to the nearest discrete numeric value and converted into a binary number for computer storage.
Continuous Analogue Wave Sampled Discrete Points
^ ^
Amp | _--_ Amp | * *
| / \ | * *
| / \ | * *
0 +------------> Time 0 +------------> Time
| \ | *
| \-- | **
During playback, a Digital-to-Analogue Converter (DAC) reads the stored binary numbers and converts them back into an analogue voltage signal that vibrates a speaker diaphragm.
Key Sampling Parameters
Two primary parameters govern how accurately an analogue sound wave is represented digitally:
1. Sampling Rate (Hz)
- Definition: The number of sound samples taken per second.
- Unit of Measurement: Hertz ($\text{Hz}$) or kilohertz ($\text{kHz}$), where $1\text{ Hz} = 1\text{ sample per second}$ and $1\text{ kHz} = 1,000\text{ samples per second}$.
- Typical Values:
- Voice telephony: $8,000\text{ Hz}$ ($8\text{ kHz}$)
- CD-quality music: $44,100\text{ Hz}$ ($44.1\text{ kHz}$)
- Studio master audio: $96,000\text{ Hz}$ ($96\text{ kHz}$)
- Impact: A higher sampling rate captures faster frequency changes in the sound wave. The sampled points are closer together in time, making the reconstructed wave much smoother and closer to the original sound.
2. Sample Resolution / Bit Depth (bits)
- Definition: The number of bits used to encode the amplitude value of each individual sample.
- Unit of Measurement: Bits per sample.
- Formula for Amplitude Levels:
- Typical Values:
- $8\text{-bit}$: $2^8 = 256$ amplitude levels (basic quality, audible background hiss)
- $16\text{-bit}$: $2^{16} = 65,536$ amplitude levels (standard CD audio quality)
- $24\text{-bit}$: $2^{24} = 16,777,216$ amplitude levels (professional studio quality)
- Impact: Higher sample resolution means the amplitude measurement is rounded (quantized) to a much finer scale. This reduces quantization error (the difference between the actual analogue amplitude and the assigned discrete digital value), creating a richer dynamic range and clearer audio.
Audio File Size Calculations
To calculate the size of an uncompressed digital audio file (such as an uncompressed WAV or AIFF file), multiply the four core recording properties:
Where:
- Sample Rate: Expressed in Hz (if given in kHz, multiply by 1,000).
- Sample Resolution: Expressed in bits per sample.
- Duration: Expressed in seconds (if given in minutes, multiply by 60).
- Channels: 1 for Mono (single audio track), 2 for Stereo (left and right channels).
To convert the resulting size from bits into bytes:
Worked Example: Audio File Size
Problem: A student records a 3-minute stereo audio track with a sampling rate of $44,100\text{ Hz}$ and a sample resolution of $16\text{ bits}$. Calculate the file size in:
- Bits
- Bytes
- Mebibytes (MiB), rounded to two decimal places.
Solution Step-by-Step:
- Identify and convert input units:
- $\text{Sample Rate} = 44,100\text{ Hz}$
- $\text{Sample Resolution} = 16\text{ bits}$
- $\text{Duration} = 3\text{ minutes} \times 60 = 180\text{ seconds}$
- $\text{Channels} = 2\text{ (Stereo)}$
- Calculate size in bits:
- Calculate size in bytes:
- Convert to Mebibytes (MiB):
Summary of Trade-offs
Parameter Change | Effect on Sound Quality | Effect on File Size | Effect on Transmission / Streaming |
|---|---|---|---|
Increase Sampling Rate | Captures higher frequencies; smoother wave curve closer to original. | Increases proportionally. | Requires higher bandwidth; longer download times. |
Decrease Sampling Rate | May cause aliasing distortion; loses high frequencies. | Decreases proportionally. | Requires less bandwidth; faster download. |
Increase Sample Resolution | Finer amplitude steps; lower quantization noise; wider dynamic range. | Increases proportionally. | Requires higher bandwidth; consumes more storage. |
Decrease Sample Resolution | Audible quantization noise and distortion on quiet passages. | Decreases proportionally. | Requires less storage and bandwidth. |
Written practice and self-review
A podcast producer decides to upgrade their recording settings from 22,050 Hz / 8-bit to 44,100 Hz / 16-bit.
Explain the effects of increasing both the sampling rate and the sample resolution on:
- The sound quality and accuracy of the digital audio.
- The resulting file size and network transmission requirements.
Write an explanation before checking the theory. Check that each claim answers the question, uses the correct concept and explains why it applies. Discuss uncertain points with a teacher. The structured exercise below checks specific facts; it does not automatically mark this explanation.
AI Socratic Tutor
Need guidance? Ask a question or use the hint below.
AI Socratic Tutor is an All-Access Benefit
Unlock step-by-step Socratic hints, algorithm trace table walkthroughs, and error diagnostics for every Cambridge exercise.
You're chatting with an AI tutor, not a person. AI can make mistakes, so double-check its answers.
Application: Check the reasoning
Application: Check the reasoning
- Mono recording: 8000 samples/second, 8 bits/sample, 3 seconds. Size in bytes: [Space 1]
- Doubling sample rate doubles or halves the raw size? [Space 2]
- Does increasing resolution increase or decrease quantisation precision? [Space 3]
Sign in or create a free account to test your solution and track XP.