MathGroup Archive 2011

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Problem with Solve and NSolve

  • To: mathgroup at smc.vnet.net
  • Subject: [mg122482] Re: Problem with Solve and NSolve
  • From: Andrzej Kozlowski <akoz at mimuw.edu.pl>
  • Date: Sat, 29 Oct 2011 07:14:39 -0400 (EDT)
  • Delivered-to: l-mathgroup@mail-archive0.wolfram.com
  • References: <201110280935.FAA20759@smc.vnet.net>

On 28 Oct 2011, at 11:35, V. Williams wrote:

> I've recently tried Mathematica 8.0.1, and I've found that it's unable 
to compute Solve[x^3*Sin[x]==1,x] (and the same with NSolve), which 
gives an error:
> Solve::nsmet: This system cannot be solved with the methods available to Solve
>
> WolframAlpha solves it without problems, so what's wrong with Mathematica?
>

WolframAlpha gives you only a few roots in an interval chosen by itself (and assumes that you only want the real ones). You can get as many roots as you like with:

N[Solve[x^3*Sin[x] == 1 && Abs[x] < 100, x, Reals]]


{{x->-97.3894},{x->-94.2478},{x->-91.1062},{x->-87.9646},{x->-84.823},{x->-81.6814},{x->-78.5398},{x->-75.3982},{x->-72.2566},{x->-69.115},{x->-65.9734},{x->-62.8319},{x->-59.6903},{x->-56.5487},{x->-53.4071},{x->-50.2655},{x->-47.1239},{x->-43.9823},{x->-40.8407},{x->-37.6991},{x->-34.5575},{x->-31.416},{x->-28.2743},{x->-25.1328},{x->-21.9911},{x->-18.8497},{x->-15.7077},{x->-12.5669},{x->-9.42358},{x->-6.28721},{x->-3.10829},{x->-1.04879},{x->1.04879},{x->3.10829},{x->6.28721},{x->9.42358},{x->12.5669},{x->15.7077},{x->18.8497},{x->21.9911},{x->25.1328},{x->28.2743},{x->31.416},{x->34.5575},{x->37.6991},{x->40.8407},{x->43.9823},{x->47.1239},{x->50.2655}, {x->53.4071},{x->56.5487},{x->59.6903},{x->62.8319},{x->65.9734},{x->69.115},{x->72.2566},{x->75.3982},{x->78.5398},{x->81.6814},{x->84.823},{x->87.9646},{x->91.1062},{x->94.2478},{x->97.3894}}

or if you want complex roots:

N[Solve[x^3*Sin[x] == 1 && Abs[x] < 100, x, Reals]]

=
{{x->-97.3894},{x->-94.2478},{x->-91.1062},{x->-87.9646},{x->-84.823},{x->-81.6814},{x->-78.5398},{x->-75.3982},{x->-72.2566},{x->-69.115},{x->-65.9734},{x->-62.8319},{x->-59.6903},{x->-56.5487},{x->-53.4071},{x->-50.2655},{x->-47.1239},{x->-43.9823},{x->-40.8407},{x->-37.6991},{x->-34.5575},{x->-31.416},{x->-28.2743},{x->-25.1328},{x->-21.9911},{x->-18.8497},{x->-15.7077},{x->-12.5669},{x->-9.42358},{x->-6.28721},{x->-3.10829},{x->-1.04879},{x->1.04879},{x->3.10829},{x->6.28721},{x->9.42358},{x->12.5669},{x->15.7077},{x->18.8497},{x->21.9911},{x->25.1328},{x->28.2743},{x->31.416},{x->34.5575},{x->37.6991},{x->40.8407},{x->43.9823},{x->47.1239},{x->50.2655},{x->53.4071},{x->56.5487},{x->59.6903},{x->62.8319},{x->65.9734},{x->69.115},{x->72.2566},{x->75.3982},{x->78.5398},{x->81.6814},{x->84.823},{x->87.9646},{x->91.1062},{x->94.2478},{x->97.3894}}

Andrzej Kozlowski





  • Prev by Date: Re: Mathematica Beginner/Student and Mysql
  • Next by Date: Re: Problem with Solve and NSolve
  • Previous by thread: Re: Problem with Solve and NSolve
  • Next by thread: Re: Problem with Solve and NSolve