I'm watching videos of Gilbert Strang's linear algebra lectures. In lecture 17, where he goes over orthonormal bases and the Gram-Schmidt process, he proves

$$ A^TB = A^T\left( b - \frac{A^Tb} {(A^TA)} A\right) = 0 $$

by having

$$ A^T \frac{A^Tb} {(A^TA)} A $$ cancel out into ATb. I don't know how the ATA on the top was allowed to cancel out with the ATA on the bottom if there is an ATb sandwiched in between the AT and the A on the numerator. Shouldn't the AT and the A on the numerator not be allowed to multiply each other?

I wondered if the AT on the numerator can cancel out with the AT on the denominator and the same for the two A's, but I do not know if this violates the order of operations for matrix multiplication. If I were to write (ATA)-1 rather than have the (ATA) on the denominator below the (ATb), where would it go?

  • 3
    $\begingroup$ Dividing by matrices is completely insane (undefined) in every context I'm aware of, FYI. It might be a misunderstanding. Are we sure these are not dot products, or something of that nature? $\endgroup$
    – The Count
    Jan 18, 2017 at 2:57
  • $\begingroup$ I believe the (A^T)A on the denominator is also interpreted as (A^T)A inverse. $\endgroup$
    – Eric He
    Jan 18, 2017 at 3:44
  • 1
    $\begingroup$ The term on the right doesn’t look right for another reason: If $A$ is a matrix and $b$ a column vector the product $bA$ doesn’t make much sense, either. Also, are $B$ and $b$ meant to be the same object? I’m with @TheCount: if this is about the Gram-Schmidt process, then all of the variables in your question are likely vectors. If so, then $A^TA$ is a scalar (well, a $1\times1$ matrix, which you can treat as a scalar most of the time), so you can move it around and divide by it all you like. $\endgroup$
    – amd
    Jan 18, 2017 at 7:40
  • 1
    $\begingroup$ @eriche the problem with that interpretation is that it doesn't specify if the inverse is supposed to be on the right or on the left of the expression:) $\endgroup$
    – Ant
    Jan 18, 2017 at 12:09

1 Answer 1


Here's Prof. Strang's blackboard at 33m56s:

enter image description here

Note that $\mathrm A, \mathrm B$ are vectors, not matrices!! In other words, the question makes no sense whatsoever.

  • $\begingroup$ Unconventional notation, to say the least! Thanks for clearing it up! $\endgroup$
    – The Count
    Jan 18, 2017 at 13:23
  • $\begingroup$ Ohh, thank you so much. I let the notation confuse me into thinking A and B were matrices! $\endgroup$
    – Eric He
    Jan 18, 2017 at 19:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .