Function: algtrace
Section: algebras
C-Name: algtrace
Prototype: GG
Help: algtrace(al,x): (reduced) trace of x.
Doc: Given an element \var{x} in \var{al}, computes its trace. If \var{al} is
 a table algebra output by \tet{algtableinit}, returns the absolute trace of
 \var{x}, which is an element of $\F_p$ or~$\Q$; if \var{al} is the output of
 \tet{alginit}, returns the reduced trace of \var{x}, which is an element of
 the center of \var{al}.
 \bprog
 ? A = alginit(nfinit(y), [-1,-1]);
 ? algtrace(A,[5,0,0,1]~)
 %2 = 11
 @eprog

 Also accepts a square matrix with coefficients in \var{al}.
