Source: http://math.univ-lyon1.fr/~gelineau/devagreg/Theoreme_2_carres.pdf