A two state system is the simplest to exhibit quantum behavior. For
such a system, we can write the Hamiltonian as a 2
by 2 matrix in some basis {∣1⟩,∣2⟩}
H=(E1Δ∗ΔE2).
Here ⟨1∣H∣1⟩=E1 is the energy of being in state ∣1⟩, E2 is the energy of being in state ∣2⟩, and Δ is
the energy associated with transitioning between the two states
(i.e. tunneling). In some basis, H will be diagonal, but this is
often not the most natural basis to write it in.
To find the eigenstates and diagonalize H we can take a similar
approach to what we did with spin. We defined the three
Pauli matrices σxyz and the spin operators Sxyz, and
then used these to define a spin operator Sn=nxSx+nySy+nzSz in some arbitrary direction n=(nx,ny,nz). We found the eigenvalues were ±2ℏ and found the
eigenvectors.
The last term of the new expression gn⋅σ is
like the spin operator Sn, but with a g instead of
2ℏ. We can use the same eigenvectors and eigenvalues we
already found for Sn here. The g01^ term is just the
identity, and so will add g0 to each eigenvalue without affecting
the eigenvector.
The eigenvalues g0±g represent a ground state and an excited
state. When Δ=0, g1 and g2 disappear, and the
eigenvectors become (1,0) and (0,1) as expected, with eigenvalues
E1 and E2.