3
$\begingroup$

I am given the $3$-D coordinates of two triangles. For example:

  • for $\triangle ABC$, the coordinates are: $A=(0, 0, 0)$, $B= (3.37576, 0, 0)$, $C=(5.14131, -2.47202, 0)$

and

  • for $\triangle DEF$ the coordinates are: $D=(0, 0, 0)$, $E(3.73345, 0, 0)$, $F=(7.06825, -3.44094, 0)$.

How to calculate the transformation matrix between two triangles?

Any help will be largely appreciated!

  • 2
    Do you see that both triangles lie in the x-y coordinate plane? (i.e., both triangles are, essentially, in 2-dimensions), Each with a vertex at the origin (A, D), and each with one side lying along the x-axis, overlapping (side DE a bit longer than side AB?), and each lying in the same quadrant?2011-05-31

1 Answers 1

1

This particular case is rather simple. Note:

$$\frac{3.73345}{3.37576} \approx 1.105958,$$

$$\frac{7.06825 - 5.14131\times 1.105958}{-2.47202} \approx -0.559128, \text{ and}$$

$$\frac{-3.44094}{-2.47202} \approx 1.391958.$$

so giving a solution of

$$ \left( \begin{array}{ccc} 1.105958 & -0.559128 & c \\ 0 & 1.391958 & f \\ 0 & 0 & i \end{array} \right)$$

where $c$, $f$ and $i$ can take any values because, as amWhy noted, you only have information about the x-y plane. In general it will be slightly more complicated.

  • 0
    Hi thanks for the detailed answer! Can you please explain the math behind this calculation? What are the rotation and translation component of the given solution?2011-06-01
  • 0
    @Irina: there is no translation component (the origin stays at the origin), and the transformation is not a rotation (the two triangles have different areas and different shapes). So you need to move B to E along the $x$-axis and move the $x$ and $y$ components of C to the components of F.2011-06-01
  • 0
    @Henry: So what does the resultant matrix represent?2011-06-02
  • 0
    @Irina: it is a linear transformation.2011-06-02
  • 0
    Does it mean if I apply this linear transformation on each point of triangle DEF, will DEF fall on ABC?2011-06-02
  • 0
    No - the reverse. This transformation takes ABC to DEF. You would need the inverse (at least as it applies to the $xy$ plane) to get back.2011-06-02
  • 0
    I forgot to mention another thing is that the shape and the area of the triangle should be retained. After applying this transformation on DEF I figured that it becomes the same triangle as ABC.2011-06-02
  • 0
    The two triangles are not the same shape, nor the same area.2011-06-02
  • 0
    Hi Henry thank you so much for your help. I plotted the two triangles after transformation and they are as I expected. Can you suggest me a good link for the linear transformation with examples like this?2011-06-02
  • 0
    You could try [Wikipedia on matrices and linear transformation](http://en.wikipedia.org/wiki/Matrix_%28mathematics%29#Linear_transformations) and links from that article2011-06-02