Linsolve doesn't check arguments



On 2013-09-04, Stavros Macrakis <macrakis at alum.mit.edu> wrote:

> 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.

Agreed -- any user-callable function should carry out whatever checking
is needed to ensure it returns a valid result.

best

Robert Dodier