From 245e7f58131d1885adde4850f8825bfe87d843c6 Mon Sep 17 00:00:00 2001 From: mrgransky <farid.alijani@student.lut.fi> Date: Tue, 27 Sep 2016 22:25:48 +0200 Subject: [PATCH] Trajectoiry nice --- .../docking_with_PID_controller.m | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Files_4_thesis/Different_controllers/docking_with_PID_controller.m b/Files_4_thesis/Different_controllers/docking_with_PID_controller.m index 3357a359..63a4cd75 100644 --- a/Files_4_thesis/Different_controllers/docking_with_PID_controller.m +++ b/Files_4_thesis/Different_controllers/docking_with_PID_controller.m @@ -232,8 +232,8 @@ ref_Pose_data_3 =[ref_X_data_3;ref_Y_data_3]; %data 4: % when using marker pose ,,,, Pose_X_data_4 = Pose_Matrix_data_4(:,4); -Pose_Y_data_4 = Pose_Matrix_data_4(:,3); -Theta_data_4 = Pose_Matrix_data_4(:,7); +Pose_Y_data_4 = abs(Pose_Matrix_data_4(:,3)); +Theta_data_4 = -abs(Pose_Matrix_data_4(:,7)); % Extracting reference values when the robot is manually docked! @@ -320,7 +320,7 @@ plot(t_P_sec_data_3,Pose_X_data_3,'g','LineWidth',2.3); title('Pose estimation in marker coordinate system'); ylabel('${x_{mar}}$ [m]','interpreter','latex','FontSize',14); -l2 = legend('${P_y = 0.31, I_y = 0.00065, D_y = 0.071}$', '${P_y = 0.38, I_y = 0.0001, D_y = 0.02}$','${P_y = 0.38, I_y = 0, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); +l2 = legend('${P_y = 0.28, I_y = 0.0001, D_y = 0.01}$', '${P_y = 0.29, I_y = 0.00026, D_y = 0.015}$','${P_y = 0.3, I_y = 0.0004, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); set(l2,'interpreter','latex','FontSize',11); legend('boxoff'); @@ -333,7 +333,7 @@ plot(t_P_sec_data_3,Pose_Y_data_3,'g','LineWidth',2.3); % hold on % plot(t_P_sec_data_4,Pose_Y_data_4,'m','LineWidth',1.6); ylabel('${y_{mar}}$ [m]','interpreter','latex','FontSize',14); -axis([0 80 -.1 .67]) +% axis([0 80 -.1 .67]) subplot(3,1,3); plot(t_P_sec_data_1,Theta_data_1,'LineWidth',3); hold on @@ -363,7 +363,7 @@ title('Control Signals'); ylabel('$\dot{x}_{Rob}$ [m/s]','interpreter','latex','FontSize',14); axis([0 45 -.01 .2]); -l2 = legend('${P_y = 0.31, I_y = 0.00065, D_y = 0.071}$', '${P_y = 0.38, I_y = 0.0001, D_y = 0.02}$','${P_y = 0.38, I_y = 0, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); +l2 = legend('${P_y = 0.28, I_y = 0.0001, D_y = 0.01}$', '${P_y = 0.29, I_y = 0.00026, D_y = 0.015}$','${P_y = 0.3, I_y = 0.0004, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); set(l2,'interpreter','latex','FontSize',11); legend('boxoff'); @@ -482,7 +482,7 @@ plot(y_circle,x_circle,'k--','LineWidth',3.4); title('Target area'); % axis([0.0065 .0095 .1995 .2055]); -l = legend('${P_y = 0.31, I_y = 0.00065, D_y = 0.071}$', '${P_y = 0.38, I_y = 0.0001, D_y = 0.02}$','${P_y = 0.38, I_y = 0, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); +l = legend('${P_y = 0.28, I_y = 0.0001, D_y = 0.01}$', '${P_y = 0.29, I_y = 0.00026, D_y = 0.015}$','${P_y = 0.3, I_y = 0.0004, D_y = 0.02}$','${P_y = 0.39, I_y = 0.0005, D_y = 0.01}$'); set(l,'interpreter','latex','FontSize',11); % legend('boxoff'); -- GitLab