“Arrival,” the new movie from Denis Villeneuve (“Sicario,” “Prisoners”), which Anthony Lane reviewed in last week’s issue of the magazine—and which, this past weekend, earned twenty-four million dollars at the box office, more than people were expecting—is based on “Story of Your Life,” by the literary sci-fi writer Ted Chiang. It stars Amy Adams as a linguist who comes to play an extraordinary role during an alien visitation. The movie is a model of faithful, transformative film adaptation. It’s also an exploration of a humble and brave ontological position that, in the aftershock of the Presidential election, feels as sublime, unfamiliar, and vaguely oracular as the iron-gray spaceships that hover in the film.

There are twelve of these spaceships in total: tall, partial ovoids, silent and weightless, suspended feet above the Siberian tundra, the Indian Ocean, the Sudanese desert. The news coverage is immediately hysterical, of course. But the objects seem lonely, not menacing; they are visual articulations of the tone of the movie, powerfully incomprehensible and sad. The opening of “Arrival” sets this mood, with Max Richter’s elegiac strings piece “On the Nature of Daylight” connecting a series of apparent flashbacks, in which Amy Adams watches her daughter grow from infancy to girlhood to young adulthood, then die. “I’m not sure I believe in beginnings and endings,” Adams murmurs, handing the audience an epigraph and a clue.

Adams plays a self-effacing professor named Louise Banks, who remains calm as the spaceships descend. Viewers, on the other hand, might find their pulses rising, as I did; post-election, the panic resonates. Students walk out of class; the stock market plunges; fights break out in public; everyone calls his mom. “Me?” Banks says, cradling a phone to her ear, kicking off her shoes in the house where she lives alone. “You know me. I’m about the same.” The next day, a military official shows up in her office with a recording of alien language. Then, while she’s sleeping, shards of light break across her bedroom, waking her. An alarming craft descends from above. It’s the government, taking her to Montana to translate firsthand.

Villeneuve made “Arrival” with the screenwriter Eric Heisserer, who spent six years adapting Chiang’s “Story of Your Life” on spec. The cinematographer Bradford Young, who also worked on “A Most Violent Year” and “Ain’t Them Bodies Saints,” does uncommon work to expand an esoteric story about death and linguistics into a tale that feels as wild and wide as the sky. Chiang writes with a gruff and ready heart that brings to mind George Saunders and Steven Millhauser, but he’s uncompromisingly cerebral: “Story of Your Life” contains explanations of variational calculus, charts that illustrate the mathematician Pierre de Fermat’s principle of least time, and sentences like “The sound spectrograph for ‘heptapod eats gelatin egg’ was analyzable.”

The filmmakers steer clear of this lecture-hall material, and Young turns Chiang’s functional transitions into rich and staggering visual revelations. In “Story of Your Life,” Banks arrives on site by driving an “off-road vehicle into the encampment, a small village of tents pitched by the Army in a farmer’s sun-scorched pasture.” In “Arrival,” this moment is not quotidian: it’s breathtaking, sublime. “Behold the great mass of the thing, standing prouder than a neolithic stone,” Lane writes in his review, “with green prairies beneath and billows of bright fog streaming off the hills and breaking around it like waves. David Lean would have approved.”

Chiang writes the human-alien encounters as leisurely endeavors, conducted through a looking glass, in a utilitarian tent, over the course of months. Heisserer, thankfully, puts the humans and aliens in direct communication, and adds an element of geopolitical conflict that speeds up the plot. Banks and her assigned partner, a physicist named Ian Donnelly (Jeremy Renner), ascend deliriously through an opening in the spaceship itself, astronauts in hazmat orange floating up in zero G. The site of encounter is cavernous and lunar. The seven-legged aliens, called heptapods, have no front, no back, no faces; they move like elephant trunks, insects, anemones, angry brooms. And yet it’s wondrous, not monstrous, to meet them. Outside, the world has been plunged into fear, panic, and crisis; inside, there’s a sense of loneliness, ineffability, and strength.

Banks is a wonderful character for Adams, who naturally projects sweetness and resilience; she’s bolder than her physicist partner, as well as the military blowhards directing the operations at all twelve sites. She takes off her hazmat suit and elicits the alien language in writing. “A doodle of script, vaguely cursive, popped onto the screen,” Chiang writes. In the movie, this event is rendered to make the theatre gasp. A heptapod splits its own leg into a spindly, squishy starfish; it blasts a cloud of ink that smokes and curls like cream in iced coffee, and then resolves into an ornamented circle—their version of a sentence. The written heptapod language, Banks realizes, has an entirely alien grammar. As with their bodies, there’s no forward or backward direction. They don’t speak in terms of causality or linear time.

In Chiang’s story, this discovery is prompted by a breakthrough in alien physics: the heptapods don’t understand algebra, but they understand the variational calculus behind Fermat’s principle, which dictates that a ray of light always travels the shortest possible distance between two points. Fermat’s principle is “purposive, almost teleological.” The ray of light, in order to maximize efficiency, seems to know where it’s going from the start. In the movie, Banks begins to experience the events of her life with a corresponding simultaneity; the heptapod language is teaching her the heptapod way of seeing. “I’m not sure it’s something I can explain,” she tells Donnelly, as the flashes from the beginning of the movie keep intruding, building to a revelation. Chiang writes, “We experienced events in an order, and perceived their relationship as cause and effect. They experienced all events at once, and perceived a purpose underlying them all.”

Banks, by the end, is seeing the future. And, wonderfully, none of her instincts tell her to resist it; she gains a sort of divine urgency to carry out her part. (If you watch “Arrival” after reading “Story of Your Life,” you’ll get another shade of this feeling: the movie is exactly, equally urgent even if you know what’s in store.) As the global panic escalates, an Alex Jones type rants about the heptapods on YouTube: the smartest thing we could do, he says, is display force. A war nearly begins when the heptapods state their desire to offer a “weapon,” which Banks frantically tells her superiors could mean something as innocuous as “tool.” In a stupefying final encounter, the heptapods communicate to Banks that they’ve really been trying to pass down a gift. It’s a trade, in the long run: in three thousand years, they’ll need the help of humanity.

The Sunday after the election, I watched this and wept. What a dream—to perceive instinctive purpose in what happens around us, to submit to that teleology, to enact it. What a fantasy, to imagine that we’ll be around to help anyone in three thousand years.