Frequency Tuning in a Subterahertz Gyrotron With a Variable Cavity