In standard pseudoinverse-based approaches to treat redundant manipulators, the vector of joint increments that corresponds to a desired motion in the space of the
secondary task is projected in the Jacobian null space associated with the primary task. In general, this projection may distort the projected vector, so that the secondary task may not
adequately be executed. A usual remedy is to rotate the null space projection operator by using a special-purpose weighting matrix. The problem, however, is that this rotation cannot be enforced arbitrarily since it influences the manipulator's performance. In our work
we propose an algorithm that is independent on the chosen null space operator and always provides the best attainable motion in the space of the secondary task. Hence, the secondary
task is executed more efficiently and the numerical procedure is more robust. A series of numerical experiments confirmed these results.