17.02.2014 Views

Amplitude and Frequency/Phase Modulation - Zurich Instruments

Amplitude and Frequency/Phase Modulation - Zurich Instruments

Amplitude and Frequency/Phase Modulation - Zurich Instruments

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Amplitude</strong> <strong>and</strong> <strong>Frequency</strong>/<strong>Phase</strong><br />

<strong>Modulation</strong><br />

I always had difficulties in underst<strong>and</strong>ing frequency modulation (FM) <strong>and</strong> its frequency spectrum.<br />

Even for the pure tone modulation, the FM spectrum consists of an infinite number of sideb<strong>and</strong>s<br />

whose signs change from one sideb<strong>and</strong> to the next one <strong>and</strong> whose amplitudes are given by the horrible<br />

Bessel functions. . .<br />

I work for <strong>Zurich</strong> <strong>Instruments</strong>, a Swiss maker of lock-in amplifiers <strong>and</strong> it has become a professional<br />

inclination to always think in terms of demodulation. The pictorial representation of AM/FM that I<br />

like comes with a (pictorial) digression on lock-in demodulation. Reader not interested in demodulation<br />

should read only Sect. 1.1.3 <strong>and</strong> Sect. 1.2 1<br />

1.1 Lock-in Demodulation as a Change to a Rotating Frame<br />

of Reference<br />

A lock-in amplifier can find the amplitude A S <strong>and</strong> phase ϕ S of an input signal of the type<br />

V S (t) = A S cos(ω S t + ϕ S ). (1.1)<br />

by a process called demodulation. The existing literature explains demodulation with the multiplication<br />

of the input signal by sine <strong>and</strong> cosine of the reference phase, also referred to as the in-phase <strong>and</strong><br />

quadrature of the reference: this reflects the low level implementation of the scheme (it is a real<br />

multiplication) but I could never really underst<strong>and</strong> it.<br />

I prefer more a different explanation using complex numbers: first I will present the math, then an<br />

equivalent pictorial representation.<br />

1.1.1 Demodulation of the Signal: a Mathematical Approach<br />

The signal of eq. (1.1) can also be written in the complex plane as the sum of two vectors (phasors),<br />

each one of length A S<br />

2<br />

rotating at the same speed ω S , in opposite directions:<br />

V S (t) = A S<br />

2<br />

[<br />

e j(ω St+ϕ S ) + e −j(ω St+ϕ S ) ] .<br />

Multiplying by 2e −jω St stops the counter-clockwise rotating phasors [described by e j(ω St+ϕ S ) ] <strong>and</strong><br />

makes the clockwise one precesses at −2ω S :<br />

V S (t)2e −jω St = A S e jϕ S<br />

+ A S e −j[2ω St+ϕ S ] .<br />

Let us assume we can get rid of the fast rotating phasor by averaging/filtering, indicated by the symbol<br />

〈 〉: the averaged signal becomes<br />

z(t) ≡ 〈 V S (t)2e −jω St 〉 = A S e jϕ S<br />

(1.2)<br />

1 Many thanks to Nikola Bucalovic for useful discussions <strong>and</strong> to Andrin Doll for the final revision of this note.<br />

1


This is the demodulated signal.<br />

To make the connection with the existing literature, where the real (or X or in-phase) <strong>and</strong> the<br />

imaginary (or Y or quadrature) components of the signal are shown, one notes that e −jω St ≡ cos(ω S t)−<br />

j sin(ω S t), from which z ≡ X + jY where<br />

X = 〈 Re { V S (t)2e −jω St }〉 = 〈2V S (t) cos(ω S t)〉 = A S cos ϕ S<br />

Y = 〈 Im { V S (t)2e −jω St }〉 = 〈−2V S (t) sin(ω S t)〉 = −A S sin ϕ S .<br />

This is equivalent to multipying the input signal by cos <strong>and</strong> − sin of the reference signal.<br />

Demodulation consists in two steps just enounced:<br />

• multiplication (or mixing) of the input signal by e −jω St <strong>and</strong><br />

• filtering of the mixed signal: the filters should remove at least the 2ω component. (The type <strong>and</strong><br />

implementation of the filters is not the subject of this note.)<br />

1.1.2 Demodulation of the Signal: a Pictorial Representation<br />

I restate the demodulation process using a pictorial representation. Let us start with the input signal<br />

eq. (1.1) <strong>and</strong> represent it as the sum of two phasors with equal length A S<br />

2<br />

as before. Simple trigonometry<br />

is sufficient to show that the projection on the x–axis is 2 · AS<br />

2<br />

cos(ω S t) <strong>and</strong> has a null projection on<br />

the y–axis, see Figure 1.1a) <strong>and</strong> b).<br />

a)<br />

b) c)<br />

f S<br />

Y<br />

X<br />

Figure 1.1: a) Decomposition of the input signal as two counter-rotating phasors of length A S<br />

2<br />

. b) The<br />

sum of the two phasors is always along the x–axis. c) In the rotating frame, one phasor is at rest <strong>and</strong><br />

the other rotating at 2ω S .<br />

Imagine now to st<strong>and</strong> at the origin <strong>and</strong> to rotate counter-clockwise at the same speed ω S : you will<br />

see one phasor at rest, at an angle ϕ S with your forward direction (ϕ S is the angle at time t = 0 of<br />

the input signal), while the other is moving at 2ω S in the clockwise direction 2 (the angle between you<br />

<strong>and</strong> the second phasor is time-dependent, −2ω S t + ϕ S , Figure 1.1c).<br />

After averaging the total signal, only the steady phasor remains: elementary trigonometry is sufficient<br />

to see that the steady phasor has projection on the x–axis equal to A S<br />

2<br />

cos ϕ S <strong>and</strong> on the y–axis<br />

equal to A S<br />

2<br />

sin ϕ S .<br />

The factor 1 2<br />

comes from the decomposition of the real signal eq. (1.1) into the two vectors each<br />

of amplitude A S<br />

2<br />

, of which one averages out in the rotating frame. Therefore, since one phasor only<br />

is detected, to account for the missing power, it is customary in lock-in detection to display the<br />

components multiplied by 2 or √ 2 for peak or RMS amplitude respectively.<br />

2 This is the rotating frame approximation that NMR people like so much, applied to lock-ins!<br />

2


1.1.3 The Explanation (<strong>and</strong> Some Easy Math)<br />

The rotating frame picture is equivalent to the mathematical approach: here is why.<br />

Complex exponents are a very practical way of dealing with rotations in a 2D plane: given a<br />

vector (phasor) Re jθ with length R <strong>and</strong> angle θ with the x–axis, the phasor rotated by an angle φ is<br />

Re j(θ+φ) = Re jθ · e jφ , that is the product of the original phasor with the ”rotation operator by an<br />

angle φ”. The angle φ can also be a time-dependent angle, for instance φ(t) = ω S t, in which case the<br />

phasor rotates at a constant speed.<br />

I can equally well think of e jφ as a rotation of the observer: if the phasor in the previous example<br />

appears at an angle θ + φ, this means that the observer has rotated by an angle −φ, in the clockwise<br />

direction. So a rotation of the observer reference frame by an angle φ in the counter-clockwise direction<br />

multiplies by e −jφ , with the minus sign.<br />

The change to a rotating frame of reference I mentioned above, with an angle φ(t) = ω R t, corresponds<br />

to multiplying the input signal (each one of the two phasors) by e −jω Rt . But e −jω Rt is just<br />

cos ω R t − j sin ω R t! This is why the cos <strong>and</strong> − sin multiplications to obtain the X (in-phase, the real<br />

part of the product) <strong>and</strong> the Y (the quadrature, the imaginary part) components.<br />

As a side note: The Fourier transformation is a demodulation with infinitely long averaging<br />

F (ω R ) = 1<br />

2π<br />

∫ +∞<br />

−∞<br />

f(t)e −jω Rt dt.<br />

Think of f(t) as the sum of all components at different frequencies ω. 3 The recipe for the Fourier<br />

transform has two steps: first, rotate the reference frame at a speed ω R , f(t)e −jωRt . Now, only the<br />

ω R component is a steady phasor in this new rotating frame of reference. Second, take an infinitely<br />

long average, the time integration from −∞ to +∞ so that all the moving phasors having frequencies<br />

different from ω R average out.<br />

1.1.4 Demodulation at a Different <strong>Frequency</strong><br />

The pictorial representation is as correct as the mathematical approach <strong>and</strong> by no means an approximation<br />

of it. We will now only make use of the pictorial representation <strong>and</strong> predict what happens<br />

to the demodulated signal when the reference/demodulation frequency <strong>and</strong> the signal frequency differ,<br />

ω R ≠ ω S ; we then compare it to the math approach <strong>and</strong> show it is the same.<br />

Let us assume that the signal is advancing faster than the reference phase, ω S > ω R : in the rotating<br />

frame, the signal slow moving phasor will appear moving counter-clockwise at a speed ω S − ω R . As<br />

before, the fast one rotating at −(ω S + ω R ) is averaged out.<br />

Using now the mathematical approach, we want to check the validity of the result: the multiplication<br />

by the reference signal e −jωRt <strong>and</strong> the subsequent averaging of the 2ω component gives<br />

〈<br />

VS (t)2e −jω Rt 〉 〈 A<br />

=<br />

2<br />

[<br />

e j(ω St+ϕ) + e −j(ω St+ϕ S ) ] 2e −jω Rt<br />

〉<br />

= Ae j[(ω S−ω R )t+ϕ S ]<br />

a ccw rotating phasor at frequency ω S − ω R : this is exactly the result we obtained in the rotating<br />

frame.<br />

1.2 Signal <strong>Modulation</strong><br />

With the previous pictorial representation in mind, we can proceed to analyze signal modulation. Any<br />

generic input signal can be written as<br />

with a constant carrier frequency ω c <strong>and</strong> adequate A(t) <strong>and</strong> ϕ(t).<br />

V S (t) = A(t) cos[ω c t + ϕ(t)] (1.3)<br />

3 Never mind that I explain the Fourier transform in terms of the Fourier transform: all geeks like recursion.<br />

3


amplitude<br />

1.5<br />

1.0<br />

0.5<br />

0.0<br />

0.5<br />

1.0<br />

a<br />

1.5<br />

0 20 40 60 80 100<br />

time<br />

b<br />

20 40 60 80 100<br />

time<br />

Figure 1.2: a) <strong>Amplitude</strong> modulated <strong>and</strong> b) frequency modulated signal: note that in one case the<br />

amplitude changes with time, in the second the spacing between successive zero crossings.<br />

To underst<strong>and</strong> amplitude <strong>and</strong> phase modulation, we change to the rotating frame of reference with<br />

ω R = ω c<br />

[<br />

V S (t)2e −jωct = A(t) e j[ωct+ϕ(t)] + e −j[ωct+ϕ(t)]] e −jωct = A(t)e jϕ(t) + A(t)e −j[2ωct+ϕ(t)]<br />

where the 2 is for the peak amplitude.<br />

Let us neglect the 2ω c term (the filters are selected such that A(t) <strong>and</strong> ϕ(t) are not affected) <strong>and</strong><br />

consider the first term only:<br />

z(t) = A(t)e jϕ(t) (1.4)<br />

For the reader who has skipped the introduction about demodulation:<br />

eq. (1.3) describes a generic modulated signal <strong>and</strong> it can be written as<br />

V S (t) = 1 2<br />

[<br />

A(t)e jϕ(t) + A(t)e −j[2ωct+ϕ(t)]] e jωct<br />

We consider only the first term, z(t) = A(t)e jϕ(t) discarding for simplicity the<br />

factor 1 2 as done in eq. (1.4): ejωct accounts for what I refer to a rotation of the<br />

observer, as explained in Sect. 1.1.3.<br />

Eq. (1.4) describes in general neither an amplitude nor a frequency modulated signal since both<br />

vary, see Fig. 1.3a. In an amplitude modulated signal, only the phasor length A(t) changes (the blue<br />

line in the figure) but not its phase: in other words, all the changes are along the phasor direction<br />

<strong>and</strong> not perpendicular to it. <strong>Phase</strong> modulation on the other h<strong>and</strong> would instead move the phasor on<br />

a circle (red line), with no changes to its radius.<br />

1.2.1 <strong>Amplitude</strong> <strong>Modulation</strong><br />

<strong>Amplitude</strong> <strong>and</strong> (narrow b<strong>and</strong>) frequency modulations have equal Fourier power spectral densities: in<br />

fact their Fourier transforms differ by the sign of the sideb<strong>and</strong>s but this disappears when squaring to<br />

obtain the power density. One can easily explain the sign by using eq. (1.4) <strong>and</strong> the rotating frame.<br />

A general AM signal has time independent phase offset ϕ c . Let us assume for simplicity ϕ c = 0:<br />

V AM (t) = A(t) cos(ω c t)<br />

rotating frame<br />

−→ d AM (t) = A AM (t) (1.5)<br />

This means that in the rotating frame, the only time dependent term is the the phasor length.<br />

4


pure<br />

a) PM b)<br />

d(t)<br />

pure<br />

AM<br />

Figure 1.3: a) The phasor of a generically modulated signal can sweep the grey area. In pure amplitude<br />

modulation, only the length A(t) is time dependent, in pure phase modulation, the phase only changes.<br />

The amplitude <strong>and</strong> phase modulations are not restricted to be a fraction of the radius <strong>and</strong> π respectively.<br />

b) The decomposition of the sideb<strong>and</strong>s of an AM signal: the sideb<strong>and</strong>s must add up to have only a<br />

horizontal contribution: at t = 0 they must have the same absolute value of the phase.<br />

To illustrate the spectral properties of this signal, we consider the simplest amplitude modulation,<br />

a pure tone modulation<br />

A AM (t) = 1 + h cos(ω m t) = 1 + h 2<br />

[<br />

e<br />

+jω mt + e −jωmt]<br />

with average amplitude 1 <strong>and</strong> amplitude modulation h.<br />

With reference to Fig. 1.3b, the modulation of the amplitude, h cos(ω m t), originates from the two<br />

blue phasors of length h/2 counter-rotating with frequency f m : their sum, the thick blue arrow, is<br />

always along the x–axis. (The support carrier of length 1 is not shown in the Figure.) At t = 0 they<br />

are both pointing outwards: this will be different in the case of frequency modulation, see Sect. 1.2.2.<br />

These two phasors are the two sideb<strong>and</strong>s of the AM spectrum: the phasor rotating ccw is the upper<br />

sideb<strong>and</strong> at f c + f m <strong>and</strong> the cw is the lower sideb<strong>and</strong> at f c − f m 4 .<br />

1.2.2 <strong>Frequency</strong> <strong>Modulation</strong><br />

A generic FM signal has the form<br />

V FM (t) = A cos[ω c t + ϕ(t)]<br />

with constant A.<br />

Let us now consider the simplest case of frequency modulation<br />

rotating frame<br />

−→ d FM (t) = Ae jϕFM(t) (1.6)<br />

ϕ FM (t) = h sin(ω m t) (1.7)<br />

h is also called the modulation index. The instantaneous frequency of the signal is the time derivative<br />

of the instantaneous phase ω c t + ϕ FM (t):<br />

f(t) = f c + 1 dϕ FM (t)<br />

= f c + f ∆ cos(ω m t)<br />

2π dt<br />

f ∆ ≡ hf m is the peak frequency, the maximum frequency deviation.<br />

4 For reference,<br />

[1 + h cos(ω mt + ϕ m)] cos(ω ct + ϕ c) = cos(ω ct + ϕ c) + h 2<br />

with ω ± = ω c ± ω m <strong>and</strong> ϕ ± = ϕ c ± ϕ m.<br />

[<br />

cos(ω − t + ϕ − ) + cos(ω + t + ϕ +]<br />

5


Pictorial representation of sideb<strong>and</strong>s Electrical engineers know that the FM signal with ϕ(t)<br />

given by eq. (1.7) has a frequency spectrum consisting of an infinite number of sideb<strong>and</strong>s at ω c ± nω m<br />

<strong>and</strong> the amplitude of the n-th sideb<strong>and</strong> is given by the n-th Bessel function. Is there an intuitive<br />

picture of this?<br />

The demodulated signal d FM (t) = Ae jϕFM(t) has constant amplitude, so it describes a phasor<br />

that moves on a circle of radius A: let us take A = 1. For a small phase swing, Fig. 1.4a, one<br />

can neglect the curvature of the circle <strong>and</strong> two terms only are sufficient to approximate d FM (t): an<br />

horizontal time independent phasor b 0 (h) = 1 <strong>and</strong> a vertical phasor that has the same time periodicity<br />

as ϕ FM (t) ∝ sin(ω m t).<br />

We now need to find its amplitude b 1 (h). Let τ ≡ ω m t: for small ϕ FM (τ), one has d FM (τ) =<br />

e jϕFM(τ) ≈ 1 + jϕ FM (τ) <strong>and</strong> the imaginary (i.e. vertical) component is approximated by<br />

b 1 (h) sin τ ≈ Im[d FM (t)] ≈ ϕ FM (τ) ≡ h sin τ.<br />

This small angle limit, usually taken for h < 0.2, is called narrow b<strong>and</strong> FM by the engineers.<br />

a) b)<br />

c) d)<br />

Figure 1.4: The FM signal <strong>and</strong> its decomposition in terms of the Bessel functions.<br />

With large angle<br />

√<br />

modulations (large h), this approximation fails, because the length of the approximated<br />

phasor b 2 0 (h) + b2 1 (h) sin2 τ ≈ 1 + h2<br />

2 sin2 τ = 1 + h2<br />

4<br />

[1 − cos(2τ)] changes twice per cycle of<br />

the phasor, see Fig. 1.4b. One could compensate for this overshoot with the additional term b 2 (h) in<br />

the horizontal direction, Fig. 1.4c. Since the b 2 (h) correction has to take place twice per cycle, it must<br />

have a cos(2τ) dependence. We conclude that b 2 (h) cos(2τ) is the second set of sideb<strong>and</strong>s at ±2ω m .<br />

However at τ = 0, π, b 2 (h) has a contribution towards positive x, <strong>and</strong> b 0 (h) = 1 − b 2 (h) must be<br />

smaller than 1 to make the unit phasor, see Fig. 1.4d. Therefore the conditions on b 0 (h) <strong>and</strong> b 2 (h) are<br />

{<br />

b 0 (h) + b 2 (h) = 1 when τ = 0<br />

b 0 (h) + b 2 (h) cos(2τ) = cos ϕ FM (τ) −→<br />

b 0 (h) − b 2 (h) = cos(h) when τ = π<br />

6


a) b)<br />

Figure 1.5: The sideb<strong>and</strong> phasors for a) b 1 (<strong>and</strong> the odd terms) <strong>and</strong> b) b 2 (<strong>and</strong> the even terms). The<br />

blue arrow is the direction of the modulation.<br />

At this point, we still do not know we are dealing with the Bessel functions J n (h), but we can note<br />

that also J 0 (h) has one maximum (its global) at h = 0.<br />

One could continue with the third order expansion, now in the vertical direction, which is odd in<br />

time, so its time dependence is b 3 (h) sin(3τ) <strong>and</strong> imagine that in general, the phasors must satisfy the<br />

following relations<br />

sin ϕ FM (τ) = ∑ n≥0<br />

b 2n+1 (h) sin[(2n + 1)τ] cos ϕ FM (τ) = ∑ n≥0<br />

b 2n (h) cos[2nτ] (1.8)<br />

Before showing that the b n (h) are related to the J n (h) Bessel function, one should note that the first<br />

vertical phasor is the sum of two counter-rotating complex phasors (Figure 1.5a), which at τ = 0 point<br />

one in the positive <strong>and</strong> the other in the negative x–axis direction. This also holds for all odd phasors.<br />

On the other h<strong>and</strong>, for the even phasors, which are horizontal, they are the sum of two phasors<br />

(Figure 1.5b) which at τ = 0 are pointing in the same direction, +x. So: odd phasors have a π phase<br />

difference between the upper <strong>and</strong> lower sideb<strong>and</strong>, even phasors are in phase. This distinguishes the<br />

AM sideb<strong>and</strong>s from the FM (first set of) sideb<strong>and</strong>s. Eq. (1.8) describes all sideb<strong>and</strong>s at ω c ± nω m with<br />

n ∈ N.<br />

The Relation with the Bessel Coefficients The b n (h) are in fact proportional to the Bessel<br />

coefficients. To show this, let us rewrite eq. (1.8):<br />

sin ϕ FM (τ) = ∑ b 2n+1 (h) sin[(2n + 1)τ] = ∑ b 2n+1 (h)<br />

[e ]<br />

(2n+1)τ − e −(2n+1)τ<br />

2j<br />

n≥0<br />

n≥0<br />

cos ϕ FM (τ) = ∑ b 2n (h) cos[2nτ] = ∑ b 2n (h) [<br />

e 2nτ + e −2nτ ]<br />

2<br />

n≥0<br />

n≥0<br />

Defining J n (h) ≡ (−1) n b n(h)<br />

2<br />

to take care of the negative coefficient in the sine, <strong>and</strong> J 0 (h) ≡ b 0 (h),<br />

one can write<br />

cos ϕ FM (τ) + j sin ϕ FM (τ) ≡ e jh sin(τ) =<br />

<strong>and</strong> multiplying both sides by e −jkτ <strong>and</strong> integrating gives<br />

1<br />

2π<br />

∫ +π<br />

−π<br />

e −j(kτ−h sin τ) dτ = 1<br />

2π<br />

+∞∑<br />

n=−∞<br />

7<br />

J n (h)<br />

∫ +π<br />

−π<br />

+∞∑<br />

n=−∞<br />

J n (h)e jnτ (1.9)<br />

e j(n−k)τ dτ = J k (h) (1.10)


which is the integral generating function of the Bessel coefficients 5 .<br />

amplitude<br />

1.0<br />

0.8<br />

0.6<br />

0.4<br />

0.2<br />

0.0<br />

0.2<br />

J 0<br />

J 1<br />

J 2<br />

J 3<br />

J 4<br />

0.4<br />

0 1 2 3 4 5 6<br />

h<br />

Figure 1.6: The first five Bessel functions. Note the zero crossing of J 0 (h) at h = 2.4048.<br />

Sideb<strong>and</strong>s, the Hardcore Math While I am at it, I will also show the usual mathematical treatment:<br />

this requires some higher math.<br />

To get the frequency spectrum, one starts from the Jacobi–Anger expansion 6 :<br />

e jx sin φ =<br />

+∞∑<br />

n=−∞<br />

J n (x)e jnφ<br />

J −n (x) = (−1) n J n (x).<br />

We are going to consider a slightly more complicated phase modulation, ϕ(t) = h sin(ω m t + ϕ m ) + ϕ c :<br />

the FM signal is<br />

V S (t) = cos[ω c t + h sin(ω m t + ϕ m ) + ϕ c ].<br />

Writing<br />

e j(ωct+ϕc) e jh sin(ωmt+ϕm) = e j(ωct+ϕc)<br />

<strong>and</strong> taking the real part gives<br />

s(t) =<br />

+∞∑<br />

n=−∞<br />

+∞ ∑<br />

n=−∞<br />

J n (h)e jn(ωmt+ϕm) =<br />

+∞∑<br />

n=−∞<br />

J n (h) cos[(ω c + nω m )t + ϕ c + nϕ m ].<br />

J n (h)e j[(ωc+nωm)t+ϕc+nϕm]<br />

(1.11)<br />

5 From http://en.wikipedia.org/wiki/Bessel function. This should also solve the Bessel equation<br />

6 From the Laurent series<br />

h 2 J ′′<br />

k (h) + hJ ′ k (h) + (h2 − k 2 )J k (h) = 0?<br />

e (x/2)(t−1/t) =<br />

+∞ ∑<br />

n=−∞<br />

J n(x)t n<br />

with the substitution t = e iφ for sin or t = ie iφ for cos. From https://ccrma.stanford.edu/∼jos/mdft/FM Spectra.html.<br />

See also http://mathworld.wolfram.com/BesselFunctionoftheFirstKind.html<br />

8

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!