1 00:00:00,000 --> 00:00:06,008 Okay. So, in the second video, we are going to talk about Hermitian matrices, 2 00:00:06,008 --> 00:00:13,041 and Eigenvectors and Eigenvalues. So, let's see. What's a Hermitian matrix? A 3 00:00:13,041 --> 00:00:27,021 matrix is Hermitian so, so, A is Hermitian if and only if A is equal to A conjugate 4 00:00:27,021 --> 00:00:35,077 transpose. Okay, so in particular, it has to be a square matrix. And so for example, 5 00:00:35,077 --> 00:00:42,099 this is a two by two Hermitian matrix. So the, the entries on the diagonal have to 6 00:00:42,099 --> 00:00:49,084 be real. So they could be, it could be like this. And then the matrix has to be 7 00:00:49,084 --> 00:00:56,023 equal to it's, if you conjugate the entries then, then, and you transpose the 8 00:00:56,023 --> 00:01:02,084 matrix, you have got to get back to the same place. So for example, if this was 9 00:01:02,084 --> 00:01:11,022 one + i, then this matrix, this entry must be it's conjugate transpose so it must be 10 00:01:11,022 --> 00:01:25,025 one - i. So, if A is, if A is Hermitian and real, then it's also a symmetric 11 00:01:25,025 --> 00:01:41,023 matrix. Okay, so now we say that the vector phi is an Eigenvector of A if A 12 00:01:41,023 --> 00:01:49,005 times phi is lambda times phi. So what A does to phi is it either, it just shrinks 13 00:01:49,005 --> 00:01:56,008 or stretches it. Okay, in general of course, lambda is going to be a complex 14 00:01:56,008 --> 00:02:05,007 number. Okay. So now, there's this beautiful theorem about Hermitian matrices 15 00:02:05,007 --> 00:02:19,003 which is called the Spectral Theorem. So what, what the spectral theorem says is 16 00:02:19,003 --> 00:02:41,083 that, if is A is Hermitian implies that A has orthonormal set of Eigenvectors with 17 00:02:41,083 --> 00:02:55,012 real Eigenvalues. Okay, so let's, let's call these Eigenvectors phi sub zero 18 00:02:55,012 --> 00:03:04,014 through phi sub k minus one. And the corresponding Eigenvalues, let's call them 19 00:03:04,014 --> 00:03:12,006 lambda naught through lambda k minus one. And so, what this is telling us? Okay, so 20 00:03:12,006 --> 00:03:18,029 let's, let's pretend for a moment that A was, it was a real matrix. So it's, it's 21 00:03:18,029 --> 00:03:25,013 just a symmetric way, matrix with all real entries. So then, what is the, what is the 22 00:03:25,013 --> 00:03:32,016 spectral theorem telling us? Well, what it's, what it's telling us is, if you look 23 00:03:32,016 --> 00:03:39,074 at the unit ball in this k-dimensional space, so I'm thinking of ks2 right now. I 24 00:03:39,074 --> 00:03:47,069 couldn't think of anything. Well, what happens to it under, under the action of 25 00:03:47,069 --> 00:03:55,052 A? Well, to, to figure this out what you have to do is you first have to locate the 26 00:03:55,052 --> 00:04:03,038 Eigenvectors of A, a nd perhaps one of the Eigenvectors is this one and one of them 27 00:04:03,038 --> 00:04:11,018 is that one. So it's, let's see these are the two Eigenvectors. They are, they are 28 00:04:11,018 --> 00:04:18,055 orthogonal to each other. And now, what you are guaranteed is that what A does to 29 00:04:18,055 --> 00:04:25,022 this is, it just scales each of these. Okay. So, so what it might do is it might, 30 00:04:25,022 --> 00:04:33,012 it might shrink this vector and it might expand this one. Okay. So, and of course, 31 00:04:33,012 --> 00:04:39,035 once we know what it does to each of these we know what it does to any linear 32 00:04:39,035 --> 00:04:47,030 combination and so what it does is it takes this circle or a sphere and 33 00:04:47,030 --> 00:04:58,003 k-dimensions and it converts it, sorry about my drawing here. It sort of distorts 34 00:04:58,003 --> 00:05:10,097 it into an ellipse like this. Okay. So, A maps the sphere, the unit sphere. Okay. 35 00:05:10,097 --> 00:05:21,086 So, in this case a circle into an ellipse, and the unit sphere into an ellipsoid. 36 00:05:21,086 --> 00:05:29,061 Okay where there are, where there are k principle axis which, whose lengths are 37 00:05:29,061 --> 00:05:35,023 given by these Eigenvalues, and then you have this kind of object except maybe 38 00:05:35,023 --> 00:05:42,029 three space or four space, or whatever you have. So let's look in at an, at an 39 00:05:42,029 --> 00:05:52,058 example of this. So for example we already looked at this operator x which was a bit 40 00:05:52,058 --> 00:06:01,069 flip operator. It was given by this matrix which is of course, Hermitian. And so we 41 00:06:01,069 --> 00:06:09,009 can ask, what are its Eigenvalues and what are the Eigenvectors? So this you can 42 00:06:09,009 --> 00:06:15,070 solve just by inspection. You can, you can, you know, it's, it's sort of easy to 43 00:06:15,070 --> 00:06:24,009 see that one of the Eigenvectors of x is, is plus. So the, the Eigenvectors of x are 44 00:06:24,009 --> 00:06:32,073 plus and minus. Okay? So what is, what does x do to plus? Well, well, what is, 45 00:06:32,073 --> 00:06:38,098 what is you know, let's, let's write it out in the, in the usual vector notation. 46 00:06:38,098 --> 00:06:46,023 So what's plus? It's one over square root two, one of a square root two. Well what's 47 00:06:46,023 --> 00:06:54,066 this product? It's exactly one over square root two, one over square root two. Right? 48 00:06:54,066 --> 00:07:04,063 So, what's, what's the corresponding lambda? What's lambda plus? Well, it's 49 00:07:04,063 --> 00:07:13,032 exactly one. Okay? So lambda, x maps plus to pluss. What does x map minus do? Well 50 00:07:13,032 --> 00:07:19,064 it's, exactly the same thing, one over square root two, minus one over square 51 00:07:19,064 --> 00:07:33,069 root two. And thi s time, it flips them which is minus of what we started from. So 52 00:07:33,069 --> 00:07:45,015 lambda minus, is -one. Okay so, so x has two Eigenvectors, plus and minus, with 53 00:07:45,015 --> 00:07:55,058 Eigenvalues one and -one. Okay. But, you could, you could also ask, well, how would 54 00:07:55,058 --> 00:08:00,077 you figure out these Eigenvalues and Eigenvectors if you, if you couldn't guess 55 00:08:00,077 --> 00:08:06,034 them? Well then, you know, just to remind you how one does that you, you sort of 56 00:08:06,034 --> 00:08:12,065 solve of what you say is, for example, you know, let's, let's say that you wanted to 57 00:08:12,065 --> 00:08:19,009 work this out instead for the Hadamard transform H which is one over square root 58 00:08:19,009 --> 00:08:25,005 two, one over square root two, one over square root two minus one over square root 59 00:08:25,005 --> 00:08:31,000 two. Well again, you know, actually it's a little easier to guess what the, what the 60 00:08:31,000 --> 00:08:37,014 Eigenvectors and Eigenvalues are because remember what, what the Hadamard transform 61 00:08:37,014 --> 00:08:45,045 does? There's the zero state, there's plus, there's minus and there's one. And 62 00:08:45,045 --> 00:08:53,051 what, what the Hadamard transform does it's, it's a rotation by pi about this 63 00:08:53,051 --> 00:09:01,065 axis here. Right? About this pi by eight axis. So what are the Eigenvectors going 64 00:09:01,065 --> 00:09:09,038 to be? Well clearly, one of them should be this vector, the five by eight vector. And 65 00:09:09,038 --> 00:09:15,027 the other should be orthogonal to it. Right? This would have a Eigenvalue one 66 00:09:15,027 --> 00:09:22,002 and this would have Eigenvalue -one because it flips when you apply H to it. 67 00:09:22,002 --> 00:09:27,048 Okay, but, but, let's go back and think about, how would you actually work this 68 00:09:27,048 --> 00:09:34,012 out? Well, let's, let's carry out, you know, so what you would do is you would 69 00:09:34,012 --> 00:09:44,073 say, okay, so I want to find some vector phi such that H times phi is lambda times 70 00:09:44,073 --> 00:09:54,096 phi, which means that H minus lambda times the identity times phi equal to zero. But 71 00:09:54,096 --> 00:10:02,069 we want a nonzero solution to this so for this to happen, this must be a singular 72 00:10:02,069 --> 00:10:10,039 matrix, so it must have determinant equal to zero. So let's write out this 73 00:10:10,039 --> 00:10:16,096 condition. So what's H minus lambda I? Well, H is one over square root two minus 74 00:10:16,096 --> 00:10:22,003 one over square root two, one over square root two, one over square root two. And 75 00:10:22,003 --> 00:10:27,087 now we want to subtract off lambda times the identity, so we subtract off lambda 76 00:10:27,087 --> 00:10:33,052 from the diagonal. And now we want the determinant of this to be equal to zero, 77 00:10:33,052 --> 00:10:38,048 but what's the determinant? It's this times this minus this times this, so it's 78 00:10:38,048 --> 00:10:44,092 one over square root two minus lambda, times minus one over square root two minus 79 00:10:44,092 --> 00:10:53,023 lambda minus one over square root two over one over square root two which is minus a 80 00:10:53,023 --> 00:11:06,007 half plus lambda squared minus a half equal to zero which means lambda squared 81 00:11:06,007 --> 00:11:15,005 equal to one. So lambda equal to plus or minus one as we wanted. And now, we just, 82 00:11:15,005 --> 00:11:25,006 we just choose each of these values and we figure out what, what phi must be. Okay. 83 00:11:25,006 --> 00:11:34,045 So, so finally, let's you know, let's, let's do one last thing which is, what we 84 00:11:34,045 --> 00:11:44,092 said is A has an orthonormal set of Eigenvectors phi naught through phi k 85 00:11:44,092 --> 00:11:56,083 minus one with real Eigenvalues lambda naught through lambda k minus one. Okay. 86 00:11:56,083 --> 00:12:06,050 What another way you can say this is, that if you were to change your basis to, to 87 00:12:06,050 --> 00:12:15,045 this phi naught through phi k minus one, then what's the action of A? Well it's, 88 00:12:15,045 --> 00:12:23,042 it's just a diagonal matrix, so in the phi naught through phi k minus one bases, so 89 00:12:23,042 --> 00:12:31,045 if you, if you, if you were to write A in this, in this, in this phi naught through 90 00:12:31,045 --> 00:12:38,038 phi k minus one basis, then A would look like this. It would look like lambda 91 00:12:38,038 --> 00:12:44,077 naught, lambda one, through lambda k minus one. It would be a diagonal matrix, 92 00:12:44,077 --> 00:12:50,092 because all it does is it takes phi naught. What does A do to it? It, it 93 00:12:50,092 --> 00:12:59,013 multiplies it by lambda naught and so on. So let's call this diagonal matrix capital 94 00:12:59,013 --> 00:13:07,096 lambda, okay? So, now we can write A as the following. So, if we first do a change 95 00:13:07,096 --> 00:13:14,081 of basis, so if we, if we first perform some unitary transformations, some 96 00:13:14,081 --> 00:13:22,015 rotation that rotates our standard basis into this basis of Eigenvectors, then the 97 00:13:22,015 --> 00:13:28,054 action of A is just given by this diagonal matrix, lambda. And then if you want to 98 00:13:28,054 --> 00:13:34,068 switch back to the standard bases, then we'd be applying the inverse of U, which 99 00:13:34,068 --> 00:13:40,091 is U dagger. So what we are saying is, A can always be written as U dagger lambda 100 00:13:40,091 --> 00:13:50,000 U. Where U is a matrix which changes the standard basis to the, to the phi basis, 101 00:13:50,000 --> 00:13:57,007 the basis of Eigenvectors. Okay. So what, wha t is, what is U look like? Well U 102 00:13:57,007 --> 00:14:03,030 obviously the columns of U are going to look like the phi, the phi [inaudible]. So 103 00:14:03,030 --> 00:14:09,007 the first column will look like phi naught, the second column will look like 104 00:14:09,007 --> 00:14:21,040 phi one, etc. The last column will look like phi k minus one. Okay. And now if you 105 00:14:21,040 --> 00:14:29,005 look at it, what does this tell you? Well A is just the following. It's just lambda 106 00:14:29,005 --> 00:14:39,005 naught times the projection onto phi naught plus lambda one times the 107 00:14:39,005 --> 00:14:47,043 projection onto phi one plus lambda k minus one times the projection onto phi k 108 00:14:47,043 --> 00:14:56,010 minus one. So you can, you can either read it off of this, off of this, right? 109 00:14:56,010 --> 00:15:04,008 Because, you know, the rows of U dagger are the, the phi J's complex conjugated. 110 00:15:04,008 --> 00:15:11,060 And so when you multiply all this out since these phi's are orthonormal, all you 111 00:15:11,060 --> 00:15:17,074 will get is, the j-th row with the j-th column, of course multiplied by lambda jn, 112 00:15:17,074 --> 00:15:23,032 and that's what these. Or you could just, or you could just check that when you 113 00:15:23,032 --> 00:15:31,046 multiply this times phi, times, times any phi j, you get lambda j times phi. Okay. 114 00:15:31,046 --> 00:15:39,004 So, so finally what, what this is telling us is that, is that A can just be written 115 00:15:39,004 --> 00:15:49,060 as the sum of lambda sum over j went from zero to k minus one of lambda sub j times 116 00:15:49,060 --> 00:15:59,062 the projection onto the, onto phi sub j, let's call that projection matrix P sub j, 117 00:15:59,062 --> 00:16:11,003 where P sub j is phi sub j bra phi sub j, sorry, ket phi sub j bra phi sub j.