Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have 2 sets of 3 points: the "origin" and "destiny". Any ideas on how to find the best-fit transformation matrix that will convert the origin's points to destiny using (only) rotation, scaling and translation?

I know a way to solve that, which is creating a function that applies the 3 transformation to the origin points and calculate the distance of them to the destiny points; then I minimize this function. Any easier way?

share|cite|improve this question
up vote 0 down vote accepted

A simple way to do this would be to canonicalize both triangles and then concatenate the transform that canonicalizes the "origins" with the inverse of the one that canonicalizes the "destinies".

For instance, a) apply a translation to move the point in the first pair to the origin; b) apply a rotation about an axis through the origin to move the point in the second pair onto the $z$-axis; c) apply a rotation about the $z$-axis to move the point in the third pair into the $y$-$z$-plane with non-negative $y$ coordinate. That moves all congruent triangles with identically numbered points into the same position.

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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