Rolandb
unread,Oct 3, 2010, 1:26:38 PM10/3/10Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to sage-support
Hi,
Two examples:
var('x1,x2')
y=[x1,x2]
opl=solve([x1^2==4,x2^2==9],y,solution_dict=True)
print opl
[{x2: -3, x1: -2}, {x2: -3, x1: 2}, {x2: 3, x1: -2}, {x2: 3, x1: 2}]
var('x1')
y=[x1]
opl=solve([x1^2==4],y,solution_dict=True)
print opl
Traceback (click to the left of this block for traceback)
...
TypeError: [x1] is not a valid variable.
In both cases y is a list.
Roland