The three people involved in your question are not the same kind of people. Which is why, there is no contradiction, even if the movies make somewhat different implications.
- Arwen is an immortal elf who could make the choice to become mortal and die, or remain immortal and go to the home of the elves and gods, Valinor.
- Gandalf is an immortal Wizard whose body was destroyed, but got sent back to Middle-Earth by the Gods (from Valinor) because his work was not yet done.
- Aragorn is a mortal man who dies just like normal people and does not have anything to do with Valinor.
Arwen is of the Half-Elven lineage
This means she got to choose whether she wanted to be Elf or Human. 
ARWEN: Do you remember what I told you?
STRIDER: You said you'd bind yourself to me, forsaking the immortal life of your people.
ARWEN: And to that I hold. I would rather share one lifetime with you than face all the ages of this world alone. I choose a mortal live.
Granted, the movies do a really bad job (as in no job) of explaining why she can make this choice etc. Going simply from the movie dialogue, I guess the "idea" seems to be that Arwen is a normal elf, and giving up their immortality is something doable by all Elves, and a prerequisite for marrying a mortal; or that the thing she is choosing is the knowledge that once Aragorn is dead she'll die/fade away from grief:
ELROND: Arwen, it is time. The ships are leaving for Valinor. Go now... before it is too late.
ARWEN: I have made my choice. ....
ELROND: If Aragorn survives this war, you will still be parted. If Sauron is defeated, and Aragorn made king and all that you hope for comes true, you will still have to taste the bitterness of mortality. Whether by the sword or the slow decay of time, Aragorn will die. And there will be no comfort for you. No comfort to ease the pain of his passing. He will come to death, an image of the splendor of the kings of men in glory undimmed before the breaking of the world. But you, my daughter, you will linger on in darkness and in doubt. As nightfall in winter that comes without a star. Here you will dwell, bound to your grief, under the fading trees, until all the world is changed and the long years of your life are utterly spent. Arwen... there is nothing for you here, only death.
Following this idea, the reason for the parting between Elrond and Arwen would be that Arwen having faded away from grief, would become a 'ghost' bound to the world by it.
Gandalf is an Istar/Maia
That is, he is an angelic being given bodily form and sent to Middle-Earth for a mission by the gods, Valar. This means that when he 'died', that just meant his body was destroyed, and his spirit sent back to the Valar. The Valar decided his mission was not yet complete, and he was still needed in Middle-Earth, plus they learnt of Saruman's fall, so Gandalf got a 'promotion' and got sent back.
In the movies, though no information is given about the Istari, the implication that Gandalf and Saruman are not mere humans is clear, as is the implication of the involvement of higher powers in Gandalf being 'sent back'.
GANDALF: From the lowest dungeon to the highest peak, I fought with the Balrog of Morgoth. Until at last, I threw down my enemy and smote his ruin upon the mountainside. Darkness took me. And I strayed out of thought and time. Stars wheeled overhead and everyday was as long as a life-age of the earth. But it was not the end. I felt life in me again. I've been sent back until my task is done.
The 'white shore and green forests' are Valinor, the land of the Gods, aka the place where Elrond and Galadriel and Gandalf and Bilbo and Frodo sailed to at the end of the trilogy, the place where Arwen would have also gone to if she had not chosen to be Mortal.
This is also what happens to 'true' elves according to the books, - ie. if they die, their spirits go to Valinor where they may or may not be re-embodied. This is the fate Elrond chose. However, he never died (in battle etc) so he got to physically sail to this place, instead.
In the movies, however, no mention of this is made, which could mean that elf-death is as 'permanent' as mortal death in this 'version' - which could be another explanation for the parting of Elrond and Arwen - if she stayed on, and eventually died due to any reason including from grief, by the movie logic, she wouldn't meet up with Elrond again.
Aragorn is a Mortal Man
This means he dies like all Men, and after death his spirit does not go to Valinor, but beyond the known world, to Capital-G God (aka Eru/Illuvatar). This is the fate that Arwen chose (according to the books, again)