There are several positive factors in the mixed equation that is “Gifted,” starring Chris Evans and the appealing 10-year-old Mckenna Grace: A brilliant and precocious, yet sweetly empathetic, young girl. A devoted and decidedly hunky father figure. And then there’s math itself, presented not as a refuge for social misfits, but as an exciting and elegant pursuit.

Unfortunately, a movie about mathematical formulas relies way too much on a movie-making formula, and the result is way less than the sum of its parts. Indeed, “Gifted,” directed by Marc Webb, often feels like the incomplete shell of a movie, with the guts and connective tissue missing.

This is hardly the fault of the cast, which also features the welcome (but underused) presence of Octavia Spencer, and the estimable Scottish actress Lindsay Duncan. Rather, it seems due to the way-too-obvious dialogue and often unconvincing plot twists, not to mention a courtroom subplot that is, strangely, rarely interesting.

We meet Frank (Evans) and 6-year-old Mary (Grace) as the two are readying for her first day of school. Until now, Frank, Mary’s uncle who has been raising her since she was a baby, has home-schooled her, but that well has run dry. Mary, a child prodigy, is not excited for school, and one can see why: the children are asked simple addition questions, but Mary shows an ability to do complex multiplication in her head. Immediately, the teacher, Bonnie (Jenny Slate) knows she has a gifted child on her hands.

Mary has a caring disposition and a sweet smile, but also a dry wit when bantering with Frank. When Mary’s teacher approaches Frank after school that first day, the girl whispers: “Oh, it’s my teacher. She probably wants to remind me what one plus one is.”

When the school principal suggests — almost orders — that Frank enroll Mary in a school for gifted children, Frank insists otherwise. He has some knowledge from his own family of what it’s like to live as a prodigy, cut off from a normal social life. He wants Mary to have friends and playdates.

In marches Frank’s mother, Evelyn (Duncan), a hard-edged Brit (and former mathematician herself) who has clear ideas of what she wants for Mary: a life of productivity, brilliance, academic fame. She brings Mary up to MIT, to show off the girl’s mathematical brain. Most importantly, she sues Frank for custody.

The first courtroom scene comes abruptly, with no real buildup. Then, the dialogue is so superficial that it just doesn’t feel real. The same problem wends through all the courtroom scenes.

As the plot unfolds, there’s the occasional bright moment, usually thanks to Mary’s wit (And Mckenna’s genuine screen presence). One of the most amusing moments comes when teacher Bonnie, against her judgment, falls into bed with Frank after an evening of drinking. Mary, who’s supposed to be visiting neighbor Roberta (Spencer), sneaks into the apartment to grab something and runs right into Bonnie, who’s clutching a sheet around her naked body. The young girl’s knowing look — and especially her three-word response — is priceless.

More courtroom fighting comes, and once again, both plot and dialogue prove themselves overly simplistic and in some cases, simply not believable. This is especially true in a final twist that feels utterly tacked on, to miraculously tie up the plot’s loose ends.

That’s a shame, because the sensitive performances here deserved a better vehicle. Nonetheless, there will surely come a moment deep in the film when your eyes will moisten, because, hey, is anyone totally immune to a happy moment between an adult, a child and a one-eyed cat?

It’s too bad that by then, the whole thing feels just a little over-calculated.

“Gifted,” a Fox Searchlight release, is rated PG-13 by the Motion Picture Association of America for “thematic elements, language and some suggestive material.” Running time: 101 minutes. Two stars out of four.

McKenna Grace and Chris Evans appear in a scene from, ‘Gifted.’ Grace plays Mary, a child math prodigy who is being raised by her uncle (Evans).
http://www.theweekender.com/wp-content/uploads/2017/04/web1_AP17093148207579.jpg.optimal.jpgMcKenna Grace and Chris Evans appear in a scene from, ‘Gifted.’ Grace plays Mary, a child math prodigy who is being raised by her uncle (Evans). AP photo

Jennie Slate, left, portrays Mary’s (McKenna Grace) teacher, who recognizes the child’s need for advanced schooling, in ‘Gifted.’
http://www.theweekender.com/wp-content/uploads/2017/04/web1_Gifted2.jpg.optimal.jpgJennie Slate, left, portrays Mary’s (McKenna Grace) teacher, who recognizes the child’s need for advanced schooling, in ‘Gifted.’ AP photo

By Jocelyn Noveck

The Associated Press

‘Gifted’

Starring: Chris Evans, McKenna Grace, Octavia Spencer

Director: Marc Webb

Rated: PG-13

Weekender Rating: WW out of WWWW

Length: 101 minutes