TITLE: For every prime of the form $2^{4n}+1$, 7 is a primitive root.
QUESTION [5 upvotes]: What I want to show is the following statement.
For every prime of the form $2^{4n}+1$, 7 is a primitive root.
What I get is that
$$7^{2^{k}}\equiv1\pmod{p}$$
$$7^{2^{k-1}}\equiv-1\equiv2^{4n}\pmod{p}$$
$$7^{2^{k-2}}\equiv(2^{n})^2\pmod{p}$$
Thus $(\frac{2^n}{p})=(\frac{7^{2^{k-2}}}{p})=1$.
I think that $7$ is important because $7$ is a primitive root but I don't know how to use $7$.

REPLY [2 votes]: Case $n=0$ is trivial and satisfies our assumption.
So consider all possible outcomes when the natural number $n = 3k + t$ for some $k \in \mathbb{Z}$ and $t \in \{\, 0,1,2 \,\}$:
\begin{align*}
& p = 2^{4\cdot 3k} + 1 = 2^{12k}+1 = (2^{4k} + 1)(2^{8k} - 2^{4k} + 1) \not\in \mathbb{P} \quad (\text{prime}); \\
& p = 2^{4\cdot (3k+1)} + 1 = 8^{4k} \cdot 16^1  + 1 \equiv 1^{4k} \cdot 2^1 + 1 = 3 \mod{7}; \\
& p = 2^{4\cdot (3k+2)} + 1 = 8^{4k} \cdot 16^2  + 1 \equiv 1^{4k} \cdot 2^2 + 1 = 5 \mod{7}.
\end{align*}
If $p \equiv 3 \mod{7}$ then we have $(p/7) = (3/7) = -(7/3) = -(1/3) = -1$.
If $p \equiv 5 \mod{7}$ then we have $(p/7) = (5/7) = (7/5) = (2/5) = -1$.
Since obviously $p \equiv 1 \mod{4}$, quadratic reciprocity law gives $(7/p) = (p/7)$ and
\begin{equation*}
-1 = (p/7) = (7/p) \equiv 7^{\frac{p-1}{2}} = 7^{2^{4n-1}} 
\mod{p}.
\end{equation*}
This means that $\operatorname{ord}_p(7) \nmid 2^{4n-1}$ while at the same time $\operatorname{ord}_p(7) \mid \varphi(p) = 2^{4n}$.
Then the only possibility is that $\operatorname{ord}_p(7) = \varphi(p)$ and $7$ is a primitive root modulo $p$ by definition.