Source: https://www-l2ti.univ-paris13.fr/~dauphin/tp_tin_v2.pdf