[s] algorithms for estimating instantaneous frequency

Upload: christian-f-vega

Post on 13-Apr-2018

214 views

Category:

Documents


0 download

TRANSCRIPT

  • 7/26/2019 [S] Algorithms for Estimating Instantaneous Frequency

    1/5

    Signal Processing 84 (2004) 14231427

    www.elsevier.com/locate/sigpro

    Algorithms for estimating instantaneous frequency

    Jaideva C. Goswami, Albert E. Hoefel

    Schlumberger Technology Corporation, 110 Schlumberger Drive, Sugar Land, TX 77478, USA

    Received 28 March 2003; received in revised form 22 April 2004

    Abstract

    Three algorithms to estimate instantaneous frequency of a frequency-modulated signal is discussed. These algorithms are

    based on Hilbert transform, Haar wavelet, and generalized pencil of function (GPOF) methods. While GPOF-based frequency

    detection method appears to be least sensitive to noise, wavelet-based method is easiest to implement. The latter method is

    also computationally more ecient and can be implemented in real-time. Results for both synthetic and experimental data

    are shown.

    ?2004 Elsevier B.V. All rights reserved.

    Keywords: Frequency modulation; Phase-shift keying; Frequency-shift keying; Wavelet; Hilbert transform; Matrix pencil

    1. Introduction

    The problem of estimating instantaneous frequency

    of a received signal is very important in many com-

    munication areas. In this paper, we discuss this prob-

    lem in the context of wireless data acquisition in

    oileld industry. In some oil-eld exploration

    applications, a small amount of measured data are

    transferred between a measurement sensor and a

    host unit where, both the sensor and host units are

    located at a few kilometers underground. Binaryfrequency-shift keying (BFSK) scheme is often used

    for data communication. The major problem for such

    data communication comes because of highly lim-

    ited availability of space and power. Demodulation

    algorithms should be easily implementable in hard-

    ware and rmware. With this application in mind,

    Corresponding author.

    E-mail addresses: [email protected] (J.C. Goswami),

    [email protected] (A.E. Hoefel).

    we have studied three dierent methods for estimating

    instantaneous frequencies. These are based on Hilbert

    transform [6], Haar wavelet [1], and generalized pen-

    cil of function (GPOF) methods [2,3,5]. In this section

    we briey review frequency modulation scheme. Sec-

    tions24describe algorithms for estimating instanta-

    neous frequency by Hilbert transform, wavelet trans-

    form, and GPOF methods, respectively. And nally,

    in Section5, we discuss numerical and experimental

    results.

    In frequency modulation (FM), the instantaneous

    frequency !i of the carrier varies linearly with the

    modulating signalm(t)[4]. Thus!i can be written as

    !i=!c+kfm(t); (1)

    where!c is the carrier frequency and kfis a constant.

    The phase, (t), is given by

    (t) =

    t

    [!c+kfm()] d (2)

    =!ct+kf

    t

    m() d: (3)

    0165-1684/$ - see front matter? 2004 Elsevier B.V. All rights reserved.doi:10.1016/j.sigpro.2004.05.016

    mailto:[email protected]:[email protected]:[email protected]:[email protected]
  • 7/26/2019 [S] Algorithms for Estimating Instantaneous Frequency

    2/5

    1424 J.C. Goswami, A.E. Hoefel/ Signal Processing 84 (2004) 1423 1427

    ModulatingSignal

    PhaseModulator

    FM

    Signal

    ModulatingSignal Frequency

    Modulator

    PM

    SignalDifferentiator

    Integrator

    Fig. 1. Relationship between phase and frequency modulation.

    An FM signal, therefore, can be represented as

    s(t) =A cos!ct+kf t

    m() d : (4)It is worth mentioning here that in a phase-modulated

    (PM) signal, instead of frequency, the phase (t)

    varies linearly with the modulating signal, namely

    (t) =!ct+kpm(t) (5)

    and instantaneous frequency !i varies linearly with

    the derivative of the modulating signal

    !i=d

    dt =!c+kpm(t): (6)

    It is, therefore, clear that PM and FM are intimatelyrelated. One can be obtained from the other as shown

    in Fig.1.The commonly used digital modulation tech-

    niques, BPSK (binary phase-shift keying) and BFSK

    are special cases of PM and FM, respectively, when

    the modulating signal m(t) takes binary values. Al-

    though all the examples discussed in this paper pertain

    to FM, the algorithm, with trivial modication, can be

    used for PM as well.

    2. Hilbert transform algorithm

    The Hilbert transform of a signal s(t) produces a

    signalsh(t) that is orthogonal tos(t). The angle of the

    complex signal s(t) + jsh(t) then gives the instanta-

    neous phase, and its derivative, the instantaneous fre-

    quency of the signal.

    Let s(!) represent the Fourier transform of a

    real-valued signals(t). A typical magnitude spectrum

    ofs(t) is shown in Fig. 2.We can construct a signal

    s+(t) that contains only positive frequencies of s(t)

    cc

    |s ()|^

    Fig. 2. A typical magnitude spectrum of a signal.

    by multiplying its spectrum s(!) with a unit step func-

    tion as

    s+

    (!) = s(!)u(!); (7)

    where u(!) is the unit step function, dened in the

    usual way as

    u(!) =

    1 ! 0

    0 otherwise:(8)

    From (7)we have

    2 s+(!) = s(!)[1 + sgn(!)]

    = s(!) +j[ j sgn(!) s(!)]

    sh(!); (9)

    where sgn(!) is the signum function dened as

    sgn(!) =

    1 ! 0

    1 ! 0:(10)

    In (9),sh(t) is the Hilbert transform ofs(t), dened as

    sh(t) =F1{j sgn(!) s(!)}

    =1

    s()

    t d; (11)

    whereF1

    represents inverse Fourier transform. It iseasy to verify thats(t); sh(t) = 0 sh(t) s(t).Once we have the orthogonal signal sh(t) of s(t),

    the instantaneous phase and frequency ofs(t) can be

    obtained by [6]

    (t) = arctan

    sh(t)

    s(t)

    (12)

    and

    !i(t) =d

    dt =!c+kfm(t): (13)

  • 7/26/2019 [S] Algorithms for Estimating Instantaneous Frequency

    3/5

    J.C. Goswami, A.E. Hoefel / Signal Processing 84 (2004) 1423 1427 1425

    0 10.5

    0 1

    (b)(a)

    Fig. 3. Haar (a) scaling function, and (b) wavelet.

    3. Wavelet algorithm

    The principle behind wavelet-based instantaneousfrequency estimation is the same as Hilbert transform

    method, namely nding orthogonal signal of a given

    frequency-modulated signal. From wavelet theory [1],

    we can decompose a given function s(t) into orthog-

    onal signals f(t) andg(t) such that

    f(t) =

    k

    ck(at k); (14)

    g(t) =

    k

    dk(at k); (15)

    where parameter a depends on the sampling rate ofs(t). The bases (t) and(t) are called scaling func-

    tion and wavelet, respectively. These two functions

    are orthogonal to each other, i.e.(at); (at )=0; Z:= {: : : ;1; 0; 1; : : :}.

    We will use the simplest scaling function and

    wavelet due to Haar, as shown in Fig. 3.For this case

    the coecients{ck}and{dk}witha = 2 are given as

    2ck= s(k) +s(k+ 1); (16)

    2dk= s(k) s(k+ 1): (17)

    As with Hilbert transform case, once we have orthog-

    onal signals, we can obtain the instantaneous phase

    k :=(tk); tk= kt

    k= Aarctan

    dk

    ck

    ; (18)

    whereA is a constant depending upon the sampling

    rate. Finite dierence of{k}then gives the instanta-neous frequency.

    4. GPOF algorithm

    Given a set of discrete data {fi : i= 0; 1; : : : ; N }

    of a complex-valued functionf(t), generalized pencilof function method nds a set of complex coecients

    {ck; k :k= 1; 2; : : : ; M }such that

    fi :=f(ti) =

    Mk=1

    ckexp(kti); M N; (19)

    whereti = itand tis the discretization step. The

    GPOF method has better numerical performance than

    the conventional Pronys method [7]which involves

    solving an ill-conditioned matrix equation, and nd-

    ing roots of a polynomial. The GPOF method also

    has better noise sensitivity [3]. A detailed discussionon the subject may be found in [3]. The algorithm is

    briey described below.

    Consider vectors of discrete data{fi},

    Fi := [fi fi+1 : : : fi+NL1]T; 06 i6L; (20)

    where T stands for transpose, and form matrices of

    size (NL) L,

    A1= [F0 F1 : : : FL1] (21)

    and

    A2= [F1 F2 : : : FL]: (22)

    Then, withzk:= exp(kt), it can be shown that{zk}are the generalized eigen values of matrix pencil A2 zA1. Once we have all the exponents, the coecients

    {ck}can be easily computed from (19)since in{ck},it is a linear equation.

    In the present problem of instantaneous frequency

    estimation, we choose a window size that covers at

    least one cycle of the highest carrier frequency and

    then extract two exponents. The imaginary parts of

    these exponents k give instantaneous frequency. Bysliding the window, we can compute the instantaneous

    frequency for the entire signal.

    5. Results and discussions

    As a rst step, we test and compare all three

    algorithms discussed in this paper by applying them

    to synthetic frequency-modulated data. The compari-

    son is based on relative signal reconstruction error, ,

  • 7/26/2019 [S] Algorithms for Estimating Instantaneous Frequency

    4/5

    1426 J.C. Goswami, A.E. Hoefel/ Signal Processing 84 (2004) 1423 1427

    Table 1

    Error () in frequency estimation by three algorithmsHilbert

    transform, Haar wavelet, and generalized pencil of function

    (GPOF)for dierence noise level (as a percentage of signal

    strength)

    Noise Error

    Hilbert transform Haar wavelet GPOF

    10 0.00004 0.00024 0.00004

    20 0.00019 0.00109 0.00005

    30 0.00042 0.00273 0.00010

    40 0.00076 0.00523 0.00016

    50 0.00123 0.00850 0.00022

    60 0.02897 0.02143 0.00030

    70 0.03840 0.03500 0.00042

    80 0.04707 0.06756 0.00062

    90 0.05133 0.10211 0.00099

    100 0.05656 0.11747 0.01252

    0 0.5 1 1.5 2 2.53

    2

    1

    0

    1

    2

    3

    Time (seconds)

    Frequency modulated signal

    Fig. 4. A BFSK signal with additive Gaussian noise

    (SNR = 3:0 dB).

    dened as

    =

    i |Si; n Si; 0|

    2i |Si; 0|

    2 ; (23)

    where summation is over all samples, andSi; n, andSi; 0representi th sample of reconstructed signal with and

    without noise in the modulated data, respectively. Ta-

    ble1,shows the results for error with dierent levels

    of additive Gaussian noise as a percentage of signal

    strength. To visually see the eect of noise on fre-

    quency demodulation, we have plotted the signal in

    0 0.5 1 1.5 2 2.50

    10

    20

    30

    40

    Frequency estimation ( Exact Computed)

    Time (seconds)

    Frequency(Hz)

    0 0.5 1 1.5 2 2.50

    10

    20

    30

    40

    Time (seconds)

    Frequency(Hz)

    0 0.5 1 1.5 2 2.50

    10

    20

    30

    40

    Time (seconds)

    Frequency(Hz)

    Hilbert transform

    Haar wavelet

    GPOF

    Fig. 5. Frequency demodulation of a BFSK signal shown in Fig.

    4 by using three algorithms based on Hilbert transform, Haar

    wavelet, and GPOF.

    0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 50.2

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    Time (milli-seconds)

    Frequency detection using Hilbert transform

    Experimental modulating dataComputed normalized frequency

    Fig. 6. Frequency demodulation of experimental BFSK data using

    Hilbert transform.

    Fig.4and the frequency demodulated signals in Fig.5

    for all three algorithms. Finally, we apply these algo-

    rithms to experimental data obtained by using a BFSK

  • 7/26/2019 [S] Algorithms for Estimating Instantaneous Frequency

    5/5

    J.C. Goswami, A.E. Hoefel / Signal Processing 84 (2004) 1423 1427 1427

    0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 50.2

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    Time (milli-seconds)

    Frequency detection using Haar wavelet

    Experimental modulating dataComputed normalized frequency

    Fig. 7. Frequency demodulation of experimental BFSK data using Haar wavelet.

    0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 50.2

    0

    0.2

    0.4

    0.6

    0.8

    1

    1.2

    Time (milli-seconds)

    Frequency detection using GPOF

    Experimental modulating dataComputed normalized frequency

    Fig. 8. Frequency demodulation of experimental BFSK data using

    GPOF.

    transmitter and a pick-up coil. The results are shown

    in Figs.68.For experimental data, all three methodsperform well because of low noise environment.

    The results indicate that GPOF-based method is

    least sensitive to noise. This is primarily due to the

    fact that in GPOF, the frequency is determined by

    a least squared algorithm which essentially mini-

    mizes the error. Wavelet-based method is the sim-

    plest to implement and fastest to compute. Further-

    more, wavelet-based method can be implemented

    for real-time application, since it requires signal infor-

    mation only in the vicinity of the current time loca-

    tion. In Hilbert transform method, on the other hand,

    we need the entire signal before estimating the in-

    stantaneous frequency because of the global nature of

    Fourier bases. The GPOF method can be implemented

    in real-time, however, matrix operations are dicult

    to be realized in hardware.

    References

    [1] J.C. Goswami, A.K. Chan, Fundamentals of Wavelets: Theory,

    Algorithms, and Applications, Wiley, New York, 1999.

    [2] J.C. Goswami, R. Mittra, On the solution of a class of

    large-body scattering problems via the extrapolation of FDTD

    solutions, J. Electromagn. Waves Appl. 12 (1998) 229244.

    [3] Y. Hua, T.K. Sarkar, Generalized pencil-of-function method

    for extracting poles of an EM system for its transient response,

    IEEE Trans. Antennas Propagat. 37 (1989) 229234.

    [4] B.P. Lathi, Modern Digital and Analog Communication

    Systems, Holt, Rinehart & Wilson, New York, 1983

    (Chapter 4).[5] A.J. Mackay, A. McCowen, An improved pencil-of-function

    method and comparisons with traditional methods of pole

    extraction, IEEE Trans. Antennas Propagat. 35 (1987)

    435441.

    [6] J.G. Proakis, Digital Communication, McGraw-Hill, New

    York, 1995, pp. 152157.

    [7] M.L. Van Blaricum, R. Mittra, A technique for extracting

    the poles and residues of a system directly from its transient

    response, IEEE Trans. Antennas Propagat. 23 (1975) 777781.