Understanding Phase Locked Loops (PLLs) with Phasors

In summary, Sami recommends the ancient Signetics PLL applications book, which does a good job of developing the equations.
  • #1
samski
60
0
Hi. So I thought I understood PLLs pretty well after I designed a couple over summer, but I've just been taught them at university and I'm now pretty stumped! The lecture notes use Phasors which just make things confusing. I wonder if anyone could explain the 2 initial setup equations used in my notes?

Here are the notes:
http://img835.imageshack.us/img835/5376/pllv.png

please note that my big confusion is because of the possible mixing of phasors and phases, so it would be awesome if you could try and be clear between the two.

Any help would be really appreciated,

Cheers,

Sam
 
Last edited by a moderator:
Engineering news on Phys.org
  • #2
i'd recommend the ancient Signetics PLL applications book, ca 1972

it's on the net as a pdf...

google on terms "signetics PLL applications", maybe add NE565

this public computer won't display any of the pages, i guess it's afraid of cookies or something

that book does a good job of developing the equations.

i don't see any ambiguity in your sketch - perhaps the author considered the terms interchangeable, or perhaps slightly mis-used one ?

Or - If V2 represents phase, VCO turns it back into a phasor, ie K0 includes requisite unit (inverse of Kp) ??

old jim
 
Last edited:
  • #3
I am no expert in PLL, I did studied a few books on PLL and never use phasor representation. Sometimes phasor like this is for representation of sine and cosine wave.

[tex] Re [e^{j(\omega t +\theta_0)}] = \cos(\omega t +\theta_0)\;\hbox { and }\; I am [e^{j(\omega t +\theta_0)}] = \sin(\omega t +\theta_0)[/tex]

Do you mean this? This is not phasor though.

For Phasor, let [itex] \vec v(z)\;[/itex] be a complex function:

[tex]\vec v(z)=Re[V_0e^{j(\omega t -kz+\theta_0)}]=Re[V_0 e^{j\omega t} e^{-j(kz-\theta_0)}]= Re[\tilde v(z) e^{j\omega t}]\;\hbox { where } \tilde v(z)=V_0e^{-j(kz-\theta_0)} \;\hbox { is defined as phasor.}[/tex]

Where you see the phasor has no time component. If you Q0 is phasor

[tex] \vec Q_0= Re[\tilde Q_0 e^{j\omega t}]\;\Rightarrow\; \frac {d\vec Q_0}{ d t}= \frac{d\;Re[\tilde Q_0 e^{j\omega t}]}{dt} =Re[j\omega \tilde Q_0 e^{j\omega t}]\Rightarrow \; \frac {d \tilde Q_0}{dt}= j\omega \tilde Q_0[/tex]

Hope this help.
 
Last edited:
  • #4
thanks for the replies guy. turns out (i think) that the phasors are the actual phases of the input and output signals. the omega is the wobble in the input phase, not the input frequency... equation 2 still doesn't quite make sense though :(
 
  • #5
samski said:
thanks for the replies guy. turns out (i think) that the phasors are the actual phases of the input and output signals. the omega is the wobble in the input phase, not the input frequency... equation 2 still doesn't quite make sense though :(

That's what I thought, so the first part of the equation is what you want, just a fancy way of saying sine and cosine. Never seen people using phasor in PLL. BUT what you wrote in (2) is true phasor differentiation though, what is that??

To answer your last question, you can have the phase change even the frequency is kept constant.

[tex] cos(\omega t)=sin(\omega t-\frac {\pi} 2) \;\hbox{ compare to }\;sin (\omega t)\;\hbox { represent the same frequency but has phase diffrerence of 90 deg.}[/tex]
 
  • #6
my confusion is that in order to differentiate a phase to get a frequency, the phase should be an increasing function right? whereas the equation for phase here is oscillating around 0.
 
  • #7
samski said:
my confusion is that in order to differentiate a phase to get a frequency, the phase should be an increasing function right? whereas the equation for phase here is oscillating around 0.

Yes, this can be confusing! took me a while to understand this. [itex] \omega t \;[/itex] is a phase. If you differentiate this, you get only [itex] \omega\;[/itex], which is frequency. But [itex] \theta_0\;[/itex] is not time dependent, it is a constant with time. They are two independent thing. If you differentiate [itex] \omega t +\theta_0\;\hbox { you get } \omega\;[/itex] no matter what [itex]\theta_0\;[/itex] is.
 
  • #8
theta-0 is time dependent here, it is a function of t right? theta-0 = e(jwt+theta)
 
  • #9
samski said:
theta-0 is time dependent here, it is a function of t right? theta-0 = e(jwt+theta)

Nop! Like what you gave [itex](\omega t +\theta)\;[/itex], obviously it is not a function of time!

But if you think back, what is the theta represent? It is the difference between the phase of the incoming signal freq. to the "locked" local oscillator. When "locked" means they are at the same frequency. So the phase is not a time dependent thing, just the phase difference between the two.

Example is say if you incoming signal is [itex]\omega t\;\hbox { and the LO signal after lock on is }\; ( \omega t +\theta)\;[/itex] The two only different by a constant [itex]\theta\;[/itex] no matter you look at it now or a minute later. It is not time dependent.
 
Last edited:
  • #10
yungman said:
Nop! Like what you gave [itex](\omega t +\theta_0)\;[/itex], obviously it is not a function of time!

But if you think back, what is the theta represent? It is the difference between the phase of the incoming signal freq. to the "locked" local oscillator. When "locked" means they are at the same frequency. So the phase is not a time dependent thing, just the phase difference between the two.

Example is say if you incoming signal is [itex]\omega t\;\hbox { and the LO signal after lock on is }\; ( \omega t +\theta_0)\;[/itex] The two only different by a constant [itex]\theta_0\;[/itex] no matter you look at it now or a minute later. It is not time dependent.

sorry are we getting confused here, i mean [itex]\theta_0 = e^{j(\omega t +\theta)}[/itex] which definitely IS a function of time. i think the phase function should look more like [itex]\theta_0 = 2 \pi f t + e^{j(\omega t +\theta)}[/itex], because then, differentiating we get [itex]frequency = 2 \pi f + j \omega e^{j(\omega t + \theta)} [/itex]
 
  • #11
samski said:
sorry are we getting confused here, i mean [itex]\theta_0 = e^{j(\omega t +\theta)}[/itex] which definitely IS a function of time. i think the phase function should look more like [itex]\theta_0 = 2 \pi f t + e^{j(\omega t +\theta)}[/itex], because then, differentiating we get [itex]frequency = 2 \pi f + j \omega e^{j(\omega t + \theta)} [/itex]

OK, I read theta_0 is not a constant.
 
Last edited:
  • #12
samski said:
my confusion is that in order to differentiate a phase to get a frequency, the phase should be an increasing function right? whereas the equation for phase here is oscillating around 0.

Now I come back to your original question. I highlight the two words. You must be referring the first one to be [itex]\theta_0\;[/itex] and the second one to be [itex]\theta.[/itex]

This is where all my confusion. All my following explanations still valid for [itex]\theta.[/itex] With that, what is your confusion again? They are of two different thing, first one is time dependent, the second is a constant! There should be no confusion.

I am going to edit my post to reflect that.
 
  • #13
samski said:
sorry are we getting confused here, i mean [itex]\theta_0 = e^{j(\omega t +\theta)}[/itex] which definitely IS a function of time. i think the phase function should look more like [itex]\theta_0 = 2 \pi f t + e^{j(\omega t +\theta)}[/itex], because then, differentiating we get [itex]frequency = 2 \pi f + j \omega e^{j(\omega t + \theta)} [/itex]

What you wrote is way off!

[tex]\cos \theta_0 = Re[e^{j(\omega t +\theta)}]\;\hbox { not what you wrote, this is very important to distinguish.} [/tex]

[tex]\theta_0 = 2 \pi f t + e^{j(\omega t +\theta)}\; \hbox { is not correct at all.}[/tex]

You got me confused! I went back and read your formulas. It is not correct that:

[tex] \theta_0=e^{(j\omega t + \theta)} \;\hbox { do not give you the phase at all.}[/tex]

I think you really need to review the phase stuffs.

It all start with:

[tex]e^x= \cos x +j\sin x\;\; ,\;\; \cos x =\frac {e^x+e^{-x}}{2}\;\;,\;\; \sin x =\frac {e^x-e^{-x}}{2j}[/tex]

[tex] \cos x =Re[e^x] \;\;,\;\; \sin x =Im[e^x][/tex]

Work out these few and if you have any question, come back.
 
Last edited:
  • #14
jim hardy said:
i'd recommend the ancient Signetics PLL applications book, ca 1972

it's on the net as a pdf...

Yep. I decided to download a copy and found it here:

"bitsavers.org/pdf/signetics/_dataBooks/1972_Signetics_PLL_Applications.pdf"
 
Last edited by a moderator:
  • #15
yungman said:
What you wrote is way off!

[tex]\cos \theta_0 = Re[e^{j(\omega t +\theta)}]\;\hbox { not what you wrote, this is very important to distinguish.} [/tex]

[tex]\theta_0 = 2 \pi f t + e^{j(\omega t +\theta)}\; \hbox { is not correct at all.}[/tex]

You got me confused! I went back and read your formulas. It is not correct that:

[tex] \theta_0=e^{(j\omega t + \theta)} \;\hbox { do not give you the phase at all.}[/tex]

I think you really need to review the phase stuffs.

It all start with:

[tex]e^x= \cos x +j\sin x\;\; ,\;\; \cos x =\frac {e^x+e^{-x}}{2}\;\;,\;\; \sin x =\frac {e^x-e^{-x}}{2j}[/tex]

[tex] \cos x =Re[e^x] \;\;,\;\; \sin x =Im[e^x][/tex]

Work out these few and if you have any question, come back.

i think i might have mentioned this in my 2nd post, omega is NOT the input frequency, omega is the wobble in the input phase.

edit: or at least i think it is, its the only way to make formula 1 make sense. omega is different to f
 
Last edited:
  • #16
I see nothing wrong with [tex]V=K[\theta_0-\theta_{ref}][/tex]

This only said voltage is proportional to the phase difference of the two phase.

Remember [itex] \theta_0 = (\omega t + \theta)\hbox{, say }\; \theta_{ref}= \omega t \;\Rightarrow\; V=K(\omega t +\theta-\omega t)=K\theta[/itex]

Therefore output voltage is K times the constant phase angle. There is nothing wrong and there is no time component in it.

Try work out the few equations I gave you, those are very important to be very familiar with. Also [itex] \cos \theta \;[/itex] is not a phase. It is the cosine of a PHASE! Look back at the forumlas how the exponential relate to cosine and sine. Don't take it offensive, I think you are confused with this whole phase thing and you need to go through it. Make sure you distinguish the difference between

frequency [itex]\omega\hbox{, phase}\;(\omega t + \theta)\;\hbox { and the simple }\;\cos ( \omega t +\theta)\;\hbox { which is NOT a phase.}[/itex]

Please don't feel bad about this, I used to have problem with this for years. It was until only like two or three years ago that I really had it, I stop and spent the time to go through this a baby step at a time and finally got it. It might look quite easy, but it can be very confusing if you don't stop and for once work it out. Until then, it will pop up from time to time. I bet you if you just work it out, it will only take you a hour or two.
 
Last edited:
  • #17
yungman said:
I see nothing wrong with [tex]V=K[\theta_0-\theta_{ref}][/tex]

This only said voltage is proportional to the phase difference of the two phase.

Remember [itex] \theta_0 = (\omega t + \theta)\hbox{, say }\; [/itex]
that's not quite true. have a look back at the original formulae.
[tex] \theta_{ref}= \omega t \;\Rightarrow\; V=K(\omega t +\theta-\omega t)=K\theta[/tex]

Therefore output voltage is K times the constant phase angle. There is nothing wrong and there is no time component in it.

Try work out the few equations I gave you, those are very important to be very familiar with. Also [itex] \cos \theta \;[/itex] is not a phase. It is the cosine of a PHASE! Look back at the forumlas how the exponential relate to cosine and sine. Don't take it offensive, I think you are confused with this whole phase thing and you need to go through it. Make sure you distinguish the difference between

frequency [itex]\omega\hbox{, phase}\;(\omega t + \theta)\;\hbox { and the simple }\;\cos ( \omega t +\theta)\;\hbox { which is NOT a phase.}[/itex]

Please don't feel bad about this, I used to have problem with this for years. It was until only like two or three years ago that I really had it, I stop and spent the time to go through this a baby step at a time and finally got it. It might look quite easy, but it can be very confusing if you don't stop and for once work it out. Until then, it will pop up from time to time. I bet you if you just work it out, it will only take you a hour or two.

i spoke to my lecturer today and he agreed that this maths doesn't quite work. please try to differentiate the equation for [itex]\theta_0[/itex] given in the original formulae. you will see that we don't get [itex]2 \pi f[/itex].

I'm wondering how we can make this maths work to get to an eventual differential equation in theta_0...
 
  • #18
samski said:
Hi. So I thought I understood PLLs pretty well after I designed a couple over summer, but I've just been taught them at university and I'm now pretty stumped! The lecture notes use Phasors which just make things confusing. I wonder if anyone could explain the 2 initial setup equations used in my notes?

Here are the notes:
http://img835.imageshack.us/img835/5376/pllv.png

please note that my big confusion is because of the possible mixing of phasors and phases, so it would be awesome if you could try and be clear between the two.

Any help would be really appreciated,

Cheers,

Sam

Read post #13 again, what you gave for theta_0 is wrong. I cannot imagine this is what the professor gave you. He should know better that

[tex] \theta_0= e^{j(\omega t +\theta )} \;\hbox { is absolutely wrong! This is not a phase!}[/tex]

Read post #13 again carefully. learn the relation between sine and cosine function to exponential function and try again. You can verify my formulas on web. This is very basic stuff that you really have to learn, or else, you'll be bouncing back and fore between people that might not get the whole picture on just a specific question.

Here is the Wiki definition of Euler's formulas

http://en.wikipedia.org/wiki/Euler's_formula

You really need to get pass this before moving on.BTW

[tex] e^{j(\omega t +\theta )}=e^{j\omega t }e^{j\theta}[/tex]
 
Last edited by a moderator:
  • #19
yungman said:
Read post #13 again, what you gave for theta_0 is wrong. I cannot imagine this is what the professor gave you. He should know better that

[tex] \theta_0= e^{j(\omega t +\theta )} \;\hbox { is absolutely wrong! This is not a phase!}[/tex]

Read post #13 again carefully. learn the relation between sine and cosine function to exponential function and try again. You can verify my formulas on web. This is very basic stuff that you really have to learn, or else, you'll be bouncing back and fore between people that might not get the whole picture on just a specific question.

Here is the Wiki definition of Euler's formulas

http://en.wikipedia.org/wiki/Euler's_formula

You really need to get pass this before moving on.


BTW

[tex] e^{j(\omega t +\theta )}=e^{j\omega t }e^{j\theta}[/tex]



These notes are EXACTLY what the professor gave us (as these are his writing from the online uploaded version of the notes)

I am quite familiar with eulers formulae and i know how multiplication and powers work, bear in mind that this is a 3rd year engineering degree course. the formula for theta_0 is one that defines a wobble in the phase itself, ie it is not constantly increasing but rather increasing and wobbling at frequency omega. what i think i need is an argument or explanation that allows equation 2 to be acceptable (even though it is wrong and neglects terms) for the derivation to a full differential equation on theta. here is a link to the full notes for this section of the course which shows the full working through to the differential equation: http://dl.dropbox.com/u/38907387/3B1%2BLecture%2B11.pdf
 
  • #20
Sorry, I can't help you anymore because if you said you are familiar with the Euler formulas and you get notes of the phase [itex]\;\theta_0=e^{j(\omega t +\theta)}\;[/itex], I don't know what to say anymore. This is just simply wrong, no other way to put it as you can see the Euler formula. I am not a professor and I am not going to say your professor is wrong. I might be missing this all together. I stand by everything I wrote so far, but what can I say? It's up to you to talk to your professor why he put it like that. Bring out the Euler formula and ask him why.

Equation 2 is not wrong, it is a simple differentiation of theta_0 that is defined at the beginning. It is the theta_0 right at the beginning I cannot accept. If everything follow are based on this, then I can't help you anymore. I cannot go any further until you resolve this.
 
Last edited:
  • #21
yungman said:
Sorry, I can't help you anymore because if you said you are familiar with the Euler formulas and you get notes of the phase [itex]\;\theta_0=e^{j(\omega t +\theta)}\;[/itex], I don't know what to say anymore. This is just simply wrong, no other way to put it as you can see the Euler formula. I am not a professor and I am not going to say your professor is wrong. I might be missing this all together. I stand by everything I wrote so far, but what can I say? It's up to you to talk to your professor why he put it like that. Bring out the Euler formula and ask him why.

Equation 2 is not wrong, it is a simple differentiation of theta_0 that is defined at the beginning. It is the theta_0 right at the beginning I cannot accept. If everything follow are based on this, then I can't help you anymore. I cannot go any further until you resolve this.

agreed, the theta_0 at the beginning is wrong. ok, so what do we say theta_0 should be to make the final maths work? it must be a phase that gives a frequency of f, but is wobbling at omega. ie the intention is that the frequency, f, is wobbling at frequency omega
 
  • #22
samski said:
agreed, the theta_0 at the beginning is wrong. ok, so what do we say theta_0 should be to make the final maths work? it must be a phase that gives a frequency of f, but is wobbling at omega. ie the intention is that the frequency, f, is wobbling at frequency omega

[tex]\theta_0=\omega t +\theta \;\hbox { where }\; \omega t \;\hbox { is the phase of the main frequency that is changing at the rate of }\;\omega[/tex]

[tex] \frac {d\theta_0}{dt}= \omega[/tex]

Which said differentiation of a phase is the frequency in radian. But obvious this is not what you want to see because the notes don't agree. In the notes, the professor:

[tex] \theta_0=e^{j(\omega t +\theta)} \;\Rightarrow\; \frac {d\theta_0}{dt}= e^{j(\omega t +\theta)}\; d(j(\omega t +\theta)\;=\; j\omega \theta_0[/tex]

This give you (2) in the notes. The professor use the theta_0 and get (2). If you accept his assertion, then (2) is correct. The problem is I cannot accept his assertion. So how are we going to get pass this? It is hard to keep going further and look at the formulas.

I don't see the phase wobble at the frequency [itex]\omega\;[/itex]. the V1 wobble with [itex]\theta_0-\theta_{ref}[/itex]. This is defined in (1).
 
Last edited:
  • #23
this is why i thought up the formula of:

[itex] \theta_0 = 2 \pi f t + e^{j(\omega t + \theta)} [/itex] (note 2*pi*f =/= omega)
differentiating gives:
[itex] differential = 2 \pi f + j \omega e^{j(\omega t + \theta)} [/itex]

which is a constant frequency of f with a wobble in the frequency, omega
 
  • #24
As I said, I am not a PLL expert, but we never even get pass the gate so far. From my understand, the [itex] \theta \;[/itex] is the modulation and is changing. So your theta_0 is changing. If [itex]\theta_{ref}\;[/itex] is stationary( or varying much slower), V1 is changing with the modulation. That's how PLL demodulate the signal.

I don't want to give advice on the PLL as I only studied it a few years ago. The main thing I jumped in is the phase part of it that something is not right.
 
  • #25
samski said:
this is why i thought up the formula of:

[itex] \theta_0 = 2 \pi f t + e^{j(\omega t + \theta)} [/itex] (note 2*pi*f =/= omega)
differentiating gives:
[itex] differential = 2 \pi f + j \omega e^{j(\omega t + \theta)} [/itex]

which is a constant frequency of f with a wobble in the frequency, omega

How do you come up with that equation?

But still [itex]e^{j(\omega t + \theta)}\;[/itex] is not a phase because by the definition of Euler equation of [itex] e^{jx}= \cos x + j\sin x\;[/itex] which is not a phase. In this example, x is the phase.

I don't think theta_0 wobble with frequency. it only wobble with theta.

I am pretty sure (1) is correct for PLL regardless of how you define theta_0. The the output of the phase detector V1 is [itex] K_p(\theta_0-\theta_{ref})[/itex].
 
Last edited:
  • #27
samski said:

Where did you find differential=2πf+jωej(ωt+θ)? Is this in your book for PLL? I am not very good in PLL, only studied it once. I don't feel comfortable to get deeper than the phase relation part. I have a few books, I think the book by William F. Egan is the best in explaining the theory. I don't like the most popular one by Roland Best.
 
  • #28
yungman said:
Where did you find differential=2πf+jωej(ωt+θ)? Is this in your book for PLL? I am not very good in PLL, only studied it once. I don't feel comfortable to get deeper than the phase relation part. I have a few books, I think the book by William F. Egan is the best in explaining the theory. I don't like the most popular one by Roland Best.

i made it up to try and make the maths work right lol. i wondered if it made sense in the rest of the maths
 
  • #29
samski said:
i made it up to try and make the maths work right lol. i wondered if it made sense in the rest of the maths

I don't think that is the right way to do. Go to Amazon and see whether you can read the William Egan book. It is a very good book on formulas and theories. I studied it...almost 6 years ago and most leaked out already. That's old age for you. At the time, I derived most of the formula and I did not spot any questionable formulas like this.

My personal laptop got infected after I came on this forum! I likely won't be able to spend much time here in the next day or two as I need to fix the computer. I suck at computers! While at this, don't ever get McAfee, they suck big, I have three attack this year alone on three different computers! the kicker is I was only on this forum today and still got attacked! I have everything with McAfee, spam, firewall and anti virus!
 
  • #30
sounds unlucky, but unless you have downloaded any files from this forum, i doubt you've got a virus from here. some browsers can help with keeping ur pc protected so have a look at that. i use AVG but there is a lot of hate out there for that. i tend to manage to stay relatively free of nasties (touch wood!).

So I *think* I have a solution for this problem based on my equation above. i think ill try and latex up a proper proof/document and post here and send to my lecturer.

here it is: http://dl.dropbox.com/u/38907387/PLLmaths.pdf If you can spot any errors in it before I sent it to my lecturer & make an arse of myself, that would be super.

Cheers

Sam
 
Last edited:
  • #31
I read the first part of your notes. x and y is not frequency! [itex]\theta (t) , \theta_{out}(t)\;[/itex] are both not even frequency, both are phase. x and y is only the sine function of those two. I think you really mixed up with the terms.

Remember the frequency is the derivative of the phase. [itex]\omega t\;[/itex] is a phase varying at speed of [itex]\omega[/itex].

[itex]\omega t\;[/itex] is the instantaneous phase at any given time t.

[tex]\theta_0=( \omega t + \theta)\;\Rightarrow\; \frac {d \theta_0}{dt}=\omega=2\pi f[/tex]

You really need to stop and work out the freq/phase and Euler stuffs before you go any further.
 
Last edited:
  • #32
re-read. x and y are the input signals
 
  • #33
samski said:
re-read. x and y are the input signals

I know, x and y are input, they are NOT frequencies like you trying to say"Define frequency input to the PLL oscillating:[itex]x=\sin(\theta(t)[/itex]! This is your first sentence! Input signals to a PLL are ALWAYS frequencies.
 
  • #34
i guess its badly phrased. but anyway, they are oscillating terms on the input to the PLL.
 
  • #35
But as I said, the input to the PLL has to be frequency. that's how PLL work, you have a LO, you input a certain frequency [itex]\omega[/itex], the PLL will take the difference between the input frequency and the LO frequency and generate a voltage according to the phase difference. that is where [itex]V_1 =K(\theta_0-\theta_{ref})[/itex]. Before it lock, the difference in phase between the two will create a voltage V1 that move the LO towards the in coming frequency. Then it become DC when the frequencies equal and lock. Under modulation, V1 will show the modulation. PLL is a down converter like IF stage of a AM or FM radio.
 
Last edited:

Similar threads

  • Electrical Engineering
Replies
2
Views
1K
  • Electrical Engineering
Replies
1
Views
5K
Replies
2
Views
3K
Replies
8
Views
2K
  • STEM Career Guidance
Replies
4
Views
1K
Replies
9
Views
6K
Replies
8
Views
2K
Replies
5
Views
3K
Replies
3
Views
4K
  • General Discussion
Replies
12
Views
5K
Back
Top