Sie sind auf Seite 1von 4

Price Forecasting Based on PSO Train BP Neural Network

Yong Gui He
Department of Economy Management, North China Electric Power University, Baoding 071003, Hebei, China hyg_1961@tom.com

Li Bo
Department of Economy Management, North China Electric Power University, Baoding 071003, Hebei, China libothebest@163.com

Abstract: In this paper, the basic idea is to use percent of reserve capacity, the historical load and price to forecast short-term electricity price .The paper provides an example of bidding model to forecast market clear price using BP neural network trained by PSO. To compare with the result of traditional BP neural network, the proposed method has better forecasting precision and can convergence to global optimal solution at all times. Key words: back propagation network; particle swarm optimization; electricity market; market clear price

I.

INTRODUCTION

The electricity market is the development trend of the world's electric power industry. In the power market, the generation electricity companies participate in the bidding for connecting to network, and the resources are collocated by the market. In the electric power trading and bidding, if the generation electricity companies can get the information of price in advance, they can pre-arrange the production planning and the bidding strategies, so they can obtain greater proceeds. Therefore, with the continuous deepening of the electricity market, the generation electricity companies will pay more and more attention to the price forecasting. The Domestic and foreign scholars have done a great deal of research on the issue, and brought forward a lot of forecasting methods, which can be summed up mainly four categories as follows: the analysis methods based on the timing, such as the time series analysis, the grey forecasting, and mean generation function; the methods based on factor analysis, such as linear regression equation, artificial neural networks, fuzzy clustering and synthetic evaluation methods; the price forecasting methods based on econometrics, such as the three times model, the Markov economical forecasting theory; the forecasting methods based on the combination idea. In recent years, many scholars have explored the neural network forecasting methods actively. They have done

short-term price forecasts for the attempt, which separately used the regression neural network, RBF neural network, adaptive neural network, recurrent neural networks, and module neural network, and CMAC joint control neural networks [3] and so on, and they have received some harvest. While using neural network models to do forecasting, the emphases of studying are how to form the forecasting samples, and how to make the data of input layer. The structure of model has some disadvantages, such as the layers of network and the numbers of neurons in each layer are chosen by right of experience mostly, or it adopts tentative method when have not any experience knowledge, in other words, it chooses the data whose forecasting error is less relatively. So the problems of neural network lead to the restriction of precision and convergence, which are the difficulty to determine a reasonable structure and convergence to local solution. While investigating how to use BP neural networks to forecasting MCP, this paper focuses on the problem of weak search capabilities of BP neural network. This paper trains BP neural network forecasting model by using PSO algorithm, by which we can enhance the convergent velocity and the forecasting precision. The forecasting result of example shows that, the method is superior to conventional BP neural networks, which has rapid convergence and good scalability. II. PSO ALGORITHM AND BP NEURAL NETWORK

2.1 PSO algorithm PSO algorithm is a stochastic search optimization based on swarm intelligence, which operates at the basis of draw near theory, the particles in group learn from one anothet, and based on the knowledge they move to the neighborhood area which simple to them and better, the particles update themselves by pursuing individual extremum best and global extremum best .According to the following formulas, they update their velocity and location:

978-1-4244-2487-0/09/$25.00 2009 IEEE

vid = vid + c1rand () ( pbest xid ) + c2 rand () ( g best xid )


(1)

various fields, but it has the potential to a local minimum, and can not guarantee that convergence to the global minimum point. In addition, the reverse spread is satisfied. According to the above problems, this paper import PSO algorithm to optimize the weight of BP network, the formula is:

xid = xid + vid


in the formulas the position

(2)

vid

is the velocity of particle,

xid

is

pbest is the optimal solution to the particle,


c1
,

wij (k ) = wij (k 1) + vi (k )
III.
ALGORITHM

gbest is the optimal solution to the whole group, rand () is the


random in 01

(3)

c2

TRAINING BP NEURAL NETWORK BY USING PSO

c1 c 2
=

are learn factors, commonly

=2.

Training BP neural network by using PSO algorithm the Elements of position vector x ,which belongs to defined particle swarm is all connection weight and Threshold of BP neural networkAt first initialize position vector x then use PSO algorithm search optimum placement the optimization flow chart of using the PSO algorithm to train BP neural network as follows:
begin

The process of the basic PSO algorithm as follows: (1)Initialize a flock of particles, define the accelerated constants are

c1

and

c2

, the most evolution algebra is

Tmax

,the current algebra is t=1 ,and we set the initial

position and the velocity, and define the position,

pbest as initial

gbest is the optimal solution of pbest ;

(2) Evaluate the fitness value of each particle, namely, calculate the objective function according to each particle; (3)According to each particle, we compare the fitness

initialize all parameters of PSO

pbest ,if better than pbest ,the fitness is the p current optimal position best ;
value with (4)According to each particle, we compare

PSOalgorithm trainning

No

pbest with

Meet ending condition?

gbest ,if better than gbest ,the pbest is reinstalled as gbest ;


(5) According to the equations on velocity and position update, we adjust the velocity and position of particles; (6)Stop rule (reach the most iteration times or the best fitness value) or the optimal solution stagnate, it will not change any more. Loop to step (2) until the criterion is met. 2.2 BP Neural Network Artificial neural network is the network formed by artificial nerve cell interconnecting, which realizes the abstract and predigestionof cerebroid form microstructure and function, and has lots of advantages. Traditionally, the BP algorithm is used to confirm the weight modulus. BP network is multi-layer and feedback, and BP algorithm is composed of two parts: the information passes forward and the error spreads in reverse. In back-propagation algorithm, the mountain climbing is used to do weight training (i.e.: algorithm). This method has achieved great success in

Select optimal particle valuation to BP neural network weight and threshold value

BP neural network trainning No

Meet condition? yes end

GRAPH 1 FORECASTING FLOW CHART OF USING THE TRAIN BP NEURAL NETWORK

PSO ALGORITHM TO

IV.

APPLICATION EXAMPLE

actual value

4. 1 the model of forecasting data In order to inspection the effectiveness of the model ,this paper using the loadthe percentage of system surplus capacity and the marginal price data of PJM electricity market of USA, from january 1st,1998 to march 1st 1998, to train the forecasting network , using the data from march 23rd to march 29 th to inspection forecasting resultThe training model use Multi-layered BP Neural Network.Input nodes includes MCP,system load , the percentage of system surplus capacitythe index is mainly used measure the effect about the spinning reserve to bidding behavior of market participants in electricity marketof the first two periods of forecast daythe day before forecast day andthe same periods of last week and system's actual load and the percentage of system surplus capacity of the periods in forecast day ,which come to 14 input nodes the determination of the number of hidden nodes use formula as follow:

60

pso train bp predictive value bp predictive value pso train bp prediction error bp prediction error

MCP / ( $/MW . h )

40

20

50

periods 100

150

GRAPH 2

CURVE OF ACTUAL VALUE AND PREDICTIVE VALUE OF MCP

n+m + a (4) in the formulas n is input nodes m is output nodes n


1

constant a=1~10 there is only one node in output layer that is forecast periods MCP 4. 2 prediction result

In order to measure prediction result,two statistical indexes are used , one is individual maximum relative error i ,the other is average relative error MAPE

when analysis prediction results statistically it is found that the single-period maximum relative error is 8.21% average relative error is 2.38%,when the method which use PSO to train BP neural network to forecast is used; the single-period maximum relative error is 18.63%,average relative error is 7.94 %,when traditional BP network is used. The average using time is 11.76s when the method which use PSO to train BP neural network to forecast is used while the average using time is18.42s when traditional BP network is used obviouslythe method which use PSO to train BP neural network to forecast is superior to using BP network to forecast singly.By tested some times , this method can convergent well each time, while traditional BP network can not reached presumptive convergence value sometimes Therefore,it is satisfied that use the method which use PSO to train BP neural network to forecast. It is also found from the graph 2 that the trend forecasted by MCP and the actual price curve are basically identical, but in the periods when load change greatly, or the peak of MCP appeares, the deviation of predictive value will be greater. In addition, when MCP is forecasted, input nodes which are selected are mainly historical data in the same periods.If the changing trend of load and MCP in each periods and holiday are considered,the forecast result will be better. V. CONCLUSION The prediction of MCP is one of basic data that is used to structure optimal bidding strategy by generation company in electricity market.This paper use the method which use PSO to train BP neural network to forecast MCP. The algorithm of particle swarm optimization find optimal regions of complex search space through the interaction of

i=

pi pi
1

5 6

M APE = i N

in the formulas,

pi

is the actual value of MCP

pi

is

the predictive value of MCP N is the number of periods ,when MCP is forecasted in graph2, the comparison about forecast result and error curve between the method which use PSO to train BP neural network to forecast and the method which use typical BP neural network is given.

individuals in a population of particles. The method utilizes the PSO algorithm to speed up the learning of the neural network, and doesn't have the disadvantages of the BP algorithm such as slow convergence and local minimum. By establishing simulation and forecast model with neural network toolbox in Matlab6.5 and forecasting PJM electricity market in USAthe average relative error can be controlled within 10%,so the method has high accuracy. By forecasting and analysising,the composition of training set that is used to training BP neural network affect prediction results directly, so select the data of the similar historical days and the adjacent days to carried out the training . On the other hand the result is not very perfect,which has something to do with the bidding strategy of generation company.It is problem that remains to be solved.

REFERENCE
[1] YANG Pu,YOU Da Hai, XIE Pei Yuan. Price Forecasting Based on Generic Algorithm and BP Neural Network [J]. International Journal Hydroelectric Energy, 2003, 21(2) : 71274 DONG Zhao Xia, GAO Jian Jun, CHAN Qing Hua. Study on Integrated Short Term Load Forecasting Model in Power System [J]. International Journal Hydroelectric Energy, 2002, 20(1) : 71274 CHEN Si Jie, ZHOU Hao. Electricity price forecast methods of electricity market [J]. RELAY, 2004, 34 (11) : 4897 ZHAO Lin Ming, HU Hao Yun, WEI De Hua. Multi-Layer forward BP Artificial Neural Networks [M]. the yellow river and water resources, 1999. LIU,Guo,Zheng,FU Xiang Ming,GAO Fu Ying.Forecasting market-clearing price in zhejiang generation market using neural network [J]. Automation of Electric Power Systems,2002, 26 (9) : 49252 XIE Pei Yuan, ZENG Ci Ling. Short-Term Electricity Price Forecast Using Neural Network [J]. Hunan Electric Power 2004, 24 (2) : 0198

[2]

[3] [4]

[5]

[6]