Solving equation with mathematica

  • Context: Mathematica 
  • Thread starter Thread starter yashar
  • Start date Start date
  • Tags Tags
    Maple Mathematica
Click For Summary

Discussion Overview

The discussion revolves around solving the equation a/x = Cosh[b/x] using Mathematica, with specific values for a and b. Participants explore numerical methods and the existence of real and complex roots for the equation.

Discussion Character

  • Technical explanation, Debate/contested, Mathematical reasoning

Main Points Raised

  • One participant expresses difficulty in solving the equation using NSolve in Mathematica and questions if there are alternative numerical methods.
  • Another participant suggests using FindRoot instead of NSolve, noting that NSolve is limited to polynomial equations.
  • A subsequent reply claims that the solution x=25.16 obtained is incorrect.
  • One participant proposes rewriting the equation as COSH(5/x) - 1/x = 0 and notes that the function appears asymptotic to the x-axis, suggesting no real solutions exist.
  • Another participant agrees that plotting indicates the absence of real roots and questions the validity of results obtained from Maple.
  • A later post introduces FindInstance as a method to find complex roots and mentions that FindRoot can be used with complex initial values to search for complex roots.

Areas of Agreement / Disagreement

Participants express disagreement regarding the existence of real roots, with some asserting that there are none while others reference results from Maple. The discussion on complex roots remains open, with some participants proposing methods to explore them.

Contextual Notes

There are limitations related to the assumptions about the nature of the roots, the dependence on the specific methods used, and the potential for different results across software tools.

yashar
Messages
31
Reaction score
0
hi
i want to solve this equation
a/x=Cosh[b/x]

i set a=1 and b=5
and use NSolve code but mathematica say it can not solve it. but with maple i get real and imaginary parts.
1-is there another method to solve this equation numerically?
2-can this equation be solve for arbitrary a and b?

thanks
 
Last edited:
Physics news on Phys.org
NSolve is only for polynomial equations. Use FindRoot instead.
 
it gives me x=25.16 which is incorrect!
 
If you rewrite the expression so that COSH(5/x) - 1/x = 0 = f(x) and plot, you will see that f(x) is asymptotic with the x axis. Therefore, there is no x value for which f(x) = 0
 
Plotting it it seems that it does not have any real roots. So I think Maple is wrong, there are no real roots.

PS. SteamKing got it faster!
 
I just found a new function: FindInstance. You can use it to find complex roots. Also, apparently you can specify a complex number for your initial value in FindRoot and it will search for a complex root, which I didn't know before.
 

Similar threads

  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 5 ·
Replies
5
Views
4K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 19 ·
Replies
19
Views
3K
  • · Replies 13 ·
Replies
13
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K