Generalizations of Fermat's little theorem in rings with a multiplicative identity

Anthony Narkawicz

Fermat's Little Theorem states that if p is a prime number that does not divide a, then a(p-1) = a mod p. Similar theorems include Euler's Theorem, which states that if a and m are relatively prime, then am = 1 mod m. These theorems are especially applicable in basic coding methods such as RSA encryption. As a source of motivation, this paper aims in part to answer the following question (a generalization of FLT): What are necessary and sufficient conditions on Q and m so that aQ = a mod m for every integer a? This question is easily answered, but more generally, we are able to answer the following question. Let R be any ring with a 1, let Q be an integer at least 2, and let I be an ideal of R. What are necessary and sufficient conditions on Q and I so that aQ = a mod I for every a in R? The result is that aQ = a mod I for every a in R if and only if I is the intersection of all maximal ideals containing I, and for any such maximal ideal M, we have that R/M is a field and |R/M|-1 divides Q-1.