Factor $x^p-y^p$

552 Views Asked by At

I would like to factor the polynomial $p(x,y)=x^p-y^p$ for some small prime $p$ $(p=3,5,\text{or } 7)$ and for all values of $p(x,y)$ with $1 < x < 1000$ and $1 < y < x$.

There is a similar post, but the answers just indicate that you can factor out $(x-y)$. I am aware of this, but I still cannot find a fast way to factor to rest of the polynomial efficiently. In a previous post I learnt quick ways to factor the polynomial $(x-y)$ using a sieve and I am hoping that there is a similar and efficient way to factor this polynomial.

1

There are 1 best solutions below

0
On BEST ANSWER

Apply $$x=(x-y)+y$$ and expand the binomial and cancel and you get :$$(x-y)((x-y)^{p-1}+p(x-y)^{p-2}y+\cdots+py^{p-1})$$ The factorization is conditional. It has the gcd of $x-y$ and $y$ raised to $p-1$ as a factor if p is in their gcd, that means $p$ can be raised to at least the $p$ power.