In a method for determination or adaptation of a shim for homogenization
of a magnetic field of a magnetic resonance apparatus, which magnetic
field is provided for the generation of magnetic resonance exposures of a
specific examination region, an automatic determination, of a computer
and/or supported by an operator on an image output unit of the computer,
is made of a three-dimensional volume that is relevant for the
determination or adaptation of the shim and that is matched to the
examination region and/or an examination protocol by selection from an
arbitrary morphology set of selectable volumes (which morphology set is
not limited to specific shapes) and/or by generation of an arbitrarily
three-dimensional volume not limited to specific shapes. The computer
then automatically calculates the shim for the determined or selected
three-dimensional volume.