Power Capacity Optimization in a Photovoltaics-Based Microgrid Using the Improved Artificial Bee Colony Algorithm

: Although the combined cooling, heating and power (CCHP) microgrid is feasible for achieving a high energy utilization efficiency, the fluctuation of energy sources, such as a photovoltaic system and multiple loads, may affect the safety, economics and stability in CCHP microgrid operation. For this reason, this paper establishes a mathematical model using a multi-objective optimization mechanism for resolving the inﬂuence of economy and energy allocation in the mixed photovoltaic type CCHP microgrid. It is based on analytic hierarchy process (AHP) to determine the individual weight of objective function optimization for the multi-objective power capacity allocation. The improved artiﬁcial bee colony (IABC) based on the whale search and dynamic selection probability can achieve an optimization solution, reaching a stable operation state and reasonable capacity conﬁguration in the microgrid system. The performance results conﬁrm that the proposed algorithm is superior to others in both convergence speed and accuracyfor the capacity allocation of the CCHP microgrid.


Introduction
With the environmental aggravation and energy shortage in the world, distributed generation (DG) using renewable energy has been attracting extensive attention in recent years. However, renewable energy has inherent volatility and intermittency. To resolve this problem, the microgrid system combined with large power grids has been developed to be faster than before. For example, a combined cooling, heating and power (CCHP) type microgrid allows users to determine the system structure and power capacity [1]. Therefore, it is of great significance to optimize the capacity of the CCHP microgrid to be more economical, safe and reliable, and have more environmental friendliness and energy conservation.
A CCHP microgrid operation optimization model for wind-generated energy was established by taking the minimum total operating cost in the objective function [2]. However, it requires a complicated calculation with a long computation time due to the mixed integer programming process. In [3], a CCHP mathematical model was developed by adopting the improved particle swarm optimization algorithm. The objective of minimizing the operation cost was achieved under the computational simulation. Although the above two methods satisfied the economic optimum, both environmental and energy issues were not fully taken account of. In [4], a hybrid microgrid model of a landscape system and CCHP was reported to construct evaluation indexes from the three aspects of energy, economy and environment. In [5], a planning model with comprehensive consideration of carbon dioxide emission and total system cost was established using theoptimization software (CPLEX). The capacity configuration was simulated using Energy Plus software.The above two schemes improved the capacity allocation optimization model, but there was no sufficient clarification on the weight of the multi-objective function.
Prior studies usingthe optimization methods have made some progress in this field. For instance, [6] proposed a hybrid solution to meet the residential energy demand, which was composed of micro-CHP units and solar power units. Alternatively, [7] evaluated the performance of several designs ofhybrid CHP systems composed of solar thermal collectors, photovoltaic panels and natural gas internal combustion engines. Compared with the traditional mathematical methods, meta-heuristic algorithms had the advantages of fast solving speed and high accuracy in dealing with the highly coupled problems [8,9].
The genetic algorithm (GA) was proposed to optimize the capacity of configuration for the energy consumption, operation cost, and pollutant emission index in the CCHP system [10]. Ref. [11] established a microgrid system mixed with a photovoltaic power generation system and CCHP. It wasa multi-objective function based on energy, environmental protection and economy. The particle swarm optimization (PSO) algorithm was adopted to minimize the value of the objective function. However, typical GA, PSO, DE and other algorithms may be easily trapped intoa local convergenceand get unsatisfactory results. For this reason, a new CCHP microgrid model based on a multi-objective optimization and hybrid multi-objective intelligent algorithm(C-NSGA-II) wasproposed [12]. It was focused on environmental benefit, energy saving rate and security. In [13], the chaos-mutation-whale optimization algorithm achieved an optimization solution of a CCHP system in a shorter number of iterations. On the other hand, ahybrid algorithm that combined DE and PSO algorithms was proposed to optimize the CCHP systems [14].
The artificialbee colony (ABC)algorithm is often used to optimize the weighting factors of a multi-objective function [15]. Therefore, a new optimizationapproach based on the ABC algorithm was developed to determine the optimal DG-unit's size, power factor, and location for minimizing the total system real power loss [16]. In [17], a multi-period ABC optimization algorithm wasproposed foreconomic dispatch, considering generation, storage and responsiveload offers. However, the convergence rate may decrease when it is applied to a multi-dimensional multi-objective function model.
To sum up, the optimization of capacity allocation in the CCHP microgrid still requires further improvement as follows: (1) A new energy power generation hybrid system should be given more attention because of the greatchallenge of the recent energy crisis and environmental problems.
(2) The multi-objective function constructed by taking the economic, energy and environmental factors should find an appropriate weight for the capacity allocation. (3) PSO, GA, DE and other typical algorithms were widely applied to find the optimization solutionfor the power capacity allocation, but they may be trapped into the local minima solution, which will affect the optimization performance.
In this paper, amathematical model that considers the hybrid microgrid based on the photovoltaic and CCHP systemis built. Amulti-objective function is constructed by taking the economy, energy saving and environmental protection into account. The weight of the multi-objective function is determined by the analytic hierarchy process. Under the four scheduling strategies, the improved artificial beecolony (IABC) algorithm is developed to achieve the optimization solution for the power capacity allocation. In addition, another three classical algorithms are compared to verify the superiority of IABC in terms of convergence accuracy and speed.

CCHP Microgrid System
The structure of the CCHP microgrid system is shown in Figure 1. Itcontains cold, heat and electric loads [18]. The electric power is mainly supplied by the micro-gas turbine and photovoltaic power generation system. The heat power is supplied by the waste recovered heat from both the micro-gas turbineand gas boiler, which originally consume natural gas. The coldpower is mainly power generation system.The heat power is supplied by the waste recovered heat from both the micro-gas turbineand gas boiler, which originally consume natural gas. The coldpower is mainly supplied by the electric chiller and the adsorption chiller, which consumes the electric energy and converts the heat energy into the cold energy, respectively.  The mathematic model of the photovoltaic (PV) generator is described as where N pv E is the maximum output power of photovoltaic cells under standard test conditions (GSTC=1000W/m 2 , TSTC=25 °C).G is the actual light intensity; k is the power temperature coefficient of the photovoltaic cell.Tc is the surface temperature of the photovoltaic cell, which is close to the actual ambient temperature. The mathematic model of the micro-gas turbine (MT) is described as whereEmt is the power generated by MT.Fmt is the fuel consumed by MT. ηmtis the production efficiency of MT. The mathematic model of the battery is described as where Ec(t) represents the actual capacity of the battery at time t. ESTC represents the capacity of the battery under standard test conditions.δB is the capacity temperature coefficient.Tb(t) is the surface temperature of the battery at time t, approximately equal to the ambient temperature. TSTCis the temperature under standard test conditions [19]. Eb(t) represents the remaining charge of the battery at time t.Eb(t− 1) represents the remaining charge of the battery at time (t − 1). ηbis the self-discharge rate of the battery.Pc(t) andPd(t) are the charge and discharge power.ηc and ηdare the charging and discharging efficiency of the battery, respectively [20].Δt is the time interval.
The mathematic model ofthe thermal storage tank (TST) is described as The mathematic model of the photovoltaic (PV) generator is described as where E N pv is the maximum output power of photovoltaic cells under standard test conditions (G STC = 1000 W/m 2 , T STC = 25 • C). G is the actual light intensity; k is the power temperature coefficient of the photovoltaic cell. T c is the surface temperature of the photovoltaic cell, which is close to the actual ambient temperature.
The mathematic model of the micro-gas turbine (MT) is described as where E mt is the power generated by MT. F mt is the fuel consumed by MT. η mt is the production efficiency of MT. The mathematic model of the battery is described as where E c (t) represents the actual capacity of the battery at time t. E STC represents the capacity of the battery under standard test conditions. δ B is the capacity temperature coefficient. T b (t) is the surface temperature of the battery at time t, approximately equal to the ambient temperature. T STC is the temperature under standard test conditions [19]. E b (t) represents the remaining charge of the battery at time t. E b (t − 1) represents the remaining charge of the battery at time (t − 1). η b is the self-discharge rate of the battery. P c (t) and P d (t) are the charge and discharge power. η c and η d are the charging and discharging efficiency of the battery, respectively [20]. ∆t is the time interval.
Appl. Sci. 2020, 10, 2990 4 of 21 The mathematic model ofthe thermal storage tank (TST) is described as where H tst,chr and H tst,dis are the heat storage and heat release power in the thermal storage tank, respectively. H tst (t) is the heat energy stored in the thermal storage tank at time t. α tst is the self-loss coefficient. η tst,chr and η tst,dis are the heat storage efficiency and heat release efficiencyof TST, respectively [21]. The mathematic model of the gas boiler (GB) is described as where H gb is the thermal power generated from the GB. F gb is the fuel consumption of the boiler. η gb is the efficiency of the boiler. The waste heat recovery device (WHRD) recycles the heat from micro-gas turbines. The mathematic model of WHRD is described as where H re is the heat recovered by WHRD. η re is the waste heat recovery efficiency of heat energy. The mathematic model of heat exchange(HE) deviceis described as where H(t) is the output power of the HE deviceat time t; H he (t) is the input power of the heat exchangerat time t; η he is the efficiency ofthe HE device. The mathematic model of the electric chiller (EC) is described as where E ec (t) is the input power of ECat time t; Q ec (t) is theoutput power of ECat time t; COP ec is the refrigeration coefficient of EC. The mathematic model of the adsorption chiller (AC) is described as where H ac (t) is the input power of ACat time t; Q ac (t) is theoutput power of ACat time t; COP ac is the refrigeration coefficient of AC.

Selection of Decision Variables
Modern CCHP microgrid systems contain a variety of loads [22]. For this reason, every load and power supply source can be regarded as a variable to be optimized for the power capacity allocation. Among variables, the capacity of a photovoltaic power generation system can determine the penetration strength of green energy in the CCHP microgrid [23]. In addition, the capacity of the micro-gas turbine can greatly affect the supply of electric, heat and cold loadin the CCHP microgrid [24]. The upper limit of the exchange power in the grid directly determines the upper limit of the power that the microgrid buys or sells from/to the grid. Therefore, this variable should not be set too large. Otherwise, it may cause an unnecessary impact on the grid. Moreover, the energy storage system and thermal storage tank are important devices for stabilizing power fluctuations. If their capacity configuration is too low, the stored energy is not sufficientto meet the demand of the load. If the capacity allocation is too large, it will inevitably cause unnecessary waste. As the main source of heat, the capacity configuration of the gas boiler must be reasonably distributed to ensure the reliable power supply of the microgrid system.
As above, this study selects six device capacities as system decision variables.
where N pv , N mt , N grid , N b , N tst and N gb are the installed capacity of PV, MT, interactive with power grid (electricity purchase and sale from/to power grid), battery, TST and GB, respectively.

Economic Evaluation
Theannual total cost (ATC) includes the initial investment cost, interaction cost with power grid, and fuel cost. The smaller ATC is, the better the economy achieves.
where C i is the cost of the i-th equipment; N i is the installation capacity of the i-th equipment; E grid,in (t) is the amount of electricity purchased from the grid during system operation; E grid,out (t) is the amount of electricity sold to the grid during the system operation [25]; C e (t) is the time-of-use electricity price; C f (t) is the time-sharing gas price.

Energy-Saving Evaluation
TEC defined in Equation (13) represents the total energy consumption of the entire CCHP hybrid system [26]. The smaller the energy consumed, the better the energy conservation thatthe system achieves.
where F mt is the fuel consumptionof the micro-gas turbine. F gb is the fuel consumption of the gas boiler. E vacancy and E waste represent the power shortage and power waste; H vacancy and H waste represent the heat shortage and heat waste [13]; λ is the punish coefficient.

Environmental Evaluation
The pollutants emitted from the CCHP system are mixed, mainly including CO 2 , CO, NO X and PM, among which CO 2 accounts for more than 99.5%. Therefore, carbon dioxide emission (CDE) is adopted as the environmental evaluation index [27].
where CDE is the emission of CO 2 (kg); µ e (g/kWh) is the CO 2 emission coefficient corresponding to the purchased electricity; µ f (g/kWh) is the CO 2 emission coefficient corresponding to the combustion of natural gas.

Establishment of Multi-Objective Optimization Model
This study develops a multi-objective function F(X) based on the combination of economy, energy saving and environmental protection, which gives a certain weight to each evaluation index to reflect its contribution to the whole [28].
In this paper, the AHP algorithm is adopted to determine the value of the weight coefficient for the allocation of capacity of the CCHP system. The procedure is described as follows.

1.
Establish the hierarchical analysis structure of capacity optimization. According to the composition of the multi-objective function, the target is the capacity optimization, where the criterion layer includes economy, energy saving and environmental protection, as shown in Figure 2.

2.
Construct judgment matrix. A(a ij ) n×n is the judgment matrix. a ij is the comparison weight of relative importance obtained by pairwise comparison of standard layer indicators. Twenty experts were consulted to complete the questionnaire [29]. Experts rate the relative importance (between two factors) of the criterion layer. The scale of relative importance is 1-9 [30]. Calculate the arithmetic mean of the comparison weight column of relative importance between each two factors, and then round to get a ij . Finally, A(a ij ) n×n is obtained. 3.
Weight sorting. The weight ordering refers to the ordering of the importance of each element in the standard layer for the target layer. First, calculate the element product of each row of the judgment matrix, and then find the n-th square root of the element product of each row to obtain the eigenvector matrix. At last, normalize the sum of the eigenvectors to be 1, and then obtain the weight vector W. The specific steps are expressed as follows.
where M i is the score of elements in each row of the judgment matrix; W i is the n-th root of M i ; W i is the i-th element of the matrix W. The calculated results are: W = [0.637, 0.258, 0.105] T .

4.
Conduct theconsistency test for the judgment matrix. Consistency index (CI), Randomconsistency index (RI) and Consistency ratio (CR) are calculated as follows.
where λ max is the maximum characteristic root of matrix A. (AW) i is the i-th element of the matrix AW. Substitute the W matrix obtained in step (3) into Equation (18): λ max = 3.038, CI = 0.019. According to the RI value table with a sample size of 100-500 given by Satty, it can be obtained: [31]. This indicates that the judgment matrix has a satisfactory consistency, and its normalized feature vector can be used as the weight vector. The final result from the above steps is obtained as Appl. Sci. 2019, 9, x FOR PEER REVIEW 6 of 21 1. Establish the hierarchical analysis structure of capacity optimization. According to the composition of the multi-objective function,the target is the capacity optimization, where the criterion layer includes economy, energy saving and environmental protection, as shown in Figure 2. 2. Construct judgment matrix. A(aij)n×n is the judgment matrix.aijis the comparison weight of relative importance obtained by pairwise comparison of standard layer indicators.Twenty experts were consulted to complete the questionnaire [29].Experts rate the relative importance (between two factors) of the criterion layer.The scale of relative importance is 1-9 [30].Calculate the arithmetic mean of the comparison weight column of relative importance between each two factors, and then round to get aij.Finally, A(aij)n×n is obtained.

Capacity optimization
Energy-saving Economic Environmental

Constraints
The constraints mainly include the capacity constraints ofequipment, electricity balance, heating balance, and cooling balance.Decision parameters and their range of variations are listed in Table 1. The heat storage tanks and batteries have some constraints in the specific operation.
where H tst,chr (t) and H tst,dis (t) are the heat storage and heat release power in the thermal storage tank, respectively; SOC(t) is the charged state of the battery at time t; P b,in (t) and P b,out (t) are the charging and dischargingpower of the battery, respectively [32]. Theelectrical power balance is as follows: where E pv (t) and E mt (t) represent the electric energygenerated from the photovoltaic power generation system and micro-gas turbine at time t, respectively. E grid,in (t) and E grid,out (t) represent the electricity purchased and sold from/to the grid at time t, respectively. E b,in (t) and E b,out (t) are the charging and discharging power of the battery at time t, respectively. E(t) represents the power load demand at time t. E ec (t) represents the energy consumed by the electric refrigerator at time t. Theheat power balance is as follows: where H re (t) is the waste heat recovered by RE at time t. H GB (t) is the heat generated by the gas boiler at time t. H tst,in (t) and H tst,out (t) are the heat energy absorbed and released by the heat storage tank at time t, respectively. H he (t) is the heat energy consumed by the heat exchanger at time t. H ac (t) is the heat energy consumed by the adsorption chiller at time t [28,32]. Thecold power balance is as follows: where Q ac (t) is the cold energy generated by the adsorption chiller at time t; Q ec (t) is the cold energy generated by the electric chiller at time t; Q(t) is the cooling load demand at time t.

Improved Scheduling Strategy
Two improved scheduling strategies based on traditional ones are proposed in this study. The following four scheduling policies are described in detail. The FEL strategy assures that the electrical energy generated by the CCHP system matches the electric load demand at any time. Priority is given to the photovoltaic power generation to meet the demand of the electric load and electric chiller [33][34][35]. If photovoltaic power generation cannot satisfy the demand of the electric load and electric chiller, the gas turbine will be taken as a backup power to fill the demand of the power load. On the contrary, if the generated power from the photovoltaic power generation is greater than the power demand, the excess power is sold to the grid [34].

Traditional "Following Heat Load" (FHL) Strategy
The collection of waste heat from the micro-gas turbine should match the demand of the adsorption chiller and heat load of exchanger conversion at any moment. If it is not satisfactory, the gas boiler is used as a backup heat source to fill gaps [35]. On the contrary, if it exceeds the demand of the adsorption chiller and heat load, the extra heat energy is stored in the heat storage tank [36,37].

Improved "Following Electric Load" (IFEL) Strategy
The synergy power generated from the micro-gas turbine and photovoltaic power generation system should match the demand of the electricity load and refrigerating machine at any moment. If the generated power is more than the demand, the excess power can be used to charge the battery storage system. If it is insufficient to support the demand, the energy can be supplied from the battery storage system or an external grid.

Improved "Following Heat Load" (IFHL) Strategy
The heat energy generated from the micro-gas turbine and gas boiler should match the load demand by the adsorption refrigerating machine and heat exchanger for conversion of heat load at any moment. If the heat energy produced is more than the load demand at any moment, excess heat energy will be stored in the heat storage tank. However, it will cause excess heat energy waste once it is beyond the capacity of the heat storage tank. On the contrary, if the generated heat is insufficient, the heat storage tank is used to resupply. The flowchart of four strategies is shown in Figure 3. The FEL strategy assures that the electrical energy generated by the CCHP system matches the electric load demand at any time. Priority is given to the photovoltaic power generation to meet the demand of the electric load and electric chiller [33][34][35]. If photovoltaic power generation cannot satisfy the demand of the electric load and electric chiller, the gas turbine will be taken as a backup power to fill the demand of the power load. On the contrary, if the generated power from the photovoltaic power generation is greater than the power demand, the excess power is sold to the grid [34].

Traditional "Following Heat Load"(FHL) Strategy
The collection of waste heat from the micro-gas turbine should match the demand of the adsorption chiller and heat load of exchanger conversion at any moment. If it is not satisfactory, the gas boiler is used as a backup heat source to fill gaps [35]. On the contrary, if it exceeds the demand of the adsorption chiller and heat load,the extra heat energy is stored in the heat storage tank [36,37].

Improved "Following Electric Load" (IFEL) Strategy
The synergy power generated from the micro-gas turbine and photovoltaic power generation system should match the demand of the electricity load and refrigerating machine at any moment. If the generated power is more than the demand, the excess power can be used to charge the battery storage system. If it is insufficient to support the demand, the energy can be supplied from the battery storage system or an external grid.

Improved "Following Heat Load"(IFHL)Strategy
The heat energy generated from the micro-gas turbine and gas boiler should match the load demand by the adsorption refrigerating machine and heat exchanger for conversion of heat load at any moment. If the heat energy produced is more than the load demand at any moment, excess heat energy will be stored in the heat storage tank. However, it will cause excess heat energy waste once it is beyond the capacity of the heat storage tank. On the contrary, if the generated heat is insufficient, the heat storage tank is used to resupply. The flowchart of four strategies is shown in Figure 3.

Improved Artificial Bee Colony Algorithm
In the typical ABC algorithm, there are three types of individuals: hired bees, observer bees and detection bees [38]. Each hired bee corresponds to a defined honey source (solution vector), and the area of the honey source is searched during the iteration. According to the abundance of the nectar source (the size of the adaptive value), a roulette wheel is used to select observer bees to collect honey (search for new nectar source).If the honey sourcesare not improved after several updates, the honey source are abandoned and the hired beesare turned into detection bees to search for the new honey source randomly [39].

Improved Artificial Bee Colony Algorithm
In the typical ABC algorithm, there are three types of individuals: hired bees, observer bees and detection bees [38]. Each hired bee corresponds to a defined honey source (solution vector), and the area of the honey source is searched during the iteration. According to the abundance of the nectar source (the size of the adaptive value), a roulette wheel is used to select observer bees to collect honey (search for new nectar source). If the honey sourcesare not improved after several updates, the honey Appl. Sci. 2020, 10, 2990 9 of 21 source are abandoned and the hired beesare turned into detection bees to search for the new honey source randomly [39].

(a) Population Initialization
Random numbers matching the predefined range are randomly generated on each element of the honey source position matrix to fill the honey source position matrix. The expression of the population initialization is expressed as follows.
where ld and ud are the lower and upper bounds of the d-dimensional search space, respectively; lhsdesign(0,1) represents a random number of (0,1) generated by Latin hypercube sampling. Compared with the traditional rand distribution, lhsdesign can make every individual in each dimension of the initial population within the interval of uniform distribution, ensuring that the initial population can contain locally optimal individuals and ensuring the convergence of the algorithm.

(b) Hired Bee Stage of the Hybrid Whale Search Strategy
The hired bees are responsible for finding suitable honey sources within the designated search area. Then, the information of the source is saved. The formula for searching the honey source is shown as follows.
where u i,d represents the location of the new nectar source. x i,d is the d-dimension values of the ith nectar source. x k,d is the d-dimensional value of a randomly selected nectar source among N nectar sources, and k i. r represents the random number within the interval [−1,1].
In the typical ABC, both hirer and observer bees use Equation (24) to conduct one-dimensional operations, which has a strong global search ability but low search efficiency. Thewhale optimization algorithm (WOA) is a new algorithm to simulate the hunting behavior of humpback whales in the ocean [40]. The contraction enveloping mechanism is simulated by Equation (25). A spiral equation is established between the position of whale and prey to simulate the spiral motion of humpback whales as shown in Equation (26). In order to simulate the simultaneous occurrence of both movements in the humpback whale, it is assumed that there is a 50% probability that a choice can be made between the narrowing of the enveloping mechanism and the spiral model, as shown in Equation (27).
This paper combines the WOA to improve the search mode of hired bees. The behavior of bees searching for honey is modeled based on that of humpback whales searching for prey.
where a is the iteration number that decreases linearly from 2 to 0; r is a random number within the range [0,1]; x * d is the d-dimension value of the current optimal nectar source; b is a constant; l is the random number within the range of [−1,1]; p is a random number within the range [0,1].
When the new honey source is obtained, the fitness values of new and old honey sources are calculated by Equation (28).
where fit i represents the fitness value of the ith nectar source; f i represents the value of the objective function of the ith solution. The greedy algorithm (29) is used to compare the fitnessvalues of new and old honey sources and update the honey sources.
(c) The Observer Bee Stage of the Dynamic Adjustment of P i P i is the selection probability of each honey source in the typical ABC algorithm. After the hired bees update the honey source, they fly back to the information exchange area to share the honey source.The observer bees calculated the P i according to the honey source information shared by the hired bees.The calculated P i is used to perform roulette to select the honey source. According to Equation (24), the observer bees update the nectar source near the selected nectar source and determine the nectar amount of the new nectar source.If the fit of the new solution is better than the previous one, the observer bee will remember the new solution instead of the old one.
The P i formula of the typical ABC algorithm is shown in Equation (30). The higher the fitness value of a honey source, the greater the probability that a better honey source will be selected. However, in the later stage of the algorithm, there are already many dominant individuals in the population. If the population is selected with fixed P i , the dominant individuals may be destroyed and the convergence rate will be slowed down. In this paper, P i is improved into a dynamic function with the number of iterations as the independent variable, as shown in Equation (31), where P i d is the selection probability of each honey source in the IABC algorithm. P 0 and P max are the minimum and maximum selection probabilities, respectively. In the initial stage of the algorithm, P i d is close to P i . With the progress of the algorithm, P i d increases slightly, and in the later stage, dominant individuals can be better highlighted.
The convergence rate of the algorithm is thus accelerated.

(d) Detection Bee Stage
When the mining times of the honey source reaches the limit, the fitness value of a certain honey source remains unchanged. This means that the honey source mining is trapped into a local optimum. Then, the honey source should be abandoned, and the hired bee changes to the detection bee. A new honey source location is generated according to Equation (23).
The specific steps of the improved artificial bee colony algorithm are as follows: Step 1 Initialize population: initializing all parameters, e.g., the total number of bees NP, the maximum number of iterations t max , the control parameter limit, lower (l d ) and upper (u d ) bounds of the search space; and randomly generating initial solution {x i i = 1, 2..., NP}; Step 2 Calculate the adaptive value of each bee in the population; Step 3 Set the parameters of the whale search strategy: a, b, l, p. The hired bee generates a new solution u i,d, according to Equation (27), and calculate the fitness value; Step 4 The hired bee selects the nectar source according to the greedy strategy; Step 5 Calculate the selection probability P i according to Equations (30) and (31); Step 6 The observer bees select the honey source according to the probability P i , and generate a new one near the honey source according to Equation (24). Meanwhile, the fitness value of the new honey source is calculated. Finally, the source of honey is selected using the greedy algorithm; Step 7 Determine whether detection bees exist. If so, randomly generate a honey source to replace them according to Equation (23); Step 8 Check whether the end condition is satisfied. If not, repeat Steps 3-7, or output the optimal solution.
There are six decision variables, e.g., N pv , N mt , N grid , N b , N tst and N gb , regarded as the locations of the nectar sources in the CCHP microgrid capacity optimization configuration. The multi-objective function value established is regarded as the quantity of nectar. The IABC algorithm process is to find a set of optimal solutions to minimize the value of the objective function. The optimization method based onthe IABC algorithm is shown in Figure 4. Step6 The observer bees select the honey source according to the probability Pi, and generate a new one near the honey source according to Equation (24). Meanwhile, the fitness value of the new honey source is calculated. Finally, the source of honey is selected using the greedy algorithm; Step7Determine whether detection bees exist. If so, randomly generate a honey source to replace them according to Equation (23); Step8Check whether the end condition is satisfied. If not, repeat Steps 3-7, or output the optimal solution.
There are six decision variables, e.g.,Npv, Nmt, Ngrid, Nb, Ntst and Ngb, regarded as the locations of the nectar sources in the CCHP microgrid capacity optimization configuration. The multi-objective function value established is regarded as the quantity of nectar. The IABC algorithm process is to find a set of optimal solutions to minimize the value of the objective function.The optimization method based onthe IABC algorithm is shown in Figure4.

Initial population in lhsdesign
Calculate the adaptive value of each bee

Analysis of Model Performance
In this study, large hotels in 16 commercial reference buildingspublished by the U.S. Department of Energy (DOE) were selected as the research carrier to test the operation state of the microgrid system [41,42]. The prices of the various equipment used are shown in Table 2.The cost of each equipment is cited in reference [4]. The electricity price and natural gas price are shown in Table 3. The parameters of the CCHP system are shown in Table 4. The parameter setting of the CCHP system is cited in reference [4,11,12]. The entire experiment was performed using Microsoft Windows 8 operating system and MATLAB R2014a software (MathWorks, Natick, Massachusetts, USA) developer, city, country . The computer configuration used Core i5, 3.0 GHz, 8 GB RAM.
According to the cold, heat and electric load curves, as shown in Figure5, the following characteristics of energy demands can be derived as: (1) The electricity load per hour fluctuates greatly at the morning and evening peak periods, where it is generally larger than the cold and hot load;

Analysis of Model Performance
In this study, large hotels in 16 commercial reference buildingspublished by the U.S. Department of Energy (DOE) were selected as the research carrier to test the operation state of the microgrid system [41,42]. The prices of the various equipment used are shown in Table 2. The cost of each equipment is cited in reference [4]. The electricity price and natural gas price are shown in Table 3. The parameters of the CCHP system are shown in Table 4. The parameter setting of the CCHP system is cited in reference [4,11,12]. The entire experiment was performed using Microsoft Windows 8 operating system and MATLAB R2014a software (MathWorks, Natick, MA, USA) developer, city, country. The computer configuration used Core i5, 3.0 GHz, 8 GB RAM.  According to the cold, heat and electric load curves, as shown in Figure 5, the following characteristics of energy demands can be derived as: (1) The electricity load per hour fluctuates greatly at the morning and evening peak periods, where it is generally larger than the cold and hot load; (2) The great fluctuation of heat load occurringin the morning and evening during the day is due to the special environment of the selected hotel; (3) The daily cooling load demand is stable because of the hot local climate.
(2) The great fluctuation of heat load occurringin the morning and evening during the day is due to the special environment of the selected hotel; (3) The daily cooling load demand is stable because of the hot local climate.

Analysis of Operation Using FEL Strategy
From Figure 6a, under the FEL strategy, it was found that the electrical power mainly comes from the micro-gas turbine and power grid. The micro-gas turbine power supply is more stable. However, the power grid provides more electricity than the micro-gas turbine power. On the other hand, the micro-gas turbine provides more power than the photovoltaic system. The grid power purchase is more economic than the micro-gas turbine and photovoltaic power system. From 7:00 to 15:00, when the sunlight is relatively sufficient, the photovoltaic power generation system participates in the power supply task. Nevertheless, its contribution is very small due to the economic cost. From Figure 6b, the heat power is mainly supplied by the micro-gas turbine and the gas boiler. However, the output of the gas boiler varies with the fluctuation of the load. In contrast, the output of the micro-gas turbine is relatively stable. Moreover, the system adopts the operation strategy of FEL. From Figure 6c, the first priority is to meet the demand of electric load. Subsequently, redundant electric energy is produced to cool. Therefore, the AC bears more cold load than the EC. Note that the E load increases substantially at 6 o'clock. Under the FEL strategy, the electric balance is satisfied, and there is no excess electrical energy to provide EC to generate cold power at this stage. To maintain the cold power required by the users, the Qac therefore increases abruptly. , under the FEL strategy, it was found that the electrical power mainly comes from the micro-gas turbine and power grid.The micro-gas turbine power supply is more stable. However, the power grid provides more electricity than the micro-gas turbine power. On the other hand, the micro-gas turbine provides more power than the photovoltaic system. The grid power purchase is more economic than the micro-gas turbine and photovoltaic power system. From 7:00 to 15:00, when the sunlight is relatively sufficient, the photovoltaic power generation system participates in the power supply task. Nevertheless, its contribution is very small due to the economic cost. From Figure 6b,the heat power is mainly supplied by the micro-gas turbine and the gas boiler. However, the output of the gas boiler varies with the fluctuation of the load. In contrast, the output of the micro-gas turbine is relatively stable. Moreover, the system adopts the operation strategy of FEL. From Figure 6c, the first priority is to meet the demand of electric load. Subsequently, redundant electric energy is produced to cool. Therefore, the AC bears more cold load than the EC. Note that the Eload increases substantially at 6 o'clock. Under the FEL strategy, the electric balance is satisfied, and there is no excess electrical energy to provide EC to generate cold power at this stage. To maintain the cold power required by the users, the Qac therefore increases abruptly.

Analysis of Operation Usingthe FHL Strategy
As can be seen from Figure7a, under the FHL strategy, electric energy is mainly supplied by the micro-gas turbine and power grid, but a little fluctuation appears in the micro-gas turbine power supply. In terms of power supply economic benefit, it is the same result as that under the FEL strategy. From 7:00 to 16:00, the photovoltaic power generation system participates in the power supply task, but its contribution is limited due to the restriction of economic cost. From Figure 7b, the heat powers are mainly supplied by the micro-gas turbine and the gas boiler. Their output varies with the fluctuation of load. From Figure 7c,the electric chiller can bear more cold load than the adsorption chiller. The system adopts the strategy of FTL, and it ensures itmeets the demand of the

Analysis of Operation Using the FHL Strategy
As can be seen from Figure 7a, under the FHL strategy, electric energy is mainly supplied by the micro-gas turbine and power grid, but a little fluctuation appears in the micro-gas turbine power supply. In terms of power supply economic benefit, it is the same result as that under the FEL strategy. From 7:00 to 16:00, the photovoltaic power generation system participates in the power supply task, but its contribution is limited due to the restriction of economic cost. From Figure 7b, the heat powers are mainly supplied by the micro-gas turbine and the gas boiler. Their output varies with the fluctuation of load. From Figure 7c, the electric chiller can bear more cold load than the adsorption chiller. The system adopts the strategy of FTL, and it ensures itmeets the demand of the heat load. Simultaneously, redundant heat energy is generated for refrigeration. Note that the H load goes down considerably at 11 o'clock. At this time, the E load is stable, and E mt thus remains stable. In addition, MT's waste heat recovery device still produces a stable H re . Under the FHL strategy, the heat balance is preferentially satisfied, and a large amount of heat energy can only supply AC to generate cold power. This results in theQac increasing suddenly. heat load. Simultaneously, redundant heat energy is generated for refrigeration. Note that the Hload goes down considerably at 11 o'clock. At this time, the Eload is stable, and Emtthus remains stable. In addition, MT's waste heat recovery device still produces a stable Hre. Under the FHL strategy, the heat balance is preferentially satisfied, and a large amount of heat energy can only supply AC to generate cold power. This results in theQac increasing suddenly.

Analysis of Operation Using the IFEL Strategy
As can be seen from Figure8a, under the IFEL strategy, the power is mainly supplied by the photovoltaic, micro-gas turbine and power grid. During 0:00~2:00, the discharge of the battery supplements a small part of the electric load. From 7:00 to 16:00, the sunlight is relatively sufficient so that the photovoltaic power generation can produce more electric power. The generated power ismainly concentrated on the daytime, reducing the electricity purchase cost from the power grid. Obviously, it alleviates some of the electrical pressure from system. From Figure 8b, the heat power is mainly supplied by the micro-gas turbine. The output of waste heat recovery from the gas turbine varies with the fluctuation of load. The excess heat power is used for the AC cooling. From Figure  8c,the adsorption chiller bears more cold load than the electric chiller. The system adopts the IFEL strategy so that it initially ensures that it meets the demand of the electric load. Incidentally, redundant electric energy is generated for refrigeration.

Analysis of Operation Using the IFEL Strategy
As can be seen from Figure 8a, under the IFEL strategy, the power is mainly supplied by the photovoltaic, micro-gas turbine and power grid. During 0:00~2:00, the discharge of the battery supplements a small part of the electric load. From 7:00 to 16:00, the sunlight is relatively sufficient so that the photovoltaic power generation can produce more electric power. The generated power ismainly concentrated on the daytime, reducing the electricity purchase cost from the power grid. Obviously, it alleviates some of the electrical pressure from system. From Figure 8b, the heat power is mainly supplied by the micro-gas turbine. The output of waste heat recovery from the gas turbine varies with the fluctuation of load. The excess heat power is used for the AC cooling. From Figure 8c, the adsorption chiller bears more cold load than the electric chiller. The system adopts the IFEL strategy so that it initially ensures that it meets the demand of the electric load. Incidentally, redundant electric energy is generated for refrigeration.

Analysis of Operation Using the IFHL Strategy
As can be seen from Figure 9a, under the IFHL strategy, the power is mainly supplied by the photovoltaic, micro-gas turbine, power grid and battery. During 0:00~2:00 and 10:00~14:00, the battery, usinga charging and discharging process, maintains the electrical power balance of the CCHP system. From 7:00 to 16:00, when the sunlight is sufficient, the photovoltaic power generation can produce a relatively high electric power outputduring theday, reducing the electricity purchase from the power grid. From Figure 9b, the heat power is mainly supplied by the micro-gas turbine and heat storage tank. The output power from the micro-gas turbine is relatively stable. In Figure 9c, the EC bears more cold load than the AC. When the system adopts the strategy of IFHL, it ensuresitmeets the demand of heat load and then generates redundant heat energy for refrigeration.
ismainly concentrated on the daytime, reducing the electricity purchase cost from the power grid. Obviously, it alleviates some of the electrical pressure from system. From Figure 8b, the heat power is mainly supplied by the micro-gas turbine. The output of waste heat recovery from the gas turbine varies with the fluctuation of load. The excess heat power is used for the AC cooling. From Figure  8c,the adsorption chiller bears more cold load than the electric chiller. The system adopts the IFEL strategy so that it initially ensures that it meets the demand of the electric load. Incidentally, redundant electric energy is generated for refrigeration.

Analysis of Operation Usingthe IFHL Strategy
As can be seen from Figure9a, under the IFHL strategy, the power is mainly supplied by the photovoltaic, micro-gas turbine, power grid and battery. During 0:00~2:00 and 10:00~14:00, the battery,usinga charging and discharging process, maintains the electrical power balance of the CCHP system. From 7:00 to 16:00, when the sunlight is sufficient, the photovoltaic power generation can produce a relatively high electric power outputduring theday, reducing the electricity purchase from the power grid. From Figure 9b, the heat power is mainly supplied by the micro-gas turbine and heat storage tank. The output power from the micro-gas turbine is relatively stable. In Figure  9c,the EC bears more cold load than the AC. When the system adopts the strategy of IFHL, it ensuresitmeets the demand of heat load and then generates redundant heat energy for refrigeration.

Analysis of Operation Usingthe IFHL Strategy
As can be seen from Figure9a, under the IFHL strategy, the power is mainly supplied by the photovoltaic, micro-gas turbine, power grid and battery. During 0:00~2:00 and 10:00~14:00, the battery,usinga charging and discharging process, maintains the electrical power balance of the CCHP system. From 7:00 to 16:00, when the sunlight is sufficient, the photovoltaic power generation can produce a relatively high electric power outputduring theday, reducing the electricity purchase from the power grid. From Figure 9b, the heat power is mainly supplied by the micro-gas turbine and heat storage tank. The output power from the micro-gas turbine is relatively stable. In Figure  9c,the EC bears more cold load than the AC. When the system adopts the strategy of IFHL, it ensuresitmeets the demand of heat load and then generates redundant heat energy for refrigeration.

Comparison of Strategies
Under four different scheduling strategies, the proposed IABC algorithm was used to solve the multi-objective optimization model, and the scheduling results of the CCHP system are shown in

Comparison of Strategies
Under four different scheduling strategies, the proposed IABC algorithm was used to solve the multi-objective optimization model, and the scheduling results of the CCHP system are shown in Table 5. As can be seen from Table 5, under the two scheduling strategies of FEL and FHL, the capacity allocation of photovoltaic power generation (PV) is less, while the capacity allocation of photovoltaic power generation (PV) under the two scheduling strategies of IFEL and IFHLis greater. Therefore, the ATC of these two strategies is larger, while the TEC and CDE are smaller. Under the two scheduling strategies of FEL and IFEL, the capacity configuration of ECis less than that of the latter two strategies, while the capacity configuration of AC is more than that of the latter two strategies due to firstly satisfying the demand of the system electrical load. Under the two scheduling strategies of IFEL and IFHL, a battery is usedto maintain the stable electric load, and a heat storage tank is used to maintain the stable thermal load, alleviating the instability of photovoltaic power generation. In general, the value of the target function F(X) using FHLis the smallest, indicating the best performance.

Comparison of Algorithms
The IABC algorithm, WOA algorithm, ABC algorithm and PSO algorithmare set up to evaluate under the same conditions, i.e., the number of iterations = 500, population number = 32, using different strategies. The objective function values usingfour strategies are concluded in Table 6. Based on the log value of the objective function, thecorresponding convergence curves are shown in Figure 10. optimization result of IABC is the best, and its convergence speed is faster than ABC. In conclusion, IABC presents better performance than the other three algorithms in either convergence accuracy or speed.

Conclusions
This paper studies the hybrid of photovoltaic power generation and CCHP microgrid systems. The proposed IABC algorithm can achieve the optimal configuration in the capacity allocation of the CCHP microgrid. Major contributions are summarized as follows:  As can be seen from Table 6, under the FEL strategy, the objective function value of IABC is 2.73% lower than that of WOA, 9.52% lower than that of ABC, and 5.67% lower than that of PSO.Under the FTL strategy, the objective function value of IABC decreased by 7.61% compared with WOA, 0.28% lower than the objective function value of the ABC algorithm, and 9.37% lower than the objective function value of PSO.Under the IFEL strategy, the objective function value of IABC is 1.54% lower than that of WOA, 14.98% lower than the objective function value of the ABC algorithm, and 0.73% lower than the objective function value of PSO.Under the IFHL strategy, the objective function value of IABC was 9.27% lower than that of WOA, 2.27% lower than that of the ABC algorithm, and 8.74% lower than that of PSO.In summary, compared with the three algorithms, the objective function value of IABC is the lowest under the four strategies, which can reflect the advantage of IABC in the optimization ability.
In Figure 10a, both the optimization ability and convergence speed of IABC are better than the other three algorithms. In Figure 10b, the convergence results of WOA and PSO are obviously worse than the other two algorithms. On the other hand, the convergence speed of IABC and ABC are comparable. However, the optimization results of IABC are slightly better than ABC. It can be seen from Figure 10c that IABC has the fastest convergence speed and the best optimization outcome. In Figure 10d, the convergence of WOA and PSO is fast, but they get into a local solution. The optimization result of IABC is the best, and its convergence speed is faster than ABC. In conclusion, IABC presents better performance than the other three algorithms in either convergence accuracy or speed.

Conclusions
This paper studies the hybrid of photovoltaic power generation and CCHP microgrid systems. The proposed IABC algorithm can achieve the optimal configuration in the capacity allocation of the CCHP microgrid. Major contributions are summarized as follows: (1) The capacity optimization modelcomprehensively considers the influence of economy, energy and environment. In addition, the AHP algorithmintegrated with the proposed modelcan find the appropriate weight values of a multi-objective function successfully. (2) From the performance analysis of four scheduling strategies using FEL, FHL, IFEL and IFHL, FEL and FHL were found to be more economical but hadless energy-saving and environmental benefits. Contrastively, IFEL and IFHL are less economical but have more energy-savingand environmental benefits instead. Among them, the distributed power supply under the FHL strategy achieves a more stable operation. (3) Among the IABC, ABC, WOAand PSO algorithms, under four scheduling strategies, the IABC algorithm presents the best performance in both convergence speed and accuracy.