## 4 Numerical Results
### Results  
It is noteworthy that the mentioned problem is a mixed-integer nonlinear optimization problem. Therefore, this article used the CSA algorithm to solve it. Population size and maximum number of iterations to reach convergence were set to 80 and 5000, respectively. The rest of the parameters were extracted from [77]. 1. Case studies In this section, three case studies were carried out:
2. Case 1: Power flow studies (in a network without DGs and without applying reconfiguration)
3. Case 2: Power flow studies in the presence of DGs
4. Case 3: Reconfiguration the distribution network with DGs
5. Evaluation of reconfiguration Reconfiguration results for the 69-bus distribution network are presented in Table 2. In this table, the open switches of the network are specified. Based on this table, the function of each switch will change every hour. This is due to the change in load. With the changes in the amount of load, there is a possibility of increasing the power loss. Thus, the function of the switches is changed until a suitable path for feeding the loads is obtained in order to minimize energy losses. In addition, five switches are open at any moment. This case is due to compliance with constraint (17) that keeps the distribution system in a radial form. Figure 4: Average daily curve of PV unit power rate [86]. Figure 3: Average daily curve of wind unit power rate [86]. Based on Figures 5-7 the active power of wind systems, solar systems, and diesel generators in Case 3 is generally more than that of Case 2. This is because the reconfiguration of the network increased the power fed by these sources. The occurrence of such conditions is in accordance with this fact that the paper assumes that DGs are able to control their power. In other words, in optimal energy management, local elements similar to sources located at the consumption points are expected to control their power. Therefore, the paper assumes constant power DGs. In this paper, the upper boundary of control power of DGs is proportional to wind speed or irradiation. Nevertheless, according to Figure 8, the reactive power of the diesel generator is reduced in Case 3 compared to Case 2. Note that the DG is located on Bus 60, and the magnitude of voltage of this bus based on power flow studies [79] is around 0.93 p.u. Hence, the presence of only one DG on this bus cannot increase the voltage magnitude to 1 p.u. Hence, the DG is not expected to play the role of voltage regulator; therefore, this bus remains as a PQ bus. In addition, by performing the reconfiguration program in Case 3, the distance between bus 60 and the upstream network may not be reduced; hence, its voltage becomes higher compared to that of Case 1. In the following, the DG lowers its reactive power to prevent any high overvoltage. Nonetheless, note that active power of the DG has increased in Case 3. In such conditions, if reactive power of the DG is not reduced, higher overvoltage is more probable in the network. different solvers such as CSA, krill herd optimization (KHO) [88], gray wolf optimization (GWO) [89], teaching-learning-based optimization (TLBO) [90], and particle swarm optimization (PSO) [78] have been reported. The population size and the maximum convergence iterations for these algorithms are 80 and 5000, respectively. In addition, Refs. [77; 78; 88; 89; 90] were referred to to choose the parameters of the algorithms. To calculate the standard deviation of the final response, each of the mentioned algorithms finds the solution of the problem 30 times. As per the table, the CSA obtains 97.455 MWh for the objective function in 2936 convergence iterations. This iteration corresponds to a computing time of 128 s. However, other algorithms extract more than 99.8 MWh for the objective function. Moreover, their convergence iterations and computing time are more than 3500 and 170 s, respectively. Therefore, CSA can extract the optimal solution in a shorter period than other algorithms.