# Thread: Matrix of a Composite

1. ## Matrix of a Composite

$\displaystyle f(x) = Ax$
$\displaystyle g(x) = Bx$

First we do the f and then the g, which is written g 0 f. So the final matrix is BA. So why is the first matrix transformation written and done last?

2. Originally Posted by mark090480
$\displaystyle f(x) = Ax$
$\displaystyle g(x) = Bx$

First we do the f and then the g, which is written g 0 f. So the final matrix is BA. So why is the first matrix transformation written and done last?
Because BA operates on whatever is to the right of it.

3. I'm not sure if I understand. Can you explain a bit more?

4. f(x) means that the function f is applied to the number x that is to its right. g(f(x)) means that g is applied to f(x), to its right. Ax means the matrix A is multiplied by the vector x to its right. BAx means that the matrix B is multiplied by the vector Ax to its right. If f(x)= Ax and g(x)= Bx then g(f(x))= g(Ax)= B(Ax)= BAx.

5. Thanks, It was easier than I thought.

6. Originally Posted by mark090480
$\displaystyle f(x) = Ax$
$\displaystyle g(x) = Bx$

First we do the f and then the g, which is written g 0 f. So the final matrix is BA. So why is the first matrix transformation written and done last?
Because $\displaystyle (g \circ f)(x)$ means $\displaystyle g(f(x))=g(Ax)=B(Ax)=BAx$

CB