Source: https://mms2.mines-paristech.fr/mat_paris/structure/exercices/TD_Cristallo_2008.pdf