Hey folks, my name is Nathan Johnston and welcome to lecture 20 of Advanced Linear Algebra. Today we're going to talk all about orthogonality, which is something you learned about back in introductory linear algebra. Remember back then what orthogonality meant was that two vectors were perpendicular to each other.
The angle between them was pi over 2 or 90 degrees. Okay, and the way that you checked orthogonality was you computed the dot product between the two vectors. Okay, if that dot product equaled zero, they were orthogonal, and if it equaled anything else, they were not orthogonal. Well...
Now that we have inner products to work with as a generalization of the dot product, we can do the same sort of thing in arbitrary vector spaces. We can talk about orthogonality in arbitrary vector spaces just via this idea that the inner product now, instead of the dot product, equals zero. So this is our starting point for this lecture. Orthogonality in any old inner product space, so in other words in any vector space with an inner product, what that means we say that two vectors are orthogonal if their inner product equals zero. And so again the idea behind this, the intuition, is the same as it was back in Rn, back when we were doing dot products.
If vectors are orthogonal to each other that sort of means they're in as independent as possible in a sense. They're sort of pointing as far away from each other as they can. Okay so let's draw a picture here to try to sort of pin down this intuition.
All right so first off let's talk about linear dependence, what that means geometrically. Well, linear dependence just means that one of the vectors is a linear combination of the others, which if you have two vectors for example, means that they both point along the same line, right? They're in the span of each other. Okay, so that's our linearly dependent picture.
Our linearly independent picture just means, well not that, it means they're not pointing along the same line, right? There's some angle between them, okay, some non-zero angle between them. So that's what linear independence is. And then orthogonality It's just the stronger version of this. Not only are they not pointing in the same direction, but they're sort of pointing as far away from each other as they could before you start rotating back towards the span of each other.
Remember the span of one of the vectors is the entire line in the direction of that vector. So once you go past pi over 2 or 90 degrees, you start going back towards that same line. So orthogonality is sort of, they're pointing in sort of as not the same directions as possible. So that's our orthogonality picture.
It's like linear independence but on steroids. Alright, so because linear independence is one of the main ingredients in bases, well now that we have linear independence on steroids, it makes sense to ask the question, well what happens to bases if you have this stronger notion of linear independence? What happens to bases if you have orthogonality instead? Alright, so that's sort of our next step here. Now that we understand orthogonality, let's think about well, bases where you have this orthogonality requirement rather than just linear independence.
And we call these bases orthogonal bases. And we throw in one other minor condition, then we get something called orthonormal bases. So that's really the thing that we're going to be interested in. All right, so here's the setup. Suppose that you've got any old basis of an inner product space V, okay?
Well, we say that it's an orthonormal basis if it has some extra conditions, okay? The first extra condition is what we call mutual orthogonality. And it just means that every vector...
in that basis is orthogonal to everything else in that basis, right? So if you pick any two vectors v and w, the inner product equals zero. They're all orthogonal to each other. They're all sort of as independent from each other as possible, right?
And the other thing that we require is what makes it an orthonormal basis rather than just an orthogonal basis, okay? So this normalization condition is just that we scale every vector in the basis to have length one with respect to whatever inner product we're talking about. Okay, so this is sort of an easy condition to throw in after the fact, because once you have an orthogonal basis, well, you can just rescale everything to have length one, but by dividing every member of the basis by its length.
So this is just sort of an easy extra condition that makes the basis even more well behaved. So we usually throw it in. All right.
And we have all sorts of standard examples of orthonormal bases in vector spaces that we've been looking at throughout this course. So, for example, I mean, the standard basis. in Rn or Cn, it's a straightforward calculation to show that yeah those really are orthonormal bases. Okay, I mean you have to check two things.
You have to check this inner product condition. Okay, and here I mean I'm just working with the standard inner product on these two spaces over here, so just the dot product. So these Ej vectors, right, these vectors that have one and a single entry and zeros everywhere else, if you take the inner product, the dot product of any two of those, you just get a bunch of zeros being added up.
So yeah, all of their dot products, all of their inner products are zero. And similarly, they all have length one. Again, that's straightforward to check.
And if we go to our more exotic vector spaces, like the space of m by n matrices, well, we've seen a standard basis in that vector space as well. Again, these are the matrices that have a one in a single entry and zeros everywhere else. And again, you just go through the calculation, use the standard inner product, the Frobenius inner product on this vector space, and it's just straightforward to check that yeah, all of the inner products of those Eij matrices, they all equal zero, and their lengths in the Frobenius norm, the norm induced by the inner product, those all equal one.
So yeah, that is an orthonormal basis in that vector space as well. And then sort of continuing the trend, it seems natural to ask, okay, what about in the vector space? pp which remember this is the degree less than or equal to p polynomials and now on the real interval from a to b okay so what i mean by this is i'm working in the inner product space of degree p polynomials and the the inner product i'm using is just the integral from a to b of this you know f of x times g of x that standard inner product that we looked at on this vector space all right and then the question is well is that an orthonormal basis and this time we actually sort of break the trend a little bit this is not an orthonormal basis.
So you have to be a little bit careful when working in these function spaces. Okay, there are orthonormal bases in these function spaces, but they're actually all sort of uglier, and we'll come back to this problem at the end of the week. All right, but to see that this is not an orthonormal basis in this vector space, let's just compute some inner products of some members of the standard basis. So for example, the inner product of 1 and x squared. Well, the inner product of that, you just multiply those two functions together, so you get x squared, and then you integrate from a to b.
And because you're integrating a non-negative function, actually a strictly positive function, as long as x is not zero, this integral is not going to equal zero, unless a equals b, which you know not really a space to begin with. So this integral here is not going to equal zero, it's going to be something strictly positive. So no, they're not orthogonal to each other even in the first place. So that is not an orthonormal basis on that vector space. We'll see an example.
of an orthonormal basis a bit later. Okay, well let's try to pin down this idea that we talked about earlier. We talked about how the idea behind orthogonality is sort of it's a stronger version of linear independence. Let's pin that that down.
I mean sort of we have the geometric picture that sort of suggests it, but how do you prove it in an arbitrary inner product space? All right, so here here's our theorem that pins down that idea. Suppose you've got some inner product space and suppose that you've got some set B that consists of non-zero mutually orthogonal vectors. Okay, so the idea here is you've got something that sort of looks like an orthogonal basis.
Okay, so all of the vectors have to be non-zero just because, well, I mean the zero vector is orthogonal to everything. So we sort of need to take away that trivial case. And then mutually orthogonal, again, just remember what that means is that they're all orthogonal to each other. You take the inner product of any two of them and you get zero.
So if you have a set like that where all the vectors are orthogonal to each other, then it must be linearly independent. So let's pin down this idea. Let's see why orthogonality implies independence.
All right, so the setup here, we want to show that some sets linearly independent. The way you do that, remember, is you show that the only solution of this linear system here is the all zero solution. So in other words, you show that this linear combination equaling zero implies that all of the Cs have to equal zero. So that's what we're going to try to do here. We're going to try to show that each of the C's has to equal zero.
All right. So the way we do that is what we're going to do is we're going to take this linear combination here, and I'm going to take the inner product of it with the vector VJ, with the Jth vector from the basis. Okay.
I'm going to do that both on the left-hand side and on the right-hand side. And I better get the same thing when I do that. All right. Well, starting off on the right-hand side, if I take the inner product on the right-hand side with the vector VJ.
well it's just some vector interproduct with a zero vector, I'm going to get zero. On the other hand, if I do the same inner product on the left hand side with vj, what do I get? Well now I get this junk over here, I get vj inner product with that linear combination, just substitute out zero equals that linear combination. And now I'm going to use properties of inner products to sort of break that apart and simplify it as much as I can. So linearity in the second entry of the inner product tells me that I can split it apart like this, I just split this linear combination up outside of the inner product.
So now it's just C1 V1 with Vj, C2 V2 with Vj, and so on down the line. Alright, next up. Now I'm gonna notice that, hey, over on the right here, what I've got is I've got the inner product of two vectors in that set B, and I've got the inner product of two vectors in that set B, and then the inner product of two vectors in that set B. But B, it's a mutually orthogonal set. So all of these inner products actually equal zero, right?
Because all, except for one, okay, right? Because every vector in the set is orthogonal to every other vector in the set. So the only term in this sum that does not die is the one where it's vj inner product with vj. Okay, so most of these terms die. Whenever the subscript over here on the right is not j, the term goes away.
That inner product is zero. Okay, so all I end up with out of this sum is the term cj times vj inner product with vj. All right, now, because this all equals zero, right?
If I trace this through, this equals zero. Well, now I look at this. Can this inner product over here equal zero? And no, it can't.
Because if you go back and look at the defining properties of an inner product, The third defining property was whenever you take a vector and inner product with itself you get something bigger than or equal to zero and furthermore the only way to get zero is if the vector is the zero vector but go back to the statement of the theorem we're assuming that every vector in the set B is non-zero it's not the zero vector okay so this inner product over here cannot equal zero in fact it's gotta be strictly bigger than zero so the only way that this product here can equal zero is if cj itself equals zero. So yeah, that inner product is bigger than zero. So therefore, cj equals zero for all j, right? Because it didn't matter what j was. So in other words, we got exactly what we wanted.
We got that each of these coefficients here equals zero, right? So b must be a linearly independent set. So yeah, mutual orthogonality does imply linear independence, okay?
If we combine this with earlier results, we saw earlier in the course, a fairly quick... Really nice corollary of this is that if you have any set that is A, mutually orthogonal, B, all of the vectors are non-zero, and C, the number of vectors in that set matches the dimension of the vector space that they live in, then you know right away that they must form an orthogonal basis of that space, okay? Because that mutual orthogonality and non-zeroness implies that they're linearly independent. And then the fact that their dimension matches up with the space implies that they span the entire space, right? We have this theorem that tells us that if you have linear independence and the dimension and the size of the vector is the dimension of the space, then actually it's a basis, okay?
So in a sense you're getting both spanning and linear independence almost for free now. Now all we have to do to check whether or not something's an orthogonal basis of a vector space is just check orthogonality and then count things. So it becomes really, really easy. We get a lot of stuff for free here.
So let's do an example here of showing that something is an orthonormal basis or at least an orthogonal basis of a vector space. And what we're going to do is we're going to show that this set of poly matrices that we've seen a couple of times now, let's show that this really is an orthogonal basis of the space of two by two complex numbers. We've seen earlier that this is a basis of that space.
And the way we did that, we had to solve a bunch of linear systems to show linear independence and spanning. Now we'll show this property without solving any linear systems at all, okay? So how do we do this? Well, we've just got to compute a whole bunch of inner products, right?
So first off, we note, I guess, that, hey, there's four vectors here, right? And I already know that m2 of c, that's four-dimensional. So I have the right number of vectors, right number of matrices.
I just need to check whether or not the inner products of all these pairs equals zero, right? So that you have to check. six different inner products here because how many pairs are there of four matrices?
Well, there's six of them. It's four choose two. In general, if you have a vector space that's n-dimensional, so you have n vectors that you need to check orthogonality between them, you have to do n choose two pairs.
So n times n minus one over two with that many inner products that you have to check. All right, so let's just check all these inner products. I'm not actually going to go through all six of them. They're all just straightforward, right?
You use the standard inner product here, because again, I haven't indicated otherwise. So we're just using the standard Frobenius inner product. All right. And let's just check some of these inner products.
So here I took 0, 1, 1, 0. So this basis matrix. And I took the inner product with 1, 0, 0, minus 1. So this one here. So I did this pair.
And remember the way the Frobenius inner product works, you could use that trace formula. Or you could do, hey, just. multiply them entry-wise and add them up, right?
It's the dot product for matrices, and you have to be careful, throw complex conjugates on the first matrix, but they're all real here, so it doesn't make a difference. So you just do 0 times 1, ah, that's 0. 1 times 0, that's 0. 1 times 0, ah, that's 0. 0 times minus 1, ah, that's 0. Add them up, I'm adding up four 0s, I get a 0, okay? So yes, this pair here, they're orthogonal to each other.
Let's do another one, okay? Let's do this matrix with this matrix, okay? 0, 1, 1, 0 with 0 minus i, i is 0. Again, just do it entry-wise.
0 times 0, that's 0. 1 times minus i, that's minus i. 1 times i, that's i. 0 times 0, that's 0. Add them up.
Of course, you get 0. Okay, so they're orthogonal to each other as well. There are four other pairs that we haven't done, but you can just check those straightforwardly yourself. I mean, they're all just as easy to do as these two here.
Okay, so now that you've checked orthogonality, great, we know that it's an orthogonal basis of the space of two by two complex matrices. To make it an orthonormal basis, right, the question also asks how can you turn it into an orthonormal basis? Well, to do that, just take every vector, every matrix in that set and divide it by its norm, right? Divide it by the norm induced by whatever inner product you're working with. Okay, so again, here we're working with the standard inner product, the Frobenius inner product.
So just compute the norm with respect to the Frobenius inner product of each of these matrices here. It's going to turn out that each of these have length or norm root two, right? Because again, remember, what does the Frobenius norm do?
It just, you square each of the entries, add them up, and then square root at the end of the day. So we get one plus zero plus zero, one plus zero plus zero plus one, and then square root at the end of the day, and you get root two. And similarly for all of the other matrices, they all have Frobenius norm root two.
So if you just stick a 1 over root 2 in front of each of these, you get an orthonormal basis of the space M2 of C. Alrighty, so that'll do it for orthogonality. And then next class, we'll start looking at things that you can do with orthogonality.