Optimization of Fuzzy Logic Controllers by Particle Swarm Optimization to Increase the Lifetime in Power Electronic Stages Optimization of Fuzzy Logic Controllers by Particle Swarm Optimization to Increase the Lifetime in Power Electronic Stages

In recent years, brushless direct current motor (BLDCM) applications have been increased due to their advantages as low size, mechanical torque, high-speed range, to mention some. The BLDCM control is required to operate at high frequency, high temperature, large voltage, and quick changes of current; as a result of this kind of operation, the power drive lifetime is affected. The power drives commonly utilized insulated gate bipolar transistors (IGBTs) and metal oxide semiconductor field effect transistors (MOSFETs), which present power losses, on-state losses, and switching losses caused by temperature oscillations. Hence, the power losses are related to the command signals generated by the controller. In this sense, the BLDC motor drive controller design, frequently, does not take into account the power losses and the temperature oscillations, which cause the IGBT lifetime decrease or premature fail. In this chapter, a brushless DC motor drive is designed based on a fuzzy controller tuned with the particle swarm optimization algorithm, where the temperature oscillations and speed set points are considered in order to increase IGBT module lifetime. The valida-tion of the proposed fuzzy-PSO controller is carried out by the co-simulation between LabVIEW ™ and Multisim ™ and finally analysis and conclusion of the work.


Introduction
In this chapter, a design of a BLDCM speed control based and tuned by particle swarm optimization is presented; this proposal control considers two objectives, the first one is the speed set point and the second one is the power electronic lifetime. The BLDC motor covers a wide range of applications in several fields as the robotic systems, aerospace industry, medical industry, automotive industry, and electronic devices [8,17,25,32]. Their structure of control is integrated by BLDC motor stage, power drive stage, and sensor stage. The power drive is integrated by semiconductors as IGBTs and MOSFETs, these semiconductors frequently work under high thermal stress to reach the mechanical reference of speed, and in some cases, after a certain period of operation, they are damaged due to the generation of command signals by the speed controller [7,9,12,23,34,35]. There are several methods to predict and evaluate the lifetime of power electronics devices [34], the manufactures develop these studies as an estimation of certain conditions and operation features, but in some applications, these conditions are not always the same and change according to the control objective, which affects the power electronics lifetime used. For these reason, it is important that the controller design not only considers the mechanical references such as position and velocity in the case of BLDCM, as well as the lifetime of semiconductors [10, 22,23,24,33,34,35]. Hence, a great effort for predicting and improving the lifetime in semiconductors has been pushing to develop new control algorithms that help to improve the conditions in the semiconductor [16]. In this chapter, the designed controller uses an optimization process based on an objective function that takes into account the temperature of the power electronic stages in order to increase their lifetime, and tracking motor speed reference [1,10]. Thus, PSO algorithm has been implemented to optimize the controller proposed as in [13,18,21,27,30], due to its few parameters that need to be tuned and its easy implementation. Finally, the proposed controller in BLDCM is validated through co-simulation, which helps to combine two or more specialized programs utilizing advanced models and avoiding implementation problems between the control systems and power electronics stage [11,14,15].

Types of BLDCM drives
The BLDC motor drive employs a permanent magnet alternating current; the stator windings are commonly star connection, when voltage source is applied between any two terminals, the current flows between two phases, leaving one of the three without energy, and as a result, only one current at a time needs to be controlled. This kind of operation is known as back electromotive force (EMF) and Figure 1 shows the waveform in the BLDC motor with two phases active.
According to their physical position, the output is related to 60 or 120 phase shift to each other. To drive the windings, a sequence of commutation is necessary; this kind of operation is commonly called "six-step commutation." The trapezoidal waveform is due to the rotor revolving in a counterclockwise direction, for example, to phase A, after the 120 rotation to the top conductor of phase.
The motor position must be measured by three Hall effect sensors (A, B, and C) so a voltage is sent to the specific coils to control the speed and position of the brushless motor [3,25]. A standard circuit to drive BLDCM in Multisim™ program is shown in Figure 2.

States space model
According to [25], the BLDCM can be represented by Eq. (1) where R is the stator resistance per phase, i as , i bs , and, i cs are the stator phase current, and e as , e bs , and e cs are the rotating back-EMF that are produced by the winding flux linkage caused by rotating rotor.
where windings are symmetrical, the self-inductance will be equal, and so as the mutual inductance, L as ¼ L bs ¼ L cs ¼ L and L ab ¼ L bc ¼ L ca ¼ M. The electromagnetic torque is given in Eq. (4): and, the complete model of the electromechanical system is described by Eq. (5): where T l is the load torque, J is the rotor moment of inertia, and B is the viscous coefficient.

Semiconductor losses
Power losses can be classified as on-state losses and switching losses. The IGBT power losses in on-state are calculated by Eq. (6): and the diode power losses in on-state are calculated by Eq. (7): These can also be estimated using datasheet information of Figure 3. On the other hand, the IGBT energy losses in turn-on are given by Eq. (8): and, the energy losses in turn-off are given by Eq. (9): On the other hand, the diode energy losses in turn-on are mostly presented when the reverserecovery energy occurs, and they are given by: The switch-off losses in the diode are commonly neglected E offD ≈ 0. In consequence, the switching losses in the IGBT are calculated in Eq. (11) as: In the case of a diode, they are given as the product of switching energies and the switching frequency F sw as shown in Eq. (12).
Finally, the total losses are calculated by Eq. (13).
Besides, the IGBT and diode switching losses can be estimated from characteristic curve provided by datasheet of manufactures as shown in Figures 3, 4 and 5, respectively [5]. Using the equivalent circuit of Figure 6(a), where W is a module power loss, T j is the junction temperature IGBT chip, T f is the heat sink temperature, T c is the module case temperature, T a is the ambient temperature, R th jÀc ð Þ is the thermal resistance between case and heat sink, R th cÀf ð Þ is the contact thermal resistance between case and heat sink, and R th f Àa ð Þ is the thermal resistance between heat sink and ambient air. The junction temperature T j can be calculated using the thermal Eq. (14), according to [1,10].
Modeling of commutation and conduction losses as well as the temperature profiles on IGBT junction is done by electrothermic networks considering averages on a modulation period as shown in Figure 6(b).

Power cycle life
The power cycle life can be calculated from the power cycle capability curve that shows the relation between the temperature change ΔT j and the number cycles. An example of the temperature changes is shown in Figure 7.  During the ΔT j power cycle tests, the junction temperature goes up and down in a short time cycle; as a consequence, the temperature difference between silicon and bonding wire results in thermal stress. The ΔT j power cycle lifetime is mainly limited by the aluminum bonding wire joints. Figure 8 shows the power cycle capability curve of the IGBT module to ΔT jmin ¼ 25 C and to ΔT jmax ¼ 150 C according to [5].
On the other hand, the cycles before failure (CBF) can be calculated by Eq. (15), according to [28,29].
where Δ T ¼ P t Z th , P t ¼ I 2 rms R on , and Z th ¼ 2:3354F À0:165 r , and the time before failure (TBF) can be calculate in years by Eq. (16).
where F r is the frequency of the thermal oscillations [5,29]. Table 2 shows the parameters of IGBTs, which are considered in Multisim co-simulation; these parameters are obtained from datasheet of IGBT 10-0B066PA00Sb-M992F0 [24].

Fuzzy logic controller
The fuzzy logic was proposed in [26] as a class of fuzzy sets with a continuum grade of membership; hence, a useful methodology to design fuzzy logic controllers is based on a linguistic phase plane [19,20] as shown in Figure 9, where the error e t ð Þ, change of error _ e t ð Þ , and the variation of current i c are considered as membership functions in the fuzzification stage. Figure 9. Linguistic phase plane. Thus, Eq. (17) is defined as the sum of control error (e c ) and error of temperature (e t ), where e c is defined as the difference of the desired speed e d and the real speed e r ; on the other hand, e t is defined as e t ¼ e td À e tr , where e td is the desired temperature and e tr is the real temperature.

Rules
The design of membership functions is according to Mamdani method; the knowledge base can be expressed as if-then statements to design a rules base, which is shown in Table 1. At last, the defuzzification stage gets a crisp value from the rule evaluation stage. Hence, the method of the center of gravity is used to compute the crisp value and is given by Eq. (19).
So that, the fuzzy control design is carried out by means of the linguistic plane and the rules presented in Table 1. Thus, the controller with small/big rise time as well as small/big overshoot is possible.

Particle swarm optimization
Particle swarm optimization (PSO) was developed by [4]; this method is based on the behavior and movement of bird flocks looking for targets; this algorithm was developed to optimize nonlinear and multidimensional functions as in [13,18,27,30,31]. PSO algorithm needs to initialize the population in a random manner; each particle has a position x i t ð Þ and velocity v i t ð Þ with respect to target; then in main loop stage, the x i t ð Þ and v i t ð Þ update each iteration; this information is called best local position P i t ð Þ; on the other hand, between all population, there exists a particle that is more closest with respect to the target and it is called global best g t ð Þ. Additionally, the position and velocity update are defined by: where • i ¼ 1, 2, …, N, and N is the size of population; • j ¼ 1, 2, …, D, and D is the number of dimensions; • k ¼ 1, 2, …, iter, and iter is the maximum iteration number; • x ij k ð Þ is the position of particle i, dimension j at iteration k; • v ij k ð Þ is the velocity of particle i, dimension j at iteration k; • P ij k ð Þ is the local best position of particle i, dimension j at iteration k; • g j k ð Þ is the global best; • ω is an inertia factor; • C is an acceleration constant; and • r 1 , r 2 are the independent random numbers, uniformly distributed in 0; 1 ð Þ.
Thus, the primary objective is to find a minimal global value from the cost function to be minimized as it is shown in the next pseudocode [31].
For each particle of population N,

1.
Initialize the position of each particle.
Step 2. Repeat until the criterion is satisfied.
For each particle of population N,

1.
Set random numbers to r 1j and r 2j .

Update its position with Eq. (21).
4. If x ij k ð Þ < P ij k ð Þ, then a. Update the best local position.
b. If P ij k ð Þ < g j k ð Þ, then update the best global position g k ð Þ.
Step 3. Get the best solution g k ð Þ:

Design of fuzzy-PSO controller
The design of controller considers two objectives, the first one reaches the desired motor speed, and the second one is the increase of the semiconductor lifetime. The design of fuzzy-PSO controller to the speed control of BLDCM is based on the diagram shown in Figure 11, where μ d is the desired speed and temperature, μ t is the temperature sensed, and μ c is the speed sensed. Furthermore, one of the leading features is the definition of objective function; this is considered as the sum of error of temperature e t and error of speed e c , which is given by Eq. (22).
where e t is the difference between the desired temperature and the operating temperature; on the other hand, e c is the difference between the desired speed and the real speed. In optimization   process, Eq. (22) is defined as the cost function to be minimized, and each membership functions proposed in Figure 10 are considered as a decision variable; finally, the mechanical capacity of BLDC and thermal capacity of IGBT shown in Table 2 are the constraints of the controller optimization.

Co-simulation design
The experimental frame is a set of assumptions to obtain the behavior trace and compare it with a real world, which is carried out by co-simulation in order to analyze its dynamic response during a specific period of time [6]. Hence, co-simulation helps to validate how it works under specific assumptions [2,6]. The problem solution of speed control and lifetime of power electronic components is developed with co-simulation tool of Labview™ and Multisim™, where the BLDCM, the Hall effect sensors, and the six steps are simulated in Multisim™ and the parameter design of the BLDCM, the six IGBT 10-0B066PA00Sb-M992F09 [24], and the six-steps inverter are shown in Table 2.
The proposal control is developed in Labview™ software and its response is shown in Figure 14, and the PID and fuzzy control are developed with control design and simulation module and fuzzy logic toolkit [19]; moreover, PSO algorithm is also developed in Labview™, and their parameters are shown in Table 3.
Finally, the primary purpose of co-simulation is to analyze the complete behavior of the electric drive with the proposed control.

Discussion and results
The proposed control considers two control objectives, the first one is to track the speed reference and the second one is to keep the desired temperature to increase the lifetime of the IGBTs. Furthermore, the fuzzy-PSO trade-off was tested with PID and fuzzy controllers in co-simulation program, which were evaluated under 25, 30, 35, 40, 60, 80, and 100 C as a temperature desired, 10 and 5 m/s as the reference speed, respectively. As a result, the PID controller response reaches set point of speed in a short time, but it does not present an improvement in the temperature of semiconductors. The fuzzy logic controller improves the response when the desired temperature values are at 40 and 60 and fuzzy-PSO controller presents the best response in order to accomplish the control objective because they reduce the overshoot of current when it reaches the temperature and reference speed. Figures 13 and 14 show the response of controllers, and Figure 12 shows the final membership function adaptation of fuzzy-PSO controller.  (15) was computed to take into account the maximum temperature T jmax , the change of temperature, ΔT ¼ T jmax À T f , and the IGBT datasheet. Table 5 shows the calculation of TBF of the PID, fuzzy, and fuzzy-PSO controllers according to Eq. (16), and Figure 15 shows the behavior of the TBF versus temperature, where the fuzzy-PSO controller reaches a longer lifetime.

Conclusions
In this chapter, a control design that takes into account the power electronics lifetime stage and the speed set point for BLDCM is presented. The objective function of optimization is integrated with the error of power stage temperature and the error of BLDCM speed. A voltage source inverter with six IGBT to drive the BLDCM is considered as power stage, where the current temperature in the power electronic stage, reference temperature, current motor speed, and reference motor speed are considered in the controller design. The PID controller, fuzzy logic controller, and fuzzy-PSO controller were designed and validated by NI Labview™ and Multisim™ co-simulation software. As a result, the fuzzy-PSO controller obtains a good response that increases the lifetime and reaches the set point desired due to the time that it takes to reach the desired speed increases but it reduces the overshoot of current during the transition time which produces minimal stress and degradation of the power electronic components.