Solution

ID: past-exam-of-the-mathematics-course-of-the-university-of-cambridge/2006/ii/paper-4/11h/a/solution

If is prime, Fermat's little theorem gives . If , the strong test already passes. Otherwise let be the first index with . Its preceding value satisfies and in the field . Since in a field, . The index lies between zero and , so every coprime base passes the strong test when is prime.

New to topics? Read the docs here!