In the recent movie "Melancholia", a planet, also called Melancholia, enters the solar system and hits the Earth. I want to leave aside the (also unreasonable) aspect that planet "hides behind the Sun" and is undetected until it's a few weeks from Earth. I want to focus on the final stages. In the movie, the planet passes close to the Earth, starts receding, doubles back and hits the Earth, all in a few days. My question: Is that physically possible? I guess not, but I was never good at orbital mechanics.
Assume the givens are as in the movie. One of the main characters finds on the internet a path for the planet that seems to what it eventually does. Mass of the planet is four times that of the earth?