The Weinstein Company on Monday released a trailer for its upcoming film based on the life of Alan Turing.

The 38-year-old Benedict Cumberbatch (Star Trek Into Darkness, 12 Years a Slave, August: Osage County) plays Turing in the film. (The trailer is embedded on this page. Visit our video library for more videos.)

Turing, described as a brilliant mathematician, helped crack the German Enigma machine code – a triumph of computer science and a turning point for the Allies in World War II.

He died an early death for acknowledging that he was gay. In 1952, Turing and Arnold Murray were charged with gross indecency after Turing disclosed their relationship to detectives investigating a break in at Turing's Manchester home. Turing was convicted and given the choice of going to prison or submitting to a form of chemical castration via estrogen hormone injections. He chose the latter. The therapy left him impotent and he developed breasts.

It is widely believed that he committed suicide two years after his arrest by eating a cyanide-laced apple.

Last year, Turing was given a posthumous pardon by Queen Elizabeth II.

The Imitation Game, which opens stateside on November 21, also stars Keira Knightly as Joan Clarke, a fellow code-breaker engaged to Turing for a short time before he confessed he was gay.