MathGroup Archive 2004

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

Search the Archive

Re: output in NMinimize on each step?

  • To: mathgroup at smc.vnet.net
  • Subject: [mg46415] Re: output in NMinimize on each step?
  • From: Omega Consulting <info at omegaconsultinggroup.com>
  • Date: Tue, 17 Feb 2004 07:05:47 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

At 06:16 AM 2/12/2004, mfific wrote:
>I would appreciate suggestion how to get an output on each step during
>minimization process in NMinimize.
>
>I am surprised  this has not been included as an option in Nminimize,
>because it is very useful to see what is Mathematica doing.
>
>The solution for getting an output could  be found for FindMinimum, but
>somehow I cannot use that in NMinimize.
>An example would be very helpful.
>
>thanks,
>
>Mario Fific

In version 5, there's the StepMonitor option.

In[1]:= Options[NMinimize]
Out[1]=
{AccuracyGoal -> Automatic, EvaluationMonitor -> None, MaxIterations -> 100,
   Method -> Automatic, PrecisionGoal -> Automatic, StepMonitor -> None,
   WorkingPrecision -> MachinePrecision}

In[2]:= ?StepMonitor
StepMonitor is an option for iterative numerical computation \
functions that gives an expression to evaluate whenever a step is taken by \
the numerical method used.

In[3]:= NMinimize[{x^2 + (y - 0.5)^2, y >= 0 && y >= x + 1},
   {x, y}, StepMonitor :> Print[{x, y}]]

--------------------------------------------------------------
Omega Consulting
"The final answer to your Mathematica needs"
http://omegaconsultinggroup.com


  • Prev by Date: Re: A zillion times slower in version 5
  • Next by Date: Re: how to read this data file in mathematica?
  • Previous by thread: output in NMinimize on each step?
  • Next by thread: Re: output in NMinimize on each step?