Optimal Operational Scheduling of Reconﬁgurable Multi-Microgrids Considering Energy Storage Systems

: This paper proposes an optimal operational scheduling of a reconﬁgurable multi-microgrid (MG) distribution system complemented by demand response programs and Energy Storage Systems (ESSs) in an uncertain environment. Since there is a set of competing players with inherently conﬂicting objectives in the system under study such as the Distribution System Operator (DSO) and MG owners, a one-leader multi-follower-type bi-level optimization model is proposed. In this framework, the upper-level player as a leader minimizes the total cost from DSO’s point of view, while the lower-level players as multi-followers maximize the proﬁt of MG owners. Since the resulting model is a non-linear bi-level optimization problem, it is transformed into a single-level mixed-integer second-order cone programming problem through Karush–Kuhn–Tucker conditions. The satisfactory performance of the proposed model is investigated on a real-test system under di ﬀ erent scenarios and working conditions.


Introduction
Recently, due to the energy crisis and environmental deteriorations, the penetration level of Distributed Energy Resources (DERs) including Energy Storage Systems (ESSs), dispatchable and renewable energy sources in distribution sector has been increased significantly. This growing tendency has led to defining the Microgrid (MG) concept as a promising solution to the optimal use of energy resources [1]. Moreover, it mitigates the monitoring and management burden for the Distribution System Operator (DSO) and increases the operational flexibility of the system in the modified decision-making environment of sustainable energy systems [2]. Specifically, a MG is a cluster of loads and DERs which can be operated in both grid-connected and islanded modes [3]. Different aspects related to the application of MGs in distribution systems regarding the analysis and optimization of energy processes including optimal planning [4], operational scheduling [5] and system reliability [6] were thoroughly investigated in the literature. In Reference [7], DSO, who has the responsibility of operating the distribution system in an optimal fashion, determines day-ahead scheduling of DERs using particle swarm optimization (PSO) algorithm. In Reference [8], a two-phase optimal short-term operational scheduling of utility-owned DERs in an active distribution system has been proposed. In the first phase, to determine the amount of purchased power from the wholesale market and the set-points of DERs, a day-ahead energy acquisition model has been developed, where in the second-phase hourly network reconfiguration has been implemented. A day-ahead scheduling

•
A one-leader multi-follower-type bi-level model considering ESSs in an uncertain environment is proposed, • An optimal day-ahead scheduling of multi-MG distribution systems is proposed considering DR and hourly reconfiguration actions, • Modelling the DSO's decision-making problem which is affected not only by the exchanged power between DSO and each MG as a mutual decision variable but also by the reactions of interconnected MGs in an hourly reconfigurable environment.
The remainder of the paper is organized as follows: In Section 2, the conceptual framework of the proposed DMS is explained. The bi-level formulation of the optimization problem is proposed in Section 3. Case study and simulation results are discussed in Section 4. Finally, Section 5 summarizes the contribution of the paper.

Conceptual Framework of the Proposed DMS
In this study, it is assumed that MGs have their own private owners who seek profit maximization, while DSO utilizes the DMS software to minimize the total cost of the distribution system. Thus, DSO and MGs have their own inherently conflicting objectives in optimal scheduling of energy-related generation and consumption units, which can be modelled as a bi-level optimization problem. Figure 1 shows the framework of the proposed bi-level model in the form of a one-leader multi-follower structure for DMS. The leader (which plays at the upper-level in our proposed DMS) is DSO who is responsible for minimizing the total operating costs, whereas the followers (act in the lower-level of the proposed DMS) are MGOs aiming to maximize their own profit. DSO is connected to the upstream utility grid and interacts with networked MGs, while MGOs not only feed the local demand but also exchange energy with each other to make more profit. Thus, the exchanged powers between DSO and multi-MGs are considered as coupling variables between these levels, which enforce decision maker to consider a multi-criteria action plan. It can be seen that DMS receives the network model, retail prices, cost function of DERs, RLs bilateral contracts and forecasted data of load profile, PVs output power and the wholesale market prices as input data. Finally, proposed bi-level DMS returns the optimal amount of exchanged power among MGs, exchanged power between DSO and MGs, Micro Turbines (MTs) and ESSs dispatches, RLs participations, wholesale market purchases and RCSs status during each time interval. Changing the status of RCSs in short-term results in a reconfigurable topology of distribution system, which represents a flexible multi-MG distribution system.

Uncertainty modelling
In the proposed DMS, there are some uncertain parameters such as solar irradiance, wholesale market price and electrical load demand. To study the uncertainty nature of these input data, a stochastic scenario-based method using the mean values (i.e., day-ahead prediction) with different probability density functions is implemented. The scenario generation process is done by Monte-Carlo simulation on predicted mean values while forecasting errors are considered within appropriate probability density functions through associated standard deviations (STDs). The total number of generated scenarios can be calculated by (1) considering constraint (2).
Due to the computational burden limits of the optimization process, a scenario reduction algorithm based on Kantorovich distance [27] method is also incorporated to decrease the number of generated scenarios into a smaller set representing well enough the uncertainties.

Bi-level formulation of the optimization problem
Problem formulation of the bi-level model for operational scheduling of the examined multi-MG distribution system and related solution methodology are described in the following subsections.

Uncertainty Modelling
In the proposed DMS, there are some uncertain parameters such as solar irradiance, wholesale market price and electrical load demand. To study the uncertainty nature of these input data, a stochastic scenario-based method using the mean values (i.e., day-ahead prediction) with different probability density functions is implemented. The scenario generation process is done by Monte-Carlo simulation on predicted mean values while forecasting errors are considered within appropriate probability density functions through associated standard deviations (STDs). The total number of generated scenarios can be calculated by (1) considering constraint (2).
Due to the computational burden limits of the optimization process, a scenario reduction algorithm based on Kantorovich distance [27] method is also incorporated to decrease the number of generated scenarios into a smaller set representing well enough the uncertainties.

Bi-Level Formulation of the Optimization Problem
Problem formulation of the bi-level model for operational scheduling of the examined multi-MG distribution system and related solution methodology are described in the following subsections.

Upper-Level: DSO
The objective function of the upper-level is defined as: Energies 2019, 12, 1766

of 23
As can be seen, the objective function of the upper-level aims at minimizing the total cost from DSO's point of view, which includes different cost terms. The first term denotes the cost of power losses as proposed in (4).
C loss t = ρ loss P loss t (4) where, the amount of active power losses P loss t can be calculated by (16). The second term which is represented by (5) denotes the switching cost of RCSs.
The absolute value in (5) can be avoided by introducing new auxiliary variables as follows: The third term in (3) calculates the cost of purchasing/selling active power from/to day-ahead wholesale market at time t.
Finally, the last term stated in (3) denotes the cost of exchanging power between DSO and MGs represented by (8).

Constraints:
The upper-level objective function is subjected to the following constraints.
• Distribution power flow equations: The generic form of the branch flow model deals with the currents and powers flowing through the branches is as follows: where, (9) represents the Ohm's law, (10) defines the branch power flow and (11) states the power balance constraint at each bus. By defining new variables ij,t,s = I ij,t,s 2 and ν i,t,s = V i,t,s 2 as the squared current and voltage magnitudes, respectively and neglecting the phase angles of currents and voltages, the branch flow model is derived as follows: ν j,t,s = ν i,t,s − 2(r ij P ij,t,s + x ij Q ij,t,s ) + (r 2 Energies 2019, 12, 1766 6 of 23 The amount of active power losses is calculated as: • Voltage limits constraints: • Exchanged power limit with the wholesale market: • Line current limits: At any time and working conditions, the loading level of the lines/feeders should be in an allowed range.
• Network radiality: To preserve the radial configuration of the distribution network at each optimization interval, constraints (20)-(23) should be met.
N br,t = N bus,t − 1 (20) β ij + β ji = X br (21) Equation (20) indicates that the resulted configuration at each hour should be without any loop in the equivalent tree graph. In case that bus j is the parent of bus i (β ij = 1) or bus i is the parent of bus j (β ji = 1), according to (21) the respective branch is in the spanning tree (X br = 1). In order to avoid islanded buses in the final topology, (22)- (23) state that except the substation bus, all the buses should have one parent.

•
Number of switching actions: The above nonlinear constraint can be linearized using auxiliary variables as proposed in (6).
• Exchanged power limit between MGs and DSO:

Lower-Level: Multi-MGs
The objective function of the lower-level part aims to maximize the profit of pth MG considering seven different terms.
Profit terms of the above objective function are defined as follows:

Constraints:
The constraints of the operational scheduling problem at the lower-level are as follows:   • Limits on operation of ESSs: • DR program limits: In this paper, bid-quantity package offers including the amount of load curtailment and related requested prices are considered as the model of RLs. A typical bid-quantity package for the ith node is proposed in Figure 2 and formulated by (52)-(54).

Figure 2.
A bid-quantity offer package for ith node.
• Power balance for pth MG:

Solution methodology
As formulated in previous section, are DSO's and MGOs' decision variables, respectively. The amount of exchanged power between DSO and MGs plays an important role in the solution process, which couples the two levels through interactions among players. The proposed bi-level framework cannot be directly implemented in commercial solvers. To resolve this, by adding the KKT conditions of each follower problem, the lower-level problem (27)-(55) is converted into a single-level optimization problem. To solve the resulted single-level MISOCP problem by DSO, DSO has thorough knowledge of the required information pertaining to the MGs. Figure 3 briefly represents the decision-making process outlining the objectives, constraints of the bilevel problem and its transformation into a corresponding single-level MISOCP problem through

Solution Methodology
As formulated in previous section, are DSO's and MGOs' decision variables, respectively. The amount of exchanged power between DSO and MGs plays an important role in the solution process, which couples the two levels through interactions among players. The proposed bi-level framework cannot be directly implemented in commercial solvers. To resolve this, by adding the KKT conditions of each follower problem, the lower-level problem (27)-(55) is converted into a single-level optimization problem. To solve the resulted single-level MISOCP problem by DSO, DSO has thorough knowledge of the required information pertaining to the MGs. Figure 3 briefly represents the decision-making process outlining the objectives, constraints of the bi-level problem and its transformation into a corresponding single-level MISOCP problem through KKT optimality conditions of the lower-level. The Lagrangian function and related derived KKT conditions of the lower-level problem can be calculated by (A1)-(A36) which are given in Appendix A. In this regard, the collection of non-equality constraints of the lower-level problem are rewritten as greater than or equal to zero constraints. Likewise, all equality constraints of the lower-level problem are rewritten as equal to zero constraints. Indeed, the resulted MISOCP problem is nonlinear because of the complimentary conditions from applying KKTs. To this end, the strong duality theorem is used in Appendix A to linearize the resulted MISOCP problem. In this regard, the collection of non-equality constraints of the lower-level problem are rewritten as greater than or equal to zero constraints. Likewise, all equality constraints of the lower-level problem are rewritten as equal to zero constraints. Indeed, the resulted MISOCP problem is nonlinear because of the complimentary conditions from applying KKTs. To this end, the strong duality theorem is used in Appendix A to linearize the resulted MISOCP problem.

Verification of Nash equilibrium
Generally speaking, a Nash equilibrium of a competitive system indicates that no player has incentive to change its decision. In order to verify that each final solution obtained from the transformed single-level MISOCP problem is a Nash equilibrium, a single-iteration diagonalization technique [28] is used. In this way, offered decision of other players are assumed to be constant which results to a single player problem. To this end, the multi-follower players in the proposed equilibrium problem are divided into MG N (the number of MGs) optimization problems. Optimization problem

Test and results
The bi-level formulation of the proposed model and the solution methodology were discussed in the previous sections. In this section, after introducing the test system, simulation results of the proposed bi-level day-ahead scheduling model are discussed.

Verification of Nash Equilibrium
Generally speaking, a Nash equilibrium of a competitive system indicates that no player has incentive to change its decision. In order to verify that each final solution obtained from the transformed single-level MISOCP problem is a Nash equilibrium, a single-iteration diagonalization technique [28] is used. In this way, offered decision of other players are assumed to be constant which results to a single player problem. To this end, the multi-follower players in the proposed equilibrium problem are divided into N MG (the number of MGs) optimization problems. Optimization problem of each MG is solved with regard to the fixed decision strategies of the rival players (i.e., other MGs). This process is repeated for all of the players. If the decision strategies resulted by diagonalization technique are identical to those obtained by MISOCP problem (i.e., no rival has a profitable unilateral deviation), then the proposed final solution is a Nash equilibrium.

Test and Results
The bi-level formulation of the proposed model and the solution methodology were discussed in the previous sections. In this section, after introducing the test system, simulation results of the proposed bi-level day-ahead scheduling model are discussed.

Case study
In this paper, the 84-bus 11.4 kV Taiwan power company distribution system [29], as shown in Figure 4, is considered as the test system. This system has three MGs which are interconnected through 13 tie lines. Moreover, it includes 11 feeders and 20 sectionalizing switches. It is assumed that similar type and size of MTs, PVs and ESSs are utilized in MGs with a sitting layout illustrated in Figure 4. All characteristics of DERs and other values for technical parameters are depicted in Table 1 [29]. The predicted values for PV output powers can be extracted from [30]. The support areas of DR programs for the corresponding MGs and their bid-quantity offer packages [31] are provided in Tables 2 and 3 [29].

Parameter
Value Parameter Value

Simulation results
In order to investigate the satisfactory performance of the proposed model, the problem is addressed in three different case studies. In Case Study 1 (CS1), the interaction of MGs based on the hourly reconfiguration through RCSs is studied, while no interconnection among MGs is considered in Case Study 2 (CS2). In both CS1 and CS2, MGs are equipped with DR programs and ESSs facilities, where MGs in Case Study 3 (CS3) are not possess any of them. In order to deeply evaluate these case As proposed in Reference [13], a seven-segment density function for a given normally distributed random variable with mean centred on zero and different STDs can be used to account for generated scenarios. Therefore, the same procedure is adopted for stochastic modelling of the output power of PV units, the wholesale market prices and the electrical load demand. The STD of the PV units' power, the wholesale market prices and the electrical load demand forecast errors are assumed to be ±10%, ±4% and ±2% of their hourly forecasted values, respectively. The Monte-Carlo simulation is performed using MATLAB 2016a and the proposed MISOCP optimization problem is formulated using the General Algebraic Modeling System (GAMS) language and solved by the CPLEX (24.1.2, GAMS Development Corporation, Fairfax, NV, USA) [32] solver.

Simulation results
In order to investigate the satisfactory performance of the proposed model, the problem is addressed in three different case studies. In Case Study 1 (CS1), the interaction of MGs based on the hourly reconfiguration through RCSs is studied, while no interconnection among MGs is considered in Case Study 2 (CS2). In both CS1 and CS2, MGs are equipped with DR programs and ESSs facilities, where MGs in Case Study 3 (CS3) are not possess any of them. In order to deeply evaluate these case studies, three different scenarios are considered in each case. The proposed wholesale market and retail prices in Figure 5b are considered as scenario 1, where 10% increment and decrement in these prices are defined as scenario 2 and scenario 3, respectively. Table 4 summarizes the above CSs and scenarios. The opened RCSs in reconfiguration process of multi-MG distribution system have been tailored in Table 5. By determining the proposed switching sequences at each hour, the optimal topology of the distribution system is resulted. As can be seen in all the final topologies in Table 5, the network radiality without any islanded buses is preserved, which meet constraints (20)- (23). Moreover, the maximum allowable number of switching actions constraint in the day, stated in (24), is met. Particularly, due to the excess power supply in MG1 and shortage power supply in MG3, RCS no. 84 has the most switching action among all the switches during the day. It is 5 times, which is less than the maximum allowable number of switching actions. Hourly operation scheduling of the MTs, DR programs and ESSs in CS1 for the defined three scenarios in MG1, MG2 and MG3 are shown in Figures 6-8, respectively. It can be seen that for scenario 2 in all three MGs, due to the increased retail and wholesale market prices, the amount of participated load in DR programs and MTs output power are increased. On the other hand, the amount of responsive loads and MTs output power are decreased in scenario 3.
Hourly operation scheduling of the MTs, DR programs and ESSs in CS1 for the defined three scenarios in MG1, MG2 and MG3 are shown in Figure 6, Figure 7 and Figure 8, respectively. It can be seen that for scenario 2 in all three MGs, due to the increased retail and wholesale market prices, the amount of participated load in DR programs and MTs output power are increased. On the other hand, the amount of responsive loads and MTs output power are decreased in scenario 3. Hourly operation scheduling of the MTs, DR programs and ESSs in CS1 for the defined three scenarios in MG1, MG2 and MG3 are shown in Figure 6, Figure 7 and Figure 8, respectively. It can be seen that for scenario 2 in all three MGs, due to the increased retail and wholesale market prices, the amount of participated load in DR programs and MTs output power are increased. On the other hand, the amount of responsive loads and MTs output power are decreased in scenario 3. As can be seen in Figure 6, Figure 7 and Figure 8, curtailable loads are participated in DR programs through the bid-quantity offer packages in peak load periods to flatten the demand curve. In all scenarios, ESSs tend to store power during the hours with low market prices and discharge (i.e., positive values in the figures) the stored power during the high market price periods. Figure 9a, shows the amount of exchanged power among MGs in different scenarios for CS1. Due to the lowload level condition and high penetration of MTs and PVs in MG1, for all scenarios, the power is transmitted from MG1 to MG2 and MG1 to MG3. The negative values represent the reverse power flow (e.g., negative power flow from MG2 to MG3 denotes a flow from MG3 to MG2). Due to the decrement of market prices in scenario 3, MG2 generates less power, thus, the transmitted power from MG1 to MG2 is increased by 6% compared to scenario 1. The amounts of exchanged power between DSO and MGs in different scenarios for CS1 to manage the excess or shortage of power supply in each MG are illustrated in Figure 9b. Based on the lower market prices at time 1:00-8:00 and 24:00, MGOs mainly purchase power from DSO in scenario 1 and scenario 3, while in other hours (i.e., 9:00-23:00), MG1 sells power to DSO. In contrast, in scenario 2 at time 8:00 and 24:00, MG1 sells power to DSO because of the higher wholesale market prices. Moreover, due to the lower wholesale market prices in scenario 3, the total amount of purchased power from DSO is increased by 5% and 8%, respectively in comparison with those in scenario1 and scenario 2. Figure 10 shows the amounts of exchanged power between each MG and DSO in CS2 for the three defined scenarios. Since no interconnection between MGs is considered in CS2, the power is not exchanged among MGs. This As can be seen in Figures 6-8, curtailable loads are participated in DR programs through the bid-quantity offer packages in peak load periods to flatten the demand curve. In all scenarios, ESSs tend to store power during the hours with low market prices and discharge (i.e., positive values in the figures) the stored power during the high market price periods. Figure 9a, shows the amount of exchanged power among MGs in different scenarios for CS1. Due to the low-load level condition and high penetration of MTs and PVs in MG1, for all scenarios, the power is transmitted from MG1 to MG2 and MG1 to MG3. The negative values represent the reverse power flow (e.g., negative power flow from MG2 to MG3 denotes a flow from MG3 to MG2). Due to the decrement of market prices in scenario 3, MG2 generates less power, thus, the transmitted power from MG1 to MG2 is increased by 6% compared to scenario 1. The amounts of exchanged power between DSO and MGs in different scenarios for CS1 to manage the excess or shortage of power supply in each MG are illustrated in Figure 9b. Based on the lower market prices at time 1:00-8:00 and 24:00, MGOs mainly purchase power from DSO in scenario 1 and scenario 3, while in other hours (i.e., 9:00-23:00), MG1 sells power to DSO. In contrast, in scenario 2 at time 8:00 and 24:00, MG1 sells power to DSO because of the higher wholesale market prices. Moreover, due to the lower wholesale market prices in scenario 3, the total amount of purchased power from DSO is increased by 5% and 8%, respectively in comparison with those in scenario1 and scenario 2. Figure 10 shows the amounts of exchanged power between each MG and DSO in CS2 for the three defined scenarios. Since no interconnection between MGs is considered in CS2, the power is not exchanged among MGs. This can also be deduced from Figure 10 where due to the higher wholesale market prices in scenario 2, the amount of purchased power from DSO is decreased by 3% and 5%, respectively. As a whole, in scenario 3, which reflects an operating condition with lower electricity prices, the MGOs prefer to supply more power from the DSO through participating in the market rather than internal energy trading among themselves. Thus, the expensive DERs are switched off in scenario 3 to ensure the economical operation of the distribution system. The amounts of exchanged power between each MG and DSO in CS3 for the three scenarios are shown in Figure 11. As can be seen, the amounts of purchased power from DSO to MG2 and MG3 are increased in peak load periods (i.e., 18:00-23:00) compared to CS2 and CS3. This is because there is no ESSs or DR programs in CS3 to supply power shortage. Figure 12 compares the technical and financial results between CS1, CS2 and CS3 under different scenarios. To get a better insight into this comparative study, the results related to the CS2 scenario 1 are considered as base values and treated as 1.00 per unit (p.u.). As can be seen, in the interconnected topology through the hourly reconfiguration the total loss of the distribution system is less than that of in CS2. Specifically, a reduction of 7%, 6% and 8% in total losses for scenario 1, scenario 2 and scenario 3 are achieved, respectively, which demonstrates the effect of hourly reconfiguration on loss reduction. Due to the increased power generations from DERs in scenario 2, the total loss in scenario 2 is less than that of scenario 1 and scenario 3 for both CSs. The responsive loads commitment in DR programs in scenario 2 is 27% and 38% more than those in scenario 1 and scenario 3, respectively for CS1. On the other hand, consumers' participation in DR actions for CS2 in scenario 2 is 21% and 29% more than those in scenario 1 and scenario 3, respectively. Hence, by utilization of hourly reconfiguration for interconnected topology of MGs in CS1, DR activities are increased by 4%, 11% and 2% in scenario 1, scenario 2 and scenario 3, respectively as compared to CS2. More importantly, the financial profit of MGOs in CS1 are more than those made in CS2 for all scenarios, which demonstrates the efficiency of the proposed interconnected MGs topology. Due to the hourly reconfiguration in CS1, the amounts of profit in scenario 1 are 1.04 p.u., 1.09 p.u. and 1.07 p.u. for MG1, MG2 and MG3, respectively, where these amounts are considered to be 1.00 p.u. for CS2. It is clearly observed from Figure 12 that by applying the hourly reconfiguration through interconnected MGs topology, significant decreases in total cost of distribution system could be achieved in different scenarios. Besides, the amounts of total loss, DR participation, profit of MGs and total costs are presented in Figure 12c. As can be seen, the amounts of losses and total costs are increased compared to CS1 and CS2. On the other hand, the profit of MGs is decreased significantly in different scenarios, which shows the effectiveness of DR programs and ESSs implementation. Through the proposed checking mechanism in Section 3.3, it is verified that the final solutions obtained by the MISOCP problem are Nash equilibrium. For example, for the optimization problem related to the MG1 (MGO2 and MGO3 are considered as fixed decision makers), the profit of MGO1 is 1.04 p.u. and 1 p.u., respectively for CS1 and CS2 in scenario 1, which are consistent with the results shown in Figure 12.
in different scenarios, which shows the effectiveness of DR programs and ESSs implementation. Through the proposed checking mechanism in Section 3.3, it is verified that the final solutions obtained by the MISOCP problem are Nash equilibrium. For example, for the optimization problem related to the MG1 (MGO2 and MGO3 are considered as fixed decision makers), the profit of MGO1 is 1.04 p.u. and 1 p.u., respectively for CS1 and CS2 in scenario 1, which are consistent with the results shown in Figure 12.  Through the proposed checking mechanism in Section 3.3, it is verified that the final solutions obtained by the MISOCP problem are Nash equilibrium. For example, for the optimization problem related to the MG1 (MGO2 and MGO3 are considered as fixed decision makers), the profit of MGO1 is 1.04 p.u. and 1 p.u., respectively for CS1 and CS2 in scenario 1, which are consistent with the results shown in Figure 12.    Total load profile of the system after load participation in DR program is shown in Figure 13. It can be seen that RLs are participated in DR programs through the bid-quantity offer packages in peak load periods to flatten the demand curve. Due to the increased retail and wholesale market prices in scenario 2, the amount of participated load in DR programs is increased. Particularly, the peak load has been decreased from 34.2 MW to 29.9 MW, 29.7 MW and 30.7 MW for scenario 1, scenario 2 and scenario 3, respectively. Total load profile of the system after load participation in DR program is shown in Figure 13. It can be seen that RLs are participated in DR programs through the bid-quantity offer packages in peak load periods to flatten the demand curve. Due to the increased retail and wholesale market prices in scenario 2, the amount of participated load in DR programs is increased. Particularly, the peak load has been decreased from 34.2 MW to 29.9 MW, 29.7 MW and 30.7 MW for scenario 1, scenario 2 and scenario 3, respectively. From the voltage-security point of view, Figure 14 shows the maximum voltage deviation of busses from 1.00 p.u. for CS1, CS2 and CS3 in three defined scenarios. Due to the higher wholesale market prices and increased power generations from DERs in scenario 2, better bus voltages are achieved. It can be seen that hourly reconfiguration through the interconnected MGs, DR From the voltage-security point of view, Figure 14 shows the maximum voltage deviation of busses from 1.00 p.u. for CS1, CS2 and CS3 in three defined scenarios. Due to the higher wholesale market prices and increased power generations from DERs in scenario 2, better bus voltages are achieved. It can be seen that hourly reconfiguration through the interconnected MGs, DR participation and ESSs implementation in CS1 causes better results for bus voltages during the 24h time horizon in all scenarios. Besides, all bus voltages are regulated within their allowable 0.05 p.u. ranges. From the voltage-security point of view, Figure 14 shows the maximum voltage deviation of busses from 1.00 p.u. for CS1, CS2 and CS3 in three defined scenarios. Due to the higher wholesale market prices and increased power generations from DERs in scenario 2, better bus voltages are achieved. It can be seen that hourly reconfiguration through the interconnected MGs, DR participation and ESSs implementation in CS1 causes better results for bus voltages during the 24h time horizon in all scenarios. Besides, all bus voltages are regulated within their allowable 0.05 p.u. ranges.

Conclusion
In this paper, the problem of optimal day-ahead scheduling of reconfigurable multi-MG distribution system considering demand response programs and ESSs in an uncertain environment was investigated. Due to participation of multi-players including DSO and multi-MGs with inherently conflicting objectives in the framework, a one-leader multi-follower-type bi-level optimization model was developed to embody DSO-MGOs gaming strategy. The proposed decisionmaking model sought to minimize the DSO's total operation cost as the upper-level problem taking into account maximizing the profit of each MG as the lower-level problem. Decision maker was affected not only by the exchanged power between DSO and MGOs as a mutual decision variable but also by the interactions of the interconnected MGs in an hourly reconfigurable topology. KKT optimality conditions and linearization techniques were used to transform the proposed non-linear bi-level optimization problem into a single-level MISOCP problem. The performance of the proposed

Conclusions
In this paper, the problem of optimal day-ahead scheduling of reconfigurable multi-MG distribution system considering demand response programs and ESSs in an uncertain environment was investigated. Due to participation of multi-players including DSO and multi-MGs with inherently conflicting objectives in the framework, a one-leader multi-follower-type bi-level optimization model was developed to embody DSO-MGOs gaming strategy. The proposed decision-making model sought to minimize the DSO's total operation cost as the upper-level problem taking into account maximizing the profit of each MG as the lower-level problem. Decision maker was affected not only by the exchanged power between DSO and MGOs as a mutual decision variable but also by the interactions of the interconnected MGs in an hourly reconfigurable topology. KKT optimality conditions and linearization techniques were used to transform the proposed non-linear bi-level optimization problem into a single-level MISOCP problem. The performance of the proposed model was investigated on the 84-bus Taiwan power company distribution system. The simulation results revealed that in conditions where the market prices are relatively higher, MGOs prefer to dispatch first their distributed energy resources including micro turbines, PVs and responsive loads and then exchange power with the interconnected MGs and DSO. However, when the market prices are lower, MGOs prefer to trade energy with DSO. Moreover, it was shown that by implementing hourly reconfiguration through interconnected MGs, the total power losses, the maximum voltage deviation of buses, participation in demand response programs, MGOs' profit and the total system cost could be improved significantly.

Conflicts of Interest:
The authors declare no conflict of interest.

Appendix A
To calculate the KKT conditions of the follower problem, all non-equality constraints of the lower-level problem can be rewritten as greater than or equal to zero constraints proposed in (A1)-(A24). Similarly, the collection of equality constraints of the lower-level are rewritten as equal to zero constraints (A25)-(A28).

Nomenclature
Parameters y i Admittance between bus i and ground.      Greater than or equal to zero constraints.

L p
Lagrangian function of pth lower-level problem related to MG p. α