|  | ||||
| PHY.K02UF Molecular and Solid State Physics | ||||
The Fourier coefficients of the electron density can be determined from the atomic form factors,
$$n_{\vec{G}} = \frac{1}{V}\sum\limits_j f_j\left(G\right)e^{-i\vec{G}\cdot\vec{r}_j} = \frac{1}{V}\sum\limits_j f_j\left(G\right)\left(\cos\left(\vec{G}\cdot\vec{r}_j\right)-i\sin\left(\vec{G}\cdot\vec{r}_j\right)\right).$$It is customary to define a quantity called the structure factor by multiplying the Fourier coefficients by the volume of the primitive unit cell.
$$S_{\vec{G}} =Vn_{\vec{G}} = \sum\limits_j f_j\left(G\right)e^{-i\vec{G}\cdot\vec{r}_j} = \sum\limits_j f_j\left(G\right)\left(\cos\left(\vec{G}\cdot\vec{r}_j\right)-i\sin\left(\vec{G}\cdot\vec{r}_j\right)\right).$$When the structure factors are defined this way, $S_{\vec{G}=0}$ is equal to the number of electrons in the primitive unit cell. The measured intensities of the diffraction peaks in an x-ray diffraction experiment are proportional to the structure factors.
The form below calculates the x-ray structure factors for an arbitrary crystal with up to 8 atoms in the basis. The crystal structure is specified by providing the lattice vectors and the positions of the atoms in the basis. The script first calculates the reciprocal lattice vectors and from them calculates the reciprocal lattice vectors $\vec{G}_{hkl}=h\vec{b}_1+k\vec{b}_2+l\vec{b}_3$.
Often in experiments, the directions are given in terms of the conventional lattice vectors, and the reciprocal lattice vectors are labeled as the reciprocal lattice vectors of the conventional unit cell. When this is done, a bcc lattice is described as simple cubic with a basis of atoms at (0,0,0) and (0.5,0.5,0.5), while fcc is described as simple cubic with a basis of atoms at (0,0,0), (0,0.5,0.5), (0.5,0,0.5), and (0.5,0.5,0). The program below will calculate the diffraction pattern either for the primitive lattice vectors or the conventional lattice vectors. You just have to modify the basis appropriately.
Primitive reciprocal lattice vectors
| $\vec{b}_1=2\pi\frac{\vec{a}_2\times\vec{a}_3}{\vec{a}_1\cdot\left(\vec{a}_2\times\vec{a}_3\right)}=$ $\hat{k}_x+$ $\hat{k}_y+$ $\hat{k}_z$ [m-1] | 
| $\vec{b}_2=2\pi\frac{\vec{a}_3\times\vec{a}_1}{\vec{a}_1\cdot\left(\vec{a}_2\times\vec{a}_3\right)}=$ $\hat{k}_x+$ $\hat{k}_y+$ $\hat{k}_z$ [m-1] | 
| $\vec{b}_3=2\pi\frac{\vec{a}_1\times\vec{a}_2}{\vec{a}_1\cdot\left(\vec{a}_2\times\vec{a}_3\right)}=$ $\hat{k}_x+$ $\hat{k}_y+$ $\hat{k}_z$ [m-1] | 
Structure factors
| The value of $|S_{\vec{G}}|$ for the 000 diffraction peak is the total number of electrons in the primitive unit cell. The intensities of the peaks in an x-ray diffraction experiment are proportional to $|S_{\vec{G}}|^2$. Note that elements with more electrons produce stronger diffraction intensities. | 
 |