Angular criteria and χ parameters#
The two descriptors on this page are computed from the angles between the bonds of an atom to its neighbors. The angular criterion \(A\) of Uttormark et al. [1] measures how far the four nearest neighbors of an atom are from a regular tetrahedron. It is used to find atoms in diamond structures, such as crystalline silicon or germanium. The χ parameters of Ackland and Jones [2] are a histogram of the cosines of all bond angles of an atom. The Ackland–Jones classification uses the same kind of counts, with eight bins and its own choice of neighbors. For a structure label of diamond atoms, see Common neighbor analysis, and for the bond angle distribution of a whole system, see Distribution functions.
Definition#
Angular criterion#
For an atom \(i\), take its four nearest neighbors. The bonds to these neighbors form six angles \(\theta_{jk}\), one for each pair \(j < k\) of the four neighbors. The angular criterion is
where \(\cos\theta_{jk} = \mathbf{r}_{ij} \cdot \mathbf{r}_{ik} / (r_{ij} r_{ik})\), and \(\mathbf{r}_{ij}\) is the vector from atom \(i\) to its neighbor \(j\). The tetrahedral angle of 109.47° has \(\cos\theta = -1/3\). \(A = 0\) when the four neighbors form a regular tetrahedron around the atom, and \(A > 0\) otherwise.
χ parameters#
For an atom \(i\) with \(N(i)\) neighbors, compute \(\cos\theta_{jk}\) for all \(N(i)\,(N(i) - 1)/2\) pairs of neighbors. The χ parameter \(\chi_n(i)\) is the number of pairs whose cosine falls in bin \(n\):
Parameter |
\(\cos\theta\) |
\(\theta\) |
|---|---|---|
\(\chi_0\) |
\([-1, -0.945)\) |
160.9° to 180° |
\(\chi_1\) |
\([-0.945, -0.915)\) |
156.2° to 160.9° |
\(\chi_2\) |
\([-0.915, -0.755)\) |
139.0° to 156.2° |
\(\chi_3\) |
\([-0.755, -0.705)\) |
134.8° to 139.0° |
\(\chi_4\) |
\([-0.705, -0.195)\) |
101.2° to 134.8° |
\(\chi_5\) |
\([-0.195, 0.195)\) |
78.8° to 101.2° |
\(\chi_6\) |
\([0.195, 0.245)\) |
75.8° to 78.8° |
\(\chi_7\) |
\([0.245, 0.795)\) |
37.3° to 75.8° |
\(\chi_8\) |
\([0.795, 1]\) |
0° to 37.3° |
Ackland and Jones [2] use eight bins, \(\chi_0\) to \(\chi_7\). pyscal splits their fourth bin, \([-0.755, -0.195)\), at \(-0.705\) into \(\chi_3\) and \(\chi_4\). The other bins are the same, so \(\chi_5\) to \(\chi_8\) in pyscal are \(\chi_4\) to \(\chi_7\) in the paper.
Usage#
Find the neighbors first, then compute the descriptors:
import numpy as np
import pyscal
from ase.build import bulk
silicon = bulk("Si", "diamond", a=5.43, cubic=True).repeat(4)
pyscal.find_neighbors(silicon, method="cutoff", cutoff=0)
A = pyscal.angular_criteria(silicon)
chi = pyscal.chi_params(silicon)
A[:4].round(3), chi[0]
(array([0., 0., 0., 0.]), array([0, 0, 0, 0, 6, 0, 0, 0, 0]))
angular_criteria returns \(A\) for each atom, and chi_params returns an \((N, 9)\) array of integer counts.
Both store their results on atoms:
Key |
Shape |
Content |
|---|---|---|
|
\((N,)\) |
\(A\) |
|
\((N, 9)\) |
\(\chi_0, \dots, \chi_8\) |
|
list of \(N\) lists |
\(\cos\theta_{jk}\) for all pairs of neighbors, with |
With angles=True, chi_params returns the χ parameters and the list of cosines.
Both functions use the stored neighbor list and raise an error if find_neighbors has not been called.
angular_criteria uses only the four nearest of the stored neighbors, so any neighbor method that finds at least four neighbors gives the same result.
chi_params uses all stored neighbors, and the counts change with the neighbor method.
Values for perfect crystals#
import pandas as pd
from ase.cluster import Icosahedron
from pyscal.structures import make_crystal
icosahedron = Icosahedron("Cu", noshells=2) # 13 atoms, the first is the centre
icosahedron.center(vacuum=5.0)
crystals = {
"fcc": make_crystal("fcc", lattice_constant=3.61, repetitions=(4, 4, 4)),
"hcp": make_crystal("hcp", lattice_constant=2.51, repetitions=(4, 4, 4)),
"bcc": make_crystal("bcc", lattice_constant=2.87, repetitions=(4, 4, 4)),
"ico": icosahedron,
"diamond": make_crystal("diamond", lattice_constant=5.43, repetitions=(3, 3, 3)),
}
perfect = {}
for name, crystal in crystals.items():
pyscal.find_neighbors(crystal, method="cutoff", cutoff=0)
perfect[name] = pyscal.chi_params(crystal)[0]
table = pd.DataFrame(perfect, index=[f"χ{n}" for n in range(9)]).T
table["neighbors"] = table.sum(axis=1).map(lambda pairs: int((1 + np.sqrt(1 + 8 * pairs)) / 2))
table
| χ0 | χ1 | χ2 | χ3 | χ4 | χ5 | χ6 | χ7 | χ8 | neighbors | |
|---|---|---|---|---|---|---|---|---|---|---|
| fcc | 6 | 0 | 0 | 0 | 24 | 12 | 0 | 24 | 0 | 12 |
| hcp | 3 | 0 | 6 | 0 | 21 | 12 | 0 | 24 | 0 | 12 |
| bcc | 7 | 0 | 0 | 0 | 36 | 12 | 0 | 36 | 0 | 14 |
| ico | 6 | 0 | 0 | 0 | 30 | 0 | 0 | 30 | 0 | 12 |
| diamond | 0 | 0 | 0 | 0 | 6 | 0 | 0 | 0 | 0 | 4 |
The table gives the χ parameters of one atom in each perfect structure, with first shell neighbors: 12 in fcc, hcp and the icosahedron, 14 (8 + 6) in bcc and 4 in diamond. For the icosahedron, the atom is the centre of a 13-atom cluster. \(\chi_0\) counts pairs of neighbors on nearly opposite sides of the atom. There are 7 such pairs in bcc, 6 in fcc and the icosahedron, and 3 in hcp. \(\chi_2\) is nonzero only in hcp, from the six angles of 146.4° between neighbors in the layers above and below the atom. \(\chi_5\) counts angles near 90°, which are absent in the icosahedron. These differences are the basis of the Ackland–Jones classification.
Crystals at finite temperature#
Thermal vibrations spread the angles, and pairs move into neighboring bins.
We compute the χ parameters for three MD snapshots from the examples folder: an fcc crystal and a bcc crystal at finite temperature, and a liquid.
The neighbors are all atoms within the first minimum of the radial distribution function (see Finding neighbors).
from ase.io import read
snapshots = {
"fcc": read("conf.fcc.dump", format="lammps-dump-text"),
"bcc": read("conf.bcc.dump", format="lammps-dump-text"),
"liquid": read("conf.lqd.Al.dump", format="lammps-dump-text"),
}
cutoffs = {"fcc": 3.5, "bcc": 3.8, "liquid": 4.1}
chi_snapshots = {}
for name, snapshot in snapshots.items():
pyscal.find_neighbors(snapshot, method="cutoff", cutoff=cutoffs[name])
chi_snapshots[name] = pyscal.chi_params(snapshot)
Panel (a) shows the values of the table. Panel (b) shows the mean over the atoms of each snapshot, and the error bars give the standard deviation over the atoms. In the fcc snapshot, \(\chi_0\) drops from 6 to 5.2 on average, and 55 % of the atoms have at least one angle in \(\chi_1\) to \(\chi_3\), which are empty in the perfect crystal. In the bcc snapshot, \(\chi_0\) drops from 7 to 6.4. In the liquid, \(\chi_0\) is 2.6 on average, and many pairs fall in bins that are empty in fcc and bcc, for example 7.0 in \(\chi_2\). A classifier that tests for the exact counts of the perfect structures is therefore sensitive to temperature.
Finding tetrahedral atoms#
Does \(A\) separate atoms in a diamond structure from atoms in other structures at finite temperature? We add random displacements to perfect cubic and hexagonal diamond, with a standard deviation of 4 % of the nearest neighbor distance in each direction, a rough model of thermal vibrations. We compare them with the three MD snapshots.
a = 5.43
nearest = a * np.sqrt(3) / 4
diamonds = {
"diamond": bulk("Si", "diamond", a=a, cubic=True).repeat(4),
"hex. diamond": bulk("SiSi", "wurtzite", a=a / np.sqrt(2),
c=a / np.sqrt(2) * np.sqrt(8 / 3)).repeat((6, 6, 4)),
}
angular = {}
for name, structure in diamonds.items():
structure.rattle(0.04 * nearest, seed=1)
pyscal.find_neighbors(structure, method="cutoff", cutoff=0)
angular[name] = pyscal.angular_criteria(structure)
for name, snapshot in snapshots.items():
pyscal.find_neighbors(snapshot, method="cutoff", cutoff=0)
angular[name] = pyscal.angular_criteria(snapshot)
Both diamond structures have \(A\) below 0.17.
Only 1 of the 1008 atoms of the fcc snapshot and 0 of the 500 atoms of the liquid have smaller values.
In the bcc snapshot, 20 of the 1024 atoms are below this value, and a few have \(A\) as small as in the diamond structures.
The eight nearest neighbors in bcc sit at the corners of a cube, and four alternating corners form a regular tetrahedron.
When thermal motion brings these four atoms closer than the other four, \(A\) is close to zero.
A small value of \(A\) therefore shows that the four nearest neighbors are arranged as a tetrahedron, but not that the atom is in a diamond structure.
Cubic and hexagonal diamond have the same values, so \(A\) does not tell them apart.
Use diamond_structure (see Common neighbor analysis) to identify and separate the two.
Things to watch#
Fewer than four neighbors. An atom with fewer than four stored neighbors gets \(A = 0\), the value of a perfect tetrahedron. Check the number of neighbors, for example with
np.diff(atoms.info["pyscal_bond_offsets"]), before selecting atoms by small \(A\).Ties between neighbors. In close packed crystals, the 12 nearest neighbors are at the same distance, and the four nearest are chosen among them by index. \(A\) then takes several values in a perfect crystal. \(A\) is meaningful only for atoms with four clearly nearest neighbors.
χ depends on the number of neighbors. The χ parameters are counts, and they add up to \(N(i)\,(N(i) - 1)/2\). A neighbor method that gives one extra neighbor adds \(N(i)\) pairs. Compare χ parameters only when they were computed with the same neighbor method.
References#
M. J. Uttormark, M. O. Thompson and P. Clancy, Kinetics of crystal dissolution for a Stillinger–Weber model of silicon, Phys. Rev. B 47, 15717 (1993). doi:10.1103/PhysRevB.47.15717
G. J. Ackland and A. P. Jones, Applications of local crystal structure measures in experiment and simulation, Phys. Rev. B 73, 054104 (2006). doi:10.1103/PhysRevB.73.054104