Ask Your Question

inertialFrost's profile - activity

2014-06-29 20:38:59 +0200 received badge  Famous Question (source)
2013-05-01 20:59:13 +0200 received badge  Notable Question (source)
2012-12-12 05:29:05 +0200 received badge  Popular Question (source)
2012-02-28 11:47:08 +0200 asked a question inverse of a polynomial modulo another polynomial

Hi, I'm trying to implement the Baby Step Giant Step algorithm in the group of units of prime fields. I would like to generate the field provided one generator polynomial. But I need to calculate p^(-1) (where p is a polynomial), but can't find a function to do so. This is what I'm doing,

F.<a> = GF(2)[];
R.<b> = PolynomialRing(F)
S.<x> = R.quotient(b^4+b+1)

m = sqrt(S.modulus().degree()); 
gamma = S.modulus();
alpha = x^3+1;

now i need to calculate (alpha)^(-1) modulo gamma

Any help? Better ways to do the same thing?

Thanks!