Alan Turing was one of the most important computer scientists of the 20th century. He contributed not only to the foundations of the study of artificial intelligence, but played an important–perhaps the most important–role in the British World War II code-breaking effort that was headquartered at Bletchley Park, north of London. After the war was over, Turing continued his work in both the civilian and military worlds and was elected a Fellow of the Royal Society in 1951.

Turing was gay, a not unusual situation for a British intellectual of the period. That latter did not help, however, when he was arrested and convicted in 1952 of “gross indecency” for his relationship with a young Manchester man. This was the same crime for which Oscar Wilde had been convicted more than half a century previously.

Turing’s choice was jail or probation contingent on him being “chemically castrated” through regular injections of estrogen. He chose the latter, and remained out of jail. But the Cold War panic over security meant that the government would no longer give security clearances for avowed homosexuals. The rationale was that they could be easily blackmailed by the Soviets, though logic would suggest that avowed homosexuals no longer had anything about which to be blackmailed. Despite that rather obvious conclusion, Turing’s security clearance was revoked and he was forbidden from working on military cryptanalysis projects.

On June 8, 1954, Turing’s cleaning lady found Turing dead in bed. He had ingested potassium cyanide, whether accidentally (as his mother insisted) or deliberately (as most others seem to think).

And there things might have remained, an appalling story of injustice rapidly fading into the depths of the past. Might have, except John Graham-Cummings, a programmer of some repute, decided to mount a petition to try and get the British government to apologize for its treatment of Turing. He did not expect to succeed in this obscure and perhaps quixotic quest, but he pushed hard at publicizing the petition, and last week, the Prime Minister of the United Kingdom, Gordon Brown, called him:

A few minutes later the phone rang and a soft Scottish voice said: “Hello John. It’s Gordon Brown. I think you know why I am calling you”. And then he went on to tell me why. He thanked me for starting the campaign, spoke about a “wrong that he been left unrighted too long”, said he thought I was “brave” (not sure why) and spoke about the terrible consequences of homophobic laws and all the people affected by them.

That same day, the PM released a statement of apology:

While Turing was dealt with under the law of the time and we can’t put the clock back, his treatment was of course utterly unfair and I am pleased to have the chance to say how deeply sorry I and we all are for what happened to him. Alan and the many thousands of other gay men who were convicted as he was convicted under homophobic laws were treated terribly. Over the years millions more lived in fear of conviction.

Alan deserves recognition for his contribution to humankind. For those of us born after 1945, into a Europe which is united, democratic and at peace, it is hard to imagine that our continent was once the theatre of mankind’s darkest hour. It is difficult to believe that in living memory, people could become so consumed by hate – by anti-Semitism, by homophobia, by xenophobia and other murderous prejudices – that the gas chambers and crematoria became a piece of the European landscape as surely as the galleries and universities and concert halls which had marked out the European civilisation for hundreds of years. It is thanks to men and women who were totally committed to fighting fascism, people like Alan Turing, that the horrors of the Holocaust and of total war are part of Europe’s history and not Europe’s present.

So on behalf of the British government, and all those who live freely thanks to Alan’s work I am very proud to say: we’re sorry, you deserved so much better.

The apology cannot, of course, stand in for justice at the time. It is nonetheless some small form of redemption, for the British government more than Turing, who himself actually needed nothing in the way of absolution.