Micro-grid dynamic interval optimization scheduling method considering source load uncertainty

Photovoltaic and load prediction is carried out through the ConvLSTM-Attention-LSTM model and clustering algorithm, and combined with the ShapeDTW and CEEMDAN models, a dynamic interval optimization scheduling model is established, which solves the problem of traditional microgrid scheduling ignores source load uncertainty and improves operational stability and economical.

CN119050987AActive Publication Date: 2024-11-29ZHEJIANG UNIV OF TECH

Patent Information

Application Number
CN202411011530.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-26
Publication Date
2024-11-29
Estimated Expiration
2044-07-26

AI Technical Summary

Technical Problem

Traditional microgrid scheduling methods ignore source load uncertainty, resulting in insufficient operating efficiency and economics, making it difficult to cope with the randomness of renewable energy and loads.

Method used

The ConvLSTM-Attention-LSTM fusion prediction model is used to predict photovoltaic power, combined with photovoltaic power climbing clustering and ShapeDTW algorithm for dynamic interval prediction, and the load feature decomposition and prediction are used to calculate the prediction error through Kmeans clustering, and establish A microgrid dynamic interval optimization scheduling model that takes into account source load uncertainty.

Benefits of technology

The accuracy of photovoltaic power and load interval prediction is improved, the interval prediction width is reduced, the source load uncertainty is fully considered, the safe and stable operation of the microgrid is ensured, and the operation economy is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119050987A_ABST
    Figure CN119050987A_ABST
Patent Text Reader

Abstract

The invention belongs to the field of micro-grid optimal scheduling, and discloses a micro-grid dynamic interval optimal scheduling method considering source load uncertainty, which comprises the following steps of: 1, predicting photovoltaic power; step 2, photovoltaic power dynamic interval prediction; step 3, power load prediction; step 4, load dynamic interval prediction; and step 5, performing dynamic interval optimization scheduling of the micro-grid considering the source load uncertainty, firstly establishing a micro-grid dynamic interval optimization scheduling model considering the source load uncertainty, further establishing an objective function and a constraint condition of the micro-grid dynamic interval optimization scheduling model, and solving to obtain an optimization scheduling result of the micro-grid. According to the method, photovoltaic power prediction is carried out by using the ConvLSTM-Attention-LSTM fusion prediction model, and the model can more accurately capture space and time dependence in time sequence data, so that the prediction accuracy is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of microgrid optimization scheduling, and in particular to a microgrid dynamic interval optimization scheduling method considering source and load uncertainty. Background Art

[0002] With the rapid development of microgrids, their importance in power systems has become increasingly prominent. As a small, independently operated power system, microgrids are usually composed of multiple energy resources and loads, with high flexibility and reliability. However, due to the uncertainty of renewable energy and distributed energy contained in microgrids, as well as the randomness of loads, the optimization and scheduling of microgrids faces great challenges.

[0003] Most traditional microgrid scheduling methods are optimized based on deterministic models, ignoring the impact of source-load uncertainty on system operation. Therefore, in order to better cope with source-load uncertainty and improve the operating efficiency and economy of microgrids, this patent proposes a dynamic interval optimization scheduling method for microgrids that takes into account source-load uncertainty. This method first obtains the interval range of source-load uncertainty by predicting the error of photovoltaic power and power load in the microgrid. Then, based on the source-load interval range, dynamic intervals are used to schedule the microgrid to achieve optimal operation of the system in an uncertain environment. Compared with traditional deterministic optimization methods, this method fully considers the impact of source-load uncertainty and improves the operating stability and economy of the microgrid. Summary of the invention

[0004] The purpose of the present invention is to provide a microgrid dynamic interval optimization scheduling method considering source-load uncertainty. First, the ConvLSTM-Attention-LSTM fusion prediction model is used to train and predict the photovoltaic power after data cleaning and feature screening. Then, the power climbing clustering is used to perform weather analysis and ShapeDTW algorithm output dynamic interval prediction to obtain the dynamic interval result. Then, the CEEMDAN sequence decomposition model is used to decompose the load characteristics and FEDformer is used for model training and prediction. After Kmeans load clustering, the prediction error is calculated and the dynamic interval prediction result is optimized. Finally, the objective function and constraint conditions are set and solved to obtain the microgrid optimization scheduling result, so as to solve the problems raised in the above background technology.

[0005] To achieve the above object, the present invention provides the following technical solutions:

[0006] A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty, the method comprising the following steps:

[0007] Step 1: Photovoltaic power prediction: First, the original photovoltaic power data is processed and the Spearman correlation coefficient feature is screened. The photovoltaic data set is divided into a photovoltaic training set and a photovoltaic test set. Then, the ConvLSTM-Attention-LSTM fusion prediction model is used for training and prediction.

[0008] Step 2: PV power dynamic interval prediction: First, the PV test set prediction results are divided into multiple weather types through the PV power ramp clustering model, and then the interval range is calculated based on the dynamic interval prediction method of the ShapeDTW algorithm to obtain the dynamic interval prediction results;

[0009] Step 3, power load forecasting, firstly, the original load data is preprocessed and the Spearman correlation coefficient feature is screened, then the CEEMDAN sequence decomposition model is used to decompose the load features, the decomposed sequence and the screened data together constitute the training data, and the load data set is divided into load training set, load test set and load verification set, and finally the FEDformer model is used for model training and forecasting;

[0010] Step 4: Load dynamic interval prediction. First, the Kmeans clustering model is used to classify the load test set prediction results into multiple categories. The dynamic interval calculation formula is then used to calculate the dynamic prediction errors of multiple categories. The dynamic prediction errors are superimposed on the point prediction results to obtain the final photovoltaic and load interval prediction results.

[0011] Step 5, dynamic interval optimization scheduling of microgrid considering source-load uncertainty, firstly establish a dynamic interval optimization scheduling model of microgrid considering source-load uncertainty, further establish the objective function and constraint conditions of the dynamic interval optimization scheduling model of microgrid, and solve to obtain the optimization scheduling result of microgrid.

[0012] Furthermore, the step 1 specifically includes:

[0013] Step 1.1, preprocess the original photovoltaic power data to obtain initial features. The data preprocessing includes missing value processing, outlier processing and data standardization;

[0014] Step 1.2: Use the Spearman correlation coefficient to analyze the correlation between features and power of the processed photovoltaic power station historical data, delete features with less correlation, obtain the screened photovoltaic power station historical data, and divide the screened photovoltaic power station historical data into a photovoltaic training set and a photovoltaic test set of the ConvLSTM-Attention-LSTM fusion prediction model;

[0015] Step 1.3: Use the ConvLSTM-Attention-LSTM fusion prediction model to train the filtered historical data of photovoltaic power stations and predict future data.

[0016] Furthermore, the ConvLSTM-Attention-LSTM fusion prediction model is:

[0017] (1) The ConvLSTM-Attention-LSTM fusion prediction model is first reshaped into the dimensions required by the model, passed through several ConvLSTM networks and applied to the input; local spatial features are extracted through convolution operations to maintain the spatial continuity of the data. The convolution kernel slides region by region on the input feature map to perform calculations, and each time the weighted sum of local features is calculated, and then the state in the LSTM is updated based on these local features;

[0018] (2) The Attention mechanism is integrated into the ConvLSTM-Attention-LSTM fusion prediction model by using a custom attention function. First, the Permute layer is used to transpose the dimension of the input data. Then the data passes through a Dense layer and is processed using the softmax activation function. The output result can be regarded as the attention weight of each time step. Then the dimension of the attention weight is transposed again to restore it to the original order. Finally, the input data and the attention weight are multiplied at the element level. The output result is the data after the attention mechanism is applied.

[0019] (3) After completing the attention processing, the data is passed to several LSTM layers and the ReLU activation function is used; finally, the data is processed by the fully connected layer and the nonlinear transformation is completed by the ReLU activation function. Finally, after multiple iterations, the data is processed in the output layer to obtain the photovoltaic prediction result data.

[0020] Furthermore, the step 2 specifically includes:

[0021] Step 2.1, cluster the prediction results of the photovoltaic test set into n weather types through the photovoltaic power ramp clustering model;

[0022] Step 2.2, select k similar days of future prediction results from the prediction results of the photovoltaic test set through the ShapeDTW algorithm, calculate the prediction error of the similar days, find the maximum absolute value of the prediction error to obtain the interval range, and finally superimpose the interval range on the prediction result to obtain the final interval prediction result.

[0023] Furthermore, the photovoltaic power ramping clustering model is implemented using an improved optimized power ramping calculation formula, which is as follows:

[0024] P t '=P t (sgn((P t -P t-1 )·(P t -P t+1 )>0)(1)

[0025] ΔP t+i =P t+i -P t '(i=1,…,τ) (2)

[0026] P ε =ηP d (3)

[0027] Where, t is the time of slope detection; P t ——power at time t; P t '——Possible climbing point; ΔP t+i ——The power difference between time t+i and time t; P ε ——climbing threshold; τ——climbing duration threshold; P d ——PV installed capacity, η——ramp threshold as a percentage of installed capacity, sgn(*) is the sgn function;

[0028] The improved power ramp calculation formula determines the ramp starting point and continuous ramp by traversing the power data points; sets the ramp threshold to filter the regular daily power trend points, and sets the ramp time threshold to select irregular power fluctuations, thereby identifying effective ramp events;

[0029] Based on the improved power ramp calculation formula, the power ramp detection process is as follows:

[0030] S100, first traverse each power data from the first point, and use formula (1) to determine whether it is a possible power climbing point;

[0031] S101, then use formula (2) to determine whether it is a real climbing point;

[0032] S102, further determine the duration of the climbing by calculating the time at the subsequent data point P t+i (i=1, 2, 3, ...), determine whether there is |ΔP t+i |>P ε (i=1,…,τ) climbing point, when i<τ, the climbing value ΔP=ΔP t+i , ΔP>0 is the up-climbing point, ΔP<0 is the down-climbing point; τ is the specified time threshold, when i>τ, stop the judgment at the current moment; the climbing judgment of the points after the continuous climbing interval t~t+i, if it exists, it constitutes a continuous climbing point together with the climbing interval;

[0033] S103, continue judging other points until all points are traversed, and finally record the climbing value, climbing time, and climbing number of the climbing point;

[0034] Using the improved power ramp calculation formula, the photovoltaic ramp characteristics are constructed and calculated and counted. The photovoltaic ramp characteristics include the photovoltaic power ramp value, the duration of the ramp, and the number of ramps. The photovoltaic power ramp clustering model uses these photovoltaic ramp characteristics to divide the data of each day into four categories according to the weather type: sunny, a little cloudy, cloudy, and rainy.

[0035] The workflow of the photovoltaic power ramping clustering model is as follows:

[0036] S200, based on the photovoltaic power ramp clustering model, first obtains the data after the photovoltaic power ramp detection, and counts the number of daily ramps and the daily average power in units of days;

[0037] S201, then preliminarily judge the weather type based on the daily average power. If the daily average power is less than the threshold value P mean , it is directly judged as a rainy day; if the daily average power is greater than or equal to the threshold P mean , when the climbing times is 0, it is sunny; when the climbing times is (0, N 1 ] is the type of weather with few clouds; the number of climbs is (N 1 ,N 2 ] is cloudy weather type; the number of climbing times is greater than N 2 The weather type is cloudy and rainy when the clustering occurs. The judgment of other days is continued until all days are traversed, and finally the clustering results are recorded to complete the photovoltaic power ramp clustering detection process.

[0038] Furthermore, the photovoltaic power ramping clustering model is:

[0039] Based on the ShapeDTW algorithm, a clustering model of photovoltaic power ramp-up similar days is constructed. The photovoltaic power time series τ=(t 1 ,t 2 ,…t L ) T ,τ∈R L , R L Represents the L-dimensional space composed of real numbers R. First, at each time point t in the sequence i Extract a subsequence s of length l i ;Subsequence s i With t i The length l is much smaller than L, and a series of subsequences are obtained, namely S = (s 1 ,s 2 ,…s L ) T,s i ∈R l , R l represents the l-dimensional space composed of real numbers R, where s i Corresponding to time point t i ;

[0040] Then, shape descriptors are used to represent subsequences. Subsequences with similar shapes have similar descriptors, while subsequences with different shapes have different descriptors. i The shape descriptor of naturally encodes the time point t i The surrounding local structural information;

[0041] Designing a shape descriptor boils down to designing a mapping function F(·) that maps a subsequence s i ∈R l to the shape descriptor d i ∈R m , R m represents the m-dimensional space composed of real numbers R, that is, d i =F(s i ), using Euclidean distance to measure the similarity between descriptors; given a shape descriptor calculation function F(·), select the slope as the shape descriptor calculation function; convert the subsequence S into a descriptor sequence D; after the above conversion, use the DTW algorithm to align the two descriptor sequences, and points with similar local shapes tend to be aligned;

[0042] D=(d 1 ,d 2 ,…d L ) T ,d i ∈R m

[0043] D=F(S)=[F(s 1 ),F(s 2 ),…,F(s L )] T .

[0044] Furthermore, the step 3 specifically includes:

[0045] Step 3.1, preprocess the original load data, including missing values, outliers and standardization processing;

[0046] Step 3.2, analyze the periodicity of the original load data after preprocessing, and use the Spearman correlation coefficient to perform feature screening to obtain load characteristics;

[0047] Step 3.3, use the CEEMDAN sequence decomposition model to decompose the load characteristics, and the decomposed sequence and the filtered data together constitute the training data;

[0048] Step 3.4, finally, divide the training data into load training set, load test set and load verification set, and use FEDformer model training until the model training is completed, and save the optimal training model.

[0049] Furthermore, the step 4 specifically includes:

[0050] Step 4.1, obtain the load test set, use the optimal FEDformer model to predict the load test set, and obtain the prediction result of the load test set;

[0051] Step 4.2, classify the prediction results of the load test set into m categories, and obtain cluster prediction results of m categories;

[0052] Step 4.3, calculate the clustering prediction error of m categories, use the dynamic interval calculation formula to get the interval range of different categories, superimpose the interval range on the prediction result, and get the final interval prediction result. The dynamic interval calculation formula is as follows:

[0053]

[0054] In the formula, E negtive (t)——the lower bound of the interval at time t; E postive (t)——the upper bound of the interval at the tth moment; e(t)——the prediction error at the tth moment; e(t) Q(i) ——The i-th Q(i) that satisfies the condition at time t 1 ,i 2 ,i 3 ,i 4 Quartile; σ 1 , σ 2 ——Set the adjustment threshold.

[0055] Furthermore, the step 5 specifically includes:

[0056] Step 5.1, the optimization operation of the microgrid takes minimization of daily operation cost as the objective function, which is calculated by the total operation cost of each system of the microgrid. The environmental protection is determined by the equivalent cost of pollution emission control of the microgrid, and the safety is achieved through the constraints of the operation of each system of the microgrid and the system operation control;

[0057] The daily operating cost formula of the microgrid is as follows:

[0058]

[0059] In the formula, C is the total daily operating cost of the system (yuan); ac (t)——Daily operating cost of battery (yuan); C mt(t)——Daily operating cost of micro gas turbine (yuan); C grid (t)——interaction cost between microgrid and distribution network; C ep (t)——total cost of environmental protection operation (yuan);

[0060] (1) Economical operation of microgrids

[0061] The average charging and discharging cost of the battery in period t is C ac (t) is expressed as:

[0062]

[0063] In the formula, K ac ——Converted unit charging and discharging cost of energy storage; and ——represent the charging power and discharging power of the energy storage during time period t; η ac ——Charging and discharging efficiency of energy storage unit; Δt——scheduling step length;

[0064] The cost function of the micro gas turbine is:

[0065] C mt (t) = [aP mt (t)+b]Δt

[0066] In the formula, C mt (t)——operating cost of micro gas turbine in period t; P mt (t)——output power of micro gas turbine in period t; a, b——cost coefficients of fitting function;

[0067] The interaction cost between the microgrid and the distribution network can be expressed as:

[0068]

[0069] Where, λ(t) is the time-of-use electricity price of the distribution network; ——The electric power purchased and sold by the microgrid from the distribution network;

[0070] (2) Environmental friendliness of microgrid operation

[0071] The calculation formula for the environmental protection of microgrid operation is as follows:

[0072]

[0073] In the formula, i——represents different pollutants; β i ——the cost of treating pollutant i; P grid (t)——dispatching power of the power grid; ——emission fitting coefficient of pollutant i in the distribution network; ——emission fitting coefficient of micro gas turbine pollutant i;

[0074] (3) Microgrid operation safety

[0075] The safety of the microgrid is realized through the constraints of the operation of each system and the system operation control to realize the operation constraints of photovoltaic, energy storage, and micro gas turbine systems, and the energy balance constraints supply and demand balance; the power balance constraints of the microgrid are as follows:

[0076]

[0077] In the formula, —— is the actual consumption value of photovoltaic power; P mt (t)——power generation of micro gas turbine; P load (t)——electrical load of the system; P ac (t)——battery charging and discharging power; ——Discharge and charge status, charge and discharge status are 0-1 variables;

[0078] Energy storage system operation constraints:

[0079] The operation constraints of the microgrid energy storage system include charging and discharging power constraints, equal initial and final capacity, and remaining capacity. The energy storage unit constraints are as follows:

[0080]

[0081] In the formula, ——The maximum charge and discharge power allowed by energy storage; μ ac (t)——Charging and discharging state of energy storage, the discharge state value is 1, and the charging state value is 0; E ac (0)——the capacity of the energy storage at the initial moment, ——The minimum and maximum remaining capacity allowed during the dispatch process;

[0082] The operating constraints of the micro gas turbine are as follows:

[0083]

[0084] In the formula, ——Minimum output power and maximum output power of the micro gas turbine;

[0085] Distribution network interaction constraints:

[0086] The constraints for power exchange between the microgrid and the distribution network are as follows:

[0087]

[0088] In the formula, ——The maximum value of the power exchanged between the microgrid and the distribution network; μ grid (t)——The power purchase and sale status between the microgrid and the distribution network. The value is 1 when the microgrid purchases power from the distribution network, and the value is 0 when the microgrid sells power to the distribution network;

[0089] Step 5.2: Based on the interval prediction results of steps 2 and 4, the prediction error range of photovoltaic output and load power is constructed into an interval prediction uncertainty set U, as shown in the following formula:

[0090]

[0091] In the formula, u is an uncertain variable; pv (t)——PV power uncertainty variable; u load (t)——Uncertain variable of load power; ——Minimum and maximum values ​​of the PV power uncertainty variable; ——the minimum and maximum values ​​of the load uncertainty variables; ——set of real numbers; N——positive real number;

[0092] The optimal optimization scheduling result is obtained by solving the dynamic interval optimization scheduling model of the microgrid. The focus is on finding the most economically optimal and safest scheduling scheme when the uncertain variable u changes towards the most unfavorable situation in the interval prediction uncertainty set u. It has the following form:

[0093]

[0094] Where, min[·] is the first-stage optimization problem, with the optimization variable x; maxmin(·) is the second-stage optimization problem, with the optimization variables u and y, where the minimization problem represents minimizing the operating cost; c is the objective function; and the maximization problem represents the scenario that leads to the most unfavorable operating cost.

[0095] Step 5.3, combined with the interval prediction uncertainty set U, the problem can be summarized as follows, and the optimal dispatch result of the microgrid is obtained:

[0096]

[0097] In the formula, D, K, F, G, I u ——The coefficient matrix of the variables under the corresponding constraints; d, h, γ, λ, ν, π——constant column vector; B pv (t), B load (t)——binary 0-1 variable; λ pv ——“uncertainty adjustment parameter” of photovoltaic power; λ load ——“Uncertainty adjustment parameter” of load power;

[0098] By solving the optimal dispatching variables based on the power and load uncertainty sets, the optimal dispatching variable values ​​and dispatching strategies that minimize the operating cost are obtained.

[0099] Compared with the prior art, the present invention has the following beneficial effects:

[0100] 1) The present invention uses the ConvLSTM-Attention-LSTM fusion prediction model to predict photovoltaic power. The model can more accurately capture the spatial and temporal dependencies in time series data, thereby improving the accuracy of the prediction;

[0101] 2) The present invention uses a photovoltaic dynamic interval prediction model based on power ramp clustering and ShapeDTW. The prediction results of the test data set are divided into different weather types through the power ramp clustering model, and the interval range is further calculated using the dynamic interval prediction method based on the ShapeDTW algorithm. The model can effectively improve the accuracy of interval prediction;

[0102] 3) The present invention uses a load dynamic interval prediction model based on Kmeans clustering, uses the Kmeans clustering model to divide the prediction results of the test data set into different categories, and further uses the dynamic interval calculation formula to calculate the dynamic prediction errors of different categories to obtain the load interval prediction results. The model can effectively improve the load interval prediction accuracy and reduce the interval prediction width;

[0103] 4) The present invention uses a dynamic interval optimization scheduling model for microgrids that takes into account source-load uncertainty, establishes a two-stage robust optimization model that takes into account source-load uncertainty, and performs microgrid optimization scheduling by building the interval prediction results of photovoltaic output and load power into an interval prediction uncertainty set. The model fully considers source-load uncertainty and ensures the safe and stable operation of the microgrid. BRIEF DESCRIPTION OF THE DRAWINGS

[0104] Figure 1 It is a flow chart of the present invention;

[0105] Figure 2 It is the flow chart of photovoltaic dynamic interval prediction;

[0106] Figure 3 This is the workflow diagram of the load dynamic interval prediction model. DETAILED DESCRIPTION

[0107] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0108] like Figure 1 As shown, a dynamic interval optimization scheduling method for a microgrid considering source-load uncertainty includes the following steps:

[0109] Step 1: PV power prediction. First, the original PV power data is processed and the Spearman correlation coefficient feature is screened. The original PV power data comes from the open source data set. The PV data set is divided into a PV training set and a PV test set. Then, the ConvLSTM-Attention-LSTM fusion prediction model is used for training and prediction. This model is a deep learning model that integrates Convolutional Long Short-Term Memory (ConvLSTM), Attention Mechanism (Attention) and LSTM. Specifically, it includes:

[0110] Step 1.1: Preprocess the original photovoltaic power data, that is, the historical data of photovoltaic power stations, to obtain initial features. Data preprocessing includes missing value processing, outlier processing and data standardization. In this implementation case, missing values ​​are filled in the front and back terms, and outliers are not processed.

[0111] Step 1.2: further analyze the correlation between features and power using the Spearman correlation coefficient on the processed data, delete features with less correlation, and obtain the screened historical data of photovoltaic power stations. The screened historical data of photovoltaic power stations are divided into photovoltaic training set and photovoltaic test set of ConvLSTM-Attention-LSTM fusion prediction model. In this implementation case, the photovoltaic test set data is the data 180 days after the original data.

[0112] Step 1.3, use the ConvLSTM-Attention-LSTM fusion prediction model to train the filtered historical data of photovoltaic power stations, predict future data, and obtain the prediction results of the photovoltaic test set. In this implementation case, the data of 96 points in the next day are predicted.

[0113] The above ConvLSTM-Attention-LSTM fusion prediction model is:

[0114] (1) The fusion prediction model is first reshaped into the dimensions required by the model, passed through several ConvLSTM networks and applied to the input. The local spatial features are extracted through the convolution operation to maintain the spatial continuity of the data. The convolution kernel will slide region by region on the input feature map to perform calculations, and each time the weighted sum of local features is calculated, and then the state in the LSTM is updated based on these local features.

[0115] (2) The Attention mechanism is integrated into the fusion model by using a custom attention function. First, the Permute layer is used to transpose the dimension of the input data. Then the data passes through a Dense layer and is processed using the softmax activation function. The output result can be regarded as the attention weight of each time step. After that, the dimension of the attention weight is transposed again to restore it to the original order. Finally, the input data and the attention weight are multiplied at the element level. The output result is the data after the attention mechanism is applied.

[0116] (3) After the attention processing is completed, the data is passed to several LSTM layers and the ReLU activation function is used. Finally, the data is processed by the fully connected layer and the nonlinear transformation is completed by the ReLU activation function. Finally, after multiple iterations, the data is processed in the output layer to obtain the photovoltaic prediction result data.

[0117] Step 2: PV power dynamic interval prediction. First, the PV test set prediction results are divided into multiple weather types through the PV power ramp clustering model. Then, the dynamic interval prediction method based on the ShapeDTW algorithm is used to calculate the interval range and obtain the dynamic interval prediction results, including:

[0118] Step 2.1: Cluster the prediction results of the photovoltaic test set into n types of weather types through the photovoltaic power ramp clustering model. The principle of the power ramp clustering model is as follows:

[0119] The power ramp clustering model is implemented using an improved power ramp calculation formula, which includes power ramp value and ramp time. The formula is as follows:

[0120] P t '=P t (sgn((P t -P t-1 )·(P t -P t+1 )>0) (1)

[0121] ΔP t+i =P t+i -P′ t (i=1,…,τ) (2)

[0122] P ε =ηP d (3)

[0123] Where, t is the time of slope detection; P t ——power at time t; P t '——Possible climbing point; ΔPt+i——Power difference between time t+i and time t; P ε——climbing threshold; τ——climbing duration threshold; P d ——PV installed capacity, η——ramp threshold as a percentage of installed capacity, in this implementation case η is 20%, sgn(*) is the sgn function.

[0124] The improved power ramp calculation formula determines the starting point of ramping and continuous ramping by traversing power data points; sets the ramp threshold to filter the regular daily trend points of power, and sets the ramp time threshold to select irregular power fluctuations, thereby identifying effective ramping events.

[0125] Based on the above optimized photovoltaic power ramp detection formula, the power ramp detection process is as follows:

[0126] S100, first traverse each power data from the first point, and use formula (1) to determine whether it is a possible power climbing point.

[0127] S101, then use formula (2) to determine whether it is a real climbing point.

[0128] S102, further determine the duration of the climbing by calculating the time at the subsequent data point P t+i (i=1, 2, 3, ...), determine whether there is |ΔP t+i |>P ε (i=1,…,τ) climbing point, when i<τ, the climbing value ΔP=ΔP t+i , ΔP>0 is the up-climbing point, ΔP<0 is the down-climbing point; τ is the specified time threshold, when i>τ, stop the judgment at the current moment; the climbing judgment of the points after the continuous climbing interval t~t+i, if it exists, it constitutes a continuous climbing point together with the climbing interval.

[0129] S103, continue judging other points until all points are traversed, and finally record the climbing value, climbing time, and climbing number of the climbing point.

[0130] The photovoltaic power ramp clustering model is:

[0131] Based on the ShapeDTW algorithm, a clustering model of photovoltaic power ramp-up similar days is constructed. The photovoltaic power time series τ=(t 1 ,t 2 ,…t L ) T ,τ∈R L , R L Represents the L-dimensional space composed of real numbers R. First, at each time point t in the sequence i Extract a subsequence s of length l i . subsequences i With t iThe length l is much smaller than L. A series of subsequences are obtained, namely S = (s 1 ,s 2 ,…s L ) T ,s i ∈R l , R l represents the l-dimensional space composed of real numbers R, where s i Corresponding to time point t i .

[0132] Then, shape descriptors are used to represent subsequences. Subsequences with similar shapes have similar descriptors, while subsequences with different shapes have different descriptors. i The shape descriptor of naturally encodes the time point t i The surrounding local structure information.

[0133] Designing a shape descriptor boils down to designing a mapping function F(·) that maps a subsequence s i ∈R l to the shape descriptor d i ∈R m , R m represents the m-dimensional space composed of real numbers R, that is, d i =F(s i ), and the Euclidean distance is used to measure the similarity between descriptors. Given a shape descriptor calculation function F(·), the slope is selected as the shape descriptor calculation function, and the subsequence S is converted to a descriptor sequence D. After the above conversion, the DTW algorithm is used to align the two descriptor sequences, and points with similar local shapes tend to be aligned.

[0134] D=(d 1 ,d 2 ,…d L ) T ,d i ∈R m

[0135] D=F(S)=[F(s 1 ),F(s 2 ),…,F(s L )] T .

[0136] Using the improved power ramp calculation formula, the photovoltaic ramp characteristics are constructed and calculated and counted. The photovoltaic ramp characteristics include the photovoltaic power ramp value, the duration of the ramp, and the number of ramps. The photovoltaic power ramp clustering model uses these photovoltaic ramp characteristics to divide the data of each day into four categories according to the weather type: sunny, few clouds, cloudy, and rainy.

[0137] The workflow of the photovoltaic power ramp clustering model is as follows:

[0138] S200, based on the photovoltaic power ramp clustering model, firstly obtain the data after the photovoltaic power ramp detection, and count the daily ramp times and the daily average power in units of days.

[0139] S201, then preliminarily judge the weather type based on the daily average power, and divide the weather into four types: sunny, lightly cloudy, cloudy, and rainy. If the daily average power is less than the threshold value P mean , it is directly judged as a rainy day; if the daily average power is greater than the threshold P mean , when the climbing times is 0, it is sunny; when the climbing times is (0, N 1 ] is n 1 Weather type; climbing times (N 1 ,N 2 ] is n 2 Weather type; climbing times greater than N 2 When n 2 Weather type; continue to judge other days until all days are traversed, and finally record the clustering results to complete the photovoltaic power ramp clustering detection process. In this implementation case, the daily average power is greater than the threshold P mean , when the climbing times is 0, it is sunny; when the climbing times is (0, N 1 ] is a lightly cloudy day; the number of climbs is (N 1 ,N 2 ] is cloudy weather; the number of climbs is greater than N 2 It is cloudy and rainy at that time.

[0140] Step 2.2, select k similar days of future prediction results from the prediction results of the photovoltaic test set through the ShapeDTW algorithm, calculate the prediction error of the similar days, find the maximum absolute value of the prediction error to obtain the interval range, and finally superimpose the interval range on the prediction result to obtain the final interval prediction result. In this implementation case, k is selected as 5.

[0141] Step 3, power load forecasting, first preprocess the original load data and screen the Spearman correlation coefficient features, then use the CEEMDAN sequence decomposition model to decompose the load features, and use the decomposed sequence and screened data to form training data. The load data set is divided into load training set, load test set and load verification set, and finally FEDformer is used for model training and forecasting, which includes:

[0142] Step 3.1, preprocess the original load data, including missing values, outliers and standardization. In this implementation case, missing values ​​are filled with the adjacent date of the previous day, and outliers are filled with the previous and next items.

[0143] Step 3.2, further analyze the periodicity of the original load data after preprocessing, and use the Spearman correlation coefficient to perform feature screening to obtain load characteristics.

[0144] In step 3.3, the CEEMDAN sequence decomposition model is used to decompose the load characteristics, and the decomposed sequence and the filtered data together constitute the training data.

[0145] Step 3.4, divide the training data into load training set, load test set and load verification set, use FEDformer model training until the model training is completed, and save the optimal training model.

[0146] Step 4: Load dynamic interval prediction. First, the Kmeans clustering model is used to divide the load test set prediction results into multiple categories. The dynamic interval calculation formula is further used to calculate the dynamic prediction errors of multiple categories. The dynamic prediction errors are superimposed on the point prediction results to obtain the final photovoltaic and load interval prediction results, which include:

[0147] Step 4.1, obtain the load test set, use the optimal FEDformer model to predict the load test set, and obtain the prediction result of the load test set.

[0148] Step 4.2, the prediction results of the load test set are divided into m categories to obtain cluster prediction results of m categories. In this implementation case, m is 4, which are divided into 4 categories: high load, medium-high load, medium-low load and low load.

[0149] Step 4.3, calculate the cluster prediction errors of the four categories, use the dynamic interval calculation formula to get the interval range of different categories, superimpose the interval range on the point prediction result, and get the final interval prediction result. The dynamic interval calculation formula is as follows:

[0150]

[0151] In the formula, E negtive (t)——the lower bound of the interval at time t; E postive (t)——the upper bound of the interval at the tth moment; e(t)——the prediction error at the tth moment; e(t) Q(i) ——The i-th Q(i) that satisfies the condition at time t 1 ,i 2 ,i 3 ,i 4 Quartile; σ 1 , σ 2 ——The set adjustment threshold. In this implementation case, Q(i) is the upper quartile.

[0152] Step 5, dynamic interval optimization scheduling of microgrid considering source-load uncertainty, firstly establish a dynamic interval optimization scheduling model of microgrid considering source-load uncertainty, further establish the objective function and constraint conditions of the dynamic interval optimization scheduling model of microgrid, and solve to obtain the optimization scheduling result of microgrid, specifically including:

[0153] Step 5.1, the optimization operation of the microgrid takes the minimization of daily operation cost as the objective function to ensure the economy, environmental protection and safety of the microgrid. In terms of economy, it is calculated through the total operation cost of each system of the microgrid. The environmental protection of the microgrid operation is determined by the equivalent cost of the pollution emission control of the system. The safety is achieved through the constraints of each system operation and system operation control. Specifically, the daily operation cost of the microgrid can be expressed by the following formula:

[0154]

[0155] Where, minC is the minimum value of the system daily operating total cost C (yuan); C ac (t)——Daily operating cost of battery (yuan); C mt (t)——Daily operating cost of micro gas turbine (yuan); C grid (t)——interaction cost between microgrid and distribution network; C ep (t)——Total cost of environmental protection operation (yuan).

[0156] (1) Economical operation of microgrids

[0157] The average charging and discharging cost of the battery in period t is C ac (t) is expressed as:

[0158]

[0159] In the formula, K ac ——Converted unit charging and discharging cost of energy storage; and ——represent the charging power and discharging power of the energy storage during time period t; η ac ——Charging and discharging efficiency of the energy storage unit; Δt——scheduling step size.

[0160] The cost function of the micro gas turbine is:

[0161] C mt (t) = [aP mt (t)+b]Δt

[0162] In the formula, C mt (t)——operating cost of micro gas turbine in period t; P mt (t)——output power of micro gas turbine in period t; a, b——cost coefficients of fitting function.

[0163] The interaction cost between the microgrid and the distribution network can be expressed as:

[0164]

[0165] Where, λ(t) is the time-of-use electricity price of the distribution network; ——The electric power purchased and sold by the microgrid from the distribution network.

[0166] (2) Environmental friendliness of microgrid operation

[0167] The environmental friendliness of microgrid operation is determined by the equivalent cost of pollution emission control of the system, where the pollution emission control equivalent is determined by the amount of natural gas of the micro gas turbine and the amount of electricity purchased by the distribution network. The formula for calculating the environmental friendliness of microgrid operation is as follows:

[0168]

[0169] In the formula, i represents different pollutants, including CO 2 、SO 2 and NO X Several types of pollutants; i ——the cost of treating pollutant i; P grid (t)——dispatching power of distribution network; P mt (t) —— dispatch power of micro gas turbine; ——emission fitting coefficient of pollutant i in the distribution network; ——Emission fitting coefficient of micro gas turbine pollutant i. In this implementation case, CO 2 、SO 2 and NO X The treatment costs are 0.02, 2.375 and 2.12 respectively. 2 、SO 2 and NO X The pollutant emission coefficients are 0.22 and 1.8×10 -3 and 1.6×10 -3 , CO in micro gas turbine 2 、SO 2 and NO X The pollutant emission coefficients are 0.968, 0.968 and 1.98×10 -6 .

[0170] (3) Microgrid operation safety

[0171] The safety of the microgrid is achieved through the operating constraints of each system in the microgrid and the system operation control, including the operation constraints of photovoltaic, energy storage, and micro gas turbine systems, and the energy balance constraints and supply and demand balance.

[0172] The power balance constraint of the microgrid requires that all sources and loads in the microgrid be balanced to ensure the balance of power supply and demand in the microgrid. The power balance constraint of the microgrid is as follows:

[0173]

[0174] In the formula, ——Power purchased from the power grid; ——Power sold by the power grid; ——actual consumption value of photovoltaic power; P mt (t)——power generation of micro gas turbine; P load (t)——microgrid electric load; P ac (t)——battery charging and discharging power; ——Discharge and charge status, charge and discharge status are 0-1 variables.

[0175] The operation constraints of the microgrid energy storage system include charging and discharging power constraints, equal initial and final capacity, and remaining capacity. The energy storage unit must meet the following constraints during operation:

[0176]

[0177]

[0178] In the formula, ——The maximum charge and discharge power allowed by energy storage; μ ac (t)——Charging and discharging state of energy storage, the discharge state value is 1, and the charging state value is 0; E ac (0)——the capacity of the energy storage at the initial moment, ——The minimum and maximum remaining capacity allowed during the dispatch process. 500kW, 1600kWh, 80kWh, E ac (0) is 800kWh.

[0179] The power output of the micro gas turbine should meet the load demand within the microgrid. At the same time, the maximum power output limit of the micro gas turbine should also be considered. The micro gas turbine only considers the output power constraint:

[0180]

[0181] In the formula, ——The minimum and maximum output power of the micro gas turbine. In the implementation case, 300Kw, is 0.

[0182] The power interaction between the microgrid and the distribution network mainly includes the purchase and sale of electricity. The power exchange between the microgrid and the distribution network must follow certain constraints:

[0183]

[0184] In the formula, ——The maximum value of the power exchanged between the microgrid and the distribution network; ——The electric power purchased and sold by the microgrid from the distribution network; ——The electric power purchased and sold by the microgrid from the distribution network. grid (t)——The power purchase and sale status between the microgrid and the distribution network. When the microgrid purchases power from the distribution network, the value is 1; when the microgrid sells power to the distribution network, the value is 0. It is 400kW.

[0185] Step 5.2: Establish a two-stage robust optimization model considering source-load uncertainty and solve it to obtain the optimal optimization scheduling result. Based on the interval prediction results of steps 2 and 4, the prediction error range of photovoltaic output and load power is constructed into an interval prediction uncertainty set U, as shown in the following formula:

[0186]

[0187] In the formula, u is an uncertain variable; pv (t)——PV power uncertainty variable; u load (t)——Uncertain variable of load power; ——Minimum and maximum values ​​of the PV power uncertainty variable; ——the minimum and maximum values ​​of the load uncertainty variables; ——The set of real numbers; N——a positive real number.

[0188] The two-stage robust optimization model considering the dynamic range of source and load aims to find the most economically optimal and safest scheduling scheme when the uncertain variable u changes towards the most unfavorable situation in the uncertainty set U. It has the following form:

[0189]

[0190] Where min[·] is the first-stage optimization problem, with the optimization variable x; maxmin(·) is the second-stage optimization problem, with the optimization variables u and y, where the minimization problem represents minimizing the operating cost; c is the objective function; and the maximization problem represents the scenario that leads to the most unfavorable operating cost.

[0191] Step 5.3, finally combined with the uncertain set, the problem can be summarized as follows, and the optimal dispatch result of the microgrid is obtained:

[0192]

[0193] In the formula, D, K, F, G, I u ——The coefficient matrix of the variables under the corresponding constraints; d, h, γ, λ, ν, π——constant column vector; B pv (t), B load (t)——binary 0-1 variable; λ pv ——“uncertainty adjustment parameter” of photovoltaic power; λ load ——“uncertainty adjustment parameter” of load power. In the implementation case, λ pv , load Both are taken as 24.

[0194] By solving the optimal dispatching variables based on the power and load uncertainty sets, the optimal dispatching variable values ​​and dispatching strategies that minimize the operating cost are obtained.

[0195] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.

Claims

1. A microgrid dynamic interval optimization scheduling method considering source and load uncertainty, characterized in that: The method comprises the following steps: Step 1: Photovoltaic power prediction: First, the original photovoltaic power data is processed and the Spearman correlation coefficient feature is screened. The photovoltaic data set is divided into a photovoltaic training set and a photovoltaic test set. Then, the ConvLSTM-Attention-LSTM fusion prediction model is used for training and prediction. Step 2: PV power dynamic interval prediction: First, the PV test set prediction results are divided into multiple weather types through the PV power ramp clustering model, and then the interval range is calculated based on the dynamic interval prediction method of the ShapeDTW algorithm to obtain the dynamic interval prediction results; Step 3, power load forecasting, firstly, the original load data is preprocessed and the Spearman correlation coefficient feature is screened, then the CEEMDAN sequence decomposition model is used to decompose the load features, the decomposed sequence and the screened data together constitute the training data, and the load data set is divided into load training set, load test set and load verification set, and finally the FEDformer model is used for model training and forecasting; Step 4: Load dynamic interval prediction. First, the Kmeans clustering model is used to classify the load test set prediction results into multiple categories. The dynamic interval calculation formula is then used to calculate the dynamic prediction errors of multiple categories. The dynamic prediction errors are superimposed on the point prediction results to obtain the final photovoltaic and load interval prediction results. Step 5, dynamic interval optimization scheduling of microgrid considering source-load uncertainty, firstly establish a dynamic interval optimization scheduling model of microgrid considering source-load uncertainty, further establish the objective function and constraint conditions of the dynamic interval optimization scheduling model of microgrid, and solve to obtain the optimization scheduling result of microgrid.

2. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The step 1 specifically includes: Step 1.1, preprocess the original photovoltaic power data to obtain initial features. The data preprocessing includes missing value processing, outlier processing and data standardization; Step 1.2: Use the Spearman correlation coefficient to analyze the correlation between features and power of the processed photovoltaic power station historical data, delete features with less correlation, obtain the screened photovoltaic power station historical data, and divide the screened photovoltaic power station historical data into a photovoltaic training set and a photovoltaic test set of the ConvLSTM-Attention-LSTM fusion prediction model; Step 1.3: Use the ConvLSTM-Attention-LSTM fusion prediction model to train the filtered historical data of photovoltaic power stations and predict future data.

3. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The ConvLSTM-Attention-LSTM fusion prediction model is: (1) The ConvLSTM-Attention-LSTM fusion prediction model is first reshaped into the dimensions required by the model, passed through several ConvLSTM networks and applied to the input; local spatial features are extracted through convolution operations to maintain the spatial continuity of the data. The convolution kernel slides region by region on the input feature map to perform calculations, and each time the weighted sum of local features is calculated, and then the state in the LSTM is updated based on these local features; (2) The Attention mechanism is integrated into the ConvLSTM-Attention-LSTM fusion prediction model by using a custom attention function. First, the Permute layer is used to transpose the dimension of the input data. Then the data passes through a Dense layer and is processed using a softmax activation function. The output result can be regarded as the attention weight of each time step. Then the dimensions of the attention weights are transposed again to restore them to their original order, and finally the input data and the attention weights are multiplied element-wise, and the output result is the data after the attention mechanism is applied; (3) After completing the attention processing, the data is passed to several LSTM layers and the ReLU activation function is used; finally, the data is processed by the fully connected layer and the nonlinear transformation is completed by the ReLU activation function. Finally, after multiple iterations, the data is processed in the output layer to obtain the photovoltaic prediction result data.

4. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The step 2 specifically includes: Step 2.1, cluster the prediction results of the photovoltaic test set into n weather types through the photovoltaic power ramp clustering model; Step 2.2, select k similar days of future prediction results from the prediction results of the photovoltaic test set through the ShapeDTW algorithm, calculate the prediction error of the similar days, find the maximum absolute value of the prediction error to obtain the interval range, and finally superimpose the interval range on the prediction result to obtain the final interval prediction result.

5. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 4, characterized in that: The photovoltaic power ramp clustering model is implemented using an improved optimized power ramp calculation formula, which is as follows: P t '=P t (sgn((P t -P t-1 )·(P t -P t+1 )>0) (1) ΔP t+i =P t+i -P t '(i=1,...,τ) (2) P ε =ηP d (3) Where, t is the time of slope detection; P t ——power at time t; P t '——Possible climbing point; ΔP t+i ——The power difference between time t+i and time t; P ε ——climbing threshold; τ——climbing duration threshold; P d ——PV installed capacity, η——ramp threshold as a percentage of installed capacity, sgn(*) is the sgn function; The improved power ramp calculation formula determines the ramp starting point and continuous ramp by traversing the power data points; Set the ramp threshold to filter the regular daily power trend points, and set the ramp time threshold to select irregular power fluctuations, thereby identifying effective ramp events; Based on the improved power ramp calculation formula, the power ramp detection process is as follows: S100, first traverse each power data from the first point, and use formula (1) to determine whether it is a possible power climbing point; S101, then use formula (2) to determine whether it is a real climbing point; S102, further determine the duration of the climbing by calculating the time at the subsequent data point P t+i (i=1, 2, 3, ...), determine whether there is |ΔP t+i |>P ε (i=1,...,τ) climbing point, when i<τ, the climbing value ΔP=ΔP t+i , ΔP>0 is the up-climbing point, ΔP<0 is the down-climbing point; τ is the specified time threshold, when i>τ, stop the judgment at the current moment; the climbing judgment of the points after the continuous climbing interval t~t+i, if it exists, it constitutes a continuous climbing point together with the climbing interval; S103, continue judging other points until all points are traversed, and finally record the climbing value, climbing time, and climbing number of the climbing point; Using the improved power ramp calculation formula, the photovoltaic ramp characteristics are constructed and calculated and counted. The photovoltaic ramp characteristics include the photovoltaic power ramp value, the duration of the ramp, and the number of ramps. The photovoltaic power ramp clustering model uses these photovoltaic ramp characteristics to divide the data of each day into four categories according to the weather type: sunny, a little cloudy, cloudy, and rainy. The workflow of the photovoltaic power ramping clustering model is as follows: S200, based on the photovoltaic power ramp clustering model, first obtains the data after the photovoltaic power ramp detection, and counts the number of daily ramps and the daily average power in units of days; S201, then preliminarily judge the weather type based on the daily average power. If the daily average power is less than the threshold value P mean , it is directly judged as a rainy day; if the daily average power is greater than or equal to the threshold P mean , when the number of climbing times is 0, it is a sunny day; when the number of climbing times is (0, N1], it is a light cloud weather type; when the number of climbing times is (N1, N2], it is a cloudy weather type; when the number of climbing times is greater than N2, it is a rainy weather type; continue the judgment of other days until all days are traversed, and finally record the clustering results to complete the photovoltaic power climbing clustering detection process.

6. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 4, characterized in that: The photovoltaic power ramp clustering model is: Based on the ShapeDTW algorithm, a photovoltaic power ramp-up similar day clustering model is constructed. The photovoltaic power time series τ=(t1, t2, …t L ) T ,τ∈R L , RL represents the L-dimensional space composed of real numbers R. First, from each time point t in the sequence i Extract a subsequence s of length l i ;Subsequence s i With t i As the center, its length l is much smaller than L; we get a series of subsequences, namely S = (s1, s2, ... s L ) T ,s i ∈R l , Rl represents the l-dimensional space composed of real numbers R, where s i Corresponding to time point t i ; Then, shape descriptors are used to represent subsequences. Subsequences with similar shapes have similar descriptors, while subsequences with different shapes have different descriptors. i The shape descriptor of naturally encodes the time point t i The surrounding local structural information; Designing a shape descriptor boils down to designing a mapping function F(·) that maps a subsequence s i ∈R l to the shape descriptor d i ∈R m , R m represents the m-dimensional space composed of real numbers R, that is, d i =F(s i ), the Euclidean distance is used to measure the similarity between descriptors; Given a shape descriptor calculation function F(·), select the slope as the shape descriptor calculation function; convert the subsequence S into a descriptor sequence D; after the above conversion, use the DTW algorithm to align the two descriptor sequences, and points with similar local shapes tend to be aligned; D=(d1,d2,…d L ) T ,d i ∈R m D=F(S)=[F(s1),F(s2),…,F(s L )] T 。 7. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The step 3 specifically includes: Step 3.1, preprocess the original load data, including missing values, outliers and standardization processing; Step 3.2, analyze the periodicity of the original load data after preprocessing, and use the Spearman correlation coefficient to perform feature screening to obtain load characteristics; Step 3.3, use the CEEMDAN sequence decomposition model to decompose the load characteristics, and the decomposed sequence and the filtered data together constitute the training data; Step 3.4, finally, divide the training data into load training set, load test set and load verification set, and use FEDformer model training until the model training is completed, and save the optimal training model.

8. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The step 4 specifically includes: Step 4.1, obtain the load test set, use the optimal FEDformer model to predict the load test set, and obtain the prediction result of the load test set; Step 4.2, classify the prediction results of the load test set into m categories, and obtain cluster prediction results of m categories; Step 4.3, calculate the clustering prediction error of m categories, use the dynamic interval calculation formula to get the interval range of different categories, superimpose the interval range on the prediction result, and get the final interval prediction result. The dynamic interval calculation formula is as follows: In the formula, E negtive (t)——the lower bound of the interval at time t; E postive (t)——the upper bound of the interval at the tth moment; e(t)——the prediction error at the tth moment; e(t) Q(i) ——The i1, i2, i3, i4 quartiles of Q(i) that meet the conditions at time t; σ1, σ2——the set adjustment thresholds.

9. A method for dynamic interval optimization scheduling of a microgrid considering source-load uncertainty as claimed in claim 1, characterized in that: The step 5 specifically includes: Step 5.1, the optimization operation of the microgrid takes the minimization of daily operation cost as the objective function, which is calculated by the total operation cost of each system of the microgrid. The environmental protection is determined by the equivalent cost of pollution emission control of the microgrid, and the safety is achieved through the constraints of the operation of each system of the microgrid and the system operation control; The daily operating cost formula of the microgrid is as follows: In the formula, C is the total daily operating cost of the system (yuan); ac (t)——Daily operating cost of battery (yuan); C mt (t)——Daily operating cost of micro gas turbine (yuan); C grid (t)——interaction cost between microgrid and distribution network; C ep (t)——total cost of environmental protection operation (yuan); (1) Economical operation of microgrids The average charging and discharging cost of the battery in period t is C ac (t) is expressed as: In the formula, K ac ——Converted unit charging and discharging cost of energy storage; and ——represent the charging power and discharging power of the energy storage during time period t; η ac ——Charging and discharging efficiency of energy storage unit; Δt——scheduling step length; The cost function of the micro gas turbine is: C mt (t)=[aP mt (t)+b]Δt In the formula, C mt (t)——operating cost of micro gas turbine in period t; P mt (t)——output power of micro gas turbine in period t; a, b——cost coefficients of fitting function; The interaction cost between the microgrid and the distribution network can be expressed as: Where, λ(t) is the time-of-use electricity price of the distribution network; ——The electric power purchased and sold by the microgrid from the distribution network; (2) Environmental friendliness of microgrid operation The calculation formula for the environmental protection of microgrid operation is as follows: In the formula, i——represents different pollutants; β i ——the cost of treating pollutant i; P grid (t)——dispatching power of the power grid; ——emission fitting coefficient of pollutant i in the distribution network; ——emission fitting coefficient of micro gas turbine pollutant i; (3) Microgrid operation safety The safety of the microgrid is realized through the constraints of the operation of each system and the system operation control to realize the operation constraints of photovoltaic, energy storage, and micro gas turbine systems, and the energy balance constraints supply and demand balance; the power balance constraints of the microgrid are as follows: In the formula, —— is the actual consumption value of photovoltaic power; P mt (t)——power generation of micro gas turbine; P load (t)——electrical load of the system; P ac (t)——battery charging and discharging power; ——Discharge and charge status, charge and discharge status are 0-1 variables; Energy storage system operation constraints: The operation constraints of the microgrid energy storage system include charging and discharging power constraints, equal initial and final capacity, and remaining capacity. The energy storage unit constraints are as follows: In the formula, ——The maximum charge and discharge power allowed by energy storage; μ ac (t)——Charging and discharging state of energy storage, the discharge state value is 1, and the charging state value is 0; E ac (0)——the capacity of the energy storage at the initial moment, ——The minimum and maximum remaining capacity allowed during the dispatch process; The operating constraints of the micro gas turbine are as follows: In the formula, ——Minimum output power and maximum output power of the micro gas turbine; Distribution network interaction constraints: The constraints for power exchange between the microgrid and the distribution network are as follows: In the formula, ——The maximum value of the power exchanged between the microgrid and the distribution network; μ grid (t)——The power purchase and sale status between the microgrid and the distribution network. The value is 1 when the microgrid purchases power from the distribution network, and the value is 0 when the microgrid sells power to the distribution network; Step 5.2: Based on the interval prediction results of steps 2 and 4, the prediction error range of photovoltaic output and load power is constructed into an interval prediction uncertainty set U, as shown in the following formula: In the formula, u is an uncertain variable; pv (t)——PV power uncertainty variable; u load (t)——Uncertain variable of load power; ——Minimum and maximum values ​​of the PV power uncertainty variable; ——the minimum and maximum values ​​of the load uncertainty variables; ——set of real numbers; N——positive real number; The optimal optimization scheduling result is obtained by solving the dynamic interval optimization scheduling model of the microgrid. The focus is on finding the most economically optimal and safest scheduling scheme when the uncertain variable u changes towards the most unfavorable situation in the interval prediction uncertainty set u. It has the following form: Where, min[·] is the first-stage optimization problem, with the optimization variable x; maxmin(·) is the second-stage optimization problem, with the optimization variables u and y, where the minimization problem represents minimizing the operating cost; c is the objective function; and the maximization problem represents the scenario that leads to the most unfavorable operating cost. Step 5.3, combined with the interval prediction uncertainty set U, the problem can be summarized as follows, and the optimal dispatch result of the microgrid is obtained: In the formula, D, K, F, G, I u ——The coefficient matrix of the variables under the corresponding constraints; d, h, γ, λ, ν, π——constant column vector; B pv (t), B load (t)——binary 0-1 variable; λ pv ——"uncertainty adjustment parameter" of photovoltaic power; λ load ——"uncertainty adjustment parameter" of load power; By solving the optimal dispatching variables based on the power and load uncertainty sets, the optimal dispatching variable values ​​and dispatching strategies that minimize the operating cost are obtained.

Citation Information

Patent Citations

  • Power prediction correction method considering photovoltaic power climbing characteristics

    CN116227677A

  • Deep reinforcement learning method for microgrid energy scheduling under consideration of source load uncertainty

    CN116247648A

  • Power distribution network dynamic reconstruction and mobile energy storage collaborative optimization method and device

    CN118214046A

Cited By

  • Multi-energy micro-grid robust optimization method considering uncertain scene clustering information

    CN119298239A