Supply teacher deck · Computer Science · Year 10

Calculating File Sizes for a Digital Archive

Slide 1 of 7
04:00

Slide 1 of 7 · Settling starter · Computer Science · Year 10

4 minutes

Calculating file sizes for a digital archive

Lleisiau’r Cwm (Voices of the Valley) is a volunteer group in the Cynon Valley turning old photographs and recorded interviews into digital files. They have a 15 GB cloud account and no idea whether everything will fit. Gareth, the chair, asks: “Will it all fit? Should we squash the files, and will that spoil them?”

While the register is called: write your name, class and date on your worksheet, then read sections 1 and 2 of the brief, the project and the storage units table.

Starter question: How many bytes are in 1 KB, and how many KB are in 1 GB? Remember: 1,024, not 1,000.

DCF: Interacting and collaborating → Storing and sharing Calculators out · no computers needed

Slide 2 of 7 · Today’s brief and key words · Computer Science · Year 10

3 minutes

Your brief: size every file, then write Gareth a storage plan

You will work out how big each scan and recording is, what compression does to it, whether the whole collection fits in 15 GB, and then write a storage plan of about 80 words. Show your working every time: in the exam, the working earns marks even when the final answer slips.

Base 2 units

8 bits in a byte, then 1,024 for every step: KB, MB, GB, TB. Divide to go up a unit, multiply to go down.

Colour depth & bit depth

Bits per pixel in an image (1 bit gives 2 colours, 8 bits gives 256, 24 bits about 16.7 million). Bits per sample in sound.

Lossless & lossy

Lossless (PNG, FLAC) brings every bit back exactly. Lossy (JPEG, MP3) throws detail away for good.

Compression ratio

Original : compressed, written as something : 1. 900 KB squashed to 300 KB is 3 : 1, a 66.7% reduction.

LNF: Numeracy → Understanding the number system helps us to represent and compare relationships between numbers and quantities → Calculation Finish Step 1 now: 4 warm-up questions

Slide 3 of 7 · Step 2: image sizes · Computer Science · Year 10

12 minutes

Step 2: how big is each scan?

Image size in bits = width × height × colour depth. Then ÷ 8 for bytes, ÷ 1,024 for KB, ÷ 1,024 again for MB. Use the items in section 4. KB and MB to 2 decimal places where needed.

Item Working (bits) Bytes KB MB
P1 2,048 × 1,536 × 8 = 25,165,824 3,145,728 3,072 3.00

(e) P3 is scanned at 1 bit. What happens to the quality and the file size at 8 bits instead, and why might the volunteers do that for a handwritten page?

Step 2 on your worksheet · 12 minutes Write the formula with the real numbers in every row

Slide 4 of 7 · Step 3: sound sizes · Computer Science · Year 10

10 minutes

Step 3: how big is each recording?

Sound size in bits = sample rate in Hz × bit depth × length in seconds. Change the length into seconds first. All 3 recordings are mono, so this is the whole formula.

Item Seconds Working (bits) Bytes KB MB
A1 40 × 60 = 2,400 48,000 × 16 × 2,400 = 1,843,200,000 230,400,000 225,000 219.73

(d) A3 is much smaller per minute than A1. Name the 2 settings that make it smaller, and say what this does to the sound.

Step 3 on your worksheet · 10 minutes Minutes × 60 = seconds, before anything else

Slide 5 of 7 · Steps 4 and 5: compression and the storage plan · Computer Science · Year 10

21 minutes

Step 4 & Step 5: what compression did, then the plan for Gareth

Step 4 (10 min): use section 5. Ratio = original ÷ compressed, written as something : 1. Reduction = (original − compressed) ÷ original × 100, to 1 decimal place. Then say whether each format suits the master copy, the web copy, or both, and why.

File Compression ratio Reduction in size Master, web or both? Why?
P2 as PNG 4,800 ÷ 2,400 = 2 : 1 2,400 ÷ 4,800 × 100 = 50.0% Master. Lossless, so every pixel of the scan can be recovered exactly.

Step 5 (11 min): use section 6: 1,200 photographs like P2 and 60 interviews like A1. (a) uncompressed total, does it fit in 15 GB? (b) PNG and FLAC masters. (c) JPEG and MP3 web copies, masters and web together, space left. (d) a plan of about 80 words for Gareth: formats and why, where the second copy goes, a file name pattern.

Steps 4 and 5 on your worksheet · 21 minutes GB to 2 decimal places · divide by 1,024 twice from KB

Slide 6 of 7 · Self and partner check · Computer Science · Year 10

3 minutes

Check your working as an examiner would

Swap sheets with your partner. Tick each success criterion the work meets, then correct 1 thing: a missing ÷ 8, a 1,000 that should be 1,024, or a ratio not written as something : 1.

  • I can calculate the storage needed for an image and a sound file, showing the working from bits to bytes, KB and MB.
  • I use base 2 units correctly: 8 bits in a byte and 1,024 for every step after that.
  • I can calculate a compression ratio and the reduction in file size.
  • I can use compression as a file management technique, choosing lossless or lossy for a reason.
  • I can plan how files are stored and shared, including a second copy and a file naming pattern.
DCF: Interacting and collaborating → Storing and sharing Finished early? Try the stereo, 1 TB and privacy questions

Slide 7 of 7 · Plenary review · Computer Science · Year 10

2 minutes

Quick-check answers before handing in

Check your headline figures before your worksheets are collected.

Question Correct answer
How big is P2, the colour postcard, in KB and MB? 4,800 KB, 4.69 MB (1,600 × 1,024 × 24 bits, ÷ 8, ÷ 1,024).
What is the compression ratio and reduction for A1 as MP3? 6 : 1 and 83.3%. Lossy, so use it for the web copy.
Does the whole collection fit in 15 GB? Uncompressed 18.37 GB: no. Lossless masters plus web copies 13.49 GB: yes, with 1.51 GB left.
Check your name and class are on your worksheet Leave brief sheets and calculators neat on the desk