Bayesian Network and Association Rules-based Transformer Oil Temperature Prediction

The oil temperature prediction of transformer is very important for the operation stability and life evaluation of transformer. As the oil temperature prediction of transformer is still short of a comprehensive and efficient method with combining various information of transformer such as operation data and meteorological data, this paper proposed a Bayesian network and association rules-based transformer oil temperature prediction method, which can improve the prediction accuracy of RBF-NN for transformer oil temperature prediction. The proposed method first mines all association rules among transformer state data and transformer operation data and environmental meteorological information by combining the Bayesian network and the Apriori algorithm and then uses the association rules to improve the prediction accuracy of RBF-NN based on only transformer state data. A case study with a 500kV transformer is conducted to test the effectiveness of the proposed method, and the result shows that the proposed method can improve the prediction accuracy of RBF-NN about 10%.


Introduction
Transformer is one of the most important equipment in power transmission network. In order to ensure the safe and stable operation of transformer, it is very necessary to predict the oil temperature of transformer. The existing transformer oil temperature prediction methods are mainly based on a single or few state parameters. Most of them are limited to threshold diagnosis and the inherent relationship between transformer state variables and transformer operation data and environmental meteorological information to conduct a comprehensive prediction, which lead to the analysis and prediction results one-sided and inaccurate. Therefore, how to make full use of the inherent law between various state data of transformers to increase the prediction accuracy of transformer oil temperature becomes a key problem. Obviously, association rule mining among transformer state variables with combining transformer operation data and environmental meteorological information will help to improve the prediction accuracy of transformer oil temperature.
In this paper, the Bayesian network is introduced to mine the association rules between transformer oil temperature and its related state variables. An association rule mining method is proposed by combining the Bayesian network and the Apriori algorithm, and the results of association rule mining are used to improve the prediction accuracy of transformer oil temperature. First, the proposed method uses the Apriori algorithm to find out all frequent 3-itemsets. Second, the Bayesian network is introduced to mine all association rules and calculates the support and confidence of each association rule. Finally, the association rules mined by the proposed method is used to improve the prediction A case study on a 500kV transformers is conducted to verify the effectiveness of association rule mining with combining the Bayesian network, and the results show that the proposed method can efficiently mine all association rules among transformer state variable and improve the prediction accuracy of transformer oil temperature with RBF-NN.

Related works
At present, the calculation methods of transformer oil temperature mainly include hot spot temperature calculation method, heat circuit model calculation method, numerical calculation method and intelligent prediction method. Among them, the empirical model for calculating hot spot temperature of transformer windings recommended by GB/T 15164-1994 and IEEE Std C57.91-1995 was first used. In view of the fact that the first derivative model in two guidelines does not take environmental temperature into account, many researchers improved the first derivative model and proposed a top oil temperature model including environmental temperature and a heat circuit model for solving hot spot temperature [1][2][3]. Numerical calculation method is widely applied in transformer internal temperature calculation with its continuous development, for example finite volume method is often used to solve the flow and heat transfer problem [4]. With the rapid development of artificial intelligence, intelligent algorithms for predicting transformer oil temperature based on historical monitoring data are emerging [5,6]. Li constructed a hot spot temperature and top oil temperature prediction model of transformer winding by using an artificial neural network, and obtained a lot of good prediction results [6]. In addition, support vector machine and Kalman filter are also applied to oil temperature prediction [7,8].
In summary, the direct measurement method is simple to operate and the measurement results are the most accurate, but in practical application, the high cost of measurement equipment and the difficulty of operation and maintenance increase the cost of measurement. The hot spot temperature calculation method often produces non-negligible errors when transformer load changes. The thermal circuit model calculation method is simple, but the calculation results need to be optimized. The numerical calculation method involves many parameters. The process of oil temperature prediction using intelligent algorithm is simple and the prediction accuracy is high. It will certainly develop into an important tool to solve the prediction problem of transformer oil temperature in the future.

Bayesian network and association rules-based transformer oil temperature prediction
In the prediction of transformer oil temperature based on Bayesian network and association rules, all association rules among various states of transformer are firstly found by using the Apriori algorithm and the Bayesian network, and then the model parameters of RBF-NN are optimized according to the association rules. Finally, the accurate prediction of transformer oil temperature is achieved by RBF-NN with the optimized parameters.

The construction of the Bayesian network
A Bayesian network is a directed acyclic graph that can describe the relationship of state variables and achieve the probabilistic reasoning. For a set of variables X={X1,X2,...,Xn}, the Bayesian network represents the joint probabilities based on conditional probability chains as shown in equation (1).
(1) A Bayesian network consist of two parts: qualitative description and quantitative description. • A directed acyclic graph consists of several nodes and directed edges. Nodes represent random variables such as phenomena, states or attributes in a target problem. Directed edges represent the relation of dependence or causality between nodes and the arrow of a directed edge represents the direction of dependence or causality, and undirected edges between nodes represent the conditional independence of the corresponding variables. • A conditional probability table represents the correlation degree between a child node and its parent node, and the probability of a node without the parent node is its prior probability.
Assuming that G denotes a directed acyclic graph, V is a set of n random variables, L denotes a set of edges, P denotes a set of conditional probability distributions, the Bayesian networks can be described as follows: Herein, G, V and P can be described with the following equations.
According to the chain rule (1) and conditional independence assumption, if is the parent node set of a variable Vi, then the joint probability distribution can be described as follows:

The key steps of association rule mining
The purpose of association rule mining is to find out the relationship between different items in a dataset. Association rule mining has the following important concepts: ① The dataset of association rule mining is denoted as D={t1,t2,...,tm}, where tk={i1,i2,...,in}(1≤k≤ m) is called a transaction, ij(j=1,2,...,n) is called an item. Each transaction has a unique identifier TID.
② Let I={i1,i2,...,ip} is a set of all items in D. Any subset X of I is called an itemset of D. If |X|=k, X is a k-itemset. If X∈tk, the transaction tk contains the itemset X ③ The number of the transactions containing the itemset X in D is called the support number of X, which is denoted as . The support of X is denoted as support(X): Where |D| is the element number of D. If support(X) is not less than the minimum support threshold minSup, then X is called a frequent itemset. Otherwise, X is called a non-frequent itemset.
④ If X and Y are two itemset and ∩ = , ⇒ is called an association rule. The support of ∪ is called the support of ⇒ , which is denoted as support( ⇒ ).
The confidence of ⇒ is denoted as confidence( ⇒ ): The minimum confidence threshold should be specified in association rule mining and denoted as minConf. The support is used to measure the statistical importance of an association rule in D, and the confidence is used to measure the statistical credibility of an association rule in D.
⑤If X⇒Y satisfies support(X⇒Y)≥minSup and confidence(X⇒Y)≥minConf, X⇒Y is called a strong association rule. If not, X⇒Y is called a weak association rule.
The purpose of association rule mining is to mine all strong association rules in D. Association rule mining can be divided into two steps: Step 1: Find out all frequent itemsets in D according to the minimum support.
Step 2: Mine all association rules according to the frequent itemsets and the minimum confidence.

Mining association rules with Bayesian network
The procedure of mining all association rules between state variables based on the Bayesian network is as follows: Stage 1: Use the Apriori algorithm to find out all frequent 3-itemsets. The Apriori algorithm uses the iterative method of layer-by-layer search to generate the frequent itemsets from the candidate itemsets, and finally obtain all association rules from the frequent itemsets. The specific steps of finding out all frequent 3-itemsets are listed as follows: Step 1. Scanning all transactions and calculating the occurrences number of each item to generate the frequent 1-itemsets L1; Step 2. Generating the frequent 3-itemsets L3 from L1 with the following method: • Joining two patterns that have one common item to get C'2 and pruning C'2 according to the anti-monotonicity of frequent itemset to get candidate 3-itemsets C2. • Scanning the dataset D and calculating the support(C2,t) of the candidate 2-itemsets contained in each transaction t and storing it in a hash table. • Deleting the itemsets that the support is lower than minSup and getting the frequent 3-itemsets L3. Stage 2: Selecting the frequent 3-itemsets according to the concept of interest proposed by Piatetsky-Shapiro. When support(X∪Y)≈support(X)×support(Y), we consider that the 2-itemset (X,Y) are independent and the association rule X⇒Y is not interesting. The interest of the 2-itemset (X,Y) is defined as follows: • If interest(X,Y)>0, X and Y are positively correlated.
• If interest(X,Y)≈0, X and Y are independent and the 2-itemset (X,Y) will be deleted from the frequent 2-itemsets. • If interest(X,Y)<0, X and Y are negatively correlated. Stage 3: According to the 2-itemsets L2 in Stage 2, the Bayesian network can be constructed by taking each state as a node and taking L2 and conditional probability distribution as the edge.
Stage 4: According to the Bayesian network, the association rule set R is generated. Stage 5: Listing the probability table of all association rules and optimizing the parameters of RBF-NN with the association rules. To test the effectiveness of the proposed method, we take a 500kV transformer in a substation as an example to mine all association rules of transformer state variables. The daily average value probability density of transformer operation data such as operation current, active power and reactive    The association rules in all frequent itemset that the item number is more than 3 and their maximum support and maximum confidence are shown in table 1.

Using the result of association rule mining to improve the prediction accuracy of RBF-NN
RBF-NN is a forward three-layer neural network. The first layer is the input layer, the second layer is the hidden layer and the third layer is the output layer. As a neuron transformation function in the hidden layer, RBF is a radially symmetric and attenuated non-linear function for the central point, which changes a low-dimensional space input vector into a high-dimensional space input vector and makes a linear inseparable problem in a low-dimensional space become linear separable in a highdimensional space. RBF-NN not only has the advantages of global approximation, good generalization, small computation and fast learning velocity, but also has no local minimum problem. Therefore, RBF is widely used in many fields such as time sequence analysis and pattern recognition. The 1200 days' data of oil chromatogram, oil temperature and air temperature about the 500kV transformer from March 21, 2010 to June 28, 2013 are shown in figure 5, and the load current data are shown in figure 6.    figure 7, it can be observed that the average prediction error of RBF-NN with association rules is reduced about 10%, which proves that the proposed method can optimize the parameters of RBF-NN and improve the prediction accuracy of RBF-NN effectively.

Conclusion and future work
The changing trend of transformer oil temperature is affected by many factors such as load conditions and meteorological conditions. Using a large number of transformer historical data to mine the data law and predict the changing trend of transformer oil temperature is a key content of electric power big data analysis. In this paper, the correlation relationship among numerous state variables of transformer oil temperature is studied, and Bayesian network and association rules are introduced to improve the efficiency of association rule mining. It is applied to the prediction of transformer oil temperature, and improves the prediction accuracy of transformer oil temperature. In the future, we will predict the oil temperature of transformer with more machine learning algorithms.