Make more use of matrix operations to transform coordinate vectors, and ultimately remove the old transform functions.