[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread William Stein
On Jan 23, 2008 4:08 PM, Jonathan Bober <[EMAIL PROTECTED]> wrote: > > I just realized a source of my confusion. The docstring that I quoted > was not actually wrong in the way that I thought is was, but was > apparently deceptive (to me). Perhaps some people are already aware of > this, but GF(5)

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread Jonathan Bober
I just realized a source of my confusion. The docstring that I quoted was not actually wrong in the way that I thought is was, but was apparently deceptive (to me). Perhaps some people are already aware of this, but GF(5), GF(25), and GF(5^100) are all different types, and so have different docstr

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread David Kohel
Hi All, Just a few comments: there are three possible concepts for generator[s]: 1) As a field over its prime field or base field (function gen(), category Field or Algebra); 2) As a vector space over its base field (function additive_generators(), category Module) 3) As a group, restricted to t

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread Martin Albrecht
Sorry, I was confused. You and William are right. Martin -- name: Martin Albrecht _pgp: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x8EF0DC99 _www: http://www.informatik.uni-bremen.de/~malb _jab: [EMAIL PROTECTED] --~--~-~--~~~---~--~~ To post to this g

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread William Stein
On Jan 23, 2008 4:06 AM, Martin Albrecht <[EMAIL PROTECTED]> wrote: > > > > By contrast F.multiplicative_gen() does make sense for all finite > > > fields so should be provided, though not necessarily computed until > > > requested for the reasons given by Martin. (It seems that with the > > > cu

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread John Cremona
On 23/01/2008, Martin Albrecht <[EMAIL PROTECTED]> wrote: > > > > By contrast F.multiplicative_gen() does make sense for all finite > > > fields so should be provided, though not necessarily computed until > > > requested for the reasons given by Martin. (It seems that with the > > > current impl

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread Martin Albrecht
> > By contrast F.multiplicative_gen() does make sense for all finite > > fields so should be provided, though not necessarily computed until > > requested for the reasons given by Martin. (It seems that with the > > current implementation of non-prime fiinite fields this comes for > > free, but

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-23 Thread John Cremona
Thanks for taking the time to read and respond to my lengthy contribution. I agree with everything you say! Sorry to those who don't like the more mathematical discussions on sage-devel -- personally I find them more interesting than the notebook interface! but one of Sage's strengths is surely

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-22 Thread William Stein
On Jan 22, 2008 3:46 AM, John Cremona <[EMAIL PROTECTED]> wrote: > > Thoughts on this thread: > > For finite fields (or any other fields) the concept of additive > generator makes no sense -- only finite prime fields have one and it > is hardly a useful concept then since every nonzero element is

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-22 Thread John Cremona
Thoughts on this thread: For finite fields (or any other fields) the concept of additive generator makes no sense -- only finite prime fields have one and it is hardly a useful concept then since every nonzero element is one. It's different if talking about generators (plural!) which I think is w

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-21 Thread Martin Albrecht
> In this case, the docstring needs to be corrected, because the statement > that "All elements x of self are expressed as log_{self.gen()}(p) > internally" is not true, right? (Extrapolating from this sentence and my > two examples led me to make my previous statements.) Probably it is true > tha

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-21 Thread Jonathan Bober
Ok, I was wrong. I'm convinced that sage has the correct behavior, which I think is: GF(q).gen() returns an element x of GF(q) such that the smallest subfield of GF(q) containing x is GF(q). In this case, the docstring needs to be corrected, because the statement that "All elements x of self are

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-21 Thread David Kohel
Hi, It is probably a bias of the choice of (additive) generators for finite field extensions which results in the primitive field element also being a generator for the multiplicative group (confusingly called a "primitive element of the finite field"). It is not possible to set GF(q).gen() to a

[sage-devel] Re: generator inconsistencies in finite fields

2008-01-20 Thread William Stein
On Jan 20, 2008 10:54 PM, Jonathan Bober <[EMAIL PROTECTED]> wrote: > > I don't like the behavior illustrated below. Briefly, my problem is that > GF(p).gen() gives a generator for the additive group of GF(5), while > GF(p^n).gen() gives a generator for for multiplicative group of GF(p^n) > (n > 1