DSPRelated.com
Forums

Advantages of Envelope detector using Hilbert Transform

Started by c1910 February 11, 2008
Philip Martel wrote:
> "Jerry Avins" <jya@ieee.org> wrote in message > news:GLGdnTjnkfQWVyzanZ2dnUVZ_g2dnZ2d@rcn.net... >> c1910 wrote: >>>> c1910 wrote: >>>>> hi! >>>>> i make an envelope detector for AM demodulation using Hilbert >>> Transform >>>>> and complex envelope... >>>>> >>>>> but i don't really understand about the advantages of using Hilbert >>>>> Transform and complex envelope... >>>>> >>>>> what is the advantages of using Hilbert Transform and complex >>> envelope? >>>>> why using Hilbert Transform method is more effective than square-law? >>>>> >>>>> and i think i can make an envelope detector just without hilbert >>>>> transform. >>>>> i can use the I-phase, then multiply with exp(-jwt), then LPF. and we >>> can >>>>> multiply the output by 2, because the output will give me only half >>>>> amplitude... >>>>> >>>>> please give me some advice... >>>>> >>>>> thanks... >>>> Square-law detectors suffer from distortion (with the rare exception of >>>> single-sideband with carrier. They have no place in digital designs that >>>> I know of. Peak detectors work with continuous signals, but there is no >>>> reason to think that most samples will be near the carrier peak in a >>>> sampled system unless the oversampling ratio is quite high relative to >>>> the carrier or IF frequency. I-Q demodulation allows you to get the >>>> magnitude at much lower sample rates. >>>> >>>> If you didn't know that, what led you to that method? >>>> >> >>> i use that method because i think there is a lot of distorsion in square >>> law...coz, square law still have the Carrier's Amplitude... >> I don't understand the part the reason for the distortion. Squaring a >> signal inevitably distorts it. Forget square-law detectors for recovering >> ordinary AM. Most "simple" AM demodulators are peak detectors. A digital >> peak detector is not only hard to design, hard even to define what it is. >> You can approximately extract the envelope by ensuring that the RF or IF >> signal is zero mean, then taking its absolute value -- not squaring -- and >> low-pass filtering. That will work fairly well most of the time, but on >> occasion it can fail horribly. Those failures will be brief enough to go >> unnoticed, except when you're demonstrating your system. >> >> Jerry >> -- >> Engineering is the art of making what you want from things you can get. >> &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295; > &#4294967295;&#4294967295; > Perhaps I'm missing something. I *think* this is a "digital peak detector" > that behaves like a diode feeding an RC network > > y(0) = 0; > y(n+1) = x(n) > y(n) ? x(n) : A * y(n); > > A should be a bit smapper than 1...
Smapper? It it's only an approximate digital peak detector. There's no guarantee that any of the samples will occur near the peak of the carrier waveform. When the sample rate is badly timed relative to the carrier frequency, there can be periods of distortion. Jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
On Wed, 13 Feb 2008 21:03:42 -0500, "Philip Martel"
<pomartel@comcast.net> wrote:

              (snipped)

>&#4294967295;&#4294967295; >Perhaps I'm missing something. I *think* this is a "digital peak detector" >that behaves like a diode feeding an RC network > >y(0) = 0; >y(n+1) = x(n) > y(n) ? x(n) : A * y(n); > >A should be a bit smapper than 1... > > Best wishes, > --Phil Martel
Hi Phil, sorry for my being so thick-skulled. What do the ">", "?", ":", and "*" symbols mean? Thanks, [-Rick-]
On 14 Feb, 10:28, Rick Lyons <R.Lyons@_BOGUS_ieee.org> wrote:
> On Wed, 13 Feb 2008 21:03:42 -0500, "Philip Martel" > > <pomar...@comcast.net> wrote: > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; &#4294967295; &#4294967295; &#4294967295; (snipped) > > >&#4294967295;&#4294967295; > >Perhaps I'm missing something. &#4294967295;I *think* this is a "digital peak detector" > >that behaves like a diode feeding an RC network > > >y(0) = 0; > >y(n+1) = x(n) > y(n) ? x(n) : A * y(n); > > >A should be a bit smapper than 1... > > > &#4294967295; Best wishes, > > &#4294967295; --Phil Martel > > Hi Phil, > &#4294967295; sorry for my being so thick-skulled. > What do the ">", "?", ":", and "*" > symbols mean?
Seems to me that it's an "if-then-else" test written "compact C" style... Rune
"Rune Allnor" <allnor@tele.ntnu.no> wrote in message 
news:f57d431f-c48f-46e4-92df-08c50f88ad0f@h11g2000prf.googlegroups.com...
On 14 Feb, 10:28, Rick Lyons <R.Lyons@_BOGUS_ieee.org> wrote:
> On Wed, 13 Feb 2008 21:03:42 -0500, "Philip Martel" > > <pomar...@comcast.net> wrote: > > (snipped) > > >&#4294967295;&#4294967295; > >Perhaps I'm missing something. I *think* this is a "digital peak > >detector" > >that behaves like a diode feeding an RC network > > >y(0) = 0; > >y(n+1) = x(n) > y(n) ? x(n) : A * y(n); > > >A should be a bit smapper than 1... > > > Best wishes, > > --Phil Martel > > Hi Phil, > sorry for my being so thick-skulled. > What do the ">", "?", ":", and "*" > symbols mean?
Seems to me that it's an "if-then-else" test written "compact C" style... Rune Yes that is right. if x(n) > y(n) y(n+1) = x(n); else y(n+1) = A * y(n); end A should be smaLLer than 1...
"Jerry Avins" <jya@ieee.org> wrote in message 
news:ou-dnUw6NYPsOi7anZ2dnUVZ_qrinZ2d@rcn.net...
> Philip Martel wrote: >> "Jerry Avins" <jya@ieee.org> wrote in message >> news:GLGdnTjnkfQWVyzanZ2dnUVZ_g2dnZ2d@rcn.net... >>> c1910 wrote: >>>>> c1910 wrote: >>>>>> hi! >>>>>> i make an envelope detector for AM demodulation using Hilbert >>>> Transform >>>>>> and complex envelope... >>>>>> >>>>>> but i don't really understand about the advantages of using Hilbert >>>>>> Transform and complex envelope... >>>>>> >>>>>> what is the advantages of using Hilbert Transform and complex >>>> envelope? >>>>>> why using Hilbert Transform method is more effective than square-law? >>>>>> >>>>>> and i think i can make an envelope detector just without hilbert >>>>>> transform. >>>>>> i can use the I-phase, then multiply with exp(-jwt), then LPF. and we >>>> can >>>>>> multiply the output by 2, because the output will give me only half >>>>>> amplitude... >>>>>> >>>>>> please give me some advice... >>>>>> >>>>>> thanks... >>>>> Square-law detectors suffer from distortion (with the rare exception >>>>> of single-sideband with carrier. They have no place in digital designs >>>>> that >>>>> I know of. Peak detectors work with continuous signals, but there is >>>>> no reason to think that most samples will be near the carrier peak in >>>>> a sampled system unless the oversampling ratio is quite high relative >>>>> to the carrier or IF frequency. I-Q demodulation allows you to get the >>>>> magnitude at much lower sample rates. >>>>> >>>>> If you didn't know that, what led you to that method? >>>>> >>> >>>> i use that method because i think there is a lot of distorsion in >>>> square >>>> law...coz, square law still have the Carrier's Amplitude... >>> I don't understand the part the reason for the distortion. Squaring a >>> signal inevitably distorts it. Forget square-law detectors for >>> recovering ordinary AM. Most "simple" AM demodulators are peak >>> detectors. A digital peak detector is not only hard to design, hard even >>> to define what it is. You can approximately extract the envelope by >>> ensuring that the RF or IF signal is zero mean, then taking its absolute >>> value -- not squaring -- and low-pass filtering. That will work fairly >>> well most of the time, but on occasion it can fail horribly. Those >>> failures will be brief enough to go unnoticed, except when you're >>> demonstrating your system. >>> >>> Jerry >>> -- >>> Engineering is the art of making what you want from things you can get. >>> &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295; >> &#4294967295;&#4294967295; >> Perhaps I'm missing something. I *think* this is a "digital peak >> detector" that behaves like a diode feeding an RC network >> >> y(0) = 0; >> y(n+1) = x(n) > y(n) ? x(n) : A * y(n); >> >> A should be a bit smapper than 1... > > Smapper?
"smaller" sorry about the typo...
> > It it's only an approximate digital peak detector. There's no guarantee > that any of the samples will occur near the peak of the carrier waveform. > When the sample rate is badly timed relative to the carrier frequency, > there can be periods of distortion.
True. Will using a Hilbert transform avoid that problem?
> > Jerry > -- > Engineering is the art of making what you want from things you can get. > &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
Philip Martel wrote:
> "Jerry Avins" <jya@ieee.org> wrote in message > news:ou-dnUw6NYPsOi7anZ2dnUVZ_qrinZ2d@rcn.net... >> Philip Martel wrote:
...
>>> Perhaps I'm missing something. I *think* this is a "digital peak >>> detector" that behaves like a diode feeding an RC network >>> >>> y(0) = 0; >>> y(n+1) = x(n) > y(n) ? x(n) : A * y(n); >>> >>> A should be a bit smapper than 1... >> Smapper? > "smaller" sorry about the typo...
I should have guessed.
>> It it's only an approximate digital peak detector. There's no guarantee >> that any of the samples will occur near the peak of the carrier waveform. >> When the sample rate is badly timed relative to the carrier frequency, >> there can be periods of distortion. > > True. Will using a Hilbert transform avoid that problem?
Yes. Sin^2 + cos^2 = 1 even when neither is at the peak. Jerry -- Engineering is the art of making what you want from things you can get. &#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;&#4294967295;
On Thu, 14 Feb 2008 20:15:36 -0500, "Philip Martel"
<pomartel@comcast.net> wrote:

> >"Rune Allnor" <allnor@tele.ntnu.no> wrote in message >news:f57d431f-c48f-46e4-92df-08c50f88ad0f@h11g2000prf.googlegroups.com... >On 14 Feb, 10:28, Rick Lyons <R.Lyons@_BOGUS_ieee.org> wrote: >> On Wed, 13 Feb 2008 21:03:42 -0500, "Philip Martel" >> >> <pomar...@comcast.net> wrote: >> >>
(snipped)
>> >> Hi Phil, >> sorry for my being so thick-skulled. >> What do the ">", "?", ":", and "*" >> symbols mean? > >Seems to me that it's an "if-then-else" test >written "compact C" style... > >Rune >Yes that is right. >if x(n) > y(n) > y(n+1) = x(n); >else > y(n+1) = A * y(n); >end > >A should be smaLLer than 1...
Thanks Phil (& Rune) [-Rick-]
i don't know how to make a ceomplex envelope in C, 
so in my program i multiply the I-phase and Q-phase signal with sinusoidal
signal 
for example : the I-phase signal multiply with cos
              the Q-phase signal multiply with sin
then each signal from the multiplier pass through LPF then sum the output
signal from LPF.

is it all right?
or are there any bad things will happen to the signal?
On Feb 21, 9:56 am, "c1910" <c_19...@hotmail.com> wrote:
> i don't know how to make a ceomplex envelope in C, > so in my program i multiply the I-phase and Q-phase signal with sinusoidal > signal > for example : the I-phase signal multiply with cos > the Q-phase signal multiply with sin > then each signal from the multiplier pass through LPF then sum the output > signal from LPF. > > is it all right? > or are there any bad things will happen to the signal?
i think the envelope is sqrt(I^2 + Q^2). and you don't need to filter either I or Q (and shouldn't). r b-j
dear Jerry,
>u said :
>Square-law detectors suffer from distortion (with the rare exception of >single-sideband with carrier. They have no place in digital designs that
>I know of. Peak detectors work with continuous signals, but there is no >reason to think that most samples will be near the carrier peak in a >sampled system unless the oversampling ratio is quite high relative to >the carrier or IF frequency. I-Q demodulation allows you to get the >magnitude at much lower sample rates. > >If you didn't know that, what led you to that method? > >Jerry >-- >Engineering is the art of making what you want from things you can get. >&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533;&#65533; >
i need a mathematical calculation or proof in math... is there any math explanation for this?