# Thread: Prime number problem

1. ## Prime number problem

Hi

I need direction with the following problem.

p<>2 is a prime number, suppose the equation x^2=-1(modp) has a solution.
Show that p=1(mod4).

SK

2. You could use complex numbers to prove this.

First note that if $\displaystyle p\equiv 3\pmod{4}$, then $\displaystyle p\in \mathbb{Z}[i]$ is prime. Now it will suffice to show that if $\displaystyle x^2\equiv -1\pmod{p}$ has a solution, then $\displaystyle p\in \mathbb{Z}[i]$ is not prime. (This will force $\displaystyle p\equiv 1\pmod{4}$.

If the equation is satisfied, then there exists an integer $\displaystyle m$ such that $\displaystyle pm=x^2+1$. We can factor the right hand side to receive $\displaystyle pm=(x+i)(x-i)$. If $\displaystyle p$ were prime, then $\displaystyle p|(x+i)$ or $\displaystyle p|(x-i)$, but this would mean that $\displaystyle (1/p)x+(1/p)i\in \mathbb{Z}[i]$, which is absurd. Therefore, $\displaystyle p$ is not prime.

3. For this class I need to show this without complex numbers. We could use Fermat's litlle theoreme though but I can't see how

4. This can also be done using the Euler criterion. Do you have it?

5. can't use it yet

6. Originally Posted by skyking
Hi

I need direction with the following problem.

p<>2 is a prime number, suppose the equation x^2=-1(modp) has a solution.
Show that p=1(mod4).

SK
Let $\displaystyle a$ be a solution of $\displaystyle x^2+1\equiv0(\text{mod}p)$. Therefor $\displaystyle p\nmid a$, from Fermat's theorem:

$\displaystyle 1\equiv a^{p-1}\equiv(a^2)^{\frac{p-1}{2}}\equiv(-1)^{\frac{p-1}{2}}(\text{mod}p)$

There is impossible that $\displaystyle p=4k+3$, because if $\displaystyle p=4k+3$ then:
$\displaystyle (-1)^{\frac{p-1}{2}}=(-1)^{2k+1}=-1$, and therefore $\displaystyle 1\equiv -1(\text{mod}p)$, and the conclusion has $\displaystyle p|2$, which is not true. Hence $\displaystyle p$ is from the form of $\displaystyle p=4k+1$.

The end!

By the way...

It also true that:

Let $\displaystyle p>2$ is a prime number, the equation $\displaystyle x^2 \equiv -1(modp)$ has a solution if and only if $\displaystyle p=4k+1$

7. In math subject there are many problems occur in numeric theory....This forum is very helpful for students because it solve the problems of math students...Thanks a lot for this help..

http://fruition.com.au/