You are here: Symbol Reference > Dew Namespace > Dew.Math Namespace > Classes > TVec Class > TVec Methods > TVec.CrossCorr Method
Dew Math for .NET
ContentsIndexHome
PreviousUpNext
TVec.CrossCorr Method

The cross-correlation of two vectors.

Syntax
C#
Visual Basic
public TVec CrossCorr([In] TVec Vec1, [In] TVec Vec2, int HiLag, int LoLag, TCorrNorm CorrelationNorm, [In] TVecInt Buffer);

Calculate the cross-correlation of two vectors Vec1 and Vec2. The parameter HiLag indicates the top of the range of lags at which the correlation estimates should be computed. The parameter LoLag indicates the bottom of the range of lags at which the correlation estimates should be computed. The results are stored in calling vector. The resulting elements are defined by the equation: 

 

 

The Buffer parameter allows the same work memory to be used between consecutive calls to this and other functions. The Buffer object will not be resized, if sufficient memory is present.

var a,b,c: TVec; begin CreateIt(a,b,c); a.SetIt(False,[1,-2,3,4]); b.SetIt(False,[2,-2,3,4]); c.CrossCorr(a,b,2,2); FreeIt(a,b,c); end;
Copyright (c) 1999-2024 by Dew Research. All rights reserved.
What do you think about this topic? Send feedback!