GCSE · Computer Science · OCR · Spec J277
Sample rate, duration, bit depth
Same sound, two files: one small, one huge. And the huge one doesn't always sound better. Squeeze a sound wave through two settings and see what gets lost.
Computer Science · Representing sound
Squeeze a wave into four heights
Pretend the clip lasts one second and 8 samples are taken, so the sample rate is 8 hertz. Each sample uses 2 bits, so it can only take 4 levels: 0 (the shortest bar), 1, 2 or 3 (the tallest). The wave's true heights at the 8 moments are 0.6, 1.8, 2.7, 2.2, 1.4, 0.3, 1.2 and 2.6. Set each bar to the closest level it is allowed, then look at what your stored wave has lost. Notice the bits stored: 8 samples × 2 bits = 16 bits, and painting never changes it. Every sample costs the same.
Work it out: the file size of a sound recording
Every sample costs its bit depth in bits. The sample rate says how many samples there are each second, and the duration says how many seconds the recording lasts. Multiply the three and you have the file size in bits.
WHAT YOU'VE LEARNED
A quick recap of today's lesson.
Two settings decide how faithful a digital sound is, and one multiplication tells you what the file costs.
What you need to know
- A computer stores sound by measuring the wave's height again and again. Each measurement is called a sample.
- Sample rate is how many samples are taken each second. It is measured in hertz (Hz).
- Sample bit depth is the number of bits used to represent each sample.
- Low bit depth limits the values a sample can take, so it is approximated to the closest one. Accuracy drops and distortion can appear.
Have a goPriya has a sample that can only take the levels 0, 1, 2 or 3. The wave's true height is 2.2. She says it will just stay 2.2. What really happens?
It is approximated to the closest level it can take: 2.
A sample can only hold a value its bits allow, so the true height is rounded to the nearest allowed one, and a little accuracy is lost.
- Low sample rate misses changes between samples, so higher frequencies are lost. A higher rate captures the wave more completely.
- Raise the bit depth or the sample rate and quality improves, but more bits are stored, so the file gets bigger.
Have a goPredict: you raise the sample rate and leave the bit depth and the length alone. What happens to the quality and to the file size?
The quality improves and the file gets bigger.
More samples each second capture the wave more completely, but every extra sample is more bits stored.
- File size in bits = bit depth × sample rate × duration in seconds.
- The units must match: bits, hertz and seconds. 1 kHz is 1000 Hz and 1 minute is 60 seconds, so convert first.
Have a goA recording's sample rate is given as 5 kilohertz. What number goes into the formula, and in what unit?
5000, in hertz.
The formula needs hertz, and 1 kilohertz is 1000 hertz. The tempting 5 would give an answer 1000 times too small.
- Afterwards: bits ÷ 8 gives bytes, and bytes ÷ 1000 gives kilobytes (1 kilobyte is 1000 bytes).
- Human ears only hear up to 20 kHz (fewer high frequencies with age), so very high settings mean big files for little perceivable gain.
The big picture
Sound is stored as samples. The sample rate is samples per second, in hertz; the bit depth is bits per sample. Low bit depth approximates samples to the closest value, hurting accuracy. Low sample rate misses changes between samples, so higher frequencies are lost. Raising either improves quality but stores more bits. File size in bits = bit depth × sample rate × duration in seconds, converted first. Very high settings give big files for little perceivable gain.
Key points
Worked example
Problem
Recording A lasts 1 minute, with a sample rate of 2 kilohertz and a bit depth of 4 bits. Recording B lasts 30 seconds, with a sample rate of 4 kilohertz and a bit depth of 8 bits. Which one stores more bits, and how many times as many?
⚠ Watch out
Multiplying with the duration still in minutes (or the sample rate still in kilohertz). The formula needs seconds and hertz, so convert before you multiply.
Memory hook
Bits × hertz × seconds. Check the units, then multiply.
Check yourself
A 12 second clip has a sample rate of 3 kilohertz and a bit depth of 2 bits. What is its file size in bits, and what happens if the bit depth rises to 4?
Flashcards
(11)What is the sample rate?
What is the sample bit depth?
What does a low bit depth do to a digitised sound?
What does a low sample rate do to a digitised sound?
What do higher settings give you, and what do they cost?
What is the formula for a sound file's size in bits?
Which units must the formula use, and what if you are given kilohertz or minutes?
How do you change bits into bytes?
How do you change bytes into kilobytes here?
What is the highest frequency the human ear can hear?
Why not always choose the highest sample rate and bit depth?
Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.
Learning with Lightbulb is opening soon
You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.
Keep me postedMore OCR GCSE Computer Science topics
- Need for primary storage
- Need for secondary storage
- Optical storage
- Purpose of RAM
- Purpose of ROM
- RAM vs ROM
- Solid state storage
- Sound representation: sampling
- Storage characteristics: capacity, speed, portability, durability, reliability, cost
- Suitable storage for application
- Unicode
- Units of data: bit, nibble, byte
How this lesson was checked. This OCR GCSE Computer Science (specification J277)lesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 14 November 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.