Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
eminus 3.0.3 documentation
Light Logo Dark Logo
eminus 3.0.3 documentation

Contents

  • Home
  • 1. Overview
  • 2. Installation
  • 3. Theory
  • 4. Examples
    • 4.1. Installation test
    • 4.2. Minimal example
    • 4.3. The Atoms object
    • 4.4. DFT calculations
    • 4.5. Input and output
    • 4.6. Advanced functionalities
    • 4.7. FOD and FLO generation
    • 4.8. Visualization
    • 4.9. SIC calculations
    • 4.10. Domain generation
    • 4.11. Germanium solid
    • 4.12. Wannier localization
    • 4.13. Geometry optimization
    • 4.14. Custom functionals 1
    • 4.15. Custom functionals 2
    • 4.16. FOD optimization
    • 4.17. Reduced density gradient
    • 4.18. k-points
    • 4.19. Band structures
    • 4.20. Smeared occupations
  • 5. Modules
    • 5.1. eminus
      • 5.1.1. demo
    • 5.2. atoms
      • 5.2.1. atoms.Atoms
    • 5.3. band_minimizer
      • 5.3.1. band_minimizer.auto
      • 5.3.2. band_minimizer.cg
      • 5.3.3. band_minimizer.get_grad_occ
      • 5.3.4. band_minimizer.get_grad_unocc
      • 5.3.5. band_minimizer.lm
      • 5.3.6. band_minimizer.pccg
      • 5.3.7. band_minimizer.pclm
      • 5.3.8. band_minimizer.scf_step_occ
      • 5.3.9. band_minimizer.scf_step_unocc
      • 5.3.10. band_minimizer.sd
    • 5.4. cell
      • 5.4.1. cell.Cell
    • 5.5. config
      • 5.5.1. config.ConfigClass
      • 5.5.2. config.info
    • 5.6. data
    • 5.7. dft
      • 5.7.1. dft.H
      • 5.7.2. dft.H_precompute
      • 5.7.3. dft.Q
      • 5.7.4. dft.get_epsilon
      • 5.7.5. dft.get_epsilon_unocc
      • 5.7.6. dft.get_grad
      • 5.7.7. dft.get_n_single
      • 5.7.8. dft.get_n_spin
      • 5.7.9. dft.get_n_total
      • 5.7.10. dft.get_phi
      • 5.7.11. dft.get_psi
      • 5.7.12. dft.guess_pseudo
      • 5.7.13. dft.guess_random
      • 5.7.14. dft.orth
      • 5.7.15. dft.orth_unocc
    • 5.8. domains
      • 5.8.1. domains.domain_cuboid
      • 5.8.2. domains.domain_isovalue
      • 5.8.3. domains.domain_sphere
      • 5.8.4. domains.truncate
    • 5.9. energies
      • 5.9.1. energies.Energy
      • 5.9.2. energies.get_E
      • 5.9.3. energies.get_Eband
      • 5.9.4. energies.get_Ecoul
      • 5.9.5. energies.get_Edisp
      • 5.9.6. energies.get_Eentropy
      • 5.9.7. energies.get_Eewald
      • 5.9.8. energies.get_Ekin
      • 5.9.9. energies.get_Eloc
      • 5.9.10. energies.get_Enonloc
      • 5.9.11. energies.get_Esic
      • 5.9.12. energies.get_Exc
    • 5.10. gga
      • 5.10.1. gga.calc_Vtau
      • 5.10.2. gga.get_grad_field
      • 5.10.3. gga.get_tau
      • 5.10.4. gga.gradient_correction
    • 5.11. gth
      • 5.11.1. gth.GTH
      • 5.11.2. gth.calc_Vnonloc
      • 5.11.3. gth.eval_proj_G
      • 5.11.4. gth.init_gth_loc
      • 5.11.5. gth.init_gth_nonloc
    • 5.12. kpoints
      • 5.12.1. kpoints.KPoints
      • 5.12.2. kpoints.bandpath
      • 5.12.3. kpoints.gamma_centered
      • 5.12.4. kpoints.get_brillouin_zone
      • 5.12.5. kpoints.kpoint_convert
      • 5.12.6. kpoints.kpoints2axis
      • 5.12.7. kpoints.monkhorst_pack
    • 5.13. localizer
      • 5.13.1. localizer.eval_psi
      • 5.13.2. localizer.get_FLO
      • 5.13.3. localizer.get_FO
      • 5.13.4. localizer.get_R
      • 5.13.5. localizer.get_S
      • 5.13.6. localizer.get_scdm
      • 5.13.7. localizer.get_wannier
      • 5.13.8. localizer.second_moment
      • 5.13.9. localizer.wannier_center
      • 5.13.10. localizer.wannier_cost
      • 5.13.11. localizer.wannier_supercell_cost
      • 5.13.12. localizer.wannier_supercell_grad
      • 5.13.13. localizer.wannier_supercell_matrices
    • 5.14. logger
      • 5.14.1. logger.CustomFormatter
      • 5.14.2. logger.CustomLogger
      • 5.14.3. logger.create_logger
      • 5.14.4. logger.get_level
      • 5.14.5. logger.name
    • 5.15. minimizer
      • 5.15.1. minimizer.auto
      • 5.15.2. minimizer.cg
      • 5.15.3. minimizer.cg_method
      • 5.15.4. minimizer.cg_test
      • 5.15.5. minimizer.check_convergence
      • 5.15.6. minimizer.linmin_test
      • 5.15.7. minimizer.lm
      • 5.15.8. minimizer.pccg
      • 5.15.9. minimizer.pclm
      • 5.15.10. minimizer.print_scf_step
      • 5.15.11. minimizer.scf_step
      • 5.15.12. minimizer.sd
    • 5.16. occupations
      • 5.16.1. occupations.Occupations
    • 5.17. operators
      • 5.17.1. operators.I
      • 5.17.2. operators.Idag
      • 5.17.3. operators.J
      • 5.17.4. operators.Jdag
      • 5.17.5. operators.K
      • 5.17.6. operators.L
      • 5.17.7. operators.Linv
      • 5.17.8. operators.O
      • 5.17.9. operators.T
    • 5.18. orbitals
      • 5.18.1. orbitals.FLO
      • 5.18.2. orbitals.FO
      • 5.18.3. orbitals.KSO
      • 5.18.4. orbitals.SCDM
      • 5.18.5. orbitals.WO
      • 5.18.6. orbitals.cube_writer
    • 5.19. potentials
      • 5.19.1. potentials.coulomb
      • 5.19.2. potentials.coulomb_lr
      • 5.19.3. potentials.ge
      • 5.19.4. potentials.get_pot_defaults
      • 5.19.5. potentials.harmonic
      • 5.19.6. potentials.init_pot
    • 5.20. scf
      • 5.20.1. scf.RSCF
      • 5.20.2. scf.SCF
      • 5.20.3. scf.USCF
    • 5.21. tools
      • 5.21.1. tools.center_of_mass
      • 5.21.2. tools.check_norm
      • 5.21.3. tools.check_ortho
      • 5.21.4. tools.check_orthonorm
      • 5.21.5. tools.cutoff2gridspacing
      • 5.21.6. tools.electronic_entropy
      • 5.21.7. tools.fermi_distribution
      • 5.21.8. tools.get_Efermi
      • 5.21.9. tools.get_bandgap
      • 5.21.10. tools.get_dipole
      • 5.21.11. tools.get_dos
      • 5.21.12. tools.get_elf
      • 5.21.13. tools.get_ip
      • 5.21.14. tools.get_isovalue
      • 5.21.15. tools.get_magnetization
      • 5.21.16. tools.get_multiplicity
      • 5.21.17. tools.get_reduced_gradient
      • 5.21.18. tools.get_spin_squared
      • 5.21.19. tools.get_tautf
      • 5.21.20. tools.get_tauw
      • 5.21.21. tools.gridspacing2cutoff
      • 5.21.22. tools.inertia_tensor
      • 5.21.23. tools.orbital_center
    • 5.22. units
      • 5.22.1. units.ang2bohr
      • 5.22.2. units.bohr2ang
      • 5.22.3. units.d2ebohr
      • 5.22.4. units.deg2rad
      • 5.22.5. units.ebohr2d
      • 5.22.6. units.ev2ha
      • 5.22.7. units.ha2ev
      • 5.22.8. units.ha2kcalmol
      • 5.22.9. units.ha2kelvin
      • 5.22.10. units.ha2ry
      • 5.22.11. units.kcalmol2ha
      • 5.22.12. units.kelvin2ha
      • 5.22.13. units.rad2deg
      • 5.22.14. units.ry2ha
    • 5.23. utils
      • 5.23.1. utils.BaseObject
      • 5.23.2. utils.Ylm_real
      • 5.23.3. utils.add_maybe_none
      • 5.23.4. utils.atom2charge
      • 5.23.5. utils.dotprod
      • 5.23.6. utils.get_lattice
      • 5.23.7. utils.handle_backend
      • 5.23.8. utils.handle_k
      • 5.23.9. utils.handle_spin
      • 5.23.10. utils.molecule2list
      • 5.23.11. utils.pseudo_uniform
      • 5.23.12. utils.vector_angle
    • 5.24. version
      • 5.24.1. version.info
    • 5.25. io
      • 5.25.1. io.read
      • 5.25.2. io.write
    • 5.26. io.cube
      • 5.26.1. io.cube.read_cube
      • 5.26.2. io.cube.write_cube
    • 5.27. io.gth
      • 5.27.1. io.gth.mock_gth
      • 5.27.2. io.gth.read_gth
    • 5.28. io.json
      • 5.28.1. io.json.read_json
      • 5.28.2. io.json.write_json
    • 5.29. io.pdb
      • 5.29.1. io.pdb.create_pdb_str
      • 5.29.2. io.pdb.write_pdb
    • 5.30. io.poscar
      • 5.30.1. io.poscar.read_poscar
      • 5.30.2. io.poscar.write_poscar
    • 5.31. io.traj
      • 5.31.1. io.traj.read_traj
      • 5.31.2. io.traj.write_traj
    • 5.32. io.xyz
      • 5.32.1. io.xyz.read_xyz
      • 5.32.2. io.xyz.write_xyz
    • 5.33. xc
    • 5.34. xc.gga_c_chachiyo
      • 5.34.1. xc.gga_c_chachiyo.gga_c_chachiyo
      • 5.34.2. xc.gga_c_chachiyo.gga_c_chachiyo_spin
    • 5.35. xc.gga_c_pbe
      • 5.35.1. xc.gga_c_pbe.gga_c_pbe
      • 5.35.2. xc.gga_c_pbe.gga_c_pbe_spin
    • 5.36. xc.gga_c_pbe_sol
      • 5.36.1. xc.gga_c_pbe_sol.gga_c_pbe_sol
      • 5.36.2. xc.gga_c_pbe_sol.gga_c_pbe_sol_spin
    • 5.37. xc.gga_x_chachiyo
      • 5.37.1. xc.gga_x_chachiyo.gga_x_chachiyo
      • 5.37.2. xc.gga_x_chachiyo.gga_x_chachiyo_spin
    • 5.38. xc.gga_x_pbe
      • 5.38.1. xc.gga_x_pbe.gga_x_pbe
      • 5.38.2. xc.gga_x_pbe.gga_x_pbe_spin
      • 5.38.3. xc.gga_x_pbe.pbe_x_base
    • 5.39. xc.gga_x_pbe_sol
      • 5.39.1. xc.gga_x_pbe_sol.gga_x_pbe_sol
      • 5.39.2. xc.gga_x_pbe_sol.gga_x_pbe_sol_spin
    • 5.40. xc.lda_c_chachiyo
      • 5.40.1. xc.lda_c_chachiyo.chachiyo_scaling
      • 5.40.2. xc.lda_c_chachiyo.lda_c_chachiyo
      • 5.40.3. xc.lda_c_chachiyo.lda_c_chachiyo_spin
    • 5.41. xc.lda_c_chachiyo_mod
      • 5.41.1. xc.lda_c_chachiyo_mod.chachiyo_scaling_mod
      • 5.41.2. xc.lda_c_chachiyo_mod.lda_c_chachiyo_mod
      • 5.41.3. xc.lda_c_chachiyo_mod.lda_c_chachiyo_mod_spin
    • 5.42. xc.lda_c_pw
      • 5.42.1. xc.lda_c_pw.lda_c_pw
      • 5.42.2. xc.lda_c_pw.lda_c_pw_spin
    • 5.43. xc.lda_c_pw_mod
      • 5.43.1. xc.lda_c_pw_mod.lda_c_pw_mod
      • 5.43.2. xc.lda_c_pw_mod.lda_c_pw_mod_spin
    • 5.44. xc.lda_c_vwn
      • 5.44.1. xc.lda_c_vwn.lda_c_vwn
      • 5.44.2. xc.lda_c_vwn.lda_c_vwn_spin
    • 5.45. xc.lda_x
      • 5.45.1. xc.lda_x.lda_x
      • 5.45.2. xc.lda_x.lda_x_spin
    • 5.46. xc.lda_xc_gdsmfb
      • 5.46.1. xc.lda_xc_gdsmfb.Coefficients
      • 5.46.2. xc.lda_xc_gdsmfb.PhiParams
      • 5.46.3. xc.lda_xc_gdsmfb.Zeta0Coeffs
      • 5.46.4. xc.lda_xc_gdsmfb.Zeta1Coeffs
      • 5.46.5. xc.lda_xc_gdsmfb.lda_xc_gdsmfb
      • 5.46.6. xc.lda_xc_gdsmfb.lda_xc_gdsmfb_spin
    • 5.47. xc.utils
      • 5.47.1. xc.utils.get_exc
      • 5.47.2. xc.utils.get_vxc
      • 5.47.3. xc.utils.get_xc
      • 5.47.4. xc.utils.get_xc_defaults
      • 5.47.5. xc.utils.get_zeta
      • 5.47.6. xc.utils.mock_xc
      • 5.47.7. xc.utils.parse_functionals
      • 5.47.8. xc.utils.parse_xc_libxc
      • 5.47.9. xc.utils.parse_xc_pyscf
      • 5.47.10. xc.utils.parse_xc_type
    • 5.48. extras
    • 5.49. extras.dispersion
      • 5.49.1. extras.dispersion.get_Edisp
    • 5.50. extras.fods
      • 5.50.1. extras.fods.get_fods
      • 5.50.2. extras.fods.get_localized_orbitals
      • 5.50.3. extras.fods.remove_core_fods
      • 5.50.4. extras.fods.split_fods
    • 5.51. extras.hdf5
      • 5.51.1. extras.hdf5.read_hdf5
      • 5.51.2. extras.hdf5.write_hdf5
    • 5.52. extras.jax
      • 5.52.1. extras.jax.I
      • 5.52.2. extras.jax.Idag
      • 5.52.3. extras.jax.J
      • 5.52.4. extras.jax.Jdag
    • 5.53. extras.libxc
      • 5.53.1. extras.libxc.libxc_functional
      • 5.53.2. extras.libxc.pyscf_functional
    • 5.54. extras.symmetry
      • 5.54.1. extras.symmetry.symmetrize
    • 5.55. extras.torch
      • 5.55.1. extras.torch.I
      • 5.55.2. extras.torch.Idag
      • 5.55.3. extras.torch.J
      • 5.55.4. extras.torch.Jdag
    • 5.56. extras.viewer
      • 5.56.1. extras.viewer.executed_in_notebook
      • 5.56.2. extras.viewer.plot_bandstructure
      • 5.56.3. extras.viewer.plot_dos
      • 5.56.4. extras.viewer.view
      • 5.56.5. extras.viewer.view_atoms
      • 5.56.6. extras.viewer.view_contour
      • 5.56.7. extras.viewer.view_file
      • 5.56.8. extras.viewer.view_kpts
    • 5.57. psp
    • 5.58. psp.pade
    • 5.59. psp.pbe
  • 6. Citation
  • 7. Changelog
  • 8. License
  • 9. Nomenclature
  • 10. Further information
Back to top
View this page

5.23.2. utils.Ylm_real¶

eminus.utils.Ylm_real(l, m, G)[source]¶

Calculate real spherical harmonics from cartesian coordinates.

Reference: https://scipython.com/blog/visualizing-the-real-forms-of-the-spherical-harmonics

Parameters:
  • l – Angular momentum number.

  • m – Magnetic quantum number.

  • G – Reciprocal lattice vector or array of lattice vectors.

Returns:

Real spherical harmonics.

Next
5.23.3. utils.add_maybe_none
Previous
5.23.1. utils.BaseObject
Copyright © 2021-2025, The eminus developers
Made with Furo
On this page
  • 5.23.2. utils.Ylm_real
    • Ylm_real()