QM2 Exercises MathRecap
QM2 Exercises MathRecap
Quantum Mechanics 2
Catching up with mathematical tools: Linear Algebra
Dr Max Beyer
VU Amsterdam and QMLA Group
[Link]/, [Link]@[Link]
This problem set provides representative linear algebra exercises to refresh your knowledge of some of
the key mathematical tools that are required during the QM2 course. This knowledge is assumed to be a
prerequisite for the course. While no dedicated tutorial session is devoted to this problem set, students are
encouraged to go through them as part of their self-study and in case of questions reach out to the course
TAs during the tutorial sessions.
Solutions
Problem 1.1) Vector spaces Let V be the set of all functions from a nonempty set X into R. For any
function f, g ∈ V and any scalar k ∈ R, let f + g and kf be the functions in V defined as follows:
Solution:
If V is indeed a vector space over R, all axioms for vector spaces must hold. We check them one by one.
(i) The sum of f (x) and g(x), denoted by (f + g)(x) = f (x) + g(x) is in V as given in the definition;
(iii) From (f + g)(x) = f (x) + g(x) = g(x) + f (x) = (g + f )(x) and using the fact that addition is
commutative, we see that f + g = f + g;
(iv) Let f, g, h ∈ V , then we see that ((f + g) + h)(x) = (f + g)(x) + h(x) = (f (x) + g(x)) + h(x) and
(f + (g + h))(x) = f (x) + (g + h))(x) = f (x) + (g(x) + h(x). Using the fact that addition is associative
we see that (f (x) + g(x)) + h(x) = f (x) + (g(x) + h(x), and thus (f + g) + h = f + (g + h);
Page 1 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
(v) Let 0 denote the zero function: 0(x) = 0 ∀x ∈ X, then for any function f ∈ V , (f + 0)(x) =
f (x) + 0(x) = f (x) + 0 = f (x), ∀x ∈ X, so f + 0 = f ;
(vi) For any function f ∈ V , let −f be the function defined by (−f )(x) = −f (x), then (f + (−f ))(x) =
f (x) + (−f )(x) = f (x) − f (x) = 0 = 0(x). Hence, f + (−f ) = 0;
(vii) For a scalar k ∈ R, then (k(f + g))(x) = k((f + g)(x)) = k(f (x) + g(x)) = kf (x) + kg(x) = (kf ))(x) +
(kg)(x) = (kf + kg)(x), where we used the fact that multiplication is distributive over addition. So we
see that k(f + g) = kf + kg;
(viii) For a, b ∈ R, ((a + b)f )(x) = (a + b)f (x) = af (x) + bf (x) = (af )(x) + (bf )(x) = (af + bf )(x), hence
(a + b)f = af + bf ;
(ix) Let again a, b ∈ R, then ((ab)f )(x) = (ab)f (x) = a(bf (x)) = a(bf )(x) = (a(bf ))(x), so (ab)f = a(bf );
(x) For the unit 1 ∈ (R), (1f )(x) = 1f (x) = f (x), hence 1f = f .
Since all axioms are satisfied, we can conclude that V is a vector space over R.
Page 2 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.2) Subspaces Let V be the vector space of all 2 × 2 matrices over R. Show that W is not a
subspace of V where:
Hint: think of counterexamples that do belong to W but are not closed under either vector addition or scalar
multiplication.
Solution:
!
1 4
• Recall that det = ad − bc.
2 3
! !
1 0 0 0
We can think of matrices A = and B = that belong to W , since det(A) = 0 and
0 0 0 1
!
1 0
det(B) = 0. However, their sum A + B = does not belong to W , as det(A + B) = 1. W is
0 1
therefore not closed under vector addition and cannot be a subspace of V
!
1 0
• The unit matrix I = belongs to W since
0 1
! ! !
2 1 0 1 0 1 0
I = = =I
0 1 0 1 0 1
Page 3 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
!
3 1
Problem 1.3) Linear combinations Write the matrix E = as a linear combination of the
1 −1
matrices ! ! !
1 1 0 0 0 2
A= B= C= (2)
1 0 1 1 0 −1
Solution:
Form the equivalent system of equations by setting corresponding entries equal to each other:
x=3 x + 2z = 1 x+y =1 y − z = −1
Substitute x = 3 in the second and third equations to find y = −2 and z = −1, we can check that the last
equation is also satisfied by these values. We have now found the solution E = 3A − 2B − C.
Page 4 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.4) Linear independence Let V be the vector space of 2 × 2 matrices over R. Determine
whether the matrices A, B, C ∈ V are linearly dependent, where
! ! !
1 1 1 0 1 1
A= B= C= (3)
1 1 0 1 0 0
Solution:
Set a linear combination of A, B, C equal to the zero matrix using unknown scalars x, y, z:
xA + yB + zC = 0, thus
! ! ! !
1 1 1 0 1 1 0 0
x +y +z =
1 1 0 1 0 0 0 0
! ! ! !
x x y 0 z z 0 0
+ + =
x x 0 y 0 0 0 0
! !
x+y+z x+z 0 0
=
x x+y 0 0
Using x = 0 from the third equation in the second and last equations, we find y = 0 and z = 0, so
that we only obtain the zero solution x = 0, y = 0, z = 0. We have shown that xA + yB + zC = 0 implies
x = 0, y = 0, z = 0. Hence, the matrices A, B, C are linearly independent.
However, A, B and C do not form a basis of V , since we need 4 linearly independent matrices to span the
entire vector space of 2 × 2 matrices over R.
Page 5 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.5) Coordinates Let S be the basis of R2 consisting of basis vectors u1 = (2, 1) and u2 =
(1, −1). Find the coordinates of v relative to S where v = (a, b) in the standard basis.
Solution:
where C1 and C2 indicate the components of the vector v in the basis S. This is because C1 and C2 indicate
how much v is in the direction of u1 and u2 , respectively. The above equation leads us to a system of two
linear equations:
a = 2C + C
1 2
, (5)
b = C1 − C2
a+b a − 2b
C1 = C2 = . (6)
3 3
Therefore, in basis S, vector v would be written as:
! !
a+b
C1 3
v= = a−2b
. (7)
C2 3
Page 6 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
S1 = {u1 = (1, −2), u2 = (3, −4)} and S2 = {v1 = (1, 3), v2 = (3, 8)} (8)
• Verify that Q = P −1
Solution:
The general strategy to transform a vector expressed in basis B = {b1 , b2 } to one in basis A = {a1 , a2 }
is as follows: we use the basis transformation equation:
xA = PA←B xB
To then find the basis transformation matrix PA←B we need to row reduce:
(a1 a2 | b1 b2 ) ∼ (I | PA←B )
!
a
• We want to find PS1 ←St and then calculate PS1 ←St · . Here St denotes the standard basis St =
b
{e1 = (1, 0), e2 = (0, 1)}. To do this, we row reduce:
! ! ! !
1 3|1 0 1 3|1 0 1 3|1 0 1 0 | −2 − 32
∼ ∼ 1
∼ 1
−2 −4 | 0 1 0 2|2 1 0 1|1 2 0 1|1 2
! ! ! !
−2 − −3
2 −2 − 32 a −2a − 32 b
We thus find PS1 ←St = 1
, and vS1 = 1
· =
1 2 1 2 b a + 12 b
Page 7 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
! ! ! !
1 3|1 0 1 3|1 0 1 3|1 0 1 0 | −8 3
∼ ∼ ∼
3 8|0 1 0 −1 | −3 1 0 1|3 −1 0 1 | 3 −1
! ! ! !
−8 3 −8 3 a −8a + 3b
We thus find QS2 ←St = , and vS2 = · =
3 −1 3 −1 b 3a − b
!−1 !
a b 1 d −b
=
c d ad − bc −c a
Page 8 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.7) Inner product spaces Consider the vector space V of polynomials with inner product
R1
defined by 0 f (t)g(t)dt and the polynomials f (t) = t + 2, g(t) = 3t − 2, and h(t) = t2 − 2t − 3. Find:
• We now redefine f and g. Find k so that f (t) = t + k and g(t) = t2 are orthogonal with the inner
product as defined in the introduction of the exercise.
Solution:
• To normalise, we divide each function by its modulus. We denote the normalised function by a hat:
fˆ(t) = ||ff (t) g(t)
(t)|| and ĝ(t) = ||g(t)|| . Finally, to check if they are orthonormal, we calculate:
1
−1
Z
⟨fˆ, ĝ⟩ = fˆ(t)ĝ(t)dt = q . (11)
0 19
3
Since this is not zero, we see that the two functions are not orthonormal.
• Using the fact that ⟨f, g⟩ = ||f ||||g||cosθ, we immediately see that:
⟨f, g⟩ −1
cosθ = =q . (12)
||f ||||g|| 19
3
• To find k, we calculate the inner product between the newly defined f (t) and g(t). We find:
Z 1
4k + 3
⟨f, g⟩ = f (t)g(t)dt = . (13)
0 12
In order for the two functions to be orthogonal, we want ⟨f, g⟩ = 0. We solve for k and we find:
−3
k= . (14)
4
Page 9 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.8) Projections Find the projection of v = (1, −2, 3, −4) along w = (1, 2, 1, 2) in R4
Solution:
To find the projection, we start by calculating the component of v along w. This involves calculating the
inner product between the two vectors and normalising it by the length of w. Since we are in Euclidean
space, the inner product is extremely simple, and we get:
v·w 1−4+3−8 −8
= √ =√ . (15)
||w|| 10 10
We can finally simply scale the unit vector ŵ by the above scalar and we obtain:
−8 w −8
√ ·√ = w, (16)
10 10 10
which is the result we were after.
Page 10 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
1 5 −2
Solution:
• The matrix has not linear dependent row or columns thus the determinant is not zero. Since the matrix
do not contain any 0, there are no privileged row or column for the determinant computation, so we
decide to compute it along the fist column:
4 −1 −2 3 −2 3
det(A) = (1) −2 + (1) = (−8 + 5) − 2(4 − 15) + (2 − 12) = 9 (18)
5 −2 5 −2 4 −1
where Mi,j is the matrix of minors in the i-th row, j-th column. Clearly this inverse exists if and only
if, the determinant of A is not 0
Page 11 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
!
1 4
Problem 1.10) Eigenvalues and Eigenvectors Let A = . Find:
2 3
Solution:
The related eigenvectors can then be computed solving the linear systems:
( !
−4x + 4y = 0 1
– λ1 = 5: A − 5I = 0 → → v1 =
2x − 2y = 0 1
( !
2x + 4y = 0 −2
– λ2 = −1: A + I = 0 → → v2 =
2x + 4y = 0 1
• We compute A5 = A2 A2 A: ! ! !
4 1 1
4 9 16
A2 = = (23)
3 2 32 8 17
! ! ! !
9 16 9 16 1 4 1041 2084
A5 = = (24)
8 17 8 17 2 3 1042 2083
Page 12 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.11) Eigenvectors (continued) Without computing anything, find at least one eigenvector
associated with the following operators
Solution:
• The easiest eigenvector of the rotation around the z-axis is the versor of the z-axis itself e3 = 0 0 1 .
You can verify it, considering the matrix of a rotation with angle θ to be:
cos(θ) −sin(θ) 0
sin(θ) cos(θ) 0 (26)
0 0 1
0 0 1
The eigenvectors of this transformation are then given by the versor e1 , e2 rotated by θ, which corre-
spond to the matrix columns:
√ ! !
1 3 1 −1
e1 → , e2 → √ (29)
2 1 2 3
Page 13 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.12) Commutators The commutator between two linear operators A and B is defined as
compute the following commutators: [A, B], [B, C] and [A, C]. What do you notice?
A, B, C are the famous Pauli matrices which will play a central role throughout the course - they describe
the spin 1/2 system.
Solution:
We start computing the commutator:
! ! ! !
1 0 0 −i 0 −i 0 1
[A, B] = AB − BA = − (32)
0 1 i 0 i 0 1 0
! !
i 0 −i 0
= − (33)
0 −i 0 i
!
1 0
= 2i = 2iC (34)
0 −1
This is because the Pauli matrices are a set of unitary matrices following the commutation relation:
Page 14 of 15
Mathematical Tools Quantum Mechanics 2: Tutorial Exercises Linear Algebra
Problem 1.13) Some identities In this exercise, you will get to prove some of the most recurring (and
useful) matrix identities and properties.
• What is the condition for the product of two hermitian matrices to be hermitian?
Solution:
• To prove this, it is convenient to re-write matrix multiplication in terms of its components. (AB)ij =
Pn
k=1 Aik Bkj . Then, recalling that transposition corresponds to the inversion of rows and columns,
Pn Pn
we see that: (AB)Tji = (AB)ij = k=1 Aik Bkj = k=1 Bjk T
ATki = (B T AT )ji ; proving that (AB)T =
B T AT .
• To show that (AB)† = B † A† , we can simply use the result from the previous point together with the
definition of hermitian conjugate. (AB)† = ((AB)T )∗ = (B T AT )∗ = B † A† .
• To prove this identity, we can rely on the fact that M −1 M = I, with I being the identity matrix.
Then (AB)−1 AB = I. We can then immediately see that to satisfy this property, we need: (AB)−1 =
B −1 A−1 .
• A unitary matrix is defined as: A† = A−1 . Then we can easily see that given A and B unitary, we get:
(AB)† = (B † A† ) = (B −1 A−1 ) = (AB)−1 .
• Recall that a hermitian matrix is defined as: A† = A. Then we can easily see that given A and B
hermitian, the condition for their product to be hermitian is: (AB)† = B † A† = BA = AB, meaning
that the necessary requirement is [A, B] = 0.
Page 15 of 15