If Rafa wins French Open and reaches Final of Halle. He will be seeded 4th but he will not pass Ferrer in the rankings only in the seedings.
Nadal will be 4th only if he wins both RG and Halle.
Nadal has 6095 ranking points and not 6040. He has 2 zero-pointers, because he has only played 2 ATP500 tournamnets in 2012... It is really absurd, I admit.
He can add 800 points for RG final win, and 250 for grass bonus points(no ranking points will be added) if he wins Halle for a total of 1050 points. He is 995 points behind Ferrer right now.