4.5. pyopus.optimizer.hj — Box constrained Hooke-Jeeves optimizer

Inheritance diagram of pyopus.optimizer.hj

Box constrained Hooke-Jeeves optimizer (PyOPUS subsystem name: HJOPT)

An extended version of coordinate search where so-called speculative steps are taken from time to time. These steps are hoped to speed up the search.

The convergence theory applied to coordinate search can also be applied to Hooke-Jeeves algorithm if the speculative step length factor is an integer.

The algorithm (unconstrained version) was first published in [hj].

[hj]Hooke R., Jeeves T. A., Direct Search Solution of Numerical and Statistical Problems. Journal of the ACM (JACM), vol. 8, pp. 212-229, 1961.
class pyopus.optimizer.hj.HookeJeeves(function, xlo=None, xhi=None, debug=0, fstop=None, maxiter=None, stepup=1.0, stepdn=0.5, step0=None, minstep=None, speculative=2.0)

Hooke-Jeeves optimizer class

speculative is the step length factor for the speculative step.

See the CoordinateSearch class for more information.


Checks the optimization algorithm’s settings and raises an exception if something is wrong.


Puts the optimizer in its initial state and sets the initial point to be the 1-dimensional array or list x0. The length of the array becomes the dimension of the optimization problem (ndim member). The shape of x0 must match that of xlo and xhi.


Runs the optimization algorithm.

Previous topic

4.4. pyopus.optimizer.coordinate — Box constrained coordinate search optimizer

Next topic

4.6. pyopus.optimizer.nm — Unconstrained Melder-Mead simplex optimizer

This Page