Reconﬁguration Strategy for DC Distribution Network Fault Recovery Based on Hybrid Particle Swarm Optimization

: DC distribution network faults seriously affect the reliability of system power supply. Therefore, this paper proposes a fault recovery reconﬁguration strategy for DC distribution networks, based on hybrid particle swarm optimization. The original particle swarm algorithm is improved by simplifying the distribution network structure, introducing L é vy Flight, and designing an adaptive coding strategy. First, the distribution network structure is equivalently simpliﬁed to reduce the problem dimensionality. Further, the generated branch groups are ensured to satisfy the radial constraints based on the adaptive solution strategy. Subsequently, L é vy ﬂight is introduced to achieve intra-group optimality search for each branch group. The method is simulated in several distribution systems and analyzed in comparison with the particle swarm algorithm, genetic algorithm


Introduction
With the increasing demand for electricity, the size and complexity of modern distribution networks have increased significantly [1].In practice, most power outages are due to damage caused by distribution network failures, which can have serious consequences for both utilities and customers [2].At the same time, medium-voltage direct current (MVDC) distribution networks are becoming increasingly important in view of the large-scale application of DC technology [3][4][5].Compared with the traditional AC distribution network, the flexible DC distribution network based on voltage source converter (VSC) technology has the advantages of easy access to distributed energy and multiple loads, and flexible control [6].Therefore, to improve power supply reliability and customer satisfaction, it is necessary to study the fault recovery reconfiguration of the DC distribution network.
Reconfiguration of the distribution network aims to find the optimal combination of all switches in the distribution, and achieve objects as follows: (1) maximizing demand, (2) minimizing the number of switching operations, (3) giving priority to automatic switching operations over manual operations, and (4) giving priority to special loads [7].Distribution network reconfiguration (DNR) is essentially a multi-objective nonlinear hybrid optimization problem, which is mathematically an NP-hard problem [8].
There are several common reconfiguration methods, including heuristic algorithms, artificial intelligence (AI), and mathematical modeling.Heuristic algorithm is an intuitive analysis algorithm.It iterates step-by-step, according to certain principles, to obtain satisfactory results, and mainly includes branch-and-swap and optimal flow methods.In [9], the branch switching pair that caused the most network loss reduction is selected for branch Energies 2021, 14, 7145 2 of 15 switching in a simple way.In [10], all switches are closed, and the switches with the least optimal flow are subsequently opened sequentially until the reconfiguration solution is obtained.In addition, inspired by the fractal theory for solving optimization problems, implementation of a stochastic fractal search (SFS) algorithm is proposed to solve the distribution network reconstruction problem [11].Although the method of [11] is an improvement on [9,10], it still cannot guarantee that the solution is the global optimal solution.In addition, ref [12] applies a heuristic algorithm based on Harris Hawks optimization to DNR, which can ensure global convergence performance.Ref [13] uses the discrete network reconfiguration of the data set method, which can significantly improve the effectiveness of the distribution network.This type of method has good convergence performance, and can obtain a global optimal solution for single-objective optimization problems.
AI algorithms for solving reconstruction problems are mainly based on swarm optimization methods.In [14], a genetic algorithm (GA) based on a standard benchmark problem is used to solve single-objective optimization problems.PSO has the advantages of simple principle, robustness, and easy implementation [15].A binary particle swarm algorithm (BPSO) is proposed in [16] to solve the DNR problem.A new optimization algorithm called the Salp swarm algorithm can effectively solve the optimization problem.The beetle antennae search (BAS) algorithm is an intelligent optimization algorithm, which has the advantages of a simple principle, fewer parameters, and less calculation required [17].The cuckoo algorithm (CA) can effectively solve the optimization problem of reconstruction by simulating the parasitic brooding of some species of cuckoo, and using the related Lévy flight search mechanism [18,19].The above methods have been successfully applied to the field of DNR with better results than heuristic algorithms.However, a common problem is that they tend to fall into premature maturity and still cannot guarantee global optimality.
In addition, the reconfiguration problem can also be solved using mathematical modeling.In [20], a mixed-integer linear programming (MILP) model was developed to solve the distribution network fault recovery-reconstruction problem.Based on MILP, a mixed-integer second-order cone programming formulation for service restoration in distributed generation distribution networks was proposed, which relaxes the original non-convex tidal equation to quadratic form [21].Meanwhile, the problem of uncertainty for renewable energy or load can be solved in the mathematical model by stochastic optimization [22] or robust optimization [23] to obtain the theoretically optimal solution.Mathematical modeling can be proved by formulas, but solving non-convex problems takes too long to solve.Therefore, linearized mathematical models and convex transformation of the original non-convex problems are further difficulties to be overcome for this kind of problem.
AI is a stochastic class of algorithms, and this class of methods has been successfully applied to solve DNR.Since traversing the feasible solution space takes a lot of computational time, the efficiency of the algorithm becomes crucial.The key to improving the efficiency of the algorithm lies in the encoding method, and the corresponding evolutionary approach.In traditional distribution networks, most distribution systems are designed as weak meshes, but usually operate in a radial topology to efficiently coordinate their protection systems [24,25].In [26], a loop-based coding method was proposed to disconnect a branch in an independent loop to satisfy radial constraints, and increase the proportion of feasible solutions.The resulting solutions are all feasible, but the repetition rate is too high, reducing evolutionary efficiency.In [27], a new graph theory-based method is proposed for restoring the distribution system after multiple simultaneous faults due to extreme weather conditions.All of the above different encoding methods and evolutionary strategies improve the encoding efficiency to a certain extent, but still need to carry out the feasibility testing process of the solution, and the computation time is still long.
In summary, the reconstruction method based on the stochastic algorithm can solve the optimal solution more efficiently when solving large-scale distribution network problems.However, the stochastic algorithm generates many invalid solutions, and needs to judge whether the generated solutions are valid, which reduces the evolutionary efficiency.Mean-Energies 2021, 14, 7145 3 of 15 while, the stochastic algorithm falls into local optimum easily.Therefore, a reconfiguration strategy based on HPSO is proposed.The main contributions of this paper are summarized as follows: (1) Considering the topological characteristics of DC distribution, the network structure is equivalently simplified to improve the search efficiency in the DNR process; (2) An adaptive coding strategy is designed to make the generated solutions satisfy the topological constraints.This strategy can improve the evolution efficiency of particles in the particle search process without judging infeasible solutions; (3) To avoid the algorithm from falling into premature, the idea of Lévy flight (LF) is introduced to improve the global search ability and convergence speed of the particles.
The paper is organized as follows.The mathematical modeling of DNR is in Section 2. In Section 3, the simplification and coding method of the distribution network is proposed.In Section 4, an HPSO combining adaptive coding strategy and improved discrete particle swarm optimization (DPSO) is proposed.In Section 5, the proposed algorithm is compared with other algorithms such as GA, PSO, and CA to verify the efficiency and accuracy of HPSO.Section 6 summarizes the paper.

Mathematical Model of Converters
Before calculating the tidal distribution of DC distribution network, it is necessary to establish an equivalent circuit for the converters commonly found in DC distribution networks, and obtain the mathematical model of a DC distribution network.The voltage source converter (VSC) has obvious advantages in tidal current reversal and control, compared with the current source converter (CSC).In Figure 1, R c + jX c is the equivalent impedance of the converter, R c is the equivalent resistance of the transformer and the converter reactor (Ω), X c is the equivalent reactance of the converter (Ω), P s and Q s represent the active (W) and reactive power (Var) of the AC bus, P c and Q c represent the active (W) and reactive power (Var) of the AC side, U s and δ s represent the line voltage amplitude (V) and phase angle (rad) of the AC bus, U c and δ c represent the line voltage amplitude (V) and phase angle (rad) of the AC side, and P dc and Q dc are the active power (W) and reactive power (Var) of the DC side for the converter, respectively.certain extent, but still need to carry out the feasibility testing process of the solution, and the computation time is still long.
In summary, the reconstruction method based on the stochastic algorithm can solve the optimal solution more efficiently when solving large-scale distribution network problems.However, the stochastic algorithm generates many invalid solutions, and needs to judge whether the generated solutions are valid, which reduces the evolutionary efficiency.Meanwhile, the stochastic algorithm falls into local optimum easily.Therefore, a reconfiguration strategy based on HPSO is proposed.The main contributions of this paper are summarized as follows: (1) Considering the topological characteristics of DC distribution, the network structure is equivalently simplified to improve the search efficiency in the DNR process; (2) An adaptive coding strategy is designed to make the generated solutions satisfy the topological constraints.This strategy can improve the evolution efficiency of particles in the particle search process without judging infeasible solutions; (3) To avoid the algorithm from falling into premature, the idea of Lévy flight (LF) is introduced to improve the global search ability and convergence speed of the particles.
The paper is organized as follows.The mathematical modeling of DNR is in Section 2. In Section 3, the simplification and coding method of the distribution network is proposed.In Section 4, an HPSO combining adaptive coding strategy and improved discrete particle swarm optimization (DPSO) is proposed.In Section 5, the proposed algorithm is compared with other algorithms such as GA, PSO, and CA to verify the efficiency and accuracy of HPSO.Section 6 summarizes the paper.

Mathematical Model of Converters
Before calculating the tidal distribution of DC distribution network, it is necessary to establish an equivalent circuit for the converters commonly found in DC distribution networks, and obtain the mathematical model of a DC distribution network.The voltage source converter (VSC) has obvious advantages in tidal current reversal and control, compared with the current source converter (CSC).In Figure 1, Rc + jXc is the equivalent impedance of the converter, Rc is the equivalent resistance of the transformer and the converter reactor (Ω), Xc is the equivalent reactance of the converter (Ω), Ps and Qs represent the active (W) and reactive power (Var) of the AC bus, Pc and Qc represent the active (W) and reactive power (Var) of the AC side, Us and δs represent the line voltage amplitude (V) and phase angle (rad) of the AC bus, Uc and δc represent the line voltage amplitude (V) and phase angle (rad) of the AC side, and Pdc and Qdc are the active power (W) and reactive power (Var) of the DC side for the converter, respectively.The active power and reactive power on the AC side satisfy the following relationship: The active power and reactive power on the AC side satisfy the following relationship: Equation ( 2) can be approximated to derive the internal losses of the converter P loss VSC , where A, B, and C are the coefficients of the fitted quadratic functions for converter current and active losses, respectively.
Energies 2021, 14, 7145 where S N and V d N denote the rated capacity (VA) of the converter and the rated voltage (V) of the DC side; and S B and V d B denote the reference capacity (VA) of the system and the reference voltage (V) of the DC network.
In Figure 1, the power relationship between the DC side of the converter and the AC side is shown in the following equation:

The Calculation of Power Flow in Medium Voltage DC Distribution Network
The DC distribution network does not have reactive power and voltage phase angle, and each node contains only two variables: power, and voltage.Therefore, only the value of one of the two variables is needed to solve the power flow.The Newton-Raphson method is the basic algorithm for solving the power flow.To solve the power flow, it is only necessary to obtain the voltage values of each node in the network.The nodal conductance matrix G needs to be established first in the tide calculation.Since the DC system is a purely resistive line and does not contain reactance, the conductance matrix is composed entirely of conductance, and the nodal current matrix I and the nodal voltage matrix U are related as follows: The amount of active power and power imbalance injected at node i on the DC side is shown as follows: where I i is the node i injection current (A); U i is the node i voltage (V); G ij is the conductance value (S) between node i and node j; and P is denotes the fixed P node injection power (W).
The following equation is the formula for solving each element of the Jacobi matrix: The voltage adjustment value is obtained by using the Jacobi matrix, and the power flow of the distribution network can be obtained by iteratively correcting the voltage value.

Mathematical Model for Recovery Reconfiguration
DNR is a process of changing the switching state so that as much load as possible is transferred from the non-faulty zone to the normal feeder.DNR is not only a mixed-integer nonlinear optimization problem, but also a high-dimensional discrete non-convex optimization problem, making the optimization problem an NP-hard problem.The conventional solver takes too long to solve, and even the final solution cannot be obtained.Therefore, AI algorithms can be used to solve the problem.The main consideration is system economy, and the objective is to minimize network loss after reconfiguration.
The constraints that should be satisfied for fault recovery reconfiguration mainly include the tidal current constraint of the distribution network, the upper and lower voltage constraints of the nodes, the upper and lower branch current constraints, and the topological constraints of the distribution network structure: where N b denotes the number of distribution network branches after reconfiguration; k j denotes the operation status of the first branch; 1 indicates normal operation and 0 indicates withdrawal; I j is the current of the corresponding branch (A); r j is the impedance of the corresponding branch (Ω); A is the node-branch correlation matrix; i is the current vector of all branches; I is the current injection vector of all nodes; U i is the actual voltage of node i; U i,max and U i,min denote the allowed upper (V) and lower voltage (V) of node i; I i is the actual current (A) flowing through the branch; I i,max is the maximum current (A); and g is the current network structure.The decision variable is the branch switch number of the power distribution system, which is an integer decision variable.The number of tie switches in the distribution system is equal to the number of decision variables.If the IEEE33 node is used as an example, there are five decision variables for DNR.Among the constraints, active power balance constraints and reactive power balance constraints are equality constraints, and node voltage constraints and branch current constraints are inequality constraints.

Simplification of Power Distribution Networks
A characteristic of smart algorithm solutions is randomness, which allows the algorithm to traverse the entire solution space, but it also encounters situations where the generated solutions are infeasible.Due to the existence of radial constraints in the distribution network, the algorithm may generate infeasible solutions during all iterations, and the decoded distribution network structure does not satisfy the radial constraints.The existence of infeasible solutions seriously reduces the search efficiency of distribution network reconstruction, so the generation of infeasible solutions should be avoided as much as possible during the iteration of the algorithm.Considering the large number of variables in the actual distribution network, the distribution network structure should also be simplified equivalently.
As shown in Figure 2, the following equivalent simplifications are made to the distribution network before fault recovery reconfiguration: (1) Some branches that already exist in radial branches need to be ignored.For example, the branch between node 1 and node 2, which is involved in splitting, will form an island that does not satisfy the radial constraint.Therefore, the first step should be to eliminate the branches that are not related to the ring network first; (2) Branches that have the same effect need to be disconnected.For example, disconnecting any two branches between node 3 and node 6 will have the same effect for disconnected loops, although the tide of the system will change accordingly.Therefore, in the second step, the concept of degree in graph theory is introduced to eliminate the nodes with 2 • .The remaining equivalent branches are merged to form a set of branches with the two end nodes as branches.
As can be seen in the final simplified diagram generated in Figure 2, with all tieswitches closed, the original IEEE33 distribution system is reduced to an equivalent diagram containing 12 branched groups of 5 loops (L1-L5).As can be seen in the final simplified diagram generated in Figure 2, with a switches closed, the original IEEE33 distribution system is reduced to an equiv diagram containing 12 branched groups of 5 loops (L1-L5).

Coding Method
How the search space is defined is the key to determine the efficiency of the algor For the simplified topology diagram generated at the end of Figure 2, a decision varia used to represent a branch group, and the number of branch groups is the dimensional the particles.If the value is 0, it means that all the branches contained in the correspon branch group are in the on state, and the number of removed branches is 0. If the valu positive integer, the integer indicates the numbered branch corresponding to the rem branch.Therefore, the branch group generation process requires numbering of each br The upper value of each dimension is the number of branches in each branch group, an lower limit is 0. In this coding method, the maximum number of branches broken in branch group is guaranteed to be 1, which reduces the generation of infeasible solution improves the search efficiency.
The branch group matrix is defined with the branch group number as the row nu and the internal branch number of each branch group as the internal element.For the i state of the contact switch in Figure 2, the disconnected switch is numbered [3 3 3 4 3 5 7], and the decision variables of this network are coded [0 0 0 0 0 0 0 0 1 2 4 0 5 1].
After the initialization of the particle swarm is completed, the evolution o particles is divided into two phases.The first stage uses an adaptive solution-based B to ensure that the generated solution satisfies the topological constraints o distribution network.The second stage uses the improved DPSO to select a disconn switch in each branch group.

Branched Group Selection Optimization Based on Adaptive BPSO
The BPSO sets the individual pid and global pgd of the particle and the position each dimension to 0 or 1, depending only on the magnitude of the particle velocity the velocity is larger, the chance that the corresponding particle dimension xid is 1 w larger.Conversely, if the velocity is smaller, the chance that the current particle dimen xid is 0 will be larger.The update formula for the position update expression si function of the BPSO algorithm is shown below: Step 2: Merge the equivalent branches to form a branch group, that is, delete the node with degree 2

Final simplified diagram
Step 3: Further simplification Step 1, Delete branches and nodes that are not related to the ring network, such as nodes 1

Coding Method
How the search space is defined is the key to determine the efficiency of the algorithm.For the simplified topology diagram generated at the end of Figure 2, a decision variable is used to represent a branch group, and the number of branch groups is the dimensionality of the particles.If the value is 0, it means that all the branches contained in the corresponding branch group are in the on state, and the number of removed branches is 0. If the value is a positive integer, the integer indicates the numbered branch corresponding to the removed branch.Therefore, the branch group generation process requires numbering of each branch.The upper value of each dimension is the number of branches in each branch group, and the lower limit is 0. In this coding method, the maximum number of branches broken in each branch group is guaranteed to be 1, which reduces the generation of infeasible solutions and improves the search efficiency.
The branch group matrix is defined with the branch group number as the row number and the internal branch number of each branch group as the internal element.For the initial state of the contact switch in Figure 2, the disconnected switch is numbered [3 3 3 4 3 5 3 6 3 7], and the decision variables of this network are coded [0 0 0 0 0 0 0 0 1 2 4 0 5 1].
After the initialization of the particle swarm is completed, the evolution of the particles is divided into two phases.The first stage uses an adaptive solution-based BPSO to ensure that the generated solution satisfies the topological constraints of the distribution network.The second stage uses the improved DPSO to select a disconnected switch in each branch group.

HPSO Algorithm 4.1. Branched Group Selection Optimization Based on Adaptive BPSO
The BPSO sets the individual p id and global p gd of the particle and the position v id of each dimension to 0 or 1, depending only on the magnitude of the particle velocity v id .If the velocity is larger, the chance that the corresponding particle dimension x id is 1 will be larger.Conversely, if the velocity is smaller, the chance that the current particle dimension x id is 0 will be larger.The update formula for the position update expression sigmod function of the BPSO algorithm is shown below: where r is the random value on the interval [0, 1], ω is the inertia weight, c 1 and c 2 denote the two acceleration factors, v t+1 id denotes the velocity of particle i in the d-th dimension of the second iteration, and x t+1 id denotes the position of particle i in the d-th dimension of the second iteration.The necessary condition for DNR is that the number of disconnected tributary switches must be the number of tie-switches, since it cannot be arbitrarily set to 0 or 1 in each dimension by the binary algorithm, and needs to be limited.According to the number of loops in the distribution network, disconnecting a tributary group number in each loop in turn can satisfy the necessary condition for DNR, but it is still not a sufficient condition.Here, according to the distribution network loops, a strategy to improve BPSO is proposed for adaptive solving to ensure that the generated solutions are all feasible solutions.Algorithm 1 shows the adaptive coding algorithm.By choosing the disconnected branching group numbers sequentially through the loop number, the dimensionality of the decision variables can be guaranteed to be constant.The adaptive solution strategy for distribution network loops with branching degree can obtain feasible solutions that satisfy the radial constraint of DNR.For the DNR model, the stochastic algorithm can traverse the whole solution space.Based on the adaptive solution strategy, the solutions generated in are feasible solutions.

LF-Based Improved DPSO for Intra-Group Optimization
After determining the group of branches to be operated, an internal search for the best solution is required, at which point a feasible solution is generated using the encoding method.Since the decision variable at this point is an integer, it is necessary to use an algorithm that can handle decision variables of integer type.We define a random rounding method r and (N): with an integer N, if N ≥ 0, then a random integer value is selected from the interval [0, N]; if N ≤ 0, then a random integer value is selected from the interval [N, 0].We can obtain the speed and position iteration formula of the DPSO as: x t+1 id = x t id + v t id (13) Energies 2021, 14, 7145 LF is a random wandering strategy obeying the Lévy distribution, and the position iterative update equations are: where ⊕ is the point-to-point multiplication, α denotes the step control quantity, and Levy(λ) is the random search path.In order to simplify the distribution function, the probability density function can be obtained by Fourier transform The Mantegna algorithm, where the step size s can be calculated using two variables U and V that obey a Gaussian distribution: ) where U ∼ N(0, σ 2 ) indicates that the sample follows a Gaussian normal distribution with mean 0 and variance σ 2 ; V ∼ N(0, 1) indicates that the sample follows a standard normal distribution.
The improved DPSO combined with LF can broaden the spatial search capability of particles, and increase the diversity of particle search.Using the previously described encoding method to update the particles, the iterative formula of the improved discrete PSO based on LF for intra-group optimization can be obtained as shown below.
where, r(1, 2, If the d-th dimension of particle i is selected for disconnection in step 1, the optimization process within the branch group in step 2 is divided into the following cases. (1) If the particle i being optimized is set to 0, it means that the branch group in this dimension has no previously selected branches.Therefore, the individual and global extremes have no guiding effect on this particle and the velocity of this particle does not change in this dimension and retains the last value, see the first case of (19).However, since this iteration needs to find the internal optimization of the branching group, the position of this dimension should be determined by randomly selecting a branching path, see the first case of ( 20); (2) If the value of the optimized particle is not set to 0, it is further divided into the following cases: 1 If the individual extreme value and global extreme value velocity is 0, it cannot affect the particle velocity in this dimension.There is no guidance for non 0 particles, the velocity does not change, the position from the branch group randomly chooses a path, see the second case of ( 19) and ( 20); If the individual extreme and the global extreme are all non 0, both are guided at this time, and can be updated according to the particle iteration formula after joining the LF, see the third case of ( 19) and ( 20); 3 If one of the individual and one of the global poles is 0 and one is not 0, the poles in the 0 state cannot be guided, and the poles in the non 0 state are guided to the velocity.The corresponding item is changed to a random value from the velocity space, LF is added to enhance the particle search ability, see the fourth and fifth cases of ( 19) and the 3rd case of (20).

Case Study
The structure of the original IEEE 33-node arithmetic example is shown in the original diagram in Figure 2. Since the original example is an AC system, a VSC converter is added between node 1 and node 2, and the reactive load of the node load and the reactance of the branch circuits are ignored to make it a DC distribution network.To prove the effectiveness of the algorithm, we take the same approach for the IEEE 69-node improvement as a test case.In the modified IEEE 33-node, branch 7 is set as a faulty branch; in the modified IEEE 69-node example, branch 14 is set as a faulty branch.Since the current study is a static reconstruction problem, the test is focused on a single time section.
Table 1 shows the parameters of different algorithms.This paper mainly considers the proposed HPSO in comparison with PSO, CA, GA, and BAS.The population size and maximum number of iterations are kept consistent for all algorithms.In addition to the variables that have already appeared, it is necessary to account for the added parameters.In GA, p c , p m , p w , and p n denote the crossover probability, the exchange variation probability, the inverse variation probability, and the addition probability, respectively.The η in BAS denotes the coefficient of variable step size.

Algorithm
Parameter Value

Comparison of Differen Metaheuristic t Algorithms
The metaheuristic algorithm seeks the optimal solution mainly through iterations of pseudo-probabilities, leading to differences in the results of each run.Therefore, each algorithm is set to run 50× to compare the mean value of the optimal solution and running time.In addition, the number of successful convergences to the global optimal solution is used as a comparison metric.
Table 2 shows the comparison results of different algorithms.Among all algorithms, HPSO has the highest number of successful solutions, which results in the smallest mean value of all solutions.The convergence performance of HPSO is faster than other algorithms, because the adaptive solution of HPSO reduces the judgment process of feasible solutions, which further improves the operation efficiency.PSO and BAS have simpler algorithm principles and faster iterations, thus the running time is smaller than the other two algorithms.In addition, the network architecture of 69 nodes is more complex than that of 33 nodes, thus the algorithms take longer to solve 69 nodes and have fewer successful solutions.Figure 3 shows the comparison of evolution curves of different algorithms.Among the results of the runs for the improved IEEE 69-node, the one with the fastest convergence is selected for comparison.In Figure 3, the maximum number of iterations for each algorithm is 50.In the enlarged local plot, HPSO converges to the global optimal solution most quickly after 9 iterations.Although the running time of GA is longer, the optimal solution can be obtained in fewer iterations than other methods, and it only took 12 iterations to converge successfully.Therefore, the fastest number of iterations and running time are a pair of contradictory metrics in the DNR, and HPSO is highly compatible with them.

Comparison of Different Algorithms
HPSO is divided into two main parts: branched group selection optimization based on adaptive solving, and the internal optimization of branched groups based on LF.In order to reflect the advantages of HPSO, the following three algorithms are set up separately for comparison: Improved binary particle swarm optimization (IBPSO):The branch group selection optimization uses the improved BPSO algorithm based on adaptive coding strategy proposed in this paper, and the conventional DPSO is used for the internal optimization of the branch group.
Improved discrete particle swarm optimization (IDPSO): The internal optimization of the branch group adopts the improved DPSO based on LF proposed in this paper, and the optimization of branch group selection uses the conventional BPSO.
HPSO: The branch group selection optimization adopts the improved BPSO based on adaptive solution proposed in this paper, and the internal optimization of the branch group adopts the improved DPSO based on LF.
Table 3 shows the results of different algorithms.On the one hand, IBPSO has the fastest running speed, since LF is not included in the intra-branch group search, which saves computation time.On the other hand, the lack of LF also reduces the diversity of particles, which makes IBPSO the weakest in global search.IDPSO has the same global  Table 3 shows the results of different algorithms.On the one hand, IBPSO has the fastest running speed, since LF is not included in the intra-branch group search, which saves computation time.On the other hand, the lack of LF also reduces the diversity of particles, which makes IBPSO the weakest in global search.IDPSO has the same global search ability asHPSO, which is due to the inclusion of the LF strategy in the intra-branch group search.The particle search space becomes wider, which improves the population's merit-seeking ability.However, the average running time is longer than that ofHPSO.The lack of adaptive solution strategy causes IDPSO to require the inclusion of infeasible solution judgment, which increases the total running time of the intelligent algorithm.HPSO combines the advantages of both.It can not only ensure the global merit-seeking ability of the population by improving DPSO, but also improve the algorithm's operation efficiency by adaptive solution method.In summary, HPSOhas a better global search capability than Algorithm 1, and also can converge faster than IDPSO.The test verifies the effectiveness of the proposed algorithm HPSO. Figure 4 shows the comparison of evolution curves of different algorithms.Three algorithms obtained the global optimal solution.HPSO achieves convergence the fastest and obtains the global optimal solution at the ninth iteration.The convergence performance of IDPSO is basically the same as that of HPSO, but the convergence speed of IBPSO is much smaller than those of IDPSO andHPSO.Therefore, the convergence performance of Algorithm 1 is weaker than those of the other algorithms, which proves the necessity of the intra-branch group optimization search strategy.Figure 4 shows the comparison of evolution curves of different algorithms.Three algorithms obtained the global optimal solution.HPSO achieves convergence the fastest and obtains the global optimal solution at the ninth iteration.The convergence performance of IDPSO is basically the same as that of HPSO, but the convergence speed of IBPSO is much smaller than those of IDPSO andHPSO.Therefore, the convergence performance of Algorithm 1 is weaker than those of the other algorithms, which proves the necessity of the intra-branch group optimization search strategy.

Validity Analysis of Conclusions
Table 4 compares the network losses and minimum voltage of the distribution network at different periods.Figure 5 shows the voltage comparison of each node before and after DNR.To verify the effectiveness of the reconfiguration scheme, a comparative analysis is performed for the distribution network before and after reconfiguration.

Validity Analysis of Conclusions
Table 4 compares the network losses and minimum voltage of the distribution network at different periods.Figure 5 shows the voltage comparison of each node before and after DNR.To verify the effectiveness of the reconfiguration scheme, a comparative analysis is performed for the distribution network before and after reconfiguration.Both the network loss and voltage excursion of the reconfigured system were significantly reduced.In the 33-node case, the network loss value is reduced by 34.4%, and the minimum voltage of the distribution network is increased by 3.1%, which improves the economic performance of the system.In the 66-node case, the network loss value is reduced by 55.8%, the system loss is reduced, and the minimum voltage of the distribution network is increased by 4.0%.In Figure 5, the voltage magnitudes after reconfiguration are all improved, which improves the reliability of the system.The above diagram proves the effectiveness of the HPSO, which can be successfully applied to practical engineering.

Conclusions
In this paper, a two-stage HPSO method for DC distribution networks is proposed.The first stage uses an improved BPSO based on adaptive solution strategy for interbranch group search, and the second stage uses an improved DPSO based on LF idea for intra-branch group optimization.The combination of the two stages can effectively solve the DC distribution network fault recovery reconfiguration problem.The established model has the following advantages: (1) The improved BPSO based on the adaptive solution strategy can remove the judgment process of infeasible solutions and improve the efficiency of population evolution; (2) The improved DPSO based on LF idea can avoid the population from getting into local optimum, and find the global optimal solution faster; (3) The equivalent simplification of the distribution network reduces the problem dimension, and the special coding can further improve the computational efficiency.
Therefore, the method in this paper is more efficient and reliable than the existing Both the network loss and voltage excursion of the reconfigured system were significantly reduced.In the 33-node case, the network loss value is reduced by 34.4%, and the minimum voltage of the distribution network is increased by 3.1%, which improves the economic performance of the system.In the 66-node case, the network loss value is reduced by 55.8%, the system loss is reduced, and the minimum voltage of the distribution network is increased by 4.0%.In Figure 5, the voltage magnitudes after reconfiguration are all improved, which improves the reliability of the system.The above diagram proves the effectiveness of the HPSO, which can be successfully applied to practical engineering.

Conclusions
In this paper, a two-stage HPSO method for DC distribution networks is proposed.The first stage uses an improved BPSO based on adaptive solution strategy for inter-branch group search, and the second stage uses an improved DPSO based on LF idea for intrabranch group optimization.The combination of the two stages can effectively solve the DC distribution network fault recovery reconfiguration problem.The established model has the following advantages: (1) The improved BPSO based on the adaptive solution strategy can remove the judgment process of infeasible solutions and improve the efficiency of population evolution; (2) The improved DPSO based on LF idea can avoid the population from getting into local optimum, and find the global optimal solution faster; (3) The equivalent simplification of the distribution network reduces the problem dimension, and the special coding can further improve the computational efficiency.

Figure 2 .
Figure 2. Simplified diagram of distribution network.

Figure 3 .
Figure 3.Comparison of evolution curves of different metaheuristic algorithms.

Figure 3 .
Figure 3.Comparison of evolution curves of different metaheuristic algorithms.

5. 2 .
Comparison of Different Algorithms HPSO is divided into two main parts: branched group selection optimization based on adaptive solving, and the internal optimization of branched groups based on LF.In order to reflect the advantages of HPSO, the following three algorithms are set up separately for comparison: Improved binary particle swarm optimization (IBPSO):The branch group selection optimization uses the improved BPSO algorithm based on adaptive coding strategy proposed in this paper, and the conventional DPSO is used for the internal optimization of the branch group.Improved discrete particle swarm optimization (IDPSO): The internal optimization of the branch group adopts the improved DPSO based on LF proposed in this paper, and the optimization of branch group selection uses the conventional BPSO.HPSO: The branch group selection optimization adopts the improved BPSO based on adaptive solution proposed in this paper, and the internal optimization of the branch group adopts the improved DPSO based on LF.

Figure 4 .
Figure 4. Comparison of evolution curves of different algorithms.

Figure 4 .
Figure 4. Comparison of evolution curves of different algorithms.

Figure 5 .
Figure 5. Voltage comparison of each node before and after DNR.(a) Improved IEEE 33 nodes; (b) improved IEEE 69 nodes.

Figure 5 .
Figure 5. Voltage comparison of each node before and after DNR.(a) Improved IEEE 33 nodes; (b) improved IEEE 69 nodes.
• • • , L d ) denotes a random value in the 1, 2, • • • , L d array, L d is the number of branches contained in the d branch group, and the round symbol indicates rounding to the nearest integer.

Table 1 .
Parameters of different algorithms.

Table 2 .
Results of different metaheuristic algorithms.

Table 3 .
Results of different algorithms.

Table 4 .
Comparison before and after DNR.

Table 4 .
Comparison before and after DNR.