Solution. The inner dimensions are both equal to , so we can do matrix-matrix multiplication. The outer dimensions are both , so our output will be a matrix. Through our linear combination of columns approach, we can find the resulting matrix through a column-by-column approach.
Let's begin with column 1. Let's start by creating a general plan for what we are going to compute.
Now that we have this in mind, let's plug in our values.
We continue this process for our column 2
and column 3
Putting our columns 1, 2, and 3 together, we get our final matrix-matrix product
Remark. We can check our answer using Octave with the following code:
A = [1, 2; 3, 4; 5, 6]
X = [1, 2, 3; 4, 5, 6]
B = A * X
Modify a single column of a matrix
Let a modeling matrix be
Suppose we wish to double column 1 of and leave the other columns untouched. In other words, we want to multiply by 2 and leave the other columns untouched.
What type of matrix would allow us to leave all other columns untouched?
To double column 1 and leave all other columns untouched, we multiply on the right by a 9.9 Dilation Matrix.
Dilation Matrix
Let natural number and scalar . For , we define an dilation matrix
Recall that a dilation matrix modifies the th value of the 8.6 Identity Matrix.
Since we are trying to double column 1 of our modeling matrix , we set and for our dilation matrix.
This is how our current setup would be written:
We use an dilation matrix because we want the output matrix to have to same dimensions as the input (recall that the outer dimensions define the dimensions of )
Finally, we can combine our results to form our output.
Based on this example, we can generalize a pattern for scaling the th column of matrix by the number . To scale the th column of , we multiply on the right by the dilation matrix .