Machine learning-based state prediction and optimization of orthogonal iterative abort strategy for unbalanced power grids
Published Online: Mar 21, 2025
Received: Nov 11, 2024
Accepted: Feb 24, 2025
DOI: https://doi.org/10.2478/amns-2025-0618
Keywords
© 2025 Lei Wu et al., published by Sciendo
This work is licensed under the Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
As global warming and environmental pollution are becoming increasingly severe, governments have formulated a series of energy-saving and emission reduction policies and put forward the concept of carbon neutrality, in which the construction of new power systems mainly based on new energy sources is an important task during China’s “14th Five-Year Plan” [1-3]. With the increasing proportion of distributed power generation and other new energy power generation systems, the power electronic converter equipment connected to the power system is increasing, and the access of a large number of nonlinear loads has an important impact on the power quality of the power grid, which is most prominently manifested in the increase of the three-phase imbalance degree of the grid, so analyzing and mastering the three-phase imbalance characteristics of the power grid is the first task of controlling the power quality [4-6]. In the distribution network state estimation problem, the essence is to utilize the relevant computer technology and mathematical processing algorithms to fit the parameters, predict, and correct the errors of the measurement data with redundancy and correlation, in order to improve the integrity and reliability of the processed data, so as to obtain accurate real-time information about the state of the distribution network [7-9].
In distribution networks, there are three situations, namely, line asymmetry and load imbalance of distributed power access [10]. These three situations can disrupt the three-phase distribution network trend equalization, so state assessment of the distribution network is needed to solve the three-phase unbalanced situation [11-12]. The state assessment of distribution networks usually requires huge computational volume and high requirements on computational hardware equipment [13]. At present, the research results of scholars at home and abroad on the state assessment problem of distribution networks mainly include artificial intelligence assessment method, least squares assessment method, semidefinite planning assessment method and interior point method. Intelligent optimization algorithm is a kind of biomimetic evolutionary computation method, which usually has better computational efficiency, robustness and diverse relevance, and is an effective solution strategy for state assessment of distribution network system [14-16]. However, in practice, the complexity and variability of the distribution network system structure, and the large number of access devices, can easily lead to the “dimensional disaster” of all kinds of intelligent optimization algorithms [17-18].
To address the highly variable characteristics of time-varying power networks, this paper proposes unbalanced grid state prediction and optimization strategy methods using grid cross-section data, respectively. Normalization is performed on the initial electrical characteristics of the grid operation cross section, and neighbor nodes are sampled.The information from nodes at each layer is aggregated to obtain the attribute vector of each node at the highest layer, and the output is the spatial characteristics of the operating cross section.Using Euclidean distance and cosine similarity, the similarity of operating sections is compared in both macroscopic and microscopic ways, and the weights are used to rank the similarity of different positions in the window. Based on the relative unbalance degree of current, the relative fluctuation of active two-fold frequency positive cosine, and the relative fluctuation of reactive two-fold frequency positive cosine, the multi-objective function for controlling the balance of power grid is established. Based on the orthogonal iteration method to optimize the genetic algorithm, the grid imbalance state abort optimization strategy is proposed. Finally, simulation experiments and real grid arithmetic example analysis are carried out respectively to verify the effectiveness of the prediction method in this paper.
Currently, grid operators use short-term operational state prediction. However, as a time-varying network, critical changes may occur in the power system within 5 or 15 minutes, and the traditional method cannot achieve timely identification.
Grid operation for many years has stored a huge amount of operational section data, if we can effectively mine the historical section information similar to the current and future sections, not only can assist in predicting the future state of grid operation, but also can refer to the corresponding historical work ticket information, assisting the operation and scheduling personnel to analyze the weak links, fault plans, etc..
The process of operation state prediction is as follows: firstly, feature extraction is performed on the operation sections, and then the similarity between the current operation section features and the historical operation section features is calculated to filter the historical operation sections that are most similar to the current operation sections. Finally, the subsequent moments of similar historical running sections are used as a reference for the future state of the current running.
The existing cross-section feature extraction methods are not able to characterize the operating cross-section well, which leads to a low reference value in the subsequent matching results. In order to improve the representativeness of the operating cross-section features and the effectiveness of the matching results, firstly, according to the grid operation information obtained from PSD-BPA, MATPOWER and other trend calculation software, we define six attribute quantities as the initial electrical characteristics of each node, namely, voltage magnitude, phase angle, power generation, power generation reactive, load active, load reactive, and express them as a 6-dimensional column vector, e.g., the initial characteristics of node
where
The Z-score normalization method is utilized to
The standard deviation
The normalized value
The standard deviation 2 of attribute 1 across all nodes is:
The grid operation section data after normalization of all node attribute vectors is shown in the following equation:
In order to further enhance the representativeness of the spatial features of the extracted run sections, this paper adds the network topology attribute information using the Graph SAGE algorithm on the basis of Eq. (5). The GraphSAGE algorithm is a method for analyzing topological attribute information in the context of network connectivity, which generates new node representation vectors by aggregating information about the nodes themselves and their surrounding neighboring nodes, enabling the accounting of attributes of each node while preserving topological information [19].
The sampling process of neighbor nodes is introduced by taking the operation section of the local area of the system at a certain moment as an example. Set any node as the target node
Considering that section similarity matching is the comparison of attribute values of corresponding nodes in each dimension between sections, in order to improve the matching accuracy, and taking into account the matching efficiency, in the process of aggregating neighboring nodes’ information, except for the nodes’ features of the node in the 0th sampling layer as a column vector of 6 dimensions in Eq. (5), in this paper, the nodes’ features of the other layers are kept in 128 dimensions through the weighting matrix. The process of aggregating the features of each node in layer
Let
The obtained mean vector
where
The nonlinear transformation of
Where
The node information is aggregated layer by layer to get the attribute vectors of each node in the highest layer
The spatial characteristics of operational sections are composed of 128×
Macro-similarity is represented by the reciprocal of the Euclidean distance, and micro-similarity is represented by the cosine value. Let the extracted features of two sections be
where
The consecutive sections within the window where the current running section is located are matched one-to-one with the consecutive sections within the historical window, and the similarity is calculated and then summed. Due to the temporal characteristics of the running section, the sample similarity of different positions within the window has a differential effect on the combined similarity between windows, i.e., the closer the position of the section within the window is to the tail end, the more important the calculation results are. Therefore, in the paper, the similarity values of different positions within the window are given weights, such as the macro-similarity and micro-similarity between the section within the
Where,
The macroscopic comprehensive similarity ranking and microscopic comprehensive similarity ranking of the windows are averaged, and the historical windows with the first total similarity ranking with the current window are screened, taking the calculation process of the total similarity ranking of window
Where
When the control objective is to suppress the twofold frequency fluctuation of instantaneous active power, a large negative sequence current is generated, making the output current unbalanced in three phases. When the three-phase balance of output current is the control objective, due to the negative sequence voltage and positive sequence current, it will lead to the existence of two-fold grid frequency fluctuation of instantaneous active power and reactive power. So there is a contradiction between these three control objectives, and the improvement of one control objective may lead to the performance degradation of another control objective. Based on this, this paper proposes a control strategy that can be coordinated among these three objectives according to the grid imbalance, and optimizes the output power quality by minimizing the multi-objective optimization function to take into account the three control objectives.
The calculation of the positive and negative sequence reference current values for the three objectives is unified by adding the optimization adjustment factor
Optimization factor
The positive cosine peak expressions of active and reactive power two-fold fluctuations are Eqs. (14) and (15):
As can be seen from Eq.
Further,
The multi-objective function is defined as:
Further, according to the actual situation can be assigned weights to the three objectives, adding the weight assignment coefficients are
For a
The optimization process of Genetic Algorithm (GA) is basically a trial-and-error method with the nature of stochastic search, and it has been pointed out that the iterative operation process of GA can be regarded as a set of experimental design for optimizing the sample points. For example, the crossover operation can be thought of as a sampling experiment, where some genes are extracted from individuals of the parent generation and combined to produce individuals of the offspring. As a result, introducing the orthogonal iterative design idea into the iterative process of GA can effectively improve the optimization-seeking efficiency of GA [21].
Orthogonal sequences filter the combination of levels from the solution space, with the characteristics of “uniformly dispersed and neatly comparable”. Specifically, for an optimization problem with 1) For each factor in any column, the number of occurrences of each level 2) For any two columns in the orthogonal sequence, the number of occurrences of any two-factor combination of levels is 3) For the task two columns in the orthogonal sequence, it is necessary to contain a full permutation of the two factor combination levels: (1.1), (1.2),…, (1,Q), (2.1), (2.2),…, (2,Q),…, (Q,1), (Q,2),…, (Q,Q). 4) Swap the positions of any two columns of the orthogonal sequence and the new sequence remains orthogonal. 5) Delete some columns in the orthogonal sequence, the new sequence is still an orthogonal sequence with some factors missing.
When the number of levels and the number of factors are certain, various types of orthogonal sequences that satisfy the above conditions can be found in existing studies, and orthogonal experimental design can be carried out by checking the table. However, considering its application to recovery path optimization, the orthogonal sequences under different systems are different, and it is troublesome and less versatile if all the orthogonal sequences queried are stored in advance for calling.
So in this paper, a special class of orthogonal tables is constructed to automatically generate orthogonal sequences, and the number of level combinations of orthogonal table
The generated orthogonal table is a
The number of factors and levels required for the calculation are entered and the orthogonal table is constructed. The method improves the efficiency of searching the solution space by reducing the number of combinations traversed, and thus improving the efficiency of searching the solution space.
The solution space is partitioned by dividing a set of codes representing the commissioning state of the entire network into
Specifically, two sets of initial codes
Applying the orthogonal experimental design to crossover operations to guide the generation of individuals during the iteration process of the genetic algorithm helps to increase the diversity of the newborn population and improve the efficiency of the solution space search.
Applying the orthogonal table
The above method is applied to solve the grid balance optimization problem as a way to improve the search efficiency of the intelligent optimization algorithm traversing the solution space. The specific steps of the orthogonal genetic algorithm for grid imbalance suspension are as follows:
Step 1: Generate a candidate initial population. Generate
Step 2: Initial population screening. When the number of individuals in the candidate initial population generated is larger than the initial population size
Whether a one-bit code undergoes mutation.
Step 3: Selection of parent individuals. From the
Step 4: Generation of candidate offspring individuals. According to the orthogonal crossover step, orthogonal operations are performed on the
Step 5: Candidate offspring individual mutation operation. The probability value
Step 6: Screening of candidate offspring individuals. Similar to the initial population screening in Step 2, the
Step 7: Generate the offspring population. Since the number of individuals generated by a single orthogonal crossover operation is
Step 8: optimization termination condition judgment. In order to simplify the analysis, this paper according to the iteration number of the genetic algorithm as a judgment condition for the termination of the algorithm, when the number of iterations does not reach the maximum number of iterations, then return to step 3, when the maximum number of iterations is reached, then go to step 8, ending the algorithm of the search for excellence process.
Step 9: Select the recovery path. Each individual generated in the above steps, the encoded 0-1 state corresponds to the state of the whole network transmission lines in operation, and all the transmission lines with a state of “1” constitute the restoration path of the power outage system. In order to speed up the computational speed of the iterative process, this paper checks the security constraints on the restoration path scheme corresponding to the population at the end of the iteration, and selects the final restoration path from it.
A 10Kv-A VSG grid-connected inverter system simulation model is constructed under the MATLAB/Simulink simulation environment for the simulation of multi-objective optimization of balancing of the grid equilibrium state. The parameters for system simulation are shown in Table 1.
The parameters of the simulation system
| Parameter | Value | Parameter | Value |
|---|---|---|---|
| Udc/V | 500 | C/μF | 60 |
| LS/mH | 15 | S*/(Kv·A) | 15 |
| Rs/Ω | 0.2 | f/Hz | 60 |
| Lg/mH | 3 |
When selecting the weighting coefficients in the optimization function, priority should be given to meet the current quality requirements injected by the VSG grid-connected inverter. So the weighting coefficients of current should be larger than those of active and reactive power. In addition, since the VSG grid-connected inverter provides active power and a certain amount of reactive power to the grid, the weight coefficient of active is slightly higher than that of reactive. Finally, the weighting coefficients ξI, ξP, and ξQ are selected as 0.6, 0.3, and 0.1, which correspond to the current control objective, the active fluctuation suppression control objective, and the reactive power fluctuation suppression control objective, respectively.
Fig. 1 shows the simulation results of the control using the traditional method λ=1 when the grid A-phase voltage falls 0.5 p.u. at 0.1s and the grid unbalance is 0.3. (a)~(c) are the grid voltage, VSG output grid-connected current and VSG output active and reactive power, respectively.

The grid current and work and reactive power of the equilibrium current control
From Fig. 1, it can be observed that the grid A-phase voltage drops by 0.5 p.u. at 0.1 s, the output current is unbalanced, and after 0.02 s, the output current is basically balanced. There are obvious fluctuations in active and reactive power, and the fluctuation of reactive power is larger, the specific values are 821 W and 1082 var. This verifies that under the unbalanced grid voltage, the traditional control method can realize the balance of three-phase output current, but there are large fluctuations in active and reactive power, and the effect of grid-connected controller is not ideal. Therefore, it is necessary to coordinate and optimize the output current, active, and reactive power fluctuations.
Fig. 2 shows the simulation results of introducing orthogonal iterative genetic multi-objective optimization control when the grid voltage phase A drops 0.5 p.u. and 0.3 p.u. in 0.1s and 0.2s, respectively, and (a)~(c) are the grid voltage, grid-connected current of this paper’s algorithm, and the active and reactive power of this paper’s algorithm, respectively. As can be seen from the figure, 0.1~0.2s voltage phase A falls 0.5p.u., single-phase imbalance occurs in the grid, multi-objective optimization control works, a small amount of imbalance occurs in the output current, and the active and reactive power fluctuations both fall compared to the unoptimized, and the fluctuations are 618w and 1038var, respectively.
From the comparison of Fig. 1 and Fig. 2, it can be seen that the active power fluctuation after optimization decreases by 203w, and reactive power fluctuation decreases by 44var.0.2~0.3s voltage phase A drops by 0.3p.u., single-phase imbalance occurs in the grid, and the fluctuation of active and reactive power is 284w and 343var, respectively, and a small amount of imbalance occurs in the output of the three-phase currents. The current, active, and reactive power of the system showed a significant coordinated improvement over the conventional control.

The grid current and work and reactive power of our method
Table 2 Comparison of simulation results of this paper’s algorithm with balancing current control. It can be seen that there is no difference between the two grid balancing methods within 0~0.1 seconds. However, within 0.1~0.2 seconds, the active and reactive power fluctuations of this paper’s algorithm are 611W and 1002war, respectively, and the achieved grid balance is better than the balanced current control method.
The comparison of the control of the balance of the grid
| Time/s | Current inequality | Active fluctuation/W | Reactive fluctuation/war | |||
|---|---|---|---|---|---|---|
| Balance current control | Ours | Balance current control | Ours | Balance current control | Ours | |
| 0~0.1 | 0.02 | 0.02 | 50 | 50 | 70 | 70 |
| 0.1~0.2 | 0.08 | 0.08 | 838 | 611 | 1083 | 1002 |
In this paper, the actual data of the power grid in a region is used to construct an arithmetic example to validate the algorithm presented in this paper. Taking 15:00 on August 30, 2017 in the region as the planning section, the bus injection and outflow power in the state forecast result at that moment is regarded as the generation plan and load forecast data at that moment. The calculation scale is 105 500kV buses, 259 AC lines, 228 transformers, 35 generators, and 85 reactive power compensation.
The state prediction results of the cross sections at 24 points of the week before the cross section to be calibrated are used as historical tide data for similar cross section matching. The grid operation section estimation algorithm in this paper is validated by matching single moment sections and similar day multi-moment sections, respectively.The similar cross section for single-moment cross section matching is the 11 o’clock cross section on August 28th, and the similar cross section for similar-day cross section matching is the 15 o’clock cross section on August 30th. The similarity indexes of the cross section in the week before the planned cross section and the cross section to be calibrated are shown in Fig. 3, and the convergence of the state prediction calculation is shown in Fig. 4.

The similarity of history and the verification of the nuclear section

The convergence of state prediction calculation
Pass rate for all bus and line currents is checked. For the injected and outgoing power of buses for a given plan data with higher accuracy requirements, an absolute deviation of less than 10 MW (/Mvar) or a relative error of less than 5% is considered satisfactory. If the line power has an absolute deviation of less than 15 MW(/Mvar) or a relative error of less than 10%, it is acceptable. Voltage deviation of less than 0.05p.u. Is qualified. The initial prediction results of the grid balance state corresponding to single-section matching and multiple-section matching are shown in Table 3.
Initial forecast results
| Project | Bus qualification (%) | Line qualification (%) | Voltage qualification (%) |
|---|---|---|---|
| Single cross matching | 88.98 | 72.33 | 87.59 |
| Similar day matching | 96.21 | 85.05 | 99.38 |
The bus current pass rate is larger than the line current pass rate due to the large weight assigned to the bus power corresponding measurements to ensure that the planned state prediction results satisfy the planned data as much as possible. Compared with the grid state prediction methods based on the current algorithm, the prediction results of this paper’s algorithm have a higher bus pass rate but a slightly lower line pass rate, probably because the algorithm proposed in this paper sacrifices a part of the accuracy with the advantage of the convergence performance and the selection of the kernel width of the kernel function still needs to be optimized.
The algorithm based on tidal current estimation is easier to converge than the state prediction method due to its measurement redundancy, but the accuracy of the calculation is slightly reduced due to a certain deviation between the tidal current of the similar section and the real tidal current of the section to be calibrated. In terms of computational efficiency, the grid state prediction method based on tidal current algorithm needs to carry out state prediction several times, while the grid state prediction algorithm based on orthogonal iteration only needs to carry out state prediction once in the initial computation, so the computational efficiency is greatly improved.
Comparing the two similar section matching methods, the calculation result of similar day matching has a higher passing rate. Although the similar sections matched on similar days are less similar to the sections to be calibrated compared with the similar sections matched on single sections, the similarity is likely to be greatly reduced by the large differences between the individual historical current data and the planned data, and the similarity is significantly higher than that of the sections matched on single sections after removing the large differences between the individual historical current data. After computing the resistance estimates, the accuracy of the computation is higher when using similar day-matched sections.
Based on the state prediction results of each historical section in the week before the section to be calibrated, the application of the grid balance restoration algorithm based on orthogonal iteration is verified.
The initial calculated values of the planned currents of 190 cross sections in the week before the time of the cross section to be calibrated are used as the input data of the training set, and the real currents of the cross sections corresponding to the next time of the cross section are used as the output data of the training set. The initial calculated value of the planned tidal current at 11:00 on the 28th is inputted into the network that has completed the training to obtain the reallocated tidal current, i.e., the imbalance power allocation result of the section to be calibrated.
The curves of the difference between the reallocated tidal currents and the initial calculated value of the planned tidal currents for the 603 measurements are shown in Fig. 5. Fig. 5(a) shows the curves in the order of the actual calculated measurements, and Fig. 5(b) shows the curves in the order of the magnitude of the imbalance power adjustment value.

The difference of the initial calculation of redistributed trend and planning trend
Using the line power data in the re-allocated currents as a substitute, correcting the similar section currents measured as the state prediction calculation volume, the state prediction calculations were performed again, and the pass rates of the calculations are shown in Table 4.
The results of the prediction of the operation section of the grid
| Project | Bus qualification (%) | Line qualification (%) | Voltage qualification (%) |
|---|---|---|---|
| Reforecast | 99.31 | 89.81 | 98.66 |
After the state prediction calculation is performed again, the bus pass rate and line pass rate are both improved. The reason is that the re-allocated currents obtained based on orthogonal iteration are closer to the real currents of the section to be calibrated than the similar section, and the optimization process of the extreme orthogonal genetic algorithm is the process of finding the allocation law of the unbalanced power borne by each unit and load in the actual network.
In this study, machine learning algorithms were developed using grid operation cross-section feature data to predict the imbalance state of the grid. Subsequently, a grid balancing strategy is designed using an orthogonal iterative approach. The fluctuations of active and reactive power are 821 W and 1082 var, respectively, using the traditional method for grid state control, while the optimization method in this paper achieves a decrease in fluctuations of 203 W and 44 var, respectively, which mitigates the unbalanced state of the grid. Compared to the balanced current control method, this paper’s algorithm also shows better performance in grid balance control within 0.1-0.2 seconds.After optimization based on machine learning, this paper’s algorithm achieves higher than 85% accuracy in both prediction calculations and similar day matching calculations.In this study, an effective unbalanced grid state prediction and an orthogonal iteration abort strategy are realized using machine learning and orthogonal iteration methods.
