Weather prediction has reached the point at which forecasters can reliably tell you what direction a storm is going, the general area that will be affected and the timing. But the biggest problem it has is pinpointing and communicating where the storm’s most severe impacts start and stop. This is the edge problem, and Hurricane Matthew demonstrated loud and clear that the current generation of meteorologists must confront it.

When Matthew’s torrential rains engulfed eastern North Carolina and the Virginia Tidewater, many residents — expecting they would escape the worst of the storm — were stunned and dismayed.

The forecast failure was due to both scientific limitations in prediction and inadequate communication.

Computer models, for a time late last week, suggested Matthew would approach the South Carolina coast and then drift back out to sea and even curl back toward Florida — sparing areas to the north.

These models suggested a weak cold front exiting the East Coast would not significantly interact with Matthew. They predicted eastern North Carolina would get a good amount of rain and the Virginia Tidewater a little less, but not a severe flooding situation.

Of course, Matthew was ultimately drawn into the front, which focused a 10- to 15-inch deluge over this region. Computer models started to hint at this consequential shift on Friday, but some meteorologists didn’t have enough confidence in this scenario to sound alarm bells.

“To use a sports analogy, we punted,” wrote Evan Stewart, a meteorologist at the ABC affiliate WVEC which serves southeast Virginia. “And we didn’t do the best job expressing the uncertainty.”

Even in North Carolina, where forecasts better captured the heavy rain threat than in Virginia, so much national media attention was on Florida that the flooding threat there hardly registered.

Part of the problem is that, in hurricane situations, too much emphasis is placed on peak wind speeds (and the hurricane category) — which affect only a tiny area near the center of the storm. Meanwhile, devastating rains and storm surge can extend tens to hundreds of miles away.

So the scientific uncertainty about the storm’s northern edge, the difficulty in the communicating it, and the national focus on wind rather than water, converged to produce an unsatisfactory forecast. It left segments of the public ill-prepared on the storm’s northern periphery.

Meanwhile, many Floridians, who braced for disaster after days of headlines and warnings, were surprised but relieved when their east coast was scraped by 60 to 100 mph winds rather than blasted by the 140 mph gusts that were feared.

Just as Virginia straddled the northern edge of Matthew’s excessive rainfall, Florida lived on the edge of Matthew’s most severe winds. Model forecasts shifted back and forth in their predictions as to whether the storm’s eyewall — containing its most powerful winds, would cross the coast. Ultimately, they remained 30 to 40 miles offshore.

Given the uncertainty in the forecast and how a tiny wobble west in Matthew’s track would’ve wrought devastation on Florida, it was smart for forecasters to loudly communicate the reasonable worst-case scenario and for the public to prepare for it.

But imagine if the science of meteorology can reach the point in which we can pinpoint if and where the eye of a hurricane will make landfall with high confidence. The economic value would be enormous if we could avoid unnecessary evacuations as well as disruptions to business and commerce. This is why investments into the science of meteorology — including improving models, our network of observations, and our physical understanding of the way the atmosphere works — are so important.

Problems in forecasting along the edge of storms and knowing where the worst conditions will begin and end are not unique to hurricanes. Recall the backlash after forecasters in New York City, in February 2015, predicted 24 to 30 inches of snow and, when the storm shifted 60 miles east, only 8 inches fell. Then, in January 2016, the situation happened in reverse — New York City was expecting a modest snowstorm but was pummeled by its biggest on record.

For now, meteorologists are stuck in a situation in which they will have to issue forecasts with imperfect information. This means becoming masters of communicating uncertainty and identifying situations in which the forecast could quickly change for the better or worse. It also means the public needs to have reasonable expectations about forecasts — knowing how small changes can have such large consequences and accepting the responsibility of erring on the side of caution when forecasters say the storm might be bad or it might not.