Mode switching in a gyrotron with azimuthally corrugated resonator.