Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
documentation:language_reference:functions:newoperator [2026/11/12 17:51] – Maurits W. Haverkortdocumentation:language_reference:functions:newoperator [2026/11/17 07:05] (current) – Maurits W. Haverkort
Line 1: Line 1:
 ====== NewOperator ====== ====== NewOperator ======
 +;;# 
 +<color #ed1c24>Modified in 0.9.1</color>
 +;;#
  
 ### ###
-//NewOperator(name, ...)// creates one of the standard operators as described in the section on standard operators. A "Basis" option on the last position selects the one particle basis the orbitals are in, see below. //[[documentation:language_reference:functions:angularmomentumoperators|AngularMomentumOperators()]]// creates several of the standard operators of a single atomic shell in one call. The operators //"Dirac"//, //"AU"// and //"NuclearMultipole"// act on atomic orbitals given by their radial functions, see below.+//NewOperator(name, ...)// creates one of the standard operators as described in the section on standard operators. A "Basis" option on the last position selects the one particle basis the orbitals are in, see below. //[[documentation:language_reference:functions:angularmomentumoperators|AngularMomentumOperators()]]// creates several of the standard operators of a single atomic shell in one call. The operators //[[documentation:standard_operators:dirac_operator|"Dirac"]]//, //[[documentation:standard_operators:atomic_coulomb_repulsion|"AU"]]// and //[[documentation:standard_operators:nuclear_multipole|"NuclearMultipole"]]// act on atomic orbitals given by their radial functions, see below.
 ### ###
  
Line 27: Line 30:
     * "Name" a string specifying the name of the operator     * "Name" a string specifying the name of the operator
     * "NBitsKey" a list of integers specifying the number of bits in the key used for the hash lookup tables. Only useful when a lot of operations are done on the operators. Not used when Operator * Wavefunction is calculated.     * "NBitsKey" a list of integers specifying the number of bits in the key used for the hash lookup tables. Only useful when a lot of operations are done on the operators. Not used when Operator * Wavefunction is calculated.
 +    * "Basis" a string either "Y", "Z", "K", or "jjz" specifying the one particle orbital basis used for a standard operator related to an atomic (spherical) shell. Options are:
 +
 +^ value ^ basis ^ order of the indices ^
 +| "Y" | spherical harmonics $Y_{l,m}$, the default | //IndexUp// and //IndexDn// both hold the $2l+1$ orbitals from $m=-l$ to $m=l$ |
 +| "Z" | tesseral harmonics, the real combinations of $Y_{l,m}$ and $Y_{l,-m}$ | as for "Y", in the order of //[[documentation:language_reference:functions:ytozmatrix|YtoZMatrix()]]//, sine first, then cosine |
 +| "K" | cubic harmonics, defined for $l \leq 3$ | as for "Y", in the order of //[[documentation:language_reference:functions:ytokmatrix|YtoKMatrix()]]//, by irreducible representation |
 +| "jjz" | eigenstates of $j$ and $j_z$ | //IndexUp// holds the $2l$ states of $j=l-1/2$ and //IndexDn// the $2l+2$ states of $j=l+1/2$, both from $j_z=-j$ to $j_z=j$, in the order of //[[documentation:language_reference:functions:ytojjzmatrix|YtojjzMatrix()]]// |
  
  
Line 33: Line 43:
   * O : Operator   * O : Operator
  
-===== Basis ===== +===== Example 1 ===== 
- +;;#  
-### +<color #ed1c24>New in 0.9.1</color> 
-The standard operators created by //NewOperator(name, ...)// need to know which one particle states the indices refer to. This is set by a "Basis" option on the last position. The value is one of: +;;#
-### +
- +
-^ value ^ basis ^ order of the indices ^ +
-| "Y" | spherical harmonics $Y_{l,m}$, the default | //IndexUp// and //IndexDn// both hold the $2l+1$ orbitals from $m=-l$ to $m=l$ | +
-| "Z" | tesseral harmonics, the real combinations of $Y_{l,m}$ and $Y_{l,-m}$ | as for "Y", in the order of //[[documentation:language_reference:functions:ytozmatrix|YtoZMatrix()]]//, sine first, then cosine | +
-| "K" | cubic harmonics, defined for $l \leq 3$ | as for "Y", in the order of //[[documentation:language_reference:functions:ytokmatrix|YtoKMatrix()]]//, by irreducible representation | +
-| "jjz" | eigenstates of $j$ and $j_z$ | //IndexUp// holds the $2l$ states of $j=l-1/2$ and //IndexDn// the $2l+2$ states of $j=l+1/2$, both from $j_z=-j$ to $j_z=j$, in the order of //[[documentation:language_reference:functions:ytojjzmatrix|YtojjzMatrix()]]// |+
  
 <code Quanty Example.Quanty> <code Quanty Example.Quanty>
 -- the atomic operators of Ne on its own Dirac-Fock orbitals -- the atomic operators of Ne on its own Dirac-Fock orbitals
-G, F, x, Atom = CalculateAtomicBasisFunctions(10)+G, F, Atom = CalculateAtomicBasisFunctions(10)
 indices, NF = CreateAtomicIndicesList(Atom.Labels, {{"Kappas", true}}) indices, NF = CreateAtomicIndicesList(Atom.Labels, {{"Kappas", true}})
  
Line 74: Line 77:
 ### ###
  
-===== Example =====+===== Example 2 =====
  
 ### ###
Line 117: Line 120:
 ===== Table of contents ===== ===== Table of contents =====
 {{indexmenu>.#1}} {{indexmenu>.#1}}
 +
 +
  
  
  
Print/export