On the convergence of the projected gradient method