Source: http://www.normalesup.org/~carpenti/Cours/PSY-L3-TDinfo-2-2003.pdf