# Advancing Fault Detection in Distribution Networks with a Real-Time Approach Using Robust RVFLN
## 2 Fault Detection Method
### RVFLN Algorithm  
The RVFLN algorithm was published in 1992 by [PERSON] et al. as a single-hidden-layer feed-forward network [45]. Figure 1 shows the basic structure of RVFLN. Since its development, the RVFLN model has been successfully used for regression and classification in various engineering applications [46; 47; 48]. However, it has not been used for fault type and location detection in distribution networks. The main advantage of this method is that the weights between the input layer and the hidden layer are randomly assigned [49; 50]. It also has the advantage of calculating the output weights using the least squares (LS) algorithm. Another advantage of this method is that it can process data in real time for engineering applications [51; 52].  
The data consist of training samples, \(D=\{(s_{o},z_{o})|o=1,\ldots,N\}\subset\mathbb{R}^{d}\times R\). This is indicated as a special type of SLFN with K hidden nodes [53].  
\[h(s)=\sum_{u=1}^{K}\alpha_{u}f_{u}(t_{u},n_{u},s) \tag{1}\]  
\(t_{u}\) and \(n_{u}\) are hidden node parameters. Between the hidden layer node and the output node is \(\alpha_{u}\), which is also defined as the output weight. \(f_{u}\) can be used as a radial basis activation function.  
\[f_{u}=f(\frac{\left\|s-t_{u}\right\|}{n_{u}})\hskip 28.452756 ptt_{u}\in\mathbb{R }^{d},n_{u}\in\mathbb{R}^{+} \tag{2}\]  
The norm \(\ell_{2}\) is indicated by \(\left\|\bullet\right\|\). The sum of squared errors is preferred as a cost function for N samples \((s_{o},z_{o})\subset\mathbb{R}^{d}\times R\).  
\[V=\sum_{o=1}^{N}\left\|\sum_{u=1}^{K}\alpha_{u}f_{u}(t_{u},n_{u},s_{o})-z_{o} \right\|^{2} \tag{3}\]  
In the RVFLN algorithm, the hidden node parameters (\(t_{u}\) and \(n_{u}\)) can be given randomly. However, the linear parameters of the output layer are calculated analytically. Using Equation (3), a quadratic optimization problem is obtained.  
\[\arg\min_{\alpha}\left\|\mathbb{F}\alpha-\mathbb{Z}\right\|^{2}, \tag{4}\]  
\[F=\begin{bmatrix}f(t_{1},n_{1},s_{1})&\ldots&f(t_{K},n_{K},s_{1})\\ \vdots&\ddots&\vdots\\ f(t_{1},n_{1},s_{N})&\ldots&f(t_{K},n_{K},s_{N})\\ \end{bmatrix}_{N\times K} \tag{5}\]  
Figure 1: RVFLN algorithm.  
\[\alpha=\begin{bmatrix}\alpha_{1}\\ \vdots\\ \alpha_{K}\end{bmatrix}_{K\times 1}\quad and\quad\quad\quad\mathbf{Z}= \begin{bmatrix}z_{1}\\ \vdots\\ z_{N}\end{bmatrix}_{N\times 1} \tag{6}\]  
**F** is the hidden layer output. **Z** is the sampled output. \(\alpha\) is the sampled output's weight. The optimal output weight \(\alpha\) is calculated as in Equation (7).  
\[\alpha=\mathbf{F}^{\dagger}\mathbf{Z} \tag{7}\]  
**F\({}^{\dagger}\)** can be described as the Moore-Penrose generalized inverse of **F**. According to the results described in [53; 54], fixed coverage for \(t\) and \(n\) does not guarantee the modeling performance. Therefore, when using RVFLN, it is necessary to pay sufficient attention to this scope setting. One way to solve this scope setting problem is to assign arbitrary parameters from the \([\lambda,+\lambda]\) variable's scope. It is also necessary to choose a reasonable value according to some specific criteria.