The making of the movie The Martian seems almost like a fairy tale, or more specifically, a Horatio Alger-type success story. Computer programmer Andy Weir wrote a story about Mars in blog posts over three years, which then became a book, which was picked up by Hollywood and made into a critically-acclaimed movie directed by Ridley Scott with help from NASA. James Green, director of NASA’s Planetary Sciences Division, was tremendously excited when Scott wanted to speak to him about NASA’s help for the movie The Martian. The conversation led to a tour of NASA’s Johnson Space Center and the Jet Propulsion Laboratory and then more.
Beyond tours, NASA gave the filmmakers hundreds of photos—of Mars, of what's on a screen when scientists are commanding a satellite orbiting the planet, and of the layout of the control center. Green weighed in on what the Hermes—the spacecraft used by the Ares III crew in the film to travel between Mars and Earth—would look like. (The filmmakers went through two versions before settling on a third, which uses ion engines to get to our red neighbor.) He also read the script, jotting down notes and comments that he went over with Max when he came to NASA. Most of Green's comments “were really all about how to make the movie use some of the latest information about Mars,” he says. In most cases, though, the filmmakers decided to stick with what was in the book, which was fine with Green: “It’s cleaner. It’s easier. It is something they can fall back on,” he says.
Dr. Green spoke with mental_floss about the ways NASA helped to tweak the screenplay to make The Martian as realistic as cinematically possible. The article about the collaboration contains no spoilers, as far as I can tell.