# General form of a linear transformation

Let $v_1 = \begin{bmatrix} 2 \\ -1 \end{bmatrix}$ and $v_2=\begin{bmatrix} 1 \\ -1 \end{bmatrix}$ and let $A= \begin{bmatrix} 3 & 2 \\ -2 & 1 \end{bmatrix}$ be a matrix for $T\colon \Bbb R^2\to \Bbb R^2$ relative to the basis $B = \{v_1, v_2\}$.

From this I found that: $T(v_1) = \begin{bmatrix} 4 \\ -1 \end{bmatrix}$ and $T(v_2) = \begin{bmatrix} 5 \\ -3 \end{bmatrix}$

How would I find a formula for $T\begin{pmatrix} \begin{bmatrix}x_1 \\ x_2\end{bmatrix} \end{pmatrix}$. The answer in my book is $\begin{bmatrix} -x_1-6x_2 \\ 2x_1+5x_2 \end{bmatrix}$

• Welcome! Is your question about math in general or about Mathematica? Nov 16, 2013 at 20:26

Given vectors $\;v_1, v_2, Tv_1, Tv_2$:

{ v1,  v2} = {{2, -1}, {1, -1}};
{Tv1, Tv2} = {{4, -1}, {5, -3}};


This is a direct way of solving underlying linear system:

With[{ m = Array[a, Dimensions[{v1, Tv1}]]},
m.Subscript @@@ {{x, 1}, {x, 2}} /.
Solve[ m.#1 == #2 & @@@ {{v1, Tv1}, {v2, Tv2}}, Join @@ m] //

Transpose[{Tv1, Tv2}].Inverse @ Transpose @ {v1, v2}.{x, y} // MatrixForm

where we put {x, y} instead of Subscript @@@ {{x, 1}, {x, 2}}.
These both ways are easily applicable to higher dimensional problems involving appropriate numbers of vectors, such that $\;v_1, \dots, v_n\;$ and $\;Tv_1, \dots, Tv_n$ satisfy:
Det @ { v1, ..., vn} != 0 and Det @ { Tv1, ..., Tvn} != 0