ifrah jaffri
Newbie level 6
Is there any relation between correlation between two signals and dot product between two
vectors?
vectors?
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
x1 = [0;1;-1];
x2 = [-2;1;1];
sum(x1)
sum(x2)
covariance = (x1 - mean(x1)).'*(x2 - mean(x2));
variance1 = sum(abs(x1 - mean(x1)).^2);
variance2 = sum(abs(x2 - mean(x2)).^2);
correlation = covariance/sqrt(variance1*variance2)
x1.'*x2