PrepShorts · Study sheet · Class 12 Mathematics · Chapter 3, MatricesPrepShorts

Chapter 3 · Matrices

Row into column: why multiplication needs the inner orders to match

The algebra of matrices18 min

This video could not be loaded. Reload the page to try again.

Sign in with Google

18 min.

Two of the four numbers in a pair of orders meet in the middle, and two never meet anything. The inner pair decides whether a product exists; the outer pair IS the answer's order. Of the 256 ordered pairs of orders up to four by four, only 64 have a product - and the three rules students actually reach for get 72, 96 and 108 of them wrong.

The idea

This is the first operation in the chapter that is not computed position by position, and every difficulty in it follows from that. One entry of a product consumes a whole row of the left matrix and a whole column of the right one, so the two have to be the same length — which is a condition on the inner pair of the four numbers in the two orders, while the outer pair survives untouched into the answer. The shopping bill the chapter opens with is worth all the time it takes, because it is the only place in the chapter that explains where the sum comes from: a bill is quantity times price, added over the items, and that sum is the definition. Get that across and the summation formula is a transcription rather than a new idea.

What you should be able to do

  • Explain where the sum of products in a matrix product comes from, using a quantities-against-prices situation
  • State the condition under which a product is defined, in terms of the two orders
  • Predict the order of a product without computing any entry
  • Compute one named entry of a product by pairing a row against a column
  • Compute a whole product of small matrices, keeping the intermediate sums visible
  • Read and use the summation form of the entry definition, naming what the index runs over
  • Decide, from orders alone, which of a list of matrix expressions are defined
  • Handle products involving a single row or a single column, including one that collapses to a single number
  • Interpret the entries of a product in an applied setting, saying what each one counts

Words to know

TermDefinition in one lineFirst introduced
productthe matrix built by pairing each row of the left factor against each column of the rightprinted in this chapter (§3.4.5, Part I p. 51, set in italic where it is first defined)
definedsaid of a product the rule actually produces, as against one it refusesprinted in this chapter (§3.4.5, Part I p. 51, italic in the defining sentence)
elementwisesaid of a pairing that multiplies matching members of a row and a columnprinted in this chapter (§3.4.5, Part I p. 51 — the only two occurrences in the chapter, both about this operation)
orderthe pair of counts that decides whether a product exists and what shape it hasprinted in this chapter (§3.2.1, Part I p. 36, and used throughout §3.4.5)
rowthe strip of the left factor consumed by one entry of the productprinted in this chapter (§3.2, Part I p. 36, and throughout §3.4.5)
columnthe strip of the right factor consumed by one entry of the productprinted in this chapter (§3.2, Part I p. 36, and throughout §3.4.5)
inner pairthe two counts that meet at the join and must agreean added term; the chapter states the condition in words and gives the two numbers no collective name
outer pairthe two counts that survive into the order of the answeran added term; not printed
dot pairingone row met with one column, multiplied along and added upan added shorthand; the chapter describes the operation in a full sentence each time and never names it

Where people slip up

  • "Multiply matrices the way you add them, position against position." That operation exists in mathematics and is not this one. An entry of this product is a sum over a whole row and a whole column, and nothing about the answer's entry at a position depends on the two factors' entries at that position alone.
  • "The two matrices must have the same order." They must have matching inner counts. A two by three times a three by four is fine; a two by three times a two by three is not defined at all.
  • "If the product exists one way it exists the other way." Not in general. The chapter states the exact condition for both to exist and it is two equations, not one. This is the hinge into the next topic.
  • "The answer has the order of the bigger matrix." The answer takes the outer counts: rows from the left factor, columns from the right. Predict it before computing, every time.
  • "A row times a column and a column times a row are the same thing." One collapses to a single entry, the other expands to a full square array. Exercise 3.2 Q3(ii) and Miscellaneous Exercise Q4 sit on opposite sides of this and both should be shown.
  • "The summation formula is a new definition." It is the same sentence written with a sigma. Show the sum of n products written out and the sigma form on the same screen.
  • "Ten dozen books is ten books." Exercise 3.2 Q20 is a unit-conversion trap wearing a matrix costume; the conversion happens before the product is formed.
  • "An applied product's entries are just numbers." In the manufacturer item each entry is a revenue or a cost for a named market, and a student who cannot say which has not finished the question.
Transcript2,534 words

Two friends walk into a shop. A pen costs five, a notebook costs fifty. The first wants two pens and five notebooks. The second wants eight pens and ten notebooks. You already know how to work out the first bill. Two pens at five is ten. Five notebooks at fifty is two hundred and fifty. Two hundred and sixty altogether. Now write it down without adding it up yet. The first bill is two times five, plus five times fifty. The second is eight times five, plus ten times fifty.

That unresolved column is the whole of what follows. Each bill is a product plus a product: quantity times price, added over the items. Put the wants in a two by two arrangement and the prices in a column of two, and what you just wrote down is a column of two bills. Two hundred and sixty, and five hundred and forty. Nothing new has happened. A bill has always been a sum of products, and that sum is going to be the definition.

Now a second shop, where the pen costs four and the notebook forty. Ask the same question and you get two more bills: two hundred and eight, and four hundred and thirty-two. Here is the step worth watching. Put the two price lists side by side, as the two columns of one arrangement. The answer gains a column and nothing else changes. The first column of bills is exactly what the first price list already gave you, entry for entry, and the second column is exactly what the second one gave you.

So the columns of the right-hand arrangement are handled independently. Each one produces one column of the answer, and it never looks at the others. That is why the rule can be stated once, for one row against one column, and then simply repeated. Write the two orders down in a line. The left arrangement is two by two, the right one is two by two. Four numbers. Two of them meet in the middle. The number of columns on the left, and the number of rows on the right.

They have to agree, and the reason is not a convention. One entry of the answer consumes a whole row of the left arrangement and a whole column of the right one, and pairs them off. If the row is longer than the column, something is left holding nothing. So the condition is on the inner pair. Call it that, because you are going to check it every single time before you compute anything.

Put a number on how much that condition rules out. Take every order from one by one up to four by four, sixteen of them, and every ordered pair of those, two hundred and fifty-six. Sixty-four of those pairs have a product. The other hundred and ninety-two have none at all. Now test three rules students actually use. The two orders being the same gets seventy-two of the two hundred and fifty-six wrong. The outer counts agreeing gets ninety-six wrong. Some count of one matching some count of the other gets a hundred and eight wrong.

Not one of the three is right, and the inner-pair rule is right in all two hundred and fifty-six. The other two of the four numbers, the outer pair, never meet anything. They survive. Rows of the answer come from the left arrangement. Columns of the answer come from the right one. In all sixty-four cases where a product exists, the answer's order is exactly the outer pair, with no exceptions.

Which means you can say the shape of the answer before you do any arithmetic at all, and you should, every time. A two by three against a three by four: the inner pair is three and three, so it exists, and the answer is two by four. A two by three against a two by three: the inner pair is three and two. No product. And these two have the same order, which is the point.

One more thing that count tells you. Of the two hundred and fifty-six pairs, only sixteen have a product both ways round, and of those sixteen, only four give two answers of even the same order. Existing one way is not existing the other. So: one entry of the answer, in full. Take a two by three holding one, minus one and two on the top row, zero, three and four on the bottom. And a three by two holding two and seven, minus one and one, five and minus four.

The inner pair is three and three, so this exists, and the answer is two by two. Four entries. For the entry in row one, column one: lift out row one of the left, which is one, minus one, two. Lift out column one of the right, which is two, minus one, five. Pair them along. One times two is two. Minus one times minus one is one. Two times five is ten. Add: thirteen.

Notice what that entry used. A whole row of three, a whole column of three, six entries in all. And notice what it did not use: the other three entries of the left arrangement never came into it. That paragraph, written as a formula. If the left arrangement is m by n and the right one is n by p, then the entry of the answer in row i, column j is the first entry of row i times the first entry of column j, plus the second times the second, and so on, for n terms.

Write that sum with a sigma and the index runs from one to n, where n is the shared count, the one from the inner pair. The sigma form is not a new definition. It is the same sentence written shorter, and the way to be sure of that is to write the operation twice. One version runs an index over the shared count. The other has the sums for one, two, three and four terms written out longhand, with no index in it anywhere.

Across forty-eight ordered pairs of assorted shapes drawn from twelve arrangements, the two versions disagree on nothing, and there is no pair where one produces an answer and the other does not. The only thing that separates them is that the longhand one gives up when the shared count reaches five, because nobody wants to write that out. The one with the index does not care. Back to that two by two answer, and the other three entries.

Row one against column two: one times seven is seven, minus one times one is minus one, two times minus four is minus eight. Seven minus one minus eight is minus two. Row two against column one: zero times two is nothing, three times minus one is minus three, four times five is twenty. Seventeen. Row two against column two: zero, three, and minus sixteen. Minus thirteen. Thirteen and minus two above seventeen and minus thirteen.

Four entries, four pairings, and each one lit a different row and a different column. That picture is the operation. If you can see which strip of each arrangement an entry is eating, you can compute any product there is. There is another way to multiply two arrangements, and students reach for it constantly. Multiply the facing entries: top left by top left, and so on. That operation exists in mathematics. It is not this one, and here is the sharpest way to see the difference.

The facing operation needs the two orders to be identical. This one needs the inner pair to agree. Those are different demands, and in two shapes they are opposite. A two by three against a three by two: this product exists, the facing one does not. A two by three against a two by three: the facing one exists, this product does not. Now the deeper difference. Take every two by two you can build from the entries zero, one and two. Eighty-one of them, and six thousand five hundred and sixty-one ordered pairs.

Ask whether the answer's entry at a position is decided by the two factors' entries at that same position. There are thirty-six combinations of a facing pair and a position to try. Thirty-four of the thirty-six leave the answer undecided. One of them leads to seven different values. The two that do decide it are the ones where a zero faces a zero at an off-diagonal position, and they decide it at zero, which is not much of an exception.

So the entry at a position is essentially never a function of the entries at that position. It is a function of a whole row and a whole column, which is the one thing to carry out of this video. A worked product, in the order you should always do it. A two by two holding six and nine above two and three. A two by three holding two, six and zero above seven, nine and eight.

Check first. The inner pair is two and two. It exists. The outer pair is two and three, so the answer is two by three, and that is six entries to find. Six times two plus nine times seven is twelve plus sixty-three, seventy-five. Six times six plus nine times nine is thirty-six plus eighty-one, a hundred and seventeen. Six times zero plus nine times eight is seventy-two. Second row: four plus twenty-one is twenty-five. Twelve plus twenty-seven is thirty-nine. Zero plus twenty-four is twenty-four.

And the other way round does not exist at all. A two by three against a two by two: the inner pair is three and two. Two shapes that look alike and behave in opposite ways. A row of three met with a column of three. The inner pair is three and three, so it exists, and the outer pair is one and one. The whole thing collapses to a single number.

Two, three, four against one, two, three gives two plus six plus twelve, twenty. Now turn them around. A column of three met with a row of three. The inner pair is one and one, so this exists too. But the outer pair is three and three. The same six numbers open out into a three by three array: two, three and four; four, six and eight; six, nine and twelve.

One collapses, one expands, and nothing about that is surprising once you read the outer pair. It is only surprising if you were not reading it. Here is what that buys you. Take a row of three, a three by three arrangement, and a column of three, all multiplied together. The row met with the square gives another row of three: six, two, four. Met with the column, that gives a single number.

Set that number to zero and you have an ordinary equation. In one such question the number is four plus four times the unknown, so the unknown is minus one. In another the unknown appears in the row and in the column, and what comes out is the unknown squared, less forty-eight. That has two answers, plus and minus the square root of forty-eight, and a question asked in the singular still has both.

One last kind of question, where there are no numbers anywhere. Five arrangements are named, and their orders are given in letters. Two by n, three by k, two by p, n by three, and p by k. You are asked what has to be true for a certain sum of two products to exist. No arithmetic is possible and none is needed. The first product needs its inner pair to agree, which forces k to be three. The second product always exists. Then the two answers have to have the same order for the sum, which forces p to equal n.

Try every triple of letters from one to four, sixty-four of them, and the combination exists for exactly four. The option saying k is three and p equals n gets all sixty-four right. The other three get eighteen, twelve and eight wrong. A second item asks only for the order of a combination when n equals p. Both arrangements involved are then two by n, so the answer is two by n. One of the four options is right for every n; the others fail three, four and three times out of four.

That is the whole return on the inner-pair and outer-pair reading. Those two questions are answerable by inspection, and without that reading they are a puzzle. Finally, a case where every number on the board is something a shopkeeper would recognise. Three products, two markets. The first market sold ten thousand, two thousand and eighteen thousand units. The second sold six thousand, twenty thousand and eight thousand. That is a two by three arrangement: markets down, products across.

The unit prices are two and a half, one and a half, and one. A column of three. Two by three against three by one. The inner pair agrees, and the answer is two by one: one number per market. Forty-six thousand from the first market, fifty-three thousand from the second. Each of those is a revenue, and each came from one whole row of sales met with the whole column of prices.

Now the unit costs: two, one, and a half. Same shape, so the same product works, and it gives thirty-one thousand and thirty-six thousand. Subtract, and the gross profits are fifteen thousand and seventeen thousand. Thirty-two thousand in all. Notice that the second market took more money and also made more profit. Those are two different questions and the arrangement answered both, because the price column and the cost column were handled independently, exactly as the two shops were at the start.

One trap before we finish, because it is wearing a disguise. A bookshop sells ten dozen, eight dozen and ten dozen copies of three books, priced at eighty, sixty and forty. Form the product straight from those counts and you get one thousand six hundred and eighty. Convert the dozens first, so a hundred and twenty, ninety-six and a hundred and twenty, and you get twenty thousand one hundred and sixty.

The two differ by a factor of twelve, and the matrix did not warn you. The conversion has to happen before the arrangement is built, because once the numbers are in the array they are just numbers. So, what to keep. One entry of a product eats a whole row of the left arrangement and a whole column of the right one, and adds up the pairings. Everything else follows from that.

The inner pair has to agree or there is no product at all. The outer pair is the order of the answer, and you can read it off before computing anything. And the answer's entry at a position almost never depends on the two factors' entries at that position. This is the first operation in the subject where that is true, and forgetting it is the single most common way to get a product wrong.

Where this fits

Either side of this one

The book

Open in a new tab