Fuzzy Control of AC Servo Systems Based on Genetic Algorithms
2026-04-06 05:41:56··#1
Abstract: A self-optimizing fuzzy controller based on genetic algorithm was developed to address the characteristics and requirements of AC servo systems. This design utilizes a real-time simulation system and employs a genetic algorithm to achieve automatic online optimization of fuzzy control parameters, effectively solving the problem of precision and speed characteristics in servo systems. Experiments demonstrate that the system performs well. Keywords:Servo system; Fuzzy control; Genetic algorithm; Real-time simulation 1 IntroductionHigh -precision AC servo systems generally employ three-loop control. Among them, the position control loop is a high-order, strongly coupled, time-varying nonlinear control object. Therefore, the system design under linear conditions will result in the absence of certain nonlinear and uncertain factors, such as static friction of the load, backlash of the mechanical transmission system, saturation of each link, and randomness of the given signal, which makes the model in the design differ greatly from the actual system [1-2]. Fuzzy control can effectively overcome the adverse effects of uncertainties, noise, nonlinearity, and time-varying nature of the controlled object on the system. However, since the fuzzy control parameters are affected by factors such as insufficient knowledge and experience, the dynamic and static performance and robustness of the system are reduced [3-5]. This system uses a genetic algorithm to automatically optimize the quantization factors K1 and K2, proportional factor K3 and correction factor αi of the fuzzy controller to achieve optimal control. 2 System Overall Design The position regulator adopts a fuzzy controller. Both the speed loop and the current loop adopt digital PID control. The current loop is designed as a typical type I system, and the speed loop is designed as a typical type II system. The system fuzzifies the difference between the actual feedback value and the given value, as well as their rate of change. The membership function determines the level of the difference, and the optimal fuzzy rule obtained through self-optimization determines the fuzzy control signal. The system structure is shown in Figure 1. [align=center] Figure 1 AC Servo Control System[/align] The position setpoint signal is directly given by a digital signal, and the power converter uses a PWM AC frequency converter. A three-phase AC motor is selected as the drive motor. The position and speed feedback signals are detected by an incremental photoelectric encoder. The photoelectric encoder has a detection resolution of 2048 pulses/revolution. Two pulse signals with a 90-degree phase difference are output from the code disk to form a four-fold frequency and phase detection signal, with an actual resolution of 9192 pulses/revolution. 3 System Real-time Simulation Optimization Platform The system real-time simulation optimization platform consists of an "AC servo motor real-time simulation system" composed of a host PC and an "AC servo motor control system" composed of a slave unit. The AC servo motor real-time simulation system communicates with the AC servo motor system through a USB bus interface and, in conjunction with corresponding experimental equipment, achieves online real-time simulation to complete the self-optimization of the motor's fuzzy control parameters. The optimized control parameters generated through optimization are transmitted to the AC servo motor system via the communication interface. The real-time simulation system for the AC servo motor is shown in Figure 2. [align=center] Figure 2 Real-time simulation system for AC servo motor[/align] 4 Self-adjusting fuzzy control of the position loop Different correction factors αi are introduced for different deviation levels. By adjusting the value of αi, the weighting of the deviation E and the rate of change of deviation EC on the output U is changed. When the absolute value of the deviation is large, the main purpose of the control system is to eliminate the deviation and reduce the dynamic error of the system; when the deviation is small, the main purpose of the control system is to suppress system overshoot and make the system reach steady state as soon as possible. Selecting {E}={EC}={U}={-3,-2,-1,0,1,2,3}, then i=0,1,2,3; < > indicates rounding. To improve the system's adaptability and robustness, and to improve the system's dynamic quality to achieve optimal performance, the correction factor αi, quantization factors K1, K2, and proportional factor K3 must be optimized. 4.1 Fuzzy Control Parameter Self-Optimization Considering that the optimization of the fuzzy controller involves a large-scale and multi-parameter search surface, a genetic algorithm is used to automatically optimize K1, K2, K3, and αi in stages [6-7]. First, K1, K2, and K3 are optimized to obtain their optimal values. Then, αi is optimized using the same optimization method. Since the optimal αi cannot be obtained when optimizing K1, K2, and K3, αi is temporarily implemented using the intelligent weight function method, i.e., αi=|E|/(|E|+|EC|). The control objective is described as the ability of the system output to track the given value with the minimum error, i.e., the objective function is defined as J=min(eTe). A serial binary mapping encoding method is adopted. Each parameter is encoded with a binary string of a certain length, and then the encodings of each parameter are concatenated to form a combined code string. K1 directly affects the dynamic characteristics and steady-state accuracy of the controller, so it is encoded with eight bits. The error rate of change is relatively small and easily affected by noise. To improve the robustness of the controller, the encoding length should be appropriately shortened, so K2 is encoded with six bits. The value range of is related to the accuracy of the actuator, so it is encoded with seven bits. The binary codes of parameters K1, K2, and K3 are concatenated from left to right to form a 21-bit combined code string. Let the value ranges of parameters K1, K2, and K3 be [K1min, K1max], [K2min, K2max], and [K3min, K3max], respectively, and their binary codes be b1, b2, and b3, respectively. K1, K2, and K3 and their corresponding binary codes satisfy the following: 4.2 The genetic operating system adopts the CHC genetic algorithm. In the actual optimization, according to the principles of mathematical statistics, an initial population of 20 individuals is generated by experiment within the defined domain. The population size is 20, that is, the population contains 20 samples. The previous generation population is mixed with individuals generated through a new crossover method, and the better individuals are selected with a certain probability. In this design, the fitness value fi of each individual in each population is first calculated using the function F=1/J. Then, 20 individuals with larger fi are selected to form a new population. An improved uniform crossover is used. When the number of different positions between two parent individuals is m, m/2 positions are randomly selected to swap the parent individuals' positions. Since this operation is highly destructive to the model, a threshold is determined. When the Hamming distance between individuals is below this threshold, crossover is not performed. This threshold is gradually reduced as the population converges. Mutation ensures that the searched solution has a globally optimal characteristic. When the population reaches a certain convergence period, a portion of the excellent individuals are selected for initialization. The initialization method is to select loci of 0.25 and randomly determine their positions. The genetic algorithm flow is shown in Figure 3, where the variable Gen represents the number of generations. [align=center]Figure 3. Genetic Algorithm Flowchart[/align] 5. System Experiment When the position input signal is 1000 pulses, the system response curve is shown in Figure 4. Clearly, the system response using the self-optimizing fuzzy control based on the genetic algorithm is faster and more accurate than that of ordinary PID control. Furthermore, changes in the system structure and parameters have a smaller impact on the system output characteristics. Although the integral element of the position system helps reduce steady-state error, experiments show that steady-state error still exists, which is determined by the fuzzy control itself. To further improve steady-state performance, a composite control method combining coarse and fine fuzzy control can be used. 6. Conclusion The innovation of this paper lies in applying a genetic algorithm to perform online real-time optimization of the fuzzy control parameters of the AC servo motor system using a self-developed real-time simulation system for AC servo motors, obtaining optimized fuzzy control parameters. The application of fuzzy control enhances the robustness of the system, solving the problems of fast, overshoot-free response and high precision requirements of traditional servo systems. The introduction of fuzzy control parameter optimization further weakens the influence of human factors on parameter selection in fuzzy control, greatly improving the dynamic and static quality of the system. [align=center] Figure 4 Control system response characteristic curve[/align] References [1] Li Guohou, Yang Qingjie. Intelligent servo technology and its application [J]. Microcomputer Information, 2005, 7-1: 128-130. [2] Shi Liting, Huang Xiaotiao, Yang Yong. Three-loop tuning and application of CNC AC servo system [J]. Nanjing: Journal of Nanjing University of Technology, 2006, 28(4): 36-40. [3] Li Shiyong (ed.), Fuzzy Control, Neural Network and Intelligent Control Theory [M]. Harbin: Harbin Institute of Technology Press, 1998. [4] Gao Hongyan, Wang Jianhui. Fuzzy control method and application of online self-adjusting correction factor [J]. Microcomputer Information, 2006, 5-1: 83-84. [5] JB Kiszka, ME Kochanska and DS Sliwinska. The infuence of some parameters on the accuracy of fuzzy model. in Industry Applications of Fuzzy Control, M Sugeno, Ed. Amsterdam, North-Holland, 1985. [6] Zhang Wenxiu, Liang Pa. Mathematical basis of genetic algorithms [M]. Xi'an: Xi'an Jiaotong University Press, 2000. [7] XM Qi, TC Chin. Genetic algorithms based fuzzy controller for high order system. Fuzzy Sets and Systems, 1997, 91: 279-284.