**1. Introduction**

As the energy crisis becomes more serious, renewable distributed power sources, such as wind power and photovoltaics have gradually been developed, and microgrids are attracting further attention [1]. A microgrid is a small power generation and distribution system that integrates distributed power sources, energy storage devices, loads, and protection devices, and with the characteristics of flexible, reliable and safe power supply [2].

In order to use all kinds of energy reasonably and effectively, the microgrid energy scheduling meets certain constraints and load demands, and rationally dispatch energy and energy storage devices, which can effectively reduce operating costs and improve environmental benefits [3]. The energy dispatch of the microgrid is a key content in the related research problems of the microgrid. The factors considered in the dispatch model will affect the final dispatch result. Its purpose is to reasonably allocate the various loads under the premise of meeting the normal demand of all loads [4]. The output of the unit minimizes the total operating cost of the microgrid, thereby achieving the best economic benefits [5]. Dey et al. [6] studied the economic dispatch of a grid-connected renewable integrated microgrid system. Yuan et al. [7] proposed an energy managemen<sup>t</sup> strategy based on hybrid prediction for the data interruption. Xin Li, et al. [8] considered that the microgrid environment/economic dispatch is a complex multi-objective optimization problem and reduced specific requirements for algorithm performance. Tiaan et al. [9] studied a multi-objective optimization model for multi-microgrid systems, which can not only minimize operating costs, but also reduce emissions.

Most of these papers use a static optimization scheduling model that aim to minimize the operation cost of the microgrid. Since the research on the economic optimal scheduling of the microgrid focuses on the operating economy after the system is built, the construction investment cost of the microgrid are not considered in most models, and the correlation between each time period is usually ignored. Each time period is independently optomised [10]. Compared with traditional power grids, the optimal dispatch of microgrids is more complicated, and traditional optimization methods cannot achieve optimal dispatch results. Various optimization methods based on artificial intelligence have the characteristics of fast convergence speed and not easy to fall into the local optimum. These optimization methods mainly include: Genetic Algorithm (GA) [11,12], PSO [13], and GWO [14]. However, GA and PSO also have their own disadvantages. The non-directional mutation of GA is its basic disadvantage. Likewise the convergence speed of PSO is not fast enough. In addition, the diversity of PSO is not enough, and it takes a long time to adjust the parameters in the optimization strategy. This paper uses PSO and GWO to compare and verify the e ffectiveness and accuracy of GWO in optimal scheduling. Naderi et al. [15] used fuzzy based hybrid PSO-DE to perform multi-objective economic emission dispatch on 10, 40 and 160 unit systems consider power loss, ramp rate, prohibited operating zones and valve point e ffects. In [16], a new multi-objective GWO for Optimal Reactive Power Dispatch (MORPD) is studied, which minimizes voltage deviation and active power loss (http://hainan.weather.com.cn/skjc/index.shtml).

Although a lot of work has been done in the above research on optimal dispatch of microgrid systems, none has studied dynamic optimal dispatch in conjunction with GWO. Instead, they use other intelligent algorithms to solve the optimization problem or study the static optimal dispatch of the microgrid. This paper proposes a new technology that combines dynamic optimal dispatch and GWO to achieve symmetry between the lowest operating cost of microgrid system and coordinated control of various devices. In addition, the proposed GWO is compared with the classic PSO to prove the e ffectiveness of the proposed method for dynamic optimal scheduling of microgrid systems. The comparison clearly shows that GWO has better performance, and has very fast convergence and balance in system optimization, which can avoid local optimization. The case study in this paper takes the Sanya region of China as an example. The region has 2534 h of sunshine throughout the year and has su fficient light.

The rest of this paper is organized as follows: The mathematical modeling of the microgrid components is elaborated in Section 2. The establishment of the objective function is described in Section 3. The constraints in the system are described in Section 4. In Section 5, the strategy of dynamic optimization scheduling for the system is outlined, and the GWO is introduced. Finally, the simulation results of the case study are presented and analyzed.
