Suppose we have a image which is represented by a matrix

$ \begin{bmatrix} a & b & c \\ d & e & f \\ g & h & i \\ \end{bmatrix} $

and we want to find its correlation with another image:

$ \begin{bmatrix} 1 & 2\\ 3 & 4\\ \end{bmatrix} $

Now the correlation can be found by taking the mirrored matrix of the convolution of the 2 matrices.And we end up with a correlation coefficient which tells us how alike are the images.

Suppose we rotate the first image using the 3x3 rotation matrix and find the correlation coefficient between the rotated image and the above image.Now how much will the correlation coefficient change for a rotation at a angle $\theta$?Is there a minimum or a maximum?Can we calculate the function $f(\theta)$ which gives the percentage change in the correlation coefficient?

  • $\begingroup$ That would fully depend on both matrices. $\endgroup$ Sep 27, 2023 at 10:13
  • 1
    $\begingroup$ “the correlation can be found by taking the mirrored matrix of the convolution of the 2 matrices” No, it’s the convolution of one matrix with the mirror of the other. You have to mirror one of the inputs, not the output. $\endgroup$ Sep 27, 2023 at 14:21
  • $\begingroup$ @CrisLuengo youtube.com/watch?v=C3EEy8adxvc $\endgroup$
    – Cerise
    Sep 27, 2023 at 15:37
  • $\begingroup$ I didn't watch the video, but the equations shown at the start show exactly what I'm saying. The u and v have a minus in one input for the convolution but not for the correlation. That means that that input is mirrored in one operation wrt the other operation. The other input has the same signs for u and v in both operations, so that one doesn't get mirrored. $\endgroup$ Sep 27, 2023 at 16:08
  • 1
    $\begingroup$ He's talking about traversing the F input, not the output. $\endgroup$ Sep 27, 2023 at 16:40

1 Answer 1


which gives the percentage change

Since the minimum correlation coefficient is zero, but even in that case not rotation invariant, no such percentage can exist.

Is there a minimum or a maximum?

The minimum change is "no change", for rotational symmetry, the maximum, as described above is unbounded.

You will hence need look at your individual matrices, and calculate that function $f_{P,M}(\theta)$ for every pair of matrices $P$ and $M$ that you care about. Luckily, the correlation coefficient has a simple form (it's but a sum of products), and the rotation, too, so that you can just write that out, in case you plan to exploit any specific properties of the matrices that you might know.

  • $\begingroup$ You know what?I am asking this question because I believed that if we want to compare 2 images of apples and 1 of them is rotated , due to the rotation of the 1 image we could introduce a error margin on the maximum of $f_{P,M}(\theta)$.I am suprised it hasnt been studied extensively. $\endgroup$
    – Cerise
    Sep 27, 2023 at 16:38
  • $\begingroup$ nothing in my answer suggests this hasn't been studied extensively. In fact, rotation-invariant object recognition has been studied for probably around 50 years in practical terms, and for longer in theoretical terms! My answer is just giving you the basic math answers to your question. $\endgroup$ Sep 27, 2023 at 16:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.