Services & Resources / Wolfram Forums
-----
 /
MathGroup Archive
2006
*January
*February
*March
*April
*May
*June
*July
*August
*September
*October
*November
*December
*Archive Index
*Ask about this page
*Print this page
*Give us feedback
*Sign up for the Wolfram Insider

MathGroup Archive 2006

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

Search the Archive

Points sampled by FindMinimum

  • To: mathgroup at smc.vnet.net
  • Subject: [mg71085] Points sampled by FindMinimum
  • From: "Andrew Moylan" <andrew.j.moylan at gmail.com>
  • Date: Wed, 8 Nov 2006 06:14:00 -0500 (EST)

Hi all,

Please consider the following code, which asks FindMinimum to minimise
a simple parabolic function while tracking at which which points
FindMinimum evaluates the function:

func[x_?NumericQ] := (Print[x]; 1 + (x - 1)^2)
FindMinimum[func[x], {x, 0.1}]

The output is:

0.1
0.1
0.1
0.6
0.6
0.6
1.
1.
1.
1.
1.
1.

But I would have expected output more like:

0.1
0.6
1.
1.

Can anyone explain why FindMinimum evaluates func three times at each
test point, instead of once?

Cheers,
Andrew


  • Prev by Date: Re: Possible simple bug in NMaximize
  • Next by Date: Re: Lists and polynomials
  • Previous by thread: Points sampled by FindMinimum
  • Next by thread: Re: Points sampled by FindMinimum