MATLAB Answers

MPC Controller gives 0 as output

6 views (last 30 days)
Tan Edwin
Tan Edwin on 6 May 2011
Im using Simulink MPC Toolbox to design my MPC controller. It has successfully designed the MPC controller but it appears that the output of my MPC controller is 0 throughout, i.e. does not control at all.
my plant design is : dx(1)=-2*x(1)+k1-k4; dx(2)=5*x(1)-3*x(2)+k2-k4; dx(3)=2.5*x(2)+k3-k4; dx(4)=k1+k2+k3-k4;
so what i want to control is the states x(1) and x(4) and my manipulated variable is k1, k2 and k3.
Currently the simulink mpc block has successfully self linearize and design my controller, just that the output is 0 anyone noe the reason?


Tan Edwin
Tan Edwin on 6 May 2011
im using a lvl1 S-function to code my ODEs
Tan Edwin
Tan Edwin on 6 May 2011
and when i set it to one input and one output it works fine, i.e control x(1) by changing k1
Rong on 6 May 2011
More information is needed. Please provide the A,B,C,D matrices plus the signal definitions such as MV, MD, UD, OV and UO (see “setmpcsignals” command) and MPC settings such as sample time, horizons, weights and constraints.

Sign in to comment.

Answers (1)

Tan Edwin
Tan Edwin on 9 May 2011
Hi Rong
I actually using simulink to auto design my MPC controller and this is what i get:
Linearization Result:
- To plot the response of this result click on the node labeled Custom Views.
- To export the result click on the Export To Workspace button below.
d =
u1 u2 u3
y1 0 0 0
y2 0 0 0
Static gain.
State Names:
Input Channel Names:
u1 - MPC Controller (1)
u2 - MPC Controller (2)
u3 - MPC Controller (3)
Output Channel Names:
y1 - Mux1 (1)
y2 - Mux1 (2)
Sampling time: 0.1, Prediction Horizon: 10, Control Horizon: 2
Plant: [2x3 ss]
Nominal: [1x1 struct]
Disturbance: []
Noise: []
Output disturbance model: default method (type "getoutdist(MPC1)" for details)
Details on Plant model:
3 manipulated variables -->| 0 states |
| |--> 2 measured outputs
0 measured disturbances -->| 3 inputs |
| |--> 0 unmeasured outputs
0 unmeasured disturbances -->| 2 outputs |
ManipulatedVariables: [0 0 0]
ManipulatedVariablesRate: [0.1000 0.1000 0.1000]
OutputVariables: [1 1]
ECR: 100000
0 <= u1<= 0.1, u1/rate is unconstrained,
0.00115 <= y1 <= 0.00125
0 <= u2<= 0.1, u2/rate is unconstrained,
0.03 <= y2 <= 0.08
0 <= u3<= 0.1, u3/rate is unconstrained
im new to MPC so not sure if this is what u need? Thanks

  1 Comment

Tan Edwin
Tan Edwin on 9 May 2011
i think there is somthing to do with the linearization part but it is atuo designed by Simulink so how should i change it to get results?

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!