My mistake... x^16+x+1 is in fact reducible...

On Feb 17, 5:11 pm, Eli Oxman <[email protected]> wrote:
> Hello all !
>
> I've just started using Crypto++ and wanted to check some things
> related to operations over GF(2^n) fields.
> Just checking out the functions it seems that the IsIrreducible
> function's algorithm is incorrect.
>
> For example for the polynomial x^16+x+1 (which is irreducible) it
> returns false.
>
> You can test it with the following code:
>
> #include <gf2n.h>
>
> using namespace CryptoPP;
>
> int main(int argc, char *argv[])
> {
>         PolynomialMod2* irredPoly = new PolynomialMod2();
>         irredPoly->SetCoefficient(16,1);
>         irredPoly->SetCoefficient(1,1);
>         irredPoly->SetCoefficient(0,1);
>         bool irred = irredPoly->IsIrreducible();
>
> }
>
> Am I doing something wrong, or understanding it wrong?
>
> Thanks,
> Eli

-- 
You received this message because you are subscribed to the "Crypto++ Users" 
Google Group.
To unsubscribe, send an email to [email protected].
More information about Crypto++ and this group is available at 
http://www.cryptopp.com.

Reply via email to