0

When $n = p^k$, where p is prime and k is a positive integer
if $x^2 ≡ x$ (mod $p^k$), then $p^k$ divides $x^2-x = x(x-1)$, since $x$ and $x-1$ are coprime, $p^k$ divides either $x$ or $x-1$, so $x ≡ 0$ (mod $p^k$) or $x ≡ 1$ (mod $p^k$).

When n is not in the form of $p^k$,
on checking of counterexamples, $4^2 ≡ 4$ (mod $6$), where $4$ is not congruent to $0,1$ modulo $6$ and $6$ is a product of distinct primes.
Please suggest the general approach to prove that there exists solution other than $x ≡ 0,1$ (mod $n$) for this case.

Bill Dubuque
  • 272,048

1 Answers1

0

If the modulus is of the form $pq$ for $p, q$ coprime, use the Chinese Remainder theorem to solve $x \equiv 0 \pmod p, x \equiv 1 \pmod q$ or the other way around. Note that also $3^2 \equiv 3 \pmod 6$ which is the other way around from $4$.

Ross Millikan
  • 374,822