Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sign error for point to plane #9

Open
AdamSturge opened this issue Feb 4, 2017 · 3 comments
Open

Sign error for point to plane #9

AdamSturge opened this issue Feb 4, 2017 · 3 comments

Comments

@AdamSturge
Copy link
Collaborator

AdamSturge commented Feb 4, 2017

I think I've found a sign error in the equations for point to plane (and point to point if you don't use the closed form I guess). Specifically in the matrix A.

My point to plane wasn't working right, and on a hunch I tried inverting my rotation matrix R, which worked. So I decided to go though the details of the derivation and I think all the signs on the X columns in A are reversed. I changed them in my code and I didn't need to invert my rotation anymore.

That being said, the signs look correct in that they are equivalent to the base problem. Maybe the signs in the small rotation matrix are wrong?

@AdamSturge
Copy link
Collaborator Author

AdamSturge commented Feb 4, 2017

Or maybe our minimizer is actually maximizing the distance? And therefore the inverse rotation is (at least approximate to) the minimizer?

@AdamSturge
Copy link
Collaborator Author

Looking here is seems like the signs might indeed be flipped https://en.wikipedia.org/wiki/Rotation_matrix#Basic_rotations

for example with Rx you'd have -alpha on the last row and alpha in the second row, which is the opposite of what is in the ReadMe

@rin-23
Copy link
Collaborator

rin-23 commented Feb 6, 2017

I had the same problem. I think there is a mistake in the notes about computing closest rotation.
Notes have R = U sigmaV.transpose(). If you look at the notes i linked before U,V should be reversed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants