Source: http://dpnc.unige.ch/~sfyrla/teaching/PGC_Automne2018/notes_PGC_web/PGC_full_2018.pdf