addcol list bug or feature



(%i12) a:[matrix([1],[2]), matrix([3],[4])];
(%o12) [matrix([1],[2]),matrix([3],[4])]
(%i13) b:matrix([0],[0]);
(%o13) matrix([0],[0])
(%i14) rreduce('addcol,cons(b,a));
(%o14) matrix([0,1,3],[0,2,4])


Barton

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

>To: maxima at math.utexas.edu
>From: "Martin J. Ott" <ottmartin at web.de>
>Sent by: maxima-bounces at math.utexas.edu
>Date: 02/12/2008 06:30PM
>Subject: addcol list bug or feature
>
>Hello everybody,
>
>I want to create a matrix out of list elements. Therefor I tried addcol,
>but
>unfortunately the effect ist not the expected.
>One little example(not my real problem, but contains the same behaviour):
>
>a:[matrix([1],[2]), matrix([3],[4])];
>b:matrix([0],[0])
>
>what I did is:
>addcol(b,a)
>
>but what I want is the effect of:
>addcol(b,part(a,1),part(a,2))
>
>could anybody tell me, if this is a bug or just a feature, I haven't
>understood yes?
>
>By the way; Is there a function in MAXIMA equivalent to FoldList in
>Mathematica?
>
>Any suggestions will be welcome.
>
>Martin
>_______________________________________________
>Maxima mailing list
>Maxima at math.utexas.edu
>http://www.math.utexas.edu/mailman/listinfo/maxima