Design and simulate of LQR-Fuzzy controller for unicycle robot with double flywheels

. This research is focus on design and simulate unicycle robot with double flywheels model with LQR-Fuzzy controller. Roll balancing torque is generated by gyroscopic effect. Pitch balancing torque is applied by inverted pendulum concept. To control the heading of the robot, the angular momentum from both flywheel is applied to control this. The robot model is based on Euler-Lagrange equations. The non-linear model is linearization by Taylor series expansion. The simulation results conducted by MATLAB/Simulink. LQR-Fuzzy is combination algorithm between LQR and Fuzzy controller. The main structure control is the LQR controller and use the Fuzzy controller to adjust the close loop controller gain. The simulation results is simulated and compared with conventional LQR.


Introduction
Unicycle robot is a mobile robot which has only one contact point on ground. The unicycle robot dynamic model is very challenging and interesting in research topic in dynamic control. Since, model is non-linear, unstable and difficult to control. A. Schoowinkel [1] is the first one who derives unicycle dynamic model by using the turntable mechanism concept. Z. Sheng and K. Yamafuji [2], who are successful to balance the unicycle robot. The next generation of unicycle balancing is gyroscope force (flywheel). S. Majima et al [3] proposed a single-flywheel technique for balancing a unicycle robot. The produced torque from this technique is higher than the turntable technique. To generate greater torque, the double flywheel is introduced in this paper [4]. There are many control algorithms which applied to control unicycle robot. LQR is well-known and widely used controller in robot control. This paper presents the combination of LQR and Fuzzy controller. The performance of LQR-Fuzzy [5] is evaluated and compared in this paper.

Concept Design
Unicycle robot can be falling in lateral and longitudinal direction. In lateral direction, the gyro scope is the concept to generate torque. There are two flywheels with produce the rolling torque. Both of them are rotated in difference direction with high speed in order to generate angular momentum. By opposite rotating of both flywheels, there are some component of angular momentum effect from rolling torque, it can be applied to control heading of the robot.  The angular momentum vector presents in Fig.1

Robot Dynamic Model
The dynamic model of the unicycle robot is derived into two main parts: wheel and body are presented in Fig.3. The model is referred to Chantarachit, S. [4] model. Unicycle robot model is coupling model between each axis (x y and z).

Fig. 3 Wheel and Body model
The Dynamic model is derived by using Euler-Lagrange (Eq.1). Friction in the system is small and negligible.
L is the difference between total kinetic energy and potential energy. From (Eq.1), the nonlinear equation will be presented in 4 terms and rearranged in to non-linear dynamic equation. The equation of the unicycle robot is shown in (Eq. 2). M is inertia matrix. C is Coriolis matrix. G is gravity matrix, and D is disturbance matrix. Since the robot is operated at low speed, viscous friction is small and negligible (D=0).
Sin Sin )] 0.5Sin [2 ] ( 0.5Cos [2 ] Cos 0.5Cos [2 ]) The unicycle robot equation of motion is in non-linear form. Taylor series expansion method is applied to linearize robot model and rearranged to state space form as shows in (Eq.3) x Ax Bu   where: M is the symmetrical positive definite matrix of the robot inertia and evaluated at the upright position.

Control Algorithm
This section is presented the implemented control algorithm. By combination LQR with Fuzzy controller, the details presents below.

LQR Controller
The conventional LQR controller is the optimal controller that optimally determines the gains by compromising the state and control-input cost. The LQR cost function is expressed by The Q and R matrices are the state and control weighting matrices. The control signal follows (Eq. 5) The optimal gain matrix is solved by the algebraic Riccati equation (Eqs. 6-7).
The metrics Q and R are the weighting metrics which define depend on significant state. The Q matrix is combined of many states of the unicycle robot. The balancing states (roll and pitch) of the unicycle robot are set to highest priority than other states.

LQR-Fuzzy Controller
The LQR-Fuzzy applies both advantages from LQR and Fuzzy controller. LQR controller gain is optimal gain which designed by the cost function (4). It can easily satisfy the response of the system by set the priority of the Q matrix. And Fuzzy controller can handle the non-linear term of unicycle robot system. Therefore, the combination between LQR and Fuzzy controller can improve the performance of the robot. The block diagrams shows in Fig.4. The input membership function is Gaussian type. There are two numbers of membership function of each input. For example, the membership function of the roll angle is combined with two Gaussian sets. The first set is normal period angle, and another one is aggressive angle as show in Fig.5. All member ship functions are set similar to roll angle.

Fig. 5 Input of membership function
The membership function of the output is combined with three Gaussian sets: low normal and aggressive. The defuzzification output is solved by centroid concept.

Simulation results
In this section, the balancing performances of the unicycle robot are simulated and compared with convention LQR. The robot simulation is simulated by MATLAB/Simulink. In the simulation parts, there are initial conditions in each states of the robot. The results show that the robot can reject disturbances and try to convert each states to set point (zero). The comparison of LQR-Fuzzy and LQR are simulate, presents in Fig.8.

Fig. 8 Simulation results of Roll Yaw Pitch and Wheel Position
From the simulation results, the LQR-Fuzzy is designed which meets requirements by decreasing the overshoot and increasing the performance of the unicycle robot. The LQR-Fuzzy can decease the overshoot about fifty percent compares with conventional LQR.

Conclusion
In this paper, the unicycle robot model is simulated by LQR-Fuzzy controller. LQR controller is optimal control for multivariable feedback and known the good performance for linear model. Fuzzy controller ability is to deal with non-linearity of the system. The combination of both controller can increase the performance of robot.