The constant Q spectrometer resolution function