In signal processing, cross-correlation is a measure of similarity of two series as a function of the displacement of one relative to the other. This is also known as a sliding dot product or sliding inner-product. It is commonly used for searching a long signal for a shorter, known feature. It has applications in pattern recognition, single particle analysis, electron tomography, averaging, cryptanalysis, and neurophysiology.
For continuous functions f and g, the cross-correlation is defined as:
where denotes the complex conjugate of , and is the displacement, also known as lag, although a positive value of actually means that leads .