Source: https://megarban.perso.math.cnrs.fr/MPSI220212022/TD/Exo_12_calculs_matriciels.pdf