Fractional order PID controller in velocity control loop of CNC machine feed-drive module with permanent magnet synchronous motor

Artur Kobyłkiewicz, Rafał Pajdzik, Paweł Waszczuk

Department of Control Engineering and Robotics, West Pomeranian University of Technology of Szczecin

Abstract: A significant number of publications shows that fractional order controllers can improve performance compared with traditional control algorithms. In this paper, fractional order PID velocity controller of the PMSM motor is presented. In the first step, we compared, by means of simulation research work, the fractional order PID with conventional integer order PID, and we prove the correctness of the applied method. In the second part, we have tested the proposed solution in the real-time control system with the PMSM actuator. The open architecture control system based on the industrial computer (for cyclic real-time communication with power electronics, including current controller and commutation functionality, with the use of Ethernet Powerlink communication protocol) and rapid prototyping platform were used for the evaluation of the developed here velocity control algorithms. Presented in the paper experimental results testify to the usefulness of the proposed solution.

Keywords: fractional order calculus, PMSM motor, PID controller, robust control

1. Introduction

Nowadays, a lot of attention is focused on research and modeling of phenomena and physical objects. It is obvious that the standard approach to the subject, where integrals and derivatives of integer order are used to describe complex phenomena, is insufficient. That is because highly complicated and not very reliable models are achieved as a result. Therefore, the world of science refers to the tools known for hundreds of years but which found their practical application only at the close of the previous century. These tools allow for modeling using integrals and derivatives of real order (so called differintegrals, or fractional order calculus). The result is a significantly more comprehensive description of a given phenomenon and this, in turn, leads to better results. As an example papers [5–7] can be used, in which selected issues are described with the help of fractional order equations.

Such an approach may have some implications in automation and control theory. Due to the fact that the objects which are controlled by engineers are of fractional order then it seems logical to apply fractional order controllers (with adequate properties) to control them. In the paper a practical solution to such an approach is shown based on the PID controller. The paper is divided into two main parts. Both of them contain the comparison of the integer order PID controller (IOC) with the fractional order PID controller (FOC).

First of all, the analysis of correctness and rightness of the applied method was made in comparison with the classical controller with the help of computer simulation. For this purpose MATLAB/Simulink was used with an implemented classical algorithm and fractional order PID controller as a velocity controller of the PMSM motor.

The second, more challenging part of the paper is the implementation of the already tested algorithm in the target control system of the CNC machine.

In this way it has been experimentally confirmed that the assumed goals of the improvement of the quality of real object control may be achieved by entering fractional order elements into the control loop.

2. Fractional order PID controller

There are many ways to describe fractional order calculus. One of the most used ones are the definitions by Riemann-Liouville (1) and Grünwald-Letnikov (2).

(1)

where

and it is a well known Euler function.

(2)

where

Based on definition (2), which in a natural way allows for describing discrete equations, fractional order forward difference could be shown in the form (3).

(3)

Formula (3) for a < 0 shows discrete integration process, whereas for a > 0 shows discrete differentiation process.

Furthermore, it is possible to present in a clear way discrete integral (4) and differential (5) fractional order element, which will be used in the discrete fractional order PID controller.

(4)

(5)

The sum in equations (4) and (5) determines “memory” of the analyzed element, which means that current value of the state x(t + 1) is not dependent only on the previous value of the state x(t) and the current input u(t), but it also contains all the previous states of the model. In practice the memory of fractional order elements is often limited to the finite value L due to restricted possibilities of control systems. The parameter which binds together all the previous states of the element is the coefficient and ,

which is directly dependent on the order of an analyzed element. Such a model is similar to a real object whose current state is also dependent on all its previous states.

The general scheme of the PID controller is assumed and described by equation (6)

(6)

where e(t) is a control error at a given moment t, Ts is a sampling time, whereas I a and D b symbolize a fractional order integral and a derivative respectively. By choosing a = 1 and b = 1 the classical PID controller of integer order is achieved.

3. Simulations

In this part of the paper the analysis of correctness and rightness of applying a fractional order PID controller algorithm in the context of velocity control of the PMSM motor was made.

3.1. Description of simulation environment

The well known model of the PMSM motor from [3] served as a model of the researched object with known catalogue parameters.

(7)

(8)

Equation (7) describes the electrical part, whereas equation (8) describes the mechanical part of the motor. The state vector of the described motor model is .

In order to choose the best parameters of the motor model, the parameters were selected from the catalogue note of a specific motor used in chapter 4 for experimental research. Additionally, the appropriate conditions, corresponding to the real ones, of the simulation were created. It means that PI controllers were used and sampling time was set to 400 μs. Because in such a time cycle works a real time controller used in further research. Limiting the control loop to only PI controllers is caused by a very unfavorable effect of differential term when control error changes rapidly. For this reason differential terms are not used in servo-drive motor applications [9].

Tab. 1. Parameters of the PMSM motor model
Tab. 1. Parametry modelu silnika PMSM

Parameter

Value

Stator resistance

R

18.5 Ω

Stator direct ind.

Ld

49.16 mH

Stator quadrature ind.

Lq

49.16 mH

Number of polepairs

p

2

Inertia

J

0.00009 kg∙m2

Torque

T

1.455 Nm/A

Friction

F

0 Nms

Flux

l

0.42 Wb

Fig. 1. Control system of the PMSM motor
Rys. 1. System sterowania silnikiem PMSM

Fig. 1 presents the general scheme of the used control system. Cascade control system with velocity control loop and torque (current) was applied. In a real control system the torque controllers are placed in the PMSM motor servo-drive. Hence, the parameters of the torque controllers selected for the simulation are the same as the default ones set by the servo-drive producer for a given motor. In this case the following parameters are set:

Kv = 54.587318,

Ti = 0.00088248722.

The scheme of selection of velocity controller parameters, which was used during carried out simulations, is presented in the following points:

Putting the system to the stability limit through increasing gain of the proportional term Kv, when the integration term of the controller is turned off.

Setting gain Kv as 90 % of the critical value of the gain from point 1.

Gradual decreasing of time constant of the integral term Ti until the best control quality was achieved according to the used quality criterion.

Five basic integral criteria of quality control were used in order to assess control quality:

,

,

,

,

.

As the most critical value was determined the ITAE criterion (Integral of Time multiplied by Absolute value of Error), which is one of the most widely used in industrial applications.

3.2. Results of simulation research

A number of simulations in the MATLAB/Simulink environment were carried out using the control system model shown in point 3.1. The memory of the integral element of the controller was set to L = 200 and left unchanged for the period of further simulations. In search of optimal controller settings a methodical analysis of the range of settings was applied. The minimal value of the ITAE quality criterion was determined as the indicator of optimal controller settings selection. As the reference signal was used trapezoidal signal of velocity with maximal value of 1 rps.

In this way optimal settings for the IO PI controller were obtained

(9)

and for the FO PI controller

(10)

Fig. 2. The best IOC (red line) compared with the best FOC (green line); reference signal (blue line)
Rys. 2. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia); sygnał zadany (niebieska linia)

Fig. 2 shows the response to the velocity reference signal of the best IO and FO PI controller. For the purpose of a clear presentation of the results only the selected fragments of the time courses were shown.

It is visible with the naked eye that the best FO PI controller achieves much better results than the classical
IO PI controller. It is also proved by the values of the quality criterion

ITAEI0 = 1

and

ITAEF0 = 0.8448.

What was achieved is the quality improvement by 15 %, which is strongly observable in the transient part of velocity changes.

The effect of the change of one of model parameters on control quality was also checked. The value of the inertia of the engine shaft was changed to J = 0.0019107 kg×m2 (about 20 times higher than the initial value). Then simulations were carried out again, with the same settings of the controller parameters and the results are shown in fig. 3.

Fig. 3. The best IOC (red line) compared with the best FOC (green line), determined without changed inertia used in the motor with increased inertia; reference signal (blue line)
Rys. 3. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia), uzyskane bez zmienionej bezwładności użyte dla silnika ze zwiększoną bezwładnością; sygnał zadany (niebieska linia)

In that case performance of both IO and FO regulators are qualitatively similar, which is also confirmed by the values of the integral criterion (difference less than 8 %)

ITAEI0 = 5.7904

and

ITAEF0 = 6.3606.

It shows also that the system with FO controller has a completely different character of response to disturbances of the object parameters than system with IO control.

(11)

(12)

During the final stage of simulation research the optimal settings for the motor with increased inertia were found. Equations (11) and (12) show the best IO and FO controllers respectively. Fig. 4 shows the response to reference velocity signal for these settings.

The obtained results were supported by the values of the integral criteria:

ITAEI0 = 2.160

and

ITAEF0 = 0.1735,

which show achieved quality improvement by 19 %.

Fig. 4. The best IOC (red line) compared with the best FOC (green line) for the motor with increased inertia; reference signal (blue line)
Rys. 4. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia), dla obiektu ze zwiększoną bezwładnością; sygnał zadany (niebieska linia)

4. Experiment

This chapter contains the description of a workstation where experimental research was performed (fig. 5). All the relations resulting from the simulations carried out in chapter 3 were also experimentally confirmed. This demonstrates the power of the algorithm of the FO PI controller.

Fig. 5. Workstation for rapid prototyping control systems for the PMSM motor drives
Rys. 5. Stanowisko do szybkiego prototypowania systemów sterowania silnikami PMSM

4.1. Rapid prototyping workstation description

The research workstation consists of: engineering programming environment MATLAB/Simulink from Mathworks and the software for designing IT projects for deterministic, multitasking RT operational system Automation Runtime which is the base of industrial B&R control system. Thus, the workstation integrates the designing stage, complex simulation analyses with prototyping of newly designed algorithms in the target control system.

The element that links these two solutions is toolbox Automation Studio Target for Simulink from B&R. A designed and verified model is later compiled in Simulink to optimal program code for the B&R target system processor thanks to the functionality of RT Workshop and RT Workshop Embedded Coder. This situation is shown in fig. 6.

Fig. 6. Scheme of rapid prototyping system
Rys. 6. Schemat systemu do szybkiego prototypowania

The achieved time decrease during the designing advanced control algorithms testifies to the synergy of the here presented approach. In this way it is possible to avoid the problem which happens in case of physical impossibility of implementing prototype simulation model or mathematical solution to a given issue in the target control system. A very efficient system for rapid prototyping of advanced control system algorithms is achieved. It allows for testing new solutions in a short time. Such an approach is called On-Target Rapid Prototyping [8].

Apart from the computer with the described systems, the workstation also contains the industrial computer B&R APC620 with a RT operating system and the B&R servo-drive Acopos 1090 with the PMSM motor actuator. The connection between industrial computer (PLC) and the servo-drive is through the deterministic, industrial Ethernet Powerlink which enables synchronous data transfer every 2 ms. The torque (current) controller located in the servo-drive sets a new value of current every 400 μs.

4.2. Results of experimental research

A number of experiments using the workstation described in point 4.1 were carried out. The memory of the integral element of the controller was set to L = 200 and left unchanged for the period of further experiments. In order to determine optimal controller settings, as it was in case of simulation research, the ITAE criterion was used. As the reference signal was used trapezoidal signal of the maximal value of velocity equal to 10 rps.

Firstly, the motor without increased inertia of the shaft was researched. The optimal settings for the IO PI controller were achieved

(13)

and for the PI controller

(14)

Fig. 7 shows the results achieved during the experiments.

Fig. 7. The best IO controller (red line) compared with the best FO controller (green line); reference signal (blue line)
Rys. 7. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia); sygnał zadany (niebieska linia)

The experiment confirms the simulation results. The best FO PI controller obtains significantly better results than the classical IO PI controller. The values of integral criteria for the responses from fig. 7 are

ITAEI0 = 1248.61

and

ITAEF0 = 1127.12.

According to the coefficient ITAE the improvement of control quality by over 10 % was achieved. The fluctuation amplitude of the motor velocity in the steady-states has a visible effect on the indicator value. For the FO PI controller the amplitude is noticeably narrower.

Fig. 8. The best IO controller (red line) compared with the best FO controller (green line) determined without changed inertia used in the motor with increased inertia; reference value (blue line)
Rys. 8. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia), uzyskane bez zmienionej bezwładności użyte dla silnika ze zwiększoną bezwładnością; sygnał zadany (niebieska linia)

It is also checked what are the effects of changing the motor parameters. The additional weight was mounted to the motor shaft which caused the increase of its inertia to J = 0.0019107 kg×m2. Later on, the experiment with parameters selected for the motor without increased inertia was conducted. Fig. 8 shows the results.

According to the integral criterion, the FO controller algorithm turned out to be similarly efficient (less than 2 % of difference). The maximal value of control error of the FO controller is three times lower than the classical IO controller but the response to object parameter disturbance has character of unfading oscillations. The values of the integral criterion for the controllers are the following

ITAEI0 = 4824.03,

ITAEF0 = 4895.91.

It was observed that the FO PI controller has a similar robustness that the classical one, which is in accordance with the results achieved in computer simulations.

(15)

(16)

During the final stage of the research the optimal settings of the controllers for the motor with changed inertia were selected. Equations (15) and (16) present the FO and IO controllers respectively, while fig. 9 shows the response to reference velocity signal for these settings.

Fig. 9. The best IO controller (red line) compared with the best FO controller (green line) for the motor with increased inertia; reference value (blue line)
Rys. 9. Najlepszy IOC (czerwona linia) w porównaniu z najlepszym FOC (zielona linia), dla obiektu ze zwiększoną bezwładnością; sygnał zadany (niebieska linia)

The obtained results (over 19 % better quality) were supported by the values of integral criteria:

ITAEI0 = 1005.04

and

ITAEF0 = 806.19.

5. Conclusion

This article proves that a significant improvement of control quality can be achieved using a controller adequately chosen for a given object, which means that for an FO object the FO controller should be selected.

In the described example the FO PI controller was used for velocity control of the PMSM motor. The FO controller performance was compared experimentally and in simulations with the performance of the classical IO controller. The correctness of the applied concept and method has been proved.

Moreover, the research shows that the settings of the optimal controllers (IO and FO) differ only in parameter a responsible for the order of integral term. It greatly facilitates the methodology of the settings selection of the FO controller. In order to determine optimal settings Kv and Ti one can use the methods known form the classical PID controllers and then fine-tune the controller using parameter a. Additionally, it provides a certain room for maneuver during the implementation of such a solution in the industrial conditions. It is sufficient to implement a new algorithm to the target control system (which does not pose too many complications using the described On-Target Rapid Prototyping method), take the settings from the controller already working in the system, and then fine-tune the order of the implemented controller to achieve the optimal performance of the system.

It has been concluded that the FO PID controller has a similar robustness to structural changes of the controlled object compared to the classical one. In the presented case with an increased inertia of the motor shaft it was enough to increase the value of the gain of the proportional term in order to improve control quality.

The paper contains the method of the expansion of fractional order differintegral from the definition by Grünwald-Letnikov (2). Parameter L, which results from the definition, is responsible for the memory of the fractional order elements. This method is simple to interpret and can be easily explained to engineers in charge of machine operation in the industry. What is interesting is the effect of parameter L on control quality, therefore it should form the base for further research in this direction.

Acknowledgements

Research has been done within the framework of the project “Development of the construction and experimental tests of a mechatronic machine tool feed unit with a drive controlled by an intelligent modular actuator” (MNiSW Project No. N 502 336936, code-name M.A.R.I.N.E. (multivariable hybrid ModulAR motIon coNtrollEr)).

Bibliography

1. Xue D., Zhao C., Chen Y., Fractional Order PID Control of A DC-Motor with Elastic Shaft: A Case Study, Proceedings of the 2006 American Control Conference Minneapolis, 2006, 3182–3187.

2. Domek S., Jaroszewski K., Kobyłkiewicz A., Sterowanie niecałkowitego rzędu parą antagonistycznych mięśni pneumatycznych, Modelowanie inżynierskie, 2009.

3. Krishnan K., Electric Motor Drives: Modeling, Analysis, and Control, Prentice Hall, New Jersey 2001.

4. Kaczorek T., Wybrane zagadnienia teorii układów niecałkowitego rzędu, Oficyna Wydawnicza Politechniki Białostockiej, Białystok 2009.

5. Jezierski E., Ostalczyk P., Fractional-order mathematical model of pneumatic muscle drive for robotic applications, [in:] Kozłowski K. (Ed.), Robot Motion and Control 2009, Springer-Verlag Berlin Heidelberg 2009.

6. Sierociuk D., Estymacja i sterowanie dyskretnych układów dynamicznych, Ph.D. thesis, Warszawa 2007.

7. Zaborovsky V., Meylanov R., Informational network traffic model based on fractional calculus, Proceeding of the International Conference Info-tech and Info-net, Beijing 2001.

8. Bernecker + Rainer Industrie-Elektronik GmbH, B&R Automation Studio Target for Simulink.

9. Kosmol J., Serwonapędy obrabiarek sterowanych numerycznie, Wydawnictwo Naukowo-Techniczne, Warszawa 1998.

Regulator PID ułamkowego rzędu w pętli sterowania prędkością modułu posuwowego obrabiarki CNC z napędem PMSM

Streszczenie: W licznych publikacjach wykazano, że regulatory ułamkowego rzędu mogą zwiększyć skuteczność regulacji w porównaniu z tradycyjnymi algorytmami sterowania. W artykule przedstawiono regulator PID ułamkowego rzędu do sterowania prędkością silnika PMSM. W pierwszej części zaprezentowano wyniki symulacji, porównano regulator PID ułamkowego rzędu z konwencjonalnym regulatorem PID całkowitego rzędu i dowiedziono prawidłowość zastosowanej metody. W drugiej części artykułu przedstawiono wyniki testów zaproponowanego rozwiązania, przeprowadzonych w docelowym systemie sterowania silnikiem PMSM. Otwarta architektura systemu sterowania bazująca na komputerze przemysłowym (do cyklicznego komunikowania się z energoelektroniką w czasie rzeczywistym, realizujący regulację prądu i funkcjonalność komunikacyjną z użyciem protokołu komunikacyjnego Ethernet Powerlink) oraz na systemie do szybkiego prototypowania zostały użyte do oceny zaprojektowanego algorytmu regulacji prędkości. Wyniki przedstawione w artykule potwierdzają przydatność zaproponowanego rozwiązania.

Słowa kluczowe: rachunek różniczkowy ułamkowego rzędu, napęd PMSM, regulacja PID, sterowanie odporne

Artur Kobylkiewicz, MSc Eng.

PhD student at Department of Industrial Automation and Robotics, Faculty of Electrical Engineering, West Pomeranian University of Technology Szczecin. The main fields of his interest are: fractional order control systems, Attitude and Orbital Control Systems and chaos in dynamic systems.

e-mail: artur.kobylkiewicz@zut.edu.pl

Pawel Waszczuk, MSc Eng.

PhD student at Department of Industrial Automation and Robotics, Faculty of Electrical Engineering, West Pomeranian University of Technology Szczecin. The main fields of his interest are: digital signal processing, diagnostics in milling and micromilling process and digital servodrives.

e-mail: pawel.waszczuk@zut.edu.pl

Rafal Pajdzik, MSc Eng.

PhD student at Department of Industrial Automation and Robotics, Faculty of Electrical Engineering, West Pomeranian University of Technology Szczecin. His research interests include analysis, modeling, design of digital servodrives of milling machines.

e-mail: rafal.pajdzik@zut.edu.pl