Reply by Rick Lyons August 1, 20092009-08-01
On Thu, 16 Jul 2009 07:42:04 -0500, "BCLIM" <boonchun_lim@yahoo.com>
wrote:

>Hi All, > I have read out Richard Lyons's book about approximation envelope >detection. In the book got mentione after taking magniture of analytic >signal, which is square root[square(I)+ square(Q)] and the result need to >be low pass filter to smoothen the signal. From the maths, the resultant of >the modulus of analytic signal will be only carrie(DC) plus message >signal(which is the envelope). In this case why we still need to low pass >filter to smoothen out the signal. I did a FFT plot of the signal before >low pass filtering, notice there are harmoincs of signal present. Does any >one know why the harmonic present? Thanks.
Hello BCLIM, Clay Turner's good reply answered your question. If you'd like to receive an errata for my book, please send me an E-mail. My E-mail address is in the back of the book. Regards, [-Rick-]
Reply by Dirk Bell July 22, 20092009-07-22
On Jul 22, 10:30&#4294967295;am, Dirk Bell <bellda2...@cox.net> wrote:
> On Jul 22, 7:00&#4294967295;am, "BCLIM" <boonchun_...@yahoo.com> wrote: > > > > > > > >On Jul 16, 9:45=A0pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > > >> >BCLIM wrote: > > >> >> Hi All, > > >> >> =A0 =A0 =A0 I have read out Richard Lyons's book about > > approximation > > >> envelope > > >> >> detection. In the book got mentione after taking magniture of > > analytic > > >> >> signal, which is square root[square(I)+ square(Q)] and the result > > need > > >> to > > >> >> be low pass filter to smoothen the signal. > > > >> >> From the maths, the resultant of > > >> >> the modulus of analytic signal will be only carrie(DC) plus message > > >> >> signal(which is the envelope). > > > >> >Then the math ignores the sampled nature of the signal > > > >> >> In this case why we still need to low pass filter to smoothen out > > the > > >> signal. > > > >> >To remove the images that result from the signal's sampled nature. > > > >> >> I did a FFT plot of the signal before > > >> >> low pass filtering, notice there are harmoincs of signal present. > > Does > > >> any > > >> >> one know why the harmonic present? Thanks. > > > >> >They are images. It is as if the baseband signal were modulated by > > the > > >> >sampling click. > > > >> >Jerry > > >> >-- > > >> >Engineering is the art of making what you want from things you can > > get. > > > >> Hi Jerry, > > >> Thanks for the feedback. > > >> The below is the mathlab code I used to generate the modulated AM > > signal. > > >> Just added those sine wave. I did an FFT plot on this unprocess signal. > > I > > >> don't see any images occur. But after the modulus of the analytic > > signal,= > > > I > > >> noticed the harmoinics occur. For example, 14kHz etc. > > >> fs=3D312500; > > >> T=3D41744; > > >> n=3D(0:T-1); > > >> f1=3D7000; > > >> f2=3D7060; > > >> f3=3D6940; > > > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1= > > > >*sqr=ADt(2))*sin(2*pi*f3*n/fs); > > > >> By maths, > > >> =A0 =A0 =A0 =A0Analytic signal,Xc(t) =3D A(t)*e^(jwt) > > >> A(t) is the envelope. > > >> |xc(t)| =3D square root{(A(t)*cos(wt))^2+(A(t)*sin(wt))^2} > > >> since cos^2(wt) + sin^2(wt) =3D 1 > > >> =A0 =A0|xc(t)| =3D A(t), where A(t) =3D Ac + m*cos(wm*t) and > > Ac=3Dcarrier > > >> amplitude, > > >> m=3Dmodulation index, wm=3Dw of message > > >> Does the steps looks fine? If yes, then there shouldn't be any > > hormonics > > >> present. Weird.... > > >> Regards, > > >> BC- Hide quoted text - > > > >> - Show quoted text - > > > >BCLIM, > > > >Please post the entire MATLAB code that is causing you the problem. > > >You have the generation code above, I'd like to see it all. > > > >Dirk Bell > > >DSP Consultant > > >Hi Dirk, > > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; The below is the whole code. > > fs=3D312500; > > T=41744; > > n=(0:T-1); > > f1=7000; > > f2=7060; > > f3=6940; > > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1 > > sqrt(2))*sin(2*pi*f3*n/fs); > > > fil=filter(HBT,1, xn_1); %Pass the Am signal thru hilbert transform filter > > with 0dB gain in passband. > > fil1=fil(129:41744); %remove group delay of filtered signal > > xnnew=xn_1(129:41744); % syn the original signal by taking the same amount > > of delay. > > fil1sq=fil1.*fil1; %square Q > > xn1sq=xnnew.*xnnew; &#4294967295;%square I > > RSS=sqrt(fil1sq+xn1sq); %Square root the summing > > %Then pass thru a LOW pass filter to remove the harmonics.- Hide quoted text - > > > - Show quoted text -- Hide quoted text - > > > - Show quoted text - > > BCLIM, > > Comment 1) > > I don't know what the 'D' is in fs and xn_1 (as in '3D...'), and some > of the equations after your original post. &#4294967295;It wasn't in your Jul 16 > post, so I will assume someone's editor or other SW is acting up and > the Jul 16 equations are correct. Tell us if the change actually means > something. > > Comment 2) > > I think this is your problem. > > What you have as the AM signal is not the normal AM envelope that this > method applies to. &#4294967295;You have the information modulation signal xn_1, > but you need to add a positive constant offset of greater value than > the magnitude of the minimum xn_1 value to make x1_n correspond to an > envelope modulation for this approach. So replace old xn_1 with > (1+alpha*old xn_1) where alpha is such that (1+alpha*old xn_1)>0; > maybe initially set alpha so 3/2> (1+alpha*old xn_1)>1/2. Then in your > demodulated AM output you will have the DC offset of 1 that you can > remove, and the old xn_1 scaled by alpha, which you can unscale for > comparison to the old xn_1. Note, the added constant of '1' suggested > could be some other positive number with corresponding changes to > alpha, but it will do for now. > > Dirk Bell > DSP Consultant- Hide quoted text - > > - Show quoted text -
BTW, I assume the signal you are using falls within the passband of your Hilbert filter? Dirk
Reply by Dirk Bell July 22, 20092009-07-22
On Jul 22, 7:00&#4294967295;am, "BCLIM" <boonchun_...@yahoo.com> wrote:
> >On Jul 16, 9:45=A0pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > >> >BCLIM wrote: > >> >> Hi All, > >> >> =A0 =A0 =A0 I have read out Richard Lyons's book about > approximation > >> envelope > >> >> detection. In the book got mentione after taking magniture of > analytic > >> >> signal, which is square root[square(I)+ square(Q)] and the result > need > >> to > >> >> be low pass filter to smoothen the signal. > > >> >> From the maths, the resultant of > >> >> the modulus of analytic signal will be only carrie(DC) plus message > >> >> signal(which is the envelope). > > >> >Then the math ignores the sampled nature of the signal > > >> >> In this case why we still need to low pass filter to smoothen out > the > >> signal. > > >> >To remove the images that result from the signal's sampled nature. > > >> >> I did a FFT plot of the signal before > >> >> low pass filtering, notice there are harmoincs of signal present. > Does > >> any > >> >> one know why the harmonic present? Thanks. > > >> >They are images. It is as if the baseband signal were modulated by > the > >> >sampling click. > > >> >Jerry > >> >-- > >> >Engineering is the art of making what you want from things you can > get. > > >> Hi Jerry, > >> Thanks for the feedback. > >> The below is the mathlab code I used to generate the modulated AM > signal. > >> Just added those sine wave. I did an FFT plot on this unprocess signal. > I > >> don't see any images occur. But after the modulus of the analytic > signal,= > > I > >> noticed the harmoinics occur. For example, 14kHz etc. > >> fs=3D312500; > >> T=3D41744; > >> n=3D(0:T-1); > >> f1=3D7000; > >> f2=3D7060; > >> f3=3D6940; > > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1= > > > > >*sqr=ADt(2))*sin(2*pi*f3*n/fs); > > >> By maths, > >> =A0 =A0 =A0 =A0Analytic signal,Xc(t) =3D A(t)*e^(jwt) > >> A(t) is the envelope. > >> |xc(t)| =3D square root{(A(t)*cos(wt))^2+(A(t)*sin(wt))^2} > >> since cos^2(wt) + sin^2(wt) =3D 1 > >> =A0 =A0|xc(t)| =3D A(t), where A(t) =3D Ac + m*cos(wm*t) and > Ac=3Dcarrier > >> amplitude, > >> m=3Dmodulation index, wm=3Dw of message > >> Does the steps looks fine? If yes, then there shouldn't be any > hormonics > >> present. Weird.... > >> Regards, > >> BC- Hide quoted text - > > >> - Show quoted text - > > >BCLIM, > > >Please post the entire MATLAB code that is causing you the problem. > >You have the generation code above, I'd like to see it all. > > >Dirk Bell > >DSP Consultant > >Hi Dirk, > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; The below is the whole code. > fs=3D312500; > T=41744; > n=(0:T-1); > f1=7000; > f2=7060; > f3=6940; > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1 > sqrt(2))*sin(2*pi*f3*n/fs); > > fil=filter(HBT,1, xn_1); %Pass the Am signal thru hilbert transform filter > with 0dB gain in passband. > fil1=fil(129:41744); %remove group delay of filtered signal > xnnew=xn_1(129:41744); % syn the original signal by taking the same amount > of delay. > fil1sq=fil1.*fil1; %square Q > xn1sq=xnnew.*xnnew; &#4294967295;%square I > RSS=sqrt(fil1sq+xn1sq); %Square root the summing > %Then pass thru a LOW pass filter to remove the harmonics.- Hide quoted text - > > - Show quoted text -- Hide quoted text - > > - Show quoted text -
BCLIM, Comment 1) I don't know what the 'D' is in fs and xn_1 (as in '3D...'), and some of the equations after your original post. It wasn't in your Jul 16 post, so I will assume someone's editor or other SW is acting up and the Jul 16 equations are correct. Tell us if the change actually means something. Comment 2) I think this is your problem. What you have as the AM signal is not the normal AM envelope that this method applies to. You have the information modulation signal xn_1, but you need to add a positive constant offset of greater value than the magnitude of the minimum xn_1 value to make x1_n correspond to an envelope modulation for this approach. So replace old xn_1 with (1+alpha*old xn_1) where alpha is such that (1+alpha*old xn_1)>0; maybe initially set alpha so 3/2> (1+alpha*old xn_1)>1/2. Then in your demodulated AM output you will have the DC offset of 1 that you can remove, and the old xn_1 scaled by alpha, which you can unscale for comparison to the old xn_1. Note, the added constant of '1' suggested could be some other positive number with corresponding changes to alpha, but it will do for now. Dirk Bell DSP Consultant
Reply by Dirk Bell July 22, 20092009-07-22
On Jul 22, 7:00&#4294967295;am, "BCLIM" <boonchun_...@yahoo.com> wrote:
> >On Jul 16, 9:45=A0pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > >> >BCLIM wrote: > >> >> Hi All, > >> >> =A0 =A0 =A0 I have read out Richard Lyons's book about > approximation > >> envelope > >> >> detection. In the book got mentione after taking magniture of > analytic > >> >> signal, which is square root[square(I)+ square(Q)] and the result > need > >> to > >> >> be low pass filter to smoothen the signal. > > >> >> From the maths, the resultant of > >> >> the modulus of analytic signal will be only carrie(DC) plus message > >> >> signal(which is the envelope). > > >> >Then the math ignores the sampled nature of the signal > > >> >> In this case why we still need to low pass filter to smoothen out > the > >> signal. > > >> >To remove the images that result from the signal's sampled nature. > > >> >> I did a FFT plot of the signal before > >> >> low pass filtering, notice there are harmoincs of signal present. > Does > >> any > >> >> one know why the harmonic present? Thanks. > > >> >They are images. It is as if the baseband signal were modulated by > the > >> >sampling click. > > >> >Jerry > >> >-- > >> >Engineering is the art of making what you want from things you can > get. > > >> Hi Jerry, > >> Thanks for the feedback. > >> The below is the mathlab code I used to generate the modulated AM > signal. > >> Just added those sine wave. I did an FFT plot on this unprocess signal. > I > >> don't see any images occur. But after the modulus of the analytic > signal,= > > I > >> noticed the harmoinics occur. For example, 14kHz etc. > >> fs=3D312500; > >> T=3D41744; > >> n=3D(0:T-1); > >> f1=3D7000; > >> f2=3D7060; > >> f3=3D6940; > > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1= > > > > >*sqr=ADt(2))*sin(2*pi*f3*n/fs); > > >> By maths, > >> =A0 =A0 =A0 =A0Analytic signal,Xc(t) =3D A(t)*e^(jwt) > >> A(t) is the envelope. > >> |xc(t)| =3D square root{(A(t)*cos(wt))^2+(A(t)*sin(wt))^2} > >> since cos^2(wt) + sin^2(wt) =3D 1 > >> =A0 =A0|xc(t)| =3D A(t), where A(t) =3D Ac + m*cos(wm*t) and > Ac=3Dcarrier > >> amplitude, > >> m=3Dmodulation index, wm=3Dw of message > >> Does the steps looks fine? If yes, then there shouldn't be any > hormonics > >> present. Weird.... > >> Regards, > >> BC- Hide quoted text - > > >> - Show quoted text - > > >BCLIM, > > >Please post the entire MATLAB code that is causing you the problem. > >You have the generation code above, I'd like to see it all. > > >Dirk Bell > >DSP Consultant > >Hi Dirk, > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; The below is the whole code. > fs=3D312500; > T=41744; > n=(0:T-1); > f1=7000; > f2=7060; > f3=6940; > xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1 > sqrt(2))*sin(2*pi*f3*n/fs); > > fil=filter(HBT,1, xn_1); %Pass the Am signal thru hilbert transform filter > with 0dB gain in passband. > fil1=fil(129:41744); %remove group delay of filtered signal > xnnew=xn_1(129:41744); % syn the original signal by taking the same amount > of delay. > fil1sq=fil1.*fil1; %square Q > xn1sq=xnnew.*xnnew; &#4294967295;%square I > RSS=sqrt(fil1sq+xn1sq); %Square root the summing > %Then pass thru a LOW pass filter to remove the harmonics.- Hide quoted text - > > - Show quoted text -- Hide quoted text - > > - Show quoted text -
BCLIM, Comment 1) I don't know what the 'D' is in fs and xn_1 (as in '3D...'), and some of the equations after your original post. It wasn't in your Jul 16 post, so I will assume someone's editor or other SW is acting up and the Jul 16 equations are correct. Tell us if the change actually means something. Comment 2) I think this is your problem. What you have as the AM signal is not the normal AM envelope that this method applies to. You have the information modulation signal xn_1, but you need to add a need a positive constant offset of greater value than the minimum xn_1 value to make x1_n correspond to an envelope modulation for this approach. So replace old xn_1 with (1+alpha*old xn_1) where alpha is such that (1+alpha*old xn_1)>0, maybe initially set alpha so 3/2> (1+alpha*old xn_1)>1/2. Then in your demodulated AM output you will have the DC offset of 1 that you can remove and the old xn_1 scaled by alpha (which you can unscale for comparison to the old xn_1). Note, the added constant of '1' suggested could be some other positive number with corresponding changes to alpha, but it will do for now. Dirk Bell DSP Consultant
Reply by BCLIM July 22, 20092009-07-22
>On Jul 16, 9:45=A0pm, "BCLIM" <boonchun_...@yahoo.com> wrote: >> >BCLIM wrote: >> >> Hi All, >> >> =A0 =A0 =A0 I have read out Richard Lyons's book about
approximation
>> envelope >> >> detection. In the book got mentione after taking magniture of
analytic
>> >> signal, which is square root[square(I)+ square(Q)] and the result
need
>> to >> >> be low pass filter to smoothen the signal. >> >> >> From the maths, the resultant of >> >> the modulus of analytic signal will be only carrie(DC) plus message >> >> signal(which is the envelope). >> >> >Then the math ignores the sampled nature of the signal >> >> >> In this case why we still need to low pass filter to smoothen out
the
>> signal. >> >> >To remove the images that result from the signal's sampled nature. >> >> >> I did a FFT plot of the signal before >> >> low pass filtering, notice there are harmoincs of signal present.
Does
>> any >> >> one know why the harmonic present? Thanks. >> >> >They are images. It is as if the baseband signal were modulated by
the
>> >sampling click. >> >> >Jerry >> >-- >> >Engineering is the art of making what you want from things you can
get.
>> > >> >> Hi Jerry, >> Thanks for the feedback. >> The below is the mathlab code I used to generate the modulated AM
signal.
>> Just added those sine wave. I did an FFT plot on this unprocess signal.
I
>> don't see any images occur. But after the modulus of the analytic
signal,=
> I >> noticed the harmoinics occur. For example, 14kHz etc. >> fs=3D312500; >> T=3D41744; >> n=3D(0:T-1); >> f1=3D7000; >> f2=3D7060; >> f3=3D6940; >>
xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1=
>*sqr=ADt(2))*sin(2*pi*f3*n/fs); >> >> By maths, >> =A0 =A0 =A0 =A0Analytic signal,Xc(t) =3D A(t)*e^(jwt) >> A(t) is the envelope. >> |xc(t)| =3D square root{(A(t)*cos(wt))^2+(A(t)*sin(wt))^2} >> since cos^2(wt) + sin^2(wt) =3D 1 >> =A0 =A0|xc(t)| =3D A(t), where A(t) =3D Ac + m*cos(wm*t) and
Ac=3Dcarrier
>> amplitude, >> m=3Dmodulation index, wm=3Dw of message >> Does the steps looks fine? If yes, then there shouldn't be any
hormonics
>> present. Weird.... >> Regards, >> BC- Hide quoted text - >> >> - Show quoted text - > >BCLIM, > >Please post the entire MATLAB code that is causing you the problem. >You have the generation code above, I'd like to see it all. > >Dirk Bell >DSP Consultant >Hi Dirk,
The below is the whole code. fs=3D312500; T=41744; n=(0:T-1); f1=7000; f2=7060; f3=6940; xn_1=3D(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1 sqrt(2))*sin(2*pi*f3*n/fs); fil=filter(HBT,1, xn_1); %Pass the Am signal thru hilbert transform filter with 0dB gain in passband. fil1=fil(129:41744); %remove group delay of filtered signal xnnew=xn_1(129:41744); % syn the original signal by taking the same amount of delay. fil1sq=fil1.*fil1; %square Q xn1sq=xnnew.*xnnew; %square I RSS=sqrt(fil1sq+xn1sq); %Square root the summing %Then pass thru a LOW pass filter to remove the harmonics.
Reply by Jerry Avins July 21, 20092009-07-21
Clay wrote:
> On Jul 20, 10:38 pm, Jerry Avins <j...@ieee.org> wrote:
...
>> Clay, I'm confused. We aren't squaring the signal, we're squaring >> individual samples as part of calculating sqrt(i[n]^2 +q[n]^2), or >> instantaneous magnitude. How do aliases arise?
...
> Aliasing is the issue because the effect arises when the I and Q > channels fail to have matched amplitudes. In this case the wrap around > images caused by the doubled frequencies don't cancel out.
Nuff said! I can take it from there. You have a very gentle way of making me feel dumb. ...
> I hope this helps to clear things up.
Indeed! But even while reading your latest contribution to "DSP Tips and Tricks" piece (An Efficient Analytic Signal Generator) I still didn't get it. 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;
Reply by Clay July 21, 20092009-07-21
On Jul 21, 2:37&#4294967295;pm, Dirk Bell <bellda2...@cox.net> wrote:
> On Jul 21, 10:18&#4294967295;am, Clay <c...@claysturner.com> wrote: > > > > > > > On Jul 20, 12:24&#4294967295;pm, Dirk Bell <bellda2...@cox.net> wrote: > > > > On Jul 20, 10:44&#4294967295;am, Clay <c...@claysturner.com> wrote: > > > > > On Jul 19, 10:06&#4294967295;pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > > > > > > >On Jul 16, 8:42=A0am, "BCLIM" <boonchun_...@yahoo.com> wrote: > > > > > >> Hi All, > > > > > >> =A0 =A0 =A0 I have read out Richard Lyons's book about approximation > > > > > enve= > > > > > >lope > > > > > >> detection. In the book got mentione after taking magniture of analytic > > > > > >> signal, which is square root[square(I)+ square(Q)] and the result need > > > > > to > > > > > >> be low pass filter to smoothen the signal. From the maths, the > > > > > resultant = > > > > > >of > > > > > >> the modulus of analytic signal will be only carrie(DC) plus message > > > > > >> signal(which is the envelope). In this case why we still need to low > > > > > pass > > > > > >> filter to smoothen out the signal. I did a FFT plot of the signal > > > > > before > > > > > >> low pass filtering, notice there are harmoincs of signal present. Does > > > > > an= > > > > > >y > > > > > >> one know why the harmonic present? Thanks. > > > > > > >Aliasing? When you square the I and Q signals their bandwidths double. > > > > > >Do you have enough headroom between your signal content and the sample > > > > > >rate to avoid aliasing? > > > > > > >Clay > > > > > > >Hi Clay, > > > > > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; The I and Q signal are digitized signal, the square of these > > > > > signals are done in the software. Therefore there shouldn't be any aliasing > > > > > problem. But definetely sqaure of each the signal will have second > > > > > harmonis, in this case I thought the mathematical shown at the end i will > > > > > only have the DC term(carrier) plus the message signal so I have no idea > > > > > why the harmonics still present. Thanks. > > > > > > Regards, > > > > > BC- Hide quoted text - > > > > > > - Show quoted text - > > > > > Hello BC, > > > > > I think you missed the point. For example let's say you have a 1000 Hz > > > > sinewave sampled at 2500 Hz. Here there is no aliasing. Now square the > > > > 1000 Hz sinewave. A simple trig theorem tells us that we now have a > > > > mix of 0Hz and 2000 Hz. Thus the 2000 Hz component sampled at 2500Hz > > > > becomes a 500 Hz component. The aliasing has folded the signal's > > > > spectrum back on itself. It doesn't matter that this is done in > > > > software after the original sampling process. > > > > > Now back to the main question. Is your sampling rate more than four > > > > times the maximum frequency? (before any squaring) > > > > > Clay- Hide quoted text - > > > > > - Show quoted text - > > > > And the impact on the signals obtained from the IQ demod method will > > > be? > > > > Dirk Bell > > > DSP Consultant- Hide quoted text - > > > > - Show quoted text - > > > Hello Dirk, > > > See my response to Jerry below.- Hide quoted text - > > > - Show quoted text - > > Hello Clay, > > I guess I have been fortunate to never have to deal with unmatched > channels. &#4294967295;I have always been able to start out with real sampled data > and create the IQ signals myself, which allowed me to avoid the > issue. &#4294967295;I realize that is not always possible. > > Dirk Bell > DSP Consultant- Hide quoted text - > > - Show quoted text -
Hello Dirk, It was this kind of issue that drove me to develop a scheme that ensured both channels have matched amplitudes. Sometimes you find you have a bandpass signal going through an I/Q splitter that does a great job and other times you just have a real valued stream and need to make the analytic signal in software. Clay
Reply by Dirk Bell July 21, 20092009-07-21
On Jul 21, 10:18&#4294967295;am, Clay <c...@claysturner.com> wrote:
> On Jul 20, 12:24&#4294967295;pm, Dirk Bell <bellda2...@cox.net> wrote: > > > > > > > On Jul 20, 10:44&#4294967295;am, Clay <c...@claysturner.com> wrote: > > > > On Jul 19, 10:06&#4294967295;pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > > > > > >On Jul 16, 8:42=A0am, "BCLIM" <boonchun_...@yahoo.com> wrote: > > > > >> Hi All, > > > > >> =A0 =A0 =A0 I have read out Richard Lyons's book about approximation > > > > enve= > > > > >lope > > > > >> detection. In the book got mentione after taking magniture of analytic > > > > >> signal, which is square root[square(I)+ square(Q)] and the result need > > > > to > > > > >> be low pass filter to smoothen the signal. From the maths, the > > > > resultant = > > > > >of > > > > >> the modulus of analytic signal will be only carrie(DC) plus message > > > > >> signal(which is the envelope). In this case why we still need to low > > > > pass > > > > >> filter to smoothen out the signal. I did a FFT plot of the signal > > > > before > > > > >> low pass filtering, notice there are harmoincs of signal present. Does > > > > an= > > > > >y > > > > >> one know why the harmonic present? Thanks. > > > > > >Aliasing? When you square the I and Q signals their bandwidths double. > > > > >Do you have enough headroom between your signal content and the sample > > > > >rate to avoid aliasing? > > > > > >Clay > > > > > >Hi Clay, > > > > > &#4294967295; &#4294967295; &#4294967295; &#4294967295; The I and Q signal are digitized signal, the square of these > > > > signals are done in the software. Therefore there shouldn't be any aliasing > > > > problem. But definetely sqaure of each the signal will have second > > > > harmonis, in this case I thought the mathematical shown at the end i will > > > > only have the DC term(carrier) plus the message signal so I have no idea > > > > why the harmonics still present. Thanks. > > > > > Regards, > > > > BC- Hide quoted text - > > > > > - Show quoted text - > > > > Hello BC, > > > > I think you missed the point. For example let's say you have a 1000 Hz > > > sinewave sampled at 2500 Hz. Here there is no aliasing. Now square the > > > 1000 Hz sinewave. A simple trig theorem tells us that we now have a > > > mix of 0Hz and 2000 Hz. Thus the 2000 Hz component sampled at 2500Hz > > > becomes a 500 Hz component. The aliasing has folded the signal's > > > spectrum back on itself. It doesn't matter that this is done in > > > software after the original sampling process. > > > > Now back to the main question. Is your sampling rate more than four > > > times the maximum frequency? (before any squaring) > > > > Clay- Hide quoted text - > > > > - Show quoted text - > > > And the impact on the signals obtained from the IQ demod method will > > be? > > > Dirk Bell > > DSP Consultant- Hide quoted text - > > > - Show quoted text - > > Hello Dirk, > > See my response to Jerry below.- Hide quoted text - > > - Show quoted text -
Hello Clay, I guess I have been fortunate to never have to deal with unmatched channels. I have always been able to start out with real sampled data and create the IQ signals myself, which allowed me to avoid the issue. I realize that is not always possible. Dirk Bell DSP Consultant
Reply by Dirk Bell July 21, 20092009-07-21
On Jul 16, 9:45&#4294967295;pm, "BCLIM" <boonchun_...@yahoo.com> wrote:
> >BCLIM wrote: > >> Hi All, > >> &#4294967295; &#4294967295; &#4294967295; I have read out Richard Lyons's book about approximation > envelope > >> detection. In the book got mentione after taking magniture of analytic > >> signal, which is square root[square(I)+ square(Q)] and the result need > to > >> be low pass filter to smoothen the signal. > > >> From the maths, the resultant of > >> the modulus of analytic signal will be only carrie(DC) plus message > >> signal(which is the envelope). > > >Then the math ignores the sampled nature of the signal > > >> In this case why we still need to low pass filter to smoothen out the > signal. > > >To remove the images that result from the signal's sampled nature. > > >> I did a FFT plot of the signal before > >> low pass filtering, notice there are harmoincs of signal present. Does > any > >> one know why the harmonic present? Thanks. > > >They are images. It is as if the baseband signal were modulated by the > >sampling click. > > >Jerry > >-- > >Engineering is the art of making what you want from things you can get. > > > > Hi Jerry, > Thanks for the feedback. > The below is the mathlab code I used to generate the modulated AM signal. > Just added those sine wave. I did an FFT plot on this unprocess signal. I > don't see any images occur. But after the modulus of the analytic signal, I > noticed the harmoinics occur. For example, 14kHz etc. > fs=312500; > T=41744; > n=(0:T-1); > f1=7000; > f2=7060; > f3=6940; > xn_1=(1*sqrt(2))*sin(2*pi*f1*n/fs)+(0.1*sqrt(2))*sin(2*pi*f2*n/fs)+(0.1*sqr&#4294967295;t(2))*sin(2*pi*f3*n/fs); > > By maths, > &#4294967295; &#4294967295; &#4294967295; &#4294967295;Analytic signal,Xc(t) = A(t)*e^(jwt) > A(t) is the envelope. > |xc(t)| = square root{(A(t)*cos(wt))^2+(A(t)*sin(wt))^2} > since cos^2(wt) + sin^2(wt) = 1 > &#4294967295; &#4294967295;|xc(t)| = A(t), where A(t) = Ac + m*cos(wm*t) and Ac=carrier > amplitude, > m=modulation index, wm=w of message > Does the steps looks fine? If yes, then there shouldn't be any hormonics > present. Weird.... > Regards, > BC- Hide quoted text - > > - Show quoted text -
BCLIM, Please post the entire MATLAB code that is causing you the problem. You have the generation code above, I'd like to see it all. Dirk Bell DSP Consultant
Reply by Clay July 21, 20092009-07-21
On Jul 21, 6:40&#4294967295;am, "BCLIM" <boonchun_...@yahoo.com> wrote:
> >On Jul 19, 10:06=A0pm, "BCLIM" <boonchun_...@yahoo.com> wrote: > >> >On Jul 16, 8:42=3DA0am, "BCLIM" <boonchun_...@yahoo.com> wrote: > >> >> Hi All, > >> >> =3DA0 =3DA0 =3DA0 I have read out Richard Lyons's book about > approxima= > >tion > >> enve=3D > >> >lope > >> >> detection. In the book got mentione after taking magniture of > analytic > >> >> signal, which is square root[square(I)+ square(Q)] and the result > need > >> to > >> >> be low pass filter to smoothen the signal. From the maths, the > >> resultant =3D > >> >of > >> >> the modulus of analytic signal will be only carrie(DC) plus message > >> >> signal(which is the envelope). In this case why we still need to > low > >> pass > >> >> filter to smoothen out the signal. I did a FFT plot of the signal > >> before > >> >> low pass filtering, notice there are harmoincs of signal present. > Does > >> an=3D > >> >y > >> >> one know why the harmonic present? Thanks. > > >> >Aliasing? When you square the I and Q signals their bandwidths > double. > >> >Do you have enough headroom between your signal content and the > sample > >> >rate to avoid aliasing? > > >> >Clay > > >> >Hi Clay, > > >> =A0 =A0 =A0 =A0 The I and Q signal are digitized signal, the square of > th= > >ese > >> signals are done in the software. Therefore there shouldn't be any > aliasi= > >ng > >> problem. But definetely sqaure of each the signal will have second > >> harmonis, in this case I thought the mathematical shown at the end i > will > >> only have the DC term(carrier) plus the message signal so I have no > idea > >> why the harmonics still present. Thanks. > > >> Regards, > >> BC- Hide quoted text - > > >> - Show quoted text - > > >Hello BC, > > >I think you missed the point. For example let's say you have a 1000 Hz > >sinewave sampled at 2500 Hz. Here there is no aliasing. Now square the > >1000 Hz sinewave. A simple trig theorem tells us that we now have a > >mix of 0Hz and 2000 Hz. Thus the 2000 Hz component sampled at 2500Hz > >becomes a 500 Hz component. The aliasing has folded the signal's > >spectrum back on itself. It doesn't matter that this is done in > >software after the original sampling process. > > >Now back to the main question. Is your sampling rate more than four > >times the maximum frequency? (before any squaring) > > >Clay > > >Hi Clay, > > &#4294967295; &#4294967295; &#4294967295; &#4294967295;Yup. The sampling rate is more than 4X. The signal is 7kHz and the > sampling rate 300kHz something. > BC- Hide quoted text - > > - Show quoted text -
Good, now look at just feeding a single frequency sinusoid into the system and then analyze the I and Q channels to see if they are 90 degrees out of phase and matched in amplitude over all of your frequencies of interest. I bet your problem is here. Clay