A Hybrid Approach Based on SOCP and the Discrete Version of the SCA for Optimal Placement and Sizing DGs in AC Distribution Networks

This paper deals with the problem of the optimal placement and sizing of distributed generators (DGs) in alternating current (AC) distribution networks by proposing a hybrid master– slave optimization procedure. In the master stage, the discrete version of the sine–cosine algorithm (SCA) determines the optimal location of the DGs, i.e., the nodes where these must be located, by using an integer codification. In the slave stage, the problem of the optimal sizing of the DGs is solved through the implementation of the second-order cone programming (SOCP) equivalent model to obtain solutions for the resulting optimal power flow problem. As the main advantage, the proposed approach allows converting the original mixed-integer nonlinear programming formulation into a mixed-integer SOCP equivalent. That is, each combination of nodes provided by the master level SCA algorithm to locate distributed generators brings an optimal solution in terms of its sizing; since SOCP is a convex optimization model that ensures the global optimum finding. Numerical validations of the proposed hybrid SCA-SOCP to optimal placement and sizing of DGs in AC distribution networks show its capacity to find global optimal solutions. Some classical distribution networks (33 and 69 nodes) were tested, and some comparisons were made using reported results from literature. In addition, simulation cases with unity and variable power factor are made, including the possibility of locating photovoltaic sources considering daily load and generation curves. All the simulations were carried out in the MATLAB software using the CVX optimization tool.


Introduction
Electrical distribution networks are entrusted with providing electricity services to the end users in medium-and low-voltage level in rural or urban areas [1]. These grids are typically operated with a radial configuration to reduce investment, maintenance and operative costs [2]. However, the radial configuration produces higher power losses in contrast to meshed configurations; also, the nodal voltage rapidly worsens, as the nodes are far from the substation [3]. To mitigate these higher power losses, the literature proposes multiple approaches to know: (i) optimal placement of shunt capacitors [4], (ii) optimal reconfiguration of the distribution grid [5], (iii) optimal selection/substitution of the calibers of the conductors [6,7], (iv) optimal placement and sizing distributed generators [8][9][10], among others. Each one of these approaches allow dealing with power losses minimization; nevertheless, the most effective approach for dealing with this power loss corresponds to the optimal placement and sizing of DGs since reductions higher than 50% have been reported for this methodology [11].
The optimal placement and sizing of DGs in electric distribution networks is a complex and large-scale mixed-integer nonlinear programming (MINLP) problem. This MINLP structure of the optimization problem complicates the possibility of finding the global optimal solution due to the non-convexity shape of the solution space [12]. For this reason, in this research, we propose a combination of a metaheuristic approach with a second-order cone programming (SOCP) formulation to address this problem with excellent numerical performance as will be presented in the results section.
Due to the importance of having mathematical optimization in distribution systems analysis, here, we propose a new hybrid optimization approach based on the discrete version of the sine-cosine algorithm, i.e., (DSCA) added to the SOCP formulation to solve the exact mixed-integer nonlinear programming (MINLP) formulation of the problem of the optimal location and sizing of DGs in AC distribution networks [13]. This hybrid optimization approach called DSCA-SOCP is motivated by the following facts: (i) the exact MINLP structure makes it impossible to find the global optimal solution for this problem with the current optimization approaches even using metaheuristic; this situation occurs since the studied problem contains binary variables regarding the placement of the DGs and the continuous part associated with their sizing, which is formulated as an optimal power flow problem being non-convex due to the presence of trigonometric functions in its formulation where it is not possible to ensure global solution with nonconvex methods [14,15]. The union of both problems (integer and nonlinear continuous) increases the possibility of branch and bound methods or metaheuristics to be stuck in local optimal solutions [16]; and (ii) the conventional metaheuristic approaches to solve the MINLP problem deals with the optimal power flow problems using controlled random procedures [8], which are inadequate approaches (they do not guarantee the global optimal solution); in opposition, the convex optimization allows to find it with duality zero gap [17].
Based on the aforementioned problems with conventional metaheuristic approaches, we propose a hybrid DSCA-SOCP programming to solve the studied problem using a master-slave optimization strategy, where the master stage is entrusted with determining the subset of nodes where DGs will be located, and the slave stage solves the resulting optimal power flow problem to determine their optimal sizes. The main advantage of the proposed approach is that the SOCP programming ensures the global optimal solution for each nodal combination provided by the DSCA [18], which implies that if the best subset of nodes is identified by the master stage, the global optimal solution for the problem of the optimal placement and sizing of DGs in AC distribution networks will be guaranteed (this will be confirmed in the results section) [19].
The problem of the optimal placement and sizing of distributed generation in AC distribution networks to minimize active power losses in all the branches of the grid has been largely studied in the last two decades [20]. Most of the proposed approaches in literature work with master-slave algorithms based on metaheuristic optimization techniques [8]. Some of the recent approaches in this field of study are listed in Table 1.
The common denominator of these approaches is that these references work with hybrid master-slave optimization approaches to solve the exact MINLP model in two stages, i.e., a discrete part of the algorithm is entrusted with determining the location of the DGs and the continuous part deals with the dimensioning problem via optimal power flow analysis [21]. However, no evidence about the combination of the convex optimization approach for the continuous part and the discrete sine-cosine algorithm for the integer part has been found after the revision of the state-of-the-art, and this gap has been exploited in this paper as an opportunity of research. Remark 1. In the revision of the state-of-the-art, only the methodologies called MINLP proposed in [9] and GAMS presented in [12] work with the exact model of the problem by implementing branch and bound in conjunction with interior point methods to solve the problem. However, due to the non-convexities of the solution space, these are stuck in local optimums.
To avoid being stuck in local optimum solutions, our approach combines the efficiency of conic programming with easily implementable metaheuristic to find the global optimal solution of the problem using a master-slave optimization approach. The main advantage of the SOCP is that if the combination of the nodes where DGs will be located is fixed, the optimal sizing provided by the SOCP approach remains equal (repeatability property), which is not ensured with conventional metaheuristics used for optimal power flow analysis.
Based on the review of the state-of-the-art presented in the previous section, the main contributions of our proposal can be summarized as follows: The reformulation of the exact mixed-integer nonlinear programming model into a mixed-integer one by transforming its continuous, i.e., optimal power flow, into a convex formulation via second-order cone programming. The presentation of the discrete version of the sine-cosine algorithm to address the integer part of the MISOCP approach by using an integer codification that contains the nodal numbers as decision variables. The hybridization of the SCA and the SOCP programming has the capability of finding the global optimal solution with low computational effort in both test feeders studied. Numerical results show improvements regarding classical mataheuristic methods available in literature, including exact MINLP approaches.
It is worth mentioning that the proposed optimization approach deals with the optimal placement and sizing of DGS in AC distribution networks considering the load peak conditions by assuming that the distributed generators are fully dispatchable as recommended in [9]. In addition, no considerations are made regarding the total distributed generation since we are interested in finding the best possible reduction in the active power losses in the distribution network without penetration limitations. Finally, we consider the possibility of installing three distributed generators since this is the most common assumption in literature [32]. In addition, three simulations cases are analyzed: (i) the optimal location and sizing of the DGs considering unity power factor, (ii) variable power factor, and (iii) daily load and photovoltaic solar curves.
The remainder of this document is organized as follows: Section 2 presents the exact mixed-integer nonlinear problem formulation of the optimal location and sizing of DGs in AC distribution networks with radial structure. Section 3 presents the proposed hybrid optimization methodology with master-slave structure, where the master slave is entrusted with solving the location problem by implementing the discrete version of the sine-cosine algorithm, and the slave stage is entrusted with determining the optimal sizes of the DGs by using a SOCP formulation. Section 4 presents the main features of the test feeders which are composed of 33 and 69 nodes, with radial structure and operated with 12.66 kV at the substation node. Section 5 presents the numerical achievements of the proposed optimization approach regarding the optimal location and sizing of DGs with their corresponding analysis and discussion. Section 6 shows the main concluding remarks as well as some possible future works derived from this research.

MINLP Formulation
The problem of the optimal location and sizing of distributed generation in AC distribution networks can be formulated as a mixed-integer nonlinear programming (MINLP) problem. The objective function of this problem corresponds to the minimization of the active power losses in the distribution network, which is subjected to a set of nonlinear constraints regarding active and reactive power balance equations, device capabilities and voltage regulation bounds, among others. Here, we present the MINLP formulation in the complex domain in order to simplify the proposed optimization approach that will be presented in Section 3. The complete MINLP model is presented below.
Objective function: The objective function that represents the problem of the optimal placement and sizing of DGs in AC distribution networks corresponds to the total power losses caused by the current flow in all the branches of the network. This objective function is formulated as presented in Equation (1).
where p loss is the objective function value, V i and V j are the voltage values (magnitude and angle) in the nodes i and j, respectively; Y ij is the complex admittance value of the nodal admittance matrix that relates nodes i and j. Note that N represents the set that contains all the nodes of the network, and (·) represents the complex conjugate operator applied to the argument. Set of constraints: The set of constraints that intervene in the problem of the optimal placement and sizing of DGs in AC distribution networks are described as follows: where S s, i is the apparent power generation in the slack node connected at bus i, S dg, i corresponds to the apparent power generation provided by the DG connected at node i, and S d, i represents the apparent power consumption at node i. Expression (3) is associated to the voltage regulation bounds in all the nodes of the network.
where γ is the maximum deviation given by the regulatory policies, which is usually between 0.05 pu and 0.10 pu. Note that in the case of the substation, V i = 1 + j0 pu.
The capacity of the existing and newly distributed generators is upper and lower bounded as follows: where which denotes the binary variable of the problem, which has a value of 1 if a DG is installed at node i or 0. There is a limit to the number of DGs that can be installed in the system, which is given by (7), where N DGs is the total number of distributed generators available for installation in the AC distribution network.

Remark 2.
The structure of the optimization model (1) to (7) exhibits a nonlinear non-convex structure with the presence of binary variables regarding the location of the DGs in a particular node of the grid. However, the nonlinear structure of the power balance equations in (2) is the most challenging constraint since it does not guarantee the global optimum finding even if all the binary variable combinations are explored. To address the nonlinear part of the optimization model described in Figure 1, we propose the reformulation of the nonlinear part of the model (i.e., power balance equations) into a second-order cone equivalent, while the binary part of the model is addressed through a metaheuristic approach as is presented in the following section.

Proposed Hybrid Optimization Approach
To solve the problem of the optimal placement and sizing of DGs in AC distribution networks, we propose a hybrid master-slave optimization algorithm. The master stage employs the metaheuristic sine-cosine algorithm (SCA) to solve the binary problem, i.e., the location of the distributed generators on the grid. In the slave stage the optimal power flow problem is reformulated as a second-order cone programming (SOCP) in order to guarantee the global optimum finding for each nodal combination providing for the SCA.

Slave Stage: SOCP Approach
The SOCP approach corresponds to a branch of the convex optimization where conic constraints allow for the reformulation of products between variables in order to transform nonlinear optimization problems into convex ones [18]. In the case of the optimal power flow analysis, the SOCP formulation permits to find the global optimal solution with zero gap when this is compared to the exact nonlinear programming power flow formulation [17]. Here, the SOCP formulation is presented to address the problem of the optimal sizing of DGs supposing that their locations have been previously informed by the master stage. To obtain the SOCP model, let us define a new auxiliary variable as follows where if we multiply in both sides for V ij , we have Now, if we define a new vector of U with entries v i = V i 2 , then we reach the following result which can be rewritten as follows Note that Equation (11) is still a non-convex equality constraint, however, as recommended in [18], this can be relaxed as a second-order constraint by replacing the equality symbol by an inequality one as presented below: Now, to rewrite the continuous part of the studied problem, let us substitute (8) into (1) and (2), which produces the following linear objective function and constraint, respectively.
Remark 3. The SOCP reformulation allows reaching the global optimal solution of the optimal power flow problem associated with the optimal sizing of the DGs, since the resulting optimization model is essentially linear with an only conic constraint.
Note that the characteristics of the studied optimization model depicted in Figure 1 can be redefine by eliminating the non-convex constraint based on the proposed SOCP formulation as presented in Figure 2.

Convex Equations
(3)-(5), (7), (8) and (12)-(14) x i ∈ {0, 1} Binary MI-SOCP Note that the SOCP approximation is given as a function of V ij and v i instead of the voltages V i . Notwithstanding, it is possible to recover the original voltages by the following two-step procedure: First, the voltage magnitude is computed as This value exists, and it is real since u i ≥ 0. Second, the angle of the voltages is calculated from θ ij = ang(V ij ) in a forward iteration, starting from θ 1 = 0. Therefore, a power flow calculation is not required after the optimization problem is solved.

Master Stage: Discrete SCA
The master stage is entrusted with solving the integer part of the optimization problem, i.e., to define the location of all the DGs. Here, we adopt the discrete version of the sinecosine algorithm, which works with a reduced population by using an integer codification to represent the optimization problem [21].
The SCA is an optimization technique that works with a population which evolves by using trigonometric functions and variable radius in order to explore and exploit the solution space [33]. This optimization algorithm has been employed to solve different continuous domain problems, such as optimal power flow in power and distribution systems [34,35], parameter estimation in photovoltaic modules [36], optimal design of bend photonic crystal waveguides [37], and general solution of nonlinear non-convex optimization problems [38] among others. The main aspects of the implementation of the discrete SCA are described in the following subsections.

Initial Population
The SCA is a metaheuristic optimization technique that works with an initial population that is evolving through the iterative procedure by sine and cosine rule. The structure of the initial population for the proposed SCA is defined as follows where t is the iterative counter, which is fixed as zero for the initial population, and M is the number of individuals in the population. Remember that N DGs represents the number of DGs available for installation.
Note that each element inside of the initial population is created as follows: where n is the total number of nodes in the AC distribution network. Observe that the function round(·) takes the near integer part of the number and rand is a random number between 0 and 1 generated with a normal distribution. It is worth mentioning that node 1 is not considered in the population since it corresponds to the slack node. In addition, this codification guarantees the feasibility in the integer part of the solution space.

Remark 4.
To maintain the feasibility of the solution space during the generation of the initial population we ensure that each one of the components of the individual N t i is different to the remainder components, i.e., n ij = n ik , ∀k = 1, 2, ..., N DGs , and k = j.

Fitness Function Evaluation
The SCA evolves through the solution space typically using a modification of the objective function named fitness function [39]. This helps deal with possible infeasibilties of the decision variables [40]. However, due to the continuous part for the problem is formulated as a SOCP model; most of the constraints are directly fulfilled during the solution procedure via interior point methods. In this sense, the structure of the fitness function selected in this research takes the same form of the objective function. Note that this function is evaluated for each individual in the population, i.e., p loss N t i , in order to identify the best individual in the current population. This individual is called N t best . Observe that in this research the best individual corresponds is the one who has the lower objective function value.

Evolution of the Population
The evolution of the of the population in the SCA algorithm is governed by trigonometric functions with a simple evolution rule as presented in Algorithm 1. Note that this evolution strategy takes the probability of 50% to evolve with sine or cosine trigonometric function (see r 1 parameter). In addition, r 2 controls the effect of the iteration counter in the modification of the population by presenting a linear decreasing rule; r 3 allows the evaluation of the sine or cosine function in all the points of the unitary circle, and r 4 introduces the importance of the best current individual in the evolution of the individual N t i to generate the next population.

Stopping Criterion
To finalize the searching procedure of the discrete version of the SCA, one of the following two conditions must be satisfied.
If the total iterations t max are reached, the SCA ends its iterative search and reports the best solution in the current population, i.e., N t max best . If during k max consecutive iterations the objective function does not improve, the iterative search of the SCA ends, and the best solution in the current population is reported, i.e., N t best .

Proposed Master-Slave Optimization Algorithm
The proposed master-slave optimization strategy to solve the problem of the optimal location and sizing of DGs in AC distribution networks based on the hybridization of the discrete version of the sine-cosine algorithm and the SOCP reformulation is summarized in Algorithm 2.

Algorithm 1: Evolution steps in the sine-cosine algorithm (SCA).
Result: Evolution of the Individuals in the Population (1)(n − 2)); end Evaluate the objective function value for the potential individual, i.e., p loss ( Algorithm 2: Proposed master-slave optimization approach.
Result: Optimal location and sizing of DGs Define the AC grid parameters; Define t max , k max , M and make t = 0 and k = 0; while t ≤ t max do if t = 1 then Create the initial population, i.e., N t ; Evaluate the fitness function of each individual, i.e., p loss N t i ; Select the best current solution individual, i.e., N t best ; end while i ≤ M do Apply the evolution strategy defined in Algorithm 1 to update the current population, i.e., to obtain N t+1 Report the best solution of the current population, i.e., N t best and solves the SOCP for it to determine the optimal sizes of the DGs. end end Remark 5. Since the proposed hybrid SCA-SCOP depends on a metahueristic search in the master stage, statistical evaluation is required to determine its efficiency regarding the optimal solution finding capabilities. Here, we adopt 100 consecutive evaluations to the determine the general distribution of the solution findings by using maximum, minimum, mean and standard deviation indicators [21].

Test Feeders
The computational validation of the proposed master-slave hybrid optimization algorithm to the optimal location and sizing of DGs in AC distribution is made in two classical distribution networks tests: 33 and 69 nodes. These grids works 12.66 kV at substation. The electrical connection between nodes in these test feeders are presented in Figures 3 and 4, respectively, while its parametric information can be consulted in [12]. It is worth mentioning that these test feeders are considered urban distribution networks that fed industrial users modeled as constant power consumption [8].   For both test feeders we consider as recommended in [21] the possibility of locating three distributed generators which will be sized at the peak load condition, we considered the voltage and power base values of 12.66 kV and 1000 kW, respectively. In addition, for the 33-node test feeder each DG was limited from 300 kW to 1200 kW, while for the 69-node test feeder these bounds were relaxed from 0 kW to 2000 kW, respectively.

Computational Validation
This section presents the computational validation of the proposed hybrid optimization approach based on the discrete version of the sine-cosine algorithm and the second-order cone programming model to deal with the problem of the optimal placement and sizing of distributed generators in AC distribution networks. We implement the proposed solution methodology on a personal computer AMD Ryzen 7 3700U, 2.3 GHz, 16 GB RAM with 64-bits Windows 10 Home Single Language using the MATLAB programming environment.
To compare the proposed hybrid optimization algorithm regarding objective function performance, we selected multiple metaheuristic optimization techniques reported in literature. These methodologies have been listed in Table 1. In the implementation of the proposed DSCA-SOCP approach, we have considered 50 iterations and a population of four individuals; in addition, 100 consecutive evaluations are made to validate the efficiency of the algorithm to reach the optimal solution and calculate the average processing time. Note that these parameters were found after multiple simulations that have allowed to identify an adequate trade-off between simulation times and the quality of the final solution. Table 2 reports the optimal placement and sizing of the distributed generators located in the 33-node test feeder after applying the proposed hybrid DSCA-SOCP (see last row) as well as the comparison with the literature reports. The results in Table 2 illustrate that:

Results in the 33-Node Test Feeder
• There are three methods that finds the best optimal solution for the 33-node test feeder which are the MSSA, the CBGA-VSA and the DSCA-SOCP, which find a final power losses of about 72.7853 kW by installing DGs in nodes 13, 24 and 30 with power generations of 801.8 kW, 1091.3 kW and 1053.6 kW, respectively.

•
The maximum reduction of the power loss is achieved by the aforementioned three methods (including our proposal) with a total reduction of about 65.50% regarding the base case, i.e., 210.9876 kW, while the worst approach corresponds to the GA-IWD with a reduction of about 47.62%. These results imply that all the remainder literature methods (see Table 1) have found solutions contained between these extreme solutions.

•
The best solutions show that the best nodes to locate DGs are 13, 24 and 30; however, the second-best solution reported in this table is found when node 13 is changed by node 14 as reported by the GAMS and HSA-PABC algorithms with a small variation regarding final power losses of about 27.60 W.
It is worth mentioning that the results in Table 2 show that some methods identify the best optimal nodes for optimal locating DGs (see the AHA and the MINLP methods), however, due to the non-convexities in the dimensioning stage, i.e., optimal power flow, these methods present sub-optimal solutions since the nonlinear search approach (in some cases continuous metaheuristics) is stuck in local optimums. This situation does not occur at least with our proposal since each potential location for generators is optimally solved via SOCP which guarantees the optimal finding based on its convex structure. This implies that if we evaluate the same combination of nodes multiple times the optimal sizes of the DGs will be equal for each one of the evaluations (optimal solution), which confirms the efficiency of the convex optimization, i.e., SOCP, in power systems analysis.

Results in the 69-Node Test Feeder
The numerical behavior of the proposed DSCA-SOCP method for the 69-node test feeder is reported in Table 3 (see last row), where it is compared with multiple literature reports. The numerical values in Table 3 help conclude that: The same three methods found in the 33-node test feeder has global optimization capabilities, i.e., the MSSA, the CBGA-VSA and the proposed DSCA-SOCP, since these reach the best solution for the 69-node test feeder with a final power loss of 69.4077 kW by installing the DGs in nodes 11, 18 and 61 with power injections of 526.80 kW, 380.10 kW, and 1719.00 kW, respectively. Some near optimal solutions are found with other approaches such as MINLP, AHA, KHA and CHVSA since all of them provide solutions lower than 70 kW in the final power losses. However, these methods are stuck in local optimums since, in the case of the MINLP and the CHVSA approach, the node 18 (in the global optimal solution) was changed for the node 17. In addition, the AHA and KHA methods identify nodes 12, 21 (22) and 61 as the best possible generators location, which also implies that in the solution of the discrete problem (i.e., master optimization stage), these are also stuck in local optimums. Regarding the total improvement of the power losses, we can observe that the proposed method allows reaching a total power loss reduction of about 69.15% (the same result for the MSSA and the CBGA-VSA methods), while the worst behavior regarding power losses minimization occurs for the GA-PSO with 62.40%. These extremes imply that all the other solutions are contained on this interval with a bandwidth of about 6.75%.

Additional Comments
For both test feeders it is important to mention that: (i) the proposed optimization method reaches the solution of the optimal problem of placement and sizing of DGs in AC distribution networks in the 33-node test feeder after 350 s of simulation, and in the case of the 69-node test feeder, this processing time was about 580 s; (ii) after 100 consecutive evaluations in both test feeders, the proposed DSCA-SOCP approach finds with the 30% of effectiveness in the 33-node test feeder and 20% in the case of the 69-node test system; and (iii) the differences between the best and the worst solution in both test feeders are about 2 kW, which implies that most of these solutions are indeed better than the current literature solutions presented in Tables 2 and 3.
Regarding voltage profiles, it is important to highlight that the minimum voltage regulation in the 33-node test feeder is 9.62% and in the 69-node test feeder is about 9.08% previous to the optimal location of the DGs; however, after solving the MISOCP model with the proposed DSCA-SOCP approach, these regulations have improved until 3.13% and 2.10 % (note that the best possible regulation in a distribution is 0%, which implies that percentages close to zero are high-quality solutions). These results confirm the effectiveness of including DGs in AC distribution networks for improving voltage profiles since these are close to 1.00 pu in contrast to the base case.
It is worth motioning that, numerically speaking, the proposed DSCA-SOCP is equivalent to the CBGA-VSA approach reported in [21]; however, note that the main difference between both methods is associated with the continuous part of the MINLP model, i.e., the sizing of the DGs, since our approach solves these using an exact optimization method based on convex optimization, which implies that the sizes of the DGs are optimal; nevertheless, in the case of the VSA approach, this optimal property cannot be ensured due to the heuristic nature of this algorithm.

Numerical Validation Considering Variable Power Factor
To verify the effectiveness of the proposed hybrid DSCA-SOCP approach to determine the optimal location and sizing of DGs in radial distribution networks, here we consider the possibility of installing from 1 to 3 DGs, leaving free the total amount of reactive power injection as recommended in [9]. Tables 4 and 5 present the optimal solutions reported in literature for the improved analytical (IA) method, the particle swarm optimization (PSO) and the exact MINLP approach, all of which have been reported in [9] for the 33and 69-node test feeders. From results in Tables 4 and 5 it is possible to observe that: The exact MINLP approach and the proposed DSCA-SOCP approach identify the same subset of nodes to locate DGs for all the simulation cases in the 33-and 69-node test feeders. The inclusion of the reactive power capability of the DGs significantly improves the total power losses minimization regarding the unity power factor case. For example, for the case of three distributed generators, the total power loss passes from 72.7853 kW to 11.7400 kW; while for the 69-nodes, this change is from 69.4077 kW to 4.2682 kW.
The solution with only one generator in the 33-and 69-node test feeders shows that the inclusion of reactive power improves the total active power losses in both systems, when three DGs are located considering unity power factor. This situation can be attributed to the positive effects of the moderated reactive power injections in the voltage profile behavior of the grid [10].
It is worth mentioning that the proposed DSCA-SOCP approach allows to reach the best optimal solutions compared to the comparative methods even if the location of the generators is the same as can be seen in Tables 4 and 5, since this hybrid approach ensures the optimal solution finding of the OPF problem associated with the sizing of the DGs by using a SOCP formulation, which is not the case with the PSO and IA algorithms. However, in the case of the MINLP approach, we can observe that the results presented by this method in the 33-and 69-node test feeders are comparable with the proposed DSCA-SOCP approach, and the difference in some decimals can be attributed to precision errors between both methodologies.
To verify that under the peak load condition all the voltage profiles in both test feeders fulfill their bounds, these are depicted in Figure 5. In this picture it is possible to observe that, in the case of the of the 33-node test feeder (see Figure 5a), when the distributed generation with reactive power capabilities is installed in the network, all the voltages increase and overpass 0.95 pu, which implies that the voltage regulation in this network is about 4.20% with one and two DGs and less than 1.00% in the case of the three DGs. In the case of the 69-bus test feeder (see Figure 5b), when distributed generators are located considered reactive power injections, we can observe that for one DG the regulation of the grid is about 2.00% caused by voltage drops in nodes 66 to 69, while for the two and three DGs the voltage regulation is lower than 1.00%.
It is worth mentioning that for both test feeders, when two or three DGs are used, all the voltage profile are very close to the substation voltage, which causes the line voltage drops to be very small, producing low power losses as can be observed in Tables 4 and 5.

Optimal Location of Renewable Energy Sources
To observe the effectiveness and robustness of the proposed approach to deal with renewable energy resources and variable load profiles, here, we study the problem of the optimal location of renewable energy resources in radial distribution networks. To do so, we consider that in the 69-node test feeder the possibility of installing three photovoltaic distributed generators considering a daily generation and load curves. These curves are depicted in Figure 6.
In this simulation scenario, the proposed DSCA-SOCP is compared with the largescale nonlinear optimization package widely known as GAMS and the MINLP solves BONMIN, COUENNE and DICOPT. The results of this comparison is reported in   The results in Table 6 demonstrate that: (i) with the location of three photovoltaic sources the proposed approach, i.e., the DSCA-SOCP approach, reduces the daily energy loss per day to about 919.1112 kWh/day, i.e., 34.47%; while the best GAMS approach using the COUENNE solver finds a reduction of 23.84%. These solutions demonstrate that the MINLP solvers in GAMS are stuck in local optimal solution in comparison with the optimal solution found by the DSCA-SOCP and (ii) in all the solutions reported in Table 6 nodes higher than 60 show the high power injection regarding photovoltaic penetration, and it can be observed that these nodes are more sensitive to active power injections when compared with the remainder of buses.

Conclusions and Future Works
The problem of the optimal location and sizing of DGs in AC distribution networks was explored in this research from the point of view of the hybrid optimization by proposing a master-slave optimization algorithm. The original MINLP model was rewritten as a MISOCP problem, where the master stage was entrusted with determining the optimal location of the DGS (i.e., discrete optimization problem), while the slave stage is entrusted with solving the sizing problem, i.e., the optimal power flow problem. The master stage was addressed with a new formulation of the sine-cosine algorithm in its discrete form, while the slave stage was formulated as a SOCP problem. The main advantage of using convex optimization for the optimal sizing of the DGs is that this approach guarantees global optimal solution for each nodal combination provided in the master stage.
Numerical simulations demonstrate that the proposed hybrid DSCA-SOCP approach allowed reaching the global optimal solution for both test feeders, which implies power loss reductions to about 65.50% and 69.15% for the 33-and 69-node test feeders, respectively. It was possible to establish that those solutions are indeed the global optimal ones for the test feeders considered since an exhaustive approach was made, i.e., the evaluation of the complete solution space: this has been demonstrated.
Evaluations considering active and reactive power in the distributed generation for both test feeders demonstrates that apparent power injections improve the grid performance by reducing grid power losses more than 90% for two or three distributed generators, with voltage regulation lower than 1.00% in the case of installing three distributed generators. In addition, the possibility of installing photovoltaic generation considering daily production and demand curves was tested in the 69-bus test feeder for the DSCA-SOCP approach and MINLP solvers available in GAMS, where it was observed that the proposed approach allows reducing daily energy losses by about 34.47%, while GAMS solvers are stuck in local optimal solutions with reductions lower than 25%, which demonstrates the efficiency of the proposed optimization for installing renewable energy resources in AC distribution networks.
Regarding processing times, both test feeders have been solved using less than 600 s. The time consumed for our approach illustrates the efficiency to solve the complex MINLP formulation by using an MISOCP equivalent with capabilities of optimal finding after 100 consecutive evaluations.
Lastly, the following researches can be derived from this proposal: (i) the application of the proposed MISOCP model to the problem of voltage stability improvement in distribution networks by including renewable distribution generation; (ii) the solution of the MISOCP model with branch and bound methods to guarantee the global optimum finding without requiring consecutive evaluations and statistical tests; and (iii) to propose a MISOCP formulation for the problem of the optimal location and selection of battery energy storage systems and distributed generators in AC distribution networks, including devices' costs during the planning horizon.

Data Availability Statement:
No new data were created or analyzed in this study. Data sharing is not applicable to this article.