Matt Damon in a scene from the film, "The Martian." (Giles Keyte/20 Century Fox via AP)

Scientists are used to suspending disbelief when they go to movies. But “The Martian,” which opens Friday, offers a mostly realistic view of conditions that astronauts might encounter on Mars.

The movie “is a vision of a future we can step into and make happen,” says Jim Green, director of NASA’s planetary science division and a science adviser to the film’s director, Ridley Scott.

In that envisioned future, wisecracking astronaut Mark Watney (Matt Damon) is stranded on Mars in 2035 after a fierce storm. NASA thinks he’s dead. His communications have been cut off. He’s got limited food. And the next mission to Mars won’t arrive for four years. There’s only one solution: “I’m going to have to science the [expletive] out of this,” Watney says.

His story first appeared in Andy Weir’s 2011 novel of the same name. “The core focus of the book is basically resourceful problem-solving,” Weir says, “sort of a combination of Robinson Crusoe, MacGyver and Apollo 13.” Weir provided the fictional astronaut with real equipment or minor improvements to today’s technology.

For instance, Watney’s air supply comes from an “oxygenator” that extracts breathable stuff from carbon dioxide in Mars’s atmosphere. “Not only is that real, it’s going to fly on the next NASA rover mission,” says Edwin Kite, a planetary scientist at the University of Chicago. NASA calls the equipment MOXIE; the Mars 2020 mission will test the instrument’s ability to provide oxygen for human explorers in the 2030s.

Most of the scenarios Watney encounters — and his solutions — are rooted in science, Kite and others say. Watney has to grow food to supplement his rations, which are meager. He becomes the self-proclaimed “greatest botanist on this planet” when he turns part of an intended Thanksgiving meal into a crop of potatoes.

Growing plants on Mars is feasible, says astrobiologist Thomas McCollom of the University of Colorado at Boulder. “You’d probably have to do some work on your soil first,” he says, to remove or neutralize salt and damaging chemicals such as perchlorates and hydrogen peroxide.

But the Curiosity rover and other Mars missions suggest that growing crops may be easier than once thought. Mars soil already contains nitrogen in a biologically usable form. And in one death-defying scene, Watney burns hydrogen liberated from rocket fuel to get water. But in reality, ice is just under the planet’s surface, “so all Mark had to do was bring dirt in and heat it up to get water,” Weir says.

There’s one notable exception to the believability of “The Martian”: the storm that strands Watney. “The hurricane-force winds that tear things apart are exaggerated,” planetary scientist Ramses Ramirez of Cornell University says.

That’s because the atmosphere is thin. Atmospheric pressure at Mars’s surface is only 0.6 percent of Earth’s. Winds could well reach hurricane speeds, but they would not push enough air mass to tear apart equipment and whip up sand and small rocks. A 150-mph wind on Mars is a breeze, Green says. “It’s not enough to straighten an American flag.”

Weir calculated how furiously winds on Mars would need to blow to create the killer storm: more than 10,000 mph. In the movie, the crew that landed on Mars with Watney discusses the storm’s power in terms of force in newtons, instead of providing wind speed. The viewer then must “do an extra step of math to figure out how implausible the storm is,” Weir says.

“The Martian” wields science and technology to tell a gripping tale. Scott preserves the book’s sense of adventure, produces spectacular panoramic views of the landscape and highlights the humor, ingenuity and perseverance of the primary characters: the space agency’s astronauts, engineers and administrators. The movie’s real hero is science.

This article first appeared in Science News, the magazine of the Society for Science & the Public.