# [Maxima] Matrix multiplication expansion

Frédéric Machefert frederic.machefert at in2p3.fr
Mon May 1 08:06:47 CDT 2006

```Dear All,
my question is probably naive but I am just starting with Maxima and I
have not been able to found a solution to my problem. I use Maxima
5.9.2. Notice, that I didn't observe the behaviour I mention (in the
following) with the previous version of Maxima (5.9.1).

I use Maxima for Linear Algebra and performing matrix multiplication, I
cannot obtain the result of the product as a single matrix whom the
elements are evaluated.

As a simple example :

(%i1) A1:Matrix([a,b,c],[d,e,f],[g,h,i]);

(%o1)               Matrix([a, b, c], [d, e, f], [g, h, i])

(%i2) A2:Matrix([j,k,l],[m,n,o],[p,q,r]);

(%o2)               Matrix([j, k, l], [m, n, o], [p, q, r])

(%i3) A1.A2;

(%o3) Matrix([a, b, c], [d, e, f], [g, h, i])

. Matrix([j, k, l], [m, n, o], [p, q, r])

(%i4) expand(%);

(%o4) Matrix([a, b, c], [d, e, f], [g, h, i])

. Matrix([j, k, l], [m, n, o], [p, q, r])

(%i5)

and there is no way I can get the matrix expanded. Version 5.9.1 would
give me a longer but expanded answer. I did not change the default
configuration of Maxima.
Frédéric.

--

----------------------------------------------------------------------
Frédéric Machefert                    LAL - CNRS
Tel : (33) 01 64 46 85 54             Université Paris-Sud Orsay
Fax : (33) 01 64 46 83 97             BP 34
frederic.machefert at in2p3.fr           91898 Orsay
----------------------------------------------------------------------

```