next up previous
Next: i_affine_II Up: i_affine_II Previous: i_affine_II

0. Mapping one triangle to another with an affine transformation

First, consider the standard triangle in R$ ^
2$ whose vertices are $ (1,0)$, $ (0,1)$, $ (0,0)$, which we can call e$ ^ {(1)},$   e$ ^ {(2)},$   0. Let $ PQR$ be any triangle.



Problem 0.1 . Find the extended matrix of an affine transformation $ T$ that takes the standard triangle to the triangle $ PQR$ (with $ T($e$ ^ {(1)}) = P$, etc.). (See Figure [*].)

Figure: Standard triangle to a given triangle.
book/03dir/standard.eps

Solution. Let the triangle $ P' Q'$   0 be the result of translating the triangle $ PQR$ so that $ R$ goes to the origin, by subtracting $ R$ from all three vertices. Thus $ P' = P-R$ and $ Q' = Q-R$. The desired affine transformation consists of (1) a homogeneous linear transformation taking e$ ^ {(1)}$ to $ P' $ and e$ ^
{(2)}$ to $ Q' $, followed by (2) translation by $ R$. Because e$ ^ {(1)}$ and e$ ^
{(2)}$ are the standard basis vectors, the rows of the desired $ 2 \times 2$ matrix for (1) are just their images. Putting (1) and (2) together, we see that the desired transformation has extended matrix $ \left[\begin{array}{cc}(P-R)&0\\  (Q-R)&0\\  R&1\end{array}\right]$ (to use an obvious shorthand notation). (See Figure [*].)

Figure: Standard triangle to a given triangle: solution
book/03dir/solution.eps

For example, to map the standard triangle to the triangle with vertices $ (2,1), (4,3), (2.5,4)$, the extended matrix is $ {\left [\begin{array}{ccc} -.5&-3&0\\
1.5&-1&0\\  2.5&4&1 \end{array} \right ] }$.



(To check that this matrix works, try multiplying the extended vertices $ (1,0,1)$, $ (0,1,1)$, $ (0,0,1)$ by it.)



Problem 0.2 . Find how to calculate the extended matrix of an affine transformation $ U$ that takes the triangle $ PQR$ to the triangle $ P' Q' R' $ (with $ U(P) = P' $, etc.). (See Figure [*].)

Figure: Arbitrary triangle to arbitrary triangle
book/03dir/triangle.eps

Solution. Use the standard triangle as an intermediate stage. You know how to find $ T$ taking the standard triangle to $ PQR$ and $ T' $ taking the standard triangle to $ P' Q' R' $. $ T ^ {-1}$ takes $ PQR$ back to the standard triangle. Therefore $ U = T ^ {-1} T' $, so that $ U$ has extended matrix

$ \left[\begin{array}{cc}(P-R)&0\\  (Q-R)&0\\  R&1\end{array}\right]
^ {-1} \left[\begin{array}{cc}(P' -R')&0\\  (Q' -R' )&0\\  R' &1\end{array}\right]$.



(For a specific example you could put in numbers and multiply out. If $ P,Q,R$ are noncollinear, so that $ PQR$ is a genuine triangle, then the left matrix will be invertible as required. Computationally, one way to calculate a product $ A ^ {-1} B$ is to write down an extended matrix $ [A \vert B]$ and row-reduce it to get a matrix $ [I \vert C]$; here $ C$ will be $ A ^ {-1} B$.)



Note. In R$ ^ 3$, you can use the same sort of method to move a tetrahedron to a tetrahedron.




next up previous
Next: i_affine_II Up: i_affine_II Previous: i_affine_II
Kirby A. Baker 2002-01-23