dcomplexarr and phase [message #79540] |
Tue, 06 March 2012 02:41 |
zolile mtumela
Messages: 50 Registered: September 2011
|
Member |
|
|
Hi all
I got a program that is running here, In this program I want to use
dcomplexarr function on filterdata:
my data:
Ny=360
T=20
naqy_array = naqy_array =(naqy_array)*(hanning(360))
timefilter = Digital_Filter(f_low*2*T,f_high*2*T,50,floor((Ny)/2))
;freqfilter=fft(timefilter)
nfreq=ntime/2
freq=findgen(nfreq)/(ntime*T)
freqfilter=fft(timefilter,/double)*ntime
filterdata=fft(naqy_array,/double)*freqfilter
inv_spec =fft(spec,/double,/inverse)
plot,abs(inv_spec)
phi = atan(inv_spec)
plot,phi
I need some help on the ff difficulties
I want to use dcomplexarr on filterdata so that it returns as
complex , But I dnt how?
calculate the phase angle, I dnt know if im done correctly and I would
like to calculate the amplitude
sqrt(float(inv_spec)^2 + imaginary(inv_spec)^2)
Its allowed to use inverse.
thank you in advance for ur time
Zolile
|
|
|