Services & Resources / Wolfram Forums / MathGroup Archive
-----

MathGroup Archive 2008

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

Search the Archive

Re: weird NMaximize behaviour

  • To: mathgroup at smc.vnet.net
  • Subject: [mg92067] Re: weird NMaximize behaviour
  • From: appris at att.net
  • Date: Fri, 19 Sep 2008 05:15:25 -0400 (EDT)
  • References: <gat9qm$ejo$1@smc.vnet.net>

Try to pick a method such as DifferentialEvolution

NMaximize[{(x - 1)^2, -2 <= x <= 2 && -1 <= y <= 1}, {x, y},
 Method -> "DifferentialEvolution"]
{9., {x -> -2., y -> 1.}}

I believe the default condition uses "NelderMead" and that apparently
provides the wrong result.  The RandomSearch takes a while.
"SimulatedAnnealing" converges to the right answer as well.


  • Prev by Date: Re: blurry ellipse
  • Next by Date: Re: Functional programming?
  • Previous by thread: weird NMaximize behaviour
  • Next by thread: Re: weird NMaximize behaviour