With the increasing global emphasis on renewable energy, photovoltaic (PV) power generation has emerged as a clean and sustainable energy source, widely adopted in various applications. However, due to complex geographical and environmental conditions, grid structures in many regions, particularly in remote or rural areas, often exhibit weak grid characteristics. In weak grid environments, solar inverters, which are critical components for connecting PV systems to the grid, face numerous challenges such as grid voltage fluctuations, harmonic pollution, and system instability. These issues can severely impact the operational efficiency and reliability of PV systems. Traditional control methods for solar inverters, including linear control strategies like Proportional-Integral-Derivative (PID) control, are simple to implement but often fall short in achieving desired performance under severe grid voltage variations and harmonic disturbances. To address these limitations, we propose an automatic control method for stable operation of solar inverters in weak grids, based on Space Vector Pulse Width Modulation (SVPWM) and virtual impedance correction. This method aims to enhance the stability and efficiency of solar inverters by integrating advanced modeling, modulation techniques, and adaptive control strategies. In this article, we present a comprehensive approach that includes mathematical modeling of inverter dynamics, analysis of key instability factors, and the implementation of SVPWM, virtual impedance correction, and improved second-order generalized integrator filters. Our goal is to ensure that solar inverters maintain robust performance even under challenging weak grid conditions, thereby improving overall grid power quality.
The operation of solar inverters in weak grids is influenced by several factors, including grid impedance variations and phase-locked loop (PLL) performance degradation. To develop an effective control strategy, we first establish a mathematical model for a three-phase LCL-type grid-connected solar inverter system. The LCL filter is commonly used in solar inverters due to its superior harmonic attenuation capabilities. The dynamic equations governing the inverter system are derived as follows:
$$ L_1 \frac{d}{dt} i_{1abc} + R_1 i_{1abc} = u_{abc} – u_{Cabc} $$
$$ (L_2 + L_g) \frac{d}{dt} i_{2abc} + R_2 i_{2abc} = u_{Cabc} – u_{gabc} $$
$$ i_{Cabc} = i_{1abc} + i_{2abc} $$
$$ i_{Cabc} = C \frac{d}{dt} u_{Cabc} $$
where \( i_{1abc} \) and \( i_{2abc} \) represent the inverter-side and grid-side currents, respectively; \( u_{abc} \) and \( u_{gabc} \) denote the inverter output voltage and grid voltage; \( u_{Cabc} \) is the capacitor voltage; \( L_1 \) and \( L_2 \) are the inverter-side and grid-side inductances; \( R_1 \) and \( R_2 \) are parasitic resistances; \( C \) is the filter capacitance; and \( L_g \) represents the grid inductance. To simplify analysis, these equations are transformed into the dq-frame using Park transformation, which converts three-phase quantities into two-phase components. This transformation facilitates the design of control algorithms by decoupling active and reactive power components. In weak grids, the grid impedance \( L_g \) cannot be neglected, as it significantly affects system stability. The open-loop transfer function of the LCL filter is given by:
$$ G_{LCL}(s) = \frac{i_2(s)}{u_{inv}(s)} = \frac{1}{L_1 (L_2 + L_g) C s^3 + (L_1 + L_2 + L_g) s} = \frac{1}{(L_1 + L_2 + L_g) s} \frac{\omega_r^2}{s^2 + \omega_r^2} $$
where \( s \) is the complex frequency variable, \( \omega_r \) is the resonant frequency, and \( u_{inv} \) is the bridge arm output voltage. As grid impedance increases, the system may exhibit resonance peaks, leading to potential instability. The system loop gain is expressed as:
$$ T(s) = G_1(s) G_2(s) H_i $$
where \( G_1(s) \) and \( G_2(s) \) are transfer functions of impedance components, and \( H_i \) is the feedback coefficient. The PLL is responsible for synchronizing the inverter output with the grid voltage phase. In weak grids, voltage fluctuations and harmonics can degrade PLL performance, causing phase tracking errors. Traditional DC voltage control often uses PI regulators, which may result in significant oscillations. To overcome this, we employ SVPWM combined with a dual-loop control strategy (current and voltage loops) for enhanced stability. SVPWM technique precisely controls the switching states of the solar inverter bridge arms, generating a rotating magnetic field that minimizes harmonic distortion and improves power quality. The switching function is defined as:
$$ S_x = \begin{cases} 1, & H = P \\ 0, & H = O \\ -1, & H = N \end{cases} $$
where \( P \), \( O \), and \( N \) represent positive, zero, and negative voltage states, respectively, and \( H \) denotes the current voltage state. Based on switching states, space voltage vectors are categorized into large, medium, positive small, negative small, and zero vectors. The rotation of space vectors is described by:
$$ V’ = V \cdot e^{j \frac{\pi}{3} (1-n)} $$
where \( V’ \) and \( V \) are the rotated and original space vectors, \( j \) is the rotation count, and \( n \) is the sector number. In the dual-loop control, the inner current loop ensures fast current tracking and suppresses current fluctuations, while the outer voltage loop stabilizes the DC-link voltage and responds to grid voltage changes. By carefully designing the controller parameters, we achieve synchronization between inverter output current and grid voltage, along with stable DC voltage control.
Despite the improvements from SVPWM and dual-loop control, our analysis reveals that grid impedance variations and PLL performance issues remain critical challenges in weak grids. To further enhance stability, we introduce a virtual impedance correction strategy. This strategy emulates grid impedance changes, allowing real-time adjustment of control parameters. Additionally, we incorporate a system delay conversion mechanism to improve real-time performance. The total delay is calculated as:
$$ G_u(s) = \frac{E \cdot G_d(s)}{T_s} $$
where \( G_u(s) \) is the total delay, \( E \) is the computational delay, \( G_d(s) \) is the sampling delay, and \( T_s \) is the sampling period. After computing the total delay, we adjust time parameters in the control algorithm to meet real-time requirements. The current control function, based on a second-order proportional-resonant controller, is given by:
$$ G_i(s) = k_p + \frac{k_r \omega_i s}{s^2 + \xi \omega_i s + \omega_0^2} $$
where \( k_p \) is the proportional coefficient, \( k_r \) is the resonant coefficient, \( \omega_0 \) is the grid fundamental frequency, \( \omega_i \) is the resonant bandwidth frequency, and \( \xi \) is the damping coefficient. For impedance correction, we implement a parallel virtual impedance model. The virtual impedance value is derived as:
$$ Z'(s) = \frac{Z'(s) Z_s(s)}{Z'(s) + Z_s(s)} $$
where \( Z'(s) \) is the virtual impedance and \( Z_s(s) \) is the actual grid impedance. The grid current feedback is essential in this process, and since it represents a second-order differential环节, we use a second-order resonant integrator as the feedback function. After applying parallel virtual impedance, the feedforward function becomes:
$$ G_v(s) = \frac{L_1 C s^2 + 1}{K_{PWM}} $$
where \( K_{PWM} \) is the ratio of control signal to measured signal. We adjust the system’s virtual impedance based on this feedback function. To address PLL inaccuracies under grid voltage disturbances, we improve the PLL algorithm using dual second-order generalized integrators. These integrators extract positive and negative sequence components of the grid voltage. The positive sequence component is used for phase locking, generating control signals to synchronize the solar inverter with the grid. The positive sequence component is expressed as:
$$ U_{abc}^+ = [U_a^+, U_b^+, U_c^+]^T $$
where \( U_a^+ \), \( U_b^+ \), and \( U_c^+ \) are the positive sequence voltages of phases a, b, and c, respectively. By integrating these improvements, our control method ensures robust operation of solar inverters in weak grids.

To evaluate the performance of our proposed automatic control method for solar inverters, we conducted simulations in a Simulink environment that mimics weak grid conditions, including adjustable grid impedance devices and sources simulating voltage fluctuations. The solar inverter parameters were set with a resonant coefficient of 15, bandwidth frequency of 15 Hz, damping coefficient of 0.8, and fundamental frequency of 60 Hz. We compared our method with traditional control approaches, such as operator panel control and external terminal control, analyzing grid current harmonic content and inverter output under sudden impedance increases. The results demonstrate that our method significantly reduces harmonic distortion and maintains stable current output. For instance, the harmonic content with our method fluctuates between 0.1% and 0.6%, whereas traditional methods range from 0.2% to 1.8%. Additionally, under impedance variations, the output current waveform with our method shows more regular and stable oscillations between -250 A and 250 A.
Further comparisons were made with recent advanced solar inverter control methods to validate our approach. We evaluated key performance indicators, including output conversion efficiency, total harmonic voltage distortion (THD), voltage unbalance, output voltage deviation, and output current deviation. The simulation results are summarized in Table 1, which highlights the superior performance of our method across all metrics. For example, our method achieves an output conversion efficiency of 98.48%, THD of 0.53%, voltage unbalance of 0.24%, voltage deviation of 0.50 V, and current deviation of 0.10 A, outperforming other methods.
| Method | Conversion Efficiency (%) | THD (%) | Voltage Unbalance (%) | Voltage Deviation (V) | Current Deviation (A) |
|---|---|---|---|---|---|
| Proposed Method | 98.48 | 0.53 | 0.24 | 0.50 | 0.10 |
| Method 2 | 94.87 | 1.14 | 0.59 | 1.05 | 0.22 |
| Method 3 | 91.03 | 0.78 | 0.41 | 0.68 | 0.14 |
| Method 4 | 92.74 | 0.91 | 0.47 | 0.82 | 0.15 |
The mathematical foundation of our control method can be further elaborated using additional formulas. For instance, the stability analysis involves the Nyquist criterion applied to the loop gain. The characteristic equation of the system is derived as:
$$ 1 + T(s) = 0 $$
where \( T(s) \) is the loop gain. By solving this equation, we can assess system stability margins. Moreover, the virtual impedance correction enhances the damping of resonance peaks. The adjusted impedance value is continuously updated based on real-time grid conditions, ensuring adaptive performance. The transfer function for the improved PLL using dual second-order generalized integrators is given by:
$$ G_{PLL}(s) = \frac{k_p s + k_i}{s^2 + \omega_0^2} $$
where \( k_p \) and \( k_i \) are proportional and integral gains, respectively. This design minimizes phase errors and improves synchronization accuracy.
In conclusion, our proposed automatic control method for solar inverters in weak grids effectively addresses key challenges such as grid impedance variations and harmonic distortions. By integrating SVPWM, virtual impedance correction, and enhanced second-order generalized integrators, we achieve high stability and efficiency in solar inverter operation. The simulation results confirm that our method outperforms existing techniques in terms of conversion efficiency, harmonic suppression, and voltage/current regulation. This approach ensures reliable integration of PV systems into weak grids, contributing to improved power quality and grid stability. Future work could explore the application of this method under more diverse scenarios, such as varying光照 intensity, temperature fluctuations, and grid faults, to further enhance the robustness of solar inverters.
