# Transforming a 3x3 Covariance Matrix to 2x2

Hello friends of the robotics,
for Data Association I have the Robots cov matrix in a 3x3 Form, but the measurements and landmarks only in 2x2. I want to compute the Mahalanobis distance, so how translates a 3x3 Cov Matrix (x,y,theta) to 2x2 (x,y) ? Just making the landmarks and measurements 3x3 results in a too small Mahalanobis Distance.

• You'll need the equation the generates the (x,y) measurement. Do you have that? Aug 16 '20 at 16:00
• You need to be a bit more clear on what exactly you want. If you are just trying to convert the covariance matrix of(x,y,theta) to (x,y) then you just need to remove the rows and columns related to the theta term. No extra work needs to be done. That is the nice advantage of the covariance form(seas.harvard.edu/courses/cs281/papers/mackay-2006.pdf) Aug 16 '20 at 19:58
• That's true as long as errors in theta don't affect the landmark position measurement. Aug 17 '20 at 19:47
• Actually no. It is true even if cross covariances are non zero(theta is correlated with landmark position). As explained in the linked PDF. Aug 18 '20 at 6:27