Comparative Study of a Photovoltaic System Connected to a Three-Phase Grid by Using PI or Fuzzy Logic Controllers

: This work presents a comparative study for a photovoltaic system connected to a three-phase grid through a three-phase inverter controlled by a fuzzy logic controller or through a proportional-integral (PI) controller. The innovative aspect of this article consists of the elaboration of two models in MATLAB–Simulink for the photovoltaic system consisting of 40 photovoltaic panels and of the control algorithms of the three-phase inverter for each type of controller. The comparative analysis of the results obtained through simulation has established that the use of the fuzzy logic controller (for controlling the three-phase inverter) leads to transferring to the alternative current (AC) grid an electric power of 6.5 kW, whilst the use of the PI type controller leads to transferring to the AC grid an electric power of 4.6 kW under the same value of the intensity of solar radiation. The total harmonic distortion (THD) of the voltage resulting after the ﬁltering circuit has a lower value in case of using the fuzzy logic controller than in case of using the PI controller. Through the usage of the fuzzy logic controller for controlling the inverter, an increase in quantity and quality of the electric energy introduced to an AC grid from a photovoltaic system was noticed, compared to the usage of a PI controller.


Introduction
It may be asserted that research pertaining to renewable energy sources is ongoing, providing new perspectives on the topic. Solar energy is the main source of renewable energy. Photovoltaic panels are used to convert solar energy into electric energy. Electric energy produced by photovoltaic panels can be stored in the secondary batteries batteries of accumulators or can be directly introduced into alternative current (AC) AC grids. The link between photovoltaic panels and the secondary batteries batteries of accumulators is provided by the DC-DC converters, which increase or decrease the voltage. In order to increase the quantity of electric energy supplied by the photovoltaic systems of the secondary batteries, for controlling the DC-DC converter algorithms, maximum power point tracking (MPPT) is used, in combination with controllers of the proportional-integral (PI) type [1][2][3][4], or fuzzy logic controllers [5][6][7][8][9]. In work [10], the photovoltaic system is used for charging the secondary batteries batteries of accumulators by means of two DC-DC voltage converters. The DC-DC converter of boost type is controlled by using the MPPT algorithm with the fuzzy logic controller, and the DC-DC converter of buck type is controlled through a PI controller. The link between the photovoltaic systems and the AC grids is provided through DC-DC converters and single-phase or three-phase inverters. In work [11], the photovoltaic system was analyzed and simulated in order to test two improved MPPT techniques: perturb and observe (P&O) with PI controller and fuzzy PI controller optimized through genetic algorithms (GAs). A comparison between the MPPT technique using the fuzzy PI controller in a hybrid cascade, and the MPPT technique using the "perturb and observe" (P&O) algorithm, was presented in the work [12]. A comparative study between the control of the DC-DC converter of boost type and the threephase inverter with the fuzzy logic controller or PI controller was presented in work [13].
The photovoltaic systems can supply the electric energy to the grid only by means of the single phase or three-phase inverters circuits. These inverters can be controlled through PI or fuzzy logic controllers. The fuzzy logic controller was used in work [14] to improve the dynamic response of a photovoltaic system connected to a three-phase grid through the Z-source inverter (ZSI) method upon the action of external perturbations. In works [15,16], the fuzzy logic controller was used for controlling the integration of a hybrid system of the renewable energy sources (photovoltaic system+wind power station) to an AC grid in order to improve the quality of the electric energy. A photovoltaic system connected to a variable load in an autonomous mode or connected to an AC grid under the control of a fuzzy logic controller was presented in works [17,18]. The control of a photovoltaic system with fuzzy logic controller connected to the three-phase grid of a town for residential use was presented in [19]. The algorithm of differential searches for optimizing the fuzzy logic controllers for controlling the three-phase inverters was presented in work [20]. In work [21], an extended direct control of the power (DPC) for a three-phase inverter with pulse width modulation (PWM) on several levels supplied from a photovoltaic system (PV), and connected to a three-phase grid, was presented. The connection of the photovoltaic panels through a single-phase inverter to an AC grid was presented in work [22]. In work [23], a photovoltaic system connected through a single-phase inverter to an AC grid, controlled through a fuzzy logic controller, was presented. A comparison between the fuzzy logic controller (FLC) and the conventional PI controller used for interfacing a photovoltaic system, with a grid through a three-phase inverter, was presented in [24,25]. In this work, a comparative study of a photovoltaic system connected to a three-phase grid by means of a three-phase inverter controlled by a fuzzy logic controller, or by a proportional-integral (PI) controller, is presented. This study is focused on the increase of the quantity and quality of the electric energy produced by the photovoltaic panels and supplied to the AC grid. The innovative aspect of this article consists of elaborating two models for the photovoltaic system connected to the three-phase grid and of the control algorithms of the three-phase inverter with a proportional-integrative controller or with a fuzzy logic controller.

The PV Array Model
Each photovoltaic system (PV) is composed of a matrix that includes series and/or parallel photovoltaic panels, where every panel includes more photovoltaic cells. The current intensity-voltage diagram of a photovoltaic cell can be established through the relation (1) (by neglecting the current through the shunt resistance of the equivalent circuit of the cell), [25,26]: where: I ph -is the current intensity generated by the light; I 0 -is the reverse saturation current of the PV panel; R se -is the series resistance of the matrix; V(th)-is the thermal voltage. The above equation can be written as, [25,26]: where: I sc -is the short-circuit current (in Amperes) The representation of the PV model of the above will be used for our simulations.

Description of the Model Produced in MATLAB-Simulink for the Photovoltaic System Connected to an AC Grid
The block diagram of the models produced in MATLAB-Simulink for the photovoltaic system connected to an AC grid is presented in Figure 1. The main components of the model are: (a) photovoltaic module; (b) source of solar radiations incident to the solar panels, and environment temperature; (c) three-phase inverter; (d) three-phase resintanceinductance (RL) filter; (e) measuring blocks; (f) three-phase grid; (g) control subsystem with PI or fuzzy logic controller. The representation of the PV model of the above will be used for our simulations.

Description of the Model Produced in MATLAB-Simulink for the Photovoltaic System Connected to an AC Grid
The block diagram of the models produced in MATLAB-Simulink for the photovoltaic system connected to an AC grid is presented in Figure 1. The main components of the model are: (a) photovoltaic module; (b) source of solar radiations incident to the solar panels, and environment temperature; (c) three-phase inverter; (d) three-phase resintance-inductance (RL) filter ; (e) measuring blocks; (f) three-phase grid; (g) control subsystem with PI or fuzzy logic controller. A photovoltaic module was used that was composed of 40 photovoltaic panels of Soltech 1STH-225-P. Four groups formed by 10 photovoltaic panels each, series connected, were connected in parallel. The technical characteristics of a photovoltaic panel are: = 224..36 W, = 36..9 V. The characteristics of the photovoltaic module at an intensity of the incident solar radiation of 1000 W/m and a temperature of 25 ℃ (results from Figure 2): = 296 V, = 8975 W. For the source of the solar radiation incident on the photovoltaic panels and temperature-the characteristics of variations shown in Figure 3 are imposed, for a time interval of a simulation equal to 2.5 s. The three-phase inverter is composed of power transistors of the Insulated Gate Bipolar Transistors (IGBT) type with protection diodes. The three-phase filter RL has the role of reducing the harmonics of the phase voltages. The values of the components of this filter are: L = 9.2 mH, R = 0..920 Ω. The measuring blocks are used for measuring the values of the voltages and current intensities of the three-phase grid at the output of the RL filter and of the AC grid to which the photovoltaic module is connected. The AC grid has the following parameters: U = 380 V, frequency f = 50 Hz, apparent power S = 10 MVA. The control subsystem was designed separately for the proportional-integrative (PI) con- A photovoltaic module was used that was composed of 40 photovoltaic panels of Soltech 1STH-225-P. Four groups formed by 10 photovoltaic panels each, series connected, were connected in parallel. The technical characteristics of a photovoltaic panel are: P max = 224.36 W, U max = 36.9 V. The characteristics of the photovoltaic module at an intensity of the incident solar radiation of 1000 W/m 2 and a temperature of 25°C (results from Figure 2): U max = 296 V, P max = 8975 W. For the source of the solar radiation incident on the photovoltaic panels and temperature-the characteristics of variations shown in Figure 3 are imposed, for a time interval of a simulation equal to 2.5 s. The three-phase inverter is composed of power transistors of the Insulated Gate Bipolar Transistors (IGBT) type with protection diodes. The three-phase filter RL has the role of reducing the harmonics of the phase voltages. The values of the components of this filter are: L = 9.2 mH, R = 0.920 Ω. The measuring blocks are used for measuring the values of the voltages and current intensities of the three-phase grid at the output of the RL filter and of the AC grid to which the photovoltaic module is connected. The AC grid has the following parameters: U = 380 V, frequency f = 50 Hz, apparent power S = 10 MVA. The control subsystem was designed separately for the proportional-integrative (PI) controller and the fuzzy logic controller, respectively. Essentially, two distinct programs were elaborated in a MATLAB--Simulink programming environment. troller and the fuzzy logic controller, respectively. Essentially, two distinct programs were elaborated in a MATLAB--Simulink programming environment.

Presentation of the Control Subsystem with PI Controller
The control subsystem with PI controller is composed of the following blocks: (a) measuring block of the photovoltaic module parameters, as shown in Figure 4. The parameters of the electric energy supplied by the photovoltaic module are measured: voltage _ _ and current intensity _ . The electric power at the output from the photovoltaic module is calculated through the relation: The control block of the three-phase inverter is presented in Figure 5. The signal Vgrid from the measure block 2-the voltage of the three-phase grid is applied at the input of the phase lock loop (PLL) block. The PLL block will generate the three-phase signal of frequencies wt. The signal in measure block 1 will be applied at the input of the block "abc to dq0" along with the frequency signal wt. The block "abc to dq0"

Presentation of the Control Subsystem with PI Controller
The control subsystem with PI controller is composed of the following blocks: (a) measuring block of the photovoltaic module parameters, as shown in Figure 4. The parameters of the electric energy supplied by the photovoltaic module are measured: voltage V _PV _ and current intensity I _PV . The electric power at the output from the photovoltaic module is calculated through the relation: (b) The control block of the three-phase inverter is presented in Figure 5. The signal Vgrid from the measure block 2-the voltage of the three-phase grid is applied at the input of the phase lock loop (PLL) block. The PLL block will generate the three-phase signal of frequencies wt. The signal V abc in measure block 1 will be applied at the input of the block "abc to dq0" along with the frequency signal wt. The block "abc to dq0" transforms the voltage signals from the three-phase system in the two-phase system and will supply the signals V d , V q , and V 0 . The values of these signals are given by Equation (5) [20].  If the amplitude of the phase voltage in the AC three-phase grid is equal to 220 V, at the moment t = 0 will result in the value of the voltage component by the axis d, equal to 220 V. This value will be imposed for the reference voltage in the voltage adjustment loop by the axis d. The components V d and V q of the voltage are adjusted through the discrete PID controllers. For the component V d , the reference value V d re f 1 = 220 V is imposed, and for the component V q , the reference value V q_re f 1 = 0 is imposed. The parameters of the PID controllers have the following values: k r = 0.5, k i = 120. The output signals from the voltage adjustment loops are applied at the input of the block "dq0 to abc " together with the voltage signal V 0 by means of a multiplexor block. At the input of the block "dq0 to abc ", the frequency signal wt is applied as well. The block "dq0 to abc " transforms the voltage signals of the two-phase system to the three-phase system and supplies the signals for controlling the PWM generator (2-level). The values of these signals are given by the equation (6), [20].
The PWM generator block will generate the control signals of the power transistors of type IGBT in the structure of the three-phase inverter. The output voltage of the inverter must have the same amplitude and phase as the voltage of the AC grid.
(c) The power measure block of the three-phase system uses the signals V abc and I abc supplied by the measure 1 block. With the help of the block "Power (3 ph, Instantaneous)" the active power P can be calculated, as well as the reactive power Q; Figure 6. The variation of the powers P _PV , P,P, QQ is represented graphically in function of the variation of the solar radiation intensity and temperature during the simulation process.
Sustainability 2021, 13, x FOR PEER REVIEW 8 of Figure 6. Calculation block of the three-phase system powers. Figure 6. Calculation block of the three-phase system powers.

Presentation of the Control Subsystem with Fuzzy Logic Controller
Within this subsystem, the discrete PID type controllers in the previous subsystem are replaced with fuzzy logic controllers. The structure of the adjustment loops of the voltage components V d and V q is presented at Figure 7. The other blocks remain unchanged. The error signal for the adjustment loop of the component V d is calculated through the Equation (7): The error signal for the adjustment loop of the component V q is calculated through the Equation (8): The error signal for the adjustment loop of the component is calculated through the equation (8):

Design of the Fuzzy Logic Controller
For designing the fuzzy logic controller, the input values are to be chosen: error E(k) and error derivate dE(k), as well as the output variable u(k) related to each component of the voltage by the d and q axes. The structure of the fuzzy logic controller is shown in Figure 8. For designing the fuzzy logic controller, it is not necessary to establish the mathematical model of the fix part. The variation domains of the input variables and of the output variable will be chosen and the basis of rules will be established. The output variable is determined through the de-fuzzy method of the gravity center. The variation domains of the input variables are presented in Figure 9. The variation domain of the output variable is presented in Figure 10. For designing the fuzzy logic controller, it is not necessary to establish the mathematical model of the fix part. The variation domains of the input variables and of the output variable will be chosen and the basis of rules will be established. The output variable is determined through the de-fuzzy method of the gravity center. The variation domains of the input variables are presented in Figure 9. The variation domain of the output variable is presented in Figure 10.
The basis of rules will be done as per Table 1. The following operators will be used: if, and, then. NB-big negative, NM-medium negative, ZE-zero, PM-medium positive, PB-big positive. Examples of rules:

if (E(k) is NB) and (dE(k) is NB) then (u(k) is NB); 2. if (E(k) is NM) and (dE(k) is ZE) then (u(k) is NM).
ainability 2021, 13, x FOR PEER REVIEW 11 of 21  The basis of rules will be done as per Table 1. The following operators will be used: if, and, then. NB-big negative, NM-medium negative, ZE-zero, PM-medium positive, PB-big positive. Examples of rules: As method of inference, reference [27] maximum-minimum method was used in this case:

if (E(k) is NB) and (dE(k) is NB) then (u(k) is NB); 2. if (E(k) is NM) and (dE(k) is ZE) then (u(k) is NM).
where: µ Ci (E i ) = min(µ Ai (E), µ Bi (∆E)), and µ Oi (u) is the function imposed through the rule R i . For de-fuzzy, the method of the gravity center was used, where the abscissa of the gravity center was determined through the equation (10), [27]: The output variable u(k) will be determined with the help of the relation (10). The fuzzy logic controller can be implemented and validated on the same hardware structure as that used for implementing and validating the conventional PI controller. Essentially, the hardware structure will not modify in case of implementing and validating, in real time, the two programs issued in MATLAB-Simulink for the comparative study of the photovoltaic system connected to a three-phase grid through a three-phase inverter, and additional costs will not occur from this point of view.

Simulation Results for the Control Subsystem Equipped with PI Controller
The variation of voltage and current intensity in function of the radiation intensity and temperature are presented in Figure 11. The voltage variation is proportional to the intensity of the solar radiation. The voltage value will decrease along with temperature increase. The analysis of the harmonics, in case of the subsystem with the PI controller, is presented in Figure 12. The total harmonic distortion (THD) has a value equal with 4.28%. The variation of powers in function of the solar radiation and temperature is presented in Figure 13.

Simulation Results for the Control Subsystem Equipped with Fuzzy Logic Controller
The variation of voltage and current intensity in function of the radiation intensity and temperature are presented in Figure 14. The voltage variation is proportional to the intensity of the solar radiation. The voltage value will decrease along with a temperature increase. The analysis of the harmonics, in case of the subsystem with a fuzzy logic controller, is presented in Figure 15. The total harmonic distortion (THD) has the value equal with 0.40%. The variation of powers in function of the solar radiation and temperature is presented in Figure 16.

Simulation Results for the Control Subsystem Equipped with Fuzzy Logic Controller
The variation of voltage and current intensity in function of the radiation intensity and temperature are presented in Figure 14. The voltage variation is proportional to the intensity of the solar radiation. The voltage value will decrease along with a temperature increase. The analysis of the harmonics, in case of the subsystem with a fuzzy logic controller, is presented in Figure 15. The total harmonic distortion (THD) has the value equal with 0.40%. The variation of powers in function of the solar radiation and temperature is presented in Figure 16.   The results obtained for the two types of controllers are presented in Table 2.  The results obtained for the two types of controllers are presented in Table 2.  Out of the comparative analysis of the results in Table 2, it may be noticed that better performances are obtained for the control subsystem equipped with a fuzzy logic controller.

Conclusions
This work presents a photovoltaic system connected to an AC grid through a three-phase inverter controlled by a fuzzy logic controller or by a proportional-integral (PI) controller. The work aims to increase the quantity and quality of the electric energy produced by the photovoltaic panels and introduced to the AC grids. Two models have been elaborated in MATLAB-Simulink for the photovoltaic module composed of 40 photovoltaic panels and connected to an AC grid through a three-phase inverter. The three-phase inverter was controlled through a proportional-integrative controller or through a fuzzy logic controller. The implementation and validation in real time of the two models elaborated for the photovoltaic system, connected to a three-phase grid, can be performed on the same hardware structure. Through the usage of the fuzzy logic controller for controlling the three-phase inverter, instead of the conventional PI controller, additional costs will not occur. For designing the fuzzy logic controller-the mathematical model of the fixed part to be determined is not necessary. Out of the com- Out of the comparative analysis of the results in Table 2, it may be noticed that better performances are obtained for the control subsystem equipped with a fuzzy logic controller.

Conclusions
This work presents a photovoltaic system connected to an AC grid through a threephase inverter controlled by a fuzzy logic controller or by a proportional-integral (PI) controller. The work aims to increase the quantity and quality of the electric energy produced by the photovoltaic panels and introduced to the AC grids. Two models have been elaborated in MATLAB-Simulink for the photovoltaic module composed of 40 photovoltaic panels and connected to an AC grid through a three-phase inverter. The three-phase inverter was controlled through a proportional-integrative controller or through a fuzzy logic controller. The implementation and validation in real time of the two models elaborated for the photovoltaic system, connected to a three-phase grid, can be performed on the same hardware structure. Through the usage of the fuzzy logic controller for controlling the three-phase inverter, instead of the conventional PI controller, additional costs will not occur. For designing the fuzzy logic controller-the mathematical model of the fixed part to be determined is not necessary. Out of the comparative analysis of the results, it was discovered that, through the use of the fuzzy logic controller for controlling the three-phase inverter, a higher electric power is transferred to the AC grid, compared to the case of using the PI type controller and the total harmonic distortion (THD) of the voltage, resulting after the filtering circuit has a lower value, than in case of using the PI type controller. Through the usage of fuzzy logic controllers for controlling the three-phase inverters, the efficiency of the photovoltaic systems will be increased and this will lead to lowering the costs of electric energy in the future.