An Example of Optimal Control