Number of solutions in equation $x^2 \equiv a \mod(pq)$

206 Views Asked by At

How many solutions has equation $x^2 \equiv a \mod(n)$, if $ n =pq$ and $p, q$ - odd primes, $a \in \mathbb{Z}_n$. I know that it has something to do with $\gcd(a, n)$, but it doesn't really help. Any suggestions are welcome.

1

There are 1 best solutions below

0
On

The number of solutions is equal to the number of solutions mod $p$ times the number of solutions mod $q$, by Chinese Remainder Theorem. Either of these last two congruences could have $0, 1,$ or $2$ solutions. So possibilities for your answer are $0, 1, 2,$ or $4$.