Coherent magnetic field fluctuations and locked modes in a reversed-field pinch