mpcstate
MPC controller state
Description
An mpcstate
object is a handle object pointing to the current
state of an implicit or explicit MPC controller. Use an mpcstate
object to
initialize and hold the current controller state within a MATLAB® simulation.
The controller state includes the:
States of the plant, disturbance, and noise models. These are the states of the built-in state estimator. For more information, see Controller State Estimation.
Manipulated variables used in the previous control interval.
State covariance matrix of the state estimator.
Before simulation, use mpcstate
to obtain a handle object and, if needed,
set the initial condition of the controller state. By default the initial controller state is
set to the nominal values specified in the related mpc
object.
During simulation, the controller move function (mpcmove
, mpcmoveExplicit
, mpcmoveAdaptive
or mpcmoveMultiple
), also updates the controller
state when calculating a new control move. If you use built-in state estimation, then you do
not need to modify the controller state at all. If you use custom state estimation then you
must use the handle object to provide current states for the plant, disturbance, and noise
models, before calling the controller move function.
After the simulation, the handle object reflects the state of the controller at the end of the simulation. For more information about handle objects, see Handle Object Behavior.
Creation
Description
sets the Properties of the
state object to specified nondefault values. To leave a specific property to its default
value, set the corresponding input argument to xc
= mpcstate(mpcobj
,plant
,disturbance
,noise
,lastMove
,covariance
)[]
.
Input Arguments
Output Arguments
Properties
Object Functions
mpcmove | Compute optimal control action and update controller states |
mpcmoveAdaptive | Compute optimal control with prediction model updating |
mpcmoveMultiple | Compute gain-scheduling MPC control action at a single time instant |
mpcmoveExplicit | Compute optimal control using explicit MPC |
Examples
Version History
Introduced before R2006a
See Also
Functions
getoutdist
|setoutdist
|setindist
|getindist
|getEstimator
|setEstimator
|mpcmove
|mpcmoveAdaptive
|mpcmoveMultiple
|mpcmoveExplicit