0

I am trying to check if the result is enough accurate to use. I need an accuracy of 10^-6 from some numerical method. Something like root finding algorithm. But how do I check that in mathematica? I looked over Accuracy[] and Precision[] but they are quite confusing in that they yield machineprecision. Can anyone suggest something? Thank you for help :)

jason
  • 275
  • 1
  • 8

1 Answers1

2
(root = x /. FindRoot[x*Tan[x] - Cos[x] == 0, {x, 3}]) // InputForm

2.8170396080933187

root // Precision

MachinePrecision

Your machine precision is seen with $MachinePrecision

$MachinePrecision

15.9546

root2 = x /. FindRoot[x*Tan[x] - Cos[x] == 0, {x, 3}, WorkingPrecision -> 20]

2.8170396080933199925

root2 // Precision

20.

Bob Hanlon
  • 157,611
  • 7
  • 77
  • 198