Hardy was the English mathematician who plucked Ramanujan from obscurity in Edwardian India and installed him in Cambridge University.
The film, produced by Edward R Pressman and Prashita Chaudhary of Cinemorphic with Jim Young and Sofia Sondervan, will be directed by Matthew Brown.
Brown also wrote the screenplay based on the biography 'The Man Who Knew Infinity: A Life of the Genius Ramanujan by Robert Kanigel'.
"I'm very excited that an actor like Jeremy Irons will play the crucial role of Ramanujan's mentor G H Hardy. I look forward to the film's shoot in India and the UK next year," Prashita said.
More From This Section
Irons won the Academy Award for Best Actor for his performance as Claus von Bulow in 'Reversal of Fortune'.
The production of the biopic is expected to commence on locations in the UK and India in 2014.
Ramanujan, who died at the age of 32, continues to fascinate filmmakers.
A self-educated mathematical prodigy, Ramanujan was born in rural Southern India in 1887. With no guidance other than a university textbook that he found, Ramanujan spent years filling three notebooks with groundbreaking insights. He kept sending his findings to mathematicians, finally attracting the attention of Hardy.
Hardy recognised his brilliance and invited him to visit and work with him at Cambridge. Ramanujan became a Fellow of the Royal Society and a Fellow of Trinity College, Cambridge.