Home > mpt > solvers > mpt_mpqp.m

# mpt_mpqp

## PURPOSE

MPT_MPQP Explicitly solves the given quadratic program (QP)

## SYNOPSIS

function [Pn,Fi,Gi,activeConstraints,Phard,details]=mpt_mpqp(Matrices,Options)

## DESCRIPTION

```MPT_MPQP Explicitly solves the given quadratic program (QP)

[Pn,Fi,Gi,activeConstraints,Phard,details]=mpt_mpqp(Matrices,Options)

---------------------------------------------------------------------------
DESCRIPTION
---------------------------------------------------------------------------
Solves the following QP as a multiparametric program:
min_U  0.5 U' H U + (x(0)' F + Cf) U + x(0)' Y x(0) + Cx x + Cc
subj. to  GU <= W + Ex     (constraints)
bndA*x<= bndb       (bound exploration space)
---------------------------------------------------------------------------
INPUT
---------------------------------------------------------------------------
Matrices - a struct with all the parameters which are needed.
See description above for explanation.
Matrices.G=G;
Matrices.E=E;
Matrices.W=W;
Matrices.H=H;
Matrices.F=F;
Matrices.Y=Y;
Matrices.Cf=Cf;
Matrices.Cx=Cx;
Matrices.Cc=Cc;
Matrices.bndA=bndA;
Matrices.bndb=bndb;

Options.verbose     - Optional: level of verbosity
Options.lpsolver    - Optional: which LP solver to use (help mpt_solveLP)
Options.qpsolver    - Optional: which QP solver to use (help mpt_solveQP)
Options.step_size   - Optional: length of step over a facet; Making this
value larger often mitigates numerical problems but
may produce small gaps in the partition.
Default is 1e-4;

Options.debug_level
Due to numerical problems tiny regions are sometimes difficult to
calculate, i.e. are not identified at all. This may create "gaps"
in the computed control law. For the exploration, these will be
jumped over and the exploration in the state space will continue.
"debug_level" can have three values:

0: No debug done
1: A tolerance is given to find gap in the region partition,
small empty regions inside the region partition will be discarded.
Note that this is generally not a problem, since the feedback law
is continuous and can therefore be interpolated easily.
Correction to the calculation of the outer hull.
2: Zero tolerance to find gap in the region partition, empty regions
if they exist, will be detected, i.e. the user will be notified.
Correction to the calculation of the outer hull.

Options.zero_tol    - everything below this value is considered zero
(default is 1e-13)

Note: If Options is missing or some of the fiels are not defined, the default
values from mptOptions will be used

---------------------------------------------------------------------------
OUTPUT
---------------------------------------------------------------------------
Pn,Fi,Gi           - for region Pn(i) the optimal input is U=Fi{i}*x+Gi{i}
activeConstraints  - Cell Array which stores the active constraints
of the optimizer in each region.
Phard              - The set of feasible states (i.e. union of
all regions) as Phard.H*x<=Phard.K
details            - structure with fields Ai, Bi, Ci in which the value
function associated to each region is stored
V = x' Ai{i} x + Bi{i} x + Ci{i}

## CROSS-REFERENCE INFORMATION

This function calls:
• length LENGTH Returns number of regions over which the explicit control law is defined
• set SET Set a field of MPTCTRL objects
• bounding_box BOUNDING_BOX Compute a bounding box for a given polytope
• chebyball CHEBYBALL Computes center and radius of the largest ball inscribed in a polytope
• double DOUBLE Function used to access internal properties of the given polytope
• end END Returns the last element in a given polytope array
• facetcircle FACETCIRCLE Returns largest circle inside facet 'ind' of polytope P
• intersect INTERSECT Intersection of 2 polytopes or polytope arrays
• isfulldim ISFULLDIM Checks if a polytope is full dimensional
• isinside ISINSIDE Checks if a given point lies in the interior of a given polytope
• length LENGTH Returns number of elements in a polytope array
• nconstr NCONSTR Returns number of constraints that form an H-representation of a polytope
• polytope POLYTOPE Default constructor for the POLYTOPE object
• reduce REDUCE Reduces the polytope by removing redundant inequalities
• set SET Used to modify internal properties of a given polytope object
• size SIZE Returns size of the given polytope object
• union UNION convex union computation
• unique UNIQUE Removes redundant entries from a polytope array
• mpt_error MPT_ERROR Function called if MPT toolbox is not initialized
• mpt_getFullRankSubset MPT_GETFULLRANKSUBSET Removes rows from matrix Gt until it has full row rank
• mpt_iscombequal MPT_ISCOMBEQUAL Are two vectors combinatorially equal
• mpt_statusbar Status bar function
• mpt_solveQP MPT_SOLVEQP Interface to various QP solvers
This function is called by:
• mpt_maxCtrlSet MPT_MAXCTRLSET Computes the maximal robust control invariant set C_inf
• mpt_iterative MPT_ITERATIVE Computes a time-optimal or low-complexity explicit controller for LTI systems
• mpt_iterativePWA MPT_ITERATIVEPWA Computes a time-optimal or low-complexity explicit controller for PWA systems
• mpt_mixedMinTime MPT_MIXEDMINTIME Computes minimum time controller for systems with discrete and continuous inputs
• mpt_optControl MPT_OPTCONTROL Solves the CFTOC problem for a given LTI system

Generated on Thu 30-Mar-2006 10:26:47 by m2html © 2003