Grades 3–5 · Computing
How do tiny pixels make a digital picture?
A photograph on a screen can show a soft cloud or a curved smile. Enlarge a small digital picture far enough, however, and its edges may become a staircase of squares. Those picture elements are called pixels. A raster image records a color value for each position in a grid, so many separate values can make one recognizable picture.
A tiny four-by-four picture makes the idea easy to follow. Give each square one of two colors, white or blue, and agree that 0 means white and 1 means blue. Now the row 0110 describes white, blue, blue, white. Four rows—0110, 1111, 1111 and 0110—describe all sixteen positions. Drawing each value in its proper place reconstructs the small blue shape.
The digits alone are not the entire description. The reader also needs to know the width of the image, where a row begins and which colors the digits represent. Reading those same sixteen digits as two rows of eight would arrange the colors differently. Shared rules turn a string of values into positions in a picture.
Match each four-digit row to the four squares beside it. The lower pair contains the same sixteen-pixel picture at two display sizes.
Real photographs need many more colors and brightness levels. They use larger sets of values to describe subtle differences between neighboring pixels. More pixels can record smaller features when the image is captured, provided the camera can actually distinguish those details. A greater pixel count by itself does not guarantee a clearer photograph.
Simply drawing the sixteen original squares larger adds no new recorded detail. Software can smooth the enlarged edges by calculating extra values between them, but it cannot recover a forgotten eyelash from these sixteen numbers alone. The striking part is that a picture can travel as data: another device, following the same rules, can rebuild the arrangement of colors without ever seeing the original scene.
About this explanation
Starting knowledge: Read rows from left to right, match two symbols to colors and count a four-by-four grid.
Sources
- CS Unplugged, University of Canterbury — Color by numbers
- NASA Earth Observatory — Remote Sensing
- NASA Earthdata / Esri documentation — Resample function