Robert,
Thanks for the clarification. However, is the result "Inconsistent
equations" really appropriate for [x=2,y=3], [x]?
I think it would mystify the average user (e.g. me)!
Shouldn't the result be [x=2]?
Kostas
Robert Dodier wrote:
> On 4/2/07, Kostas Oikonomou <ko at research.att.com> wrote:
>
>> I've reduced the linsolve issue to this example:
>>
>> linsolve([x=2,y=3],[x])
>
> Looks like the error occurs as SOLVEX (src/solve.lisp) attempts
> to output an error message about inconsistent equations.
> I think TFGELI is Gaussian elimination but I don't know how
> its return value is supposed to be interpreted.
>
> Maxima 5.11.0cvs http://maxima.sourceforge.net
> Using Lisp CLISP 2.38 (2006-01-24)
> (%i1) :lisp (trace solvex merror tfgeli)
> (%i1) linsolve([x=26,y=38],[x]);
> 1. Trace: (SOLVEX '(((MPLUS SIMP) -26 $X) ((MPLUS SIMP) -38 $Y)) '($X)
> 'NIL 'NIL)
> 2. Trace: (TFGELI 'XA* '2 '2)
> 2. Trace: TFGELI ==> (NIL (2) (1))
> 2. Trace: (MERROR '"Inconsistent equations: ~A" '(2))
> Maxima encountered a Lisp error:
> CAR: 2 is not a list
> Automatically continuing.
> To reenable the Lisp debugger set *debugger-hook* to nil.
>
> Solving for both variables is successful:
>
> (%i2) linsolve([x=26,y=38],[x, y]);
> 1. Trace: (SOLVEX '(((MPLUS SIMP) -26 $X) ((MPLUS SIMP) -38 $Y)) '($X
> $Y) 'NIL 'NIL)
> 2. Trace: (TFGELI 'XA* '2 '3)
> 2. Trace: TFGELI ==> (NIL NIL (1 2))
> 1. Trace: SOLVEX ==> ((MLIST) ((MEQUAL) $X 26) ((MEQUAL) $Y 38))
> (%o2) [x = 26, y = 38]
>
> FWIW
> Robert