# Thinning (morphology)

Jump to: navigation, search

Thinning is the transformation of a digital image into a simplified, but topologically equivalent image. It is a type of topological skeleton, but computed using mathematical morphology operators.

## Example

Let ${\displaystyle E=Z^{2}}$, and consider the eight composite structuring elements, composed by:

${\displaystyle C_{1}=\{(0,0),(-1,-1),(0,-1),(1,-1)\}}$ and ${\displaystyle D_{1}=\{(-1,1),(0,1),(1,1)\}}$,
${\displaystyle C_{2}=\{(-1,0),(0,0),(-1,-1),(0,-1)\}}$ and ${\displaystyle D_{2}=\{(0,1),(1,1),(1,0)\}}$

and the three rotations of each by ${\displaystyle 90^{o}}$, ${\displaystyle 180^{o}}$, and ${\displaystyle 270^{o}}$. The corresponding composite structuring elements are denoted ${\displaystyle B_{1},\ldots ,B_{8}}$.

For any i between 1 and 8, and any binary image X, define

${\displaystyle X\otimes B_{i}=X\setminus (X\odot B_{i})}$,

where ${\displaystyle \setminus }$ denotes the set-theoretical difference and ${\displaystyle \odot }$ denotes the hit-or-miss transform.

The thinning of an image A is obtained by cyclically iterating until convergence:

${\displaystyle A\otimes B_{1}\otimes B_{2}\otimes \ldots \otimes B_{8}\otimes B_{1}\otimes B_{2}\otimes \ldots }$.