Image copyright Met Office Image caption Storm Ciara and Storm Dennis have both caused widespread wind and flooding damage

Ever wondered why your village was suddenly flooded by a thunderstorm the weather forecasters hadn't mentioned?

Or why they failed to warn you about the dense fog shrouding your home in the morning?

The fact is that predicting the "big picture" of future conditions has got a lot better - Storm Dennis was spotted six days before it arrived.

But getting local forecasts right - street by street and hour by hour - is still a massive challenge.

And that might now change as the Met Office secures the help of a supercomputer project costing £1.2bn.

Better forecasting means handling more data, more rapidly, and running it through simulations of the atmosphere more accurately.

Already the Met Office is pulling in more than 200 billion observations from satellites, weather stations and buoys out in the ocean every single day, and that's set to increase.

And working out if a summer downpour will flood your home or one down the road requires more and more processing power.

Image copyright Met Office Image caption The Met Office's existing supercomputer

"We'll be streets ahead of anybody else," according to Penny Endersby, chief executive of the Met Office.

"Ultimately it'll make a difference to every individual, every government department, every industry as people see forecasts becoming steadily better."

It'll be the biggest investment in the 170-year history of the organisation and will dwarf the £97m bill for the current supercomputer.

In the new project, the billion-plus cost will cover not just the hardware itself but all the running costs too over a ten-year period.

There'll be a first stage installation, which should be six times more capable than the supercomputer used now.

And then five years later there'll be a major upgrade to increase performance by a further three times.

What will the supercomputer actually do?

It'll run what the Met Office calls its "digital twin" of the Earth's atmosphere, a highly detailed "model" of everything from the winds to the temperatures to the pressures.

Image copyright Met Office Image caption The new supercomputer will be six times more capable than the current one

To create this simulated picture of our weather, the globe is divided into grid squares.

These have become smaller as the technology has advanced - and the smaller the better because that means more accuracy.

At the moment, the model of Earth is divided up into a grid of squares that are 10km across.

The UK gets more detailed treatment: its squares are 1,500m across.

London is studied with the aid of even smaller squares - 300m wide - mainly to improve the accuracy of forecasts for the airspace above the big airports.

And the ambition, when the new supercomputer is up and running, is to operate at an even sharper resolution, down to a scale of 100m.

Will it really make a difference?

The Met Office certainly believes it will. There's huge demand for better forecasting - from the military to the power companies to organisers of big outdoor events.

It could guide Environment Agency teams deploying mobile flood barriers or help the National Grid balancing fluctuations in wind and solar power.

Image copyright Met Office Image caption Original supercomputer installed at the Met Office in Dunstable in 1959

And the prospect of rising global temperatures fuelling new and more dangerous extremes of weather makes accuracy all the more important.

There has been a huge improvement in recent years - every passing decade has seen forecasts reach a whole day further into the future.

A five-day forecast now is as accurate as a one-day forecast 40 years ago.

So will the new computing power continue that advance? Penny Endersby prefers not to make any promises.

"I won't hang my hat on getting another day in the next decade," she says. "But it will make our forecasts more accurate, more timely and more localised."

And the government has calculated what that could mean in hard cash: that for every pound invested, there should be £19 in economic benefit.

And will it help with climate change?

That's the aim, with the digitally-simulated atmosphere also run far into the future to explore the effects of a hotter world.

The effects of the rise of 1C over the past 150 years are still not fully understood, let alone those of bigger increases to come.

It should mean researchers can add more detail to their projections, weaving in factors such as the way nitrogen reacts with the carbon in the air.

And as the UK moves towards its target of net zero emissions by 2050, there'll be a chance to explore different options for how the country uses the land.

For example, what will the effects be of planting new forests or protecting peat bogs or growing more biofuels?

Won't the new supercomputer itself add to carbon emissions?

Like any huge IT installation, it'll certainly need a massive supply of electricity.

That's why the Met Office is inviting the potential providers to come up with low-carbon options.

And that's led to a radical idea. The last 14 Met Office computers have all been housed in the UK - and the new one might not be.

Around half of the processing work - the research devoted to climate change - could be located in countries blessed with easy sources of clean energy.

Iceland with its geothermal sources and Norway with its hydropower are both possibilities.

The offer is only open to countries in the European Economic Area - locating the facility on another continent has been ruled out because of the time lag in using a distant connection.

Invitations to the IT industry to bid for the project are being drawn up and will go out near the end of the year.

And the start date for the new machine will be sometime in late 2022.