 Original research
 Open Access
 Published:
Power quality enhancement in islanded microgrids via closedloop adaptive virtual impedance control
Protection and Control of Modern Power Systems volumeÂ 8, ArticleÂ number:Â 10 (2023)
Abstract
The high proportion of nonlinear and unbalanced loads results in power quality issues in islanded microgrids. This paper presents a novel control strategy for harmonic and unbalanced power allocation among distributed generators (DGs) in microgrids. Different from the existing sharing strategies that allocate the harmonic and unbalanced power according to the rated capacities of DGs, the proposed control strategy intends to shape the lowest output impedances of DGs to optimize the power quality of the microgrid. To achieve this goal, the feasible range of virtual impedance is analyzed in detail by eigenvalue analysis, and the findings suggest a simultaneous adjustment of real and imaginary parts of virtual impedance. Because virtual impedance is an openloop control that imposes DG to the risk of overload, a new closedloop structure is designed that uses residual capacity and absorbed power as feedback. Accordingly, virtual impedance can be safely adjusted in the feasible range until the power limit is reached. In addition, a fuzzy integral controller is adopted to improve the dynamics and convergence of the power distribution, and its performance is found to be superior to linear integral controllers. Finally, simulations and control hardwareintheloop experiments are conducted to verify the effectiveness and usefulness of the proposed control strategy.
1 Introduction
With increasing concern about the environment, renewable energybased distributed generation (DG) has gradually made its way into the modern energy landscape. A microgrid is a smallscale power grid formed by DGs and interconnected loads. It serves as an effective way for renewable energy integration without violating the operating principles of classical electricity distribution networks [1, 2]. In China, the plan of carbon peaking and carbon neutrality has pushed forward several microgrid demonstration projects in recent years, such as the Burang and Gar countylevel microgrids in Tibet. These microgrids are generally far away from the main grids and are designed to have the capability of operating in islanded mode.
For an islanded microgrid, DGs are required to autonomously share the power to avoid overload and ensure that the voltage and frequency vary within reasonable ranges. This topic has been studied for years, and various centralized [3] and decentralized controls [4, 5] can be found in the literature. Among the approaches, droop control has gained great popularity because of its â€˜plugandplayâ€™ feature. Considering conventional droops between the active powerâ€“frequency (Pf) and reactive powervoltage magnitude (Qâ€“V), the active power can be accurately shared because the frequency of different DGs in the microgrid is uniform in the steady state. However, accurate reactive power sharing is more challenging because the voltages measured by DGs are nonuniform [6]. Improvements in droop control have been suggested to address this issue, such as adding secondary regulation though a communication system [7, 8] or using virtual impedance control to address line impedance mismatch [9]. Although reactive power sharing is an important and challenging task, it has been discussed in many publications and is beyond the scope of this paper.
On the other hand, with the increase in nonlinear and unbalanced loads, the power quality of islanded microgrids has emerged as a concern for the safe and economic operation of the microgrids. In many cases, the power quality of islanded microgrids can be worse than that of traditional distribution systems because of a much lower short circuit ratio. Accordingly, DGs are vulnerable to overload because of excessive harmonic and unbalanced power.
To achieve a fair harmonic and unbalanced power allocation, most existing research is devoted to achieving accurate power sharing using virtual impedance control. Reference [10] points out that adding a large fixed virtual impedance at the harmonic frequency can reduce the difference in output impedances of different DGs and realize power sharing. However, this scheme is difficult to apply in microgrids with variable structures. To increase the flexibility of the harmonic power sharing, reference [11] proposes an enhanced power sharing control scheme which uses an adaptive virtual impedance at dominant frequencies calculated by the central controller. However, communication is needed for this approach. Reference [12] proposes a distributed eventtriggered power sharing control strategy. The trigger control rule is designed based on the reactive, unbalanced and harmonic power distribution deviation signals of each DG, and a proportional integral controller is introduced to dynamically adjust the virtual inductance. A novel idea proposed in [13] points out that it is feasible to eliminate power sharing error by injecting coupling between the transient real power change and virtual impedance. A term associated with reactive, unbalanced or harmonic power is added to the traditional active powerâ€“frequency droop control. As a result, the frequency of different DGs can only be uniform when the active, reactive, harmonic and unbalanced power are all shared according to the rated capacity. A recent work [14] proposes an adaptive virtual impedance control method based on small disturbance signal injection. By detecting the active power generated by small signals injected into the microgrid, the virtual harmonic inductance of the DG is adjusted to achieve harmonic power sharing.
However, all the abovementioned research focuses on accurate harmonic and unbalanced power sharing among DGs rather than power quality of the microgrid. Theoretically, when a DG is close to the harmonic or unbalanced sources, it is desirable to absorb more harmonic or unbalanced currents, so as to prevent them from flowing into the system side. From this perspective, the power sharing strategy based on the rated capacity of DGs will sacrifice the power quality of the microgrid to some extent. The original intention of sharing is to avoid overload and ensure fairness. However, the amount of harmonic and unbalanced power is usually much smaller than that of active and reactive power. This means that disproportionate sharing of harmonic and unbalanced power will not significantly increase the risk of DG overload. On the other hand, DGs in a microgrid may belong to the same utility or customer, e.g., all DGs in the Burang and Gar microgrids belong to the State Grid Corporation of China. For such cases, premium power quality is more meaningful than the fairness of DGs, especially when sensitive loads are connected.
Apart from power sharing, some recent work has focused on power quality enhancement of islanded microgrids, such as adding a secondary regulation though the communication system [11,12,13,14,15,16] and powerquality orientated virtual impedance control based on local measurements. The latter is the focus of this paper because of its noncommunication feature, and the related literature is reviewed here. Reference [17] dynamically adjusts the inverter output impedance design rules by detecting the voltage distortion at the PCC, aiming to reduce the equivalent harmonic impedance when the voltage distortion is high. To control the DG output current in a balanced condition, reference [18] concludes that the higher the value of the virtual impedance, the better the imbalance suppression. Also, considering the compromise between the mitigation effect and response speed, an upper boundary of the virtual impedance is set to ensure the DGâ€™s modulation performance. In [19], voltage distortion is compensated by employing the negative virtual impedance and establishing a droop relationship between the virtual impedance and the absorbed harmonic power. However, because power sharing is still the main control target, power quality improvement is limited.
Based on the literature review, it can be summarized that the existing control strategies cannot fully use the capacity of DGs to enhance the power quality of islanded microgrid when only local measurements are available. This paper presents an adaptive virtual impedance control aimed at enhancing the power quality of an islanded microgrid. The key idea is to minimize the equivalent impedance of the DG at the designed frequency so as to provide a low impedance path to absorb harmonic and unbalanced currents, similar to passive filters. The main contributions and innovations of this study include:

1)
A novel closedloop adaptive virtual impedance control is proposed. Conventionally, the value of the virtual impedance is predesigned by experience or system studies, which effectively is an openloop control without the capability of determining the amount of current absorbed by DGs. In this paper, virtual impedance is adaptively adjusted according to the integral of the difference between the remaining capacity and the absorbed power. Such a closedloop structure leads to a minimized output impedance without the risk of overload.

2)
The stability region of the virtual impedance is determined by eigenvalue analysis, and the root cause of instability is analyzed in detail. The findings indicate that adjusting the real and imaginary parts of virtual impedances simultaneously can effectively expand the operating range. An adjustment law is designed accordingly to maximize the stability margin.

3)
A fuzzy integral controller is adopted to improve the dynamic and convergence performance of the harmonic and unbalanced power distribution. Because the power calculation involves a nonlinear operator, the linear PI controller faces the challenge of striking the balance between dynamic performance and convergence speed. In this paper, a fuzzy integral controller is used to address this issue by adaptively adjusting the control parameters according to the operating conditions [20]. The effectiveness and computational performance of the proposed method are verified by simulations and control hardwareintheloop experiments.
The remainder of the paper is organized as follows. SectionÂ 2 reviews droop and virtual impedance control, while Sect.Â 3 analyzes the feasible range of virtual impedances via eigenvalue analysis. SectionÂ 4 presents the proposed control strategy based on the adjustment law defined in Sect.Â 3, and Sects.Â 5 and 6 show the results of the simulation and hardwareintheloop experiments, respectively. Finally, Sect.Â 7 concludes the paper.
2 Droop and virtual impedance control
The structure of a typical microgrid is shown in Fig.Â 1, where several DGs transmit their power to the local and remote loads via connection lines. Hierarchical control is commonly adopted to achieve the optimal performance of the microgrid, where: (1) the primary level is based on droop control, including a virtual impedance loop to shape the output impedance; (2) the secondary level performs the restoration of the deviations caused by droop control; and (3) the tertiary level optimizes the power flow of the microgrid. This paper focuses on the primary level, and the working principles of droop and virtual impedance control are briefly reviewed in this section.
2.1 Working principle of droop and virtual impedance control
The working principle of droop control is shown in Fig.Â 2. As seen, the DG adjusts its power output by emulating the droop characteristic of synchronous generators, as:
where f^{*} and U^{*} are the reference voltage and frequency, respectively. m and n are the droop coefficients for the active and reactive power, respectively. P_{i} and Q_{i} are the power output of DG i.
Because the voltages of different DGs are nonuniform, the reactive power cannot be allocated according to the rated capacity. To address this issue, one of the most popular and effective solutions is to add the virtual impedance loop, and the corresponding control diagram is shown in Fig.Â 3, where G_{u}(s) represents the multiresonant quasiPR controller given as:
where k_{U} is the proportional coefficient, k_{rh} is the resonance coefficient, and Ï‰_{h} and Ï‰_{c} are the resonance frequency and cutoff frequency, respectively.
G_{i}(s) is the inner current control and G_{d}(s) represents the controller delay, given as:
where k_{inner} is the proportional gain of the current loop, and k_{PWM} is the equivalent gain of the inverter bridge. T_{s} is the sampling time, and a 1.5 T_{s} delay is considered as in [21].
The working principle of the virtual impedance loop is to add a desired voltage drop in the voltage reference to achieve the same effect as adding a physical impedance at the DG output. As a result, the output impedance of the DG is reshaped. When the virtual impedance loop is considered, the output voltage of the DG can be determined as:
where
and G(s) is the voltage transfer function. Z_{inv}(s) is the equivalent impedance of the DG with the virtual impedance loop. By setting different virtual impedance values in the feedforward transfer function G_{vir}(s), Z_{inv}(s) can be changed without affecting G(s). As a result, the influence of different line impedances can be eliminated.
2.2 Virtual impedance control for harmonic and unbalanced power sharing
The droop control in (1) only works for the positivesequence fundamental power. However, the concept can be extended to the negative sequence and harmonic frequencies.
2.2.1 Extraction of harmonic and unbalanced currents
Accurate extraction of harmonic and unbalanced currents is the foundation of virtual impedance control. Generally, the dual second order generalized integratorquadrature signal generator (DSOGIQSG) can be adopted for this purpose [22], and the expression of SOGIQSG is shown as:
where Ï‰_{h} is the resonance frequency, and k_{h} is used to determine the bandwidth of the DSOGIQSG. According to (5), the magnitude gains of G_{h} and G_{hq} at Ï‰_{h} are 1, and the phase difference is 90Â°. Thus, the voltage/current in the Î±Î² frame can be extracted. However, DSOGIQSG still retains certain gains at other frequencies, which makes it difficult to eliminate the interference of the fundamental component and other harmonics. This issue can be addressed by crossover cancellation of different DSOGIQSG modules, as shown in Fig.Â 4, and the transfer function of this harmonic extraction process is shown in (6)â€“(7). FigureÂ 5 shows the frequency response of T_{11}(s)/G_{11}(s) and T_{11q}(s)/G_{11q}(s).
The harmonic currents of both positive and negative sequences can be finally extracted by (8), where i_{1Î±Î²}^{+} is the positivesequence fundamental current used for fundamental power calculation, and i_{1Î±Î²}^{âˆ’} is the negativesequence fundamental current used for unbalanced power calculation. The dominant harmonics with hâ€‰=â€‰5, 7, 11 are considered in this paper for the harmonic power calculation.
2.2.2 Virtual impedance at arbitrary sequences and frequencies
After the extraction of harmonic and unbalanced currents at each frequency of interest, the virtual impedance at arbitrary sequences and frequencies can be implemented as:
where R_{v} is the virtual resistance and L_{v} is the virtual inductance. v_{1Î±Î²}^{âˆ’}, v_{5Î±Î²}^{âˆ’}, v_{7Î±Î²}^{+}, and v_{11Î±Î²}^{âˆ’} are the calculated instantaneous voltage drops for the virtual impedance at the selected compensation frequencies. Finally, the total voltage drop for the virtual impedance is obtained by adding all voltage drops previously calculated as:
where v_{vÎ±} and v_{vÎ²} are the voltage drops for the required virtual impedance in the stationary reference frame, which are deducted from the reference voltages to emulate the effect of the actual impedance.
Based on Fig.Â 3, we can drive the equivalent impedance of the DG in the Î±Î² frame:
According to (11), there is a coupling between the impedances in the Î±Î² frame, which can be further eliminated by transforming the impedance to the sequence domain using the following transformation:
The equivalent impedance of the DG can then be obtained:
where
3 Stability region of virtual impedance
In this section, the feasible range of the virtual impedance is analyzed through eigenvalue analysis, and an adjustment law is further given on the basis of the stability analysis results.
3.1 The stability of a single DG
To facilitate the design, the stability of a single DG is analyzed first, as shown in Fig.Â 6. According to (4), at the positivesequence fundamental frequency, the DG can be equivalent to a voltage source with a series impedance. Because the equivalent impedance of the upstream system is generally much smaller than the line and filter impedances, an ideal voltage source can be used to replace the rest of the microgrid [23]. The DG at the negativesequence fundamental and harmonic frequencies is illustrated in Fig.Â 6b [24], with the only difference being the omission of the voltage source. Therefore, for all frequencies and sequences, the equivalent admittance of the DG can be expressed as:
According to Fig.Â 6b, the stability of the system is mainly determined by the pole distribution of Y(s) at the negativesequence fundamental and harmonic frequencies. With the parameters shown in Table 1, according to (4), the voltage transfer function G(s) and the positivesequence equivalent impedance Z_{o}(s) of the DG are shown in Fig.Â 7, whereas the negativesequence equivalent impedance is the same and so not shown here. At the resonant frequency of the quasiPR controller, the gain of G(s) is close to 1, and the magnitude of Z_{o}(s) is almost 0, which means that the harmonic power and unbalanced power consumed by the DG can be effectively adjusted by the virtual impedance value.
According to (11), adjusting the virtual resistance value R_{vh} and/or the virtual inductance value L_{vh} can change Z_{vir}(s). To facilitate the analysis, the virtual impedance at the negativesequence fundamental and harmonic frequencies are set to be consistent. FigureÂ 8 shows the simulation results when L_{vh} and R_{vh} are adjusted separately. In Fig.Â 8a, L_{vh} is set to L_{g} to eliminate the influence of the grid inductance. It is clear that the stability range of the virtual resistance is limited to 8 Î© with the crossover cancellation process. When the crossover cancellation is not used with DSOGIQSG, the upper bound is only 1 Î©. Similarly, as shown in Fig.Â 8b, the upper bound of the virtual inductance increases from 0.6 mH to 0.8Â m because of the crossover cancellation. The results indicate that: 1) the crossover cancellation process helps to expand the stability region; and 2) the virtual impedance of the DG must have a welldefined adjustment range to avoid instability: the larger its adjustment range, the more flexible the power allocation. Therefore, it is important to determine the cause of the instability by virtual impedances to find a method to further increase the adjustable range. Previous studies have shown that when the value of L_{vh} or R_{vh} is negative, the system can become unstable because the total impedance Z_{total} behaves as a capacitor or negative resistor [18, 25]. However, few studies have focused on the influence of positive L_{vh} or R_{vh} on stability. As shown in Fig.Â 8, when the virtual impedance of the DG changes at 5Â s, the output current gradually diverges, which confirms that there is a risk of instability under positive L_{vh} and R_{vh}.
The findings show that the oscillation frequency occurs near two compensation frequencies, that is, 561Â Hz (near the 11^{th} harmonic) and 42Â Hz (near the negativesequence fundamental frequency). This phenomenon is investigated in detail by the frequency response of the DG [26]. FigureÂ 8a shows that there is an unstable mode at approximately 550Â Hz. Because L_{vh} is set as âˆ’â€‰2 mH to eliminate the influence of the grid inductance, the negative L_{vh} value f Z_{vir} have negative resistance characteristics above 550Â Hz owing to the hysteresis characteristics of T_{hq}, as shown in Fig.Â 5, while the positive R_{vh} introduces capacitance characteristics to Z_{vir}. When Z_{vir} becomes dominant in Z_{total}, the stability tends to worsen. In addition, it can be seen that the negative resistance and capacitance characteristics of Z_{total} in Fig.Â 9a are less obvious than those in Fig.Â 9b. As a result, the stability range of R_{vh} is larger when using crossover cancellation. Similar conclusions can be drawn for the stability at approximately 250Â Hz and 350Â Hz.
FigureÂ 8b indicates that there is another unstable mode at approximately 50Â Hz. According to Fig.Â 5, when L_{vh} is positive, Z_{total} shows a negative resistance at approximately 50Â Hz, again owing to the hysteretic characteristics of T_{hq}. The range of the negative resistance gradually widens with increasing L_{vh}. With a frequency where the imaginary part of Z_{total} crosses zero, the real part of Z_{total} is negative, which indicates that the system will lose stability. Comparing Fig.Â 10a and b, the inductive feature of Z_{vir} is more evident, and the zerocrossing point of Z_{total} shifts to the left when crossover cancellation is not applied. As a result, the stability range increases when using crossover cancellation.
In summary, the following conclusions can be drawn: 1) a larger adjustment range of virtual impedance control can be obtained using crossover cancellation; and 2) the instability of the DG is mainly caused by the negative impedance effect introduced by the phase lag property of the harmonic extraction process. By analyzing the results presented in Figs. 9 and 10, we see that the negative impedance effect introduced by positive R_{vh} and negative L_{vh} can be reduced to some extent by increasing R_{vh} and L_{vh} simultaneously. This will lead to an increased adjustable range of virtual impedances. FigureÂ 11 shows the stability constraint relation with R_{vh} and L_{vh}. Clearly, the adjustment range of the virtual impedance is significantly increased when L_{vh} and R_{vh} are simultaneously adjusted. Here, the adjustment law of L_{vh} and R_{vh} is designed to maximize the stability margin, as:
FigureÂ 12 shows the locus of poles of Y(s) when the DGs increase R_{vh} and L_{vh} simultaneously according to (16). It can be seen that such an adjustment significantly enlarges the feasible range of the virtual impedance.
3.2 The influence of parallel multiDGs
The feasible range of virtual impedances has been obtained by analyzing a single DG. However, the adaptability of the results in the original microgrid needs further verification. To study the dynamics of parallel multiDGs, the equivalent circuit of the microgrid is established, as shown in Fig.Â 13. The equivalent impedance of the rest of the microgrid (apart from DG i) can be expressed as (17). It is clear that the stability of the microgrid can be analyzed by the pole distribution of Y(s), which considers the extra impedance Z_{s}^{i}(s) in (15).
In this model, the stability of the system can be verified by the Bode diagram or the Nyquist criterion. As the equivalent impedance (Z_{eq}) of each DG can be flexibly changed, it is challenging to obtain the determined mathematical representation of the equivalent impedance. To analyze the stability of the microgrid under various operating conditions, the Monte Carlo simulation method is used to verify the applicability of the conclusion in (16), in which the virtual impedance of each DG is randomly generated through Monte Carlo simulations. Then, the distribution of poles of Y(s) can be calculated accordingly. The experimental results indicate that the adjustment range obtained from the singleDG analysis performs well for the parallel system. This is because Z_{s} has a much smaller influence on the stability than Z_{lg} and Z_{line}, and therefore the stability margin determined by the singleDG analysis is sufficient.
4 Proposed closedloop adaptive virtual impedance control
4.1 Power calculation
According to the IEEE Standard 1459 [27], the fundamental and nonfundamental apparent power in a threephase system can be calculated by:
In practice, the negativesequence and harmonic voltages are much smaller than that of the positivesequence fundamental voltage, and thus they can be omitted without loss of accuracy. Accordingly, the harmonic and unbalanced power can be calculated as:
The residual capacity of a DG is calculated as:
where S_{R} and S_{rated} are the residual capacity and rated capacity of the DG, respectively. P and Q are the respective positivesequence active and reactive power, given as:
where u_{cÎ±} and u_{cÎ²} are the PCC voltages in the Î±Î² frame, i_{1Î±}^{+} and i_{1Î²}^{+} are the positivesequence fundamental currents in the Î±Î² frame.
4.2 Control principle
Without loss of generality, the control principle of the proposed method is illustrated using a simple microgrid with two connected DGs. FigureÂ 14 shows the equivalent circuit of the microgrid in the negative sequence or harmonic frequencies, where the nonlinear and unbalanced loads are modeled as current sources i_{load} and two DGs are modeled as impedances.
In this circuit, the equivalent impedance at the PCC can be determined as:
Accordingly, the total harmonic distortion (THD) and the imbalance factor (UF) can be calculated as:
According to (22) and (23), smaller values of Z_{DG,1} and Z_{DG,2} benefit the power quality. However, if the harmonic and unbalanced power are allocated according to the rated capacity, i.e., the sharing strategy is used, the following condition must be satisfied:
From this perspective, the sharing strategy must sacrifice power quality to some extent. In addition, Eq.Â (24) cannot avoid the overload of the DG if the harmonic and unbalanced power are excessive.
The idea of the proposed controller is to shape the lowest Z_{DG,1} and Z_{DG,2} at the sequence and frequency of concern on the premise that the DG does not overload. The dynamic allocation process of the harmonic and unbalanced power is illustrated using the twoDG microgrid in Fig.Â 14. Here, it is assumed that: (1) S_{R,1}â€‰>â€‰S_{R,2}; and (2) line impedances from each DG to the PCC are the same. At the beginning, the virtual impedances of the two DGs are set to be large, and thus most harmonic currents flow to the load, so the residual capacities of both DGs are larger than the summation of harmonic and unbalanced power. Afterward, the virtual impedances of the two DGs are reduced adaptively, so the absorbed harmonic and unbalanced power increase. Because S_{R,1}â€‰>â€‰S_{R,2}, when S_{R,2}â€‰=â€‰(S_{U,2}â€‰+â€‰S_{H,2}), there is S_{R,1}â€‰>â€‰(S_{U,1}â€‰+â€‰S_{H,1}). As a result, the virtual impedance of DG2 will first stop decreasing, while DG1 will continue decreasing its virtual impedance. According to the current distribution of parallel branches, the increase in S_{U,1}â€‰+â€‰S_{H,1} will reduce S_{U,2}â€‰+â€‰S_{H,2} and make S_{R,2}â€‰>â€‰(S_{U,2}â€‰+â€‰S_{H,2}). The virtual impedance of DG2 again starts to decrease. The abovementioned process will repeat until both DGs reach the state of S_{R,j}â€‰=â€‰(S_{U,j}â€‰+â€‰S_{H,j}) or the virtual impedance reaches the minimum value. Accordingly, the power quality of the microgrid is enhanced without the risk of overload.
4.3 Proposed fuzzy integral controller
Based on the working principles explained in Sect.Â 4.2, the virtual impedances at the negativesequence fundamental frequency and the harmonic frequency are shown in Fig.Â 15, and are designed as:
where a_{u} and a_{h} are the proportions of the residual capacity to deal with the harmonic and unbalanced conditions, respectively. Adjusting these two values will affect the PQ enhancement performance. In this work, the values of a_{u} and a_{h} are set to be 0.6 and 0.4, respectively. R_{max}, L_{max}, and L_{min} are the upper and lower limits of the virtual impedance determined in the previous section. They are 10 Î©, 1.5 mH and L_{g}, respectively.
According to (25), the integral of the difference between the residual capacity and the harmonic (unbalanced) power is used to adjust the virtual impedance value. For a nonlinear system, introducing an integral function into the control loop can delay the response time. If the integral coefficient k_{vi} in (25) is set too large, the harmonic power allocation process may oscillate, as shown in Fig.Â 16. In contrast, if k_{vi} is too small, the dynamic response of the DG will be very slow. Therefore, it is necessary to reasonably design the integral coefficient.
To improve the dynamic response of the harmonic power allocation process, an adaptive integral controller is designed to make the integral coefficient adjustable according to the value and the change rate of the error, defined as:
where n is a positive integer and Î”t is the time interval used to calculate the change rate. The minimum of Î”t can be taken as the sampling time of the control system, but considering the periodic fluctuation of the sampling signal and the interference of noise, the value of Î”t should not be too small. In this study, Î”t is taken as 0.01Â s.
When e(t) is large and Î”e is small, the value of k_{vi} should be large to speed up the adjustment of the virtual impedance. On the other hand, if e(t) is small and Î”e is large, the value of k_{vi} needs to decrease or even become negative to suppress the rapid change in the DGâ€™s virtual impedance and harmonic/unbalance power to avoid oscillation. A fuzzy integral controller is adopted to achieve the abovementioned function. It has the same structure as the conventional integral controller, but the integral coefficient is a nonlinear function of the input signal e(t) and its change rate Î”e. It has been found that the fuzzy logic controller has better capabilities of controlling highorder and time delay systems, nonlinear systems and systems with uncertainties [28], and has been used to improve the dynamic performance of power electronic equipment in complex situations [29, 30].
The key to using a fuzzy integral controller is to properly design a membership function and rule base. These are mainly obtained from experience [29]. By selecting the appropriate quantization factors, the basic domain of input and output can be scaled to the fuzzy set {âˆ’â€‰3, âˆ’â€‰2, âˆ’â€‰1, 0, 1, 2, 3} and the corresponding linguistic variables are chosen to be negative big (NB), negative medium (NM), negative small (NS), zero (ZE), positive small (PS), positive medium (PM), and positive big (PB). According to the triangular membership function shown in Fig.Â 17, the membership of e(t), Î”e and k_{vi} can be determined.
According to the input fuzzy variables and the fuzzy rules, the output fuzzy variables can be inferred by fuzzy reasoning. The fuzzy rules are the keys to determining the performance of the fuzzy integral controller. Applying the Mamdani method, the fuzzy rules can be expressed in the form of IFâ€“THEN, for example:
The fuzzy control rules are designed in Table 2, inspired by [30]. Because the result of fuzzy reasoning is the fuzzy variables of k_{vi}, the centerofgravity method is used for defuzzification to obtain the actual value of k_{vi}, shown as:
where F represents the fuzzy set, m(e)_{i} is the membership degree of e(t) to linguistic variable i, and m(Î”e)_{j} is the membership degree of Î”e to linguistic variable i. v_{ij} is the numerical value of k_{vi} corresponding to the linguistic variable in row i and column j of Table 2. For example, if the numerical values of e(t) and Î”e are 0.25 andâ€‰âˆ’â€‰0.05, respectively, then the fuzzy variables of e(t) can be obtained as {PM, PB}, and the fuzzy variables of Î”e can be obtained as {ZO, NS}. In this situation, the fuzzy variables of the integral coefficient k_{vi} can be obtained as{PM, PM, PM, PM}, where the membership is 0.25 and its numerical value can be calculated as 300 according to (28).
5 Simulation verification
To verify the effectiveness of the proposed control strategy, the multibus islanded microgrid shown in Fig.Â 18 is built in MATLAB/Simulink with the parameters of Table 3 [31]. Different fundamental virtual inductances are set to ensure a rational distribution of the reactive power.
FigureÂ 19 shows the voltage waveform measured at the PCC of bus 5. The THD of the PCC is 6.13% before 2Â s and quickly decreases to 4.06% after applying the proposed control strategy at 2Â s. The imbalance factor is also reduced from 3.28% to 2.01%. Therefore, the power quality is effectively improved.
FigureÂ 20 shows the change in the residual capacity S_{R} and the sum of the harmonic and unbalanced power S_{HU} (S_{H+} S_{U}) of each DG. When the proposed control strategy is not applied, DG 1â€“2 still have a certain residual capacity, while DG 3â€“4 are overloaded. Thus, it is of great importance for the microgrid to redistribute unbalanced/harmonic power to ensure the safe and stable operation of the system. After applying the proposed control strategy at 1Â s, DG 1â€“2 gradually bear more unbalanced/harmonic power, while the unbalanced/harmonic power borne by DG 3â€“4 gradually decreases. Finally, DG 3â€“4 reach the state of S_{HU}â€‰=â€‰S_{R}, which indicates that the unbalanced and harmonic power have reached a reasonable allocation between different DGs.
Tables 4 and 5 list the THD and the unbalance factor of each bus before and after applying the proposed control strategy, respectively. It can be seen that the proposed control effectively avoids the overload of all DGs. Meanwhile, the low impedance paths for the negativesequence fundamental current and harmonic currents significantly improve the power quality of all buses. To demonstrate the effectiveness of the proposed method, the power quality under the sharing strategy is displayed in the tables as the benchmark. It is clear that the proposed control leads to a much better power quality than that of the sharing strategy.
To verify the adaptability of the control strategy under dynamic conditions, load switching events are performed in the simulation. FigureÂ 21 shows the load switching results under three different integral controllers. Because of space limitations, only the results related to DG 1 and 4 are presented here. The virtual impedance control is applied at 1Â s, and the linear load at bus 5 is disconnected at 5Â s and reconnected at 6Â s. In the initial operating state, DG 4 is overloaded, and the capacity of DG 1 is in surplus. When the fuzzy integral controller is used, the power distribution among different DGs quickly reaches the new steady state. In contrast, when the integral parameter k_{vi} is fixed to 10, the imbalance and harmonic power of DGs change slowly, which indicates that the dynamic response is very poor. In contrast, when k_{vi} is fixed at 200, the power oscillates significantly, and the microgrid gradually loses its stability. These results demonstrate that compared with the fixed integral control, the fuzzy integral controller strikes a good balance between the dynamic and convergence performances.
6 Hardware in loop tests
To further verify the effectiveness of the proposed control method, control hardwareintheloop experiments are performed on a realtime simulator system.
To achieve this, the microgrid shown in Fig.Â 22 is built on the Starsim MT6020 simulator, and the controller part is built on the Starsim MT1050 controller. MT1050 receives the electrical measurement signals from MT6020 through the external line and returns the PWM signals to the simulator to form a closed loop. The realtime calculation is performed in steps of 0.5Â Âµs.
FigureÂ 23 shows the change in the residual capacity S_{R} and the sum of the harmonic and unbalanced power S_{HU} (S_{H+} S_{U}) of each DG. It can be seen that the control strategy can reasonably adjust the distribution of imbalance and harmonic power and effectively protect DGs from overload. According to Fig.Â 24, the voltage THD is reduced from 7.96% to 3.88%, and the imbalance factor is also reduced from 3.10% to 2.12%. Therefore, the control strategy achieves the goal of improving the power quality of the microgrid without overloading DGs. The control hardwareintheloop test demonstrates that the computational burden of the proposed controller is acceptable. In [32, 33], more complex controllers have been realized in prototypes, and thus the proposed method is not challenging in real life implementation.
7 Conclusion
This paper presents a new virtual impedance control strategy to enhance the power quality of islanded microgrids. Different from the traditional sharing strategy, the proposed control intends to shape a low output impedance without overloading the DG. This is realized by adjusting the virtual impedance through a fuzzy integral controller until the power limit or the minimum allowable value is reached. These lowimpedance paths absorb harmonic and unbalanced currents, similar to passive filters, and thus improve the power quality of the microgrid. The proposed method is particularly useful for situations where the power quality of the microgrid is the main concern, and accurate power sharing is not mandatory.
This paper also reveals the mechanism of the instability due to virtual impedance control. This instability is mainly caused by the negative impedance effect introduced by the phase lag property of the harmonic extraction process, while using crossover cancellation together with DSOGIQSG enhances the stability to some extent. An adjustment law of the virtual impedance is designed accordingly, which simultaneously changes its real and imaginary parts. Consequently, the stability region is effectively expanded, and the flexibility of the proposed control strategy is enhanced. Simulations and control hardwareintheloop experiments verify the effectiveness of the proposed method. The results demonstrate that the proposed method effectively improves the power quality of the microgrid and that the fuzzy integral controller accelerates the dynamic response. Because the method does not depend on a communication system, it is easy to implement and shows high reliability in real implementation.
As the proposed control strategy only uses local measurements to shape a low impedance, it cannot guarantee the optimal power quality improvement at the system level. The dynamic response of the proposed method can be further enhanced in the future using more advanced control strategies.
Availability of data and materials
The datasets used and/or analysed during the current study are available from the corresponding author on reasonable request.
References
Gurugubelli, V., Ghosh, A., & Panda, A. K. (2022). Parallel inverter control using different conventional control methods and an improved virtual oscillator control method in a standalone microgrid. Protection and Control Modern Power System, 7, 27.
Hu, C., Cai, Z., Zhang, Y., et al. (2022). A soft actorcritic deep reinforcement learning method for multitimescale coordinated operation of microgrids. Protection and Control Modern Power System, 7, 29.
Hao, F., Yuan, Z., Yuan, Z., et al. (2020). Research and practice on offgrid microgrid steady power control strategy. Power System Protection and Control, 48(22), 173â€“179.
Lee, S.J., Choi, J.Y., Lee, H.J., & Won, D.J. (2017). Distributed coordination control strategy for a multimicrogrid based on a consensus algorithm. Energies, 10(7), 1017.
Xin, H., Zhao, R., Zhang, L., Wang, Z., Wong, K. P., & Wei, W. (2016). A Decentralized hierarchical control structure and selfoptimizing control strategy for FP type DGs in islanded microgrids. IEEE Transactions on Smart Grid, 7(1), 3â€“5.
Farokhian Firuzi, M., Roosta, A., & Gitizadeh, M. (2019). Stability analysis and decentralized control of inverterbased ac microgrid. Protection and Control Modern Power System, 4, 6.
Wang, H., Zeng, G., & Dai, Y. (2021). Research on modified droop control of distributed generation units by adaptive populationbased extremal optimization. Power System Protection and Control, 45(7), 2483â€“2491.
Chen, H., Tang, Z., Lu, J., et al. (2021). Research on optimal dispatch of a microgrid based on CVaR quantitative uncertainty. Power System Protection and Control, 49(5), 105â€“115.
Vandoorn, T., Meersman, B., De Kooning, J., & Vandevelde, L. (2012). Controllable harmonic current sharing in islanded microgrids: DG units with programmable resistive behavior toward harmonics. IEEE Transactions on Power Delivery, 27(2), 831â€“841.
De, D., & Ramanarayanan, V. (2010). Decentralized parallel operation of inverters sharing unbalanced and nonlinear loads. IEEE Transactions on Power Electronics, 25(12), 3015â€“3025.
Hoang, T. V., & Lee, H. (2019). Accurate power sharing with harmonic power for islanded multibus microgrids. IEEE Journal of Emerging and Selected Topics in Power Electronics, 7(2), 1286â€“1299.
Lu, J., Zhao, M., Golestan, S., Dragicevic, T., Pan, X., & Guerrero, J. M. (2022). Distributed eventtriggered control for reactive, unbalanced, and harmonic power sharing in islanded AC microgrids. IEEE Transactions on Industrial Electronics, 69(2), 1548â€“1560.
He, J., Li, Y. W., & Blaabjerg, F. (2015). An enhanced islanding microgrid reactive power, imbalance power, and harmonic power sharing scheme. IEEE Transactions on Power Electronics, 30(6), 3389â€“3401.
Liu, B., Liu, Z., Liu, J., An, R., Zheng, H., & Shi, Y. (2019). An adaptive virtual impedance control scheme based on smallACsignal injection for unbalanced and harmonic power sharing in islanded microgrids. IEEE Transactions on Power Electronics, 34(12), 12333â€“12355.
Han, Y., Shen, P., Zhao, X., & Guerrero, J. M. (2016). An enhanced power sharing scheme for voltage unbalance and harmonics compensation in an islanded AC microgrid. IEEE Transactions on Energy Conversion, 31(3), 1037â€“1050.
GÃ¶thner, F., RoldÃ¡nPÃ©rez, J., TorresOlguin, R. E., & MidtgÃ¥rd, O.M. (2021). Harmonic virtual impedance design for optimal management of power quality in microgrids. IEEE Transactions on Power Electronics, 36(9), 10114â€“10126.
Zeng, Z., Yi, H., Zhai, H., Zhuo, F., & Wang, Z. (2017). Harmonic power sharing and PCC voltage harmonics compensation in islanded microgrids by adopting virtual harmonic impedance method. In IECON 201743rd annual conference of the IEEE industrial electronics society (pp. 263267). IEEE.
Budiwicaksana, L. A., Ardriani, T., Furqani, J., Rizqiawan, A., & Dahono, P. A. (2021). Improving inverter output current controller under unbalanced conditions by using virtual impedance. IEEE Access, 9, 162359â€“162369.
Sreekumar, P., & Khadkikar, V. (2016). A new virtual harmonic impedance scheme for harmonic power sharing in an islanded microgrid. IEEE Transactions on Power Delivery, 31(3), 936â€“945.
Lu, Y. (2018). Adaptivefuzzy control compensation design for direct adaptive fuzzy control. IEEE Transactions on Fuzzy Systems, 26(6), 3222â€“3231.
Wang, J., Yan, J. D., Jiang, L., & Zou, J. (2016). Delaydependent stability of singleloop controlled gridconnected inverters with LCL filters. IEEE Transactions on Power Electronics, 31(1), 743â€“757.
Zhang, Y., Wang, Z., Jiao, J., & Liu, J. (2020). Gridvoltage sensorless model predictive control of threephase PWM rectifier under unbalanced and distorted grid voltages. IEEE Transactions on Power Electronics, 35(8), 8663â€“8672.
Kim, J., Guerrero, J. M., Rodriguez, P., Teodorescu, R., & Nam, K. (2011). Mode adaptive droop control with virtual output impedances for an inverterbased flexible AC microgrid. IEEE Transactions on Power Electronics, 26(3), 689â€“701.
Hamzeh, M., Karimi, H., & Mokhtari, H. (2014). Harmonic and negativesequence current control in an islanded multibus MV microgrid. IEEE Transactions on Smart Grid, 5(1), 167â€“176.
Xu, H., Zhang, X., Liu, F., Shi, R., Yu, C., & Cao, R. (2017). A reactive power sharing strategy of VSG based on virtual capacitor algorithm. IEEE Transactions on Industrial Electronics, 64(9), 7520â€“7531.
Liu, H., Xie, X., Zhang, C., Li, Y., Liu, H., & Hu, Y. (2017). Quantitative SSR analysis of seriescompensated DFIGbased wind farms using aggregated RLC circuit model. IEEE Transactions on Power Systems, 32(1), 474â€“483.
IEEE standard definitions for the measurement of electric power quantities under sinusoidal, balanced or unbalanced conditions. IEEE Std 1459â€“2010.
Duan, X., Deng, H., & Li, H. (2013). A saturationbased tuning method for fuzzy PID controller. IEEE Transactions on Industrial Electronics, 60(11), 5177â€“5185.
Luo, A., Tang, C., Shuai, Z., Tang, J., Xu, X. Y., & Chen, D. (2009). FuzzyPIbased directoutputvoltage control strategy for the STATCOM used in utility distribution systems. IEEE Transactions on Industrial Electronics, 56(7), 2401â€“2411.
Tao, C.W., Wang, C.M., & Chang, C.W. (2016). A design of a DCâ€“AC inverter using a modified ZVSPWM auxiliary commutation pole and a DSPbased PIDlike fuzzy control. IEEE Transactions on Industrial Electronics, 63(1), 397â€“405.
Wang, X., Blaabjerg, F., & Chen, Z. (2014). Autonomous control of inverterinterfaced distributed generation units for harmonic current filtering and resonance damping in an islanded microgrid. IEEE Transactions on Industry Applications, 50(1), 452â€“461.
AndalibBinKarim, C., Liang, X., & Zhang, H. (2018). Fuzzysecondarycontrollerbased virtual synchronous generator control scheme for interfacing inverters of renewable distributed generation in microgrids. IEEE Transactions on Industry Applications, 54(2), 1047â€“1061.
Liang, X., AndalibBinKarim, C., Li, W., Mitolo, M., & Shabbir, M. N. S. K. (2021). Adaptive virtual impedancebased reactive power sharing in virtual synchronous generator controlled microgrids. IEEE Transactions on Industry Applications, 57(1), 46â€“60.
Acknowledgements
Not applicable
Funding
The work was supported by the Science and Technology Project of SGCC under grant 5400202219417A2â€“0ZN.
Author information
Authors and Affiliations
Contributions
YW proposed the idea and verified the feasibility of the idea. JT conducted the experiments. JS supported the verification studies and helped revise the paper. XX provided meaningful suggestions on the reresearch. PZ provided useful data to support the case study. JZ supervised the whole research. All authors read and approved the final manuscript.
Corresponding author
Ethics declarations
Competing interests
The authors declare that they have no competing interests.
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Wang, Y., Tang, J., Si, J. et al. Power quality enhancement in islanded microgrids via closedloop adaptive virtual impedance control. Prot Control Mod Power Syst 8, 10 (2023). https://doi.org/10.1186/s4160102300284z
Received:
Accepted:
Published:
DOI: https://doi.org/10.1186/s4160102300284z
Keywords
 Islanded microgrid
 Harmonic power
 Unbalanced power
 Residual capacity
 Adaptive virtual impedance