@@ -84,10 +84,9 @@ These are the integrating states for the unmeasured plant disturbances, and they
8484automatically added to the model outputs by default if feasible (see [ ` SteadyKalmanFilter ` ] ( @ref )
8585for details).
8686
87- [ ^ 1 ] : We could have use an [ ` InternalModel ` ] ( @ref ) structure with
88- ` mpc = LinMPC(InternalModel(model), Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1]) ` to avoid
89- state estimator design. It was tested on the example of this page and it gives similar
90- results.
87+ [ ^ 1 ] : To avoid observer design, we could have use an [ ` InternalModel ` ] ( @ref ) structure with
88+ ` mpc = LinMPC(InternalModel(model), Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1]) ` . It was
89+ tested on the example of this page and it gives similar results.
9190
9291Before closing the loop, we call [ ` initstate! ` ] ( @ref ) with the actual plant inputs and
9392measurements to ensure a bumpless transfer. Since ` model ` simulates our plant here, its
@@ -165,10 +164,9 @@ real-life control problems. Constructing a [`LinMPC`](@ref) with `DAQP` and inpu
165164
166165``` @example 1
167166using JuMP, DAQP
168- daqp = Model(DAQP.Optimizer)
169- estim = SteadyKalmanFilter(model, nint_u=[1, 1], nint_ym=[0, 0])
170- mpc2 = LinMPC(estim, Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1], optim=daqp)
171- mpc2 = setconstraint!(mpc2, ymin=[45, -Inf])
167+ daqp = Model(DAQP.Optimizer)
168+ mpc2 = LinMPC(model, Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1], optim=daqp, nint_u=[1, 1])
169+ mpc2 = setconstraint!(mpc2, ymin=[45, -Inf])
172170```
173171
174172leads to similar computational times, but it does accelerate the rejection of the load
@@ -212,7 +210,7 @@ model_ff = setop!(LinModel(sys_ff, Ts, i_d=[3]), uop=[20, 20], yop=[50, 30], dop
212210A [ ` LinMPC ` ] ( @ref ) controller is constructed on this model:
213211
214212``` @example 1
215- mpc_ff = LinMPC(model_ff, Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1])
213+ mpc_ff = LinMPC(model_ff, Hp=15, Hc=2, Mwt=[1, 1], Nwt=[0.1, 0.1], nint_u=[1, 1] )
216214mpc_ff = setconstraint!(mpc_ff, ymin=[45, -Inf])
217215```
218216
0 commit comments