On 9 April 2010 21:42, Nicolas M. Thiery <nicolas.thi...@u-psud.fr> wrote:
> You may want to look at: > > sage: A = AlgebrasWithBasis(QQ).example() > sage: A? > > For how to easily implement things like free commutative algebras. This intrigued me, so I did exactly the above; and found that I could not understand anything that A? displayed! And while I do understand what this object A is: sage: A An example of an algebra with basis: the free algebra on the generators ('a', 'b', 'c') over Rational Field I rapidly got lost when I came up against sage: A.basis() Lazy family (Term map from Words over Ordered Alphabet ['a', 'b', 'c'] to An example of an algebra with basis: the free algebra on the generators ('a', 'b', 'c') over Rational Field(i))_{i in Words over Ordered Alphabet ['a', 'b', 'c']} and sage: A(1) B[word: ] sage: A.one() B[word: ] sage: A.an_element() B[word: ] + 2*B[word: a] + 3*B[word: b] since I have no idea what that output means. What is B()? And why does A.gens() give an error -- I was expecting it to return ['a', 'b', 'c'] or similar. This probably just reveals my total ignorance of what it is that the Categories stuff in Sage actually does! John -- To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URL: http://www.sagemath.org