Home/Algebra/Modular arithmetic/Fermat's little theorem26. Modular arithmeticFermat's little theoremLevel: avanzadoIn 26. Modular arithmeticFormulaCopy LaTeXap−1≡1(modp)(p∤a)a^{p-1}\equiv1\pmod p\quad(p\nmid a)ap−1≡1(modp)(p∤a)Tagsalgebraarithmetic modularCSalgebra formulamodularDetailCentral result for modular arithmetic and cryptography.Explore the ideaFound an error? Contact us.Related formulasRelatedModular inverseaa−1≡1(modn) ⟺ gcd(a,n)=1aa^{-1}\equiv1\pmod n\iff\gcd(a,n)=1aa−1≡1(modn)⟺gcd(a,n)=1Open formulaOpen in sectionRelatedPrime finite fieldFp=Z/pZ(p primo)\mathbb F_p=\mathbb Z/p\mathbb Z\quad(p\text{ primo})Fp=Z/pZ(p primo)Open formulaOpen in section