Problem: Given \begin {align*} A & =[0,0,2,-1,3,7,1,2,-3,0,0]\\ B & =[0,0,1,-1,2,-2,4,1,-2,5,0,0] \end {align*}
Notice that the output sequence generated by Mathematica and Matlab are reversed with respect to each others.
Also, MATLAB uses the length \(2N-1\) as the length of cross correlation sequence, which in this example is 23 because \(N\) is taken as the length of the larger of the 2 sequences if they are not of equal length which is the case in this example.
In Mathematica, the length of the cross correlation sequence was 22, which is \(2N\).
Maple
a:=Array([0,0,2,-1,3,7,1,2,-3,0,0]); b:=Array([0,0,1,-1,2,-2,4,1,-2,5,0,0]); SignalProcessing:-CrossCorrelation(a,b);
\[ [ 7.0, 0.0, 33.0,- 14.0, 36.0, 19.0,- 9.0, 10.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0] \]
Not able to find out now why Maple result is different. May be definition used is different, no time now to find out.