The Matrix a must be a 4 X 4 matrix. So the 3D-point will be "lifted" to a 4D-Point by setting the fourth coordinate to 1. After the well-known matrix multiplication the coordinates are divided by the result in the fourth coordinate. In this way, it is for example possible, to transform a point by a matrix, which represents a perspectively projection.