NIntegrate(cos(x), {x, 0, pi}) should return 0,but return 1.3465790982269965E-16
Issue #118
resolved
maybe we can check the integrate first ,if has F(x),just subtract F(a)-F(b) and return?
Comments (4)
-
repo owner -
reporter yes,that's good!even we can implement an interface which can send an epsilon by user
-
repo owner I implemented this commit: 3cbcffb
You can now set a PrecisionGoal like this:
NIntegrate(1/Sin(Sqrt(x)), {x, 0, 1}, PrecisionGoal->10)
The default PrecisionGoal is set to 16
-
repo owner - changed status to resolved
- Log in to comment
We can try to define an epsilon value in NIntegrate for which the output will be 0? See: http://stackoverflow.com/q/3728246/3805428