MathGroup Archive 2009

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

Search the Archive

Re: NMinimize Bug in Mathematica 7.0?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg96243] Re: NMinimize Bug in Mathematica 7.0?
  • From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
  • Date: Tue, 10 Feb 2009 05:49:58 -0500 (EST)
  • Organization: The Open University, Milton Keynes, UK
  • References: <gmp0pi$c02$1@smc.vnet.net>

In article <gmp0pi$c02$1 at smc.vnet.net>, appris at att.net wrote:

> Here is an example from Mathematica's user's guide:
> 
> In[8]:= NMinimize[x^4 - 3 x^2 + x, x]
> 
> Out[8]=  {-3.513905039, {x -> -1.300839566}}
> 
> however, trying to replicate it, I get the following:
> 
> In[2]:= NMinimize[x^4 - 3 x^2 + x, x]
> 
> Out[2]= {-1.070230182, {x -> 1.130901122}}
> 
> One way to find the global min, I had to use a constraint such as x<0.
> 
> Has anyone come across such a problem?
> 
> In[3]:= $Version
> 
> Out[3]= "7.0 for Microsoft Windows (32-bit) (November 10, 2008)"

I bet that the example you posted (In[8]/Ou[8]) ran on Mathematica 5.x 
because the function NMinimize[] was introduced in Mathematica 5.0 and 
updated/modified/fixed(broken? :-) in version 6.0 (according to the 
online documentation). I get the same result as yours in Mathematica 
6.0.3 for Mac OS X and 7.0 for Windows XP.

In[4]:= $Version

Out[4]= "6.0 for Mac OS X x86 (64-bit) (May 21, 2008)"

In[5]:= NMinimize[x^4 - 3 x^2 + x, x]

Out[5]= {-1.07023, {x -> 1.1309}}

In[7]:= NMinimize[{x^4 - 3 x^2 + x, x < 0}, x]

Out[7]= {-3.51391, {x -> -1.30084}}


In[17]:= $Version

Out[17]= "7.0 for Microsoft Windows (32-bit) (November 10, 2008)"

In[18]:= NMinimize[x^4 - 3 x^2 + x, x]

Out[18]= {-1.07023, {x -> 1.1309}}

In[19]:= NMinimize[{x^4 - 3 x^2 + x, x < 0}, x]

Out[19]= {-3.51391, {x -> -1.30084}}

Regards,
--Jean-Marc


  • Prev by Date: Re: very slow Save[]s on Mathematica V7??
  • Next by Date: Re: Data interpolation
  • Previous by thread: Re: NMinimize Bug in Mathematica 7.0?
  • Next by thread: Re: NMinimize Bug in Mathematica 7.0?