The fairness of the criminal courts process goes on trial this week when two men who spent a total of 24 years wrongfully imprisoned seek compensation for their ordeals.

Sam Hallam, who served seven years for murder, and Victor Nealon, who spent 17 years in jail for attempted rape, were both freed after the court of appeal ruled they should not have been convicted. Neither, however, has ever received any apology or recompense.

Their claims come before the supreme court this week when it will examine whether the law’s restrictive definition of miscarriage of justice is incompatible with the presumption of “innocent until proved guilty” under the Human Rights Act.

Hallam, from Hoxton, east London, was released in 2012. He had been convicted at the age of 17 of participating in a gang fight that left one man dead. His original trial heard conflicting testimonies in which witnesses retracted their identification evidence and his mobile phone was never examined to support his claim that he had never been at the scene of the attack.

Nealon, a former postal worker, was released in 2014. He had originally been found guilty in 1997 of the attempted rape of a woman leaving a nightclub in Redditch, Worcestershire. His conviction was overturned by the court of appeal after fresh DNA evidence indicated someone else had been the attacker. Nealon could have left prison after seven years but was repeatedly refused parole because he refused to accept his guilt or undergo rehabilitation for the crime he was accused of.

Their cases are not exceptional. The number of successful compensation awards following quashed convictions has fallen sharply in recent years. In 2014–15, there was one successful compensation application, the following year the figure was two, in 2016–2017 there was one award and last year there was none. In 2004–5, however, the scheme paid out on 48 occasions.

The problem is highlighted in a new book published this week, Guilty Until Proven Innocent by Jon Robins, which focuses on the deepening crisis around miscarriages of justice.

In 2006 the then Labour home secretary, Charles Clarke, scrapped a scheme of ex-gratia payments to compensate victims of miscarriages of justice. Subsequent legal changes in 2014 restricted payments to only those who could prove their innocence “beyond reasonable doubt”.

Hallam said in an interview with Robins: “Money cannot make up for what happened. It is more about recognising the harm done.”

Hallam’s girlfriend, Renee, added: “Everyone just shrugged their shoulders and said: ‘Well, you’re out now. You should just be happy.’”

Robins, the book’s author, explained: “When a conviction is quashed, the court of appeal does not reinstate the presumption of innocence … There is less state support for the victims of miscarriages of justice than for other prisoners.

“A miscarriage of justice is not a one-off event. The correct analogy is not so much a car crash but a serial motorway pile-up. First they are failed by the criminal justice system …. Then they are failed by the penal system. Finally, if their conviction is overturned then, like Sam Hallam, they are undoubtedly innocent – and yet not innocent enough.”

Matt Foot, Hallam’s solicitor at the London firm Birnberg Peirce, has called the 2014 compensation threshold “absolutely shocking”.

“It isn’t just about compensation. It is about looking after people who have come through this experience. They’re left on the scrapheap with no one to look after them. They are damaged people – the experience lives with them for ever,” he said.

Two other high-profile victims of miscarriages of justice, Paddy Hill of the Birmingham Six and Patrick Maguire of the Maguire Seven, will be outside the supreme court on Tuesday to support Hallam’s and Nealon’s applications.

Justice, an organisation campaigning to reform the law, has been granted permission to intervene in the supreme court case, which will be heard by a bench of seven judges – an acknowledgment of the significance of the case.

According to a report published by Justice last month and titled Supporting Exonerees, people exonerated or cleared of their supposed crimes “do not receive the support they need to return to a normal life and are not properly compensated”.

The report also called for specialist psychiatric care for those who have been freed, automatic compensation for wrongful imprisonment subject to certain exceptions and an apology as well as an explanation of the failure that leads to a quashed conviction and, where necessary, a public inquiry.