  In this paper we solve two equivalent time optimal control problems. On one
hand, we design the control field to implement in minimum time the SWAP (or
equivalent) operator on a two-level system, assuming that it interacts with an
additional, uncontrollable, two-level system. On the other hand, we synthesize
the SWAP operator simultaneously, in minimum time, on a pair of two-level
systems subject to opposite drifts. We assume that it is possible to perform
three independent control actions, and that the total control strength is
bounded. These controls either affect the dynamics of the target system, under
the first perspective, or, simultaneously, the dynamics of both systems, in the
second view. We obtain our results by using techniques of geometric control
theory on Lie groups. In particular, we apply the Pontryagin Maximum Principle,
and provide a complete characterization of singular and non-singular extremals.
Our analysis shows that the problem can be formulated as the motion of a
material point in a central force, a well known system in classical mechanics.
Although we focus on obtaining the SWAP operator, many of the ideas and
techniques developed in this work apply to the time optimal implementation of
an arbitrary unitary operator.
