[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN109726849A - A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network - Google Patents

A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network Download PDF

Info

Publication number
CN109726849A
CN109726849A CN201811420711.9A CN201811420711A CN109726849A CN 109726849 A CN109726849 A CN 109726849A CN 201811420711 A CN201811420711 A CN 201811420711A CN 109726849 A CN109726849 A CN 109726849A
Authority
CN
China
Prior art keywords
neural network
sample set
pollen
pollination
building microgrid
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201811420711.9A
Other languages
Chinese (zh)
Inventor
易灵芝
孙颢一
赵健
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Xiangtan University
Original Assignee
Xiangtan University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xiangtan University filed Critical Xiangtan University
Priority to CN201811420711.9A priority Critical patent/CN109726849A/en
Publication of CN109726849A publication Critical patent/CN109726849A/en
Pending legal-status Critical Current

Links

Landscapes

  • Breeding Of Plants And Reproduction By Means Of Culturing (AREA)

Abstract

The invention discloses a kind of building microgrid load forecasting methods of colored pollination algorithm optimization neural network, history building microgrid load data and the local meteorological element data of history are collected, the data for collecting acquisition are pre-processed and generate training sample set and test sample collection;Neural network is trained using training sample set, the weight and threshold value of neural network are optimized, adjusted using flower pollination algorithm during training;Test sample collection is inputted and carries out the load prediction of building microgrid in above-mentioned steps in trained neural network, obtains the result of load prediction.The method of the present invention can obtain the building microgrid load prediction results of degree of precision.

Description

Building microgrid load prediction method for optimizing neural network by flower pollination algorithm
Technical Field
The invention relates to the field of load prediction of building microgrids, in particular to a building microgrid load prediction method for optimizing a neural network by a flower pollination algorithm.
Background
Nowadays, with the rapid development of power grid technology, more and more distributed energy supply systems are integrated on the building side, and a building microgrid is gradually formed. The building microgrid is a microgrid which is formed by a building as a main part and direct current and is an important component of a future intelligent power distribution and utilization system. Needless to say, the most important energy source in a building microgrid is electrical energy. However, electrical energy has the fatal disadvantage of being difficult to store, which requires more accurate prediction of load demand. The power load prediction itself has characteristics of inaccuracy, conditionality, timeliness, multi-scenario, internal correlation, etc., which also makes the accuracy of the load prediction a challenging task.
At present, the load prediction method mainly adopts a gray prediction method, a fuzzy prediction method, a support vector machine, a time series method, a neural network and other methods. Among them, the BP neural network, which has strong adaptive ability and learning ability and can approximate any nonlinear function with arbitrary accuracy, is widely used in the field of load prediction. However, the method has certain defects, such as contradiction between learning ability and generalization ability, easy falling of a back propagation algorithm into local extreme values, and the like, which are problems to be solved urgently.
Disclosure of Invention
The invention mainly aims to provide a building microgrid load prediction method for optimizing a neural network by a flower pollination algorithm.
The method comprises the following steps:
step1, acquiring historical load data and local meteorological element data of the building microgrid, preprocessing the data, and generating a training sample set and a testing sample set;
step2, establishing a neural network prediction model through a training sample set;
step3, training the neural network by adopting a training sample set, and optimizing and adjusting the weight and the threshold of the neural network in the training process by using a flower pollination algorithm;
and Step4, inputting a test sample set in the trained and optimized neural network in Step3 to obtain a building microgrid load prediction result.
The specific steps of constructing the training sample set and the test sample set in the step1 are as follows:
training sample set TrainnComprising n input samples PnAnd n output samples TnThe input samples are continuous building micro-grid historical load data and local meteorological element data which are acquired and can be recorded as Wherein m is the number of the historical load data, a is the number of local meteorological elements (considered range), and m + a is the input number of the prediction model; the output sample set is continuous historical load data collected and can be recorded asThe value of l is determined by the number of model output nodes; n is the nth sample of the sample set.
Similarly, selecting a Test sample set TestnThe method and the selection of training sample set TrainnIn the same manner.
The specific steps of constructing the neural network model by Step2 are as follows:
the input layer node number inputnum of the neural network prediction model is set to be 3, the hidden layer node number hiddennum is set to be 10, and the output layer node number outputnum is set to be 1; selecting transmission functions of a hidden layer and an output layer as a tansig function and a pureline function respectively; the number of variables to be optimized by the neural network is as follows: nvar ═ inputnum × hiddennum + hiddennum × outputnum + hiddennum + outputnum, that is, nvar ═ 3 × 10+10 × 1+10+1.
The specific steps of optimizing and adjusting the weight and the threshold of the neural network by using the flower pollination algorithm adopted in Step3 are as follows:
step31 initializes the control parameters. The pollen population scale of the Flower Pollination Algorithm (FPA) is 10, the maximum iteration number iterMAX is 10, and the switching probability p of cross pollination and self pollination is 0.5
Step32, initializing the pollen population, and searching the current optimized division and the position g thereof*And calculating the fitness f (g) thereof*)
Step33 enters the main circulation, if rand > p, cross-pollination is carried out, otherwise, self-pollination is carried out.
Wherein rand is [0,1]]Random numbers obeying uniform distribution; the formula for cross pollination is: is the position of pollen i at time t +1, g*Is the position of the optimal pollen in the current population, and the control parameter L is pollination strength which is essentially a random step size subject to Levy distribution and meets the requirementWhere Γ (λ) is the standard gamma function and for larger step sizes s>0, this distribution is valid; the formula of self-pollination is Wherein,andis the location of two pollen in the population other than i, and epsilon is a proportionality coefficient that obeys uniform distribution.
Step34 judges whether to update the individual, if soChoose to accept a new solution and pollinateTo a new position
Step35 is compared with the optimal pollen if f (x)new)<f(g*) Then the optimum pollen g before replacement*Is xnew
Step36 if the current pollen is not the last pollen in the population, then the next pollen is selected and the Step34 is returned, otherwise the Step37 is returned.
Step37, if the end condition of the algorithm is met (the maximum iteration number iterMAX is reached), the Step38 is carried out, otherwise, the Step33 is carried out, and the next generation search is continued.
Step38, finding the optimal solution, and outputting the optimal pollen individual g*And a global optimal solution f (g)*) Global optimal solution f (g)*) Namely the optimal weight and the threshold of the neural network.
The building microgrid load prediction method for optimizing the neural network by the flower pollination algorithm comprises the steps of firstly processing historical load data and local meteorological element data of the building microgrid, establishing a training sample set and a testing sample set, then establishing a neural network prediction model for the testing sample set, and simultaneously optimizing the weight and the threshold of the neural network by the flower pollination algorithm in order to improve the prediction precision and the generalization capability of the model; finally, inputting the test sample into the trained neural network to obtain a building microgrid load prediction result; and the building microgrid load prediction precision is improved.
Drawings
In order to more intuitively explain the technical solution of the embodiment of the present invention, the drawings used in the description of the embodiment will be briefly introduced below
FIG. 1 is a flow chart of a building microgrid load prediction method for optimizing a neural network by a flower pollination algorithm according to an embodiment of the invention;
FIG. 2 is a flow chart of a neural network optimized by a Flower Pollination Algorithm (FPA) according to an embodiment of the present invention;
FIG. 3 is a diagram illustrating the predicted effect of the FPA-NN model according to an embodiment of the present invention;
the objects, features, and advantages of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
The embodiment of the building microgrid load prediction method for optimizing the neural network by using the flower pollination algorithm comprises the following steps:
step1, acquiring local meteorological element data and building microgrid historical load data, preprocessing the data, and claiming a training sample set and a testing sample set;
the method comprises the following specific steps:
training sample set TrainnComprising n input samples PnAnd n output samples TnThe input samples are continuous historical load data and weather data collected and can be recorded asWherein m is the number of the historical load data, a is the number of local meteorological elements (considered range), and m + a is the input number of the prediction model; the output sample set is continuous historical load data collected and can be recorded asThe value of l is determined by the number of model output nodes; n is the nth sample of the sample set.
Selecting a Test sample set TestnThe method and the selection of training sample set TrainnIn the same manner.
Step2, establishing a neural network prediction model through a training sample set;
the method comprises the following specific steps:
the input layer node number inputnum of the neural network prediction model is set to be 3, the hidden layer node number hiddennum is set to be 10, and the output layer node number outputnum is set to be 1; selecting transmission functions of a hidden layer and an output layer as a tansig function and a pureline function respectively;
the number of variables to be optimized by the neural network is as follows:
nvar ═ inputnum × hiddennum + hiddennum × outputnum + hiddennum + outputnum, that is, nvar ═ 3 × 10+10 × 1+10+1.
Step3, training the neural network by adopting a training sample set, and optimizing and adjusting the weight and the threshold of the neural network by a flower pollination algorithm in the training process;
the method specifically comprises the following steps:
(1) control parameters are initialized. The pollen population scale of the Flower Pollination Algorithm (FPA) is 10, the maximum iteration number iterMAX is 10, and the switching probability p of cross pollination and self pollination is 0.5
(2) Initializing a pollen population, and searching the current optimized division and the position g thereof*And calculating the fitness f (g) thereof*)
(3) Entering main circulation, if rand is larger than p, cross-pollination is carried out, otherwise, self-pollination is carried out.
Wherein rand is a random number subject to uniform distribution over [0,1 ];
wherein, the formula of cross pollination is as follows:is the position of pollen i at time t +1, g*Is the position of the optimal pollen in the current population, and the control parameter L is pollination strength which is essentially a random step size subject to Levy distribution and meets the requirementWhere Γ (λ) is the standard gamma function and for larger step sizes s>0, this distribution is valid;
wherein, the formula of self-pollination isWherein,andis the location of two pollen in the population other than i, and epsilon is a proportionality coefficient that obeys uniform distribution.
(4) Judging whether to update the individual, if soChoose to accept a new solution and pollinateTo a new position
(5) With optimal pollenBy comparison, if f (x)new)<f(g*) Then the optimum pollen g before replacement*Is xnew
(6) And (4) if the current pollen is not the last pollen in the population, selecting the next pollen and returning to the step (4), otherwise, turning to the step (7).
(7) If the termination condition of the algorithm is met (the maximum iteration number iterMAX is reached), the step (8) is carried out, otherwise, the step (3) is carried out, and the next generation search is continued.
(8) Finishing finding the optimal solution and outputting the optimal pollen individual g*And a global optimal solution f (g)*) Global optimal solution f (g)*) Namely the optimal weight and the threshold of the neural network.
And Step4, inputting a test sample set in the Step3 trained network to obtain a building microgrid load prediction result.
And (3) experimental verification: load prediction method experiment for optimizing neural network by flower pollination algorithm
The test firstly establishes an FPA-NN prediction model for a training sample set to train, and then inputs a test sample to the trained FPA-NN model to obtain a load prediction result; and compared with a neural network alone (BP-NN) model. FIG. 3 is a diagram showing the predicted effect of FPA-NN.
The error comparison analysis of the monoprimary neural network model (BP-NN) and the predictive model of the invention (FPA-NN) is shown in Table 1.
TABLE 1 load prediction error comparison
As can be seen from Table 1, the prediction accuracy of the prediction model (FPA-NN) of the present invention is more accurate than that of the conventional neural network (BP-NN).
In summary, the building microgrid load prediction method for optimizing BP neural network by using a flower pollination algorithm is provided, the method comprises the steps of firstly collecting historical load data and local meteorological element data of a building microgrid, processing the historical load data and the local meteorological element data, establishing a training sample set and a testing sample set, then establishing a neural network prediction model for the testing sample set, and simultaneously optimizing weight and threshold values of the neural network by using the flower pollination algorithm in order to improve prediction accuracy and generalization capability of the model; finally, inputting the test sample into the trained neural network to obtain a load prediction result; a new method is provided for improving the precision of building microgrid load prediction.
The above descriptions are the preferred embodiments of the present invention, and therefore do not limit the scope of the present invention, and the purpose of load prediction can be achieved by using other prediction methods, and the problem of local optimization of a neural network can be solved by using other high-quality algorithms, and the equivalent structural transformation performed by using the contents of the description and the drawings of the present invention or the direct/indirect application to other related technical fields are included in the scope of the present invention.

Claims (4)

1. A building microgrid load prediction method for optimizing a neural network by a flower pollination algorithm is characterized by comprising the following steps:
step1, collecting historical load data and local meteorological element data of the building microgrid, preprocessing the collected data, and generating a training sample set and a test sample set;
step2, establishing a neural network prediction model by using the training sample set;
step3, training the neural network by adopting a training sample set, and optimizing and adjusting the weight and the threshold of the neural network by a flower pollination algorithm in the training process;
and Step4, inputting a test sample set in the Step3 trained network to obtain a building microgrid load prediction result.
2. The method of claim 1, wherein Step1 comprises the steps of:
training sample set TrainnComprising n input samples PnAnd n output samples TnThe input samples are continuous building micro-grid historical load data and local meteorological element data which are acquired and can be recorded as Wherein m is the number of the historical load data, a is the number of the local meteorological element data (considered range), and m + a is the input number of the prediction model; the output sample set is continuous historical load data collected and can be recorded asThe value of l is determined by the number of model output nodes; n is the nth sample of the sample set; selecting a Test sample set TestnThe method and the selection of training sample set TrainnIn the same manner.
3. The method of creating a neural network predictive model of claim 1, wherein Step2 comprises the steps of:
the input layer node number inputnum of the neural network prediction model is set to be 3, the hidden layer node number hiddennum is set to be 10, and the output layer node number outputnum is set to be 1; selecting transmission functions of a hidden layer and an output layer as a tansig function and a pureline function respectively;
the number of variables to be optimized by the neural network is as follows: nvar ═ inputnum × hiddennum + hiddennum × outputnum + hiddennum + outputnum, that is, nvar ═ 3 × 10+10 × 1+10+1.
4. The method for optimizing the weight and the threshold of the neural network through the flower pollination algorithm as claimed in claim 1, wherein Step3 comprises the following specific steps:
step31 initializes the control parameters; the pollen population scale of a Flower Pollination Algorithm (FPA) is 10, the maximum iteration number iterMAX is 10, and the switching probability p of cross pollination and self pollination is 0.5;
step32, initializing the pollen population, searching the current optimized division and the position g thereof, and calculating the fitness f (g) thereof;
step33 entering main circulation, if rand > p, cross-pollination, otherwise, self-pollination;
wherein rand is [0,1]]Random numbers obeying uniform distribution; the formula for cross pollination is: is the position of pollen i at time t +1, g*Is the position of the optimal pollen in the current population, and the control parameter L is pollination strength which is essentially a random step size subject to Levy distribution and meets the requirementWhere Γ (λ) is the standard gamma function and for larger step sizes s>0, this distribution is valid; the formula of self-pollination is Wherein,andis the position of two pollens in the population different from i, and epsilon is a proportionality coefficient subject to uniform distribution;
step34 judges whether to update the individual, if soChoose to accept a new solution and pollinateTo a new position
Step35 is compared with the optimal pollen if f (x)new)<f(g*) Then the optimum pollen g before replacement*Is xnew
Step36, if the current pollen is not the last pollen in the population, selecting the next pollen and returning to Step34, otherwise, turning to Step 37;
if Step37 meets the termination condition of the algorithm (the maximum iteration number iterMAX is reached), turning to Step38, otherwise, entering Step33, and continuing to perform next generation search;
step38, finding the optimal solution, and outputting the optimal pollen individual g*And a global optimal solution f (g)*) Global optimal solution f (g)*) Namely the optimal weight and the threshold of the neural network.
CN201811420711.9A 2018-11-26 2018-11-26 A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network Pending CN109726849A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811420711.9A CN109726849A (en) 2018-11-26 2018-11-26 A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811420711.9A CN109726849A (en) 2018-11-26 2018-11-26 A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network

Publications (1)

Publication Number Publication Date
CN109726849A true CN109726849A (en) 2019-05-07

Family

ID=66294744

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811420711.9A Pending CN109726849A (en) 2018-11-26 2018-11-26 A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network

Country Status (1)

Country Link
CN (1) CN109726849A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110348630A (en) * 2019-07-09 2019-10-18 武汉四创自动控制技术有限责任公司 A kind of isolated island region Methods of electric load forecasting and system
CN112821456A (en) * 2021-02-10 2021-05-18 北京国奥云高科技有限公司 Distributed source-storage-load matching method and device based on transfer learning

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107370188A (en) * 2017-09-11 2017-11-21 国网山东省电力公司莱芜供电公司 A kind of power system Multiobjective Scheduling method of meter and wind power output
CN108446808A (en) * 2018-04-08 2018-08-24 广东电网有限责任公司 A kind of short-term load forecasting method of glowworm swarm algorithm optimization neural network
CN108621844A (en) * 2018-05-10 2018-10-09 中南大学 A kind of heavy rain road automatic driving vehicle power predicating method and early warning system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107370188A (en) * 2017-09-11 2017-11-21 国网山东省电力公司莱芜供电公司 A kind of power system Multiobjective Scheduling method of meter and wind power output
CN108446808A (en) * 2018-04-08 2018-08-24 广东电网有限责任公司 A kind of short-term load forecasting method of glowworm swarm algorithm optimization neural network
CN108621844A (en) * 2018-05-10 2018-10-09 中南大学 A kind of heavy rain road automatic driving vehicle power predicating method and early warning system

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
崔东文等: "花授粉算法-BP神经网络模型及其在月径流预报中的应用", 《人民珠江》 *
牛培峰;李进柏;刘楠;李国强;王荣彦;: "基于改进花授粉算法和极限学习机的锅炉NO_x排放优化", 动力工程学报 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110348630A (en) * 2019-07-09 2019-10-18 武汉四创自动控制技术有限责任公司 A kind of isolated island region Methods of electric load forecasting and system
CN112821456A (en) * 2021-02-10 2021-05-18 北京国奥云高科技有限公司 Distributed source-storage-load matching method and device based on transfer learning

Similar Documents

Publication Publication Date Title
CN108846517A (en) A kind of probability short-term electric load prediction integrated approach of quantile
CN113128793A (en) Photovoltaic power combination prediction method and system based on multi-source data fusion
CN110517482B (en) Short-term traffic flow prediction method based on 3D convolutional neural network
CN109978283B (en) Photovoltaic power generation power prediction method based on branch evolution neural network
Woo et al. Real-time optimal power flow using twin delayed deep deterministic policy gradient algorithm
CN109558975B (en) Integration method for multiple prediction results of power load probability density
CN109345027B (en) Micro-grid short-term load prediction method based on independent component analysis and support vector machine
CN104091216A (en) Traffic information predication method based on fruit fly optimization least-squares support vector machine
CN106815782A (en) A kind of real estate estimation method and system based on neutral net statistical models
CN110751318A (en) IPSO-LSTM-based ultra-short-term power load prediction method
CN107037373A (en) Battery dump energy Forecasting Methodology based on neutral net
CN111461404A (en) Short-term load and hydropower prediction method based on neural network prediction interval
CN113469426A (en) Photovoltaic output power prediction method and system based on improved BP neural network
CN112330487A (en) Photovoltaic power generation short-term power prediction method
Tembusai et al. K-nearest neighbor with k-fold cross validation and analytic hierarchy process on data classification
CN113281790A (en) Beidou satellite clock error forecasting method and device
CN113642652A (en) Method, device and equipment for generating fusion model
CN109558898B (en) Multi-choice learning method with high confidence based on deep neural network
CN115619028A (en) Clustering algorithm fusion-based power load accurate prediction method
CN109726849A (en) A kind of building microgrid load forecasting method of colored pollination algorithm optimization neural network
CN117458480A (en) Photovoltaic power generation power short-term prediction method and system based on improved LOF
CN112036598A (en) Charging pile use information prediction method based on multi-information coupling
CN103605493B (en) Sorting in parallel learning method based on Graphics Processing Unit and system
CN112036737A (en) Method and device for calculating regional electric quantity deviation
CN116415177A (en) Classifier parameter identification method based on extreme learning machine

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20190507

WD01 Invention patent application deemed withdrawn after publication