Problem 1. Given the Pauli matrices
and a hermitian matrix that has dimensions 8x8 and written as:
Find the eigenvalues and and eigenvectors.
Solution 1. The interesting thing to note here is that the hermitian matrix can be written as the direct sum:
This means that the eigenspectrum can be calculated from the
xxxxxxxxxx
3
1
begin
2
using SymPy
3
end
x
16
1
begin
2
𝑖 = sympy.I
3
⊗(x,y)=kron(x,y)
4
⊗(x::Array{Sym,2},y::Array{Sym,2}) = kron(x,y)
5
𝐓(x::Array{Sym,2}) = sympy.Matrix(sympy.transpose(x))
6
7
"""Direct sum of vector space.
8
"""
9
⊕(x,y) = begin
10
xdim = size(x);
11
ydim = size(y);
12
M = [ x zeros(Int,xdim[1],ydim[2]);
13
zeros(Int,ydim[1],xdim[2]) y ];
14
return M
15
end
16
end;
xxxxxxxxxx
1
1
begin
2
σ₁ = [0 1;
3
1 0]
4
σ₂ = [0 -𝑖;
5
𝑖 0]
6
σ₃ = [1 0;
7
0 -1]
8
end;
The hermitian matrix given by the expression above is then:
x
1
H = (σ₁ ⊗ σ₁ + σ₂ ⊗ σ₂ + σ₃ ⊗ σ₃) ⊗ σ₁
Now just checking the direct sum comparison.
x
1
begin
2
D = Sym[ 0 -1 0 2;
3
-1 0 2 0;
4
0 2 0 -1;
5
2 0 -1 0];
6
H′ = σ₁ ⊕ D ⊕ σ₁
7
end
x
1
H == H′ "Direct sum doesn't equal hermitian matrix"
Now finding the eigenvalues and eigenvectors
x
1
begin
2
ℍ = H.eigenvects(chop=true)
3
#unpack :e - eigenvalue, :m - multiplicty (degeneracy)
4
eₕ = [Dict(:e=>e[1],:m=>e[2]) for e in ℍ]
5
vₕ = [v[end][1:end] for v in ℍ]
6
end;
Let see how these eigenvalues compare to the eigenvalues of the matrix
xxxxxxxxxx
5
1
begin
2
𝔻 = D.eigenvects(chop=true)
3
eᵨ = [Dict(:e=>e[1],:m=>e[2]) for e in 𝔻]
4
vᵨ = [v[end][1:end] for v in 𝔻]
5
end;
we find that the eigenvalues are the same but the degeneracy is now removed. We can look at the eigenvectors the the
eigenvector index 1