class Point3Matrix
{
public:
double matrix[9];
Point3Matrix compose(const Point3Matrix& b)
{
Point3Matrix ret;
for (int outx = 0; outx < 3; outx++)
{
for (int outy = 0; outy < 3; outy++)
{
ret.matrix[outy * 3 + outx] = 0;
for (int in = 0; in < 3; in++)
{
ret.matrix[outy * 3 + outx] += matrix[outy * 3 + in] * b.matrix[in * 3 + outx];
}
}
}
return ret;
}
}
What does the compose
function do? I can only deduct it is doing a row x col operation for two matrices.