MathLabs

Problem 4

Determine all pairs (n,p)(n,p) of positive integers such that p p is a prime, n n not exceeded 2p2p , and (p−1)n+1(p-1)^n+1 is divisible by np−1 n^{p-1}.
Step 2 of 5: Identify the smallest prime divisor
In plain words

The least-prime-divisor argument forces the same prime.

q=pq=p
Detailed analysis

Let q q be the smallest prime divisor of n n . Using (p−1)n≡−1(modq)(p-1)^n\equiv-1\pmod q and the least positive exponents giving residues −1-1 and 11, a Euclidean-division argument shows that the exponent n n is a multiple of the least −1-1 exponent, which must be 11. Thus p−1≡−1(modq) p-1\equiv-1\pmod q , and since p,q p,q are prime, q=p q=p .