Optimization of the Cavity Length of the Gyrotrons Operated at the Second Gyrofrequency Harmonic with One-stage Recovery of the Residual Energy of an Electron Beam