Can Wolfram Mathematica be wrong on this Integration?

  • #1
srecko97
82
13

Homework Statement


Mathematica vs (Symbolab + my brain)

Homework Equations

The Attempt at a Solution


I think this integral calculation in Mathematica is wrong. Open pictures below.
Please help me.

Graphs (the red one is under the blue and the green):
bACa3G

https://ibb.co/bACa3G
Wolfram Mathematica
iREcHb

https://ibb.co/iREcHb
Symbolab:
jHhKVw

https://ibb.co/jHhKVw
 
Physics news on Phys.org
  • #2
You've shown us steps 21, 23, 24 and then jumped to step 30. What happened in between those two? Mathematica remembers any definitions that might have been made between those two. If you restart the kernel and do just those steps you've shown, does it get the same answer?
 
  • Like
Likes srecko97
  • #3
I have deleted everything betwen 24 and 30. I also tried to solve it in another notebook. I inserted numbers inside the integral instead of pre-defined variables. The results were always 0. Try to retype the same integral in Mathematica please. I am quite sure that you will get 0 too
 
  • #4
It seems you've run into a weird quirk/bug in how Mathematica integrates. I found if you define ##\alpha=3912023/100000## and ##\beta = 103/100## and use ##\beta X## as the lower limit of the integral, you get the correct non-zero answer. Also, if you use NIntegrate instead of Integrate, you'll also get the correct answer.
 
  • Like
Likes srecko97
  • #5
Thanks. I am a beginner user of Wolfram Mathematica. Do you have a lot of such problems with Mathematica? Should I trust it or it is better to solve integrals on paper?
 
  • #6
Mathematica is a powerful tool, but you don't want to trust it blindly. Just like when you do calculations on paper, you still need to check if the results you get make sense. I'm not exactly sure what's going on in this case, but it seems to have to do with how Mathematica represents numbers internally. For example, if you type in "100-100/3*3" and "b=100-100.0/3*3" into Mathematica, you get different results because in the first case, the software represents 100/3 internally as a fraction, but in the second case, it represents 100.0/3 as a floating-point number, which has limited accuracy by its nature.
 
  • Like
Likes berkeman and srecko97
  • #7
Thank you vela!
 
  • Like
Likes berkeman
Back
Top