MullikenPopulation¶
- class MullikenPopulation(configuration)¶
Class for calculating the Mulliken population for a configuration.
- Parameters:
configuration (
DeviceConfiguration
|BulkConfiguration
|MoleculeConfiguration
.) – The Configuration which the Mulliken population should be calculated for.
- atomicAngles()¶
- Returns:
The atomic polarization angles as a list of (\(\theta\), \(\phi\)) tuples representing spherical coordinates.
- Return type:
list of tuple
- atomicCharge()¶
Calculate the charge of each atom.
- Returns:
The charge of each atom in a length n array.
- Return type:
PhysicalQuantity of type charge
- atoms(spin=None)¶
Return an array with the Mulliken population of each atom.
- Parameters:
spin (
Spin.All
|Spin.Sum
|Spin.X
|Spin.Y
|Spin.Z
|Spin.Up
|Spin.Down
|Spin.RealUpDown
|Spin.ImagUpDown
) – The mulliken population is calculated for this spin. Default:Spin.All
- bond(atom_i, atom_j)¶
Return a float which is the Mulliken population projected onto the bond between
atom_i
andatom_j
.- Parameters:
atom_i (int) – Index of the first atom in the bond projection.
atom_i
should satisfy0 <= atom_i < number_of_atoms
.atom_j (int) – Index of the second atom in the bond projection.
atom_j
should satisfy0 <= atom_j < number_of_atoms
.
- metatext()¶
- Returns:
The metatext of the object or None if no metatext is present.
- Return type:
str | None
- nlprint(stream=None)¶
Print a string containing an ASCII table useful for plotting the AnalysisSpin object.
- Parameters:
stream (python stream) – The stream the table should be written to. Default:
NLPrintLogger()
- orbitals(spin=None)¶
Calculate the Mulliken population of all orbitals.
- Parameters:
spin (
Spin.All
|Spin.Sum
|Spin.X
|Spin.Y
|Spin.Z
|Spin.Up
|Spin.Down
|Spin.RealUpDown
|Spin.ImagUpDown
) – The mulliken population is calculated for this spin. Default:Spin.All
- Returns:
One array for each atom. Each array holds the Mulliken population of each orbital of that atom.
- Return type:
list of
numpy.array
- setMetatext(metatext)¶
Set a given metatext string on the object.
- Parameters:
metatext (str | None) – The metatext string that should be set. A value of “None” can be given to remove the current metatext.
- uniqueString()¶
Return a unique string representing the state of the object.
Usage Examples¶
Calculate the Mulliken population of an ammonia molecule and print projections of orbitals and bonds:
# Set up configuration
molecule_configuration = MoleculeConfiguration(
elements=[Nitrogen, Hydrogen, Hydrogen, Hydrogen],
cartesian_coordinates=[[ 0., 0., 0.124001],
[ 0., 0.941173, -0.289336],
[ 0.81508, -0.470587, -0.289336],
[-0.81508, -0.470587, -0.289336]] * Angstrom)
# Define the calculator
calculator = HuckelCalculator()
molecule_configuration.setCalculator(calculator)
# Calculate and save the mulliken population
mulliken_population = MullikenPopulation(
configuration=molecule_configuration)
nlsave('mulliken.hdf5', mulliken_population)
# print all occupations
nlprint(mulliken_population)
# print partial occupations of N
print('N ', mulliken_population.atoms(spin=Spin.Sum)[0])
print(' | ', mulliken_population.orbitals(spin=Spin.Sum)[0])
print('')
# print partial occupations of first H
print('H ', mulliken_population.atoms(spin=Spin.Sum)[1])
print(' | ', mulliken_population.orbitals(spin=Spin.Sum)[1])
print('')
# print Mulliken population of N-H bond
print('N-H bond ', mulliken_population.bond(0, 1))
Notes¶
The total number of electrons, \(N\), is given by
where \(D\) is the density matrix, \(S\) the overlap matrix, and the sum is over all orbitals in the system.
The Mulliken population is defined by different partitions of this sum into orbitals, atoms and bonds.
- Mulliken population of orbitals
The Mulliken Population of orbitals, \(M_i\) , is defined by restricting one of the sum indexes to the orbital, i.e.
\[M_i = \sum_{j} D_{ij} S_{ji}.\]
- Mulliken population of atoms
The Mulliken Population of atoms, \(M_{\mu}\) , is defined by adding up all the orbital contributions on atom number \(\mu\)
\[M_\mu = \sum_{i \in \mu} \sum_{j} D_{ij} S_{ji}.\]
- Mulliken population of bonds
The Mulliken Population of bonds, \(M_{\mu \nu}\) , is defined by restricting the sum indexes to the orbitals on atom number \(\mu\) and \(\nu\) , i.e.
\[M_{\mu \nu} = (2-\delta_{\mu \nu}) \sum_{i \in \mu} \sum_{j \in \nu} D_{ij} S_{ji}.\]Note the factor two, which ensures that
\[N = \sum_{\mu \ge \nu} M_{\mu \nu}.\]
Noncollinear spin¶
For noncollinear systems, the Mulliken population of atoms is a four component spin tensor:
The Mulliken Population of atoms can be diagonalized to give a local spin direction. This direction is reported by the nlprint command for noncollinear systems.
The nlprint report for noncollinear spin also shows the orbital Mulliken populations in the local spin direction.