To include measured disturbances such as ambient temperature (Ta) and solar radiation (Qsolar) in a state-space model for an MPC in Simulink, you can try the below steps:
- In state-space representation, measured disturbances can be included in the input matrix B, specifically in the column(s) corresponding to the measured disturbance input(s).
- The state-space model takes the general form:
x˙=Ax+B_u u+B_d d
y=Cx+D_u u+D_d d
Where: x: State vector, u: Control inputs, d: Measured disturbances, y: Output vector, B_u: Input matrix for control inputs, B_d: Input matrix for disturbances, D_u, D_d: Feedthrough matrices
- Measured disturbances are included in the d-input vector. The terms B_d d and D_d d capture their influence on the system dynamics and outputs.
- Use the "State-Space" block in Simulink to represent the dynamics.
- Add disturbance inputs to the model. Ensure that these are fed into the State-Space block as part of the d-vector.
- Open the "MPC Controller Block" and go to the "Signals and Constraints" tab.
- Define the disturbance signals as "measured disturbances".
- Map these disturbances to the corresponding channels in the d-vector.
You can refer the below documentation link for more info on MPC Controller Block