diff options
author | Nao Pross <np@0hm.ch> | 2024-05-28 23:57:56 +0200 |
---|---|---|
committer | Nao Pross <np@0hm.ch> | 2024-05-28 23:57:56 +0200 |
commit | 9ee6d53808034c6fa342b636e4858184120d8117 (patch) | |
tree | e6e71ac85bbf450d988af14c4fb1490ead23d1d5 /uav_uncertainty.m | |
parent | Fix assumption checks in uav_model (diff) | |
download | uav-9ee6d53808034c6fa342b636e4858184120d8117.tar.gz uav-9ee6d53808034c6fa342b636e4858184120d8117.zip |
Tune state uncertainty
Diffstat (limited to 'uav_uncertainty.m')
-rw-r--r-- | uav_uncertainty.m | 29 |
1 files changed, 21 insertions, 8 deletions
diff --git a/uav_uncertainty.m b/uav_uncertainty.m index 53cd975..7cd7e38 100644 --- a/uav_uncertainty.m +++ b/uav_uncertainty.m @@ -28,27 +28,40 @@ eps_d = params.aerodynamics.DragCoefficientsUncertainties(1); eps_omega = max(.5 * eps_T, eps_r); eps_alpha = max(eps_l + eps_S + 2 * eps_omega, eps_S + eps_d + eps_omega); -b = 10; -G_highpass = make_weight(b, 1, .1); +b = 12; +G = make_weight(b, 2, .2); -W_malpha = eps_alpha * G_highpass; -W_momega = eps_omega * G_highpass; -W_mState = .1 * G_highpass; +W_malpha = .1 * eps_alpha * G; +W_momega = .1 * eps_omega * G; +W_mState = blkdiag( ... + .05 * tf(1) * eye(3), ... + .01 * tf(1) * eye(3), ... + .001 * tf(1) * eye(3), ... + .05 * tf(1) * eye(3) ... +); uncert = struct(... + 'FlapAngleEpsilon', eps_alpha, ... + 'ThrustEpsilon', eps_omega, ... 'FlapAngle', W_malpha * eye(4), ... 'Thrust', W_momega, ... - 'StateLinApprox', W_mState * eye(12)); + 'StateLinApprox', W_mState); if do_plots % Bode plots of performance requirements figure; hold on; bodemag(W_malpha); bodemag(W_momega); - bodemag(W_mState); + + bodemag(W_mState(1,1)); + bodemag(W_mState(4,4)); + bodemag(W_mState(7,7)); + bodemag(W_mState(11,11)); grid on; - legend('$W_{m,\alpha}$', '$W_{m,\omega}$', '$W_{m,\mathbf{P}}$', ... + legend('$W_{m,\alpha}$', '$W_{m,\omega}$', ... + '$W_{m,\mathbf{P}}$', '$W_{m,\mathbf{\dot{P}}}$', ... + '$W_{m,\mathbf{\Theta}}$', '$W_{m,\mathbf{\Omega}}$', ... 'interpreter', 'latex') title('\bfseries Stability Requirement (only for $\mu$-Synthesis)', ... 'interpreter', 'latex') |