## 3 Theoretical Analysis
### Adaptive Order Algorithm  
The performance of signal denoising is generally evaluated quantitatively via Root Mean Square Error (RMSE) and \(SNR\), and the principle of the proposed adaptive order determination algorithm is closely related to the latter. As such, the definitions of \(RMSE\) and \(SNR\) are first introduced in the following section. \(RMSE\) is defined as  
\[RMSE=\sqrt{\frac{1}{N}\frac{1}{i=1}\big{[}S^{\prime}(i)-S(i)\big{]}^{2}}, \tag{4}\]  
and \(SNR\) is defined as  
\[SNR=10 lg\left(\frac{\sum_{i=1}^{N}S(i)^{2}}{\sum_{i=1}^{N}E(i)^{2}}\right), \tag{5}\]  
where \(S^{\prime}(i)\), \(S(i)\) and \(E(i)\) denote the denoised signal, the noiseless signal and the pure noise signal, respectively. After signal denoising, the smaller the \(RMSE\) or the larger the \(SNR\), the better the performance of the denoising method. The \(SNR\) calculated by Equation (5) is known as accurate \(SNR\). However, for an actual signal collected, \(S(i)\) and \(E(i)\) are unknown, and accurate \(SNR\) cannot be obtained. Therefore, an estimation method is adopted to calculate \(SNR\). Specifically, \(S(i)\) is replaced by \(S^{\prime}(i)\) and \(E(i)\) is replaced by \(E^{\prime}(i)\) (\(E^{\prime}(i)=X(i)-S^{\prime}(i)\)). Substituting \(S^{\prime}(i)\) and \(E^{\prime}(i)\) into Equation (5), the Estimated Signal-to-Noise Ratio (\(ESNR\)) can be obtained:  
\[ESNR=10 lg\left(\frac{\sum_{i=1}^{N}S^{\prime}(i)^{2}}{\sum_{i=1}^{N}\big{|}X (i)-S^{\prime}(i)\big{|}^{2}}\right). \tag{6}\]  
At present, there is no fixed method for selecting the effective order \(k\) in SVD decomposition. The mean value method is commonly used, which computes the mean value of SVD decomposition singular values and sets those below the mean value to zero to determine the order \(k\). However, this method is not self-adaptive and is prone to under-denoising. Literature [19] proposes a method to determine the effective order \(k\) based on the rate of change in the singular values. This method is effective when the noise intensity is low, but underperforms in the case of high noise intensity as changes in singular values representing noise and noiseless signals become less significant and the effective order \(k\) becomes harder to determine. According to the decomposition characteristics of SVD and a large number of existing studies, the number of eigenvalues representing useful signals is twice the number of frequency components in the useful signals. Thus, the optimal order for denoising should be twice the number of frequency components in non-noisy signals. In this paper, different orders \(k\) (\(k\) is even) are selected for SVD denoising of the sample signal. Based on Equations (5) and (6), the accurate \(SNR\) and \(ESNR\) of the signal after denoising are calculated, and the curves of accurate \(SNR\) and \(ESNR\) against different orders are plotted. According to the characteristics of the curves, an adaptive order determination algorithm is proposed to determine the optimal order value \(k\). To illustrate the adaptive order algorithm, an electric power signal containing a fundamental wave, harmonics and interharmonics is constructed as follows. \[ \begin{array}{l}y=8.7 cos(50\pi t+0.167\pi)+14.2 cos(100\pi t+0.25\pi)\\ +4.5 cos(310\pi t+0.2\pi)+1.5 cos(500\pi t+0.333\pi).\end{array}  \tag{7}\]  
The fundamental wave of signal \(y\) is at 50 Hz, containing harmonics at a 250 Hz frequency and interharmonics at 25 Hz and 155 Hz frequencies. A 20 dB white Gaussian noise \(e\) is applied to signal \(y\) to obtain the noisy signal \(Y=y+e\). The adaptive order algorithm also applies to electric power signals with different amplitudes, frequency and phases without loss of generality. Different order values \(k\) (\(k\) is even) are selected for SVD denoising of signal \(Y\). Applying Equations (5) and (6), the curves of \(SNR\) and \(ESNR\) against different order values and their slopes are plotted in Figure 2.  
Figure 2a illustrates the curve of accurate \(SNR\) obtained by Equation (5).