Neutron spectra from beam-target reactions in dense Z-pinches