ArticleslgStudy

mathematics

Binary image

Binary image is a mathematics topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Binary image rather than just read about it. In short: A binary image is a digital image that consists of pixels that can have one of exactly two colors, usually black and white. Each pixel is stored as a single bit — i.e. either a 0 or 1.

Binary image — main illustration
Binary image — illustration

Key takeaways

  • Binary image belongs to mathematics; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Binary image to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Binary image from memory before moving on to harder problems.

Reference excerpt

A binary image is a digital image that consists of pixels that can have one of exactly two colors, usually black and white. Each pixel is stored as a single bit — i.e. either a 0 or 1. A binary image can be stored in memory as a bitmap: a packed array of bits. A binary image of 640 × 480 pixels has a file size of only 37.5 KiB, and most also compress well with simple run-length compression. A binary image format is often used in contexts where it is important to have a small file size for transmission or storage, or due to color limitations on displays or printers. It also has technical and artistic applications, for example in digital image processing and pixel art. Binary images can be interpreted as subsets of the two-dimensional integer lattice ⁠⁠ℤ2⁠; the field of morphological image processing was largely inspired by this view.

Terminology Binary images are also called bi-level or two-level. Pixel art made up of two colours is often referred to as 1-bit in reference to the single bit required to store each pixel. The names black-and-white, B&W, monochrome or monochromatic are often used, but can also designate other image types with only one sample per pixel, such as grayscale images. In Photoshop parlance, a binary image is the same as an image in "Bitmap" color mode.

Operations on binary images An entire class of operations on binary images operates on a 3 × 3 window of the image. This contains nine pixels, so 29 or 512 possible values. Considering only the central pixel, it is possible to define whether it remains set or unset, based on the surrounding pixels. Examples of such operations are thinning, dilating, finding branch points and endpoints, removing isolated pixels, shifting the image a pixel in any direction, and breaking H-connections. Conway's Game of Life is also an example of a 3 × 3 window operation. Another class of operations is based on the notion of filtering with a structuring element. The structuring element is binary image, usually small, which is passed over the target image, in a similar manner to a filter in gray scale image processing. Since the pixels can only have two values, the morphological operations are erosion (any unset pixels within the structuring element cause the pixel to be unset) and dilation (any set pixels within the structuring element cause the pixel to be set). Important operations are morphological opening and morphological closing which consist of erosion followed by dilation and dilation followed by erosion, respectively, using the same structuring element. Opening tends to enlarge small holes, remove small objects, and separate objects. Closing retains small objects, removes holes, and joins objects. A very important characteristic of a binary image is the distance transform. This gives the distance of every set pixel from the nearest unset pixel. The distance transform can be efficiently calculated. It allows efficient computation of Voronoi diagrams, where each pixel in an image is assigned to the nearest of a set of points. It also allows skeletonization, which differs from thinning in that skeletons allow recovery of the original image. The distance transform is also useful for determining the center of the object, and for matching in image recognition. Another class of operations is gathering orientation-free metrics. This is often important in image recognition where the orientation of the camera needs to be removed. Orientation-free metrics of a group of connected or surrounded pixels include the Euler number, the perimeter, the area, the compactness, the area of holes, the minimum radius, the maximum radius.

Image segmentation Binary images are produced from color images by segmentation. Segmentation is the process of assigning each pixel in the source image to two or more classes. If there are more than two classes then the usual result is several binary images. The simplest form of segmentation is probably Otsu's method which assigns pixels to foreground or background based on grayscale intensity. Another method is the watershed algorithm. Edge detection also often creates a binary image with some pixels assigned to edge pixels, and is also a first step in further segmentation.

Skeletons Thinning or skeletonization produces binary images which consist of pixel-wide lines. The branchpoints and endpoints can then be extracted, and the image converted to a graph. This is important in image recognition, for example in optical character recognition.

Interpretation The interpretation of the pixel's binary value is also device-dependent. Some systems interprets the bit value of 0 as black and 1 as white, while others reversed the meaning of the values. In the TWAIN standard PC interface for scanners and digital cameras, the first flavor is called vanilla and the reversed one chocolate. Dithering is often used for displaying halftone images.

Usages

1-bit pixel art

… excerpt ends here. Continue reading the full article.

Illustrations

Binary image: A photograph of a neighborhood watch sign is the foreground color while the rest of the image is the background color.[1] In the document-scanning industry, this is often referred to as "bi-tonal".
A photograph of a neighborhood watch sign is the foreground color while the rest of the image is the background color.[1] In the document-scanning industry, this is often referred to as "bi-tonal".
Binary image: 1-bit pixel art combining imagery with text
1-bit pixel art combining imagery with text
Binary image: A demonstration of visual cryptography: when two same-sized images of apparently random black-and-white pixels are superimposed, the Wikipedia logo appears
A demonstration of visual cryptography: when two same-sized images of apparently random black-and-white pixels are superimposed, the Wikipedia logo appears

Worked examples

Example 1 — a first encounter with Binary image

Start with the simplest possible case. Write down what Binary image claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In mathematics, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Binary image before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Binary image ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Binary image

In research
Binary image appears in mathematics research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Binary image in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Binary image is common in secondary-school and first-year university syllabi. It links to neighbouring topics 2 (number), Color depths, Digital geometry, so understanding it makes those chapters shorter.
In everyday life
Look for Binary image outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Binary image” →

How to study Binary image in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Binary image means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Binary image out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Binary image in simple terms?

A binary image is a digital image that consists of pixels that can have one of exactly two colors, usually black and white. Each pixel is stored as a single bit — i.e. either a 0 or 1.

Why does Binary image matter?

Because it connects several mathematics ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Binary image?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Binary image.

Tags

  • 2 (number)
  • Color depths
  • Digital geometry
  • Image processing

Keep exploring