Package jline.inference.util
Object OptimUtils
-
- All Implemented Interfaces:
public class OptimUtilsOptimization utilities for inference algorithms.
-
-
Field Summary
Fields Modifier and Type Field Description public final static OptimUtilsINSTANCE
-
Method Summary
Modifier and Type Method Description final static Pair<DoubleArray, Double>fmincon(Function1<DoubleArray, Double> objFun, DoubleArray x0, DoubleArray lb, DoubleArray ub, Integer maxIter)Bound-constrained minimization using BOBYQA (derivative-free). final static Pair<Matrix, Double>quadprog(Matrix H, Matrix f, Matrix lb)Quadratic program solver with non-negative constraints. -
-
Method Detail
-
fmincon
final static Pair<DoubleArray, Double> fmincon(Function1<DoubleArray, Double> objFun, DoubleArray x0, DoubleArray lb, DoubleArray ub, Integer maxIter)
Bound-constrained minimization using BOBYQA (derivative-free). Equivalent to MATLAB's fmincon with box constraints.
- Parameters:
objFun- objective function to minimizex0- initial pointlb- lower boundsub- upper boundsmaxIter- maximum iterations- Returns:
pair of (optimal point, objective value)
-
quadprog
final static Pair<Matrix, Double> quadprog(Matrix H, Matrix f, Matrix lb)
Quadratic program solver with non-negative constraints. Solves: min 0.5 x'Hx + f'x subject to x >= lb
Uses Cholesky decomposition to convert to NNLS problem.
- Parameters:
H- positive definite Hessian matrix (n x n)f- linear term (n x 1)lb- lower bounds (n x 1), typically zeros- Returns:
solution vector (n x 1)
-
-
-
-