summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYanzhenXiangRobotics <xyz000327@gmail.com>2023-05-11 08:16:15 +0200
committerYanzhenXiangRobotics <xyz000327@gmail.com>2023-05-11 08:16:15 +0200
commita2b24027a2df441f8bef401bd1cd956485c896e9 (patch)
tree911c4953277cd67de0ca5cd35e8c488eae832128
parentADD: pass 26 (diff)
downloadmpc_pe-a2b24027a2df441f8bef401bd1cd956485c896e9.tar.gz
mpc_pe-a2b24027a2df441f8bef401bd1cd956485c896e9.zip
ADD: pass 27
-rw-r--r--templates/compute_tube_controller.m5
1 files changed, 5 insertions, 0 deletions
diff --git a/templates/compute_tube_controller.m b/templates/compute_tube_controller.m
index adca95d..2c567f0 100644
--- a/templates/compute_tube_controller.m
+++ b/templates/compute_tube_controller.m
@@ -8,4 +8,9 @@
function K_tube = compute_tube_controller(p,params)
% YOUR CODE HERE
+ Az = params.model.A;
+ Bz =params.model.B;
+ % Bz = [params.model.B,eye(params.model.nx)];
+ K_tube = -place(Az,Bz,p);
+ % K_tube = K(1:params.model.nu,:);
end \ No newline at end of file