Linsolve doesn't check arguments



linsolve([x*y-1],[x,y]) => [x = -(%r4*x-1)/y,y = %r4]

This is wrong, presumably because linsolve is blindly assuming that the
arguments are linear in all variables.  To see that it is really grossly
wrong and not just unhelpful (which is bad enough), substitute y=%r4=1, and
you'll see x=1-x i.e. x=1/2; [x=1/2,y=1] is not a solution.

I'd propose that linsolve check this precondition and give an error if it
fails.  This should avoid some user confusion at the cost of a little
overhead.

It could be argued that only sophisticated users will use linsolve rather
than solve, and should know better, but (a) we get new users trying out all
sorts of things; (b) even sophisticated users make blunders from time to
time.  As a matter of fact, I ran into a silent bug in some share code
because of this.

             -s