@@ -4,43 +4,43 @@ Ts = 4.0
44model = setop! (LinModel (sys, Ts), uop= [10 , 10 ], yop= [50 , 30 ])
55y = model ()
66
7- mpc_im = setconstraint! (LinMPC (InternalModel (model)), ŷmin = [45 , - Inf ])
7+ mpc_im = setconstraint! (LinMPC (InternalModel (model)), ymin = [45 , - Inf ])
88initstate! (mpc_im, model. uop, y)
99mpc_im. estim ([50 , 30 ])
1010u = mpc_im ([55 , 30 ], ym= y)
1111sim! (mpc_im, 3 )
1212
13- mpc_kf = setconstraint! (LinMPC (KalmanFilter (model)), ŷmin = [45 , - Inf ])
13+ mpc_kf = setconstraint! (LinMPC (KalmanFilter (model)), ymin = [45 , - Inf ])
1414initstate! (mpc_kf, model. uop, model ())
1515mpc_kf. estim ()
1616u = mpc_kf ([55 , 30 ])
1717sim! (mpc_kf, 3 , [55 , 30 ])
1818
19- mpc_lo = setconstraint! (LinMPC (Luenberger (model)), ŷmin = [45 , - Inf ])
19+ mpc_lo = setconstraint! (LinMPC (Luenberger (model)), ymin = [45 , - Inf ])
2020initstate! (mpc_lo, model. uop, model ())
2121mpc_lo. estim ()
2222u = mpc_lo ([55 , 30 ])
2323sim! (mpc_lo, 3 , [55 , 30 ])
2424
25- mpc_ukf = setconstraint! (LinMPC (UnscentedKalmanFilter (model)), ŷmin = [45 , - Inf ])
25+ mpc_ukf = setconstraint! (LinMPC (UnscentedKalmanFilter (model)), ymin = [45 , - Inf ])
2626initstate! (mpc_ukf, model. uop, model ())
2727mpc_ukf. estim ()
2828u = mpc_ukf ([55 , 3 ])
2929sim! (mpc_ukf, 3 , [55 , 30 ])
3030
31- mpc_ekf = setconstraint! (LinMPC (ExtendedKalmanFilter (model)), ŷmin = [45 , - Inf ])
31+ mpc_ekf = setconstraint! (LinMPC (ExtendedKalmanFilter (model)), ymin = [45 , - Inf ])
3232initstate! (mpc_ekf, model. uop, model ())
3333mpc_ekf. estim ()
3434u = mpc_ekf ([55 , 30 ])
3535sim! (mpc_ekf, 3 , [55 , 30 ])
3636
37- mpc_skf = setconstraint! (LinMPC (SteadyKalmanFilter (model)), ŷmin = [45 , - Inf ])
37+ mpc_skf = setconstraint! (LinMPC (SteadyKalmanFilter (model)), ymin = [45 , - Inf ])
3838initstate! (mpc_skf, model. uop, model ())
3939mpc_skf. estim ()
4040u = mpc_skf ([55 , 30 ])
4141sim! (mpc_skf, 3 , [55 , 30 ])
4242
43- nmpc_skf = setconstraint! (NonLinMPC (SteadyKalmanFilter (model), Cwt= Inf ), ŷmin = [45 , - Inf ])
43+ nmpc_skf = setconstraint! (NonLinMPC (SteadyKalmanFilter (model), Cwt= Inf ), ymin = [45 , - Inf ])
4444initstate! (nmpc_skf, model. uop, model ())
4545nmpc_skf. estim ()
4646u = nmpc_skf ([55 , 30 ])
@@ -59,17 +59,17 @@ h(x,_) = model.C*x
5959
6060nlmodel = setop! (NonLinModel (f, h, Ts, 2 , 2 , 2 ), uop= [10 , 10 ], yop= [50 , 30 ])
6161y = nlmodel ()
62- nmpc_im = setconstraint! (NonLinMPC (InternalModel (nlmodel), Cwt= Inf ), ŷmin = [45 , - Inf ])
62+ nmpc_im = setconstraint! (NonLinMPC (InternalModel (nlmodel), Cwt= Inf ), ymin = [45 , - Inf ])
6363initstate! (nmpc_im, nlmodel. uop, y)
6464u = nmpc_im ([55 , 30 ], ym= y)
6565sim! (nmpc_im, 3 , [55 , 30 ])
6666
67- nmpc_ukf = setconstraint! (NonLinMPC (UnscentedKalmanFilter (nlmodel), Cwt= Inf ), ŷmin = [45 , - Inf ])
67+ nmpc_ukf = setconstraint! (NonLinMPC (UnscentedKalmanFilter (nlmodel), Cwt= Inf ), ymin = [45 , - Inf ])
6868initstate! (nmpc_ukf, nlmodel. uop, y)
6969u = nmpc_ukf ([55 , 30 ])
7070sim! (nmpc_ukf, 3 , [55 , 30 ])
7171
72- nmpc_ekf = setconstraint! (NonLinMPC (ExtendedKalmanFilter (model), Cwt= Inf ), ŷmin = [45 , - Inf ])
72+ nmpc_ekf = setconstraint! (NonLinMPC (ExtendedKalmanFilter (model), Cwt= Inf ), ymin = [45 , - Inf ])
7373initstate! (nmpc_ekf, model. uop, model ())
7474u = nmpc_ekf ([55 , 30 ])
7575sim! (nmpc_ekf, 3 , [55 , 30 ])
0 commit comments