Fermat's Little Theorem: Proving p-1! ≡ -1 (mod p)

  • Thread starter Thread starter moonlight310
  • Start date Start date
  • Tags Tags
    Theorem
Join the discussion
Ask a follow-up here, or get your own question answered by working scientists, mathematicians and engineers — people, not an autocomplete.
Real named experts · corrections over time · the nuance an AI answer skips
3 replies · 1K views
moonlight310
Messages
2
Reaction score
0

Homework Statement



let p be prime then, (p-1)! is congruent to -1 mod p

Homework Equations





The Attempt at a Solution



I'm not sure where to start
 
on Phys.org
First of all you should try some examples out for small prime.

Since p is prime, the set {1, 2, ... p-1} is a group under multiplication, modulo p. This means that there is a (unique) inverse for each element.
 
I've tried small numbers and it works. So since it has an inverse it means that it can be mod p ? I'm sorry I don't understand this stuff very well.
 
The fact there there is an inverse means that for each element x, there is an element y such that xy = 1 mod p - and this is only true because p is a prime (a well known group theory result). The main idea for the proof of this theorem is to try to pair up each element with it's inverse (which is valid since this group is commutative).