  In classical control theory, tracking refers to the ability to perform
measurements and feedback on a classical system in order to enforce some
desired dynamics. In this paper we investigate a simple version of quantum
tracking, namely, we look at how to optimally transform the state of a single
qubit into a given target state, when the system can be prepared in two
different ways, and the target state depends on the choice of preparation. We
propose a tracking strategy that is proved to be optimal for any input and
target states. Applications in the context of state discrimination, state
purification, state stabilization and state-dependent quantum cloning are
presented, where existing optimality results are recovered and extended.
