## 3 Identification Model of the User-Transformer Relation in LVDNs  
In this work, by analyzing the electrical distance between nodes, topological relationship discrimination can be achieved by calculating the virtual impedance between the nodes in the power system to determine their degree of connection closeness and to derive the topology of the LVDNs [23]. For LVDNs, assume that the current in the branch circuit is I\({}_{i}\), the reactance is X\({}_{i}\), and the power factor of the branch circuit is \(\cos\phi_{i}\). Then, the reactance of the branch is as follows:  
\[X_{i}=R_{i}\tan\phi_{i} \tag{26}\]  
The active power loss of this branch circuit is  
\[P_{i}=I_{i}^{2}R_{i}\cos\phi_{i} \tag{27}\]  
The reactive power loss is  
\[Q_{i}=I_{i}^{2}X_{i}\sin\phi_{i}=I_{i}^{2}R_{i}\sin\phi_{i}\tan\phi_{i} \tag{28}\]  
The total power loss in this branch circuit is  
\[S_{i}=I_{i}^{2}R_{i}+I_{i}^{2}X_{i}=I_{i}^{2}R_{i}(1+\tan^{2}\phi_{i})=I_{i}^ {2}R_{i}\sec^{2}\phi_{i} \tag{29}\]  
For \(n\) users,  
\[P_{1}-\sum\limits_{i=2}^{n}P_{i}=(\sum\limits_{i=2}^{n}I_{i})\overset{2}{R_{1 }}\sec^{2}\phi_{1}+(\sum\limits_{i=2}^{j}\overset{2}{R_{2}}\sec^{2}\phi_{2}+ \cdots+\sum\limits_{i=j}^{n}I_{i}^{2}R_{i}\sec^{2}\phi_{i} \tag{30}\]  
We use C\({}_{ij}\) to substitute the coefficients of I\({}_{i}\) and I\({}_{j}\):  
\[P_{A}-\sum\limits_{i=1}^{n}P_{i}=C_{11}I_{1}^{2}+C_{12}I_{1}I_{2}+\cdots+C_{ \rm{nm}}I_{n}^{2} \tag{31}\]  
where \(\overset{n}{\underset{i=1}{\sum}}P_{i}\) is the sum of the power at the exit of the branch monitoring meter for node \(1\); \(P_{i}\) is the power at the exit of the branch monitoring meter for node \(i\); \(P_{A}\) is the power exported from the secondary side of the transformer; and \(C_{ij}\) is the coefficient of \(I_{i}\) and \(I_{j}\) in Equation (6). The value of \(C_{ij}\) depends on the topology of the LVDNs and impedance values of the lines and transformers in the network. When there is a connection between nodes \(i\) and \(j\), \(C_{ij}\) is equal to the product of the impedance value of the upstream segments at the upstream intersection of the two nodes and the inverse square of the power factor. When there is no connectivity between nodes \(i\) and \(j\), \(C_{ij}\) is zero. The following multiple linear regression equation can be written for node \(i\):  
\[y_{i}=\beta_{0}+\beta_{1}x_{i1}+\beta_{2}x_{i2}+\cdots+\beta_{n}x_{in}+\epsilon _{i} \tag{32}\]  
\[y_{i}=P_{i1}-\sum\limits_{j=1}^{n}P_{ij} \tag{33}\]  
\[x_{ij}=I_{i}I_{j},x_{i}=[x_{i1},x_{i2},\cdots,x_{in}] \tag{34}\]We write the above problem in matrix form:  
\[Y=X\beta+\varepsilon \tag{35}\]  
where \(\beta\) is the vector of unknown parameters; \(\varepsilon\) is an \(m\times 1\) error vector and indicates the difference between predicted values of the model and actual values. Elastic network regression combines the strengths of both ridge regression and lasso regression, making it a versatile tool in statistical modeling. Compared to ridge regression, elastic network regression allows for efficient variable selection and simplification of the model by setting certain coefficients to zero. Elastic network regression can handle situations with a large number of predictors better, allowing it to select more features than lasso. As a result, to calculate the magnitude of the virtual impedance value, we use elastic network regression solve the problem [24]. The objective function of elastic network regression is as follows:  
\[P_{i}=I_{i}^{2}R_{i}\cos\phi_{i} \tag{27}\]0  
Finally, the virtual impedance values between nodes are analyzed. After the obtained virtual impedance has been normalized, the proposed impedance values are compared with preset threshold C\({}_{0}\) according to the threshold determination method to determine whether there is a connection between the nodes, and the nodes with larger virtual impedance than the set threshold value are identified as abnormal nodes.