Research on pulse signal identification algorithms based on adaptive filter and adaptive generalized cross-correlation

ABSTRACT In the area of water injection, pulse telemetry is a new and effective communication technology which is critical for the intelligent oilfield. Under a complex environment with unknown noises, numerous problems need to be solved in the process of pulses identifying and data decoding, and there are difficulties in researching the related algorithms. In this paper, the characteristics of the pulse signals and noises are analysed respectively, and an adaptive filter algorithm is applied to reduce the impact of noises in pulse signal processing. Then a new adaptive generalized cross-correlation algorithm is proposed to extract pulses by using a new weighted function, which can restrain interferences and noises in the frequency domain. By means of these algorithms, the pulse signal is more obvious with effective noise restraint, so these algorithms are more appropriate in water injection. Final results of field test indicate the algorithms have a high recognition performance and they meet the requirements of engineering application.

cost of cables and has not maintenance and connection problems of cables. It is an important problem for pulse telemetry to extract and identify pressure pulses with unknown noises. This paper focuses on pulse signal processing and identification algorithms of pulse telemetry in water injection. An adaptive filter algorithm is adapted to dispose of the pulse signal, then a new adaptive generalized cross-correlation algorithm is proposed to extract the pulse. By means of the suggested algorithms, it is effective to identify pulses and decode data. Figure 1 shows a pressure pulse communication system. The system comprises a pulse generator, a downhole control system, intelligent water allocators, a pressure sensor and a signal processing system. During the process of water injection, parameters of the injection layers, such as temperature, pressure and flowrate, are measured by intelligent water allocators and sent to a downhole control system. According to preset encoding rules, a pressure pulse generator is controlled by the downhole control system, transforming the digital signal into the pulse signal. The pressure pulse generator is essentially a rotary valve which can generate the pulse signal by changing the circulation area of the channel. A pressure sensor at the surface receives the pressure waves that are propagated in the fluid. On the basis of pulse signal processing and identification algorithms, the signal is processed by the surface signal processing system and decoded words is obtained accurately (Pillai, Marsh, Dudley, & Spross, 2017).

Pressure pulse communication system
The pulse signal contains varied noises acquired by the surface signal processing system, therefore it is critical to identify weak pulses and decode data in the environment with unknown noise. The specific signal processing steps proposed in this paper are shown in Figure 2.

Pulse coding and modulation method
The function of pulse modulation is to transform the digital signal into the pulse signal so that the signal can be transmitted in the channel. Without proper decoding of the pulses, downhole parameters of the injection layers are lost. Pulse position modulation (PPM), which is a standard communication protocol known in the art, is used for coding the pulse signals. PPM is a method which uses the time interval between two pulse peaks to represent data (Tu et al., 2015). PPM is preferred because it does not require continuous pulsing versus other methods that send signals continuously. When continuous pulsing is required, the pulse generator must constantly be actuated, thus causing more wear on the generator. Therefore, PPM is advantageous due to less wear and tear on the equipment (Finke, Doyle, Sun, & Pillai, 2005). As data transmission does not have a demand of fast data rates during the process of water injection, PPM is suitable and low-power for transmission. So it is easy and efficient to utilize PPM in the water injection. Figure 3 shows the scheme of PPM.
Data encoding is also necessary to transmit downhole information efficiently. A pulse sequence is divided into synchronization pulses and data pulses, both of which have a width of 2s. The encoding rule is specifical as follows: A pulse sequence: SSSS M . . .
(1) SSSS: Synchronization pulses, four pulses Time difference = 3 (s) (2) M: data pulses Time difference = A + m (s) m: data 0-9 (decimal) A: minimum time difference = 5 (s) Synchronization pulses represent the arriving of a pulse sequence and provide the reference for the following processing, while data pulses include the downhole information of the injection layers. Compared to data pulses, time differences of synchronization pulses are shorter.

Characteristics of the pulse signal and the noise signal
Due to the influence of the transmission channel, the surface environment and other factors, the signal contains varied noises acquired by the surface system (Cooper & Santos, 2015;Hutin, Tennent, & Kashikar, 2001). Therefore, it is vital to analyse the components of the pulse signal. Generally, the model of the pulse signal is given by the Equation (1): where x(t) is the signal acquired by the surface system, s(t) is the pulse signal generated by a pulse generator and transmitted to surface, and n(t) is the noise signal. The single ideal pulse signal from the pulse generator is shown in Figure 4. The waveform of the pulse signal is determined by the characteristics of the pulse generator (Emmerich et al., 2016). In this paper, the pulse generator is actually a rotary valve. Opening and closing the valve are the process of changing the channel flow area, which can produce positive pulse signals (Perry, Burgess, & Turner, 2008). Considering the low-power design of the downhole system and the characteristics of the pulse generator, opening and closing the valve create a series of momentary pressure changes, which includes rising and falling edges of the positive pulses. In accordance with this condition, the single ideal pulse signal from the pulse generator is a trapezoidal wave which has a width of 2 s.
Trapezoidal waves are considered as rectangular waves. So the rectangular wave theory is utilized to analyse the ideal pulse signal. In terms of this theory, the characteristics of periodic rectangular pulse signal spectrum are discrete, harmonic and convergent. The periodic rectangular signal can be converted into infinite sinusoidal signal components. 'Discrete' means that the discrete spectrum of the periodic rectangular signal is composed  of discontinuous spectral lines. Especially the spectrum of the single pulse is continuous. Figure 5 shows the continuous spectrum of the single ideal pulse signal, which is regarded as the envelope of the discontinuous spectrum, and this discontinuous spectrum can be obtained by sampling the continuous spectrum. 'Harmonic' means that each spectral line is located at the fundamental wave frequency and its multiples. 'Convergent' means that the amplitude of harmonic component is decreased with fluctuation with the increasing of harmonic frequency.
In reality, it is generally believed that the energy of the periodic rectangle signal is concentrated in a frequency range called bandwidth. And the spectrum of the expected pulse signal is discrete, harmonic and convergent, whose envelope is shown in Figure 5. Therefore, we draw a conclusion that the main component of the expected pulse signal is a low-frequency signal.
Then it is necessary to define the noise source. Figure 6 shows the pressure pulse signal sampled by the surface system. Noises exist in time domain all the time. Figure 7 shows the spectrum of this sampled signal. While the expected pulse signal is mainly low-frequency, the signal obviously includes pump noise. The noise of the pump presents a significant obstacle to accurate demodulation of the telemetry signal. The noise from the triplex pump consists of 4.38 Hz fundamental frequency and its multiples such as 8.78, 13.17 Hz. Moreover, the noise from the process of data acquisition is approximately considered to be the random Gaussian white noise. But the frequency of noises from fluid flow rate fluctuation and signal transmission is unknown, which depends on the field conditions. A major accompanying problem from the signal transmission is that the pulses attenuate and disperse as they propagate through the fluid. This dispersion is unavoidable and is caused by mechanisms, including viscous dissipation in the fluid as well as frictional energy loss at the pipe walls. In addition, the received signal is attenuated compared to the transmitted signal. These problems are exacerbated with increasing depth of the wellbore.
In summary, the complex water injection environment brings about varied noises and interferences, so it may lead to overlapping in spectrums between noise and the expected signal. The impact of pumps, data acquisition  and signal transmission is not predictable, not arbitrarily adjustable and potentially variable during the course of data transmission. As a result, with the difficulties in identifying pulse and decoding data, the sampled signal must be processed specifically.

Pulse signal filtering based on adaptive filtering algorithm
Normally, interference suppression and noise cancellation are applied to improve signal quality and to achieve maximum data rates. Based on the analyses mentioned above, classical filters are inappropriate in the situation of overlapping in spectrums between the expected signal and noises in an unknown noise environment. Therefore, the adaptive filter is utilized to enhance the Signal to Noise Ratio. Figure 8 shows the adaptive filter structure. The reference signal of the adaptive filter is an ideal synchronous sequence including four pulses. According to the reference signal, the LMS algorithm is to adjust parameters of a finite impulse response (FIR) filter automatically which causes a linear phase response. With a trained filter, the sampled signal is processed by optimum filtering.
The important characteristics of the adaptive filter are learning and tracking (Caruzo, Hutin, Reyes, Tweel, & Temple, 2012). This adaptive filter can automatically adjust its parameters with the change of the external environment. The adaptive filter works effectively through being adapted to the changing environment with unknown noises, such as pump noise and periodic low-frequency noise from data acquisition and signal transmission. Figure 9 shows the result of the adaptive filter. Compared with the sampled signal in Figure 6, most of the noise is eliminated, but some noise and the irregularly shaped pulse signal still exist, which would make mistakes in data decoding.

Pulse signal identification based on adaptive generalized cross-correlation algorithm
For the irregularly shaped pulse signal with noises, a new adaptive generalized cross-correlation algorithm (AGCC) is proposed in this paper, which is applied to reduce the amount of noise the signal during the course of signal transmission to surface. Removing the DC component of the signal is important before using the crosscorrelation algorithm. The algorithm determines the time intervals between the resulting cross-correlation peaks and decodes the intervals into an instruction.
The cross-correlation function describes the similarity between an original signal and a reference signal in the time domain (Stock et al., 2014). The reference signal is selected such that the waveform of the reference signal matches fairly closely to the waveform of the original signal to be detected. Compared with the original signal, the pulse shape of the cross-correlation function is more regularly.
In this paper, the original signal is pulses obtained by adaptive filtering while the reference signal is a single pulse which is the average of synchronous signals (four pulses). After averaging, the high-correlated pulse signal is enhanced while low-correlated noise signal is restrained. Regarded as the expected pulse signal, the reference signal is calculated by the Equation (2): where s(t) is the expected pulse signal, n(t) is the noise signal, and m(t) is the signal after averaging. The cross-correlation function and the cross-power spectral density function form a pair of Fourier Transforms. The cross-power spectral density function shows the correlation of signals in frequency domain and the frequency distribution of the cross-correlation function.
Based on standard cross-correlation (CC), generalized cross-correlation adds a weighted function to the CC Spectrum enhancement based on the reference signal Figure 10. The structure of the AGCC algorithm. Figure 11. The comparison of conditions with AGCC, CC and without cross-correlation process.
cross-power spectral density function (Jin et al., 2013), which reduces the effect of noises and interferences in frequency domain. Figure 10 shows the structure of the adaptive generalized cross-correlation algorithm. After obtaining the cross-power spectral density function by Fast Fourier Transform (FFT), a weighting algorithm in frequency domain is implemented in this function. Transformed by Inverse Fast Fourier Transform (IFFT), the generalized cross-correlation function is used to identify pulse. The generalized cross-correlation function is calculated by the Equation (3): where R 12 (τ ) is the generalized cross-correlation function, G 12 (ω) is the cross-power spectral density function from two signals, and H(ω) is the weighted function.
The key of AGCC is to find out the weighted function H(ω). At present, there are few weighted functions such as Roth, Scot and Phat (Yang, 2013;Zhang & Zhang, 2017, October). However, the purpose of these weighted functions is spectrum whitening in the situation of two signals with varied noise. In this paper, the difference is that one signal contains noises when the other is the expected pulse signal without noise. So, a new weighted function is determined as shown in the equation (4): where G 22 (ω) is the auto-power spectral density function of the reference signal. As the reference signal is a single pulse, its autopower spectrum is continuous. After weighting, the crosspower spectral density function has more components of the expected signal in frequency domain. The effect of this new weighting function is similar to the 'Matthew effect', where the frequency amplitude of the expected signal has an influence on the cross-correlation function in the frequency domain. The characteristics of different weighting functions are shown in Table 1.
For comparison, a normalization approach is necessary. Figure 11 shows the comparison of conditions with AGCC, CC and without cross-correlation process. It is obvious that pulses become more regular after using CC or AGCC. Some disturbing pulses are not be eliminated by CC, but AGCC reduces the effect of disturbing pulses. The signal is more easily identified with AGCC. The time differences corresponding to a data sequence are '6, 5, 8 s' in this figure, which are corresponds to the data '1, 0, 3' on the basis of decoding rules.

Field test
Pulse signal processing and identification algorithms in this paper had been used in Shengli Oilfield. Figure 12 shows the field test results. According to the final signal and encoding rules, the decoded words were 'SSSS 121034' which meant the temperature of the water injection layer 1 was 103.4°C. According to the results, we find out these algorithms are effective for the process of pulses identifying and data decoding in the pressure pulse communication system.

Summary
In the area of water injection, pulse telemetry is critical for information transmission, in which pulse signal processing and identification algorithms are of vital importance. In this paper, the characteristics of the pulse signal and noises have been analysed, respectively. In the complex environment with unknown noises, an adaptive filter algorithm has been adopted in pulse signal processing to reduce the impact of noises. Then a new adaptive generalized cross-correlation algorithm has been proposed to extract the pulse by using a new weighted function, which has restrained interferences and noises in the frequency domain. Finally, the results of field test have indicated that these algorithms have had a high recognition performance and have met the requirements of engineering application.