From: Richard Kreckel Date: Tue, 24 Nov 2015 12:09:47 +0000 (+0100) Subject: Tutorial: how to create noncommutative symbols? X-Git-Tag: ginac_1-6-6~5 X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=commitdiff_plain;h=27213d158e5ec4b606b4f4d0766bf75eeb18673f Tutorial: how to create noncommutative symbols? This seems to be frequently asked: Cherry-picked from dfaba64c. --- diff --git a/doc/tutorial/ginac.texi b/doc/tutorial/ginac.texi index 3db3518e..93ed619f 100644 --- a/doc/tutorial/ginac.texi +++ b/doc/tutorial/ginac.texi @@ -3033,6 +3033,8 @@ canonicalize themselves according to rules specified in the implementation of the non-commutative classes. The drawback is that to work with other than the built-in algebras you have to implement new classes yourself. Both symbols and user-defined functions can be specified as being non-commutative. +For symbols, this is done by subclassing class symbol; for functions, +by explicitly setting the return type (@pxref{Symbolic functions}). @cindex @code{return_type()} @cindex @code{return_type_tinfo()}