Skip to content
Part IA Michaelmas Term

Sampling and Quantisation

Continuous to Discrete

The physical world is continuous, but computers work with discrete values. Two processes convert between them:

Original continuous signal, sampled signal, and quantised signal

Sampling

Sampling maps a continuous function to a discrete one:

  • Spatial coordinates: continuous → discrete pixel positions
  • A continuous image I(x,y)I(x, y) becomes samples I[i,j]I[i, j]

Sampling an Image

Isampled[i,j]=I(xi,yj)I_{\text{sampled}}[i,j] = I(x_i, y_j)

where (xi,yj)(x_i, y_j) are the discrete sample positions on a rectangular grid.

Sampling Rate

The sampling rate (or spatial frequency) determines how densely the continuous signal is sampled:

  • Higher rate: more samples, better representation of detail
  • Lower rate: fewer samples, risk of aliasing

Quantisation

Quantisation maps continuous values to discrete ones:

  • Intensity values: continuous → discrete levels
  • Each colour channel typically quantised to 8 bits (256 levels)

Quantisation Levels

For bb bits per channel, there are 2b2^b discrete levels:

  • 8 bits: 256 levels (0-255)
  • 10 bits: 1024 levels
  • 12 bits: 4096 levels

Relationship Between Sampling and Quantisation

ProcessDomainEffect
SamplingSpatialDetermines spatial resolution
QuantisationIntensityDetermines tonal resolution

Both contribute to image quality and file size.

Summary

  • Sampling discretises spatial coordinates
  • Quantisation discretises intensity values
  • Higher sampling rate captures more detail
  • More quantisation levels capture smoother gradients

Past Paper Questions

2023 Paper 3 Question 3: What is meant by “sampling an image”? How does it differ from quantisation?