Page 1 sur 1

roots(5*x^2 + 2*x - 3, x, '=' ) => [[x=-1,1],[x=3/5,1]]

Publié : jeu. sept. 20, 2018 2:36 pm
par compsystems
idea, to make the output more explicit, that is, to differentiate roots of multiplicity, please incorporate a third argument '='

roots(5*x^2 + 2*x - 3, x ) =>
[[-1,1],
[3/5,1]]

roots(5*x^2 + 2*x - 3, x, '=' ) =>
[[x=-1,1],
[x=3/5,1]]

//
similarly, to be able to specify the variable in preval
preval(x^2 + 2*x - 3, x=3, x=5) => 20