Dual-Layer Optimal Dispatching Strategy for Microgrid Energy Management Systems considering Demand Response

The continuous development of microgrid’s technology creates favorable conditions for the access of distributed energy. Firstly, in order to consider the interests of the demand side and the power side, this paper presents a dual-layer optimal dispatching model of microgrid based on demand response. The objective of the first-layer optimization is to obtain the maximum load satisfaction and to optimize the load curve. The objective of the second-layer optimization is to make the microgrid system economical and environmentally friendly and to optimize the power utilization ratio. And a microsource control strategy based on the isolated microgrid is proposed, which can optimize the operation state of battery and improve the economy of the system. Finally, the Nondominated Sorting Genetic Algorithm-II (NSGA-II) is adopted to solve the optimal scheduling problem of the isolated microgrid. The simulation results indicate that the microsource scheduling strategy proposed in this paper can improve the operation economy and environmental conservation of the system. It can improve the reliability of microgrid power supply and reduce energy waste.


Introduction
The rational allocation of microsource output plays an important role in ensuring the safe and stable operation of microgrids and improving economic efficiency.It is significant to research on optimization in microgrid energy management.The microgrid energy management system (MGEMS) can coordinate distributed generators, storage battery, and load in the microgrid through the information such as the load demand forecasting.MGEMS not only ensures the security and stability of the microgrid system, but also realizes the economic optimal operation of the microgrid [1].Therefore, the microgrid modelling, optimization algorithms, and scheduling strategies should be deeply researched to achieve the optimal economic dispatching for energy management and improve the operation efficiency of the microgrid.
For microgrid operation, many studies focus on minimizing the operation cost by scheduling different power generation units, which regard the objective function as the prerequisite for the economic operation of microgrid.At present, the study of optimization of the microgrid operation mainly considers its economy and environmental protection including initial investment cost, operation and maintenance cost, sales income of power, government subsidy, and environment benefit.Guo et al. [2] proposed a multiobjective optimization model for isolated microgrid system, which aimed at the confliction of interests between the distribution company and the distributed generation owners in the isolated microgrid system.The economic scheduling objective function in [3,4] considered the operation costs, environmental pollution of the power system, and the equipment type, while Chen et al. [5] also considered the extra cost of battery.Chen et al. [6] proposed that the economic scheduling problem of isolated microgrid for reducing the total cost of distributed generators and satisfying the demand and supply constraints.Trivedi et al. [7] adopted the whale optimization algorithm to obtain the minimum operation cost and total pollution emissions.Alanazi studied the influence of high penetrability wind energy on the economical and reliable operation of microgrid in reducing the power transmission fluctuation of microgrid [8].A multiobjective optimal scheduling model is proposed based on the opportunity constraint planning of microgrid, and the uncertainty of renewable energy and load is taken into account [9].
The optimal scheduling strategies of microgrid play a crucial role in the scheduling optimization.In [10], a two-stage optimal scheduling method is proposed to solve the problem of optimal scheduling of the microgrid system with the combination of cooling, heat, and power.Duong Tran et al. proposed an economic dispatch method of the microgrid based on time-of-use pricing with coordinating the electricity price and battery charge-discharge management, which adopted the batteries for energy storage to achieve peak shaving during peak period [11].Duong Tran proposed an energy management system for the battery; the stochastic dynamic programming method is employed to deal with the forecast data to improve the battery life cycle [12].For the operation characteristics of microgrid, Bie et al. [13] proposed the reliability model of virtual power supply to realize the reliability evaluation of the distribution system with multiple microgrids.Some intelligent optimization algorithms help us better optimizing the economic operation cost of the microgrid, such as genetic algorithm, particle swarm optimization algorithm, ant colony algorithm, and differential evolution algorithm [14][15][16].Mohammadi proposed an improved adaptive firefly algorithm to solve the problem of microgrid economy optimization with establishing the operation mathematical model of microgrid [17].In [4], the K-means clustering method is used to minimize the objectives of economic and environmental during the three stages, and the use of the K-means algorithm reduced the computational time.In this paper, the NSGA-II algorithm with elite retention strategy is used to solve the multiobjective optimization model of microgrid; the algorithm can deal with the multiobjective problem efficiently.
At present, most of the researches on microgrid energy management system are single preday scheduling, which can not completely reflect the randomness of new energy generation, and the optimization results may not accord with the actual operation status of microgrid.Most of the researches based on the economic optimization of demand side microgrid only consider the charge and discharge problem of storage battery or the load but do not consider the influence of both.In order to solve the above problems, this paper puts forward a dual-layer optimal dispatching strategy based on the demand side for the independent microgrid system.The simulation results show that under the premise of considering the load satisfaction on the demand side and the influence of battery, using the dual-layer optimal dispatching strategy of microgrid proposed in this paper, the economic, environmental protection and electric energy utilization ratio of the microgrid system can reach an optimal state.The major contributions and innovations of this paper are displayed as follows: (1) A dual-layer optimal dispatching strategy of microgrid is proposed.The first-layer adjusts the load according to the microsource forecast power, adjusts the load output curve according to the load satisfaction, and inputs the corresponding load curve to the second layer.
(2) The optimal operation of the microgrid is a multiobjective optimization problem, and the operation of microgrid cannot be completely described by only single objective.Therefore, the multiobjective optimization algorithm is adopted in the second-layer optimization, and the three-target model of the economy, environmental protection, and power utilization rate of the microgrid system is established.
(3) The battery charge and discharge strategy is introduced in the algorithm, which can reasonably dispatch batteries and microgas turbines and can improve the utilization ratio of new energy.
(4) The current research neglects the diversity of user side and does not fully exploit the potential of user participation in scheduling.In this paper, based on the demand response, the microgrid energy optimization strategy is proposed to realize the economic and environmental optimization under the premise of user satisfaction and make the renewable energy to be used optimally, thus realizing the global optimization of the microgrid.
The remainder of this paper is organized as follows.Section 2 presents the system description.The optimization strategy of the microgrid is introduced in Section 3. The optimization model solving algorithm and the simulation results are introduced in Sections 4 and 5, respectively.The conclusions are presented in Section 6.

System Description
In this paper, the microsources of the microgrid system contain wind generators, photovoltaics, microgas turbines, and batteries.Due to the randomness of wind power and photovoltaic power generation, the microsource cannot provide stable output power; in order to solve the problem, we add the microgas turbine power generation as a supplementary power with less emission.The reasonable dispatching of microgas turbine and battery can make the utilization of new energy reach the highest and adopting the reasonable charging-discharging strategy to prolong the life cycle of battery is also the key to solve the reliability of microgrid.The microgrid structure diagram is shown in Figure 1.

Wind Generator Model.
The wind speed-power characteristic curves of wind generator can be obtained by polynomial fitting, which can be expressed as [17] where P WT is wind generator output active power; P r is the rated power of wind generator; v ci , v r , and v co are wind generator cut-in wind speed, rated wind speed, and cutout wind speed, respectively; a, b, c, and d are wind speed parameters, respectively.The environmental parameter correction model is shown as below.
The wind speed varies with the height, and the wind speed-power curve needs to provide the wind speed at the hub height of the wind generator, which needs to be converted to the wind speed at the wind generator hub.The conversion formula is shown as where v 1 and v 2 are the wind speed at different heights; H 1 and H 2 represent different heights, respectively;  is a powerlaw exponent, which is related to the roughness of the ground.

Photovoltaic Model.
In the optimal scheduling of microgrid, it needs to forecast the power of photovoltaic cell.The power output model of the photovoltaic cell is shown as [18] where P PV is the output active power of the photovoltaic cell; Y PV is the output power of photovoltaic cells in the standard test conditions; f PV is PV derating factor, usually 0.8; G T is the solar irradiation intensity of the current step in actual environment; G T,STC is the solar radiation intensity under standard test conditions;  P is the power temperature coefficient of the PV panel; T c is the photovoltaic cell temperature of the current time step; T c,STC is the photovoltaic cell temperature under the standard test condition, usually 25.
The PV cell temperature is the temperature of the PV array surface, which is the same as the ambient temperature and is higher than the ambient temperature during the day.According to the principle of energy conservation, the photovoltaic cell temperature model can be expressed as where T a is the ambient temperature;  is the solar absorption of photovoltaic panels;  is the solar transmittance; U L is the heat dissipation factor;  c is the photovoltaic conversion efficiency of photovoltaic cells.

Battery Model.
As the energy storage equipment, the battery will release the stored energy during the lack of renewable energy, and it provides stable power supply to users to guarantee the safe and stable operation of the system.
In the optimal scheduling of microgrid, the chargingdischarging power of the battery is limited by the total residual energy, and in the time step of Δt, the maximum charging-discharging power of the battery determined by the total remaining energy of the battery can be expressed as where k is the charging-discharging ratio constant; it reflects the energy of the binding energy and available energy in the battery; Δt is the simulation step; c is the capacity ratio constant; P batt,dmax and P batt,cmax are the maximum charge power and discharge power of battery determined by the total remaining energy of the battery respectively; Q is the total energy at any time; Q 1 is the available energy; and Q 2 is the bound energy.
The relationship between the state of charge (SOC) and the charge-discharge power of the battery (P batt ) is expressed as follows [19]: where  batt is the self-discharge efficiency of the battery; P batt is the charge-discharge power of the battery;  batt,c and  batt,d are the charge and discharge efficiency of the battery, respectively (90%); Δt is the charge-discharge time; E batt is the rated capacity of the battery.efficiency of the microgas turbine is related to the output power of its output [20]:

Microgas Turbine
where P MT is the active output power of the microgas turbine;  MT is the operational efficiency of microgas turbines.

Load Model.
For the isolated microgrid system, the load can be divided into the important load power and the interruptible load and the transferable load according to the importance degree, in which the noninterruptible loads are some basic electrical equipment, and the interruptible loads are some alternative electric or recreational equipment.Due to the limitation of power capacity and the intermittence of the renewable energy power generation for the isolated microgrid, it is difficult to ensure the real-time power balance in the microgrid only through the power generation side scheduling.There will be insufficient power supply at some periods, so the supply of part of the loads has to be interrupted.By determining the interruptible load in advance to ensure the continuous and stable operation of the microgrid, it is advantageous to ensure the safety and rationality of the load cutting operation.The load model is expressed as follows: where P L , P L im , P L in , and P tran are the daily demand load power of users, the important load power, the load power, and the transferable load power, respectively; P net-load is the power of the net load.

Optimization Strategy
Modern power system should pay more attention to the user's feelings, due to the difference between the optimal objective and the optimal variable; the solution speed, accuracy, and the effect for current optimization of microgrid are not very ideal.
In order to consider the comfort of user side comprehensively, the dual-layer scheduling strategy is designed in this paper.The objective of first-layer optimization is to obtain the maximum load satisfaction by considering from the load side, and then the user adjusts the controllable load according to the optimization results; the new load curve will be as the input of the second layer.On the premise of guaranteeing the reliability of the microgrid system, the second-layer optimization dispatches the microgas turbine and battery according to the new load curve and the predictive power of the wind generator, the photovoltaic power, and the objective of the second layer is to optimize the economy, environmentprotective, and the utilization of electricity of microgrid.
The optimal solution set of Pareto is obtained by adopting the optimization algorithm NSGA-II for multiobjective and introducing method of fuzzy model recognition and then selecting an optimal compromise solution from the Pareto optimal solution set according to the actual situation.The dual-layer scheduling strategy model can better coordinate the interests of different stakeholders in the microgrid and formulate a reasonable optimal operation scheme for microgrid to coordinate the user side and power side.The scheduling strategy of the microgrid system is given in Figure 2.
For electricity load as the management object of user side, it is necessary to adopt different scheduling strategy in the process of management according to the characteristics of load power consumption.Some of the loads will cause a great economic impact and even endanger personal safety after power failure and therefore microgrid system should give priority to ensure the sustainable supply of such loads.The optimal scheduling strategy for each microsource is as follows: the flowchart is given in Figure 3: (1) To determine the power relationship of power load and the battery.
(2) When the battery is sufficient to supply power to the net load, the microgas turbine is not running.
(3) When the battery is not enough to supply power to the net load, the microgas turbine is turned on, and when the microgas turbine and the battery cannot meet the load demand, then cut off the unimportant load.
(4) When the load demand is not very large, cut off part of the wind generator.
In this paper, the fluctuation of the output of the renewable energy unit can be alleviated by the transfer of electric energy through the cycle charge and discharge of the battery.By placing user side and load on the same layer, the two can be fully coordinated to improve the net load shape.The flowchart of the battery charge-discharge management is shown in Figure 4.

The First-Layer Optimal Model of Microgrid System.
Adopting certain measures of demand side management in microgrid is conducive to improving the reliability of microgrid operation and the utilization of new energy power generation [21].In order to improve the economy of microgrid operation from the perspective of load management, this paper introduces the concept of load satisfaction into the energy management of isolated microgrid to satisfy the load demand as much as possible.The original load curve is adjusted and the some periods of unimportant load are transferred by guiding users to use electricity rationally, so as to improve the utilization ratio of renewable energy.The optimization index is as follows: where P total is the total power supply of the system.

Objective Function
(i) Economy.In islanding mode, the objective of microgrid optimal scheduling is to obtain the minimum operation and maintenance cost.The cost of operation and maintenance include four parts: maintenance cost, fuel cost, battery wastage cost, and interruption cost.Maintenance costs are mainly concerned with the wind turbines, photovoltaic cells, and microgas turbines.When the power supply is insufficient, part load must be cut off and the objective function needs to consider the interruption cost.
where K is the maintenance factor of generating unit; F MT-i is the fuel cost of the microgas turbine at the ith hour; Q lifetime is the output energy of battery life cycle; P loadloss-i is the power of the resected load, due to insufficient power supply;  is the economic losses of resected unit load due to insufficient supply of electricity; W is the battery purchase cost.
(ii) Pollution Emission where K  is the pollution emission coefficient; C  is the cost of sewage disposal; P G-i is output power of generating unit.
(iii) The Utilization of Electricity.The highest utilization rate of electric energy is the lowest energy waste rate.
where ΔP i > 0. The optimization index of the microgrid is as follows: where ΔP i ≤ 0 and  is the load loss rate.

Optimal Variables.
In the island operating mode, the microgrid is not connected with the power grid.The optimal variables in this paper include the charging-discharging power and microgas turbine output power of 24 hours a day.

Constraints of the Microgrid System
(i) The Energy Balance Constraints.Microgrid system needs to ensure the power balance between power supply and power consumption.It is defined as where P PV-i , P WT-i , P batt-i , P MT-i , and P L-i are the power of photovoltaic, wind generator, battery, microgas turbine, and the load, respectively.
(ii) Generation Capacity Constraints.In order to maintain the stability of the operation, the actual output power of each generator has a strict upper and lower bound: (iii) Charge Constraint of Energy Storage Battery Charge-Discharge Power.In the battery work process, with the increase of the depth of the discharge, the loss of the battery increases and the life of the battery is shortened accordingly.So the battery should run in a certain range of charge: (iv) Transferable Load Constraints.The constraints required for transferable load include load power range constraints and load required power invariant constraints: 24 where P tran-i is the power of transferable load; P tran,min and P tran,max are the upper and lower limits of power for the allowable transfer load; W tran is the total amount of electricity needed in the scheduling cycle.conflict between subobjectives.The traditional algorithm is difficult to take into account the relationship between multiple objectives when there are huge differences in target types.Therefore, faced with the multiobjective optimization problem, this paper adopts the NSGA-II intelligent algorithms with elite strategy for solving, to find the Pareto solutions.The NSGA-II algorithm has such advantage as good robustness and can obtain nondominant sets with uniform distribution and good diversity.The multiobjective optimization problem is solved by NSGA-II, which avoids the problem of weight assignment, and it can deal with a variety of multidimensional complex planning problems; the application scope and space of the algorithm are wide.As long as the problem is accurately described in the algorithm, the algorithm can be optimized according to the evolutionary rule, and the optimal solution is obtained, no matter how complex the solution is.And how complicated the problem is, it will not affect the convergence direction and robustness of the algorithm.The strategy of fast nondominating sorting accelerates the speed of the algorithm, while the elitist strategy avoids the loss of the optimal solution and also extends the distribution range of the solution set in the Pareto optimal frontier to ensure the diversity of the population [22][23][24].
The algorithm used in this paper is as follows.
Step 1. Establish the initial population according to the wind turbine, photovoltaic and the predictive power.
The real number coding is used, and the battery power P bat-i and the microgas turbine power P MT-i are taken as the optimal variables.The chromosome coding diagram is shown in Figure 5, in which the value of P 1 -P 24 is controlled between -21.1973 and 159.727; the value of P 25 -P 48 is controlled between 0 and 2000.
Step 3. Set the population size and the number of objective functions and generate the initial population P 0 according to the microsource scheduling strategy.
Step 4. Sort out the population based on the nondomination and calculate the crowding distance of the population, in which the nondominated sorting which is based on the three objective function values includes the cost of power system, the pollution emission penalty cost, and the reliability index; the crowding distance is obtained from the distance information of the individual vector variable in the variable space.
Step 5 (genetic operation).Select cross and mutation, and then get the subpopulation.
Step 6 (elitist reservation strategy).Combine the offspring with the parent, select the N optimal individuals according to the nondominance sorting and crowding distance, and create a new population.
Step 7.For the number of iterations plus 1, return to Step 4, until the maximum number of iterations is reached.
The flowchart of optimization algorithm for the optimization model of microgrid system in this paper is shown as Figure 6.
The above constraint tournament criterion enables the NSGA-II algorithm to solve the interval constraints.NSGA-II uses binary competition selection processing constraints; that is, two solutions in the population are selected and the better solution is selected.
The binding tournament criteria used in this paper are defined as follows: (1) When x 1 is a feasible solution and x 2 is an infeasible solution, then x 1 is considered to be the dominant individual.
(2) When x 1 and x 2 are both infeasible solutions, the degree of constraint violation is compared, and the individual with small degree of constraint violation is dominant.
(3) When the volumes x 1 and x 2 are both feasible solutions, the order value and interval crowding distance between them are compared.The individual with small order value is dominant, and the individual with large interval crowding distance is superior if the order value is the same.
The optimal solution set of Pareto is obtained by using NSGA-II algorithm.In this paper, a fuzzy model recognition method is used to select a suitable compromise solution which conforms to the actual operation situation from the optimal solution set in Pareto [25].Firstly, the membership vector of noninferior solution is obtained and then combined with the important degree of each objective in the actual situation, according to the fuzzy tone operator to get the object weight vector.Finally, calculate the proximity of each noninferiority membership degree vector to the object weight vector, select the best closeness degree of membership vector, and the corresponding noninferior solution is the optimal compromise solution to be chosen.
The objective membership degree formula of each particle is described as where A i,m and f i,m are the membership degree and the actual value of the mth target of the ith particle, respectively; f m,max and f m,min are the maximum and minimum values of the mth target, respectively.

Simulation
This study takes a microgrid system including wind turbine, photovoltaic, microgas turbine, and battery as an example.The installed capacity is 1000kW photovoltaic cell, 1650kW wind generator, 530kW lithium battery, and 10 × 250kW microgas turbine.The parameters of each distributed energy resource (DER) are shown in Table 1.The emission parameters of the unit are shown in Table 2, and the simulation parameters of the battery are shown in Table 3.On the Matlab 2014 platform, NSGA-II is applied to solve the model of dual-layer optimal dispatching strategy for microgrid energy management system.The population size is 50, and the cycle number is 200.Genetic manipulation parameters: the crossover rate is 0.8, and the variation rate is 0.05.The curve of radiation intensity and the curve of wind speed at the wheel hub of wind turbine are shown in Figures 7  and 8, respectively.The three-dimensional Pareto solution set as shown in Figure 9 is obtained through simulation; the  number of nondominated solutions is 50.The load curve before and after demand response as shown in Figure 10 shows that the load transfer is an important management measure of load, which has fast response speed and can effectively mobilize the interactive enthusiasm of the user to participate in the optimal dispatching for microgrid.The participation of users can improve the economy of microgrid operation effectively.
Figures 11 and 12 are Pareto front diagram for each two objective functions of the three objective function, and the output of each microsource is shown in Figures 13 and 14.Table 4 lists three groups of extreme solutions in the Pareto solution sets, including the minimum operating cost, the least pollution emission, and the highest reliability, and it also lists the optimal compromise solution by using the fuzzy model recognition method.The analysis of the simulation results show that the relationship between the various goals is mutually binding.The optimality of a goal must be at the expense of the optimization of the other two goals.For instance, to achieve the optimal economy, the corresponding operation and maintenance cost is $265.89,but the pollution emissions and energy waste rate reached 49.76kg and 0.532.It can also be seen from Table 4 that the generation cost and pollution emission in the day after the optimal of compromise   solution is slightly higher than the minimum generation cost and the lowest environmental cost, while the environmental costs that are aiming at the lowest environmental costs and the lowest ones are lower than the minimum and the lowest environmental costs.The choice of the optimal compromise solution is well coordinated economic, environmental, and energy wastage among the three balances.
For further processing of the data, Table 5 gives the comparison of the indicators before and after the demand response.According to Table 5 the operation and maintenance cost of microgrid is $724.91 before the application of   dual-layer optimal dispatching strategy for microgrid energy management system based on demand side response, which is much higher than the operation and maintenance cost after demand response.At the same time, using the optimal strategy proposed in this paper, the environment-protective and reliability of the microgrid are all improved, and the optimization effect is good.The dual-layer optimal strategy proposed in this paper takes into account the benefits of microgrid operators and users.The power supply system of microgrid has better power supply qualities and takes account of environmental protection and renewable energy utilization.It realizes the economic dispatch and rational utilization of distributed generation.
In addition, the optimal allocation of microgrid energy management system in different seasons is shown in Figure 15.Take typical days as an example; run the program twenty times to get statistical analysis results as shown in Table 6.The NSGA-II has good robustness and convergence performance in dealing with large-scale nonlinear complex programming problems.The study shows that the NSGA-II is of great significance for improving the reliability of power supply, reducing the cost, and reducing the energy waste.In summary, the multiobjective optimization model proposed in this paper can accurately reflect the actual operation of microgrid.The model can achieve better environmental protection effect and good renewable energy utilization rate with small economic cost as small as possible and realize energy saving and environmental protection power generation scheduling.

Conclusions
In this paper, a microsource model of wind power, photovoltaic, microgas turbines, and energy storage devices is firstly established, and then the dual-layer optimization model of microgrid energy considering demand response is set up.With the objective of minimizing the operation cost of microgrid and the pollution emission and maximizing the load satisfaction and the reliability, the NSGA-II is used to obtain the optimal solution of Pareto.The methods and steps of the solution are discussed in detail.Finally, the fuzzy model recognition method is adopted to make the decision of the optimal compromise solution.The simulation results show that the dual-layer optimal dispatching model of microgrid energy considering the load satisfaction can take full account of the users.On the one hand, it solves the problem of multiple optimal variables in the optimal operation of microgrid.On the other hand, it is beneficial to coordinate the user side and the power side and greatly reduce the operation loss of the system, thereby reducing the operation cost and improving the reliability of the isolated microgrid.The dual-layer optimal dispatching model is suitable for coordinating the interests of different individuals with different objectives and different decision variables, fully exploiting the potential of user side to participate in the optimization of microgrid operation, and achieving global optimization.The system reliability index measures the power supply quality and ensures the power supply reliability, and the energy management and control strategy of microgrid for the isolated microgrid can make full use of microgrid power capacity, coordinate the start, stop and output between distributed power sources, and realize the economic operation of the system.

Mathematical Problems in Engineering 13
In future work, the optimal allocation of the microgrid energy in different seasons, weather, and regions can be considered.

Figure 2 :
Figure 2: The system structure diagram of the dual-layer optimization strategy for microgrid.

Figure 3 :
Figure 3: The flowchart of optimal scheduling strategy for microsource.

⩽Figure 4 :
Figure 4: The flowchart of the battery charge-discharge management.

Figure 6 :
Figure 6: The flowchart of optimization algorithm for isolated microgrid system.

Figure 8 :
Figure 8: The curve of wind speed at the wheel hub of wind turbine.

Figure 9 :
Figure 9: The Pareto frontier of optimal dispatching results.

Figure 10 :
Figure 10: The load curve of demand response.

Figure 13 :
Figure 13: Output power of renewable energy.

Figure 15 :
Figure 15: Optimal allocation of energy system for microgrids in different seasons.
)Figure7: The curve of radiation intensity.

Table 2 :
Pollution conversion costs and emission factors.

Table 3 :
Simulation parameters of storage battery.

Table 4 :
Typical solution of Pareto solution.

Table 5 :
Each index value of microgrid.

Table 6 :
Statistical results obtained by NSGA-II for microgrid system of typical day.