Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #12377

correlation function

From jure lapajne <lapajne.jure@gmail.com>
Newsgroups comp.soft-sys.math.mathematica
Subject correlation function
Date 2012-11-18 09:06 +0000
Message-ID <k8a8el$8bj$1@smc.vnet.net> (permalink)
Organization Time-Warner Telecom

Show all headers | View raw


Hello,
I'm having hard time calculating correlation (autocorrelation) function of 
two lists (list). I'm trying two different ways of calculating it. One way 
is to use fourier transform and second way is to use Mathematica's function
 ListCorrelate. I get different results but have no idea why. Here's my code:

korelacija1 = ListCorrelate[data, data, {1, 1}];
korelacija11 = Abs[InverseFourier[Abs[Fourier[data]]^2]];

All elements of "data" are real. I have two Abs in second line because for some reason InverseFourier returns small imaginary parts - I know it shouldn't. It's probably only numerical error.

Thanks for help.

Back to comp.soft-sys.math.mathematica | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

correlation function jure lapajne <lapajne.jure@gmail.com> - 2012-11-18 09:06 +0000
  Re: correlation function jure lapajne <lapajne.jure@gmail.com> - 2012-11-18 22:21 +0000
    Re: correlation function "Nasser M. Abbasi" <nma@12000.org> - 2012-11-19 22:04 +0000

csiph-web