How to use prove this $p^4\equiv p\pmod {13}$ let prime number $p$,and $n$ postive integer, such $$p|n^4+n^3+2n^2-4n+3$$
show that
$$p^4\equiv p\pmod {13}$$

A friend of mine suggested that I might be able to use the results problem
I highly respect  subtle mathematics  but here, at MSE, I give priority to the elementary.  I think mainly of beginners who, for obvious reasons, do not understand anything if the reasoning is of medium high level.

We have to prove that the polynomial $f(x)=x^4+x^3+2x^2-4x+3$ (which, say it, is always divisible by the prime $3$ because
$f(n)=n(n-1)(n+1)^2+3(n^2-n+1)$)  is such that putting $$f(n)=\prod_{i=1}^{i=r}p_i^{\alpha_i}$$  where $n$ is an arbitrary natural,  it is verified  for all $p_i$  the congruence
$$p_i^4\equiv p_i\pmod{13}$$ so it is clear that the primes $p_i$ belong to a certain class excluding a lot of other primes. 

We can write $$4f(n)=(2n^2+n+5)^2-13(n+1)^2$$  from which $$4f(n)\equiv(2n^2+n+5)^2\pmod{13}$$
A straightforward calculation gives for $g(x)=(2x^2+x+5)^2$
$$g(\mathbb F_{13})=\{0,4,10,12\}$$ so we have (adding details) in $\mathbb F_{13}$  (where $0=13k;1=13k+1$, etc)
$$\begin{cases}4f(n)=0 \hspace{10mm}\text {for }  n=0\space  \text {and 3}\\4f(n)=4\hspace{10mm}\text {for }  n=2,4,8,11\\4f(n)=10\hspace{8mm}\text {for }  n=7,9,10,12\\4f(n)=12\hspace{8mm}\text {for }  n=1,5,6\end{cases}$$ 
On the other hand the inverse of $4$ modulo $13$ is $10$ so we have

$$\begin{cases}f(n)= 0\hspace{10mm}\text {for }  n=0\space  \text {and 3} 
\\f(n)=1\hspace{10mm}\text {for }  n=2,4,8,11\\f(n)=9\hspace{10mm}\text {for }  n=7,9,10,12\\f(n)=3\hspace{10mm}\text {for }  n=1,5,6\end{cases}$$
Now the primes $p_i$ above can be only $13$ and those of the form $13k+1,13k+9$ and $13k+3$. 

This property can be easily verified because if $p^4\equiv p\pmod{13}\iff p(p^3-1)=13$k then $p^3-1$ is divisible by $13$ when   $p\ne13$. In fact
$$1^3-1=0=13\cdot0\\\hspace{5mm}9^3-1=728=13\cdot56\\3^3-1=26=13\cdot2$$
But none of the nine integers below are divisible by $13$
$$2^3-1\\4^3-1\\5^3-1\\6^3-1\\7^3-1\\8^3-1\\10^3-1\\11^3-1\\12^3-1$$
We will have modulo $13$ all the time. Notice that $$N:= n^4+n^3+2n^2-4n+3 \equiv (n^2-6n-4)^2 \equiv (n-3)^4$$

Clearly $13\mid N\iff 13\mid n-3$, so we assume $p\ne 13$ and thus $13$ does not divide $n-3$. Say prime divisor $p$ of $N$ is good if $p^4{\equiv}p$. 

Suppose the statment is not true, so there exists a prime $q$ which is not good. 

Also we can assume that there is no good prime divisor of $N$: if $p\ne 13$ is good than we can divide $N$ by $p\equiv p^4$ modulo $13$ and then observe $N' = N/p^4$ modulo $13$.  Also we can reduce $N$ with all divisors of $N$ of form $d^4$. So if we make now a prime factorisation for $N$ modulo $13$ we have $$N\equiv  2^a4^b5^c6^d7^e8^f10^g11^h12^i$$
(clearly there is no $0,1,3$ and $9$) where all the exponents are nonnegative and less than $4$ and at least one is positive. Of course, we can reduce this even more:
$$N\equiv  2^{a+2b+d+3f+g+2i} 3^{d+i} 5^{c+g}7^e11^h$$
or $$N\equiv  2^x 3^y 5^z(-6)^e(-2)^h$$
where or exponents are nonegative and less than $4.$ Again we can assume if $y=0$ (else we divide $N$ by $3$ modulo $13$). So we can write:$$ N\equiv  (-1)^{3z+e+h} 2^{x+3z+e+h} = (-1)^t2^{x+t}$$
where $t= 3z+e+h$. So $$N\equiv   -1\pm2,\pm4,\pm8$$
Now this can not be of the form $(...)^4$ and we have a contradiction.