## 3 Prony Algorithm Identification and DC Sensitive Point Sorting  
### Prony Algorithm Identification  
The Prony method can be used for both on-line and off-line monitoring of ULF oscillation modes. The Prony algorithm utilizes real-time data from the phase measurement unit (PMU) for online monitoring and historical data for offline monitoring. The data measured by the PMU can be categorized into time-varying, ambient, and sounding data. The Prony algorithm employs the time-varying data, which is the more densely populated data, for the estimation of various modes. Time-varying data \(y(i)\) can be expressed as:  
\[y(j)=\sum_{i=1}^{n_{\lambda}}c_{i}\mathrm{e}^{j\lambda(i)\Delta t}\,j=0,1, \cdots,N-1, \tag{18}\]  
where, \(n_{\lambda}\) is the total characteristic root number; \(c_{i}\) is the amplitude of the \(i\) mode; \(\lambda(i)\) is the \(i\)th eigenvalue of the system; \(\Delta t\) is the sampling interval; \(N\) is the total data points.  
The steps of Prony algorithm for pattern recognition of power system are as follows [7]:  
**Step 1.** Linear prediction model (LPM) is established. The nth-order LPM is composed of the predicted value \(y(k)\) and the first \(n\) exact value \((y(k-1),y(k-2),\cdots,y(k-n))\) and has: \(y(k)=a_{1}y(k-1)+a_{2}y(k-2)+\cdots+a_{n}y(k-n)\), where \(a_{i}\) is the coefficient of the characteristic equation.  
Let \(k=n,n+1,\cdots,N-1\). There is:  
\[\begin{bmatrix}y(n)\\ y(n+1)\\ \vdots\\ y(N-1)\end{bmatrix}= \tag{19}\] \[\begin{bmatrix}y(n-1)&y(n-2)&\cdots&y(0)\\ y(n)&y(n-1)&\cdots&y(1)\\ \vdots&\vdots&\vdots&\vdots\\ y(N-2)&y(N-3)&\cdots&y(N-n-1)\end{bmatrix},\] \[\begin{bmatrix}a(1)\\ a(2)\\ \vdots\\ a(n)\end{bmatrix}+\begin{bmatrix}\varepsilon(n+1)\\ \varepsilon(n+2)\\ \vdots\\ \varepsilon(N)\end{bmatrix}\]  
where \(a(i)\) is the coefficient of the characteristic equation.  
The coefficient \(a_{1}\), \(a_{2}\), \(\ldots\), \(a_{n}\) of the characteristic equation is obtained by using the least square method.  
**Step 2.** Discrete mode calculation. Variable \(z\) is introduced as the variable of the characteristic polynomial, and combined with the coefficient \(a\) of the characteristic equation obtained in step 1, the \(n\)-degree characteristic polynomial of variable \(z\) is constructed as follows:  
\[z^{n}-(a_{1}z^{n-1}+a_{2}z^{n-2}+\cdots+a_{n}z^{0})=0. \tag{20}\]  
**Step 3.** Residual term calculation in discrete mode. Residual terms of the discrete mode (\(c_{1}\), \(c_{2}\), \(\ldots\), \(c_{n}\)) can represent the amplitude and phase angle, and its calculation formula is as follows:  
\[\begin{bmatrix}z_{1}^{0}&z_{2}^{0}&\cdots&z_{n}^{0}\\ z_{1}^{1}&z_{2}^{1}&\cdots&z_{n}^{1}\\ \vdots&\vdots&\vdots&\vdots\\ z_{1}^{N}&z_{2}^{N}&\cdots&z_{n}^{N}\end{bmatrix}. \tag{21}\]  
**Step 4.** Discrete mode parameter calculation. The formula for calculating amplitude (\(A_{i}\)), phase angle (\(P_{i}\)), frequency (\(f_{i}\)), and oscillation factor (D) is as follows:  
\[\left\{\begin{array}{l}A_{i}=\left|c_{i}\right|\\ P_{i}=\arctan\left|\frac{Im(c_{i})}{\mathrm{Re}(c_{i})}\right|\\ f_{i}=\frac{1}{2\pi\Delta t}\arctan\left|\frac{Im(z_{i})}{\mathrm{Re}(z_{i}) }\right|\\ \sigma_{i}=\left.In\left|z_{i}\right|/\Delta t\right.\end{array}\right.. \tag{22}\]  
**Step 5.** Distinguish the real number mode and conjugate complex number mode, and calculate the energy of each mode.  
For real numbers, there are:  
\[E_{i}=\sum\limits_{j=1}^{N}{\left[real(c_{i}z_{i}^{j})\right]^{2}}. \tag{23}\]  
For conjugate complex modes, there are:  
\[E_{i}=\sum\limits_{j=1}^{N}{\left[2 real(c_{i}z_{i}^{j})\right]^{2}}. \tag{24}\]  
Different modes have different energy levels. By calculating the energy of each mode and classifying it, the dominant mode of the power system can be identified. Mode energy is defined as \(E_{i}=\sum\limits_{j=1}^{N}{\left[real(c_{i}z_{i}^{j})\right]^{2}}\) when \(c_{i}\) or \(z_{i}\) mode value is large, \(E_{i}\) is high, and this mode is the dominant mode.