TTK4115 Linear System Theory Helicopter lab assignement Eirik Worren Legernæs Christer Mathiesen October 14, 2014 1 1.1 Part I: Mathematical modeling Problem 1 To obtain the equations of motion for the pitch, elevation and travel angles we derive an analog to Newton’s second law, for rotational motion about an axis of rotation: X τ = X i r i × Fi = i X mi ri × (ac + at ) = i X mi ri × at = i X mi ri × α × ri i where τ is the torque about the given axis and α is the angular acceleration. If ri and Fi for all i lie perpendicular to the axis of rotation, then ||τ || = τz , the component along the axis of rotation. The total torque is then X i τz = X mi ri2 az = Jφ α (1) i where φ represents the axis of rotation, and Jφ the total moment of inertia around φ in a given plane of rotation. The direction of positive torque is in the following cases chosen as the direction of torque provided by Ff . 1.1.1 Pitch X τz = lp (Ff − Fb ) + lp cos(p) (Fg,b − Fg,f ) = lp Kf Vd i Jp p¨ = lp Kf Vd = L1 Vd 1 (2a) 1.1.2 Elevation X τz = lh (Ff + Fb ) cos(p) − lh (Fg,f + Fg,b ) cos(e) + lc Fg,c cos(e) i = lh Kf Vs cos(p) + g (lc mc − 2lh mp ) cos(e) Je e¨ = L2 cos(e) + L3 Vs cos(p) 1.1.3 (2b) Travel X τz = −lh cos(e) (Ff + Fb ) sin(p) = −lh Kf Vs cos(e) sin(p) i ¨ = L4 Vs cos(e) sin(p) Jλ λ 1.2 (2c) Problem 2 i) T ˙ For an equilibrium point [p, e, λ]T = [p∗ , e∗ , λ∗ ]T = [0, 0, 0]T we have [p(t), ˙ e(t), ˙ λ(t)] = T T T ¨ [0, 0, 0] for all t and hence [¨ p(t), e¨(t), λ(t)] = [0, 0, 0] for all t. Inserting in (2a) and (2b) we get the necessary input: − LL23 Vs∗ = Vd∗ 0 " # " # (3) ii) With the coordinate transformation we have p˜ p p∗ ∗ ˜ + e e = e ˜ λ λ∗ λ " and 2 Vs V∗ V˜ = ˜s + s∗ Vd Vd Vd # " # " # In the new coordinate system we can rewrite (2a)-(2c) as L1 ˜ (Vd + Vd∗ ) − p∗ p¨˜ = Jp L2 L3 e¨˜ = cos(˜ e + e∗ ) + (V˜s + Vs∗ ) cos(˜ p + p∗ ) − e∗ Je Je ¨˜ = L4 (V˜ + V ∗ ) cos(˜ e + e∗ ) sin(˜ p + p∗ ) − λ∗ λ s s Jλ (4a) (4b) (4c) iii) ¨˜ T = h(x, u). In the equilibrium ˜ T , u = (V˜s , V˜d )T and h such that (p¨˜, e¨˜, λ) Let x = (˜ p, e˜, λ) point, x0 = (0, 0, 0)T ,u0 = (0, 0)T , we have h(x0 , y0 ) = 0 and so we can linearize the system as follows: ¨= x ∂h ∂h (x0 , u0 )x + (x0 , u0 )u ∂x ∂u and the resulting linear system is then p˜¨ 0 0 0 0 e L ¨ 0 0 x + J 3 ˜ = 0 e L ∗ 4 ¨˜ V 0 0 0 λ Jλ s L1 Jp 0 u 0 (5) or simply: L1 ˜ p¨˜ = Vd = K1 V˜d Jp L3 ˜ e¨˜ = Vs = K2 V˜s Je ¨˜ = L4 V˜ ∗ p˜ = K p˜ λ 3 Jλ s 1.3 (6a) (6b) (6c) Problem 3 The physical behavior of the helicopter differs noticeably from our theoretical model. The amount of vertical thrust needed to increase the elevation angle decreases as the elevation angle increases. This is probably partially due to ground effects, causing the air pressure under the helicopter to be higher. At the equilibrium point the helicopter’s behavior was closer to that predicted by our model, but controlling it by feed forward using the joystick was still difficult. The small amount of V˜d needed to change the pitch angle by a substantial amount demanded a steady hand to avoid uncontrollable oscillations in the pitch angle. 3 1.4 Problem 4 By measurement we obtain the voltage Vs = 3.6V necessary to keep the elevation angle in equilibrium. Inserting for Vs∗ in (3) we obtain a value for the motor force constant required to compute L1 − L4 : Kf = 2 g(2lh mp − lc mc ) = 0.1990 N/V lh Vs∗ (7) Part II: Monovariable control 2.1 Problem 1 For the pitch angle we apply the PD controller V˜d = Kpp (˜ pc − p˜) − Kpd p˜˙, Kpp , Kpd > 0 (8) Inserting in (6a) we get p¨˜ = K1 Kpp (˜ pc − p˜) − K1 Kpd p˜˙ Applying the Laplace transform with zero initial conditions p˜˙ ↔ sˆ p we obtain the transfer function K1 Kpp pˆ (s) = 2 pˆc s + sK1 Kpd + K1 Kpp (9) with poles v u s1,2 u 1 1 4Kpp = − K1 Kpd ± K1 Kpd t1 − 2 2 2 K1 Kpd Adjusting Kpp and Kpd changes the pole placement, and thus the behavior of the system. 4Kpp < 1 yields real poles, but as the system is underdamped the response is poor. K1 K 2 pd 4Kpp 2 K1 Kpd = 1 yields real and equal poles at − 12 K1 Kpd . This is a critically damped system and the response only slightly better than the underdamped system. pair of complex conjugate poles. 4 4Kpp 2 K1 Kpd > 1 yields a Amplitude 1.5 1 0.5 Underdamped Critically damped Overdamped 0 0 2 4 6 8 10 Time [s] Figure 1: Step response of a critically damped vs. an underdamped/overdamped system. 1.5 1 0.5 0 −0.5 −1 Underdamped Critically damped Overdamped −1.5 −6 −5 −4 −3 −2 −1 0 Figure 2: Eigenvalues for a critically camped vs. an underdamped/overdamped system. 5 Amplitude 1.5 1 0.5 Measured Theoretical 0 0 2 4 6 8 10 Time [s] Figure 3: Step response of transfer function with simple system model vs. measured step response. 1 Amplitude 0.8 0.6 0.4 0.2 Measured Theoretical 0 0 2 4 6 8 10 Time [s] Figure 4: Step response of transfer function with updated system model vs. measured step response. 2.2 Problem 2 For the travel rate we apply the P controller ˜˙ c − λ), ˜˙ p˜c = Krp (λ Assuming p˜ = p˜c and inserting in (6c) we get 6 Krp < 0 (10) ¨˜ = K K (λ ˜˙ − λ) ˜˙ λ 3 rp Applying the Laplace transform with zero initial conditions ˜˙ ↔ sλ ˆ λ we obtain the transfer function ˆ λ K3 Krp (s) = ˆ s + K3 K3p λc (11) with pole s = −K3 Krp 1 0.9 0.8 Amplitude 0.7 0.6 0.5 0.4 0.3 0.2 Measured Theoretical 0.1 0 0 2 4 6 8 10 Time [s] Figure 5: Transfer function step response and measured step response 3 3.1 Part III: Multivariable control Problem 1 For the state vector x = (˜ p, p˜˙, e˜˙ )T , the input vector u = (V˜s , V˜d )T and chosen output T y = (˜ p, e˜˙ ) we can write (6a),(6b) in a state space formulation 7 x˙ = Ax + Bu y = Cx (12) where " # 0 1 0 0 0 1 0 0 A = 0 0 0 , B = 0 K1 , C = 0 0 1 0 0 0 K2 0 3.2 Problem 2 The controllability matrix 0 0 0 K1 0 0 0 K 0 0 0 [B AB A2 B] = 1 0 K2 0 0 0 0 0 has full rank, and the system (12) is controllable. We apply a multivariable controller u = Pr − Kx (13) with reference feed forward Pr and state feedback Kx, where K is chosen such that the state-feedback law u = −Kx minimizes the cost function J= Z ∞ (xT Qx + uT Ru) dt 0 subject to the system dynamics, for given weighting matrices Q and R. We see that diagonal matrices Q, R with diagonal entries Qi , Ri results in scaling the relative cost of xi2 by Qi and the cost of ui2 by Ri . The chosen Q and R is " # 12 0 0 0.2 0 Q = 0 0.5 0 , R = 0 0.1 0 0 10 The optimal state-feedback gain K is calculated as K = lqr(A,B,Q,R) in Matlab, with the result " # 0 0 7.0711 K= 10.9545 8.2719 0 where K = R−1 BT S, where S solves the continuous time Riccati differential equation. The reference feed forward gain P is chosen such that in theory 8 lim (˜ p, e˜˙ )T = (˜ pc , e˜˙ c )T t→∞ for a given fixed reference r0 = (˜ pc , e˜˙ c )T . Defining the state x∞ = limt→∞ x, we want x˙ ∞ = 0, and from the system (12) applied with the controller (13) we then get x∞ = (BK − A)−1 BPr0 For y∞ = Cx∞ we want y∞ = r0 for the desired convergence, and thus we derive a suitable reference feed-forward gain P: r0 = Cx∞ = C(BK − A)−1 BPr0 ↔ P = [C(BK − A)−1 B]−1 Noticing C(BK − A)−1 B as the transfer function C(sI − (A − BK))−1 B evaluated at s = σ + iω = 0 for the closed-loop system {A − BK, B, C, 0}, P is readily calculated: P = inv(evalfr(ss(A-BK,B,C,0),0)) with the resulting reference feed-forward gain " # 0 7.0711 P= 10.9545 0 »"Comment on your choice of controller design." Problem 3 0.25 Elevation rate [rad/s] 3.3 0.2 PI controller P controller 0.15 Reference input 0.1 0.05 0 9 10 11 12 13 14 15 16 Time [s] Figure 6: Elevation rate response to a step input, P vs. PI controller. 9 4 Part IV 4.1 Problem 1 4.2 Problem 2 Pitch 1 0 −1 0 5 10 15 20 25 30 20 25 30 20 25 30 Pitch rate 2 0 −2 0 5 10 15 Elevation rate 0.5 0 −0.5 0 5 10 15 Figure 7: Estimated states (blue) vs. measured states (green) for the 3-input observer, with P controller Pitch 1 0 −1 0 5 10 15 20 25 30 35 40 45 50 35 40 45 50 35 40 45 50 Pitch rate 5 0 −5 0 5 10 15 20 25 30 Elevation rate 1 0 −1 0 5 10 15 20 25 30 Figure 8: Estimated states (blue) vs. measured states (green) for the 3-input observer, with PI controller 10 4.3 Problem 3 Pitch 2 0 −2 1 2 3 4 5 6 7 8 9 10 7 8 9 10 7 8 9 10 Pitch rate 2 0 −2 1 2 3 4 5 6 Elevation rate 0.5 0 −0.5 1 2 3 4 5 6 Figure 9: Estimated states (blue) vs. measured states (green) for an aggressive 2-input observer Pitch 5 0 −5 1 2 3 4 5 6 7 8 9 10 7 8 9 10 7 8 9 10 Pitch rate 5 0 −5 1 2 3 4 5 6 Elevation rate 0.5 0 −0.5 1 2 3 4 5 6 Figure 10: Estimated states (blue) vs. measured states (green) for a lazy 2-input observer 11
© Copyright 2024