Control of asynchronous generator by variation of capacitor