Source: http://www.discmath.ulg.ac.be/cours/Graphes20-21.pdf