X-ray crystallography is a technique that uses X-rays to determine the atomic and molecular structure of crystals. When X-rays hit a crystal, they cause the crystal to diffract the X-rays into many specific directions. By measuring the angles and intensities of these diffracted beams, a three-dimensional picture of electron density within the crystal can be determined, revealing information about atomic positions and chemical bonds. Bragg's law describes the diffraction conditions of X-rays by crystals and is used to analyze diffraction patterns to determine crystal structures. Common techniques for X-ray crystallography include Laue photography, powder diffraction, and rotating crystal methods.