[sage-devel] Re: multiplicative_order in finite fields

2009-08-01 Thread John Cremona
The function generic order_from_multple() does allow the information to be cached, and the function Victor referred to should use that. John 2009/7/31 VictorMiller : > > Simon, Thanks.  I think that in order for this to work, that finite > field should have a new method, something like > > @cach

[sage-devel] Re: multiplicative_order in finite fields

2009-07-31 Thread VictorMiller
Simon, Thanks. I think that in order for this to work, that finite field should have a new method, something like @cached_method _cofactor_information(self): N = self.order() return [ (N//p**r,p) for p,r in arith.factor(N)] which would factor the order, and then return all the cofactors a

[sage-devel] Re: multiplicative_order in finite fields

2009-07-31 Thread Simon King
Hi Victor, On Jul 31, 3:59 pm, VictorMiller wrote: > I was just looking at the code for multiplicative_order in > finite_field_element.py, and noticed that it factors the group order, > and find the "cofactors" corresponding to each prime power dividing > the order (which is really the only algo