Post a reply
Username:
Note:If not registered, provide any username. For more comfort, register here.
Subject:
Message body:
Enter your message here, it may contain no more than 60000 characters. 

Smilies
:D :) :( :o :shock: :? 8) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :wink: :!: :?: :idea: :arrow: :| :mrgreen:
Font size:
Font colour
#000000 #000040 #000080 #0000BF #0000FF
#004000 #004040 #004080 #0040BF #0040FF
#008000 #008040 #008080 #0080BF #0080FF
#00BF00 #00BF40 #00BF80 #00BFBF #00BFFF
#00FF00 #00FF40 #00FF80 #00FFBF #00FFFF
#400000 #400040 #400080 #4000BF #4000FF
#404000 #404040 #404080 #4040BF #4040FF
#408000 #408040 #408080 #4080BF #4080FF
#40BF00 #40BF40 #40BF80 #40BFBF #40BFFF
#40FF00 #40FF40 #40FF80 #40FFBF #40FFFF
#800000 #800040 #800080 #8000BF #8000FF
#804000 #804040 #804080 #8040BF #8040FF
#808000 #808040 #808080 #8080BF #8080FF
#80BF00 #80BF40 #80BF80 #80BFBF #80BFFF
#80FF00 #80FF40 #80FF80 #80FFBF #80FFFF
#BF0000 #BF0040 #BF0080 #BF00BF #BF00FF
#BF4000 #BF4040 #BF4080 #BF40BF #BF40FF
#BF8000 #BF8040 #BF8080 #BF80BF #BF80FF
#BFBF00 #BFBF40 #BFBF80 #BFBFBF #BFBFFF
#BFFF00 #BFFF40 #BFFF80 #BFFFBF #BFFFFF
#FF0000 #FF0040 #FF0080 #FF00BF #FF00FF
#FF4000 #FF4040 #FF4080 #FF40BF #FF40FF
#FF8000 #FF8040 #FF8080 #FF80BF #FF80FF
#FFBF00 #FFBF40 #FFBF80 #FFBFBF #FFBFFF
#FFFF00 #FFFF40 #FFFF80 #FFFFBF #FFFFFF
Options:
BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON
Disable BBCode
Disable smilies
Do not automatically parse URLs
Confirmation of post
To prevent automated posts the board requires you to enter a confirmation code. The code is displayed in the image you should see below. If you are visually impaired or cannot otherwise read this code please contact the %sBoard Administrator%s.
Confirmation code:
Enter the code exactly as it appears. All letters are case insensitive, there is no zero.
   

Topic review - Polynomial division over GF(p^n)
Author Message
  Post subject:  Re: Polynomial division over GF(p^n)  Reply with quote
Thank you for your answer, this definitely solves my problem :)

But is this kind of pitfall anywhere documented? I tried to find something, but using google to find problems with Singular is kind of hard.
Post Posted: Fri Jul 07, 2017 3:59 pm
  Post subject:  Re: Polynomial division over GF(p^n)  Reply with quote
Without going into detail, this is due to the fact that the polynomials have another presentation
over Galoisfields and different algorithms / implementations are involved. Also factorize is not at
your disposal.

Note that in general f/g only gives the quotient without remainder. Most likely that is not what
you want, but you are not lost here.
There is the command division
http://www.singular.uni-kl.de/Manual/latest/sing_226.htm#SEC266
which performs the task. It is important to use a global odering dp as you do.
Code:
factorize(f);
   ? not implemented
   ? error occurred in or before STDIN line 6: `factorize(f);`

> list L = division(f,g);
> L;
[1]:
   _[1,1]=x-1
[2]:
   _[1]=a16
[3]:
   _[1,1]=1
> typeof(L[1]);
matrix
> typeof(L[1][1,1]);
poly
> typeof(L[2]);
ideal
> f==g*L[1][1,1] + L[2][1];
1

> (x-1)*(x+1) + 2;
x2+1

> a16;
a16
> number(2);
a16

(The third value L[3] is a unit matrix in global ordering, but the result is different
if you would work in ring rads = (49a,),x,ds;Try it!)

You may also define this finite field as an quadratic extension of Z_7 by the
minimal polynomial displayed from the ring itself.
Code:
> setring r;
> basering;
// coefficients: ZZ/49[a]
//   minpoly        : 1*a^2+6*a^1+3*a^0
// number of vars : 1
//        block   1 : ordering dp
//                  : names    x
//        block   2 : ordering C

With this approach, the elements are not represented as a power of the primitive
element a, but now f/g and factorize work.
Code:
> ring ra49 = (7,a),x,dp; minpoly = a2+6a+3;
// compare with above
> a16;
2
> number(2);
2
> poly f = x2+1;
> poly g = x+1;
> f/g;
x-1
> factorize (f);
[1]:
   _[1]=1
   _[2]=x+(-a-3)
   _[3]=x+(a+3)
[2]:
   1,1,1
> division(f,g);
[1]:
   _[1,1]=x-1
[2]:
   _[1]=2
[3]:
   _[1,1]=1
> f == (x-1)*g +2;
1
Post Posted: Fri Jul 07, 2017 3:40 pm
  Post subject:  Polynomial division over GF(p^n)  Reply with quote
Why is it not possible to divide polynomials over GF(p^n), if n >= 2? I get the following error:
Code:
> ring r = (7^2,a),x,dp;
> poly f = x2+1;
> poly g = x+1;
> f/g;
   ? not implemented
   ? error occurred in or before STDIN line 14: `f/g;`


Any help would be appreciated.
Post Posted: Thu Jul 06, 2017 11:43 am


It is currently Fri May 13, 2022 10:58 am
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group