Since the word "math" can cause terrifying S.A.T. flashbacks in many fraction-phobes, you might consider it a deadly topic for a film.

But “Good Will Hunting” (which has grossed $121.5 million) and a pair of upcoming Sundance hits — “Cube” and “

” — may prove that tossing in some trigonometry won’t necessarily stop audiences from turning out in big numbers.

Though most mathematicians don’t look like Matt Damon, many people still find numbers work very exciting. “What mathematicians do and the kind of math people study at school are completely different,” says M.I.T. professor Daniel Kleitman, the mathematical consultant for “Good Will Hunting.” “It’s like the difference between an explorer and a teacher of geography. A mathematician is more like an explorer in the realm of math.”

A mathematician doesn’t have to be meek, either: He can be as excitingly unbalanced as any Dennis Hopper character. “

,” opening July 10th, deals with a reclusive math genius who attempts to find an equation to predict the stock market and ends up trying to decipher the meaning of life. “Our mathematician is a modern-day mad scientist,” says director Darren Aronofsky, who won the directing prize at Sundance for “

“. “I was a total non-math person in high school. But to me, there’s something sexy about the lone genius off on his or her own.”

Of course, it also helps that these films have a lot more than math factored in their plot equations. “Good Will Hunting” has a love story and a complex, conflicted protagonist. “Cube” (opening this summer) is essentially a horror film, about six people who need to decipher a math code to escape a lethal maze of futuristic boxes. And “

” has suspense: The genius is hunted by people who are eager to obtain his theorems. “Ultimately, the film is just a thriller, with really neat tricks about math,” says Aronofsky.

With an entertaining story, even the most ardent math haters can be won over. “People don’t understand science either, and science fiction movies are a big hit,” says J.L. Alperin, professor of mathematics at the University of Chicago. “The public realizes that a movie’s not like a classroom. There’s gonna be some mathematician doing some funny formulas in the movie, saying words they don’t understand, but it’s no threat to them.” At least, until Loews Theaters starts handing out tests.

  • Movie