  We study the process of associating molecules from atomic gases using a
magnetic field modulation that is resonant with the molecular binding energy.
We show that maximal conversion is obtained by optimising the amplitude and
frequency of the modulation for the particular temperature and density of the
gas. For small modulation amplitudes, resonant coupling of an unbound atom pair
to a molecule occurs at a modulation frequency corresponding to the sum of the
molecular binding energy and the relative kinetic energy of the atom pair. An
atom pair with an off-resonant energy has a probability of association which
oscillates with a frequency and time-varying amplitude which are primarily
dependent on its detuning. Increasing the amplitude of the modulation tends to
result in less energetic atom pairs being resonantly coupled to the molecular
state, and also alters the dynamics of the transfer from continuum states with
off-resonant energies. This leads to maxima and minima in the total conversion
from the gas as a function of the modulation amplitude. Increasing the
temperature of the gas leads to an increase in the modulation frequency
providing the best fit to the thermal distribution, and weakens the resonant
frequency dependence of the conversion. Mean-field effects can alter the
optimal modulation frequency and lead to the excitation of higher modes. Our
simulations predict that resonant association can be effective for binding
energies of order $h \times 1$ MHz.
