*5.3.1 PID approximation*

In this subsection, the gain parameters *Kp*, *Ki*,*Kd* of the PID controller are calculated approximately from the feedback gain *K* of LQR controller based on

GA tuning method. For this application, analyzing Eq. (15) yields the following control effort [22]:

$$
\begin{bmatrix} u\_1 \\ u\_2 \end{bmatrix} = - \begin{bmatrix} k\_{11} & k\_{12} & k\_{13} & k\_{14} & k\_{15} & k\_{16} & k\_{17} \\ k\_{11} & -k\_{12} & k\_{13} & -k\_{14} & -k\_{15} & k\_{16} & -k\_{17} \end{bmatrix} \mathbf{x}^T \tag{41}
$$

where *xT* <sup>¼</sup> *<sup>ϵ</sup>*, *<sup>ρ</sup>*, *<sup>ϵ</sup>*\_, *<sup>ρ</sup>*\_,*r*, *<sup>ʓ</sup>*, *<sup>γ</sup>* � �*<sup>T</sup>* .

If *ϵd*, *ρ<sup>d</sup>* and *rd* are the desired pitch angle, elevation angle and travel rate of the helicopter system, it can express the form of PID controllers used to meet the desired output states as follows: [7, 8].

In this study, for elevation angle, the control equation is based on the following PID control equation:

$$W\_s = K\_{cp}e\_\epsilon + K\_{ed}\dot{e}\_\epsilon + K\_{ei} \int e\_\epsilon dt \tag{42}$$

*<sup>u</sup>*<sup>1</sup> <sup>þ</sup> *<sup>u</sup>*<sup>2</sup> ¼ �ð2*k*11*<sup>ϵ</sup>* <sup>þ</sup> <sup>2</sup>*k*13*ϵ*\_ <sup>þ</sup> <sup>2</sup>*k*16*ξ*޼� <sup>2</sup>*k*11*<sup>ϵ</sup>* <sup>þ</sup> <sup>2</sup>*k*13*ϵ*\_ <sup>þ</sup> <sup>2</sup>*k*<sup>16</sup> <sup>ð</sup>

*Vs* <sup>¼</sup> <sup>2</sup>*k*11ð Þ� *<sup>ϵ</sup><sup>d</sup>* � *<sup>ϵ</sup>* <sup>2</sup>*k*13*ϵ*\_ <sup>þ</sup> <sup>2</sup>*k*<sup>16</sup> <sup>ð</sup>

It is obvious that Eqs. (43) and (49) have the same structure, this means that the gain parameters of the pitch PID controller can be obtained from the gain elements of the LQR controller. Thus, comparing Eq. (43) with Eq. (49), yields the following

*A Hybrid Control Approach Based on the Combination of PID Control with LQR Optimal Control*

*K<sup>ϵ</sup><sup>p</sup>* ¼ 2*k*<sup>11</sup> *Kϵ<sup>d</sup>* ¼ 2*k*<sup>13</sup> *Kϵ<sup>i</sup>* ¼ 2*k*<sup>16</sup>

The block diagram of closed-loop control system for 3DOF helicopter system based on hybrid LQR-PID controller is shown in **Figure 9**. Taking Laplace trans-

form for elevation axis model Eq. (31) yields the following equation:

*Jeϵ*ð Þ*s :s*

*ϵ*ð Þ*s Vs*ð Þ*<sup>s</sup>* <sup>¼</sup> *Kcl*<sup>1</sup>

> <sup>2</sup> <sup>þ</sup> *<sup>K</sup>ϵps* <sup>þ</sup> *<sup>K</sup>ϵ<sup>i</sup> s*

> > *ϵ*ð Þ*s Vs*ð Þ*s*

<sup>2</sup> <sup>þ</sup> *<sup>K</sup>ϵps* <sup>þ</sup> *<sup>K</sup><sup>ϵ</sup><sup>i</sup> s*

<sup>2</sup> <sup>þ</sup> *Kcl*1*Kϵps* <sup>þ</sup> *Kcl*1*K<sup>ϵ</sup><sup>i</sup>*

*Jes*<sup>3</sup> þ *Kϵds*<sup>2</sup> þ *Kϵps* þ *K<sup>ϵ</sup><sup>i</sup>*

where *Eϵ*ðÞ¼ *s ϵd*ðÞ�*s ϵ*ð Þ*s ,* the open loop transfer function of the elevation axis

*<sup>E</sup>ϵ*ð Þ*<sup>s</sup>* <sup>¼</sup> *Vs*ð Þ*<sup>s</sup> Eϵ*ð Þ*s*

Based on Eqs. (52) and (53), the open loop elevation transfer function becomes:

*Kϵds*

The closed loop transfer function for elevation angle control is as follows:

The transfer function of the elevation axis plant is given by:

The transfer function of the PID controller is as follows:

*Vs*ð Þ*s <sup>E</sup>ϵ*ð Þ*<sup>s</sup>* <sup>¼</sup> *<sup>K</sup>ϵds*

*Gϵ*ðÞ¼ *s*

*ϵ*ð Þ*s*

*5.3.3 Pitch control using PD controller*

**31**

*<sup>ϵ</sup>c*ð Þ*<sup>s</sup>* <sup>¼</sup> *<sup>G</sup>ϵ*ð Þ*<sup>s</sup>*

*<sup>G</sup>ϵ*ðÞ¼ *<sup>s</sup> <sup>ϵ</sup>*ð Þ*<sup>s</sup>*

*Kcl*<sup>1</sup> *Jes*<sup>2</sup>

<sup>1</sup> <sup>þ</sup> *<sup>G</sup>ϵ*ð Þ*<sup>s</sup>* <sup>¼</sup> *Kcl*1*Kϵds*

Similarly, the difference of the rows of Eq. (41) results in

The above equation can be written as

*DOI: http://dx.doi.org/10.5772/intechopen.94907*

gain relationships:

control *Gϵ*ð Þ*s* is given by:

*<sup>ϵ</sup>dt* � � (48)

<sup>2</sup> <sup>¼</sup> *Kcl*1*Vs*ð Þ*<sup>s</sup>* (51)

*Jes*<sup>2</sup> (52)

ð Þ *ϵ<sup>d</sup>* � *ϵ dt* (49)

(50)

(53)

(54)

(55)

(56)

**Figure 8.** *LQR controller based on GA for 3DOF helicopter system.*

$$W\_s = K\_{cp}(\varepsilon\_d - \varepsilon) - K\_{ed}\dot{\varepsilon} + K\_{ci} \int (\varepsilon\_d - \varepsilon)dt\tag{43}$$

While the pitch angle is controlled by the following PD control equation:

$$V\_d = K\_{\rho p} \mathbf{e}\_{\rho} + K\_{\rho d} \dot{\mathbf{e}}\_{\rho} \tag{44}$$

$$W\_d = K\_{\rho p}(\rho\_d - \rho) - K\_{\rho d}\dot{\rho} \tag{45}$$

The travel rate is gonverned by the following PI control equation:

$$
\rho\_d = K\_{rp} e\_r + K\_{ri} \int e\_r dt \tag{46}
$$

$$
\rho\_d = K\_{rp}(r\_d - r) + K\_{ri} \int (r\_d - r)dt\tag{47}
$$

Where *e<sup>ϵ</sup>* ¼ *ϵ<sup>d</sup>* � *ϵ*,*e<sup>ρ</sup>* ¼ *ρ<sup>d</sup>* � *ρ*,*er* ¼ *rd* � *r*,*e*\_ *<sup>ϵ</sup>* ¼ �*ϵ*\_ and*e*\_ *<sup>ρ</sup>* ¼ �*ρ*\_ *.*
