Professional Documents
Culture Documents
After some time (which will be proportional to the prediction horizon length) you will be
presented with graphs of output and input variables:
5
Output and reference
-5
-10
0 100 200 300 400 500 600 700 800 900 1000
0.2
Input and constraints
0.1
-0.1
-0.2
100 200 300 400 500 600 700 800 900 1000
Time (sample number)
Step 3: Now re-do the exercise while changing length of the prediction horizon (from 1
to 10) and control weighting (from 1 to 10000) and observe how the responses of output
and input variables change.
For example:
y=MPC_Tutorial(1,1000);
y=MPC_Tutorial(5,1000);
y=MPC_Tutorial(10,1000);