What is "Density of States" and how does one generally find it? I'm walking out of a graduate quantum midterm kicking myself because I was asked to compute density of states as a function of energy for a spin $1/2$ particle of mass $m$ in a hard wall box of length $L$, subjected to a magnetic field of strength $h^z>0$, and I just had no idea where to begin. I was given the eigenergies:
$$E(n,\sigma^z)=K_n-h^z\sigma^z$$
where $K_n=\frac{\pi^2\hbar^2n^2}{2mL^2}$. I was supposed to set $\sigma^z=1$ initially, then combine $\sigma^z=\pm 1$ results to get the full picture. I know that a state $n$ should have wave number:
$$k=\frac{n\pi }{L}=\sqrt{\frac{2m (K_n-h^z)}{\hbar}}$$
And that I can put each $k$ in a $1$-D box of size $L/\pi$, but I don't where to go from there and worse I don't actually know what I'm doing. I know this important for figuring out transition rates, but I just don't understand the reasoning presented by either my professor or Sakurai.
Ideally, if someone could explain what density of states is mathematically (every source I see just say its the number of states in the energy interval $(E,E+dE)$, which is a statement I understand from a physical perspective but means nothing to me mathematically since I'm fairly positive $dE$ is not a differential form in the sense that I'm used to), and how one generally finds it given that we know the energies as function of $n$, that would be amazing.
I apologize for my ignorance, or if anything I've said is incorrect, quantum mechanics seems especially difficult for me for some reason.
 A: The $dE$ is meant to be a differential form, and if you define $\Omega(E)$ as the number of states below a given energy, then the density of states is simply $d\Omega/dE$. Which connects to the definition that you were given by the definition of a derivative as $$\lim_{dE\to0}\frac{\Omega(E+dE)-\Omega(E)}{dE}=\lim_{dE\to0}\frac{\text{definition you were given}}{dE} $$
This isn't a super clear way of describing the density of states in this case, because the number of states below a specific energy $E$ is a discontinuous function in quantum mechanics when the eigenenergies are discrete. Thus, $\Omega$ is formally not differentiable.
The kludge that is often used here is to notice that, for a one-dimensional system, the quantum number $n$ is related to $\Omega$, and then treating both as a continuous variable that can be differentiated. So, for instance, in the particle in a well without the electric field, the density of states would be found as such:
$$ E_n=\frac{\pi^2\hbar^2n^2}{2mL^2} $$
$$ E(\Omega)=\frac{\pi^2\hbar^2\Omega^2}{2mL^2} $$
$$ \Omega(E)=\sqrt{\frac{2mL^2E}{\pi^2\hbar^2}} $$
$$ \frac{d\Omega}{dE}=\sqrt{\frac{mL^2}{2\pi^2\hbar^2E}} $$
Note that in this case, $n$ is just $\Omega$, because there is one state for each value of the quantum number. In the case of the problem you were asked, there are two states for each value of the quantum number. Although since they have different energies, you can't simply set $\Omega=2n$ and run with it, you should simply find the density of states for the two spin states separately and combine them.
A: The number of states $\Omega$ below an energy $E$ in general is given by counting the states $i$:
$\Omega(E)=\sum_{i} U(E-E_i)$
Where $U$ is the Heaviside step function.
The density of states is the derivative of the number of states:
$\rho(E)=\frac{\partial\Omega(E)}{\partial E}=\sum_i \delta(E-E_i)$
The real meat of solving these problems is to find how to express the sum over the states in terms of the variables you are given for the energy.
For your problem, $\sum_i = \sum_{n=1}^{\infty}\sum_{\sigma=-1, 1} $
So we have:
$\rho(E)=\sum_{n=1}^{\infty}\sum_{\sigma=-1, 1}\delta(E-K_n+h\sigma)$
Which, if we make an approximation assuming L is large compared to our smallest wavelength, we can say $\sum_{n=1}^{\infty} \approx \frac{L}{\pi}\int dk$, and we know $k=n\pi/L$:
$\rho(E)=\frac{L}{\pi}\int dk \sum_{\sigma} \delta(E-k^2\hbar^2/2m+h\sigma)$
$\rho(E)=\frac{L}{\pi}\sum_{\sigma}\sqrt{{m}/{2\hbar^2(E-h\sigma)}}$
$\rho(E)=\frac{L}{\pi}\left(\sqrt{{m}/{2\hbar^2(E-h)}} + \sqrt{{m}/{2\hbar^2(E+h)}}\right)$
In general, there isn't a way to find the density of states. You can make complicated combinatorics problems, or sums that don't approximate into integrals in which you can evaluate the delta function.
