[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-math] Assigning elements in a list of lists
From: |
Fabio S. |
Subject: |
[Axiom-math] Assigning elements in a list of lists |
Date: |
Wed, 12 Nov 2008 11:42:23 +0100 (CET) |
User-agent: |
Alpine 1.00 (DEB 882 2007-12-20) |
I can't understand why I am not able to assign an element in a list of
lists like in
--------
(35) -> A:=[[0,0,0,0]]
(35) [[0,0,0,0]] Type: List List NonNegativeInteger
(36) -> A(1,1)
(36) 0 Type: NonNegativeInteger
(37) -> A(1,1):=1
The form on the left hand side of an assignment must be a single
variable, a Tuple of variables or a reference to an entry in an object
supporting the setelt operation.
--------
whereas if I declare A as a matrix it works:
--------
(43) -> A:=[[0,0,0,0]] :: Matrix INT
(43) [0 0 0 Type: Matrix Integer
(44) -> A(1,1):=1
(44) 1 Type: PositiveInteger
(45) -> A
(45) [1 0 0 0] Type: Matrix Integer
--------
Can anybody please explain me what is wrong in the first esample?
Thank you very much
Fabio
- [Axiom-math] Assigning elements in a list of lists,
Fabio S. <=