Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
feeding fminsearch with precomputed cost function values

Subject: feeding fminsearch with precomputed cost function values

From: kees de Kapper

Date: 10 Oct, 2013 11:55:06

Message: 1 of 2

Hi all!

If I use fminsearch I will get a cost function value after each parameter evaluation.
Would it be possible to feed these results in a second run?

Let me explain my question. Probably I completely misunderstand the idea of fminsearch, but I could image that an optimization procedure is "sensing" the cost-space of a problem, then finding step-by-step the minimum. Then if you feed precomputed costs for predefined parameters, it will "know" before evaluation that steping in a certian direction will lead to higher costs. Feeding predifined costs could therefore help the optimization coming more easy and faster to the optimal result.

Would this be possible?

Thanks in advance.

Kind regards,
Kees

Subject: feeding fminsearch with precomputed cost function values

From: John D'Errico

Date: 10 Oct, 2013 14:30:08

Message: 2 of 2

"kees de Kapper" <kees_de_kapper@hotmail.com> wrote in message <l364iq$i1r$1@newscl01ah.mathworks.com>...
> Hi all!
>
> If I use fminsearch I will get a cost function value after each parameter evaluation.
> Would it be possible to feed these results in a second run?
>
> Let me explain my question. Probably I completely misunderstand the idea of fminsearch, but I could image that an optimization procedure is "sensing" the cost-space of a problem, then finding step-by-step the minimum. Then if you feed precomputed costs for predefined parameters, it will "know" before evaluation that steping in a certian direction will lead to higher costs. Feeding predifined costs could therefore help the optimization coming more easy and faster to the optimal result.
>
> Would this be possible?

No. Not in practice. At least not in any valuable way.

Fminsearch, like any optimizer, looks at the objective
function values it is given and uses them to decide
the next point it will sample.

So if you knew where it was going to sample, then
you must have run the code previously on the same
objective function, and therefore you will get the same
solution you got last time you ran it.

So why bother to run it twice if you already know the
answer? It seems this is unlikely to help you much,
unless you just like taking your CPU out for a spin.
In that case, and you just wish to waste CPU cycles,
why not let it do some work and compute those
function values anyway?

John

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us