Skip to main content

Module cobyqa

Module cobyqa 

Source
Expand description

COBYQA: constrained optimisation by quadratic approximations (Ragonneau, 2022; SciPy’s minimize(method='COBYQA')), a derivative-free trust-region method for problems with bounds and nonlinear inequality and equality constraints.

The objective and each constraint get a quadratic model that interpolates their values at 2n + 1 points (more with CobyqaOptions::npt), the one of least Frobenius norm of the change of its Hessian from the previous model. Each iteration takes a Byrd–Omojokun step from the best point: a normal step that reduces the violation of the linearised constraints, and a tangential step that reduces the model of the Lagrangian without undoing that, both within the trust region and the bounds; the step is judged on an ℓ₂ merit function whose penalty parameter rises with the Lagrange multiplier estimates. Steps that do not pay are followed by moves that restore the geometry of the interpolation set, and the resolution ρ of the trust region falls from rhobeg to rhoend.

See the book entry Constrained optimisation.

Structs§

CobyqaConstants
The constants of the method, with SciPy’s defaults; CobyqaConstants::validate checks the ranges and relations that SciPy enforces.
CobyqaOptions
Options for cobyqa, with SciPy’s defaults.
CobyqaResult
The result of cobyqa.
LinearConstraints
Linear constraints a_ub x ≤ b_ub and a_eq x = b_eq (rows of a_ub, a_eq), kept exact by cobyqa_with instead of being modelled.

Enums§

CobyqaStatus
Why cobyqa stopped.

Functions§

cobyqa
Minimises problem.objective subject to the bounds lower ≤ x ≤ upper (None: unbounded) and to the problem’s inequalities(x) ≤ 0 and equalities(x) = 0, without derivatives, by COBYQA (SciPy’s minimize(method='COBYQA')). The gradient and Jacobian methods of ConstrainedProblem are never called. See cobyqa_with for linear constraints and a callback.
cobyqa_with
cobyqa with linear constraints, which are kept exact (their linearisations are the constraints themselves, and they count in the merit function and the multipliers) instead of being modelled, and a callback that receives the best point after every evaluation and stops the run by returning true (status CobyqaStatus::CallbackStop, a success).

Type Aliases§

StopCallback
A callback for cobyqa_with: it receives the best point and returns true to stop.