10
votes
What is the difference between convolution and cross-correlation?
As a student I was involved in the same problem as you are.
Let me explain to you in the simplest words without any math.
Convolution:
It is used to convolve two functions. May sound redundant but I'...
7
votes
Accepted
Auto Correlation vs Cross Correlation vs Convolution and their applications
I can tell you of at least three applications related to audio.
Auto-correlation can be used over a changing block (a collection of) many audio samples to find the pitch. Very useful for musical and ...
7
votes
Accepted
How to calculate a delay (correlation peak) between two signals with a precision smaller than the sampling period?
This is basically what @hooman suggests: fit a parabola to the three points near the peak of the sample cross-correlation of the data.
Using the formula for $p$ from Julius O. Smith - Peak Detection:
$...
7
votes
Accepted
perfect sequences
Let $\theta_a$ and $\theta_c$ respectively denote the maximum magnitudes of the off-peak or out-of-phase periodic autocorrelation functions and the periodic crosscorrelation functions of a set of $K$ ...
7
votes
Comparing multiple signals for similarity
...best results come from a weighted ensemble of techniques...
Maybe they do, depending on the application. But each one of the similarities mentioned, is equivalent to the other at least when we are ...
7
votes
Accepted
Correlation of independent random processes
No. Quoting Wikipedia's article Independence (probability theory):
If $X$ and $Y$ are independent random variables,
then the expectation operator $\operatorname{E}$ has the property
$$\...
Community wiki
6
votes
Accepted
Python - Normalized cross-correlation to measure similarites in 2 images
I guess you can compute for each pixel the correlation coefficient between patches centered on this pixel in the two images of interest. Here is an example where I downloaded the figure attached here ...
6
votes
Accepted
Cross correlate a 2D array
What you have (conceptually) is not a 2D array but a collection of 1D arrays. correlate2D is designed to perform a 2D correlation calculation, so that's not what ...
6
votes
Accepted
Cross correlation, when two signals are "uncorrelated"?
Cross correlation is a measure of similarity between two signals, where one signal is allowed to be time-shifted. In this sense, the correlation is not a single number, but a function of the time ...
6
votes
Accepted
Matched filter and cross correlation in digital processing
I'll illustrate with an example: detecting a rectangular pulse in noise, in Matlab.
Let's start with defining the signal that contains the pulse.
...
6
votes
Cross-correlation seems defined backwards
Interesting question. For purposes of "pattern matching" the resulting peak of the auto-correlation function will either be consistent with the actual time offset between the matching ...
6
votes
How to decide whether a recording contains a signal of interest?
Is it possible to decide based on the result of the cross-correlation whether a recording contains the signal of interest?
Certainly. The easiest way would be look at the crest factor (peak to RMS ...
6
votes
2D Cross-Correlation using 1D FFT
Your 2nd step is wrong, it's doing circular convolution. For circular cross-correlation, it should be:
Multiplication between the output of the FFT applied on the first vector and the conjugate of ...
6
votes
Is 2D circular cross-correlation with FFT done as described in this source?
For the question's approach of shifting the h input image spatially using ifftshift before frequency-domain complex-conjugation, ...
5
votes
Accepted
How is cross-correlation related with orthogonality?
I suppose you mean the cross-correlation at lag zero. Well take an Hilbert space $H$ (i.e. a metric space in which you can define a scalar product $\langle\cdot ,\cdot\rangle$). Then $x,y\in H$ are ...
5
votes
Accepted
Cross-correlation or cross-covariance of non-zero mean signals
What are reasons to choose for cross-correlation or cross-covariance when comparing signals with non-zero mean?
Well, part of the issue is that cross-correlation as defined in your equation:
$$(f \...
5
votes
How can define an indicator which measures the degree of similarity between two signals?
The general topic of finding similarities between signals is wide ranging:
are the signals of same sampling, length, offset, shift or scale?
where do they take their values (discrete, real, complex)?...
5
votes
How to calculate a delay (correlation peak) between two signals with a precision smaller than the sampling period?
Lagrange parabolic estimator
The standard Lagrange polynomial parabolic interpolation peak finding formula from Peter's answer,
$$p = \frac{1}{2} \frac{\alpha - \gamma}{\alpha - 2\beta + \gamma}$$
...
5
votes
When to use cross spectral density versus cross correlation?
The cross-spectral density is in the frequency domain while the cross-correlation function is in the time domain. The two are Fourier Transform pairs, the FT of the cross correlation function is the ...
5
votes
Understanding time delay estimation for GPS?
For GPS, (simplifying for now by omitting corrections for ionsphere and orbit position and relativistic clock offsets), we determine the "Pseudo-range" to each satellite (SV), which will be the ...
5
votes
Accepted
Maximum cross-correlation coefficient value for time delay estimation
As your plot shows, the second form allows for the correlation peak to be negative. Now, what does a strong negative cross correlation mean? It means the signals are very similar, except one has a ...
5
votes
Accepted
How to reliably compute the group delay of a comb filter
Since this is an FIR, the group delay is D=(N-1)/2=20 samples.
No, since this is a linear phase (i.e. symmetric or anti-symmetric) filter, the group delay is half the length! (being a FIR isn't ...
5
votes
Accepted
Confusion In DC power,Average Power,Ac Power and total Power
What you have studied doesn't seem to include a definition of Average Power. For deterministic signal $x(t)$, the instantaneous power delivered at time $t$ is $x^2(t)$ ${\big (}$yeh, yeh, nitpickers ...
4
votes
Detecting a Signal Inside a Time Series Using MATLAB's $ \tt xcorr() $
It is usually useful to use normalized cross-correlation for finding position of small template on other longer signal. The value of normalized cross-correlation coefficient is invariant to change of ...
4
votes
Signals cross-correlation
When using a constant tone audio beacon, beware of room echoes causing multi-path interference and distortion, especially around the leading and trailing portions of your received waveforms.
Try ...
4
votes
Accepted
How can define an indicator which measures the degree of similarity between two signals?
assuming finite power signals:
$$ \lVert x \rVert^2 \triangleq \lim_{N \to \infty} \ \frac{1}{2N+1} \sum\limits_{n=-N}^{+N} \big|x[n] \big|^2 \ < +\infty $$
this is a Hilbert Space sorta thingie.
...
4
votes
How can define an indicator which measures the degree of similarity between two signals?
if you are searching for similarity between two signals in frequency domain, you can go for coherence. Coherence indicates frequency components common to both signals
4
votes
How to calculate a delay (correlation peak) between two signals with a precision smaller than the sampling period?
You can fit a curve to the points around the peak of the cross-correlation obtained by xcor and find the peak of the fitted curve. Ideally, you know the cross-correlation function of your signals and ...
4
votes
Accepted
Correlation as measure of similarity
As you correctly noted, similarity is not a rigorously defined mathematical term. However, "distance" can be defined mathematically. Quoting Wikipedia:
In statistics and related fields, a ...
4
votes
Cross correlation, when two signals are "uncorrelated"?
The cross-correlation function $R_{x,y}(\tau)$ of two deterministic finite-energy signals $x(t)$ and $y(t)$ can be defined as
$$R_{x,y}(\tau) = \int_{-\infty}^\infty x^*(t)y(t+\tau) \,\mathrm dt,~-\...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
cross-correlation × 408matlab × 67
autocorrelation × 57
fft × 52
correlation × 43
discrete-signals × 39
signal-analysis × 37
image-processing × 32
convolution × 30
fourier-transform × 26
audio × 25
delay × 25
noise × 18
python × 17
power-spectral-density × 17
filters × 14
estimation × 14
signal-detection × 12
synchronization × 12
digital-communications × 11
statistics × 11
matched-filter × 11
frequency-spectrum × 10
random-process × 10
template-matching × 10