Modeling Electromechanical Aspects of Cyber-Physical Systems