## 2 Materials and Methods
### Grid Reliability  
For investigation of the primary reasons of grid faults (in particular voltage sags) and their impact on reliability indices, statistical data have been gathered in 2015-2018 during close collaboration with the Lithuanian DSO (\"Energijos skirstymo operatorius\", AB), and classified according to voltage level and target group. The primary data will not be provided in detail due to confidentiality issues. Nevertheless, this issue will not be a considerable obstacle for the development of the allocation strategy. As has been mentioned before, due to the lack of analogous works regarding interconnection between PQ and reliability, our own/specific methodology must be developed considering the format (features) of available statistical data.  
Reliability indexes for a distribution grid (in particular SAIFI and SAIDI) are calculated according to IEEE Std 1366-2022 by the following equations:  
\[\text{SAIFI}=\frac{\text{Total number of customers interrupted}}{\text{Total number of customers served}}. \tag{2}\]  
\[\text{SAIDI}=\frac{\text{Total minutes of interruptions}}{\text{Total number of customers served}}. \tag{3}\]  
Both reliability indexes are calculated when (1) ACR events are included, and (2) not included. The proposal and investigation of such an approach has not been found in the literature. The following definition is proposed for ACR success evaluation through the prism of SAIDI:  
\[\text{Success}\triangleq 1-\frac{\text{SAIDI}_{\geq\text{ACR}}-\text{SAIDI}_{ \geq\text{ACR}}}{\text{SAIDI}_{\geq\text{ACR}}}, \tag{4}\]  
where: SAIDI\({}_{\geq\text{ACR}}\)--SAIDI is a superset of ACR events, i.e., SAIDI \(\supseteq\) ACR; SAIDI\({}_{\geq\text{ACR}}\)--SAIDI is not a superset of ACR events, i.e., SAIDI \(\
ot\supseteq\) ACR.  
Theoretically, if all ACR performances are fully successful, the difference in numerator is equal to 0, and then success is equal to 1. However, it is hardly possible under real-life conditions (e.g., due to time settings of relay protection and automation, latency, incorrect logic, and device failure), hence at least a small influence (minutes of interruptions) is expected. A similar approach can be applied to SAIFI, which will estimate ACR event share. Obviously, both characteristics depend on fault location, grid topology, and level of automation. Since SAIFI is not related to duration, it can be used as a supplementary characteristic for a comparison of similar success values: the higher the ACR event part, the lower is their impact on SAIDI, and the more considerable ACR success is. The ratio through the prism of SAIFI is defined as follows:  
\[\text{Ratio}\triangleq\frac{\text{SAIFI}_{\geq\text{ACR}}-\text{SAIFI}_{ \
ot\supseteq\text{ACR}}}{\text{SAIFI}_{\geq\text{ACR}}}. \tag{5}\]  
Regression analysis is used for relationship estimation, and coefficients of a regression curve are determined using the least squares method. Model fitting is characterized by well-known coefficient of determination, which is generally defined as follows:  
\[R^{2}=1-\frac{SS_{\text{res}}}{SS_{\text{tot}}}, \tag{6}\]  
where: \(SS_{\text{res}}\)--sum of squares of residuals; \(SS_{\text{tot}}\)--total sum of squares.  
The second approach for ACR success evaluation is derived from the geometric meaning of a derivative at point \(x_{0}\):  
\[\frac{d}{dx}f(x_{0})=k=\tan\theta, \tag{7}\]  
where: \(f(x_{0})\)--the regression function at point \(x_{0}\); \(k\)--slope (gradient) of the tangent line; \(\theta\)--the angle between the tangent line and the axis of abscissas. The boundary conditions are the following: (1) when \(\theta\) approaches the straight angle, then the reliability index is not influenced by the quantity of events; (2) when \(\theta\) approaches the right angle, then the influence of a single event goes towards infinity. Mathematically this can be written as follows:  
\[\left(\lim_{\theta\to 0}\theta=0;\lim_{\theta\to\pi/2}\tan\theta=\infty\right). \tag{8}\]