Pātuhitia tēnei: Swarm Intelligence Based Controller for Electric Machines and Hybrid Electric Vehicles Applications