| Description | The autocorrelation function (ACF) of X is calculated and stored in Y in wrap-around order: Y0 to Ysize/2-1 contain the ACF for zero and positive lags. Beginning with the most negative lag in Ysize/2+1, the elements up to Ysize-1 contain the ACF for negative lags. Since this function assumes X to be periodic, the ACF for the most positive lag is identical to the ACF for the most negative lag. This element is stored as Ysize/2.
To get the ACF into normal order, you may call
VF_rotate( Y, Y, size, size/2 );
After that, the zero point is at the position size/2.
In case X is non-periodic, you should avoid end effects by the methods described in connection with VF_convolve.
About special versions with the prefixes VFp_, VFs_ and VFl_, consult chapter 4.8. |