Class SQPASVariation1
- java.lang.Object
-
- dev.nm.solver.multivariate.constrained.general.sqp.activeset.SQPASVariation1
-
- All Implemented Interfaces:
SQPASVariation
public class SQPASVariation1 extends Object implements SQPASVariation
This implementation is a modified version of Algorithm 15.4 in the reference to solve a general constrained minimization problem using Sequential Quadratic Programming.
-
-
Constructor Summary
Constructors Constructor Description SQPASVariation1(double epsilon)Construct a variation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doublealpha(Vector x, Vector d, Vector v, Vector u)Get the percentage increment along the minimizer increment direction.MatrixgetInitialHessian(Vector x0, Vector v0, Vector u0)Get the initial Hessian matrix.voidset(RealScalarFunction f, RealVectorFunction g, EqualityConstraints equal, GreaterThanConstraints greater)Associate this variation to a particular general constrained minimization problem.MatrixupdateHessian(Vector x1, Vector v1, Vector u1, Vector d, Vector g0, Matrix Ae0, Matrix Ai0, Matrix W0)Update the Hessian matrix using the latest iterates.
-
-
-
Method Detail
-
set
public void set(RealScalarFunction f, RealVectorFunction g, EqualityConstraints equal, GreaterThanConstraints greater)
Associate this variation to a particular general constrained minimization problem.- Parameters:
f- the objective function to be minimizedg- the gradient function for fequal- the equality constraintsgreater- the greater-than-or-equal-to constraints
-
getInitialHessian
public Matrix getInitialHessian(Vector x0, Vector v0, Vector u0)
Description copied from interface:SQPASVariationGet the initial Hessian matrix.- Specified by:
getInitialHessianin interfaceSQPASVariation- Parameters:
x0- the initial minimizerv0- the initial Lagrange multipliers for equality constraints (lambda)u0- the initial Lagrange multipliers for inequality constraints (mu)- Returns:
- the initial Hessian matrix, e.g., identity
-
updateHessian
public Matrix updateHessian(Vector x1, Vector v1, Vector u1, Vector d, Vector g0, Matrix Ae0, Matrix Ai0, Matrix W0)
Update the Hessian matrix using the latest iterates.- Specified by:
updateHessianin interfaceSQPASVariation- Parameters:
x1- the next minimizerv1- the next Lagrange multipliers for equality constraints (lambda)u1- the next Lagrange multipliers for inequality constraints (mu)d- the minimizer incrementg0- the gradientAe0- the set of active equality constraintsAi0- the set of active inequality constraintsW0- the current Hessian matrix- Returns:
- the next Hessian matrix
- See Also:
- "eqs. 15.41 - 15.44"
-
alpha
public double alpha(Vector x, Vector d, Vector v, Vector u)
Get the percentage increment along the minimizer increment direction.- Specified by:
alphain interfaceSQPASVariation- Parameters:
x- the current minimizerd- the minimizer incrementv- the Lagrange multipliers for equality constraints (lambda)u- the Lagrange multipliers for inequality constraints (mu)- Returns:
- the percentage increment
- See Also:
- "eq. 15.36"
-
-