Find all integers $n>1$ such that every prime that divides $n^6-1$ also divides $n^5-n^3-n^2+1$.
Problem
Source: Mathematics Regional Olympiad of Mexico Southeast 2015 P1
Tags: number theory, prime
27.10.2021 03:22
$n^6-1 =0 (mod \ p )$ $n^6 = 1 ( mod \ p)$ by Fermat little theorem for gcd(n,p) = 1 $6 = p-1$ $p = 7$ $n^6 = 1 ( mod \ 7)$ $(n^3-1) (n^3+1)= 0 ( mod \ 7)$ $(n-1)(n^2+n+1)(n+1)(n^2-n+1)= 0 mod( \ 7)$ $n^5-n^3-n^2+1= 0 mod(7)$ $(n-1)^2(n+1)(n^2+n+1) = 0 mod(7)$ hence the general solution for n are n = 7k+1 n = 7k+6 n = 7k+2 n = 7k+4
27.10.2021 04:31
@above, that's incorrect -- just because $n^6 \equiv 1\pmod{p}$ and $n^{p-1}\equiv 1\pmod{p}$ doesn't mean that $6 = p-1$ (just take $12 = p-1$ for a counterexample). Anyways, here's my solution. Note that $0^2 - 0 + 1 \equiv 1\pmod{2}$ and $1^2 - 1 + 1\equiv 1\pmod{2}$, and so $2\nmid n^2 - n + 1$ for each integer $n$. Thus, any prime divisor $p$ of $n^2 - n + 1$ is odd. Now, let $p$ be one of the such prime divisors. Assume for the sake of contradiction that $p \neq 3$. Then, we have that $$p \mid n^2 - n + 1 \mid n^6 - 1 = (n^2 - n+1)(n+1)(n^3-1),$$but $$p \nmid n^5 - n^3 - n^2 + 1 = (n^3 - 1)(n^2 - 1),$$as we have that $$n^3 - 1 \equiv n(n^2) - 1\equiv n(n-1) - 1 \equiv (n^2 - n+1) - 2 \equiv -2 \not \equiv 0\pmod{p},$$as we showed that $p\neq 2$, and $$n^2 - 1 \equiv (n-1) - 1 \equiv n - 2\not \equiv 0\pmod{p},$$as $n \equiv 2\pmod{p}$ would imply that $$0\equiv n^2 - n + 1 \equiv 2^2 - 2 + 1 \equiv 3\pmod{p},$$a contradiction (as $p\neq 3$).
It remains to show that $n = 2$ works. And in fact, we have that $$\mathrm{rad}(2^6 - 1) = \mathrm{rad}(63) = \mathrm{rad}(3^2 \cdot 7) = 3\cdot 7 = 21$$is a divisor of $$\mathrm{rad}(2^5 - 2^3 - 2^2 + 1) = \mathrm{rad}((2^2-1)(2^3-1)) = \mathrm{rad}(3\cdot 7) = 21.$$