EEG Signal Recognition Based on Wavelet Transform and ACCLN Network

The electroencephalogram (EEG) is a record of brain activity. Brain Computer Interface (BCI) technology formed by the EEG signal has become one of the hotspots at present. How to extract the feature signal of EEG is the most basic research of BCI technology. In this paper, A new method of recognizing fatigue, conscious, concentrated state of human brain is proposed by the combination of discrete wavelet transform and the neural network based on EEG signal. First of all, the law signal is preprocessed by the wavelet denoising method because the law EEG signal contains a large number of high frequency noise, which is decomposed into multi-layer high frequency signal and low frequency signal. thus, δ wave, θ wave, α wave, β wave are obtained by the wavelet transform. And then, frequency band energy of the different wave is regards as the feature signal of EEG. In the experiment, the feature signal is classified by radial basic function (RBF) and annealed chaotic competitive learning network (ACCLN). RBF and ACCLN networks are trained with 500 sets of sample data and are tested by 100 sets of samples in different mental states. The experimental results show that the average accuracy of RBF network under three conditions are 88.75%, 88.25%, 88.5%, respectively, and the correct rate of ACCLN network is 97%, 98%, 98%, respectively.


Introduction
Electroencephalogram (EEG) signals are the potential difference between the cells of the brain when the brain is active, they are superposition reflects of the brain's nerve cells on the surface of the scalp or the electrophysiological activity of the cerebral cortex.In recent years, brain computer interface technology has become one of the hot research topics in computer field.With the manmachine interface technology has become more sophisticated, EEG acquisition technology has also been rapid development.Brain wave can control the external objects with the help of the brain's electrical signals by using BCI technology [1][2][3].So study on EEG signal recognition and feature extraction is very important to BCI technology.Brainwave is a potential difference between the cells of the cerebral cortex for different people.EEG signal frequency is mainly concentrated in the low frequency range of 0.5Hz to 50Hz, the potential difference in the range of 0 to 200mV [4][5].Brainwave signal is a non-stationary weak signal, it is easy to drown in the strong background noise, so we must remove the noise before feature extraction.A method is proposed that EEG data is extracted by independent component analysis [6].P300 BCIs is used to obtain an embedded channel selection approach based on grouped automatic relevance determination [7].A robotic upper limb is controlled using human intracranial EEG and eye tracking [8].Design of FIR filters and the associated spatial weights by optimizing an objective function can effectively extract discriminative features for motor imagery-based brain-computer interface [9].In summary, BCI technology has been widely used in the field of intelligent control.
In this paper, we use the Mindwave Mobile launched by United States Neurosky Co. Ltd, it can collect and monitor the brain waves of the frontal lobe.At present, the method for EEG signal processing have single category information [10], traditional time-frequency feature combination [11], neural network analysis and wavelet transform [12][13].The δ wave, θ wave, α wave, β wave are obtained by using wavelet transform for raw brainwave data.The RBF neural network and ACCLN neural network are designed for condition recognition by using EEG data.We verify the correct rate of EEG signal recognition by using RBF neural network and ACCLN network in MATLAB software.
The rest of this paper is organized as follows: The related research is introduced in the next section.In section 3, a new EEG signal recognition method is proposed in detail.The experiment results are given in section 4. Finally, we conclude in the last section.

Radial Basic Function
RBF network is a kind of three layer forward network.The input layer is composed of the signal source node; the second layer is the hidden layer, the number of the hidden unit depends on the description of the problem, The transform function of the hidden unit is radial basis function, which is non-negative function of the radial symmetry of the center point.The third layer is the output layer.The transformation is nonlinear from the input space to the hidden layer space and linear from the hidden layer to the output layer.The mapping relationship is determined when the RBF determines the central point.Figure 1 shows RBF network structure and network mapping relationship.RBF network can approximate any nonlinear function, which has good generalization ability, it has been successfully applied to nonlinear function approximation, time series analysis, data classification, pattern recognition, information processing, image processing, system modeling, control and fault diagnosis, etc..The training data is classified correctly by a given hyperplane.Which is represented by (w,b).
The hyperplane is equally expressed by all pairs { } λ λ , w b for λ + ∈ R .Thus, the canonical hyperplane is used to separate the data by a "distance".The distance relationship satisfies the following formula: Reflected Sigmoidal function: ( ) Inverse multiquadrics function: ( ) ( ) σ is the expansion coefficient, the smaller the σ, the smaller the width of RBF, the more selective basis functions.
RBF network mainly needs three kinds of parameters: (1) Center of basis functions; (2) Expansion coefficient of basis function; (3) Weight of hidden layer and output layer.

Selection of Cluster Center
A variety of dynamic clustering algorithm is used to select the data center, the position of the data center should be adjusted in the process dynamically.K-means clustering algorithm is one of the common local search approaches, the advantage of the algorithm is that the expansion constant of each hidden node can be determined according to the distance between the cluster centers.Because the number of hidden nodes in RBF network has a great influence on its generalization ability, how to find a reasonable method to determine the number of clusters is a major task for the design of RBF network.Here, K-means algorithm is applied to determine the data center, the iterative procedure is shown in Equation (4).
Where, i t is the i-th cluster center. ( )i t n is the i-th cluster center in iteration step n. (i=1,2,3,...,I).x is the k-th input sample.η is a learning factor.When ξ , stop.

Determine the Expansion Coefficient
After determining the cluster center, the expansion coefficients of the corresponding radial basis functions can be determined according to the distance between the centers.Expansion coefficient σ i is represented in Equation ( 5).= min − Where, Expansion coefficient = , is overlap coefficient.

Weight Factor
The output layer of the RBF network is a weighted sum of the hidden layer neurons.So the actual output of the RBF network is as follows: Where, Pseudo inverse method： σ The traditional neural network is probably not global-minima, but local-minima in the training process.So chaotic simulated annealing is used to escape from local-minima and get global-optimal solution by the annealed chaotic mechanism in neural network.The energy function of the neural network demonstrates the convergence process.The related research is proposed in [14][15].A single chaotic dynamics neuron-annealing model is shown in eq.(9-10): q t E T t p t (10) Where: ( ) p t = transient state of the interconnection strength between input neurons and output neurons ( ) q t = internal state of the interconnection strength between input neurons and output neurons

Proposed Method
The process of EEG signal recognition based on the DWT and neural network is shown in Figure 5.It contains three steps: (1) Signal processing, during the process of signal transmission and collection, the EEG is polluted regularly by noise.The pure EEG is obtained by using thresholding of wavelet denoising method.(2) Feature extraction, the DWT is carried out on the EEG to get the sixth layer low frequency signal and the high frequency signal of the 2-6 layer, the δwave, θwave, αwave, β wave of EEG are selected by FFT and the sub-band energy is calculated.(3) Signal recognition, the neural network is used to recognize the EEG signal generated in different state.The threshold selection is the key to identify noise and other details of the definition, in this paper the threshold T is obtained based on the method of Bayes Shrink threshold estimation: Where, wn is wavelet coefficients and δ is noise variance, the Median estimate is performed with the first layer of high frequency coefficient wHH: The threshold function is the different processing strategies to process wavelet coefficients above or below threshold T:

Signal Processing
High frequency coefficients of noise correlation are filtered after threshold quantization, then the pure EEG signal are restructured based on the new coefficients wnew.

Feature Extraction
From the point of time domain, the EEG signals have no obvious feature, but feature is obvious and easy to get if time domain signal is transformed into frequency domain signal.The range of brainwave frequency changes greatly.Research shows that the frequency of brain activity is mainly between 0.5Hz and 40Hz and is shown in Table 1.EEG signal is a non-stationary signal, If the time domain signal is converted to the frequency domain by FFT, Its time domain information will be lost and the extracted features are too single, the processing effect is not very good.Here, The wavelet transform can obtain rich characteristics of EEG signal.The EEG signal is decomposed into different levels reconstruction signal by using db5 wavelet function and is shown in Figure 8.The FFT results of them are shown that they are similar to δ wave, θ wave, α wave, β wave of EEG.So we can obtain these waves by using wavelet transform method in Figure 9. Signal decomposition expression: Where detail coefficient: ( 1) scaling function: wavelet function: Signal reconstruction expression: ( 1) The raw data are decomposed by wavelet transform and obtain the δ(x) wave, θ(x) wave, α(x) wave, β(x) wave, its sub-band signal energy is shown as follows: Calculate the energy ratio of each signal:  10, In fatigue state, the sub-band energy of EEG signal is mainly focused on the δ wave; In the conscious state, the energy of δ wave decreases, and the other wave energy rises; In a concentrated state, the energy of α wave is more prominent.for the frequency, with the concentration of the mental state, the energy of the low frequency signal is reduced, and the energy of the high frequency signal is increased.After wavelet decomposition, the ratio of EEG signals in different states can be quantitatively analyzed, The extracted features are obvious and easy to be distinguished, which lays the foundation for the accurate and reliable identification of neural networks.

Annealed Chaotic Competitive Learning Network
The conventional competitive learning network may be obtained local minimum solutions in the training network, thus embeds into an annealed chaotic mechanism and obtains an optical solution in a global scope for the network [17].The transient chaotic network model sensitively relies on a selffeedback connection weight.The weight is similar to a stochastic simulated annealing temperature and changes dynamically in the process of the network.The annealed chaotic competitive network can escape the local-minima and reduce the convergence time quickly.
Figure 11 shows a two-layer annealed chaotic competitive learning network (ACCLN).This is an annealed chaotic neural network topology.For the network, n neurons in the input layer are divided into c classes in the output layer.That's to say, there are c cluster-centers in the output layer.In the training process, the internal state ; x j q and the transient state The convergence process of the ACCLN is shown in [18].The neuron states are changed by the function ; x j q .A simulated annealing strategy is used as the training network by Equation ( 28).The network model has n neurons in the input layer, c neurons in the output layer and n × c interconnection strengths.The mathematical expression of this model is shown as follows: x j x j q t p t e ( x j x j x j q t q t E T t p t ( Where E is energy function, the network has n input neuron nodes and c output nodes.; x j p and ; x j q are the transient state and internal state of interconnection strength, respectively.j w is weight coefficient between each input neuron node and output neuron node.η is a small learningrate parameter.These parameters are updated in real time in training process.

The Experimental Platform and EEG Signal Extraction
The human cerebral cortex is mainly divided into four regions, the occipital lobe, frontal lobe, parietal lobe and temporal lobe.The area of human mental state is located in frontal lobe.EEG signal is collected by the headset of NeuroSky Inc. in the experiment.The equipment acquisition of EEG electrode position is shown in Figure 12, the brain electrode is placed on the forehead, the other electrode grips ear.The EEG signal is filtered, amplified and A/D conversion.The sampling frequency of the module is 512Hz, 16 bit A/D converter.The module sends 512 packets per second.30 subjects are selected in the experiment, 10 people who slept for 12 hours are regarded as conscious subjects, 10 people who are not sleeping for 12 hours are regarded as fatigue subjects.10 people who are playing game after sleeping for 12 hours are regarded as concentration subjects.
Neural network is an adaptive pattern recognition technology, it does not need to give the empirical knowledge and discriminant function, which can train the information from different states and obtain some kind of mapping relation.Therefore, neural networks have been widely used in pattern recognition, The identification process is shown in Figure 13.The expected output of the network is (0, 1, 0) under the fatigue state, the conscious state is (1, 0, 0), and the concentration state is (0, 0, 1).The output function of the RBF network is a linear function and the output range is [0, 1].Root mean square error is calculated by formula (34).The closer the actual output and the expected output is, the more accurate the test is.Figure 14 shows the error of RBF network in different state.When the overlap coefficient is 0.1, the recognition effect is the worst, and the partial difference is more than 0.5, With the increase of , the higher the accuracy rate of RBF network, the smaller the output error.The output function of the ACCLN has only two states, 0 or 1.That's to say, the recognition result is true or false.Compared with RBF network, the correct recognition rate of ACCLN network is high.the number of the correct identification is 97 in the fatigue state, 98 in conscious state and 97 in a concentrated state.In the test samples of the 300 groups, the recognition error is 7, and the success rate is 97.6%.In general, brainwave recognition rate of ACCLN network is superior to the RBF network.

Conclusions
In this paper, a new method is proposed that recognition method of EEG signals uses discrete wavelet transform and neural network.First of all, the raw EEG signals are acquired by headset of NeuroSky Inc..Because of the noise in the signal acquisition and transmission, it is necessary to remove the noise.Wavelet denoising method based on threshold is a good way of removing the high frequency noise of the signal.And then, the δ wave, θ wave, α wave, β wave of EEG signals are obtained by DWT and FFT, the energy value of different wave is used as the characteristic value of the signal recognition.Finally, the ACCLN network and RBF neural network with different overlap coefficient are used to identify the EEG signal, the experiment result shows that ACCLN network is a better way to recognize EEG signals than RBF network, At the same time, the effectiveness of the proposed algorithm is verified, which lays a good foundation for the subsequent development of BCI technology.

Figure 1 .
Figure 1.RBF network structure and mapping relationship.

Figure 2 shows 2 (Figure 2
Figure2shows RBF structure of single neuron.The Euclidean distance between the input and the weight vector is used as the independent variable in RBF network.The activation function is generally Gauss's function, reflected sigmoidal function, inverse multiquadric function. k

0IEFigure 3 .
Figure 3.The initial value of weight T is 0.0677.while T < 0. 0677, the transient state ( ) p t shows a process from chaotic state though periodic bifurcation to a steady-state.The chaotic function converges with the decrease of ( ) T t gradually.Where the initial condition is as follow: λ = 0.004 , μ = 0.899 , = 0 E , = 0 0.649 I .The chaotic behavior is used in a neural network.An annealed function is used to converge to a stable equilibrium point for a dynamic weight ( ) T t .

Figure 3 .
Figure 3. Shows the various bifurcation states for different T(t) during 4000 iterations.

Figure 4
Figure 4 shows the time evolution of output ( ) p t and annealing process ( ) T t .The initial value for single neuron is as follows: = 0 E , = 0 0.65 I , = 0 0.09 T , λ = 0.004 , μ = 0.899 , α = 0.9998 , β = 450 [23].( ) p t can converge to a steady-state value.It shows the process of a number of iterations and bifurcation of chaotic dynamics.Exponential damping of ( ) T t is a process of simulated annealing [11].The dynamic structure embeds into the competitive learning network in the experiment.Furthermore, the initial value of the parameters influences the dynamics process in training network.The above selected parameters are valid for all the bifurcation processes.The experiment shows the annealed chaotic mechanism can converge rapidly in the competitive network.Figure 4(a) demonstrates the output of a single neuron ( ) p t .Figure 4(b) demonstrates annealing

Figure 5 .
Figure 5.The block diagram of EEG signal recognition.

Figure 6 (Figure 6
Figure6(a) shows that the raw EEG signal collected by sensor contain a large amount of noise, it will have a great impact on the subsequent feature extraction and recognition if it is not processed.The method based on the thresholding of wavelet denoising is shown in Figure6(b), the sym5 wavelet function is used to carry out the 5 layer decomposition of the raw EEG signal, the new wavelet coefficients ^, j k W are get by thresholding based on equation (12) and (15).The pure EEG signal is shown in Figure7and the wavelet are restructured by using ^, j k W .

Figure 7
Figure 7 The wavelet denoising method based on thresholding.

Figure 8 Figure 9 .
Figure 8 The wavelet decomposition and reconstruction.

Figure 10
Figure 10 Energy distribution in the different states.

Figure 11 .
Figure 11.Chaotic annealing mechanism embedded in the ACCLN network topology.

Figure 13 .
Figure 13.System structure based on neural network.

4. 2 .
Test Experiment Based on RBF Network Set the overlap coefficient of RBF network is 0.1，0.2，0.3，0.5.Feature (Eδ，Eθ，Eα，Eβ) is extracted from 500 sets of acquisition data sample and is regarded as training sample.100 sets of EEG signals of the subjects are acquired in fatigue, conscious and concentration state.The feature vector is calculated as the input of the neural network.In three different states, the classification results of the 10 sets of test samples are shown in the Table 3-5.
(a) the fatigue state (b) the conscious state (c) the concentrated state

Figure 14
Figure 14 Output error of RBF network

Table 1 .
Relationship between EEG frequency and brain states.

Table 2
The average energy value in the different states

Table 3 .
The RBF network output with different overlap coefficient under fatigue state.

Table . 4
The RBF network output with different overlap coefficient under conscious state

Table 5
The RBF network output with different overlap coefficient under concentrated state