Source: https://gilles-hunault.leria-info.univ-angers.fr/wstat/Mef/mazerolle-khi-carre.pdf