Can Wolfram Mathematica be wrong on this Integration?

In summary, the conversation discusses an issue with Mathematica's integration and the need to double check results obtained from the software. There is a suggestion to use NIntegrate instead of Integrate and to define specific variables in order to get the correct answer. The conversation also mentions being careful with how Mathematica represents numbers internally.
  • #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

Related to Can Wolfram Mathematica be wrong on this Integration?

1. Can Wolfram Mathematica be wrong on this Integration?

As with any computational tool, there is always a possibility for error. However, Wolfram Mathematica is known for its accuracy and has been extensively tested and validated. It also has built-in error checking capabilities to alert the user if there are any potential issues with the integration.

2. How does Wolfram Mathematica handle complex integrals?

Wolfram Mathematica has powerful algorithms and built-in functions that allow it to handle complex integrals, including those involving multiple variables and special functions. It also has the ability to perform symbolic integration, which allows for exact solutions rather than numerical approximations.

3. Can Wolfram Mathematica handle improper integrals?

Yes, Wolfram Mathematica can handle improper integrals by using appropriate methods such as splitting the integral into multiple parts, applying limits, or using substitution techniques. However, it is important to carefully check the results and make sure they are convergent.

4. How does Wolfram Mathematica handle integrals with numerical limits?

Wolfram Mathematica has the ability to handle integrals with numerical limits by using numerical integration methods such as the trapezoidal rule or Simpson's rule. It also has the option to specify the desired level of precision for the result.

5. What should I do if I suspect there is an error in the integration result from Wolfram Mathematica?

If you suspect an error in the integration result, it is important to carefully check the input, the integration method used, and any potential issues with the integrand. You can also try using different integration methods or breaking the integral into smaller parts to see if the results are consistent. If you are still unsure, you can consult the Wolfram Mathematica documentation or seek assistance from other users on online forums or communities.

Similar threads

  • MATLAB, Maple, Mathematica, LaTeX
Replies
1
Views
861
  • Calculus and Beyond Homework Help
Replies
8
Views
2K
  • Calculus and Beyond Homework Help
Replies
1
Views
2K
  • Calculus and Beyond Homework Help
Replies
10
Views
1K
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
2K
  • Calculus and Beyond Homework Help
Replies
5
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
931
  • MATLAB, Maple, Mathematica, LaTeX
Replies
3
Views
1K
  • Calculus and Beyond Homework Help
Replies
4
Views
1K
Back
Top