A key idea of NMR is that the resonance frequency of a particular substance is directly proportional to the strength of the applied magnetic field. This resonance is used in imaging techniques. If a sample is placed in a non-uniform magnetic field then the resonance frequencies of the sample's nuclei depend on where in the field they are located. Scientists try to use the highest possible magnetic fields to get the best image quality.