Lls2qp: Difference between revisions
From TomWiki
Jump to navigationJump to search
No edit summary |
No edit summary |
||
Line 17: | Line 17: | ||
==Calling Syntax== | ==Calling Syntax== | ||
< | <source lang="matlab"> | ||
qpProb = lls2qp(Prob, IntVars) | qpProb = lls2qp(Prob, IntVars) | ||
</ | </source> | ||
==Inputs== | ==Inputs== |
Latest revision as of 08:17, 10 January 2012
Purpose
Converts an lls problem to a new problem based on the formula below. Only the objective function is affected. The
problem can be of any type with an LLS objective.
Calling Syntax
qpProb = lls2qp(Prob, IntVars)
Inputs
Input | Description |
---|---|
Prob.LS.C | The linear matrix in 0.5 * ||y - Cx||. |
Prob.LS.y | The constant vector in 0.5 * ||y - Cx||. |
Outputs
Output | Description |
---|---|
qpProb | The converted problem. |
Description
If the problem is a linear least squares problem a qp problem is created. The new problem may have integer variables. Create the problem with llsAssign then use this routine.
If the problem has nonlinear constraints an nlp is created. The new problem may have integer variables. Create the problem with conAssign or minlpAssign, the set the fields Prob.LS.C and Prob.LS.y