# Hydrogen

Equations tagged (BSXX.YY) reference

• Bethe, H., & Salpeter, E. (1977). Quantum mechanics of one-and two-electron atoms. New York: Plenum Pub. Corp.

All angular integrals are computed using AngularMomentumAlgebra.jl.

Hydrogen.atomic_hamiltonianMethod
atomic_hamiltonian(orbitals[; Efun=orbital_energy, neutral_zero=true])

Return the diagonal matrix whose elements corresponds to the energies of each of the orbitals, by default orbital_energy is used to determine the energy, which dispatches on the orbital type to return the appropriate energy (non-relativistic or relativistic), and all energies are shifted such that 1s has zero energy, if neutral_zero==true.

Examples

julia> atomic_hamiltonian(os"1[s] 2[s-p]")
3×3 LinearAlgebra.Diagonal{Float64,Array{Float64,1}}:
0.0   ⋅      ⋅
⋅   0.375   ⋅
⋅    ⋅     0.375

julia> atomic_hamiltonian(ros"1[s] 2[s-p]")
4×4 LinearAlgebra.Diagonal{Float64,Array{Float64,1}}:
0.0   ⋅         ⋅         ⋅
⋅   0.375005   ⋅         ⋅
⋅    ⋅        0.375005   ⋅
⋅    ⋅         ⋅        0.375006
source
Hydrogen.dipole_matrixFunction
dipole_matrix(orbitals[, component=:z])

Return the sparse matrix whose elements correspond to the dipole moments between all of the orbitals as measured along the Cartesian direction indicated by component.

Examples

julia> dipole_matrix(sos"1[s] 2[s-p]")
10×10 SparseArrays.SparseMatrixCSC{Float64,Int64} with 8 stored entries:
[7, 1]  =  0.744936
[8, 2]  =  0.744936
[7, 3]  =  3.0
[8, 4]  =  3.0
[1, 7]  =  0.744936
[3, 7]  =  3.0
[2, 8]  =  0.744936
[4, 8]  =  3.0

julia> dipole_matrix(sos"1[s] 2[s-p]", :y)
10×10 SparseArrays.SparseMatrixCSC{Complex{Float64},Int64} with 16 stored entries:
[5 ,  1]  =  0.0+0.526749im
[9 ,  1]  =  0.0+0.526749im
[6 ,  2]  =  0.0+0.526749im
[10,  2]  =  0.0+0.526749im
[5 ,  3]  =  0.0+2.12132im
[9 ,  3]  =  0.0+2.12132im
[6 ,  4]  =  0.0+2.12132im
[10,  4]  =  0.0+2.12132im
[1 ,  5]  =  -0.0-0.526749im
[3 ,  5]  =  -0.0-2.12132im
[2 ,  6]  =  -0.0-0.526749im
[4 ,  6]  =  -0.0-2.12132im
[1 ,  9]  =  -0.0-0.526749im
[3 ,  9]  =  -0.0-2.12132im
[2 , 10]  =  -0.0-0.526749im
[4 , 10]  =  -0.0-2.12132im
source
Hydrogen.dipole_momentFunction
dipole_moment(a, b[, component=:z])

Compute the dipole moment between orbitals a and b along the Cartesian direction indicated by component. The radial integral is computed using radial_dipole_moment and the angular integral using AngularMomentumAlgebra.jl.

julia> a,b,c,d = SpinOrbital(o"1s", 0, half(1)), SpinOrbital(o"2s", 0, half(1)), SpinOrbital(o"2p", 0, half(1)), SpinOrbital(o"2p", 1, half(1))
(1s₀α, 2s₀α, 2p₀α, 2p₁α)

julia> dipole_moment(a, c)
0.7449355390278029

julia> dipole_moment(b, c)
2.999999999999999

julia> dipole_moment(a, d)
0.0

julia> dipole_moment(a, d, :x)
-0.5267489711934153
source
Hydrogen.factorial_ratioMethod
factorial_ratio(a,b)

Compute

$$$\frac{a!}{b!}$$$

via simple looping. This is efficient if $\abs{a-b}$ is not too large.

source
Hydrogen.non_relativistic_energyFunction
non_relativistic_energy(n[, Z=1])

Returns the non-relativistic energy of a hydrogen orbital with principal quantum number $n$ (and an effective nuclear charge $Z$) according to

$$$\begin{equation} \tag{BS2.11} E_n = -\frac{Z^2}{2n^2} \end{equation}$$$
source
Hydrogen.non_relativistic_energyMethod
non_relativistic_energy(o)

Return the non-relativistic energy of the orbital o.

Examples

julia> non_relativistic_energy(o"1s")
-0.5

julia> non_relativistic_energy(o"2p")
-0.125

julia> non_relativistic_energy(ro"2p")
-0.125

julia> non_relativistic_energy(ro"2p-")
-0.125
source
Hydrogen.non_relativistic_orbitalFunction
non_relativistic_orbital(n, ℓ[, Z = 1])

Returns a callable object to evaluate the reduced radial orbital $P_{nℓ}(r)$ of a hydrogen-like atom in non-relativistic theory, given by

$$$P_{nℓ}(r) = \sqrt{ \left(\frac{2Z}{n}\right)^3 \frac{(n-\ell-1)!}{2n(n+\ell)!} } \left(\frac{2Z}{n} \cdot r\right)^\ell L^{(2\ell+1)}_{n-\ell-1}\left(\frac{2Z}{n} \cdot r\right) \exp\left(-\frac{Z}{n} \cdot r\right)$$$

$P_{nℓ}(r)$ is defined through

$$$\psi_{nlm}(r,\theta,\varphi) = \frac{1}{r} P_{nℓ}(r) Y_{ℓm}(\theta,\varphi)$$$

where $\psi_{nlm}$ are the normalized solutions to the non-relativistic single-particle Schrödinger equation for a point-like nucleus with charge Z, and where $Y_{ℓm}$ are the spherical harmonics.

source
Hydrogen.orbital_energyMethod
orbital_energy(o)

Return the energy of orbital o, automatically choosing between non_relativistic_energy and relativistic_energy, depending on the type of o.

Examples

julia> orbital_energy(o"1s")
-0.5

julia> orbital_energy(ro"1s")
-0.5000066565961734

julia> orbital_energy(o"2p")
-0.125

julia> orbital_energy(ro"2p")
-0.1250004160284539
source
Hydrogen.radial_dipole_momentMethod
radial_dipole_moment(a, b)

Compute the radial dipole moment between the orbitals a and b according to

\begin{align} \tag{BS63.2} R_{n \ell}^{n',\ell-1} &= ABCD, & n \neq n'\\ \tag{BS63.5} R_{n,\ell-1}^{n\ell} &= R_{n\ell}^{n,\ell-1} = \frac{3}{2} n\sqrt{n^2-\ell^2}, & n = n', \end{align}

where

\begin{aligned} A &= \frac{(-)^{n'-\ell}}{4(2\ell-1)!}, \\ B &= \sqrt{\frac{(n+\ell)!(n'+\ell-1)!}{(n-\ell-1)!(n'-\ell)!}}, \\ C &= \frac{(4nn')^{\ell+1}(n-n')^{n+n'-2\ell-2}}{(n+n')^{n+n'}}, \\ D &= {_2}F_1(-n_r, -n_r', 2\ell, x) - \left(\frac{n-n'}{n+n'}\right)^2 {_2}F_1(-n_r-2, -n_r', 2\ell, x), \\ n_r &= n-\ell-1, \quad n_r' = n' - \ell, \quad x = -\frac{4nn'}{(n-n')^2}, \end{aligned}

and ${_2}F_1(a,b,c;x)$ is a hypergeometric function that can be computed used HyperGeometricFunctions.jl.

source
Hydrogen.relativistic_energyFunction
relativistic_energy(n, κ[, Z=1])

Returns the relativistic energy of a hydrogen orbital with principal quantum number $n$ and "angular momentum" quantum number $κ$ (and an effective nuclear charge $Z$) according to

$$$\begin{equation} \tag{BS14.29*} E_{nκ} = c^2\left[ -1+ \frac{1}{\sqrt{1 + \left( \frac{Zα}{n - \abs{κ} + \sqrt{κ^2-Z^2α^2}} \right)^2}} \right] \end{equation}$$$

where the energy has been shifted by $-c^2$ compared to $\mathrm{(BS14.29)}$.

source
Hydrogen.relativistic_energyMethod
relativistic_energy(o::RelativisticOrbital)

Return the relativistic energy for the orbital o.

Example

julia> relativistic_energy(ro"1s")
-0.5000066565961734

julia> relativistic_energy(ro"2p-")
-0.12500208019062972

julia> relativistic_energy(ro"2p")
-0.1250004160284539
source