"It's not necessarily a black and white scenario - it's a bit messier than that."

Dr Mark Green, a senior lecturer in health geography at Liverpool University, sums up the puzzle of the UK's unprecedented stalling in life expectancy.

"Since the turn of the 1900s life expectancy has increased," he says.

"Sometimes it's been volatile, but the trend is to go up and up: we've been living longer lives, better lives, and living longer lives in health as well.

"But it just did not continue. From 2012 the improvements just disappear."

Dr Green is speaking to the Herald on Sunday days after the latest statistics revealed that Scotland not only has the lowest life expectancy at birth in western Europe, it has also had the slowest growing.

Since 2012, Scotland has added just 29 days in total to male life expectancy and 26 days for females.

To put that into context, in the previous decade we were adding 16 weeks on average to male life expectancy every year and nearly 10 weeks per year to female life expectancy.

In the UK overall it is up 110 days.

The Herald: Changes in life expectancy in Scotland since 2000Changes in life expectancy in Scotland since 2000

But the statistics also reveal something surprising.

Our nearest neighbour, the Republic of Ireland, has seen its life expectancy at birth climb by more than 19 months and 12 months respectively for men and women over the same period.

Ireland's life expectancy is growing faster than anywhere else in western Europe.

To understand why this might be, you first have to understand what 'life expectancy' really is.

"It doesn't tell you how long you're likely to live," says Dr Gerry McCartney, a member of the Faculty of Public Health in Scotland.

"Life expectancy is calculated by adding up the mortality rate across all age groups at any particular time and pretends as if those mortality rates would apply to everybody for the rest of their lives, and that would be the age they could expect to live until.

"It's a completely notional figure."

READ MORE: Why trying to 'shield the vulnerable' while the rest of us carry on is doomed to fail

As a result, increases in death rates - for example, the opioid epidemic in the US or the Covid-19 crisis now - feed into the formula for life expectancy.

A decline in life expectancy is really a shorthand for saying that premature deaths are on the rise.

In the UK and US the slowdown actually began in the 1980s and 1990s as deaths from drugs, alcohol, suicide and violence increased, but this was "very much more pronounced" in Scotland, says Dr McCartney.

They were also concentrated in poorest areas, exacerbating health inequalities.

"Although average life expectancy improved right up until 2012 in Scotland, inequalities were widening quite rapidly towards the end of that period and indeed, in our most deprived areas, life expectancy was actually declining already," says Dr McCartney.

"Now there's been virtually no improvement over most of the last decade, but that again masks a widening in inequalities: for the poorest 40 per cent of the population life expectancy has actually been decreasing"

Dr McCartney says the causes are clear.

"Since 2010 a range of economic policies were introduced following the financial crash, which included things like social security benefits becoming less valuable in real terms and more conditions being put on them.

"That means the real incomes for the poorest 10th of the population across the UK have decreased by 8% over that time.

"So it's no surprise that mortality rates in that group have gone up.

"That goes alongside changes in the labour market: more precarious work, more short-term work, the problems with in-work poverty, increasing child poverty and the like.

"You've also got a bigger proportion of the population in Scotland who are on social security benefits and health-related benefits, so a change in those benefits will impact Scotland disproportionately.

"We also have longer-standing health problems here. That leads to a population who are more risk when things do go badly.

"But it is also worth saying that within England there are really different trends: England looks better because of London.

"If you look at the north of England and Wales, their trends are just as bad as Scotland."

So why has Ireland fared so much better when its 'Celtic Tiger' economy was also battered by the credit crunch?

READ MORE: Covid death toll figures 'underplay' cost of pandemic to public health, leading medic warns

Socially and culturally Ireland has much in common with Scotland.

Average alcohol consumption is slightly higher in Ireland, but our rates of obesity and smoking are greater.

Even adjusting for Ireland's comparatively younger population, Scotland's mortality rates from cancer and cardiovascular disease are both higher.

Per head, Ireland has slightly more doctors and hospital beds than the UK, more CT scanners, and higher health spending.

In the mid-1980s, Scotland and Ireland shared the same life expectancy: 70 for men and 76 for women.

Today it is 77 for men in Scotland and 80.5 for men in Ireland; for women, it is 81 years here to 84 in Ireland.

The Herald: Ireland life expectancy, 2008-2018 Source: World BankIreland life expectancy, 2008-2018 Source: World Bank

Professor Richard Layte, a sociologist and health researcher at Trinity College Dublin, said Ireland's EU membership fostered improvements in living standards which were accelerated by the economic boom of the 1990s.

This ran in tandem with Scandinavian-style labour market policies and improvements in unemployment and child welfare benefits to create a "virtuous circle" that improved life expectancy, said Prof Layte.

After 2012, with an €18 billion black hole in its finances, spending was cut but borrowing increased.

"There were reductions in some healthcare provision, benefits for younger people, some parent benefits, and there were reductions in areas such as education," says Prof Layte.

"But none of the reductions that happened in Ireland were savage to the point where those services stopped running.

"There is quite a lot of literature comparing Ireland to some of the other states in Europe, like Greece, where whole areas of public health and social welfare were just cut off.

"You ended up with increases in mortality in Greece that were directly reflective of these cuts.

"But when you look at Ireland, although we had reductions, we never had the savage reductions that happened elsewhere."

Ireland's healthcare system is also different, adds Prof Layte.

In Ireland, around half the population have private medical insurance while the poorest third receive medical cards entitling them to free healthcare.

That leaves around 20% paying for medications and GP appointments, which cost €50-75 per visit, but during the recession - as incomes fell - more people qualified for free medical cards.

Insurance-based schemes, especially the state-backed models used in Germany and France, are generally more resilient during an economic crisis.

Ireland's set-up also appears to be less prone to one of the anomalies which plagues the universally free NHS: overuse by the affluent 'worried well'.

"Overall, you've got the poorest third of the population that get healthcare for nothing, so they're quite protected," says Prof Layte.

"Then you've got the half of the population getting it through insurance and they get very quick and good healthcare.

"What this leads to is a distribution of use of healthcare in Ireland which, if anything, is quite pro-poor. It's good for people who are at the bottom of the income distribution table.

"Whereas in Britain, with the NHS, what you tend to find is that the distribution of use is a little bit pro-rich.

"Everyone's getting it on the same footing, but the middle classes make more use of it."

READ MORE: Health of poorest adults today worse than it was for those born in 1920 

There are those who have pitched the recent stalling in UK life expectancy as a random event, or the result of a couple of particularly virulent winter flu seasons.

Dr Green believes the latter might be "part of the explanation but probably not all of it", with austerity policies being the key driver.

But he also believes something else might be at play: the ageing population.

Around 19% of Scotland's population is 65 and older, compared to 13% in Ireland.

"Both in Scotland and the rest of the UK, people are getting older on average, we're living much longer lives, and that is the success of public health," says Dr Green.

"That might be putting a strain on our health services because they've got greater numbers of patients to deal with, and because people are living into later life with multiple conditions.

"So they're becoming much more complex to treat and harder to care for.

"But that probably wouldn't have led to the sudden change in life expectancy we can see in the Scottish and English data.

"It's a lazy explanation really, and it ignores the fact that our health services aren't properly funded to meet that demand.

"That's the real problem: not setting up enough care to support these ageing populations."

Lockdown and the control measures to decrease direct Covid deaths have the potential for unintended consequences on health and mortality

And there's still the fallout from the pandemic to come.

Modelling by experts at Public Health Scotland and the Glasgow Centre for Population Health (GCPH) estimates that a best-case scenario of 20,000 Covid deaths would shave around 15 weeks off life expectancy, or six years in the worst-case scenario of 500,000 UK deaths.

To date, the UK has exceeded 42,000 confirmed Covid deaths.

Dr David Walsh, public health programme manager at GCPH, stressed that these were only the direct Covid deaths.

"Lockdown and the control measures to decrease direct Covid deaths have the potential for unintended consequences on health and mortality.

"Losing your job increases your risk of premature mortality by around 63%, which is pretty staggering.

"Then there's the social isolation, the mental health consequences, the education loss children are experiencing.

"There's the difficulties around accessing healthcare during the pandemic: a lot of outpatient clinics and cancer care was postponed to prevent the spread of the virus.

"That's all likely to have negative impacts on people's health and life expectancy in due course."

Scotland's excess deaths from all causes had already surpassed 4,800 by the end of July.

Per head, Scotland's excess death rate is five times that of Ireland, pointing to an even wider gap between the nations in future.

So what should we be doing?

"It's not a mystery," says Dr Walsh. "We know what to do, but what it requires is political will.

"We produced a report a few years ago looking at the excess levels of mortality in Glasgow and Scotland and that was accompanied by about 27 different policy recommendations.

"The problem is, the more you get into the issue of austerity, the more you're making recommendations to the UK Government rather than the Scottish Government and at that point the extent to which they're going to respond is frankly doubtful. That's the issue.

"It's not that we don't know what to do - it's that it requires the will to implement them."