Doubly fed electric machine