Theoretical foundations of electrical engineering