Maxima: Syntax improvements



On 6/30/08, Stavros Macrakis <macrakis at alum.mit.edu> wrote:

>  > (1) Its a very good idea to incorporate Matlab syntax for matrix manipulations eg. a(1:4,[1 5 6]).
>
>  I assume that this denotes an array slice, which would certainly be
>  useful functionality for Maxima.  Robert Dodier's amatrix does
>  something like this (see
>  http://maxima.cvs.sourceforge.net/maxima/maxima/share/contrib/amatrix/)

Yes, amatrix is essentially an experiment to get functionality
similar to Matlab's array slicing, but using Maxima notation
(i.e. without any changes to the Maxima parser).

>  but as far as I can tell it does not interoperate with any existing
>  Maxima matrix/array functionality, so in order to calculate
>  scalar-matrix products, determinants, inversion, eigenvalues, etc.
>  etc. you need to convert back to Maxima's standard representation.

Right, at present any code which assumes it knows the internal
structure of a matrix cannot work with amatrix. But code which
only accesses elements via indexing should not notice if the
matrix implementation has changed.

>  Maxima's current array/matrix semantics are a mess, I must say, with
>  at least four different kinds of object (hasharrays, explicit lists,
>  explicit matrices, Lisp arrays) supporting subscripting with varying
>  semantics. We really need to work on this....

Yes, I think revising the array/matrix stuff would be a very useful goal.
Not sure where to start. If someone has any kind of plan, I'm all ears.

best

Robert Dodier