The electron densities of atoms in a crystal are Fourier transforms of the structure factor.

In the article on scattering factor, we have restricted the electron density ρ to a lattice point, which is too simplistic. We have also described the scattering factor (eq27) as
$$df=\rho e^{i\phi}dV$$
or in its integrated form
$$f=\int \rho e^{i\phi}dV\; \; \; \; \; \; \; (40)$$
If we now extend the distribution of ρ through the unit cell, eq40 becomes the structure factor:
$$F_{hkl}=\int \rho ^{\prime}e^{i\phi}dV$$
where ρ’ = ρ(xyz) is the electron density at coordinates xyz in the unit cell and \(\phi=2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c} )\), i.e.
$$F_{hkl}=\int \rho(xyz)e^{i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c} )}dV\; \; \; \; \; \; \; (41)$$
Let dV be an infinitesimal volume of the unit cell with edges dx, dy, dz that are parallel to the unit cell axes of a, b, c (volume of unit cell is V). The ratio of dV/V must be equal to (dxdydz)/abc and we can rewrite eq41 as
$$F_{hkl}=\frac{V}{abc}\int_{0}^{a}\int_{0}^{b}\int_{0}^{c}\rho (xyz)e^{i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}dxdydz\; \; \; \; \; \; \; (42)$$
A Fourier series is an expansion series used to represent a periodic function and is given by:
$$f(x)=\sum_{n=0}^{\infty }[A_ncos(nx)+B_nsin(nx)]$$
or by its complex form
$$f(x)=\sum_{n=-\infty }^{\infty }c_ne^{i\frac{2\pi nx}{a}}$$
Due to the repetitive arrangement of atoms in a crystal, the electron density in a crystal is also periodic and can be expressed as a Fourier series:
$$\rho (x)=\sum_{n=-\infty }^{\infty }c_ne^{i\frac{2\pi nx}{a}}\; \; \; \; \; \; \; (43)$$
In three dimensions, eq43 becomes
$$\rho (xyz)=\sum_{n=-\infty }^{\infty }\sum_{m=-\infty }^{\infty }\sum_{o=-\infty }^{\infty }c_{nmo}e^{i2\pi(\frac{nx}{a}+\frac{ my}{b}+\frac{ oz}{c})}\; \; \; \; \; \; \; (44)$$
Substitute eq44 in eq42
$$F_{hkl}=\frac{V}{abc}\int_{0}^{a}\int_{0}^{b}\int_{0}^{c}\sum_{n=-\infty }^{\infty }\sum_{m=-\infty }^{\infty }\sum_{o=-\infty }^{\infty }c_{nmo}e^{i2\pi(\frac{nx}{a}+\frac{my}{b}+\frac{oz}{c})} e^{i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}dxdydz$$
$$F_{hkl}=\frac{V}{abc}\sum_{n=-\infty }^{\infty }\sum_{m=-\infty }^{\infty }\sum_{o=-\infty }^{\infty }c_{nmo}\int_{0}^{a}e^{i2\pi\frac{x}{a}(n+h)}dx\int_{0}^{b}e^{i2\pi\frac{y}{b}(m+k)}dy\int_{0}^{c}e^{i2\pi\frac{z}{c}(o+l)}dz\; \; \; \; (45)$$
If n ≠ –h,
$$\int_{0}^{a}e^{i2\pi\frac{x}{a}(n+h)}dx=\int_{0}^{a}[cos2\pi\frac{x}{a}(n+h)+isin2\pi\frac{x}{a}(n+h)]dx$$
$$=\int_{0}^{a}cos2\pi\frac{x}{a}(n+h)dx=0$$
which makes Fhkl = 0.
Similarly, Fhkl = 0 if m ≠ -k or o ≠ -l. Therefore, the surviving term in the triple summation in eq45 corresponds to the case of n = –h, m = –k, o = –l, giving
$$F_{hkl}=\frac{V}{abc}c_{-h,-k,-l}\int_{0}^{a}dx\int_{0}^{b}dy\int_{0}^{c}dz=Vc_{-h,-k,-l}$$
$$c_{-h,-k,-l}=\frac{F_{hkl}}{V}\; \; \; \; \; \; \; (46)$$
When n = –h, m = –k, o = –l, eq44 becomes
$$\rho (xyz)=\sum_{-h=-\infty }^{\infty }\sum_{-k=-\infty }^{\infty }\sum_{-l=-\infty }^{\infty } c_{-h,-k,-l}e^{-i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}$$
Since \(\sum_{-h=-\infty }^{\infty }\sum_{-k=-\infty }^{\infty }\sum_{-l=-\infty }^{\infty }=\sum_{h=\infty }^{-\infty }\sum_{k=\infty }^{-\infty }\sum_{l=\infty }^{-\infty }=\sum_{h=-\infty }^{\infty }\sum_{k=-\infty }^{\infty }\sum_{l=-\infty }^{\infty }\)
$$\rho (xyz)=\sum_{h=-\infty }^{\infty }\sum_{k=-\infty }^{\infty }\sum_{l=-\infty }^{\infty }c_{-h,-k,-l}e^{-i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}\; \; \; \; \; \; \; (47)$$
Substitute eq46 in eq47
$$\rho (xyz)=\frac{1}{V}\sum_{h=-\infty }^{\infty }\sum_{k=-\infty }^{\infty }\sum_{l=-\infty }^{\infty }F_{hkl}e^{-i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}\; \; \; \; \; \; \; (48)$$
Since the limits of the integrals in eq42 can be changed to run from \(-\infty\) to \(\infty\) without affecting the values of the integrals because \(\rho(xyz)\) is zero outside the crystal, we have
$$F_{hkl}=\frac{V}{abc}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\int_{-\infty}^{\infty}\rho (xyz)e^{i2\pi(\frac{hx}{a}+\frac{ky}{b}+\frac{lz}{c})}dxdydz\; \; \; \; \; \; \; (48a)$$
Eq48 and eq48a are a Fourier transform pair. As mentioned in the previous article, the intensity of a diffraction signal is proportional to the square of the magnitude of the three-dimensional structure factor, i.e. \(I \propto \left | F_{hkl} \right |^2\). If we know the value of Fhkl (which in principle is the square root of the intensity of a peak from an X-ray diffraction experiment \(\sqrt{\left | F_{hkl} \right |^2}=\left | F_{hkl} \right |\) ) and having indexed the plane contributing to this intensity peak (i.e. knowing the h, k, l values), we can determine ρ(xyz) using a mathematical software. The solution to ρ(xyz) is an electron density map that elucidates bond lengths and bond angles of the compound. However, a problem called the phase problem arises.
