This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
numexercises7_15 [2014/07/15 08:31] bogner |
numexercises7_15 [2014/07/18 05:04] (current) schunck |
||
---|---|---|---|
Line 19: | Line 19: | ||
Recall that the HO wavefunctions are given by | Recall that the HO wavefunctions are given by | ||
\begin{equation} | \begin{equation} | ||
- | R_{nl}(r) = \frac{A_{nl}}{b^{3/2}}x^le^{-x^2/2}L_{n}^{l+1/2}(x^2)\,, | + | R_{nl}(r) = \frac{A_{nl}}{b^{3/2}}\xi^le^{-\xi^2/2}L_{n}^{l+1/2}(\xi^2)\,, |
\end{equation} | \end{equation} | ||
- | where the oscillator length $b\equiv \sqrt{\hbar/(m\omega)}$, and the dimensionless variable $x\equiv r/b$. The normalization constant is given by | + | where the oscillator length $b\equiv \sqrt{\hbar/(m\omega)}$, and the dimensionless variable $\xi\equiv r/b$. The normalization constant is given by |
\begin{equation} | \begin{equation} | ||
Line 29: | Line 29: | ||
* Using the uploaded code for guidance, make your own subroutine to calculate $L_{n}^{\alpha}(x)$. Then, using the definition of the HO wf's, make a subroutine/function to calculate $R_{nl}(r)$. | * Using the uploaded code for guidance, make your own subroutine to calculate $L_{n}^{\alpha}(x)$. Then, using the definition of the HO wf's, make a subroutine/function to calculate $R_{nl}(r)$. | ||
+ | |||
+ | * Why should you not calculate the factorial and double factorial functions appearing in $A_{nl}$ naively as they are written? Hint: What happens for large values of $n$ and $l$? How might you avoid this problem? Hint: What is $\log{ABC\cdots}$? | ||
* As a check on your code, check the orthogonality of the $R_{nl}$, | * As a check on your code, check the orthogonality of the $R_{nl}$, | ||
Line 36: | Line 38: | ||
\end{equation} | \end{equation} | ||
- | * As discussed in the HO notes, the "best" type of Gaussian quadrature over HO wf's is Gauss-Laguerre. However, as you see in the code {{:coulomboscrelme.f90.zip|here}}, you can use Gauss-Legendre as well. You need to play around to make sure your upper limit $r_{max}$ of your discretization range is sufficiently large. (Note: there are plenty of freely downloadable Gauss-Legendre subroutines.) In this way, the orthogonality check takes the form | + | * As discussed in the HO notes, the "best" type of Gaussian quadrature over HO wf's is Gauss-Laguerre. However, as you see in the code {{:coulomboscrelme.f90.zip|here}}, you can use Gauss-Legendre as well. You need to play around to make sure your upper limit $r_{max}$ of your discretization range is sufficiently large. (Note: there are plenty of freely downloadable Gauss-Legendre subroutines. Please feel free to use one instead of writing it from scratch.) In this way, the orthogonality check takes the form |
\begin{equation} | \begin{equation} | ||
Line 43: | Line 45: | ||
where the sum is over the N mesh points and $w_{i}$ are the quadrature weights. | where the sum is over the N mesh points and $w_{i}$ are the quadrature weights. | ||
+ | |||
+ | * Now, write a subroutine to evaluate the matrix elements $\langle nl|V|n'l\rangle$ for some arbitrary central two-body potential $V(r)$. | ||
+ | |||
+ | * To test your $\langle nl|V|n'l\rangle$ routine, apply it to the coulomb potential in the hydrogen atom problem. Use atomic units ($\hbar=e=1/4\pi\epsilon_0=m_e=1$). Now, build the Hamiltonian matrix $\langle nl|H|n'l\rangle$ (you may take $l=0$) for the hydrogen atom, keeping states $n,n'< N_{max}$. Use the analytic expressions for the K.E. matrix elements in {{:ho_spherical.pdf|}}. Now diagonalize the matrix to get the ground state energy. | ||
+ | |||
+ | * For a given $N_{max}$, repeat the calculation for many different values of oscillator length and plot the ground state versus $b$. Repeat for larger values of $N_{max}$ and put the $E$ versus $b$ curves on the same plot. Are they behaving according to expectation? (Hint: the diagonalization in a finite basis is variational.) Should results depend on $b$ as $N_{max}\rightarrow\infty$? | ||
+ | |||
+ |