Structural Engineering, Bridge Research, Programming, and more…

Entries Comments

Optimization: Himmelblau’s Function

31 August, 2010 (00:18) | General

I just came across Himmelblau’s function for testing optimization routines. It has four local minima and one maxima so it provides a good test:

I’m pleased to say my implementation of the Nelder-Meade Simplex Algorithm (on my C++ page here) was able to optimize it for each minima (depending on the starting locations of course). I did have a weird problem though – starting a solution at (0,0) failed, even though the minima are not equidistant from the origin. Go figure!




Comment from Eugene OBrien
Time: 8 February, 2011, 12:06

Try the Cross Entropy method of optimisation. It is very simple to implement, very robust and would have no problem with a function like that with multiple local minima. It’s free to download – check out

Write a comment