Multiple diffraction in crystals studied by an X-ray energy-dispersive method