How do you factor over a Z field?

131 views Asked by At

I have to factorize a polynomial e.g. enter image description here

over the field of Z5 using Matlab or Mupad. And i tried everything read a lot of Matlab and Mupad documentation and still can't find it, so i am guessing it is the math i don't know that's going to help me factor it.

2

There are 2 answers

0
D.Tomov On BEST ANSWER

I found a mupad command to do what i needed. Mupad command to factorize over a field

Still thanks for exaplaining the math behind it.

0
Leandro Caniglia On

Don't kill a mosquito with a cannon!

You only need to find a root between 0, 1, 2, -2, -1.

Also, given that x5 = x, the problem reduces to finding x such that

 2x + 2x^4 + x^3 + 2x^2 - 3 = 0

and since x ≠ 0, x^4 = 1 hence

 2x + x^3 + 2x^2 - 1 = 0

Well, let's try!

 1:  2 + 1 + 2 - 1 -> -1
 2: -1 + 3 - 2 - 1 -> -1
-2:  1 - 3 + 3 - 1 ->  0 -> root!

Then the polynomial is divisible by (x - 3), and you can repeat the procedure with the quotient until there are no roots left.

Addendum

After dividing by (x - 3) we get

x4 + x2 + 1

which we can expressed as

(x2 + 1)2 - x2

or

((x2 + 1) - x)((x2 + 1) + x)

To find the factors of degree 2 programmatically, just try with x2 + ax + b for a and b between 0 and 4.