An image is modeled as a function returning the light intensity at position .
Here:
- : spatial coordinates of a point in the image
- : light intensity at that point, bounded between a minimum and maximum
Analog Image Model
are continuous and range over a bounded region. is defined at every point of that region and varies continuously.
Properties:
- Infinite spatial resolution
A value exists between any two points. - Continuous intensity
No fixed set of allowed values. - Not directly computable
Needs sampling and quantization before a computer can store or process it.
Examples:
- Photographic film
- Image projected on the retina
- Analog video signal
Digital Image Model
A digital image is obtained from an analog image by 2 discretization steps.
- Sampling
The spatial domain is divided into an grid. Each cell covers a small finite region. - Quantization
The intensity of each cell is mapped to one of discrete levels.
is the average intensity over cell after quantization. The digital image is the matrix of these values. Each element is a pixel.
Here:
- : number of rows
- : number of columns
- : row index,
- : column index,
- : number of intensity levels, usually for a bit depth
is the spatial resolution. is the bit depth. An 8-bit grayscale image has levels, for black and for white.
Storage size in bits is for a single channel. A color image repeats this per channel.
In a computer program, an image is simply a matrix of integer values. Image processing means manipulating this matrix.
Coarse Sampling
Large grid cells, so a small and low spatial resolution. Too sparse to record fine spatial variation.
- Small features fall between sample points and disappear.
- Edges and text look blocky. This is pixelation.
- Fast repeating patterns reappear as a false slower pattern. This is aliasing.
Coarse Quantization
Few intensity levels, so a small and low bit depth. The gaps between levels are large.
- Nearby intensities collapse to the same level.
- A slow gradient becomes a set of flat steps with visible jumps between them. This is banding, also called contouring.
- Most visible in skies and other large smooth regions.

Color banding visible in sky. Image by By Steve F, CC BY-SA 2.0.