# alternate function/algorithm for MOD operation

.

```
p =37
print"\n p=",p
F=GF(p)
S.<a> = PolynomialRing( F )
K.<a> = GF( p**2);#K.modulus#, modulus=W^2+W+1 )
print "\n Modulus of K is =", K.modulus()
R.<z> = PolynomialRing( K, sparse=True )
fE=(4*a + 5)*z^111 + (5*a + 32)*z^75 + 14*z^74 + (32*a + 15)*z^39 + 9*z^38 + (15*a + 22)*z^37 + (33*a + 21)*z^3 + 14*z^2 + (22*a + 8)*z + 12
fL=(5*a + 8)*z^37 + (32*a + 28)*z + 20
F1=(fE % fL).monic()
```

the time required for the computation of F1 is very large so please suggest me any other alternative for above computation. The gcd function is also required large amount of time for computation . so please suggest me other altrnative or algorithm for computation of one variable polynomial.

enter code here

I do not see any problem, how slow is your computation (please provide a timing) ?

the time required for above compution is 1.96ms and i want 0.19 ms.