Let’s say that we’re given the standard basis vectors $\mathbf{i} = [1, 0, 0], ; \mathbf{j} = [0, 1, 0], ; \mathbf{k} = [0, 0, 1]$ and we multiply each of these vectors by an arbitrary matrix $\mathbf{M}$
The first row of $\mathbf{M}$ contains the result of performing a transformation on the vector $\mathbf{i}$, the second row is the result of transforming $\mathbf{j}$ and third row to $\mathbf{k}$
Let $\mathbf{v}$ be some vector expressed under this coordinate space which means that it can be represented as a linear combination of the basis
If we multiply this vector by the matrix $\mathbf{M}$
If we let $\mathbf{M}$ have the form
Then \eqref{vm} can be rewritten as
$\mathbf{vM}$ is a linear combination of the rows of $\mathbf{M}$, if we interpret these row vectors as the basis vectors of some coordinate system expressed/measured in terms of an outer coordinate system then we have successfully created a structure that encodes a space coordinate transformation (from object space to upright space) in the form of a matrix
Another way to see this is that $\mathbf{M}$ encodes in its rows a transformation made to the standard basis vectors $\mathbf{i}, \mathbf{j}, \mathbf{k}$
The following notation means the rotation matrix that transforms the frame $a$ to the frame $b$ and that is represented in the frame $c$
If the frame $c$ is equal to the frame $b$ then it can be omitted since it’s assumed that the matrix is represented in terms of the frame $b$
For example the matrix that transform from object space to upright space is represented as
Transforming the vector $\mathbf{v_{object}}$ expressed in object space to upright space is then
Row versus column vectors
A space coordinate transform operation has the form
Where $\mathbf{M}$ encodes in its rows a transformation made to the standard basis vectors and $\mathbf{v’}$ and $\mathbf{v}$ are row vectors
Let’s say that we want to transform a row vector by the matrices $\mathbf{A}$, $\mathbf{B}$ and $\mathbf{C}$ in that order, the operation is represented as
However it could be possible that $\mathbf{v}$ is instead a column vector, in that case also $\mathbf{v’}$ must be a column vector, for $\mathbf{v’}$ to have the correct result we must pre-multiply $\mathbf{v}$ by the transpose of the transformation matrix which is equivalent to transposing both sides of the equation
Note that
- the transformations matrices $\mathbf{A}^T$, $\mathbf{B}^T$ and $\mathbf{C}^T$ encode in their columns a transformation made to the standard basis vectors i.e. they have the form
In Dunn & Parberry’s book a column vector inside a matrix is written as
Also note that in this notation the arrow that connects the frames involved in the transformation is reversed, for example the transformation matrix that transform from object space to upright space is
In computer graphics column vectors should be used to represent points, differences between points and the likes