QM Lecture 4: Operators and the Dirac Notation

**By: Tao Steven Zheng (郑涛)**

*This article was originally posted on Brilliant.org by the same author.*

## **Linear Operators in Hilbert Space**

By now you should be aware that quantum mechanics is highly mathematical. As the mathematical complexity of physics increases, very complicated equations should be handled with very economical representations. Theoretical mathematicians in the past century have devoted great labour to the organization and abstraction of functions and algebraic structures. In doing so, physicists who were struggling with frightening equations were beginning to take advantage of what was new in math. Not surprisingly, the founders of quantum mechanics did just that. To describe the physics of quantum mechanics, much of the formalism is structured around functional analysis and linear operators. I will not go into too much detail on both, so I will explain why functional analysis and linear operators are so important in quantum theory.

The metric space in which wavefunctions inhabit is determined by the four properties of wavefunctions outlined in Lecture 3. This metric space is called the **Hilbert space**. The Hilbert space is remarkable for many reasons, particularly in the generalization of the dot product (the inner product) in arbitrarily many dimensions (up to infinite dimensions). For these reasons, the Hilbert space is also called the complete inner product space. In order to communicate quantum mechanics mathematically, we need to know the following properties. I will represent everything in the Dirac notation (also known as the **bra-ket notation**), which is a quick and tidy way of expressing inner products.

1) Given two vectors

a
# ⟩

(

a

1

a

2

⋮

a

n

)

{\displaystyle |a \rangle=\left( \begin{matrix} { a }\_{ 1 } \\ { a }\_{ 2 } \\ \begin{matrix} \vdots \\ { a }\_{ n } \end{matrix} \end{matrix} \right)}

 and

b
# ⟩

(

b

1

b

2

⋮

b

n

)

{\displaystyle b \rangle =\left( \begin{matrix} { b }\_{ 1 } \\ { b }\_{ 2 } \\ \begin{matrix} \vdots \\ { b }\_{ n } \end{matrix} \end{matrix} \right) }

 , the inner product of the two vectors is

⟨
a

b

# i
1

n

a

i

∗

b

i

{\displaystyle \langle a|b \rangle = \sum\_{i=1}^{n} {{{a}\_{i}}^{\*}}{b}\_{i} }

 where

⟨
a

=

(

a

1

∗

a

2

∗

.
.
.

a

n

∗

)

{\displaystyle \langle a|= \left({ a }\_{ 1 }^{ \* }{ a }\_{ 2 }^{ \* }...{ a }\_{ n }^{ \* } \right) }

 is the **adjoint** (complex-conjugate transpose) of the vector

a
⟩

{\displaystyle |a\rangle }

.

**Note:** In mathematics, the adjoint of a matrix is often denoted

A

H

{\displaystyle {A}^{H} }

, but physicists find it much cooler to use the dagger

A

†

{\displaystyle {A}^{\dagger} }

. I should add that

A

†

=

(

A

∗

)

T

=

(

A

T

)

∗

{\displaystyle {A}^{\dagger} = {({A}^{\*})}^{T} ={({A}^{T})}^{\*} }

 where

∗

{\displaystyle \*}

 represents taking the complex conjugate of each entry and

T

{\displaystyle T}

represents the transpose of a matrix. You can't transpose a function, so

Ψ

†

=

Ψ

∗

{\displaystyle {\Psi}^{\dagger} = {\Psi}^{\*}}

 in the end of the day.

Similarly, the inner product for two functions

f
(
x
)

{\displaystyle f(x)}

,

g
(
x
)

{\displaystyle g(x)}

 over the interval

[
a
,
b
]

{\displaystyle [a, b]}

 is

⟨
f

g
# ⟩

∫

a

b

f

∗

(
x
)
g
(
x
)
d
x
.

{\displaystyle \langle f|g \rangle = \int\_{a}^{b} {f}^{\*}(x)g(x)dx. }

2) A linear transformation for a matrix

T

{\displaystyle T}

 is given by the matrix product,

T

a
# ⟩
T
a

{\displaystyle T|a \rangle =Ta }

 where

T

{\displaystyle T}

 is a square matrix.

3) A function is normalized if

⟨
f

f
# ⟩
1

{\displaystyle \langle f|f \rangle =1 }

. Two functions are orthogonal if

⟨
f

g
# ⟩
0

{\displaystyle \langle f|g \rangle = 0 }

. A set of functions is orthonormal if

⟨

f

m

f

n

# ⟩

δ

m
n

{\displaystyle \langle {f}\_{m}|{f}\_{n} \rangle ={\delta}\_{mn} }

 where

δ

m
n

{\displaystyle {\delta}\_{mn} }

 is the Kronecker delta.

4) A set of functions is complete if any other function can be expressed as a linear combination of the set of functions

f
(
x

# n
1

∞

c

n

f

n

(
x
)
.

{\displaystyle f(x)=\sum\_{n=1}^{\infty}{c}\_{n}{f}\_{n}(x). }

.

## **Hermitian Operators**

In quantum mechanics, quantities such as the position, momentum, and energy of particles are called observables. Each observable is represented by a special type of linear operator called the **Hermitian operator**. What makes Hermitian operators special is that the adjoint of a matrix or function is equal to itself. This is why Hermitian operators are sometimes called self-adjoint operators.

Hermitian operators play a major role in quantum mechanics because they conveniently describe the expectation values of observables. It is important to note that the expectation values of Hermitian operators are always real numbers.

But how do we know if an operator is Hermitian? Consider the integral definition of expectation of an operator

A
^

{\displaystyle \hat{A}}

:

⟨

A
^

# ⟩

∫

−
∞

∞

Ψ

∗

A
^

Ψ
d
x
.

{\displaystyle \langle \hat{A} \rangle=\int\_{-\infty}^{\infty} {\Psi}^{\*} \hat{A}\Psi dx. }

In Dirac notation, we denote the above integral

⟨
Ψ

A
^

Ψ
⟩

{\displaystyle \langle \Psi|\hat{A}\Psi \rangle }

. To test if the operator is Hermitian, we must show that

⟨
Ψ

A
^

Ψ
# ⟩
⟨

A
^

Ψ

Ψ
⟩

{\displaystyle \langle\Psi|\hat{A}\Psi\rangle =\langle \hat{A}\Psi|\Psi \rangle }

.

## **The Commutator**

In abstract terms, the **commutator** is a measure of how two operations fail at commuting. If two operators

A
,
B

{\displaystyle A, B}

 commute, then

A
# B
B
A

{\displaystyle AB = BA}

. Mathematically, the commutator is expressed as

[

A
,
B

]

=
A
B
−
B
A

{\displaystyle \left[A,B\right] = AB-BA }

. For example, the multiplication of numbers is commutative; hence,

[
2
,
5
# ]
2
(
5
)
−
5
(
2
# )
0

{\displaystyle [2,5]=2(5)-5(2)=0 }

. Remember that in quantum mechanics, linear operators correspond to observables. This means the commutator tells us that observing the system in different orders affects the outcome. To illustrate how the commutator is used, recall from Lecture 2 that the position and momentum operators are

x
^

=
x

{\displaystyle \hat{x} = x }

 and

p
^

=
−
i
ℏ

∂

∂
x

=

ℏ
i

∂

∂
x

{\displaystyle \hat{p} = -i\hbar\frac{\partial}{\partial x}=\frac{\hbar}{i}\frac{\partial}{\partial x} }

respectively. Since these operators act on functions, let us introduce a test wavefunction

ψ
(
x
)

{\displaystyle \psi(x) }

.

[

x
^

,

p
^

]

# ψ

(

x

ℏ
i

d
ψ

d
x

−

ℏ
i

d

(

x
ψ

)

d
x

)

{\displaystyle \left[ \hat { x } ,\hat { p } \right] \psi =\left( x\frac { \hbar }{ i } \frac { d\psi }{ dx } -\frac { \hbar }{ i } \frac { d\left( x\psi \right) }{ dx } \right) }

[

x
^

,

p
^

]

# ψ

ℏ
i

(

x

d
ψ

d
x

−
x

d
ψ

d
x

−
ψ

)

{\displaystyle \left[ \hat { x } ,\hat { p } \right] \psi = \frac{\hbar}{i}\left( x \frac { d\psi }{ dx } -x \frac { d \psi }{ dx } -\psi \right) }

[

x
^

,

p
^

]

# ψ
i
ℏ
ψ

{\displaystyle \left[ \hat { x } ,\hat { p } \right] \psi = i\hbar \psi }

Therefore,

[

x
^

,

p
^

]

=
i
ℏ

{\displaystyle \left[ \hat { x } ,\hat { p } \right] = i\hbar }

 once the test wavefunction is dropped. We obtained a non-zero result from the above calculation. This demonstrates that the position and momentum operates do not commute. Physicists call non-commutative pairs of linear operators incompatible observables.

Although the commutator was designed to test **commutative algebras**, physicists found a clever way to exploit the commutator. Derivatives are important in physics, and in quantum mechanics we take the time derivative of the expectation value of observables. Let's see where the math takes us.

d

d
t

⟨

A
^

# ⟩

d

d
t

⟨
Ψ

A
^

Ψ
⟩

{\displaystyle \frac{d}{dt}\langle \hat{A}\rangle =\frac{d}{dt}\langle \Psi|\hat{A}\Psi \rangle }

By the product rule, we get

d

d
t

⟨

A
^

# ⟩
⟨

Ψ

t

A
^

Ψ
⟩
⟨
Ψ

A
^

t

Ψ
⟩
⟨
Ψ

A
^

Ψ

t

⟩

{\displaystyle \frac{d}{dt}\langle\hat{A}\rangle =\langle {\Psi}\_{t}|\hat{A}\Psi\rangle + \langle\Psi|{\hat{A}}\_{t}\Psi\rangle + \langle\Psi|\hat{A}{\Psi}\_{t}\rangle }

. And since the Schrödinger equation is

i
ℏ

∂
Ψ

∂
t

=

H
^

Ψ

{\displaystyle i\hbar\frac{\partial \Psi}{\partial t} = \hat{H}\Psi }

, we can simplify the above equation:

d

d
t

⟨

A
^

# ⟩

−
1

i
ℏ

⟨

H
^

Ψ

A
^

Ψ
⟩

1

i
ℏ

⟨
Ψ

A
^

H
^

Ψ
⟩
⟨

∂

A
^

∂
t

⟩
.

{\displaystyle \frac{d}{dt}\langle\hat{A}\rangle =\frac{-1}{i\hbar}\langle\hat{H}\Psi|\hat{A}\Psi\rangle +\frac{1}{i\hbar}\langle \Psi|\hat{A}\hat{H}\Psi\rangle + \langle \frac{\partial \hat{A}}{\partial t} \rangle. }

Now

H
^

{\displaystyle \hat{H}}

 is Hermitian, so

⟨

H
^

Ψ

A
^

Ψ
# ⟩
⟨
Ψ

A
^

H
^

Ψ
⟩

{\displaystyle \langle \hat{H}\Psi|\hat{A}\Psi \rangle = \langle \Psi|\hat{A}\hat{H}\Psi \rangle }

; therefore,

d

d
t

⟨

A
^

# ⟩

i
ℏ

⟨
[

H
^

,

A
^

]
⟩
⟨

∂

A
^

∂
t

⟩
.

{\displaystyle \frac{d}{dt}\langle \hat{A} \rangle =\frac{i}{\hbar}\langle [\hat{H},\hat{A}] \rangle +\langle \frac{\partial \hat{A}}{\partial t} \rangle. }

This is an important result that has wide applications in quantum mechanics. We will encounter it in the future.

To speed up computations with the commutator, it is useful to know the following properties for operators

A
,
B
,
C

{\displaystyle A, B, C}

:

1. [
A
B
,
C
# ]
[
A
,
C
]
[
B
,
C
]

{\displaystyle [A + B, C] = [A, C] + [B, C]}
2. [

A
n

,
A
# ]
0

{\displaystyle [A^n, A] = 0}
3. [
A
,
B
# ]
−
[
B
,
A
]

{\displaystyle [A, B] = -[B, A] }
4. [
A
B
,
C
# ]
A
[
B
,
C
]
[
A
,
C
]
B

{\displaystyle [AB, C] = A[B, C] + [A, C]B}
5. [
A
,
B
C
# ]
[
A
,
B
]
C
B
[
A
,
C
]

{\displaystyle [A, BC] = [A, B]C + B[A, C]}

## **Problems**

### **Problem 1: Ehrenfest Theorem**

Use the formula

d

d
t

⟨

A
^

# ⟩

i
ℏ

⟨
[

H
^

,

A
^

]
⟩
⟨

∂

A
^

∂
t

⟩

{\displaystyle \frac{d}{dt}\langle \hat{A} \rangle =\frac{i}{\hbar}\langle [\hat{H},\hat{A}] \rangle +\langle \frac{\partial \hat{A}}{\partial t} \rangle }

 to prove the Ehrenfest theorem

{

m

d

d
t

⟨

x
^

⟩

=
⟨

p
^

⟩

d

d
t

⟨

p
^

⟩

=
−
⟨

∂

V
^

∂
x

⟩

{\displaystyle \begin{cases}
m\frac{d}{dt}\langle \hat{x}\rangle &= \langle \hat{p} \rangle \\[5 pt]
\frac{d}{dt}\langle \hat{p}\rangle &= -\langle \frac{\partial \hat{V}}{\partial x} \rangle \\

\end{cases}}

where

V
^

=
V
(
x
)

{\displaystyle \hat{V} = V(x)}

 is the potential energy. [**Hint:** Remember

H
^

=

p
^

2

2
m

V
^

{\displaystyle \hat{H} = \frac{{\hat{p}}^{2}}{2m}+\hat{V} }

.]

Solution

### **Problem 2: Virial Theorem**

Use the formula

d

d
t

⟨

A
^

# ⟩

i
ℏ

⟨
[

H
^

,

A
^

]
⟩
⟨

∂

A
^

∂
t

⟩

{\displaystyle \frac{d}{dt}\langle \hat{A} \rangle =\frac{i}{\hbar}\langle [\hat{H},\hat{A}] \rangle +\langle \frac{\partial \hat{A}}{\partial t} \rangle }

 to show that

d

d
t

⟨

x
^

p
^

# ⟩
2
⟨

T
^

⟩
−
⟨

x
^

∂

V
^

∂
x

⟩

{\displaystyle \frac{d}{dt}\langle \hat{x}\hat{p} \rangle=2 \langle \hat{T} \rangle- \langle \hat{x}\frac{\partial \hat{V}}{\partial x} \rangle }

, where

T
^

{\displaystyle \hat{T}}

 is the kinetic energy and

V
^

{\displaystyle \hat{V}}

 is the potential energy. [**Hint:** Remember

H
^

=

T
^

V
^

=

p
^

2

2
m

V
^

{\displaystyle \hat{H} = \hat{T}+\hat{V} = \frac{{\hat{p}}^{2}}{2m}+\hat{V} }

, where

V
^

=
V
(
x
)

{\displaystyle \hat{V} = V(x)}

.] Then show that the expression reduces to

2
⟨
T
# ⟩
⟨

x
^

∂

V
^

∂
x

⟩

{\displaystyle 2\langle T \rangle = \langle \hat{x} \frac{\partial \hat{V}}{\partial x} \rangle }

 for a stationary state.

Solution

### **Problem 3: Orthonormal Function**

Consider the function

Ψ
(
x

# k
1

n

c

k

s
i
n

(

k
π
x

a

)

{\displaystyle \Psi(x)=\sum\_{k=1}^{n}{c}\_{k}sin\left(\frac{k\pi x}{a}\right) }

. Prove that

∑

# k
1

n

c

k

2

=
1

{\displaystyle \sum\_{k=1}^{n}{|{c}\_{k}|}^{2}=1 }

 is a necessary condition for

f
(
x
)

{\displaystyle f(x)}

 to be normalized. Note that

c

k

2

{\displaystyle {|{c}\_{k}|}^{2} }

 means

c

k

∗

c

k

{\displaystyle {c}\_{k}^{\*}{c}\_{k} }

. If

c

k

{\displaystyle {c}\_{k} }

 are real, then it is equivalent to the square of its absolute value.

### **Problem 4: Dirac Notation**

Use the Dirac notation (bra-ket notation) to prove

⟨
Ψ

H
^

Ψ

# k
1

n

E

n

c

k

2

{\displaystyle \langle \Psi|\hat{H}\Psi \rangle = \sum\_{k=1}^{n}{E}\_{n}{|{c}\_{k}|}^{2} }

, where

E

n

{\displaystyle {E}\_{n} }

 are the energy eigenvalues. Give a physical interpretation of this fact.

### **Problem 5: Eigenstates of an Infinite Square Well**

Consider a particle of mass

m

{\displaystyle m}

 trapped in an infinite square well of width

# a
2

{\displaystyle a=2}

:

Ψ
(
x
,
0
# )

2

2

5

Ψ
1

(
x
)

3
i

5

Ψ
2

(
x
)
−

2

2

5

Ψ
4

(
x
)

{\displaystyle \Psi(x,0)=\frac{2\sqrt{2}}{5} \Psi\_1 (x) + \frac{3i}{5} \Psi\_2 (x) - \frac{2\sqrt{2}}{5} \Psi\_4 (x) }

**Part 1:** What are the energy eigenstates?

**Part 2:** What is the probability of finding each eigenstate? Verify that all probabilities sum up to 1.

**Part 3:** Calculate the Hamiltonian

⟨

H
^

⟩

{\displaystyle \langle \hat{H} \rangle }

.

Solution