From: cfy30 on 16 Apr 2010 00:43 Hi all, I am a newbie to Hilbert transform. I found the follow definition from textbook H(f) = -j or -90degree, f>0 H(f) = j or +90degree, f<0 H(f) = 0, f=0 But when I plot the phase out in Matlab, I saw that the phase is not constant at -90 or +90degree across frequency. The code I have is as follow b = firpm(10,[.1 .9],[1 1],'Hilbert') w = linspace(-pi, pi, 2^12); h = freqz(b, 1, w); plot(w, angle(h)*180/pi); What do I miss? Cfy30 From: Jerry Avins on 16 Apr 2010 01:26 On 4/16/2010 12:43 AM, cfy30 wrote:> Hi all, > > I am a newbie to Hilbert transform. I found the follow definition from > textbook > > H(f) = -j or -90degree, f>0 > H(f) = j or +90degree, f<0 > H(f) = 0, f=0 > > But when I plot the phase out in Matlab, I saw that the phase is not > constant at -90 or +90degree across frequency. The code I have is as > follow > > b = firpm(10,[.1 .9],[1 1],'Hilbert') > w = linspace(-pi, pi, 2^12); > h = freqz(b, 1, w); > plot(w, angle(h)*180/pi); > > What do I miss? The phase is 90 degrees only over a limited band. All bets are off at Fs/2, and you can't include enough taps to get 90 degrees of delay at DC. What's more, there will be some amplitude ripple in the passband. Jerry -- "It does me no injury for my neighbor to say there are 20 gods, or no God. It neither picks my pocket nor breaks my leg." Thomas Jefferson to the Virginia House of Delegates in 1776. ��������������������������������������������������������������������� From: HardySpicer on 16 Apr 2010 01:47 On Apr 16, 4:43 pm, "cfy30" wrote:> Hi all, > > I am a newbie to Hilbert transform. I found the follow definition from > textbook > > H(f) = -j or -90degree, f>0 > H(f) =  j or +90degree, f<0 > H(f) =  0, f=0 > > But when I plot the phase out in Matlab, I saw that the phase is not > constant at -90 or +90degree across frequency. The code I have is as > follow > > b = firpm(10,[.1 .9],[1 1],'Hilbert') > w = linspace(-pi, pi, 2^12); > h = freqz(b, 1, w); > plot(w, angle(h)*180/pi); > > What do I miss? > > Cfy30 What wire are you using for your Hilbert Transformer? Beware of Eddie Current. Hardy From: steveu on 16 Apr 2010 01:49 >Hi all,> >I am a newbie to Hilbert transform. I found the follow definition from >textbook > >H(f) = -j or -90degree, f>0 >H(f) = j or +90degree, f<0 >H(f) = 0, f=0 > >But when I plot the phase out in Matlab, I saw that the phase is not >constant at -90 or +90degree across frequency. The code I have is as >follow > >b = firpm(10,[.1 .9],[1 1],'Hilbert') >w = linspace(-pi, pi, 2^12); >h = freqz(b, 1, w); >plot(w, angle(h)*180/pi); > >What do I miss? "Hilbert transform" is not an algorithm. Its a concept. Any algorithm you might use to realise a Hilbert transform is an approximation. It may work well over the central part of the band, but don't expect it work work well near the ends. Just a few terms for an FIR implementation of a Hilbert transform can give you pretty close to 90 degrees over a large part of the band. Don't expect a perfect brick wall transition from + to - 90 at DC, though. Its the amplitude response that is the greater problem. It takes a lot of terms to get that close to flat at low and high frequencies. Steve From: cfy30 on 16 Apr 2010 01:51 ...still don't understand. What I am observing is the phase change linearly with frequency! It is very clear when I plot(w, unwrap(angle(h))*180/pi); Cfy30 >On 4/16/2010 12:43 AM, cfy30 wrote: >> Hi all, >> >> I am a newbie to Hilbert transform. I found the follow definition from >> textbook >> >> H(f) = -j or -90degree, f>0 >> H(f) = j or +90degree, f<0 >> H(f) = 0, f=0 >> >> But when I plot the phase out in Matlab, I saw that the phase is not >> constant at -90 or +90degree across frequency. The code I have is as >> follow >> >> b = firpm(10,[.1 .9],[1 1],'Hilbert') >> w = linspace(-pi, pi, 2^12); >> h = freqz(b, 1, w); >> plot(w, angle(h)*180/pi); >> >> What do I miss? > >The phase is 90 degrees only over a limited band. All bets are off at >Fs/2, and you can't include enough taps to get 90 degrees of delay at >DC. What's more, there will be some amplitude ripple in the passband. > >Jerry >-- >"It does me no injury for my neighbor to say there are 20 gods, or no >God. It neither picks my pocket nor breaks my leg." > Thomas Jefferson to the Virginia House of Delegates in 1776. >��������������������������������������������������������������������� >  |  Next  |  Last Pages: 1 2 3 4 5 Prev: T1CMPR and CMPR1Next: MMSE & LMS Equalization Question