Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Idl-pvware > Re: How to perf...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 5 of 16 Topic 5383 of 6252
Post > Topic >>

Re: How to perform the 1-D signal filter?

by "duxiyu@[EMAIL PROTECTED] " <duxiyu@[EMAIL PROTECTED] > Feb 1, 2008 at 06:54 AM

Thank you very much.
But I still have some questions about the parameters in the procedure
Digital_Filter.

Result = DIGITAL_FILTER( Flow, Fhigh, A, Nterms [, /DOUBLE] )

In the example, you set A=50 and Nterms=40 and I do not know where
their values come from and how I get them.


Seondly, I want to know the relation between the filter in time and
frequency domain.
if the following command is excuted, I think newfsignal is exactly
equal to fft(newsignal), isn't it?
"newsignal=convol(signal,timefilter)
 fsignal=fft(signal)
 newfsignal=fsignal*freqfilter"
And I also do not konw why you set steep=20.

Du



On Feb 1, 9:27 pm, Wox <nom...@[EMAIL PROTECTED]
> wrote:
> On Fri, 1 Feb 2008 02:20:52 -0800 (PST), "dux...@[EMAIL PROTECTED]
"
>
>
>
> <dux...@[EMAIL PROTECTED]
> wrote:
> >Dear all,
>
> >Here I give a signal example and hope somone can show me how to
> >perferm the frequency filter on it.
>
> >;creat a signal data with two peaks in frequency domain at 2 and 3 Hz.
> >t=findgen(1000)/10.
> >data=sin(2*!pi*2*t)+sin(2*!pi*3*t)
>
> >freq=findgen(501)/100.
> >v=fft(data)
> >plot,freq,abs(v[0:500])^2,xtitle='frequency',ytitle='spectrum'
>
> >I want to filter the signal with the frequency higher than 2.5 Hz. How
> >do I do this?
>
> >I have read the help files about Digital_Filter and Convol, but I do
> >not know how to select the parameters for Signal_Filter.
>
> >Du
>
> Example below filters in time or frequency domain:
>
> ; Time domain
> freq1=2.
> freq2=3.
> freq3=4.
> dtime=0.1
> ntime=1000
>
> time=dtime*findgen(ntime)
> signal=sin(2*!pi*freq1*time)+sin(2*!pi*freq2*time)+sin(2*!pi*freq3*time)
>
> ; Time domain Filter
> f_low = 0
> f_high = 2.5
> timefilter = DIGITAL_FILTER(f_low*2*dtime, f_high*2*dtime, 50.,40)
> signal=convol(signal,timefilter)
>
> ; Frequency domain
> nfreq=ntime/2+1
>
> freq=findgen(nfreq)/(dtime*ntime)
> fsignal=fft(signal)
>
> ; Frequency domain filter (instead of time domain filter)
> if n_elements(timefilter) eq 0 then begin
>         steep=20.
>         freqfilter= 1./(1.+(freq/f_high)^steep)
>         fsignal*=freqfilter
> endif
>
> plot,freq,abs(fsignal[0:nfreq-1])^2,xtitle='frequency',ytitle='spectrum'
 




 16 Posts in Topic:
How to perform the 1-D signal filter?
"duxiyu@[EMAIL PROTE  2008-02-01 02:20:52 
Re: How to perform the 1-D signal filter?
Wox <nomail@[EMAIL PRO  2008-02-01 14:27:59 
Re: How to perform the 1-D signal filter?
David Fanning <news@[E  2008-02-01 07:16:26 
Re: How to perform the 1-D signal filter?
Wox <nomail@[EMAIL PRO  2008-02-01 18:16:30 
Re: How to perform the 1-D signal filter?
"duxiyu@[EMAIL PROTE  2008-02-01 06:54:42 
Re: How to perform the 1-D signal filter?
Wox <nomail@[EMAIL PRO  2008-02-01 17:57:33 
Re: How to perform the 1-D signal filter?
"Kenneth P. Bowman&q  2008-02-01 08:58:38 
Re: How to perform the 1-D signal filter?
David Fanning <news@[E  2008-02-01 11:30:29 
Re: How to perform the 1-D signal filter?
"Kenneth P. Bowman&q  2008-02-01 17:27:02 
Re: How to perform the 1-D signal filter?
David Fanning <news@[E  2008-02-01 18:07:17 
Re: How to perform the 1-D signal filter?
"duxiyu@[EMAIL PROTE  2008-02-02 07:14:05 
Re: How to perform the 1-D signal filter?
"duxiyu@[EMAIL PROTE  2008-02-02 07:20:22 
Re: How to perform the 1-D signal filter?
jdu.ustc@[EMAIL PROTECTED  2008-02-02 11:27:47 
Re: How to perform the 1-D signal filter?
Wox <nomail@[EMAIL PRO  2008-02-04 10:28:58 
Re: How to perform the 1-D signal filter?
jdu <jdu.ustc@[EMAIL P  2008-02-04 08:48:08 
Re: How to perform the 1-D signal filter?
jdu <jdu.ustc@[EMAIL P  2008-02-04 08:48:32 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Oct 11 16:18:14 CDT 2008.