High Performance of An Unified Power Quality Conditioner Based on a Fuzzy Logic

The quality of energy depends on the loads and their sensitivity to supply voltages variations. The loads being more sophisticated, the voltage disturbances become very expensive for the industrialists in term of loss of production and damage of materials. A universal solution for improving power quality in the network and protecting sensitive loads can be used by combination of the series – parallel active power filters called Unified Power Quality Conditioner (Han et al., 2006 Khadkikar et al., 2005 Reza et al., 2009). It is a versatile device that can compensate almost all types of perturbations such as voltage harmonics, voltage unbalance, voltage flicker, voltage sag and swell, current harmonics, current unbalance, reactive current, etc. A typical configuration of UPQC is shown in fig. 1. This paper is focused on voltage sag and along with current and voltage harmonics compensation based on fuzzy hysteresis band control. Initially, the equivalent circuit of the UPQC is presented. The control algorithm for parallel active power filter (PAPF) is discussed in section 3 and the control algorithm for series active power filter (SAPF) is discussed in section 4. The UPQC performances will depend on the design of power semiconductor devices, on the modulation technique used to control the switches, on the design of coupling elements (the decoupling inductance Lf for shunt part, the filter parameters Lfs -Cfs for series part and the DC link capacitor value Cdc), on the method used to determine active filters current and voltage references and on the dynamics and robustness of current and voltage control loops. For the PAPF, the standard instantaneous p-q algorithm is used to determine current references (Fujita & Akagi, 1998 Mekri et al., 2006). Among various PWM techniques, hysteresis fixed band current control is popularly used because of its simplicity of implementation. This known technique does not need any information about system parameters and has the disadvantage of uncontrolled frequency. As a result, the switching losses are increased and current sources contain excess ripples. The current controller performances can be improved by using adaptive control system theory (Rahman et al., 1997Tzou & Shiu, 1998). An adaptive hysteresis band current control PWM technique can be programmed as a function of supply and APF parameters in order to maintain a fixed modulation frequency. Unfortunately, adaptive control is very sensitive to


Introduction
The quality of energy depends on the loads and their sensitivity to supply voltages variations. The loads being more sophisticated, the voltage disturbances become very expensive for the industrialists in term of loss of production and damage of materials. A universal solution for improving power quality in the network and protecting sensitive loads can be used by combination of the series -parallel active power filters called Unified Power Quality Conditioner (Han et al., 2006-Khadkikar et al., 2005-Reza et al., 2009. It is a versatile device that can compensate almost all types of perturbations such as voltage harmonics, voltage unbalance, voltage flicker, voltage sag and swell, current harmonics, current unbalance, reactive current, etc. A typical configuration of UPQC is shown in fig. 1. This paper is focused on voltage sag and along with current and voltage harmonics compensation based on fuzzy hysteresis band control. Initially, the equivalent circuit of the UPQC is presented. The control algorithm for parallel active power filter (PAPF) is discussed in section 3 and the control algorithm for series active power filter (SAPF) is discussed in section 4. The UPQC performances will depend on the design of power semiconductor devices, on the modulation technique used to control the switches, on the design of coupling elements (the decoupling inductance Lf for shunt part, the filter parameters L fs -C fs for series part and the DC link capacitor value C dc ), on the method used to determine active filters current and voltage references and on the dynamics and robustness of current and voltage control loops. For the PAPF, the standard instantaneous p-q algorithm is used to determine current references (Fujita & Akagi, 1998-Mekri et al., 2006. Among various PWM techniques, hysteresis fixed band current control is popularly used because of its simplicity of implementation. This known technique does not need any information about system parameters and has the disadvantage of uncontrolled frequency. As a result, the switching losses are increased and current sources contain excess ripples. The current controller performances can be improved by using adaptive control system theory (Rahman et al., 1997-Tzou & Shiu, 1998). An adaptive hysteresis band current control PWM technique can be programmed as a function of supply and APF parameters in order to maintain a fixed modulation frequency. Unfortunately, adaptive control is very sensitive to parameters system and its global stability is hard to be proved. A new technique, based on the same concept, but where the hysteresis band is implemented with fuzzy logic is proposed to optimize the PWM performances. For the SAPF, a robust PLL system is used for supply voltage disturbances identification. The PLL is developed to achieve good results under unbalanced, interruption or distorted voltage conditions based on a fuzzy logic regulator. Appropriate fuzzy hysteresis band voltage controller is also synthesized for SAPF output voltage control. Simulation results will be shown and discussed in the last section to verify the performances of the proposed UPQC in different conditions such as voltage and current harmonics.

Equivalent scheme of an UPQC
The UPQC is controlled in such a way that the voltage at load bus is always sinusoidal and at desired magnitude. The function of the PAPF is to compensate current harmonics, to maintain the dc link voltage at constant level and to provide the var required by the load. The SAPF serves us to mitigate the mains voltages perturbations. The single phase equivalent circuit for a UPQC is shown in fig. 2

Current reference extraction
The objective is to get sinusoidal line currents in phase with the supply voltages at the common coupling point. The well known instantaneous p-q algorithm is used to determine the current references (Akagi, 1996). The distorted supply voltages conditions may result in partial compensated source current. To overcome this problem, a robust PLL system is first used to extract the fundamental positive sequence voltage components. The generated sinusoidal voltage signals are then used as new inputs of the p-q algorithm for instantaneous current references extraction fig. 3. The PLL is a common block between PAPF and SAPF and will be detailed in section IV.

DC voltage control
In the UPQC the management of DC bus concerns the role of the PAPF. This one determines the active power (current) necessary to keep constant the DC voltage in steady state or transient conditions (Mekri et al., 2006). There are three principal factors that affect the voltage fluctuations of the DC capacitor. The first is the alternating power of the load to be compensated, the second is the active power imbalance during transients and the third is the active power absorbed by the SAPF part for compensating network voltage sag. If a power imbalance occurs; because of load changing or voltage dips; the PAPF should consume or supply real power. This power is given by: The active fundamental current necessary to ensure the balance of the active power called i 0 (t), must be sinusoidal and in phase with the supply voltage ( fig. 4). It combines of two fundamental components: The first fundamental component corresponds to the active power consumed by the series active filter during a long term voltage dip for the network, and the second term refers to the power losses consumed by the power transistors in both inverters.

Fig. 4. Block diagram of shunt APF control
If switching losses are neglected, the real power absorbed by the PAPF can be expressed as: The aim of the synthesized voltage regulator is to adjust 2 () dc vt to its reference, to reject the internal disturbance dI of the system due to the variation of real load power and to assure a good filtering of the external one dE relating to DC voltage ripple due to the alternating power (Mekri et al., 2006). To realize these objectives, a fuzzy logic controller is considered. It consists of fourth stages: fuzzification, knowledge base, inference mechanisms and defuzzification. The knowledge bases are designed in order to obtain a good dynamic response under uncertainty in process parameters and external disturbances. In our application, the fuzzy controller is based on processing the voltage error and its derivation e . The input variable 'e' is: Triangle shaped membership function has the advantages of simplicity and easier implementation and is chosen in this application (Tzou & Shiu, 1998-Xiong & Gatland, 1996. Fig. 5 shows the membership functions of the input and the output linguistic variables. In the design of a fuzzy control system, the formulation of its rule set plays a key role in improvement of system performances. The rule table is constructed to contain the 49 rules as shown in Table 1, where PL, PM, etc, are linguistic codes (PL: positive large, PM: positive medium, PS: positive small, ZE: zero, NL: negative large, NM: negative medium, NS: negative small). In this paper, we applied max-min inference method to get implied fuzzy set of the turning rules.

Fuzzy hysteresis band current control
The shunt active filter is realized with a current controlled PWM inverter. The core of active filter is the control section that must be able to derive the reference current waveform matching the harmonic content of the line current and to drive the inverter producing a filtering current faithfully tracking the reference one. So there are two sections: the reference current generation, that, the standard instantaneous p, q algorithm is used to determine the current references (Mekri et al., 2006-Akagi, 1996, and the current control. To compensate harmonics and fundamental reactive power, two current control methods can be considered, according that the regulated variables are respectively the line currents or the active power filter currents. Both methods are equivalent. In fact, the error signal at the input of the current regulator has the same dynamic and only its sign is modified Our algorithm will be focused on the following on calculating and controlling directly the mains currents. The objective is to get sinusoidal line currents in phase with the supply voltages at the common coupling point. The current control strategies, often used, can be classified in the hysteresis current control, the ramp comparison control methods (natural, asymmetrical or optimal PWM) associated with linear controller and the predicted current control. The first method is very simple and easy to implement, but has the disadvantage of an uncontrollable high switching frequency. This high frequency produces a great stress for the power transistors and induces important switching losses. The second and third methods allow operating at a fixed switching frequency and are usually performed by software using the system parameters. In this case, the operating conditions must be known to meet sufficient and accurate control (Xiong & Gatland, 1996). Consequently, a fuzzy hysteresis band circuit control for a sinusoidal input current is involved for our application. Fixed hysteresis band method is very sample and easy to implement, but has several known disadvantages such as uncontrollable high switching frequency and induced important switching losses. To improve this control, an adaptive and fuzzy hysteresis band current control technique is studied (Mekri et al., 2006). An adaptive hysteresis band current control PWM technique can be programmed as a function of the active filter and supply parameters to minimize the influence of current distortions on modulated waveform (Mekri et al., 2006-Jiang & Chang, 2004. The band (HB) can be modulated at different points of fundamental frequency of the cycle to control the PWM switching pattern of the inverter. The hysteresis band is given by: Where f m is the modulation frequency, i s * is the source reference current and * s di /dt represents its slope. Fig. 6 shows the block diagram of the adaptive hysteresis band current control using (5). Current control with an adaptive hysteresis band current control needs a precise knowledge of the PAPF parameters (L f and V dc ). To improve active filter performances, equation (5) is implemented in our case with fuzzy logic. In order to establish a fuzzy logic controller, input and output variables must be treated.

Series active power filter control
The main function of a series active power filter is the protection of sensitive loads from supply voltage perturbations such as sags or voltage harmonics.

Voltage reference calculation
There are various methods of the identification of the network voltage perturbations (Khadkikar et al., 2005-Awad et al., 2003-Svensson & Sannio, 2002. The proposed method is based on a robust PLL system and is able to detect quickly any voltage drop due to dips or flickers besides voltage harmonics in the network (figure 8) (Mekri et al., 2010). The PLL block allows to detect the amplitude and phase (V s andˆd θ ) of fundamental positive sequence components of the utility voltages. The direct component voltages (V sd1,2,3 ) will be subtracted from the instantaneous network voltages (V s1,2,3 ) to determine disturbing homopolar and inverse components (V dif1,2,3 ). The difference between the desired voltage amplitude (V nom-desired ) and the direct voltage amplitude provided by the PLL, gives, through Park inverse transformation, the regulated load voltages (V r1,2,3 ). Finally, the reference voltages (V ref-1,2,3 ), which will be used for control of the series active filter, are obtained by the sum of disturbing components (V dif1,2,3 ) and regulated load voltages (V r1,2,3 ).
The detailed block diagram of the PLL, which can be completely implemented in software, is presented in fig. 9. The PLL block allows to control of an estimated phase angle ˆd θ with respect to the angle s θ of mains voltage. Assuming that the measured voltages at the common coupling point are sinusoidal and balanced, the d-q supply voltage components are given by: According to (6) Thus, it is possible to control s θ by regulating V sd to zero.
The synthesized regulator must answer the following objectives: the control of V sd must be carried out without bias and with a fast dynamics, the predominant undesirable frequencies present on voltage component V sd under unbalanced mode (100Hz) or distorted conditions (300 Hz and 600 Hz) must be filtered by the regulator. For this purpose, several regulators are studied and compared to satisfy these constraints (Mekri et al., 2010). The functional diagram of the PLL based on a fuzzy PI regulator is shown in fig. 10 where E is the error and E is the derivation of the error. We choose the triangular and trapezoidal functions for the variables of entries and exit in the same manner than presented in fig. 5. They allow an easy establishment and the stage of fuzzification requires a little computing time during its evaluation in real time. The knowledge obtained on the behavior of the system is put in the form of rules, which are summarized in Table 1 of inference.

Series active filter output voltage regulation
The control part of the SAPF must be able to derive the reference voltage waveform with matching the harmonic content of the line voltage. A fuzzy hysteresis band control is adopted allowing operating at nearly fixed frequency which is detailed in (Mekri et al., 2010). The adaptive hysteresis band is given by: In order to establish a fuzzy logic controller, the input and the output variables are again treated. The voltage reference slope dV ref */dt and it derivation (V x (t)=d(dV ref */dt)/dt) are selected as input variables and HB as output variable. The following step is to determine the set of linguistic values associated to each variable. Fig. 11 shows the membership functions of the input and the output variables. The resulting rules are the same that presented in Table 2.

Simulation results
The system (UPQC) shown in fig.1 is simulated using Matlab/ Simulink software. The parameters of simulation are: V dc =700V, V s =220V-50Hz,L fs =4*10 -4 H,C fs =73 *10 -4 F,f c =8kHz, R s =0.5 mΩ, L s =11 µH and L f = 150µH . The non-linear load is composed by a diode rectifier feeding an R-L load (Rd=0.66Ω L d =4mH). Fig. 12 illustrates the behavior of the PLL block (see fig. 9) under excessive distorted and unbalanced supply voltages conditions. The rms values are V s1 =230V, V s2 =180V and V s3 =300V and the main voltages are affected by 5 th and 7 th harmonic components with individual harmonics distortion rate respectively 20% and 24,5%. These results of simulations show us that the application of fuzzy logic in the control loops makes it possible www.intechopen.com to fulfil the desired requirements concerning the locking of PLL, even under the most unfavorable conditions. The estimated pulsation is constant and the extraction of unity sinusoids synchronized with the direct supply voltages components at the point of common coupling (PCC) is quasi instantaneous. Fig. 13 shows the behavior of the UPQC under distorted supply voltages conditions. Before t=0.06s, the PAPF is operational. It shows that the source current is sinusoidal and in phase with the supply voltage. The THD of the source current decreases from 29,5% before filtering to 2%. At t=0.06s a sag (50% during 40 ms) is introduced on the system, both SAPF and PAPF are operating together as UPQC. Results show that UPQC is maintaining the load voltage sinusoidal and at desired constant level even during the sag. While SAPF is providing the required real power to the load, the PAPF is maintaining the DC link voltage at constant level and the source delivered more current. This extra power flows from source to PAPF, PAPF to SAPF via DC link and from SAPF to the load. The THD of the load voltage decreases from 27.5 % before compensation to less than 0.5%. The waveforms of the nonlinear load current i ch , the line current and its reference (i s , i s *), injected shunt active filter current i f and current error δ given by hysteresis fuzzy band current control for the PAPF are shown in fig. 14. The current error is reduced. The performance of the proposed control algorithm of the active power filter is found to be excellent and the source current is practically sinusoidal. The THD decreases from 29.5% before filtering to 2% for fuzzy hysteresis band control after filtering. Fig. 15 shows the response of the UPQC with 50% voltage sag. As it can be seen the voltage sag is very fast detected by the voltage perturbations identification method and compensated by the series part of the UPQC.

Conclusion
This paper demonstrates the validation of simpler control approach for the Unified Power Quality Conditioner based on the fuzzy logic. In the first, for the parallel active power filter while basing on the method of the instantaneous real and imaginary powers to identify the currents of references, and for determination of voltage references for series active power filter we based on a robust three-phase digital locked loop (PLL) using fuzzy logic regulator.
The PLL system has a good reliability, a fast tracking performances and assures a good attenuation of undesirable supply voltage frequencies. In other hand, the UPQC has shown the ability to compensate sag, unbalanced voltages and current and/or voltage harmonics based on a new hysteresis fuzzy band voltage and current control which constraints constant switching frequency without being influenced by parameters of active filter. The current and voltage bands can be easily implemented with fuzzy logic to maintain the modulation frequency nearly constant for each control. Simulation results confirms the viability of the proposed approach and proves that the UPQC, thanks to robust voltage and current controllers, allows to improve power quality by maintaining the load voltage at desired level even during unbalanced, distorted or supply voltage sag conditions. Therefore, the proposed control can easily be adapted to others more severe constraints 8. References