# New Optimal Weight Combination Model for Forecasting Precipitation

Authors: Song-shan Yang; Xiao-hua Yang; Rong Jiang; Yi-che Zhang
Journal: Mathematical Problems in Engineering
 (2012)

---

## Abstract

In order to overcome the inaccuracy of the forecast of a single model, a new optimal weight combination model is established to increase accuracies in precipitation forecasting, in which three forecast submodels based on rank set pair analysis (R-SPA) model, radical basis function (RBF) model and autoregressive model (AR) and one weight optimization model based on improved real-code genetic algorithm (IRGA) are introduced. The new model for forecasting precipitation time series is tested using the annual precipitation data of Beijing, China, from 1978 to 2008. Results indicate the optimal weights were obtained by using genetic algorithm in the new optimal weight combination model. Compared with the results of R-SPA, RBF, and AR models, the new model can improve the forecast accuracy of precipitation in terms of the error sum of squares. The amount of improved precision is 22.6%, 47.4%, 40.6%, respectively. This new forecast method is an extension to the combination prediction method.


---

## Body

## 1. Introduction

Precipitation time series forecast has received tremendous attention in the world because of the uncertainty of climate change which increases the difficulty of accurately forecasting such time series. The forecast of the nonlinear and uncertain time series is very difficult with the traditional deterministic mathematic models, which cause new challenges to increase forecast accuracies [1, 2]. There are many methods for predicting complex time series [3–13].Rank set pair analysis (R-SPA) model is based on the principle of set pair analysis, and, in this model, we take rank as the particular characteristic of the time series which could be regarded as the standard of the similarity analysis. Radical basis function (RBF) neural network was firstly introduced by Broomhead and Lowe [7]. The RBF network model is motivated by the locally tuned response observed in biological neurons. Neurons with a locally tuned response characteristic can be found in several parts of the nervous system. The theoretical basis of the RBF approach lies in the field of interpolation of multivariate functions [8]. Chau applied particle swarm optimization training algorithm for artificial neural network system (ANN) in prediction [3, 4]. The content of autoregressive (AR) model is a random process, which is often used to model and forecast various types of natural phenomena.The combination model techniques provide consensus forecast by linear combination of individual model predictions according to different weighting strategies. The weights can be equal for all models in the simplest case or be determined through certain regression based methods [9]. The concept of combining the forecast model obtained from different models has been discussed and used previously [10–19]. The sensible combination of the outputs of different models has the additional merit that it may assist in the understanding of the underlying physical processes. Genetic algorithms (GAs) encode a potential solution to a specific problem on a simple chromosome-like data structure and apply recombination operators to these structures so as to preserve critical information. GAs are chosen to calculate the weights of three submodels because of its outstanding performance in optimization analysis, especially regarding the process of finding optimal parameters.This study first combines the three submodels which are introduced as previous, and the improved real-code genetic algorithm (IRGA) [19] is used to calculate the weights of the combination model. The three submodels and the new optimal weight combination model are used to forecast the annual precipitation for Beijing from 2004 to 2008. In the next section, optimal weight combination model is presented. In Section 3, we discuss the application of the optimal weight combination model. In Section 4, we give the conclusions.


## 2. The Optimal Weight Combination Model

In this paper, the procedure of establishing the new optimal weight combination model can be divided into three steps as follows.(1)
Construct the weight combination model.(2)
Establish three submodels.(3)
Calculate the weights of the three submodels by using IRGA.The flow chart of this procedure is shown in Figure1.Figure 1
The flow chart of the procedure of establishing the new optimal weight combination model.


### 2.1. Construction of the Weight Combination Model

In the case ofN forecast models, the weight combination forecast model [20] may be expressed as(2.1)xi=∑j=1Nwjxji+ei,
where xi is the observed discharge of the ith time period,wj is the weight assigned to the jth model, and estimated discharge xji and ei are the combination error term.Equation (2.1) can be represented in matrix notation as(2.2)X=YW+E,
where Y is the input matrix defined by(2.3)[x11x21…xN1x12x22…xN2⋮⋮⋱⋮x1nx2n…xNn],X=(x1,x2,…,xn)T is the output vector, W=(w1,w2,…,wN)T is the weight vector, E=(e1,e2,…,en)T is the combination error vector, Tdenotes the transpose of the vector, and n is the total number of observations.In the weight combination forecasting model, the sum of the weightsw is normally constrained to be equal to unity, that is(2.4)∑j=1Nwj=1.The value of the weightw cannot be less than zero, that is(2.5)wj≥0(j=1,2,…,N).


### 2.2. Establishment of the Three Submodels

#### 2.2.1. Rank Set Pair Analysis (R-SPA) Model

The procedure of the establishment of this model is shown as follows.(1)
Consider an annual precipitation seriesx1,x2,…,xn, we constructed the history sets A1,A2,…An-T, current set B and the subsequent value of these sets are represented in Table 1.Table 1
History setAt and current set B.
History setElementsSubsequent valueA1x1,x2,…,xTxT+1A2x2,x3,…,xT+1xT+2⋮⋯⋯Aixi+1,xi+2,…,xi+Txi+T+1⋮⋯⋯An-Txn-T,xn-T+1,…,xn-1xnCurrent setElementsSubsequent valueBxn-T+1,xn-T+2,…,xnxn+1Because of the weak dependence in the annual precipitation series, we assume that the number of history set and current setT to be an integer from 4 to 6.(2)
Rank transformation. We mark the elements inA1,A2,…,An-T,B from 1 to T according to the rank of elements in the sets they belong to. If some elements have the same rank, we mark them according to their average rank and round off the value. Then, we could obtain the rank setA1′,A2′,…,An-T′,B′.(3)
Constructn-T rank set pairs(Ai′,B′)(i=1,2,…,n-T)and calculate the difference d between the corresponding elements of Ai′ and B′. If the absolute value of d is equal to zero, we mark them “identical”; if the absolute value of d is greater than T-2, we mark them “contrary”; if the absolute value of d is between zero and T-2, we mark them “discrepant.” Respectively, count the total number of “identical,” “contrary,” and “discrepant” of each rank set pair. According to the value of the coefficient of the discrepancy degree i and the coefficient of the contrary degreej, the connection degree formula as follows:
(2.6)μA-B=SN+FNi+PNj,
where μ is the connection degree of the set pair, N denotes the total number of characteristics of the set pair, S represents the number of identity characteristics, P is the number of contrary characteristics, F is the number of the characteristics if the set pair is neither identity nor contrary. According to (2.6), we calculate the value of the connection degree of each rank set pair.(4)
In accordance with the maximum principle, we can find a similar setAi′ of B, and also we can find several similar sets of B under certain circumstances.Ai′ is the counterpart of Ai, and the subsequent value of Ai is xT+1. We can obtain the value of xn+1 through the formula as follows:
(2.7)xn+1=1m∑k=1mwkxT+k,
where wk is the ratio of the average of the elements in B and the average of the elements inAk, mis the number of the similar sets of B.


#### 2.2.2. Radical Basis Function (RBF) Model

The interpretation of the RBF method as an artificial neural network consists of three layers: one layer is the input layer neurons feeding the feature vectors into the network; another layer is a hidden layer of RBF neurons calculating the outcome of the bas functions; the last layer is the output layer neurons calculating a linear combination of the basis functions [21, 22]. The different numbers of hidden layer neurons and spread constant are tried in the study. Its topological structure is shown in Figure 2.Figure 2
The topological structure of RBF.The procedure of the establishment of this model is shown as follows.(1)
Normalization of the time series. Consider an annual precipitation series{x1,x2,…,xn}, we can transform the series to {x1′,x2′,…,xn′} by the normalization formula as follows. 												(2.8)xt′=xt-xmin⁡xmax⁡-xmin⁡(t=1,2,…,n),
where xmin and xmax denote the minimum and the maximum of the time series{x1,x2,…,xn}.(2)
Forecast of the data. The application of the RBF neural networks to time series data consists of two steps. The first step is the training of the neural networks. Choose the firstN value of the new series{x1′,x2′,…,xn′} as the training sample, and set up the RBF neural networks. Once the training stage is completed, the RBF neural networks will be applied to the forecasting data. Based upon the RBF neural networks established by the training sample, we forecast the value of the last n-Nelements of the series{x1′,x2′,…,xn′} and the forecasting series can be represented as{yN+1′,yN+2′,…,yn′}. In this study, we take that the value of the mean-square error is 0.0001 and the width of the radical primary function is 1.(3)
Denormalization of the forecasting series. Since the value of the elements in forecasting series is between zero and one, that isyj′∈[0,1], we should denormalize the forecasting series {yN+1′,yN+2′,…,yn′}to final forecasting{yN+1,yN+2,…,yn} through the denormalization formula as follows:
(2.9)yj=yj′×(xmax⁡-xmin⁡)+xmin⁡(j=N+1,N+2,…,n).


#### 2.2.3. Autoregressive (AR) Model

In this paper, we regard the data of the annual precipitation as a time series and the trend term, seasonal term, and random term can be extracted from the time series in sequence. Then, we superpose the trend term, seasonal term and random term, and obtain the equation as follows [23–25]:(2.10)xt=At+Bt+Ct,
where xtis the precipitation time series, Atis the trend term, Btis the seasonal term, and Ctis the random term.The procedure of establishing the autoregressive model is shown as follows.(1)
The extraction of the trend term. In this paper, the data performs a clear quadratic algorithms component, so a polynomial function is used to fit the precipitation data. The trend termAt can be described as follows:
(2.11)At=P2t2+P1t+P0,
where Pi(i=0,1,2) is the coefficient of the quadratic polynomial (2.11).(2)
The extraction of the seasonal term. The analysis of precipitation seasonality can be accomplished with the aid of modeling via spectral analysis. The precipitation seasonality can be indicated withLwaves. BBtis the output of Pt subtractAt, and the estimated value of BBtcan be defined as BBt′:
(2.12)BBt′=a02+∑k=1L[akcos⁡2pktn+bksin⁡2pktn],
where L=[n/2]is the number of harmonicwave, ak and bk are the coefficient of the Fourier series (2.12):(2.13)a0=1n∑t=1nBBt,ak=2n∑i=1nBBtcos⁡2πkin(k=1,2,…,L),bk=2n∑i=1nBBtsin⁡2πkin.Taking the working capacity into consideration, we choose the significant wave to forecast. And we define thekth wave as the significant wave when the following inequality is satisfied:(2.14)sk2=ak2+bk2>0.5s2ln⁡(k/a)n,
where a is the level of significance (a=5%); s2 is the variance of the series:(2.15)s2=1n-1∑t=1n(Pt-P̅t)2.(3)
The extraction of the random term. The random termCt is defined as a linear combination of Ct-1,Ct-2,…,Ct-p:
(2.16)Ct=α0+α1Ct-1+α2Ct-2+⋯+αpCt-p,
where p is the order number of the model;αi(i=0,1,…,p) denotes the coefficient of the regression model, which can be confirmed by AIC (Akaike’s Information Criterion) formula:
(2.17)AIC(p)=nln⁡σp2+2p,
where n is the number of series, σp2represents the variance of AR(p) and the appropriative of p can be chosen among 1, 2, 3, and 4.


### 2.3. Calculation of the Weights of the Submodels

The key of setting up the optimal weight combination model is to ascertain the weight of each forecasting model. In this study, we choose the weight which satisfies that the error sum of squares of the combination model is the minimum among all weight combination forecasting models, that is(2.18)min⁡f=min⁡∑i=1nei2=min⁡∑i=1n(xi-∑j=1Nwjxji)2,
where f is the error sum of squares of the combination model.Two matricesS and E′ are defined as(2.19)S=[e11e12…e1ne21e22…e2n⋮⋮⋱⋮eN1eN2…eNn],eij(i=1,2,…,N,j=1,2,…,n),eij is the error of the jth forecasting value of the ith model,(2.20)E′=SST=[e11′e12′…e1N′e21′e22′…e2N′⋮⋮⋱⋮eN1′eN2′…eNN′].
And, the formula (2.13) can be represented as follows:(2.21)min⁡f=min⁡∑i=1nei2=min⁡∑i=1n(xi-∑j=1Nwjxji)2=∑i=1N∑j=1Nwiwjeij′.If we obtain the value ofwj(j=1,2,…,N) with the aid of formula (2.4), (2.5), and (2.21), then we can ascertain optimal weight combination model.Genetic algorithm is an adaptive heuristic search algorithm premised on the evolutionary ideas of natural selection and genetic mutation, and it has always been regarded as a function optimizer [26–28]. The flow chart of genetic algorithm is shown in Figure 3.Figure 3
The flow chart of genetic algorithm.In this paper, we use the improved real-code genetic algorithm (IRGA) to solve this optimization problem. The population size is 20; the crossover fraction is 0.8, and the generation is 100.


## 2.1. Construction of the Weight Combination Model

In the case ofN forecast models, the weight combination forecast model [20] may be expressed as(2.1)xi=∑j=1Nwjxji+ei,
where xi is the observed discharge of the ith time period,wj is the weight assigned to the jth model, and estimated discharge xji and ei are the combination error term.Equation (2.1) can be represented in matrix notation as(2.2)X=YW+E,
where Y is the input matrix defined by(2.3)[x11x21…xN1x12x22…xN2⋮⋮⋱⋮x1nx2n…xNn],X=(x1,x2,…,xn)T is the output vector, W=(w1,w2,…,wN)T is the weight vector, E=(e1,e2,…,en)T is the combination error vector, Tdenotes the transpose of the vector, and n is the total number of observations.In the weight combination forecasting model, the sum of the weightsw is normally constrained to be equal to unity, that is(2.4)∑j=1Nwj=1.The value of the weightw cannot be less than zero, that is(2.5)wj≥0(j=1,2,…,N).


## 2.2. Establishment of the Three Submodels

### 2.2.1. Rank Set Pair Analysis (R-SPA) Model

The procedure of the establishment of this model is shown as follows.(1)
Consider an annual precipitation seriesx1,x2,…,xn, we constructed the history sets A1,A2,…An-T, current set B and the subsequent value of these sets are represented in Table 1.Table 1
History setAt and current set B.
History setElementsSubsequent valueA1x1,x2,…,xTxT+1A2x2,x3,…,xT+1xT+2⋮⋯⋯Aixi+1,xi+2,…,xi+Txi+T+1⋮⋯⋯An-Txn-T,xn-T+1,…,xn-1xnCurrent setElementsSubsequent valueBxn-T+1,xn-T+2,…,xnxn+1Because of the weak dependence in the annual precipitation series, we assume that the number of history set and current setT to be an integer from 4 to 6.(2)
Rank transformation. We mark the elements inA1,A2,…,An-T,B from 1 to T according to the rank of elements in the sets they belong to. If some elements have the same rank, we mark them according to their average rank and round off the value. Then, we could obtain the rank setA1′,A2′,…,An-T′,B′.(3)
Constructn-T rank set pairs(Ai′,B′)(i=1,2,…,n-T)and calculate the difference d between the corresponding elements of Ai′ and B′. If the absolute value of d is equal to zero, we mark them “identical”; if the absolute value of d is greater than T-2, we mark them “contrary”; if the absolute value of d is between zero and T-2, we mark them “discrepant.” Respectively, count the total number of “identical,” “contrary,” and “discrepant” of each rank set pair. According to the value of the coefficient of the discrepancy degree i and the coefficient of the contrary degreej, the connection degree formula as follows:
(2.6)μA-B=SN+FNi+PNj,
where μ is the connection degree of the set pair, N denotes the total number of characteristics of the set pair, S represents the number of identity characteristics, P is the number of contrary characteristics, F is the number of the characteristics if the set pair is neither identity nor contrary. According to (2.6), we calculate the value of the connection degree of each rank set pair.(4)
In accordance with the maximum principle, we can find a similar setAi′ of B, and also we can find several similar sets of B under certain circumstances.Ai′ is the counterpart of Ai, and the subsequent value of Ai is xT+1. We can obtain the value of xn+1 through the formula as follows:
(2.7)xn+1=1m∑k=1mwkxT+k,
where wk is the ratio of the average of the elements in B and the average of the elements inAk, mis the number of the similar sets of B.


### 2.2.2. Radical Basis Function (RBF) Model

The interpretation of the RBF method as an artificial neural network consists of three layers: one layer is the input layer neurons feeding the feature vectors into the network; another layer is a hidden layer of RBF neurons calculating the outcome of the bas functions; the last layer is the output layer neurons calculating a linear combination of the basis functions [21, 22]. The different numbers of hidden layer neurons and spread constant are tried in the study. Its topological structure is shown in Figure 2.Figure 2
The topological structure of RBF.The procedure of the establishment of this model is shown as follows.(1)
Normalization of the time series. Consider an annual precipitation series{x1,x2,…,xn}, we can transform the series to {x1′,x2′,…,xn′} by the normalization formula as follows. 												(2.8)xt′=xt-xmin⁡xmax⁡-xmin⁡(t=1,2,…,n),
where xmin and xmax denote the minimum and the maximum of the time series{x1,x2,…,xn}.(2)
Forecast of the data. The application of the RBF neural networks to time series data consists of two steps. The first step is the training of the neural networks. Choose the firstN value of the new series{x1′,x2′,…,xn′} as the training sample, and set up the RBF neural networks. Once the training stage is completed, the RBF neural networks will be applied to the forecasting data. Based upon the RBF neural networks established by the training sample, we forecast the value of the last n-Nelements of the series{x1′,x2′,…,xn′} and the forecasting series can be represented as{yN+1′,yN+2′,…,yn′}. In this study, we take that the value of the mean-square error is 0.0001 and the width of the radical primary function is 1.(3)
Denormalization of the forecasting series. Since the value of the elements in forecasting series is between zero and one, that isyj′∈[0,1], we should denormalize the forecasting series {yN+1′,yN+2′,…,yn′}to final forecasting{yN+1,yN+2,…,yn} through the denormalization formula as follows:
(2.9)yj=yj′×(xmax⁡-xmin⁡)+xmin⁡(j=N+1,N+2,…,n).


### 2.2.3. Autoregressive (AR) Model

In this paper, we regard the data of the annual precipitation as a time series and the trend term, seasonal term, and random term can be extracted from the time series in sequence. Then, we superpose the trend term, seasonal term and random term, and obtain the equation as follows [23–25]:(2.10)xt=At+Bt+Ct,
where xtis the precipitation time series, Atis the trend term, Btis the seasonal term, and Ctis the random term.The procedure of establishing the autoregressive model is shown as follows.(1)
The extraction of the trend term. In this paper, the data performs a clear quadratic algorithms component, so a polynomial function is used to fit the precipitation data. The trend termAt can be described as follows:
(2.11)At=P2t2+P1t+P0,
where Pi(i=0,1,2) is the coefficient of the quadratic polynomial (2.11).(2)
The extraction of the seasonal term. The analysis of precipitation seasonality can be accomplished with the aid of modeling via spectral analysis. The precipitation seasonality can be indicated withLwaves. BBtis the output of Pt subtractAt, and the estimated value of BBtcan be defined as BBt′:
(2.12)BBt′=a02+∑k=1L[akcos⁡2pktn+bksin⁡2pktn],
where L=[n/2]is the number of harmonicwave, ak and bk are the coefficient of the Fourier series (2.12):(2.13)a0=1n∑t=1nBBt,ak=2n∑i=1nBBtcos⁡2πkin(k=1,2,…,L),bk=2n∑i=1nBBtsin⁡2πkin.Taking the working capacity into consideration, we choose the significant wave to forecast. And we define thekth wave as the significant wave when the following inequality is satisfied:(2.14)sk2=ak2+bk2>0.5s2ln⁡(k/a)n,
where a is the level of significance (a=5%); s2 is the variance of the series:(2.15)s2=1n-1∑t=1n(Pt-P̅t)2.(3)
The extraction of the random term. The random termCt is defined as a linear combination of Ct-1,Ct-2,…,Ct-p:
(2.16)Ct=α0+α1Ct-1+α2Ct-2+⋯+αpCt-p,
where p is the order number of the model;αi(i=0,1,…,p) denotes the coefficient of the regression model, which can be confirmed by AIC (Akaike’s Information Criterion) formula:
(2.17)AIC(p)=nln⁡σp2+2p,
where n is the number of series, σp2represents the variance of AR(p) and the appropriative of p can be chosen among 1, 2, 3, and 4.


## 2.2.1. Rank Set Pair Analysis (R-SPA) Model

The procedure of the establishment of this model is shown as follows.(1)
Consider an annual precipitation seriesx1,x2,…,xn, we constructed the history sets A1,A2,…An-T, current set B and the subsequent value of these sets are represented in Table 1.Table 1
History setAt and current set B.
History setElementsSubsequent valueA1x1,x2,…,xTxT+1A2x2,x3,…,xT+1xT+2⋮⋯⋯Aixi+1,xi+2,…,xi+Txi+T+1⋮⋯⋯An-Txn-T,xn-T+1,…,xn-1xnCurrent setElementsSubsequent valueBxn-T+1,xn-T+2,…,xnxn+1Because of the weak dependence in the annual precipitation series, we assume that the number of history set and current setT to be an integer from 4 to 6.(2)
Rank transformation. We mark the elements inA1,A2,…,An-T,B from 1 to T according to the rank of elements in the sets they belong to. If some elements have the same rank, we mark them according to their average rank and round off the value. Then, we could obtain the rank setA1′,A2′,…,An-T′,B′.(3)
Constructn-T rank set pairs(Ai′,B′)(i=1,2,…,n-T)and calculate the difference d between the corresponding elements of Ai′ and B′. If the absolute value of d is equal to zero, we mark them “identical”; if the absolute value of d is greater than T-2, we mark them “contrary”; if the absolute value of d is between zero and T-2, we mark them “discrepant.” Respectively, count the total number of “identical,” “contrary,” and “discrepant” of each rank set pair. According to the value of the coefficient of the discrepancy degree i and the coefficient of the contrary degreej, the connection degree formula as follows:
(2.6)μA-B=SN+FNi+PNj,
where μ is the connection degree of the set pair, N denotes the total number of characteristics of the set pair, S represents the number of identity characteristics, P is the number of contrary characteristics, F is the number of the characteristics if the set pair is neither identity nor contrary. According to (2.6), we calculate the value of the connection degree of each rank set pair.(4)
In accordance with the maximum principle, we can find a similar setAi′ of B, and also we can find several similar sets of B under certain circumstances.Ai′ is the counterpart of Ai, and the subsequent value of Ai is xT+1. We can obtain the value of xn+1 through the formula as follows:
(2.7)xn+1=1m∑k=1mwkxT+k,
where wk is the ratio of the average of the elements in B and the average of the elements inAk, mis the number of the similar sets of B.


## 2.2.2. Radical Basis Function (RBF) Model

The interpretation of the RBF method as an artificial neural network consists of three layers: one layer is the input layer neurons feeding the feature vectors into the network; another layer is a hidden layer of RBF neurons calculating the outcome of the bas functions; the last layer is the output layer neurons calculating a linear combination of the basis functions [21, 22]. The different numbers of hidden layer neurons and spread constant are tried in the study. Its topological structure is shown in Figure 2.Figure 2
The topological structure of RBF.The procedure of the establishment of this model is shown as follows.(1)
Normalization of the time series. Consider an annual precipitation series{x1,x2,…,xn}, we can transform the series to {x1′,x2′,…,xn′} by the normalization formula as follows. 												(2.8)xt′=xt-xmin⁡xmax⁡-xmin⁡(t=1,2,…,n),
where xmin and xmax denote the minimum and the maximum of the time series{x1,x2,…,xn}.(2)
Forecast of the data. The application of the RBF neural networks to time series data consists of two steps. The first step is the training of the neural networks. Choose the firstN value of the new series{x1′,x2′,…,xn′} as the training sample, and set up the RBF neural networks. Once the training stage is completed, the RBF neural networks will be applied to the forecasting data. Based upon the RBF neural networks established by the training sample, we forecast the value of the last n-Nelements of the series{x1′,x2′,…,xn′} and the forecasting series can be represented as{yN+1′,yN+2′,…,yn′}. In this study, we take that the value of the mean-square error is 0.0001 and the width of the radical primary function is 1.(3)
Denormalization of the forecasting series. Since the value of the elements in forecasting series is between zero and one, that isyj′∈[0,1], we should denormalize the forecasting series {yN+1′,yN+2′,…,yn′}to final forecasting{yN+1,yN+2,…,yn} through the denormalization formula as follows:
(2.9)yj=yj′×(xmax⁡-xmin⁡)+xmin⁡(j=N+1,N+2,…,n).


## 2.2.3. Autoregressive (AR) Model

In this paper, we regard the data of the annual precipitation as a time series and the trend term, seasonal term, and random term can be extracted from the time series in sequence. Then, we superpose the trend term, seasonal term and random term, and obtain the equation as follows [23–25]:(2.10)xt=At+Bt+Ct,
where xtis the precipitation time series, Atis the trend term, Btis the seasonal term, and Ctis the random term.The procedure of establishing the autoregressive model is shown as follows.(1)
The extraction of the trend term. In this paper, the data performs a clear quadratic algorithms component, so a polynomial function is used to fit the precipitation data. The trend termAt can be described as follows:
(2.11)At=P2t2+P1t+P0,
where Pi(i=0,1,2) is the coefficient of the quadratic polynomial (2.11).(2)
The extraction of the seasonal term. The analysis of precipitation seasonality can be accomplished with the aid of modeling via spectral analysis. The precipitation seasonality can be indicated withLwaves. BBtis the output of Pt subtractAt, and the estimated value of BBtcan be defined as BBt′:
(2.12)BBt′=a02+∑k=1L[akcos⁡2pktn+bksin⁡2pktn],
where L=[n/2]is the number of harmonicwave, ak and bk are the coefficient of the Fourier series (2.12):(2.13)a0=1n∑t=1nBBt,ak=2n∑i=1nBBtcos⁡2πkin(k=1,2,…,L),bk=2n∑i=1nBBtsin⁡2πkin.Taking the working capacity into consideration, we choose the significant wave to forecast. And we define thekth wave as the significant wave when the following inequality is satisfied:(2.14)sk2=ak2+bk2>0.5s2ln⁡(k/a)n,
where a is the level of significance (a=5%); s2 is the variance of the series:(2.15)s2=1n-1∑t=1n(Pt-P̅t)2.(3)
The extraction of the random term. The random termCt is defined as a linear combination of Ct-1,Ct-2,…,Ct-p:
(2.16)Ct=α0+α1Ct-1+α2Ct-2+⋯+αpCt-p,
where p is the order number of the model;αi(i=0,1,…,p) denotes the coefficient of the regression model, which can be confirmed by AIC (Akaike’s Information Criterion) formula:
(2.17)AIC(p)=nln⁡σp2+2p,
where n is the number of series, σp2represents the variance of AR(p) and the appropriative of p can be chosen among 1, 2, 3, and 4.


## 2.3. Calculation of the Weights of the Submodels

The key of setting up the optimal weight combination model is to ascertain the weight of each forecasting model. In this study, we choose the weight which satisfies that the error sum of squares of the combination model is the minimum among all weight combination forecasting models, that is(2.18)min⁡f=min⁡∑i=1nei2=min⁡∑i=1n(xi-∑j=1Nwjxji)2,
where f is the error sum of squares of the combination model.Two matricesS and E′ are defined as(2.19)S=[e11e12…e1ne21e22…e2n⋮⋮⋱⋮eN1eN2…eNn],eij(i=1,2,…,N,j=1,2,…,n),eij is the error of the jth forecasting value of the ith model,(2.20)E′=SST=[e11′e12′…e1N′e21′e22′…e2N′⋮⋮⋱⋮eN1′eN2′…eNN′].
And, the formula (2.13) can be represented as follows:(2.21)min⁡f=min⁡∑i=1nei2=min⁡∑i=1n(xi-∑j=1Nwjxji)2=∑i=1N∑j=1Nwiwjeij′.If we obtain the value ofwj(j=1,2,…,N) with the aid of formula (2.4), (2.5), and (2.21), then we can ascertain optimal weight combination model.Genetic algorithm is an adaptive heuristic search algorithm premised on the evolutionary ideas of natural selection and genetic mutation, and it has always been regarded as a function optimizer [26–28]. The flow chart of genetic algorithm is shown in Figure 3.Figure 3
The flow chart of genetic algorithm.In this paper, we use the improved real-code genetic algorithm (IRGA) to solve this optimization problem. The population size is 20; the crossover fraction is 0.8, and the generation is 100.


## 3. Application of the Optimal Weight Combination Model

In this study, the data of the annual precipitation from 1978 to 2008 for Beijing are collected and shown in Figure4.Figure 4
An annual precipitation from 1978 to 2008 for Beijing.Firstly, we use R-SPA, RBF, and AR models to forecast the annual precipitation from 2004 to 2008 of Beijing, respectively. And the outputs of the three models are shown in Table2.Table 2
The forecasted data of three submodels.
YearMeasured value (mm)ModelR-SPARBFThe autoregressive modelForecasted value (mm)Error (%)Forecasted value (mm)Error (%)Forecasted value (mm)Error (%)2004483.5379.0104.5178.8304.7520.2−36.72005410.7358.851.9317.892.9429.1−18.42006318.0369.1−51.1407.5−89.5541.9−223.92007483.9382.5101.4531.0−47.1445.138.82008626.3400.1226.2576.050.3407.8218.5Based on the forecasted data of the three submodels, the weights of the three submodels in the combination model are obtained by using IRGA [19] and the weights of the three models are 22.9%, 37.2%, and 39.9%, respectively, and are given in Table 3.Table 3
The weights of the three submodels.
ModelWeightR-SPA model22.9%RBF neural networks model37.2%Autoregressive model39.9%Based on the obtained weights, we calculate the forecasted data of optimal weight combination model, and the output is represented in Table4.Table 4
The forecasted data of the combination model.
YearMeasured value (mm)Forecasted value (mm)2004483.5360.62005410.7371.32006318.0451.92007483.9462.22008626.3468.1By comparing the output of the combination model with the output of the three submodels, we find that the error sum of squares of the combination model is apparently lower than that obtained for any other submodel. In this study, the value of the error sum of squares is regarded as the standard for judging the precision of the forecast of the annual precipitation of Beijing, and the improvement of the precision of the new weight combination model compared with three submodels is shown in Table5.Table 5
The improvement of the precision of the new weight combination model.
Compared modelsThe improved precision of new weight combination modelR-SPA model22.6%RBF model47.4%Autoregressive model40.6%So we conclude that the precision of the combination model is higher than that of three models in terms of the error sum of squares.


## 4. Conclusions

A new optimal weight combination model, based on the R-SPA, RBF, and AR models and one weight optimization model based on improved real-code genetic algorithm (IRGA), is proposed in this paper. The annual precipitation time series of Beijing from 1978 to 2008 are studied by using the new model. The main conclusions are given as follows.(1)
Three submodels, that is, R-SPA model, RBF model, and AR model, are tested to forecast the annual precipitation of Beijing, and the results suggest that R-SPA is better and RBF worst in the three models in terms of the error sum of squares. Different models have different precision for forecasting annual precipitation.(2)
The optimal weights can be obtained by use of IRGA in new optimal weight combination model. Application results of the combination model indicate the weights of the submodels can be appropriately confirmed and such method provides a new way to improve the prediction precision for forecasting complex precipitation time series.(3)
Compared with the results of R-SPA, RBF, and AR models, the proposed model can improve the forecast accuracy of precipitation in terms of the error sum of squares, and its improved precision is 22.6%, 47.4%, 40.6%, respectively. So the precision of the three submodels can be improved by establishing the new model in precipitation forecast.(4)
Because of the fail to avoid the drawbacks of three submodels completely, the accuracy of the combination model is inevitably affected. In the future, the accuracy of the combination model may be improved by applying some more advanced submodels.



---

*Source: 376010-2012-05-28.xml*