X-ray spectroscopy involves analyzing the characteristic X-ray emissions from materials. X-rays are produced when high velocity electrons strike metal surfaces in a vacuum tube, with 1% of the total radiation produced being X-rays. Bragg's equation describes the diffraction of X-rays by crystal planes. Modern detectors for X-ray spectroscopy include semiconductor detectors and scintillation detectors coupled with photomultiplier tubes. Applications of X-ray spectroscopy include detecting imperfections in materials, fractures, and measuring trace elements.