In the context of global energy transition and the rapid advancement of renewable technologies, photovoltaic (PV) power generation has gained widespread adoption in electrical systems due to its clean and sustainable nature. The grid tied inverter, serving as the core component of PV systems, converts direct current generated by PV panels into alternating current suitable for grid integration. The stability and reliability of grid tied inverters are paramount for grid efficiency and operational safety. However, in practical applications, adverse environmental factors, equipment aging, and communication protocol issues can impair the performance of grid tied inverters. Numerous case studies indicate that communication faults in grid tied inverter modules occur frequently. Such faults not only lead to abnormal data transmission between the inverter and central control systems but also cause unplanned shutdowns, posing significant threats to grid security. To address this, there is an urgent need for effective communication fault detection methods for grid tied inverter modules. Existing approaches often suffer from detection interruptions, resulting in low signal integrity post-fault detection, or limited applicability under varying operational conditions. In this study, we propose a novel fault detection method based on an improved wavelet packet transform, combined with a BP neural network optimized by the marine predator algorithm, aiming to enhance detection accuracy and robustness for grid tied inverter modules.
The proposed method focuses on refining the wavelet packet transform process to obtain high-quality wavelet packets and superior signal representations. Wavelet packet transform enables multi-scale analysis and adjustable resolution, allowing for detailed examination of communication signals from grid tied inverters. The core formulas for wavelet packet coefficients at different frequency channels are given as follows:
$$ \alpha_{2i}(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} h_k \alpha_i(2t – k) $$
$$ \alpha_{2i+1}(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} g_k \alpha_i(2t – k) $$
Here, \( h_k \) represents the low-pass filter coefficients, \( g_k \) represents the high-pass filter coefficients, \( i \) denotes the frequency index, \( t \) is the time variable, \( \alpha_i(t) \) is the wavelet packet function, \( k \) is a translation parameter in the integer set \( \mathbb{Z} \). By setting \( i = 0 \), the initial low-frequency and high-frequency wavelet packet coefficients are derived as:
$$ \alpha_0(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} h_k \alpha_0(2t – k) $$
$$ \alpha_1(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} g_k \alpha_0(2t – k) $$
The scaling function \( \phi(t) \) and the wavelet function \( \psi(t) \) are defined through the two-scale equations:
$$ \phi(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} h_k \phi(2t – k) $$
$$ \psi(t) = \sqrt{2} \sum_{k \in \mathbb{Z}} g_k \phi(2t – k) $$
These functions form an orthogonal wavelet packet basis. To mitigate aliasing effects and reduce feature vector discrepancies during sampling, we incorporate a frequency-shifting technique. Utilizing the time-shift property of Fourier transform, the operation is expressed as:
$$ \mathcal{F}[f(t + t_0)] = e^{j\omega t_0} \mathcal{F}(\omega) $$
where \( f(t) \) is the time-domain signal, \( \mathcal{F} \) denotes the Fourier transform, \( \omega \) is the angular frequency, and \( t_0 \) is the time shift. This adjustment helps in lowering the signal frequency and enhancing the clarity of extracted features from grid tied inverter communication signals. The improved wavelet packet decomposition thus provides a robust foundation for subsequent fault detection by capturing intricate signal characteristics.

Following the wavelet packet processing, we construct a fault detection network using a BP neural network. Traditional neural networks often rely on fixed learning rates and gradient-based updates, which can lead to significant discrepancies between predicted and actual values, along with poor control over iteration convergence. To overcome this, we integrate the resilient backpropagation (Rprop) algorithm, which adapts learning rates dynamically. Let \( \theta \) denote the network parameters to be updated. The adjustment \( \Delta^{(\tau)} \) for iteration \( \tau \) is computed as:
$$ \Delta^{(\tau)} = \begin{cases}
\eta^+ \cdot \Delta^{(\tau-1)}, & \text{if } \frac{\partial E^{(\tau-1)}}{\partial \theta} \cdot \frac{\partial E^{(\tau)}}{\partial \theta} > 0 \\
\eta^- \cdot \Delta^{(\tau-1)}, & \text{if } \frac{\partial E^{(\tau-1)}}{\partial \theta} \cdot \frac{\partial E^{(\tau)}}{\partial \theta} < 0 \\
\Delta^{(\tau-1)}, & \text{otherwise}
\end{cases} $$
where \( \eta^+ \) and \( \eta^- \) are the increase and decrease factors (typically \( \eta^+ > 1 \), \( \eta^- < 1 \)), \( \frac{\partial E^{(\tau)}}{\partial \theta} \) is the gradient of the cost function \( E \) with respect to \( \theta \) at iteration \( \tau \). The parameter update rule is then:
$$ \theta^{(\tau+1)} = \begin{cases}
\theta^{(\tau-1)}, & \text{if } \frac{\partial E^{(\tau-1)}}{\partial \theta} \cdot \frac{\partial E^{(\tau)}}{\partial \theta} < 0 \\
\theta^{(\tau)} – \text{sign}\left( \frac{\partial E^{(\tau)}}{\partial \theta} \right) \cdot \Delta^{(\tau)}, & \text{otherwise}
\end{cases} $$
This adaptive mechanism ensures stable and efficient training of the BP neural network, enhancing its capability to detect faults in grid tied inverter modules accurately.
To optimize the neural network’s performance, we employ the marine predator algorithm (MPA) for training. MPA is a metaheuristic algorithm inspired by the foraging behavior of marine predators, which balances exploration and exploitation effectively. The algorithm initializes a population of solutions (neurons) within a defined search space:
$$ \mathbf{X}_0 = \mathbf{X}_{\text{min}} + \text{rand}() \cdot (\mathbf{X}_{\text{max}} – \mathbf{X}_{\text{min}}) $$
where \( \mathbf{X}_{\text{max}} \) and \( \mathbf{X}_{\text{min}} \) are the upper and lower bounds of the search space, and \( \text{rand}() \) generates a uniform random number in [0,1]. During optimization, adaptive parameters are introduced to control movement speeds in early and mid-iteration phases. The Lévy flight strategy is utilized to set step sizes for neuron updates, enhancing global search ability. The step size based on Lévy distribution is given by:
$$ \text{Step} = \frac{u}{|\nu|^{1/\beta}} $$
where \( u \) and \( \nu \) are normally distributed random variables, and \( \beta \) is a constant (typically 1.5). To avoid local optima, an individual matrix of neurons is constructed, and positions are updated using MPA’s rules based on predator-prey interactions. The fitness function for optimization is the mean squared error (MSE) between network outputs and actual fault labels:
$$ \text{MSE} = \frac{1}{N} \sum_{i=1}^{N} (y_i – \hat{y}_i)^2 $$
where \( N \) is the number of samples, \( y_i \) is the true label, and \( \hat{y}_i \) is the predicted output. Through iterative training, the optimized network achieves high accuracy in fault detection for grid tied inverter modules.
For experimental validation, we establish a simulation environment to compare the proposed method with existing approaches. A three-phase grid tied inverter model is constructed, incorporating an equivalent DC-link model to simulate various communication fault scenarios. The original three-phase output currents \( I_1, I_2, I_3 \) from the grid tied inverter serve as input signals. Data collection involves 1,100 samples under standard conditions: irradiance of 1,000 W/m² and temperature of 25°C. The dataset is split into training and testing sets in a 3:2 ratio, resulting in 660 training samples and 440 testing samples. To assess robustness, multiple operational conditions are considered, as summarized in Table 1.
| Condition ID | Irradiance (W/m²) | Temperature (°C) |
|---|---|---|
| TG-001 | 1000 | 25 |
| TG-002 | 1200 | 25 |
| TG-003 | 800 | 25 |
| TG-004 | 1000 | 20 |
| TG-005 | 1000 | 15 |
The performance metrics include communication integrity and anti-interference capability. Communication integrity reflects the signal quality after fault detection and correction, defined as:
$$ D = \frac{P_i}{P_{\text{all}}} \times 100\% $$
where \( P_i \) denotes the signal with missing components post-fault, and \( P_{\text{all}} \) represents the total transmitted signal. Anti-interference capability is measured by the number of detection interruptions during operation, with a baseline set at 4 interruptions; lower counts indicate better robustness. Each method is run 50 times to ensure statistical reliability.
The experimental results for communication integrity across different conditions are presented in Table 2. Our method consistently maintains high signal integrity rates around 98%, outperforming other methods which show lower and more variable rates. This demonstrates the effectiveness of our improved wavelet packet and neural network approach in preserving signal quality for grid tied inverter modules.
| Condition ID | Proposed Method | Reference Method A | Reference Method B |
|---|---|---|---|
| TG-001 | 98.35 | 93.24 | 89.15 |
| TG-002 | 97.98 | 93.33 | 88.20 |
| TG-003 | 97.22 | 92.15 | 89.51 |
| TG-004 | 97.15 | 91.05 | 90.25 |
| TG-005 | 98.01 | 91.88 | 91.02 |
Regarding anti-interference capability, the number of detection interruptions is plotted in Figure 1. Our method exhibits minimal interruptions across all conditions, staying well below the baseline of 4, whereas other methods experience higher interruption counts. This highlights the robustness of our approach under diverse operational scenarios for grid tied inverters.
The superior performance can be attributed to the synergistic combination of improved wavelet packet transform and optimized neural network training. The wavelet packet enhancement allows for precise extraction of fault features from grid tied inverter communication signals, even in noisy environments. The mathematical formulation of the wavelet packet energy distribution for fault characterization is given by:
$$ E_{j,k} = \int |W_{j,k}(t)|^2 dt $$
where \( W_{j,k}(t) \) is the wavelet packet coefficient at scale \( j \) and position \( k \). This energy distribution serves as input features to the BP neural network. The network architecture comprises an input layer with neurons corresponding to feature dimensions, hidden layers with adaptive neuron counts optimized by MPA, and an output layer for fault classification. The activation function used in hidden layers is the sigmoid function:
$$ \sigma(x) = \frac{1}{1 + e^{-x}} $$
and the output layer employs softmax for multi-class fault detection. The training process minimizes the cross-entropy loss function:
$$ L = -\sum_{c=1}^{C} y_c \log(\hat{y}_c) $$
where \( C \) is the number of fault classes, \( y_c \) is the binary indicator for class \( c \), and \( \hat{y}_c \) is the predicted probability. The MPA optimization fine-tunes network weights and biases, ensuring convergence to an optimal solution. This integrated methodology effectively addresses the limitations of prior methods, such as detection interruptions and low signal integrity, making it suitable for real-world applications in grid tied inverter monitoring.
In conclusion, we have developed a comprehensive fault detection method for grid tied inverter modules based on improved wavelet packet transform and neural network optimization. The method enhances detection accuracy, reduces interruptions, and maintains high signal integrity across various operational conditions. Future work will involve testing the method under more extreme environments and integrating advanced techniques like L4 autonomous driving and hybrid energy storage for broader applicability. This research contributes to the theoretical framework of fault diagnosis in renewable energy systems and offers practical value for ensuring the reliability and safety of grid tied inverters in photovoltaic power generation.
