Question about trigrat & matrices



-----maxima-bounces at math.utexas.edu wrote: -----

>To: maxima at math.utexas.edu
>From: David Ronis <ronis at ronispc.chem.mcgill.ca>
>Sent by: maxima-bounces at math.utexas.edu
>Date: 06/06/2007 01:08PM
>Subject: Question about trigrat & matrices
>
>I want to apply trigrat to the elements of a matrix, for example:
>
>                                                p1:matrix([1,0],[0,-1]);
>                                                p2:matrix([0,1],[1,0]);
>                                                p3:matrix([0,1],[-1,0]);
>                                                S:s1*p1+s2*p2+s3*p3;
>
>M:(ident(2)-coth(del*t/2)/del*S);
>                                                trigrat(%);
>
>However, when I try to run this I get:
>
>(%i6) trigrat(%);
>Maxima encountered a Lisp error:
>
>
>CAR: 1 is not a list
>
>Automatically continuing.
>To reenable the Lisp debugger set *debugger-hook* to nil.
>
>
>Is this a bug?  (I'm using a fairly recent CVS version and clisp)

Yes, this is a bug. If you would, file a bug report. (Also, you might
search the bug list for other trigrat bugs -- I think there is
at least one.) Until this bug is fixed, you can do use matrixmap:

(%i7) matrixmap('trigrat, M);

Barton