Crystal

The crystal module handles Bragg diffraction on crystal lattices.

class xconf.crystal.Crystal(h, k, l, roc, material, **kwargs)[source]

Create an analyzer crystal by specifying the cut via the Miller indices h, k and l, the radius of curvature roc and a material string. Valid material strings are ‘Si’ or ‘Ge’.

get_bragg_angle(energy, hkl)[source]

Get the Bragg angle under which the diffraction with Miller indices hkl selects the X-ray energy energy.

get_energy(bragg_angle, hkl)[source]

Get the energy which is selected under a given angle bragg_angle for a diffraction with Miller indices hkl.

get_interplanar_distance(hkl)[source]

Get the interplanar distance for a set of Miller indices hkl.

get_spectral_bandwidth(energy, hkl, theta, polarization='sigma')[source]

Compute the spectral bandwidth \(\epsilon^{(s)}_H\) 1 . Debye-Waller factor and anomalous scattering are neglected, i.e. the structure factor for diamond cubic lattice is

\[F_{hkl} = f [ 1 + (-1)^{h + k} + (-1)^{k + l} + (-1)^{h + l}] * [ 1 + (-i)^{h + k + l}]\]

with atomic form factor \(f\) and Miller indizes \(h,k,l\).

References

1

Shvyd’ko, Y. X-Ray Optics. 98, (Springer Berlin Heidelberg, 2004), p. 76.

get_wavelength(energy)[source]

Get the wavelength from X-ray energy energy.

class xconf.crystal.CylindricalCrystal(width, height, *args, **kwargs)[source]

An analyzer of cylindrical type as used in von Hamos type spectrometers.

get_solid_angle(angle)[source]

Compute the solid angle which is covered by this analyzers surface for a given angle. As a general rule of thumb, an analyzer will collect more photons if the solid angle is bigger.

xconf.crystal.diffraction_allowed(hkl, max_diffraction_order)[source]

Returns a list of miller indizes for allowed diffractions from hkl up to the max_diffraction_order diffraction order.

xconf.crystal.get_cut(hkl)[source]

Divides a set of miller indices hkl by its greatest common factor.

xconf.crystal.get_lattice_constant(material_name)[source]

Convenience method for assigning lattice constant parameters of common analyzer materials.