  Mechatronic systems are described by an interconnection of the
electromagnetic part, i.e., a static position-dependent nonlinear relation
between currents and forces, and the mechanical part, i.e., a dynamic relation
from forces to position. Commutation inverts a model of the electromagnetic
part of the system, and thereby removes the electromagnetic part from the
position control problem. Typical commutation algorithms rely on simplified
models derived from physics-based knowledge, which do not take into account
position dependent parasitic effects. In turn, these commutation related model
errors translate into position tracking errors, which limit the system
performance. Therefore, in this work, we develop a data-driven approach to
commutation using physics-guided neural networks (PGNNs). A novel PGNN model is
proposed which structures neural networks (NNs) to learn specific motor
dependent parasitic effects. The PGNN is used to identify a model of the
electromagnetic part using force measurements, after which it is analytically
inverted to obtain a PGNN-based commutation algorithm. Motivated by industrial
applications, we develop an input transformation to deal with systems with
fixed commutation, i.e., when the currents cannot be controlled. Real-life
experiments on an industrial coreless linear motor (CLM) demonstrate a factor
10 improvement in the commutation error in driving direction and a factor 4
improvement in the position error with respect to classical commutation in
terms of the mean--squared error (MSE).
