Figure 1: A filtration of a triangle (a). We start with three connected components. The yellow and the green components die in step two and three, but the red component persists the whole filtration. In the fourth step a loop is born, which dies in the final step of the filtration. The zeroth Betti number equals the number of connected components. The first Betti number equals the number of loops (b). We use a barcode to visualise the birth and death of the Betti numbers (c). 
