1. Introduction
As the demand for electricity continues to grow and the problems of energy scarcity and environmental pollution become increasingly severe worldwide, the drawbacks of traditional energy generation are becoming increasingly apparent. Within the background of “Carbon peak, Carbon neutral”, renewable energy represented by wind power and photovoltaic power generation has become the main direction of China’s future energy development. However, at the same time, its small-scale, wide distribution and many kinds of characteristics also bring certain troubles to grid scheduling and stable operation. The unified and coordinated management of new energy output through a Virtual Power Plant (VPP) can not only reduce the impact of random fluctuations in renewable energy on the grid, but also reduce the difficulty of distributed generation scheduling, so that distributed generation can better participate in grid scheduling and operation.
VPP have been studied in great depth in many literatures. The literature [
1,
2,
3] provides a detailed introduction to the definition, control methods, and model framework of a VPP, pointing out the urgent problems to be solved in a VPP, including the coordinated control of the VPP based on multi-agent systems, the use of efficient aggregation management methods to achieve collaboration among the VPP, the establishment of an open and reliable information interaction system, and an outlook on the future development of the VPP. In the literature [
4,
5,
6], a linear programming control allocation model for a virtual power plant containing at least one conventional power generation plant and renewable energy sources together was developed; a mixed-integer linear programming model was created with the objective of minimizing the cost of a conventional power plant, and the feasibility of the method was verified by an intelligent optimization algorithm. In the literature [
7], a probability distribution inscription method for the scheduling boundary of VPP taking into account the uncertainty of distributed new energy sources is proposed based on multi-parameter planning theory; the proposed method uses the new energy random variables as the planning parameters, studies the segmental analytical mapping of the virtual power plant gate limit exchange power and the new energy power, and calculates the cumulative distribution function of the virtual power plant dispatch boundary based on the principle of full probability. In order to reduce the heavy computational burden caused by the growth of random variables, the paper proposes a key random variable identification method based on the ranking of line transfer distribution factors to realize the fast inscription of the probability distribution of the virtual power plant dispatch boundary, and applies the proposed probability distribution of the virtual power plant dispatch boundary to the virtual power plant–main network cooperative optimization dispatch. The validity and accuracy of the proposed method are demonstrated by simulation calculations based on an IEEE 136-node distribution network. In the paper [
8], a two-stage coordinated optimal scheduling method based on economic model predictive control is proposed for multi-virtual power plants on a day-ahead basis. The analysis shows that the total profit of multi-virtual power plant joint operation is improved compared with a single virtual power plant only trading with the grid, and the proposed dispatching scheme can effectively cope with the uncertain wind power output, improve the dispatching accuracy, and realize the overall optimal economic operation of a multi-virtual power plant, thus verifying the correctness and feasibility of the model. The literature [
9] proposed a virtual power plant optimization model considering demand response, which can effectively improve scenic intermittent power consumption, reduce the peak-to-valley load difference, smooth the load curve, and maximize the economic return of the virtual power plant, verifying the effectiveness of the proposed method. The literature [
10] uses pumped-storage plants to deal with uncertainties in wind and PV output and proposes a mixed-integer linear programming model, which is verified by arithmetic examples to maximize the profitability of the VPP under long-term bilateral contracts and technical constraints. The combination of pumped-storage power plants with wind and photovoltaic greatly improves the output stability of the integrated energy system. In the literature [
11], a multi-timescale coordinated operation strategy for virtual power plant (VPP) clusters considering electric energy interaction and sharing was proposed to effectively improve the electric energy balance problem of VPP cluster systems and significantly improve the overall operation economy through multi-VPP coordinated interaction and multi-timescale rolling optimization. At the same time, it also improves the problem of uneven output of each output unit, and this operation method is more reasonable.
With the development of electric vehicles, the impact of electric vehicle charging and discharging on the power grid cannot be ignored. In the literature [
12,
13,
14,
15], several problems of large-scale electric vehicles in the form of energy storage to participate in the dispatch management of VPP and to participate in the electricity market were studied, and an optimal dispatch model of a VPP with electric vehicles was constructed. Electric vehicles can be used as both a load and a power source, and several of these papers have studied the charging and discharging problems of electric vehicles more fully, but have ignored the effects of peak ridership. In the literature [
16], a master–slave game model for a VPP containing EVs was developed to improve the overall economy of system operation by guiding the charging and discharging behavior of EVs through tariff signals; however, the cost of battery losses in EVs and energy storage systems was ignored. In order to reduce the high energy storage costs, the literature [
17] used energy routers to implement the conversion of natural gas to electricity and to participate in market regulation services, effectively increasing the average profit of energy router participants.
At present, most of the research on VPP is focused on the economic dispatch side, but there is little consideration of other aspects such as environmental impact, and in the context of China’s “Carbon peak, Carbon neutral” goal and the global efforts to reduce energy consumption, research on the environmental aspects of VPP is equally important.
The literature [
18] models the integrated carbon–electricity trading strategy of a VPP, and the introduction of a carbon-trading mechanism will significantly reduce the level of bidding output of high-carbon units. In the literature [
19], an optimal scheduling model for carbon-containing capture and waste incineration virtual power plants that takes into account the power-to-gas synergy was proposed. The simulation results show that the proposed model and method can reduce the cost and carbon emissions of the virtual power plant by enhancing the consumption of renewable energy with peak-shaving and valley-filling effects. In the literature [
20,
21,
22], an optimal dispatch model considering demand response and carbon emission constraints was developed to study the impact of environmental friendliness on the economics of a VPP. In the literature [
22], an integrated energy system optimal dispatch model considering stepped carbon trading and flexible dual response of supply and demand was proposed, adding the consideration of gas carbon emissions and introducing a stepped carbon-trading mechanism; a flexible dual response mechanism of supply and demand was proposed, introducing an organic Rankine cycle on the supply side to achieve a flexible response of cogeneration and electric output, and on the demand side, while considering that electric, thermal, and gas loads all have demand in the time dimension. Finally, an optimal dispatch model was constructed with the objectives of minimizing carbon emission cost, energy purchase cost, wind abandonment cost, and demand response cost. The results show that under the ladder carbon-trading mechanism, the total operating cost and carbon emission were reduced by 5.18% and 13.5%, respectively, when the carbon-trading cost was considered in the optimization target compared to when the carbon-trading cost was not considered in the optimization target. The results show that under the stepped carbon-trading mechanism, the total operating costs and carbon emissions were reduced by 5.18% and 13.96%, respectively, compared with those of the optimization target without carbon-trading costs, and the total operating costs and carbon emissions were reduced by 16.93% when the dual response mechanism was considered. The total operating costs and carbon emissions were reduced by 16.93% and 27.35%, respectively, when the dual response mechanism was considered. The simulation results verified the validity of the proposed model.
Although the above literature considers the impact of environmental friendliness, it idealizes the wind and PV output and does not take into account the impact of the volatility of wind and PV output on virtual power plant dispatch.
In this paper, an optimal scheduling model for a VPP considering carbon trading is developed. Firstly, based on the basic concept of a virtual power plant, a virtual power plant model containing wind power, photovoltaic power, a gas turbine, and energy storage is established. Then, considering the uncertainties of wind power and PV power generation, Latin hypercubic sampling is used to simulate wind power and PV output scenarios, combined with the improved CLARA clustering algorithm to reduce the scenarios to form a classical scenario set to reduce the impact of wind power and PV output volatility. Finally, a carbon-trading mechanism is introduced to solve the model with the objective function of maximizing the net benefit and minimizing the carbon emissions of the virtual power plant. Using arithmetic examples for verification, the results show that the introduction of a carbon-trading mechanism can improve the net benefits of a VPP while promoting energy saving and emission reduction.
3. Generation of Classic Scene Sets
3.1. Latin Hypercube Sampling
Latin hypercube sampling is a method proposed by M. D. McKay, R. J. Beckman, and W. J. Conover in 1979 that can effectively use the distribution of sample response random variables [
27]. Latin hypercube sampling is a typical stratified sampling, which can be covered by a smaller and unduplicated sample for all sampling areas. The sampling is carried out in the following steps:
- (1)
Dividing the sample into equal intervals on the cumulative probability scale 0 to 1.
Let B be the number of samples; then, the vertical axis of is divided into B equal intervals, each interval is independent of each other without repetition, and the width of the interval is 1/B.
- (2)
Generate random numbers on each interval
Generating a random number
u in the interval shown in Equation (11), where
u is a random variable obeying uniform distribution on the interval (0,1), a random number
can be generated for the
ith interval, which can be expressed as:
- (3)
Inverting to generate sample values
The sampled values are calculated by the inverse function as:
The above steps lead to the B sample values.
3.2. Improved CLARA Clustering Algorithm
The CLARA clustering algorithm is a k-centroid clustering algorithm, which is a clustering algorithm proposed to deal with larger data sets.
The CLARA clustering algorithm first uses random sampling to randomly select a small fraction of the sample size at a time for PAM clustering, and then the remaining samples are grouped according to the minimum central distance. Among the results of each repetitive sampling clustering, the result with the smallest error, i.e., the centroid substitution cost, is selected as the final result. The core is, firstly, the large-scale data are sampled several times, and each sampled sample is clustered by PAM, and then the cluster centers of the multiple sampled samples are compared to select the optimal cluster center.
Algorithm disadvantage: The validity of CLARA depends on the size, distribution, and quality of the sample, so the algorithm will depend, to some extent, on the quality of the initial sampling. In addition, CLARA’s algorithm is to determine the center and then not to change it, which will have a certain element of luck. Suppose the k objects determined are far from the best center; then, CLARA will not get the best clustering center in the end how to choose the center.
Improvement: Considering the shortcomings of the CLARA algorithm, an improved CLARA clustering algorithm is proposed by combining the characteristics of Latin hypercube sampling. The random sampling in the first step of the CLARA clustering algorithm is replaced by Latin hypercube sampling, and the characteristics of stratified sampling of Latin hypercube sampling are used to stratify the wind power and PV output scenario samples, and then some samples are taken from each stratum for CLARA clustering, and the whole sample is covered by using limited and non-repetitive sampling. This method improves the accuracy of CLARA clustering results to a certain extent.
The steps to improve the CLARA algorithm are as follows.
- (1)
Multiple Latin hypercube sampling of large-scale data to obtain the sampled samples is conducted.
- (2)
PAM clustering of each sampled sample is conducted to obtain multiple sets of clustering centers.
- (3)
The sum of distances from the center of each group of clusters to all other points is found.
- (4)
The minimum value of the distance sum of these groups is found, and the group with the smallest distance sum is the optimal clustering center.
- (5)
The large-scale data are then clustered by distance to this set of optimal clustering centers.
The flow chart of the improved CLARA algorithm is shown in
Figure 1 below.