# Adaptive PI + VPI Harmonic Current Compensation Strategy under Weak Grid Conditions
## 1 Introduction  
The new energy distributed generation system has been widely expanded under the guidance of the goal of \"carbon dioxide emission peak\" and \"carbon neutrality\", along with the scattered location of distributed generation systems, long-distance transmission lines and multiple transformers often used for interconnection. The connection of distributed generation systems to the public power grid leads to an increase in grid impedance that cannot be ignored, making the public power grid exhibit weak grid characteristics with a low short circuit ratio (SCR) [1, 2, 3]. According to IEEE standard 1204-1997, the grid is a weak one when the SCR \(<3\). In addition, an increasing number of power electronic devices and other nonlinear loads inject a large amount of harmonic and reactive current into the power grid, resulting in distortion, unbalance [4, 5] and frequency deviation of the voltage at the point of common coupling (PCC) of the weak grid, and may even cause large frequencydeviation [6]. This phenomenon usually does not appear in the strong power grid. With the increasing penetration of new energy distributed systems, the power quality problem under weak grid conditions has become a research hotspot in recent years, especially the detection accuracy of grid frequency and phase under weak grid conditions [7; 8]. Grid synchronous phase-locked technology is used to accurately extract the phase, frequency and other information of the positive sequence fundamental component of the grid from the collected grid signals. When the grid voltage is unbalanced and distorted and the frequency deviates, the conventional phase-locked loop based on the Fourier transform algorithm has the problem of spectrum leakage and reduces the accuracy of phase frequency estimation [9]. Although the introduction of a low-pass filter can improve harmonic suppression, it leads to a decrease in the phase-locked loop bandwidth and cannot quickly track the change in grid frequency and phase [10]. [PERSON] introduced a multiple second-order generalized integrator into the grid synchronization frequency-locked loop and proposed a multi-resonant frequency adaptive synchronization method. This method has strong detection capability under severe distortion and unbalanced conditions of the grid-side voltage [11]. [PERSON] introduced a decoupling network to achieve better phase estimation under the conditions of grid voltage distortion, phase unbalance and frequency transients and to reduce the impact of grid distortion on PLL performance. Both of the above methods require extraordinary calculation [12]. [PERSON] combined the complex variable notch filter and the moving average filter in series to form a hybrid filtering link for the PLL algorithm, which eliminated the influence of voltage distortion. When the frequency deviation is small, it has a small frequency overshoot, can quickly track the phase jump and has a fast transient response. The disadvantage is that it cannot adaptively adjust the notch frequency according to the estimated value of the grid frequency, and the implementation form is too complicated to be easily implemented in engineering [13]. [PERSON] used an improved delayed signal cancellation (DSC) filter unit to form a phase-locked loop. The phase-locked loop can accurately estimate the phase and frequency of the power grid, has fast dynamic response performance and can respond to frequency deviation, but there is no analysis or research on the realization form of frequency adaptation [14]. [PERSON] proposed a phase-locked strategy based on a low-pass notch filter PLL (LPN-PLL), which has good robustness to grid voltage unbalance and distortion, and still has good adaptability under the conditions of voltage drop, phase jump and frequency deviate [15]. However, the mechanism of frequency adaptability and the convergence characteristics of adaptive parameters are not discussed in detail.