
 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 2 of degree 2

x ^ 2 + x + 1, 2


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 2 of degree 17

x ^ 17 + x ^ 3 + 1, 2


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 2 of degree 43

x ^ 43 + x ^ 6 + x ^ 4 + x ^ 3 + 1, 2


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 2 of degree 62

x ^ 62 + x ^ 6 + x ^ 5 + x ^ 3 + 1, 2


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 3 of degree 30

x ^ 30 + x + 2, 3


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 5 of degree 22

x ^ 22 + x ^ 2 + x + 3, 5


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 7 of degree 16

x ^ 16 + 2 x + 3, 7


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 17 of degree 14

x ^ 14 + x ^ 2 + 2 x + 6, 17


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 137 of degree 7

x ^ 7 + x + 3, 137


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 223 of degree 8

x ^ 8 + x + 51, 223


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 557 of degree 6

x ^ 6 + x + 5, 557


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 2 of degree 4

x ^ 4 + x + 1, 2

Confirming polynomial is primitive with a brute force check.
WARNING:  You may wait an impossibly long time!
To abort, hit control-C in your console window to stop this program.
x ^ 4 + x + 1, 2 confirmed primitive!
+--------- OperationCount --------------------------------
|
| Integer factorization:  Table lookup + Trial division + Pollard Rho
|
| Number of trial divisions :           0
| Number of gcd's computed :            0
| Number of primality tests :           0
| Number of squarings:                  0
|
| Polynomial Testing
|
| Total num. degree 4 poly mod 2 :      16
| Number of possible primitive poly:    2
| Polynomials tested :                  4
| Const. coeff. was primitive root :    2
| Free of linear factors :              1
| Irreducible to power >=1 :            1
| Had order r (x^r = integer) :         1
| Passed const. coeff. test :           1
| Had order m (x^m != integer) :        1
|
+-----------------------------------------------------


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


Primitive polynomial modulo 3 of degree 5

x ^ 5 + 2 x + 1, 3

Confirming polynomial is primitive with a brute force check.
WARNING:  You may wait an impossibly long time!
To abort, hit control-C in your console window to stop this program.
x ^ 5 + 2 x + 1, 3 confirmed primitive!
+--------- OperationCount --------------------------------
|
| Integer factorization:  Table lookup + Trial division + Pollard Rho
|
| Number of trial divisions :           0
| Number of gcd's computed :            0
| Number of primality tests :           0
| Number of squarings:                  0
|
| Polynomial Testing
|
| Total num. degree 5 poly mod 3 :      243
| Number of possible primitive poly:    22
| Polynomials tested :                  8
| Const. coeff. was primitive root :    3
| Free of linear factors :              1
| Irreducible to power >=1 :            1
| Had order r (x^r = integer) :         1
| Passed const. coeff. test :           1
| Had order m (x^m != integer) :        1
|
+-----------------------------------------------------


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...


There are 6 primitive polynomials modulo 2 of degree 5



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 2 + 1, 2



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 3 + 1, 2



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 3 + x ^ 2 + x + 1, 2



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 4 + x ^ 2 + x + 1, 2



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 4 + x ^ 3 + x + 1, 2



Primitive polynomial modulo 2 of degree 5

x ^ 5 + x ^ 4 + x ^ 3 + x ^ 2 + 1, 2


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Error.  Polynomial has bad syntax or coefficients are out of range.  [ Error in parser converting polynomial from string x 1 for p = 2 Expecting to see x^ or x or x ^ integer in sentence x 1 ] 
This program generates primitive polynomials of degree n modulo p.

Usage:  Generate a single random polynomial of degree n modulo p where p is a prime >= 2 and n is an integer >= 2
        Primpoly p n
Example:
        Primpoly 2 4
          Self-check passes...
          Primitive polynomial modulo 2 of degree 4
          x ^ 4 + x + 1, 2
Usage:  Test whether a polynomial is primitive modulo p.
        Primpoly -t <Polynomial to test>, p
          If you leave off the modulus p we default to p = 2
Examples:
        Primpoly -t x^4 + x + 1, 2
          Self-check passes...
          x ^ 4 + x + 1, 2 is primitive!

        Primpoly -t x^4 + x + 1
          Self-check passes...
          x ^ 4 + x + 1, 2 is primitive!
Usage:  Generate all primitive polynomial of degree n modulo p.
        Primpoly -a p n
Example:
        Primpoly -a 2 4
          Self-check passes...
          Primitive polynomial modulo 2 of degree 4
          x ^ 4 + x + 1, 2
          Primitive polynomial modulo 2 of degree 4
          x ^ 4 + x ^ 3 + 1, 2
Usage:  Same but show computation statistics.
        Primpoly -s p n
Examples:  

        Primpoly.exe -s 13 19
          Self-check passes...
          Primitive polynomial modulo 13 of degree 19
          x ^ 19 + 9 x + 2, 13

          +--------- OperationCount --------------------------------
          |
          | Integer factorization:  Table lookup + Trial division + Pollard Rho
          |
          | Number of trial divisions :           0
          | Number of gcd's computed :            9027
          | Number of primality tests :           2
          | Number of squarings:                  9026
          |
          | Polynomial Testing
          |
          | Total num. degree 19 poly mod 13 :      1461920290375446110677
          | Number of possible primitive poly:    6411930599771980992
          | Polynomials tested :                  120
          | Const. coeff. was primitive root :    46
          | Free of linear factors :              11
          | Irreducible to power >=1 :            1
          | Had order r (x^r = integer) :         1
          | Passed const. coeff. test :           1
          | Had order m (x^m != integer) :        1
          |
          +-----------------------------------------------------
Usage:  Print help message.
        Primpoly -h
          <Prints this help message.>


Primitive polynomials find many uses in mathematics and communications
engineering:
   * Generation of pseudonoise (PN) sequences for spread spectrum
     communications and chip fault testing.
   * Generating Sobol sequences for high dimensional numerical integration.
   * Generation of CRC and Hamming codes.
   * Generation of Galois (finite) fields for use in decoding Reed-Solomon
     and BCH error correcting codes.

For detailed technical information, see my web page
    http://seanerikoconnor.freeservers.com/Mathematics/AbstractAlgebra/PrimitivePolynomials/overview.html


 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...
x ^ 4 + x + 1, 2 is  primitive!

 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...
x ^ 3 + x + 2, 3 is NOT primitive!

 - A Program for Computing Primitive Polynomials.

Primpoly comes with ABSOLUTELY NO WARRANTY; for details see the
GNU General Public License.  This is free software, and you are welcome
to redistribute it under certain conditions; see the GNU General Public License
for details.

Self-check passes...
x ^ 2 + x + 10, 32749 is  primitive!
