Cmjv03i03p0248

Page 1

J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

DC Motor Control Using Fuzzy Logic Techniques GIRIJA M. NIMBAL and S. V. HALSE Department of Electronics, Karnataka State Women’s University, Bijapur, INDIA. (Received on: February 2, 2012) ABSTRACT Fuzzy logic controller for the speed control of DC motor has been carried out in this paper. In the present study for the FLC, 7 numbers triangular membership functions are used for fuzzyfication, Center of Gravity Center of Maximum and Mean of Maximum methods are used as three different methods for defuzzification and if-then rules are used for decision-making logic experimental setup is done using lab view, signal condition extension for instrumentation cards, data acquisition board fuzzy logic toolkit all from national instruments, USA. For a rated speed of 1000 rpm speed control of DC motor is done by the said fuzificatio method and three defuzzification methods separately. Corresponding graphs of speed verses time are obtained. From the graphs it is concluded that number of triangular membership functions for fuzzification and COG method for defuzzifactionare the best choice for the speed for the speed control of the Dc motor in our present study. Keywords: Fuzzy logic Controller, Fuzzification, Defuzzification, DC motor.

INTRODUCTION Fuzzy logic controllers have been used to provide solutions to control systems, which are ill defined too complex to model etc. The field of fuzzy control systems is one of the most active and fruitful areas of research in which fuzzy set theory are applied. Fuzzy logic provides an effective

means of capturing approximate and inexact nature of the real world control problems. The incorporation of fuzzy set theory and fuzzy logic into computer models has shown tremendous payoff in areas where intuition and judgment still play major roles in the code. Control applications, such as temperature control, traffic control, Dc motor speed control ect, are the most

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


249

Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

prevalent of current fuzzy logic applications. Fuzzy logic controllers can be well suited to control a system with uncertain, complex inaccurate or nonlinear dynamics. Fuzzy controllers, contrary to classical controllers, are capable of utilizing knowledge elicited from human operators. The Dc motors are widely used in the variable speed applications due to the case of speed control. In closed loop system the speed can be maintained constant by adjusting the motor terminal vole. Smaller Dc motors operate at low voltages, which make them easier to interface with control electronics. Fuzzy logic which is based on fuzzy set theory was originally developed by Zadeh in 1965. During the past several years. FLCs are widely and successfully implemented for the speed control of motors zazo-Rodriguez et al. Used triangular membership functions and COG defuzzification method to get accurate output for any set point for a SISO nonlinear level process. Xie Kanglin and Fu Jinyou presented the problem of how to find the most thee optimal fuzzy rules and input/output membership functions in developing a fuzzy system. Castro reported how many rules are necessary to get a good fuzzy controller for a control problem in his paper. Eminoglu and atlas presented the effect of number of rules on the output of a FLC employed to a PMDC motor. They tested the sensitivity of the FLC with respect to the variations in the rules decision tables by changing the original decision table values in the range of +30% Rao and Saraf reported theoretical study of defuzzification methods of FLCs for speed control of DC motor. An overview of defuzzification methods was prepared by Hellendoorn and

Thomas. General classes of parameterized defuzzification methods were explored by filev and yager. A defuzzification based upon the principle of uncertainty invariance was proposed by Kit. An interesting strategy for dealing with the defuzzification problem, based on sensitivity analysis was developed by Mabuchi. Various fuzzification and defuzzification methods have been proposed in the literature. The efficiency of FLCs depends very much on the choice of fuzzification and defuzzification methods. Hence the present work has been carried out to study the fuzzification and defuzzfication methods of FLC for the speed control of the DC motor using lab view SCXI cards, DAQ board and fuzzy logic toolkit all from NI USA. To the best of our knowledge such studies on DC micro motor based on hardware and software packages from, NI USA are not reported. Hence the present study has been undertaken. This type of systematic study is necessary for further analysis control of DC motor. Fuzzy Logic Controllers The purpose of fuzzy logic controller is to compute value of action variables from lathe observation of state variables of the process under control. A fuzzy logic algorithm consists of situation and action pair of the form if and then. A general fuzzy logic controller consists of four modules a fuzzyfication module, a fuzzy rule base a fuzzy inference engine and defuzzification module. The interconnection among these modules and the controlled process are shown in figure.1

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

Actions

Defuzzifi -cation Module Fuzzy Inference Engine

Controlled Process

Conditions

250

Fuzzy Rule Base

Fuzzification Module

Fig.1 General Block Diagram of FLC

A fuzzy controller operated by repeating a cycle lot following steps. 1. Measurements are taken for all variables that represent the relevant conditions of the controlled process. 2. These measurements are converted into appropriate fuzzy sets to express measurement uncertainties.This is called fuzzification. 3. These fuzzfied measurements are then used by the inference engine to evaluate the control rules stored in the fuzzy rule base. The result of this evaluation is a fuzzy set defined on the universe of possible actions. 4. This fuzzy set is than converted into a single crisp value that in some sense is the best representation of the fuzzy set. This conversion is called a defuzzification the defzzifified value represents actions taken by the fuzzy controller in individual control cycles.

By identifying the relevant input and output variables of the controller and ranges of their values, we have to select meaningful linguistic states for each variable and express them by appropriate fuzzy sets. These fuzzy sets are fuzzy numbers, switch represent linguistic labels, negative lathe negative medium. Negative small zero positive small, positive medium and positive large. To characterize the steps involved in designing a fuzzy controller, two conditions are usually monitored by the fuzzy controller one is error another one is change in error the fuzzy controller produces values of a controlling variable cu which represents relevant control action. The variations of e, ce are shown in fig (2a) and fig (2b) by using 7 number triangular membership functions. Table (1) & (2) shows an set points of lingvestic variables for output voltage and error input.

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


251

Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

Fig. 2(a) Seven Triangular Membership Function For Output Voltage

Table1: Set points of lingvestic Variables for Output Voltage

NL NM NS ZE PS PM PL

Left Bottom

Left Top

Right Top

Right Bottom

-1.000 -0.826 -0.509 0.104 0.006 0.239 0.471

-1.000 -0.565 -0.260 0.000 0.348 0.491 0.685

-0.834 -0.560 -0.257 0.000 0.348 0.495 1.000

-0.548 -0.195 0.000 0.104 0.771 1.000 1.000

Fig. 2(b) Seven Triangular Membership Function For Error Input Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

252

Table2: Set points of lingvestic Variables for Error Input Left Bottom

Left Top

Right Top

Right Bottom

NL

-1000.000

-1000.000

-826.840

-666.667

NM

-861.472

-545.255

-537.746

-212.121

NS

-535.625

-284.862

-282.060

0.992

ZE

-116.883

0.000

0.000

116.883

PS

4.329

277.787

280.982

523.810

PM

277.056

584.416

584.416

857.143

PL

643.027

809.923

1000.000

1000.000

respectively for 7number triangular membership functions. Defuzzification is the conversion of a fuzzy quantity to a precise crisp quantity as practical applications need crisp control action. There are mainly three methods of defuzzification in the literature on fuzzy control. They are COG, COM, and MOM methods. In the present study fuzzification and defuzzification methods are applied separately for the real time speed control of the DC motor.

The rules are generated as follows If error (e) is PL and chances in error (ce) is NM, THEN change in control (cu) is PS. Rule base editor consists of fuzzy control rules that are of the form IF and THEN. These rules decide the working of FLC. For the specific applications of speed control of DC motor, we design a rule base editor shown in fig 3 and it has 49 terms

ce

e

e\ce PL PM PS ZE NS NM NL

NL ZE NS NM NM NL NL NL

NM PS ZE NS NM NM NL NL

NS PM PS ZE NS NS NM NL

ZE PL PM PS ZE NS NM NL

PS PL PM PS PS ZE NS NM

PM PL PL PM PM PS ZE NS

PL PL PL PL PM PM PS ZE

Fig. 3 Rule Base Editor

Experimental set up The experimental set up for the speed control of DC motor is shown in fig 4. The explanation of each block is given below.

The DC micro motor (2230U 015S) used in this application is a product from Faulhaber DC motors, Minimotor SA 6980 Croglio, Switzerland. Minimotoor products are based on the patented self supporting skew wound coil technology. The main

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


253

Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

features of these micro motors are less weight, low power, high speed etc., and the

lifetime of these motors vary from a few hundred hours to more than 10000 hours.

Fig. 4 Block Diagram for Control of DC Motor Using FLC

The specifications of DC micro motor (2230U 015S) are: • • • • • • • •

Nominal voltage Output power No load speed No load current Operating temperature range Commutation Magnetic material Weight

Optical Encoder and Frequency to Voltage (F/V) Converter: The optical encoder is a transducer that is connected to the shaft of the DC micro motor, which converts the speed of the motor into corresponding frequency. The optical encoder used in this application produces 12 pulses for one revolution. IC LM 2907(F/V Converter) Converts these TTL compatible pulses into the corresponding voltage. The output voltage of F/V converter is directly proportional to the speed of the DC motor.

: 15V : 2.63W : 8400rpm : 0.007A : -30C to85C : Precious metal : ALNiCo : 50gms SCXI Cards SCXI cards from NI, USA used in this application are CXI 122 analog input card and SCXI 1124 analog output card. These SCXI cards do the job of signal conditioning like amplifications, filtering linearization, isolation etc. DAQ Board PCI-MIO-16E-4 DAQ board of NIUSA is used in this application. This board consists of analog to digital converter,

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

digital to analog converter and counters. Lab view software uses this board for accessing the signal from SCXI cards. Lab view The speed control of DC micro motor is realized in PC using Lab view software package. Is a graphical programming language that uses icons instead of lines of text to create application? In contrast to text based programming languages where the flew of data determines program execution. Lab view use data flow programming where the flow of data determines execution.Labview programs facilitate virtual Instrumentation because their appearance and operation imitate physical instruments such as oscilloscopes millimeters etc. Lab view can be made to connect to the outside transducers and actuators through DAQ board and SCXI cards. The signal from the Transducers is accessed from SCXI analog input card and DAQ board through Lab VIEW. Similarly, control action to the actuators is given from Lab view through DAQ board and SCXI analog output card. We can add several software toolset for developing specialized applications. For Example, fuzzy logic tool kit has been added for measurement and control in the present study. Actuator The voltage from SCXI card cannot drive the motor directly due to mismatching of power. Hence a voltage follower with Darlington pair is added as an actuator to drive the motor.

254

METHODOLOGIES The main objective of our work is to measure the real time speed of DC micro motor and to control it for the desired speed. The shaft of DC micrometer is connected to the optical encoder which converts the speed of DC motor into a train of TTL compatible uses. This trai of pulses or frequency is not directly accessible by the SCXI 1122 analog input card since this card needs the signal to be in analog voltage form. Hence this frequency is converted into voltage by frequency to voltage converter using ICLM2907. The analog voltage which is rotational to the speed is accessed by LAB View I/O channel. This voltage is converted into corresponding frequency by the equation f=a1v+a0. This equation is fitted by least square curve fitting where f is the frequency of the signal generated from optical encoder and v is the output voltage of F/V converter a1= 80.156 and a0= 0.04276 are slope and intercept of the characteristics of DC micro motor. This frequency is converted into speed by the equation. Speed = (Frequency*60 seconds)*1/p rpm = (Frequency*5) rpm Where=number of pulses for one revolution. For the optical encoder used, 12 pulses are generated for one revolution. This is the measured DC motor speed. This is compared with the set value to get error. Error= Set value-Measured value. Similarly change in error=present error-previous error. These are the two inputs to the FLC. Using 3-number and 7 numbers triangular membership functions as shown in fig2a b, c respectively, the FLC fuzzified these two

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


255

Girija M. Nimbal Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012 2)

inputs. The ranges for these linguistic variables are chosen for optimized output. The fuzzy logic rules es are of IF and THEN form. Depending on the values of error and change in error rule base editor is formed as shown in fig 3. The output of FLC is also fuzzified using triangular membership is done by using COG, COM, and MOM methods separately to get pr present control action to be given to the motor. Lab view sends voltages to the motor through DAQ board and SCXI 1124 analog output card through I/O channel. Again this voltage from SCXI card cannot drive the motor due to mismatch of power. Hence a voltage

follower with Darlington pair is added as an actuator to drive the motor. Virtual Instrument Block Diagram for FLC using Lab VIEW The complete VI Block diagram for FLC using Lab view is shown in fig 5. The input voltage from F/V converter is accessed by y analog input channel. This analog voltage is converted into the corresponding speed by using operational amplifiers as adder and multipliers. First Double precision number represents the set value of 1000 rpm.

Fig. 5 VI Block Diagram for FLC Using Lab VIEW

The error and change in error are obtained by using two substactors. These two signals are fuzzified by triangular membership functions separately and defuzzified by the COG, COM and MOM methods in the fuzzy logic toolkit of Lab view package. When the fuz fuzzification study is carries out COG method is used for

defuzzification. Similarly when the defuzzificatio methods are studied, triangular membership functions are used for fuzzyfication. The output of FLC which is change in control action is added to the previous control action by another adder to get the present channel, which in turn controls the speed. The measured speed is

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421))


Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

displayed on the waveform chart on screen. All these events are carried out in a loop, which is shown with thick borderline. RESULTS AND CONCLUSIONS

the DC motor. Fig. 7 shows the graph of speed verses time for three defuzzification methods of FLC. Overshoot and undershoot is observed for MOM method, large settling time is observed for COM method as compared to the COG method for the real time control of DC motor. Hence it is obvious that COG defuzzification method gives better result. For robust, flexible and faster speed control of DC motor using fuzzy technique, triangular membership functions for fuzzification and COG defuzzification method are the best choices.

Speed in RPM

Fig. 6 shows the graphs of speed verses time for three fuzzification methods of FLC. It is found from the graph that for a set point of 1000 rpm, an overshoot is observed for 7 numbers triangular membership functions large settling time is observed. Hence, item is obvious that triangular membership functions for fuzzification is best for the speed control of

256

Time in Sec.

Fig.6 Comparative Study of Domain Responses of the tuned PID Controller and PC – based FLC for Speed control of the Swiss DC Motor Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


257

Girija M. Nimbal, et al., J. Comp. & Math. Sci. Vol.3 (3), 248-257 (2012)

Fig.7 Response of DC Motor for Three Defuzzification Methods

REFERENCES 1. D. Driankov, H Hellendoorn M & Reinfrank, An Introduction to Fuzzy Logic, Springer–verlag, Berlin Heidelberg, (1996). 2. Abraham Kandel & Gideon Langholz, Fuzzy control systems, CRC press, (1993). 3. Timothy J. Ross, Fuzzy logic with Engineering Applications, McGraw – (1995). 4. Klir G. J. & Bo Yuan, Fuzzy sets and fuzzy logic Theory and Applications, Prentice – Hall,Englewood Clifts, N. J., (1995). 5. Sen P.C,Principles of Electric Machines and Power Electronics, John Wiley and Sons,2nd ed., (2001). 6. Christopher T Killian, Modern Control Technology, West Publishing company, Minnespolis/St Paul, (1996).

7. Zadeh L A, Fuzzy Sets, Infonnation and Control, Vol. 8, pp 338 – 35, 1965. 8. Guillemain P, Fuzzy logic applied to motor control, IEEE Transactions on Industry Applications, Vol 32, no1, pp 51 -56, (1996). 9. Varga S, Farkas F & Halsaz S, Realization of a position controller by fuzzy Logic Proc 7th Int. Power Electronics and Motion Control Conf., Vol 3, pp 287 – 291, (1996). 10. Borges T T, De Azevedo H R, De Andrade D A & Goncalves C S, An application of fuuzy logic for reluctance motor drive, IEEE International Electronic machines and drives ,USA, TB1/10, 1- 3, (1997). 11. National Instruments Texas, USA,SCXI Getting Started with SCXI, (2000). 12. National Instruments Texas, USA ,DAQ PCI Series User manual, (1999).

Journal of Computer and Mathematical Sciences Vol. 3, Issue 3, 30 June, 2012 Pages (248-421)


Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.