Data storage and compression — Edexcel GCSE Computer Science
Verified courseTeaching note checked against the official specification.
Data storage and compression explained
Data storage and compression covers 2 specification points, including Understand that data storage is measured in… and Understand the need for data compression and….
Read the full explanation
Open a point below for its explanation and revision guidance.
2.3.1 understand that data storage is measured in binary multiples (bit, nibble, byte, kibibyte, mebibyte, gibibyte, tebibyte) and be able to construct expressions to calculate file sizes and data capacity requirements
Data storage is measured in binary multiples, each a power of two times the previous unit. A bit is one binary digit; a nibble is 4 bits; a byte is 8 bits. The larger units step by 2¹⁰ = 1024: 1 kibibyte (KiB) = 1024 bytes, 1 mebibyte (MiB) = 1024 KiB = 1 048 576 bytes, 1 gibibyte (GiB) = 1024 MiB, and 1 tebibyte (TiB) = 1024 GiB. To calculate a file size or capacity requirement, multiply the number of items by the bits or bytes each item needs, then convert to the requested unit by dividing by the appropriate power of 1024. For example, an image of 800 × 600 pixels at 24 bits per pixel needs 800 × 600 × 24 = 11 520 000 bits, which is 11 520 000 ÷ 8 = 1 440 000 bytes, or about 1.37 MiB. Always state the unit and keep the direction of each conversion correct.
2.3.2 understand the need for data compression and methods of compressing data (lossless, lossy)
Compression reduces the number of bits used to store or transmit data. It is needed to save storage space, reduce transmission time and lower bandwidth use, and to make files quicker to upload or download. Lossless compression reduces file size while allowing the original data to be reconstructed exactly, so it suits text, spreadsheets, source code and archives; run-length encoding and dictionary-based methods are typical. Lossy compression permanently discards some detail that humans are less likely to notice, giving much smaller files for images, audio and video, but the original cannot be restored exactly. Choosing a method depends on whether exact recovery matters: a text document needs lossless, while a photograph for a web page may accept lossy. Both methods reduce file size, but only lossless preserves every original bit.
Your focus
- State the bit values of a bit, nibble and byte and the 1024 step between kibibyte, mebibyte, gibibyte and tebibyte.
- Construct an expression that multiplies items by bits or bytes per item to find a file size.
- Convert a calculated value into the requested binary unit and label it correctly.
Show all 6 objectives
- Explain why data compression is needed for storage and transmission.
- Describe how lossless compression differs from lossy compression in terms of data recovery.
- Select a suitable compression method for a given file type and justify the choice.
Data storage and compression exam tips
Marking Points
- A bit is a single binary digit and a nibble is exactly 4 bits, so a byte (8 bits) equals two nibbles.
- Binary multiples increase by a factor of 1024 (2¹⁰): 1 KiB = 1024 bytes, 1 MiB = 1024 KiB, 1 GiB = 1024 MiB, 1 TiB = 1024 GiB.
- A file-size expression multiplies the number of items (for example pixels, samples or characters) by the bits or bytes required per item.
- Converting between units divides or multiplies by the correct power of 1024, and the answer must carry the correct unit such as bits, bytes, KiB or MiB.
- Compression reduces file size, which saves storage space and reduces the time and bandwidth needed to transmit data.
- Lossless compression allows the original data to be reconstructed exactly, so it is used where no detail may be lost, such as text or program files.
- Lossy compression permanently removes some data, producing smaller files for images, audio and video where a slight loss of quality is acceptable.
- The choice between lossless and lossy depends on whether exact reconstruction of the original data is required.
Examiner Tips
- 💡Write the expression before evaluating it, for example pixels × bits per pixel ÷ 8, so the method is visible even if the arithmetic slips.
- 💡Convert in clear steps and cancel powers of 1024 one at a time, checking whether the answer should grow or shrink.
- 💡Give the unit with every value and check the question's requested unit before selecting your final option.
- 💡Link each method to a suitable file type, such as lossless for text and lossy for a photograph, to show understanding of the trade-off.
- 💡Use the phrase 'reconstructed exactly' for lossless and 'permanently discarded' for lossy to keep the distinction precise.
- 💡When asked why compression is needed, give both a storage reason and a transmission reason rather than only one.
Common Mistakes
- Treating binary multiples as powers of 1000: the error is using 1000 bytes per kibibyte; the correction is to use 1024, because these are binary multiples.
- Confusing bits with bytes: the error is leaving a pixel calculation in bits when bytes were requested; the correction is to divide the bit total by 8 before converting to KiB or MiB.
- Multiplying when a division is needed: the error is multiplying by 1024 to change bytes into KiB; the correction is to divide by 1024 when moving to a larger unit and multiply when moving to a smaller unit.
- Saying lossy compression can be reversed to the original: the error is claiming the discarded data can be recovered; the correction is that lossy compression permanently loses detail, while lossless restores the original exactly.
- Believing compression always saves storage but never affects quality: the error is ignoring lossy quality loss; the correction is that lossy compression trades quality for a smaller size.
- Thinking lossless compression works by deleting repeated data: the error is describing deletion; the correction is that lossless methods encode data more efficiently, for example by replacing repeated patterns with shorter codes, so nothing is lost.