## 3 Solution Method  
The problem of DESS sitting and sizing shown in Section 3 is a large-scale, mixed, non-linear, constrained, optimization problem that can be solved by a GA algorithm. However, the computational efforts required can be excessive and increase significantly with the size of the distribution systems, especially when unbalances and load patterns are taken into account, as they are in this paper. To reduce the processing time while maintaining reasonable accuracy, in this paper we propose to reduce the GA algorithm search space. For this reason, the allocation problem algorithm, whose flow chart is shown in Figure 1, is dealt with in two successive steps:  
* Step 1. application of suitable techniques to identify a reduced feasible region for DESS sitting (allocation bus set, ABS);
* Step 2. application of the GA to find the optimal solution in the ABS. With reference to the reduction of the feasible region (Step 1, Figure 1), it has to be noted that DESS sizing significantly influences both the objective function and the satisfaction of constraints whereas DESS sitting significantly influences the satisfaction of constraints but has only a slight influence on the objective function (basically, in terms of grid losses). Thus, the reduction of the feasible region has to be searched with reference only to the DESS sitting in order to avoid affecting too negatively the problem solution by acting also on the DESS sizing. More specifically, the reduction of the feasible region is obtained by selecting, among all the network buses suitable for the DESS sitting (i.e., theoretically all the network buses), a subset of buses that includes only the buses whose injection has the expected better favorable impact on the network constraints satisfaction (in Equations in Table 4.  
Considering that the network operating constraints to be met include the bus voltages in Equation (g) in Table 4, the voltage unbalance factors in Equation (h) in Table 4 and the line currents in \begin{table}
\begin{tabular}{l} \hline \hline
**Load Flow Equations** \\ \hline \(P^{p}_{l_{\{y_{(y,t)}\}}}=V^{p}_{l_{\{y_{(y,t)}\}}}\sum_{j=1}^{ng}\sum_{m=1}^{3 }V^{m}_{l_{\{y_{(y,t)}\}}}\left[G^{pm}_{ij}\cos\left(\theta^{p}_{l_{\{y_{(y,t)} \}}}-\theta^{m}_{l_{\{y_{(y,t)}\}}}+B^{pm}_{ij}\sin\left(\theta^{p}_{l_{\{y_{(y,t )}\}}}-\theta^{m}_{l_{\{y_{(y,t)}\}}}\right)\right]\right.\) \\ \(Q^{p}_{l_{\{y_{(y,t)}\}}}=V^{p}_{l_{\{y_{(y,t)}\}}}\sum_{j=1}^{ng}\sum_{m=1}^{3 }V^{m}_{l_{\{y_{(y,t)}\}}}\left[G^{pm}_{ij}\sin\left(\theta^{p}_{l_{\{y_{(y,t )}\}}}-\theta^{m}_{l_{\{y_{(y,t)}\}}}-B^{pm}_{ij}\cos\left(\theta^{p}_{l_{\{y_{ (y,t)}\}}}-\theta^{m}_{l_{\{y_{(y,t)}\}}}\right)\right]\right.\) \\ \hline \(P^{p}_{l_{\{y_{(y,t)}\}}}=P^{p,sp}_{D\mathcal{C}_{l_{\{y_{(y,t)}\}}}}+P^{p}_{ DSS_{\mathcal{C}_{l_{\{y_{(y,t)}\}}}}}+P^{p,sp}_{l_{\{y_{(y,t)}\}}}\), & (b) \\ \hline \(Q^{p}_{l_{\{y_{(y,t)}\}}}=Q^{p}_{D\mathcal{C}_{l_{\{y_{(y,t)}\}}}}+Q^{p}_{ DSS_{\mathcal{C}_{l_{\{y_{(y,t)}\}}}}}+Q^{p,sp}_{l_{\{y_{(y,t)}\}}}\), & (c) \\ \hline \(i=1,\ldots,ng;p=1,2,3;k=1,\ldots,nt;y=1,\ldots,ny;d=1,\ldots,nd_{y}\). & \\ \hline \multicolumn{3}{l}{**Inter-connection bus constraints**} \\ \hline \(V^{p}_{1\mathcal{I}_{\{y_{(y,t)}\}}}=V^{slack}\), & (d) \\ \hline \(\theta^{p}_{l_{\{y_{(y,t)}\}}}=\frac{2}{3}\pi(1-p)\), & (e) \\ \hline \(p=1,2,3;k=1,\ldots,nt;y=1,\ldots,ny;d=1,\ldots,nd_{y}\), & \\ \hline \(\sqrt{\left(\sum\limits_{p=1}^{3}P^{p}_{1\mathcal{I}_{\{y_{(y,t)}\}}}\right)^{2 }+\left(\sum\limits_{p=1}^{3}Q^{p}_{1\mathcal{I}_{\{y_{(y,t)}\}}}\right)^{2}} \leq S_{MV}\), & (f) \\ \hline \(k=1,\ldots,nt;y=1,\ldots,nt;y=1,\ldots,nt;y=1,\ldots,nd_{y}\). & \\ \hline \multicolumn{3}{l}{**All network busbars**} \\ \hline \(V_{min}\leq V^{p}_{l_{\{y_{(y,t)}\}}}\leq V_{max}\), & (g) \\ \hline \(kd_{i,k_{\{y_{(y,t)}\}}}\leq kd_{max}\), & (h) \\ \hline \(l^{l}_{\{y_{(y,t)}\}}\leq l^{l}_{z}\), & (i) \\ \hline \(i=1,\ldots,ng;p=1,2,3;k=1,\ldots,nt;y=1,\ldots,nt;y=1,\ldots,nty;d=1,\ldots,nd_{y};l=1, \ldots,nl\). & \\ \hline \end{tabular}
\end{table}