Efficient Position Control of DC Servomotor Using ... - Semantic Scholar

78 downloads 253 Views 407KB Size Report
drives. Multiple non-linear parameters and dynamic factors, such as Dead Zone, Saturation, Coulomb .... When receiving the data, the input neurons receive the.
2011 Seventh International Conference on Natural Computation

Efficient Position Control of DC Servomotor Using Backpropagation Neural Network Yahia F. Makableh Mechanical and Electrical Engineering Department. Georgia Southern University Statesboro, GA. USA

Fernando Rios-Gutierrez Mechanical and Electrical Engineering Department. Georgia Southern University Statesboro, GA. USA Abstract— The increasing growth in the use of DC Servomotors for multiple industrial applications in the last few decades have made them one of the most important system’s drives. Therefore, developing an intelligent DC Servomotor position control scheme and, in particular, a DC Servomotor Neural Model based on a well-defined mathematical model that can be used for off-line simulation are very important tools for this type of system’s drives. Multiple non-linear parameters and dynamic factors, such as Dead Zone, Saturation, Coulomb Friction, Backlash and load changes, are of most concern when controlling servomotors’ angular position. Due to these nonlinearities and dynamic factors, conventional control schemes such as PID control may not be the best solution for some applications because they result in low system efficiency. To reduce the effect of these nonlinearities and dynamic factors and to improve the system’s efficiency, an intelligent Neural Network (NN) Controller is proposed. In this paper we are reporting the use of a combination of a DC Servomotor Neural Model and a Neural Network controller. The proposed NN combination is able to deal with the non-linear parameters and dynamic factors found in the original system, and is able to improve the overall system efficiency. Off line simulation using MATLAB® SIMULINK was used to show the final results of the controller and to compare them to a conventional PID controller. Keywords-component; DC Servomotors; Neural Networks; Backpropagation; Intelliegnt Controller.

I.

INTRODUCTION

DC servomotors are considered as the heart of different industrial applications and automatic systems. They can be found in disk drives, automatic doors, cruise control systems, robotic arms and many other applications. Although these motors are widely used, and different controllers have been proposed and implemented to improve their efficiency, they still suffer from non-linear parameters affecting their overall efficiency [1, 5]. Also changing the load attached to the motor or any sudden change in the working environment will add more complexity to the system [2]. DC Servomotor systems have two outputs that can be controlled, angular speed and angular position. Improving the system’s efficiency comes from the proper control of both outputs together, or by controlling one of them at a time and, hence, two identification plants can be derived for each one. For some applications, such as disk drives and robotics, position control is more important than speed control [3]. Non-linear parameters affect the servomotor operation in different ways. Saturation will limit the output position from

978-1-4244-9953-3/11/$26.00 ©2011 IEEE

reaching the desired angular angle; increase of the overshoot in the system may lead to an unstable system [4]. Dead zone occurs due to static friction which limits the input from the original useful level to a lower level, making the system hard to reach the maximum output value [6]. Backlash may exist whenever gear connections do not match in the motor’s mechanical system. For example, when gears do not mesh exactly leaving some spaces between the teeth this causes a loose contact and, hence, a bad effect on the system performance [7]. Load changes or any other sudden change on the system’s shaft side will affect the way the system deals with it. Any sudden change may cause an overshoot on the system or instability, making the system drain more power to compensate for the changes and, hence, may lead to faulty function in the motor itself or in the load functioning. Due to all of these nonlinearities and load changes on the system, conventional controllers are not able to eliminate these effects or to compensate for the changes that may occur. Therefore, intelligent control techniques such Neural Networks, Fuzzy logic and genetic algorithms have been used to improve the system performance. In summary, we are proposing an intelligent control system composed of two feed forward neural networks that are used to build both a NN model that mimics the function of the Servomotor, and a NN controller that is able to deal with the system nonlinearities and load changes to reach a high efficiency of the overall system and its improve its performance. II.

DC SERVOMOTOR AND NN MODEL

A. Servomotor Mathematical Model The mathematical model of the DC servomotor can be derived based on the schematic circuit shown in Figure 1 [8], we can get the following equation: ( )=

( ) +

( )

+

… (1)

Where Vb is the induced voltage, K is the motor torque constant, and ωm is the angular rotating speed, J is the total moment of the inertia of the rotor and load, and b is the damping ratio of the mechanical system. The actual characteristics of the servomotor used have the following parameter values [9]:

653

in which we receive our final output from the network. The output data from this NN can be found using equation 4:

Figure 1. DC Servomotor Diagram = Table I.

( )

… (2)

DC Servomotor Values.

Parameter Moment of Inertia J Damping Coefficient b Torque Constant Kt Electromotive Force constant Ke Electrical Resistance Electrical Inductance

Value 0.0062 N.m.s²/rad 0.001 N.m.s/rad 0.06 N.m/A 0.06 V.s/rad 2.2 ohms 0.5 Henry

The speed transfer function can be found using Laplace transform and combining equation 1 and 2: =

((

).(

)

)

… (3)

This transfer function of the DC servomotor contains both the electrical and mechanical parts of the system. However, for simulation purposes and to add the non-linear effects to the system we divided the transfer function into two parts; the electrical transfer function and the mechanical transfer function. The system structure with these modifications is shown in Figure 2.

Figure 2. Servomotor Block diagram.

B. Neural Network Model Different Neural Network architectures can be used to implement different types of functions, one type that has high efficiency and strong function generalizing in terms of learning speed and simplicity of the structure is the Feed Forward Neural Network (FFNN). FFNN’s are networks in which the data moves only in one forward direction, from the input layer to the hidden then to the output layer, with no internal cycles or loops inside the network [10]. A three layer FFNN is shown in Figure 3. This FFNN has an input data element; this element can be a single value, a vector of inputs or in a matrix form [11]. The input layer should accept the input data or the training data then send these data to the hidden layers. The layers between the input and the output are called the hidden layers; in which most of the data processing is being done in these layers. The last layer is the output layer;

Figure 3. Multi Layer FFNN.

=

(

(

(

p+

)+

)+

)

… (4)

Where a is the network output, f is the transfer function used in each layer, W is the weight value. The super scripts on each parameter in equation 4 stands for the number of the layer. C. Back-propagation Training Method Any NN is trained using a training method, as there are different NN architectures there are different training methods that can be used with NN’s. Back-propagation (BP) is one of the most popular training methods used with FFNN. BP is a supervised training method that uses a set of input/output data pairs to train the network. When receiving the data, the input neurons receive the input training data, and the output neurons generate the target data, the network may have one or more hidden layers, from the input/output data the network computes the error; the BP works to reduce this error. The training of the network starts with random weights and bias values, then these values are adjusted until we get the best performance of the network; at this point the network has reduced the error to the minimal value [12]. After successful training the network is capable of dealing with any new data values to find the correct output data. Equation 5 is used to calculate the error value: =

∑(

… (5)

( ))²

( ) represents the activation of the ith neuron, in the output layer , is the target value. The weights are updated using the gradient decent technique: ( )

=

( )

+

( )

+



( )

…(6)

Equation 6 calculates the new weight value, where is the weight value, is the learning step, υ is the momentum gain and ( ) represents the change of the weight in the previous cycle. The network keeps changing the weights values until it reaches the acceptable error value; the lower the error the more traning cycles and traning time needed. The NN may have one or more hidden layers, the more the hidden layers the more efficient the network, but the more complex the

654

structure, requires more processing time and is more expensive for implementation. Two transfer functions (TF) were used for traning the network, the Tan-Sigmoid (tansig) tranfer function and the linear (purelin) transfer function. The tansig TF accepts any type of data between the range of (± ∞) and generats an output between (-1,1). The second tranfer function is the linear TF, which is used after the tansif TF to make the output go back to the same range, rather than having the output between (-1,1). As a rule of thumb any NN that has a tansig TF in the hidden layers and linear TF in the output layer can generalize any type of non-linear functions. Figure 4 shows both TF’s used in the training metod.

Figure 4. NN Transfer functions.

For the tansig TF the mathmatical representation is: =

…(7)

For the linear TF the mathmatical representation is: =

…(8)

I. NEURAL NETWORK MODELS For simulation purposes it is very important to have a mathematical model for the DC Servomotor, it is also important to have a dynamic model of the servomotor using NN, the NN servomotor model was built using a FFNN. This NN servomotor model is very useful for both off-line simulation and for the academic and research use. Besides the NN motor model, we used a second NN, which is the controller model; this NN controller model was built using a FFNN. The training sets of data used for both models were obtained using MATLAB® Simulink. A. DC Servomotor Neural Network Model The block diagram of the motor model is shown in Figure 2, all nonlinearities were added to the system to make sure the NN motor model will act the same way as the real servomotor. The completed Simulink motor model is shown in Figure 5.

The input data from the test signal, and the output data from the model were obtained and recorded in different files, the data files were used to train a network that has the same function as the servomotor. The structure of the motor NN model consists of 5 neurons in the hidden layer, with tansig TF, and linear TF in the output layer. The selection of the number of neurons in the hidden layer and the transfer functions came from simulation results for the network with different number of neurons and different transfer functions. Figure 6 shows the result from the Simulink motor model and from the NN motor model. From Figure 6, we can see how the neural network was able to mimic the function of the servomotor; both output signals were completely compatible, with the NN being successfully trained. The performance of the network was very high, the network took 24 epochs to reach the pre-defined acceptable error of 0.00005. This very small error between the actual network output and the desired output confirms the high efficiency of the network and that it is able to mimic the servomotor function. With the successful training of the network, we have a dynamic NN model that can be treated as the real servomotor and can be used for testing the servomotor controller. The dynamic NN model is very important because it can be used for off-line simulation in the lab and classroom purposes, with a high efficiency and reduced time simulation results. To generate the complete NN system. A single command in MATLAB® can do the transfer process from the NN code to a NN Simulink block: gensim(net,ts) is the command used for this purpose. In this command the net represents the trained NN network, and ts represents the sampling time, for a continuous sampling it should be set to (-1). The generated NN motor model Simulink block is shown in Figure 7. Figure 8 shows the internal structure of the NN motor model. B. PID Controller Model and Responce Initially, a PID controller was used to control the motor’s model to compare the system’s performance. A PID tuning technique was used to get the best possible gains. P = 20, I = 2 and D = 20 were the best gains for the controller. The PID system still suffers from slow response, non-linear effects and it is not able to deal with sudden change in the dynamics of the environment, such as a sudden change in the load attached to the motor, which keeps the system in the low performance range for some types of time critical and high efficient systems. Figure 9 shows the response of the system with the conventional PID controller at different frequencies.

Figure 5. Simulink Servomotor model

655

Figure 9. System response with different frequencies

II.

NEURAL NETWORK COMPLETE SYSTEM

The final system consists of both the NN motor model and the NN controller model. Figure 6. Simulink motor model output position and NN motor model output position.

Figure 7. NN motor model

Figure 8. NN motor model internal structure.

From Figure 9, it is clear that when the frequency increases the system response changes, and for frequencies higher than 10 rad/sec the system response started to be bouncy, this effect is clearly shown on the system response for 50 rad/sec signal. All of the three responses were obtained with the PID controller tuned and integrated with the servomotor system. The PID controller was able to improve the system performance; this is clear from the signal shown in Figure 6 compared to the first signal in Figure 9, while keeping the frequency fixed to 2.5 rad/sec. It is clear that the control system reduces its efficiency at higher frequencies, which makes the PID controller not very efficient when dealing with applications that have nonlinearities and outside dynamic factors affecting it. The change of the frequency can represent a sudden change of the load, or any other change in the dynamics of the system environment.

A. NN Controller Model The training data for the NN controller was obtained from the PID model. Both the input and output signals of the PID controller were recorded and stored in different files to use them for the training purposes. The structure of the NN controller has 25 neurons in the hidden layer, tansig TF was used for the hidden layer and the linear TF was used for the output layer. The acceptable error was set to 0.0005, which makes the output of the NN and the required output to be very close to each other. The training process took 17 epochs to reach the acceptable error. Figure 11 shows the input/output signals of the NN PID controller, and Figure 12 shows the response of the NN controller after training. By comparing both figures it is very clear that the NN controller was able to mimic the PID controller function, but the NN controller shows improved performance compared to the conventional PID controller. From the second signal in Figure 11, we can verify how close the two signals are from each other, each graph has different scale, but the training performance was very high, and an acceptable training error was achieved, meaning that the NN controller model is ready and can be integrated with the NN motor model to get the response of the complete controlled servomotor response. B. NN Complete System A complete system with the NN motor model and the NN controller model was connected with negative feedback. The overall system response was recorded. Figures 12 and 13 show the response of the complete NN system. From both the controller and system outputs, it is clear that the NN system response is following the controller response, which makes the system performance better than with the PID controller. Also the NN system was able to deal with the changes in the input frequency. The PID controller was not able to eliminate any bouncing for the 50 rad/sec

656

signal, but the NN controller was able to deal with it and make the system immune to the frequency changes. The PID was suffering from spikes and sudden high rise in the output signal, which may drive the system to unstable response at some point when we expect the system to have a continuous operation. The NN controller was able to control the system and eliminate all the non-linear effects associated with it, the NN system was able to deal with high frequencies, and follow the NN controller response. The only drawback about the NN system response is the shift of the signal from the zero level, which can be eliminated by adding an offset to the input.

conventional PID controller; which makes the NN controller suitable for such types of systems, especially if high efficient controllers and systems are required for the needed application.

Figure 12. System Output Signal with 2.5 rad/sec input signal

Figure 10. PID controller input/output signals

Figure 13. System Output Signal with 2.5 rad/sec input signal

REFERENCES [1]

Figure 11. NN Controller model response

III. CONCLUSIONS In this paper we presented two Neural Networks a) DC Servomotor NN model, the NN model was built using the feed forward neural networks and back-propagation, b) Neural Network controller; which was built using the same type of neural networks. The proposed NN motor model was able to mimic the function of the DC Servomotor; which is very important for both off-line simulation, research and for the class room level. The NN controller has improved efficiency over the conventional PID controller, the NN controller was able to improve the system performance and to eliminate the n-on-linear effect found in the original system, also the NN controller has shown high efficiency when dealing with high frequency input. The overall NN system response was better than the system with no controller and the system with

Kandel E, Schawrtz JH and Jessel TM. “Principles of neural science”. 2000. [2] Hagan T. Martin and Howard B. Demuth. “Neural network design”. PWS Publishing Company.1996. [3] Mahanijah Md Kamal and Nasirah Mamat. “Controller design for servomotor”. IEEE symposium on Industrial Electronics and Applications. Malaysia 2009. [4] Jun Oh Jang. “Neural network saturation compensation for dc motor systems”. IEEE Transaction on Industrial Electronics. Vol 54, June 2007. [5] Miller W.T, Sutton R.S. and Werbos P.J. “Neural network for control”. MIT Press, Cambridge, MA (1990). [6] Matthew F. Borowski. “Analysis and control of a dc electric drive exhibiting dead zone characteristics”. University of New Hampshire, Department of Electrical and computer Engineering. [7] Nizar J. Ahmad, Adel A. Zerai and Muhammad Al- Mumin. “A new continuous time adaptive backlash inverse controller and applications to output backlash compensation”. Department of Electrical Engineering Technology, College of Technological Studies. Kuwait 2003. [8] Norman S. Nise. “Control system engineering”. 5th ed, John Wiley and sons Pte Ltd. 2008. [9] Robert N. Bateson. “Introduction to control system technology”. Prentice Hall, Inc. Upper Saddle River, New Jersy. 1999. [10] Haykin Simon. “An introduction to feed forward networks”. 1999. [11] Demuth Howard and Beale Mark. “MATLAB neural network toolbox documentation”. 2004. [12] Siri Weereasooriya and M. A. El-Sharkawi. “Identification and control of a dc motor using backpropagation neural networks”. Vol 6. IEEE Transaction on Energy Conversion. 1991.

657

Suggest Documents