Newton method for one variable
I try to use 'solve' for nonlinear eauqtions in one variable, but the answer is tautological or "cannot evaluate symbolic expression numerically" if I add "explicit_solutions=True". Is Newton method (or any other, like secant method) implemented in Sage?
Ex: sage: x=var('x') sage: (x-cos(x)).solve(x)
[x == cos(x)]
while I would expect x= 0.739085
You can find it with
find_root(x-cos(x),0,1)
thank you!
It appears that find_root doesn't allow arbitrary precision. Is there another way?
You might try mpmath, see using mpmath.findroot.
Ok,thank you.