This photo provided Friday, Nov.14, 2014 by the IHES (High Scientific Studies Institute) shows mathematician Alexandre Grothendieck, at the blackboard, during a lesson, south of Paris, in the 1960's. Grothendieck, an opinionated and reclusive German-born giant of 20th-century mathematics who shunned accolades and supported pacifist and environmental causes, has died, the French presidency said Friday. He was 86. (AP Photo/IHES)

Alexander Grothendieck, one of the great eccentric geniuses of 20th century mathematics, has died in France at the age of 86.

The maths master reached the very pinnacle of his profession before abandoning the discipline, taking up anti-war activism, retreating into the life of a recluse and refusing to share his research.

He died on Thursday in a hospital in Saint-Girons in southwestern France, staff said, without giving further details.

Born in 1928 in Berlin to a Russian anarchist father and a journalist mother, Grothendieck's parents left him behind in Germany while they went to fight in the Spanish Civil War.

They were reunited in France, where Grothendieck was to spend most of his life, only for his father—a Jew—to be rounded up by the Nazis and killed in Auschwitz.

Grothendieck went on to become a revolutionary mathematician, doing groundbreaking work on algebra and geometry that won him the Fields medal, known as the Nobel prize of the maths world, in 1966.

According to the legend that has built up around Grothendieck, his talents were not immediately obvious when he was a young man.

It was while he was studying at the University of Montpellier that two professors gave him a list of 14 questions, considered to be years' worth of work, and told him to pick one.

Grothendieck came back a few months later having completed them all.

"He was one of the giants of mathematics who transformed mathematics entirely with his work," said Cedric Villani, who won the medal in 2010.

French President Francois Hollande praised the memory of "one of greatest mathematicians" who "was also an extraordinary personality in his philosophy of life".

Grothendieck refused to accept the Fields award and turned down the job offers that poured in from universities around the world. His life was already headed in a more radical direction, given a boost by the 1968 student protests in Paris.

By the 1970s, he had all but abandoned his research, preferring to focus on environmental politics and anti-war activism. He quit the Institute of Higher Scientific Studies near Paris after discovering it took a small part of its financing from the defence ministry.

He also gave up a post at the College de France to join the University of Montpellier where he often found himself on the frontlines of anti-nuclear protests.

"His greatest and unique violence against the scientific community was that he stopped doing mathematics," celebrated mathematician Denis Guedj told France's Sciences et Avenir magazine.

Hidden treasure

Grothendieck did not completely give up on his research, but increasingly refused to share it publicly.

In the early 1990s he handed 20,000 pages of notes and letters to a friend who looked after them for several years before passing them on to the University of Montpellier.

Under strict orders from Grothendieck, they have been kept under lock and key in the university's archives.

In his latter years, there were reports that Grothendieck had descended into religious mania. He had moved to a tiny village in the Pyrenees where he refused all visitors and jealously guarded his privacy.

He tried to wipe away any trace of his past life, writing an angry letter to one of his students in 2010 demanding that his entire back catalogue be removed from libraries and refusing to allow republications.

With his passing, a new generation of mathematics students may get the chance to explore the treasures he left behind and fully appreciate the impact he had on the profession.

"The ideas of Alexander Grothendieck have penetrated the subconscious of mathematicians," his most celebrated student, Fields medal winner Pierre Deligne, told Le Monde newspaper. "He was unique in his way of thinking."