diff options
author | Nao Pross <np@0hm.ch> | 2024-05-24 11:06:18 +0200 |
---|---|---|
committer | Nao Pross <np@0hm.ch> | 2024-05-24 11:06:18 +0200 |
commit | 1c844e165055fca5253ed885af8c036619e9fef0 (patch) | |
tree | ba53c8b6560b8189a52131fe69a9616f4c8e0b53 /uav_performance_musyn.m | |
parent | Update DK-iteration and clean up (diff) | |
download | uav-1c844e165055fca5253ed885af8c036619e9fef0.tar.gz uav-1c844e165055fca5253ed885af8c036619e9fef0.zip |
Add more checks, update DK iteration
Diffstat (limited to '')
-rw-r--r-- | uav_performance_musyn.m | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/uav_performance_musyn.m b/uav_performance_musyn.m index aba2160..57237fa 100644 --- a/uav_performance_musyn.m +++ b/uav_performance_musyn.m @@ -19,30 +19,30 @@ function [perf] = uav_performance_musyn(params, do_plots) s = tf('s'); % Bandwitdhs -bw_alpha = params.actuators.ServoNominalAngularVelocity; -bw_omega = 10; +bw_alpha = .7 * params.actuators.ServoNominalAngularVelocity; +bw_omega = 8; -bw_xy = .05; -bw_z = .05; +bw_xy = .1; +bw_z = .4; bw_xydot = .5; bw_zdot = .1; -bw_phitheta = .1; +bw_phitheta = bw_xy; bw_psi = .08; % Inverse performance functions -W_Palpha = .2 / (s / bw_alpha + 1); -W_Pomega = .2 / (s / bw_omega + 1); +W_Palpha = .25 / (s / bw_alpha + 1); +W_Pomega = .1 / (s / bw_omega + 1); -W_Pxy = 8 * bw_xy^2 / (s^2 + 2 * 1 * bw_xy * s + bw_xy^2); -W_Pz = 1 * bw_z^2 / (s^2 + 2 * 1 * bw_z * s + bw_z^2); +W_Pxy = 2 * bw_xy^2 / (s^2 + 2 * .9 * bw_xy * s + bw_xy^2); +W_Pz = bw_z^2 / (s^2 + 2 * 1 * bw_z * s + bw_z^2); -W_Pxydot = .2 / (s / bw_xydot + 1); -W_Pzdot = .5 / (s / bw_zdot + 1); +W_Pxydot = tf(.1); % .2 / (s / bw_xydot + 1); +W_Pzdot = tf(.1); % .5 / (s / bw_zdot + 1); -W_Pphitheta = 1 / (s / bw_phitheta + 1); -W_Ppsi = .1 / (s / bw_psi + 1); +W_Pphitheta = .01 / (s / bw_phitheta + 1); +W_Ppsi = tf(.1); % .1 / (s / bw_psi + 1); % Construct performance vector by combining xy and z W_PP = blkdiag(W_Pxy * eye(2), W_Pz); @@ -60,14 +60,14 @@ if do_plots % Bode plots of performance requirements figure; hold on; - bodemag(W_Palpha); - bodemag(W_Pomega); - bodemag(W_Pxy); - bodemag(W_Pz); - bodemag(W_Pxydot); - bodemag(W_Pzdot); - bodemag(W_Pphitheta); - bodemag(W_Ppsi); + bodemag(1/W_Palpha); + bodemag(1/W_Pomega); + bodemag(1/W_Pxy); + bodemag(1/W_Pz); + bodemag(1/W_Pxydot); + bodemag(1/W_Pzdot); + bodemag(1/W_Pphitheta); + bodemag(1/W_Ppsi); grid on; legend('$W_{P,\alpha}$', '$W_{P,\omega}$', ... @@ -75,7 +75,8 @@ if do_plots '$W_{P,\dot{x}\dot{y}}$', '$W_{P,\dot{z}}$', ... '$W_{P,\phi\theta}$', '$W_{P,\psi}$', ... 'interpreter', 'latex', 'fontSize', 8); - title('Performance Requirements'); + title('\bfseries Inverse Performance Requirements', ... + 'interpreter', 'latex'); % Step response of position requirements figure; hold on; |