Computers, Materials & Continua DOI:10.32604/cmc.2022.022993 | |
Article |
Intelligent Dynamic Inversion Controller Design for Ball and Beam System
1Department of Electrical and Computer Engineering (ECE), King Abdulaziz University, Jeddah, 21589, Saudi Arabia
2Center of Excellence in Intelligent Engineering Systems (CEIES), King Abdulaziz University, Jeddah, 21589, Saudi Arabia
3Electrical and Computer Engineering, Electrical and Computer Engineering, TN, 38505, United States
4Computer and Information Systems, Umm Al-Qura University, Makkah, Saudi Arabia
*Corresponding Author: Ibrahim M. Mehedi. Email: imehedi@kau.edu.sa
Received: 25 August 2021; Accepted: 20 December 2021
Abstract: The Ball and beam system (BBS) is an attractive laboratory experimental tool because of its inherent nonlinear and open-loop unstable properties. Designing an effective ball and beam system controller is a real challenge for researchers and engineers. In this paper, the control design technique is investigated by using Intelligent Dynamic Inversion (IDI) method for this nonlinear and unstable system. The proposed control law is an enhanced version of conventional Dynamic Inversion control incorporating an intelligent control element in it. The Moore-Penrose Generalized Inverse (MPGI) is used to invert the prescribed constraint dynamics to realize the baseline control law. A sliding mode-based intelligent control element is further augmented with the baseline control to enhance the robustness against uncertainties, nonlinearities, and external disturbances. The semi-global asymptotic stability of IDI control is guaranteed in the sense of Lyapunov. Numerical simulations and laboratory experiments are carried out on this ball and beam physical system to analyze the effectiveness of the controller. In addition to that, comparative analysis of RGDI control with classical Linear Quadratic Regulator and Fractional Order Controller are also presented on the experimental test bench.
Keywords: Ball and beam system (BBS); unstable system; internal model; PD controllers; IDI control; robust control
The ball and beam system (BBS) is a standard laboratory experimental setup and serves as an essential benchmark to investigate and validate the performance of various control strategies [1]. The tilt angle of the beam is the most significant action through which the ball position is controlled systematically by varying the tilt angle. It is an under-actuated open-loop unstable system having two degrees of freedom. The fundamental idea of BBS can be applied to a wide range of applications such as stabilizing the aircraft in its horizontal position while landing, tanker on-road carrying liquid, aircraft yaw roll control, goods handling problem by industrial robots, etc.
The control of an under-actuated system is an active research field having fewer control inputs than the state variables that need to be controlled. The experimental setup of BBS deals with the two loops control strategy. The outer loop is responsible for ball position control, whereas the inner loop is engaged for servo angle control. Due to its double loop control strategies, it is not easy to control this system using linear controllers [2]. Therefore, several control techniques are proposed in the literature to investigate the tracking and stabilization problem of BBS [3–5].
A feedback linearization method is applied for BBS, which produces singularity and does not produce good results [3]. A Fuzzy-based controller is investigated in [6], showing the tracking performance numerically without implementing it on a practical testbed. The Fuzzy and Neural Networks based algorithms are presented in [7,8]. The robust control technique based on the sliding mode approach is also investigated for the ball balancing problem, see [9,10]. A Backstepping controller is designed in [11] to simulate the tracking problem of BBS. An anti-windup compensator (AWC) control scheme is also demonstrated in [12]. Similarly, the optimal performance of Model Predictive Control (MPC) is investigated to evaluate the tracking characteristics for ball and beam equipment [5].
Recent work was proposed designing a controller comprising two embedded loops based on linear fractional-order calculus [2]. The outer-loop and inner-loop control the ball's location on the beam and angle of servo gear, respectively. The prime focus of this method of control is to demonstrate a fractional-order control scheme to enhance efficiency, which is reported in several journals [13–17]. However, the performance is unsatisfactory because an integer order traditional controller is related to the non-integer order integrator, which is used in the outer loop.
In addition to that, Nonlinear Dynamic Inversion (NDI) was also implemented for this ball and beam underactuated system, see [18]. However, this control method requires the exact model of the plant dynamics.
Therefore, NDI control may possess certain shortcomings and limitations while developing the algorithms. This includes the simplified approximations to introduce the inverse model of plant dynamics, square dimensionality condition, useful nonlinearity cancellations, etc.
Recently a control law focused on the inversion principle is proposed known as Generalized Dynamic Inversion (GDI), which addresses the limitations of the classical NDI approach [19]. The control objectives of GDI are defined in the form of differential state constraints which are calculated along the solution paths of the system dynamics. The control law is obtained by inverting the suggested constraints using Moore-Penrose Generalized Inverse (MPGI) [20]. Further, the GDI algorithm is made intelligent by augmenting the switching term based on the concept of classical SMC principle to ensure robustness against parametric uncertainties and un-modeled dynamics while guaranteeing semi-global asymptotic stability conditions [21–25].
A two-loop control architecture is employed in this paper to solve the tracking and stabilization problem for two degrees of freedom under actuated BBS. A proportional derivative (PD) control is implemented in the outer loop to generate rotary servo angle commands based on the ball position on the beam. An intelligent version of GDI, Intelligent Dynamic Inversion (IDI), is used to process the inner loop's angular command. Identical (baseline) control and switching (continuous) control elements make up this IDI control system. The baseline control enforces the constraint dynamics based on the deviation function of the rotary servo angle for stable attitude tracking, while the switching control ensures robustness against nonlinearities and external perturbations. As a result, the proposed control guaranteed a semi-global attitude tracking system and bounded tracking errors. Quanser's BBS is used to simulate and perform laboratory experiments on the controller performance and compare the controller performance to existing control strategies.
The remaining sections of the paper are described as follows. The modeling of BBS is presented in Section 2. The two-loop control structure is discussed in Section 3. The classical PD control design for the outer position loop is presented in Section 4. The design implementation of IDI control for tracking the servo angle command is given in Section 5. The detailed stability analysis that will guarantee semi-global asymptotic stability was illustrated in Section 6. Controller validation through computer simulations and experimental findings are reported in Sections 7 and 8. Finally, the concluding remarks are given in Section 9.
Quanser developed BBS, a benchmark laboratory test bench [1], to validate control algorithms that are defined relative degrees with nonlinear attributes. The two significant ball and beam setup components are the ball and beam unit and rotary servo unit. One end of the finite length beam is fixed by a shaft, whereas the other end is connected to the rotary servo unit, as shown in the schematic diagram in Fig. 1. Therefore, this unstable architecture is well known as an open-loop system in control technology. The core objective is to orient and stabilize the ball placed on the beam according to the commanded reference input profile. In Fig. 1, x is the linear displacement ball, mbis the mass, rbis the beam's radius, and Jbis the ball's momentum, respectively. The relative angle of the beam concerning the horizontal plane is denoted by α, whereas the gravitational acceleration is mentioned by g. The expression of the linear acceleration of the ball is given as Eq. (1).
Similarly, the relation between the beam angle α and servo angle θl(t) is expressed as
where Lbeamis the length of the beam and rarmis the gap between the rotary servo output gear and the coupled joint. To relate the linear displacement x with the rotary servo angle θ, place the expression of sinα(t) in the linear acceleration equation given by Eq. (2), it implies
The second major component of the ball and beam setup is the rotary servo base unit which comprises a DC motor with a gearbox, as shown in Fig. 2. The subscript m represents the motor attributes in the given schematic, whereas l characterizes the load shaft variables. In the rotary servo unit, the resistance is denoted by R, L is the inductance, ω is the angular speed, τ is the applied torque, J is the moment of inertia, and B stands for the viscous friction. The variable ebrepresents the back-electromotive voltage, where kmis the back-emf constant. To realize the dynamical model of the rotary servo unit, the mechanical and electrical systems are combined to form the relationship between the angular speed of the motor load shaft ωland the applied controlled voltage Vm. The dynamical system is represented by the following equations
where the equivalent moment of inertia Jeqis expressed as
and the equivalent damping term Beqvis given by
In the expressions of the equivalent moment of inertia and damping, ηgand ηmrepresent the efficiency of the gearbox and motor, respectively. The motor torque constant is denoted by kt,and kgis the gear ratio. The actuator gain Amis computed as
The numerical value of the BBS parameters is listed in Tab. 1, see [1,26].
3 Cascade Control Architecture
A cascade control architecture based on the time separation principle is proposed to control the ball's position on the beam, as shown in Fig. 3. Based on the measured ball position x, the outer positional loop computes the desired angle θldof the servo load shaft by engaging the classical PD control. The inner fast attitude loop incorporates IDI control to track the desired angle θldby generating the corresponding motor controlled voltage V such that the desired ball position on the beam is achieved in minimal time.
4 Outer Loop PD Control Design
Given the desired and actual ball's position, i.e., xdand x, the classical PD controller is engaged in the outer loop to generate the desired servo angle command θldfor the inner loop to minimize the positional error of the ball placed on the beam. The asymptotically stable virtual (desired) dynamics to compute θldbased on the positional error of the ball in the horizontal plane is expressed as
where kpand kdare controller gains chosen to calculate the suitable value of θldsuch that x approached xdin minimum time. It is noteworthy to mention here that the position feedback of the ball is acquired from an analog sensor with its inherent noise. By taking its derivative, it will generate an amplified high-frequency signal transmitted to the inner loop via feedback which causes the grinding noise in the motor. The derivative is replaced by a first-order filter governed following dynamics to compensate for this effect.
where ωfrepresents the cutoff frequency, whose value is set to be 6.28 rad/s.
This section discussed the design and implementation of IDI control for attitude control of the rotary servo unit of BBS. The proposed non-square inversion-based intelligent controller proves to be an efficient and effective control strategy to deal with complex nonlinear systems. The control law comprises two major components, i.e., an equivalent or baseline control and a switching control component. The general form of IDI control law is expressed as follows
The first component ueqrepresents the baseline controller, which enforces the prescribed constraint dynamics based on the attitude deviation function for stable attitude tracking. On the other hand, urbtrepresents the discontinuous control element whose design principle is based on the classical SMC approach to address robustness against uncertain dynamics, parametric variations, and external disturbances.
The equations of motion of rotary servo unit angular rate dynamics given by Eq. (5) is expressed as
where
where
where the elements of the controls coefficient column vector function
and the elements of the controls load vector function
The baseline or equivalent controlled voltage
where
Remark 1: The matrix
A suitable discontinuous control element is determined to solve the reachability problem, which ensures robustness against parametric uncertainties, system nonlinearities, and external disturbances. The resultant GDI-SMC or IDI control law is constructed to be of the following form
where
Moreover,
The time derivatives of the sliding surfaces are evaluated as
It has been observed that the asymptotic convergence of the sliding surfaces
To prove the asymptotic convergence of the error dynamics, place the control law
Consider the following positive definite Lyapunov candidate function
The time derivative of V is computed as
The 2-(induced) norms of
This section investigates the performance of IDI control law through computer simulations on the dynamical simulator of BBS developed by considering the model of ball and beam unit given by Eq. (3) and the model of rotary servo unit given by Eqs. (4) and (5). The simulation environment is created in Simulink/Matlab, in which the closed-loop performance is evaluated by commanding the square wave profile having an amplitude of
To investigate the real-time performance of balancing the ball on a beam, the IDI control law developed in Section 5 is implemented on Quanser's ball and beam real hardware, as shown in Fig. 7, which proves to be a benchmark testbed for testing and validating control techniques.
The experimental setup comprised the power module VoltPAQ-X1 for supplying voltage to the rotary servo motor module. The servo motor is placed at the right corner of the beam to move the beam in an upward and downward direction. The ball placed on the beam rolls on the track accordingly by changing the slope of the beam. The ball position and the angular position feedback commands are sent to the computer through Quanser's Q8-USB data acquisition card. The communication between Simulink/MATLAB and the experimental hardware is accomplished through the QUARC software. The sampling time is chosen to be
In this analysis, the core objective is to present the comparative analysis of IDI control with classical Linear Quadratic Regulator (LQR) and Fractional Order Control (FOC) strategies. The ball is commanded to follow the step input profile in this setup. The initial position of system states are
Furthermore, the FOC suffers from high overshoot, whereas many steady-state errors were observed in the LQR response. On the other hand, the IDI controller demonstrates very stable time-domain performance near reference input with less overshoot and steady-state error. The time evolution of desired and actual angular profiles and the time histories of the controlled voltages generated in response to the step input command are shown in Figs. 9 and 10, respectively.
8.2 Disturbance Rejection Capability
This section highlighted the disturbance rejection capability of the IDI controller when the ball is subjected to some manual disturbances. The ball position on the beam in a steady state is stimulated by tapping the ball at different time instants. The ball position plot under the effect of disturbances is shown in Fig. 11. It is evident that when disturbances are applied, the ball position is perturbed but immediately returns to its stable position by control reaction and re-stabilized. The jerks appeared in the angular profile due to manual perturbations, which are depicted in Fig. 12. The controlled voltage under the supplied capacity is displayed in Fig. 13, whose magnitude fluctuates in response to the applied disturbances. The experimental results demonstrate better disturbance rejection capability and intelligent attributes of IDI control.
In this plot, the controllers’ capability is further analyzed by commanding a reference square wave profile with an amplitude of
While examining the different behaviors of the controller response in the simulation and experimental results, it is claimed that the proposed controller proves itself a reasonable control approach for stabilizing the under-actuated electro-mechanical systems.
This paper investigates the performance of IDI control for a standard nonlinear ball and beam unstable system. A two-loops structured control is implemented in which PD control is responsible for generating the desired servo angle command based on the positional error of the ball placed on the beam. Furthermore, IDI control is engaged in the inner loop for precise attitude tracking. The results are verified through computer simulations and experimental studies in a MATLAB environment. Furthermore, a comparative analysis is presented, which exhibits the superior performance of IDI control over LQR and FOC in terms of faster error convergence with lesser steady-state error. Hence the proposed methodology is quite appealing and feasible for practical electro-mechanical systems.
Acknowledgement: The authors extend their appreciation to the Deputyship for Research & Innovation, Ministry of Education in Saudi Arabia for funding this research work through the Project Number (IFPRC-023-135-2020) and King Abdulaziz University, DSR, Jeddah, Saudi Arabia.
Funding Statement: This research work was funded by Deputyship for Research & Innovation, Ministry of Education in Saudi Arabia under Grant No. (IFPRC-023-135-2020).
Conflicts of Interest: The authors declare that they have no conflicts of interest to report regarding the present study.
1. J. Apkarian, P. Karam, M. Levis and H. Gurocak, Quanser Innovative Edutech Laboratory Guide-Ball and Beam Experiment, Canada: Quanser Inc., 2012. [Google Scholar]
2. I. M. Mehedi, U. M. Al-Saggaf, R. Mansouri and M. Bettayeb, “Two degrees of freedom fractional controller design: Application to the ball and beam system,” Measurement, vol. 135, pp. 13–22, 2019. [Google Scholar]
3. J. Hauser, S. Sastry and P. Kokotovic, “Nonlinear control via approximate input-output linearization: The ball and beam example,” IEEE Transactions on Automatic Control, vol. 37, no. 3, pp. 392–398, 2002. [Google Scholar]
4. D. N. Kouya and F. A. Okou, “A new adaptive state feedback controller for the ball and beam system,” in Canadian Conf. on Electrical and Computer Engineering (CCECE), Niagara Falls, Canada, pp. 247–252, 2011. [Google Scholar]
5. D. Martinez and F. Ruiz, “Nonlinear model predictive control for a ball and beam,” in 4th Colombian Workshop on Circuits and Systems (CWCAS), Barranquilla, Colombia, pp. 1–5, 2012. [Google Scholar]
6. T. Wu and Y. T. Juang, “Adaptive fuzzy sliding-mode controller of uncertain nonlinear systems,” ISA Transactions, vol. 47, no. 3, pp. 279–285, 2008. [Google Scholar]
7. A. Nejadfard, M. J. Yazdanpanah and I. Hassanzadeh, “Riction compensation of double inverted pendulum on a cart using locally linear neuro-fuzzy model,” Neural Computing and Applications, vol. 22, no. 2, pp. 337–347, 2013. [Google Scholar]
8. W. Luhao and S. Zhanshi, “Lqr-fuzzy control for double inverted pendulum,” in Int. Conf. on Digital Manufacturing & Automation, Changcha, China, pp. 900–903, 2010. [Google Scholar]
9. P. Feng, L. Lu and X. Dingyu, “Double inverted pendulum sliding mode variation structure control based on fractional order exponential approach law,” in Proc. CCDC, Guiyang, China, pp. 5077–5080, 2013. [Google Scholar]
10. R. M. Nagarale and B. M. Patre, “Decoupled neural fuzzy sliding mode control of nonlinear systems,” in Proc. FUZZ-IEEE, Hyderabad, India, pp. 1–7, 2013. [Google Scholar]
11. Z. Song and K. Sun, “Adaptive backstepping sliding mode control with fuzzy monitoring strategy for a kind of mechanical system,” ISA Transactions, vol. 53, no. 1, pp. 125–133, 2014. [Google Scholar]
12. M. Mehdi, M. Rehan and F. M. Malik, “A novel anti-windup framework for cascade control systems: An application to underactuated mechanical systems,” ISA Transactions, vol. 3, no. 1, pp. 802–815, 2014. [Google Scholar]
13. I. M. Mehedi, U. M. Al-Saggaf, R. Mansouri and M. Bettayeb, “Stabilization of a double inverted rotary pendulum through fractional order integral control scheme,” International Journal of Advanced Robotic Systems, vol. 16, no. 4, pp. 1–9, 2019. [Google Scholar]
14. I. M. Mehedi, “State feedback based fractional order control scheme for linear servo cart system,” Journal of Vibroengineering, vol. 20, no. 1, pp. 782–792, 2018. [Google Scholar]
15. U. M. Al-Saggaf, I. M. Mehedi, R. Mansouri and M. Bettayeb, “Rotary flexible joint control by fractional order controllers,” International Journal of Control Automation and Systems, vol. 15, no. 6, pp. 2561–2569, 2017. [Google Scholar]
16. U. M. Al-Saggaf, I. M. Mehedi, R. Mansouri and M. Bettayeb, “State feedback with fractional integral control design based on the bode's ideal transfer function,” International Journal of Systems Science, vol. 47, no. 1, pp. 149–161, 2016. [Google Scholar]
17. M. Bettayeb, C. Boussalem and R. Mansouri, “Stabilization of an inverted pendulum-cart system by fractional pi-state feedback,” ISA Transactions, vol. 53, no. 2, pp. 508–516, 2014. [Google Scholar]
18. A. Young, C. Cao and N. Hovakimyan, “Control of a nonaffine double-pendulum system via dynamic inversion and time-scale separation,” in Proc. ACC, Minneapolis, MN, USA, pp. 6–12, 2006. [Google Scholar]
19. A. I. Iskanderani and I. M. Mehedi, “Experimental application of robust and converse dynamic control for rotary flexible joint manipulator system,” Mathematical Problems in Engineering, vol. 2021, Article ID 8917134, pp. 1–9, 2021. [Google Scholar]
20. A. Ben-Israel and T. N. Greville, Generalized Inverses: Theory and Applications, Piscataway, NJ, USA, Springer, 2003. [Google Scholar]
21. I. M. Mehedi, H. S. M. Shah, U. M. Al-Saggaf, R. Mansouri and M. Bettayeb, “Adaptive fuzzy sliding mode control of a pressure-controlled artificial ventilator,” Journal of Healthcare Engineering, vol. 2021, Article ID 1926711, pp. 1–10, 2021. [Google Scholar]
22. I. M. Mehedi, H. S. M. Shah, U. M. Al-Saggaf, R. Mansouri and M. Bettayeb, “Fuzzy PID control for respiratory systems,” Journal of Healthcare Engineering, vol. 2021, Article ID 7118711, pp. 1–6, 2021. [Google Scholar]
23. I. M. Mehedi, U. Ansari and U. M. Al Saggaf UM, “Three degree of freedom rotary double inverted pendulum stabilization by using robust generalized dynamic inversion control: Design and experiments,” Journal of Vibration and Control, vol. 26, no. 23–24, pp. 2174–2184, 2020. [Google Scholar]
24. I. M. Mehedi, U. M. Al-Saggaf and S. S. Ali, “Design and simulation of fractional order control scheme for rotary flexible link,” in Proc. ICIAS, Kuala Lumpur, Malaysia, pp. 1–5, 2018. [Google Scholar]
25. I. M. Mehedi, “Full state-feedback solution for a flywheel based satellite energy and attitude control scheme,” Journal of Vibroengineering, vol. 19, no. 5, pp. 3522–3532, 2017. [Google Scholar]
26. J. Apkarian, M. Levis and H. Gurocak, Quanser Innovative Edutech-Laboratory Guide-SRV02 Laboratory User Manual, Canada: Quanser Inc, 2009. [Google Scholar]
27. H. Khalil, Nonlinear Systems, NJ, USA, Pearson: Prentice-Hall, 1996. [Google Scholar]
This work is licensed under a Creative Commons Attribution 4.0 International License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited. |