General Theory of Electrical Machines