Kassandra Bremont, comptroller for a chain of Maryland gasoline stations, fired up her computer in Catonsville and stared at the screen in disbelief as the latest gas prices came into focus. "Oh my God!" she yelled, rubbing her eyes. "In all my years, I've never seen the likes of this."

It was a sentiment shared across the nation late last week as gas prices spiked in the aftermath of Hurricane Katrina. Unhappy motorists lining up at the pump muttered darkly about "price gouging," words that also passed the lips of President Bush.

Is it gouging or is it volatility?

Without doubt, the pain is acute. Gas lines have materialized across the nation. Many stations have run out. Others raised prices defensively in a deliberate, but not entirely successful, effort to slow panic buying. Prices suddenly jumped 5 cents, 30 cents, 50 cents a gallon, and in a few places fell by just as much.

Many of last week's events were classic signs of an unstable market, economists said, one that has sustained an unexpected shock and is still plagued by shaky information. Buyers and sellers simply don't know what an acceptable price is right now for a gallon of gas.

Katrina slowed oil production, knocked out oil refineries and cut the nation's gasoline supply, but by how much, and for how long? Demand is suddenly jumping because people are panicking and topping off their tanks, but how long will that go on? As global traders respond to the huge U.S. price spikes, the spigots are opening on new sources of gas, but how long will the fuel take to get here?

"I think what's going on is that people don't know where the new equilibrium will be reached," said Lester Lave, an energy economist at Carnegie Mellon University in Pittsburgh. "So they are fishing around and struggling."

Prices approached $6 a gallon last week, briefly, outside Atlanta. That station owner was quickly hounded into submission, and Georgia Gov. Sonny Purdue (R) pledged to invoke price-gouging laws against any owner who goes overboard. Gov. Mark R. Warner (D) declared a state of emergency in Virginia so his government can do the same. Prices for regular gas approached $3 a gallon nearly everywhere and topped that price in many places, including dozens of stations in the Washington region.

Some motorists pumping gas late in the week said they suspected gouging, while others said station owners were probably just passing on cost increases from their wholesalers. But even the kindliest confessed to being mystified by this week's rapid price jumps.

"I don't know who is making money off of this any more," Dante Smith, 24, said as he pumped $3.19-a-gallon gas into his Elantra in Baltimore. "All I know is $15 just gets me a quarter tank. That's it."

Many states prone to hurricanes or earthquakes, including Virginia, have gouging laws that take effect after the governor declares a state of emergency because of natural disaster. These laws attempt to specify reasonable prices for essential goods -- for example, by limiting increases to 10 percent above the prices prevailing before disaster struck. But lawyers say enforcement of such statutes is rare and difficult even in disaster zones, they seldom apply elsewhere, and there's little precedent for applying them to the national market for gasoline.

Most people interviewed at gas pumps this week wanted to know what the station owner last paid for gas, figuring that amount, plus a reasonable markup, was a fair price for the station to be charging. But a half-dozen economists interviewed on the subject said that's not necessarily how things work.

The price of an item in the marketplace is typically set by the balance between supply and demand. Buyers and sellers, each pursuing their own interests, eventually converge on what economists call a "market-clearing price." At retail, though, there's rarely just one price for an item, and that's especially true of gasoline. Usually there's a range of prices that tend to cluster around an average.

These subtle price variations may be affected by a store's particular product mix -- some huge stations sell gas virtually at cost to draw in customer traffic, then make their money charging high prices in their mini-mart.

Other stations, especially those associated with big oil companies, have longer-term supply contracts for gasoline that lock them into slightly higher prices in normal times, but allow them to temporarily undercut independent competitors buying gasoline on the spot market when wholesale prices are rising.

The bottom line, economists said, is that gas stations have a certain amount of flexibility in how they respond to a changing marketplace, but it's limited in ways that depend on the specifics of how each station is set up.

As they absorbed the impact of this week's events and the news that gas supplies may be disrupted for weeks, station managers struggled to figure out what to do. For some, it was pretty straightforward.

At the Executive Getty on Montrose Road in Rockville, general manager Dave Healander said he gets a gas delivery every couple of days. He figures his price per gallon, then tacks on 5 or 6 cents for operating costs and profit. He took a delivery at $3.25 a gallon last week and set his price at $3.31, case closed. "When I get my load, that's how much I know it's going to cost," he said.

But that doesn't work for every station owner, especially when panicked customers are lining up. The gasoline distribution system isn't set up to handle frantic buying. "It's like a bank," said Kevin F. Forbes, chairman of business and economics at the Catholic University of America, in Washington. "If everyone went down to the bank and took out their deposits, the bank would collapse."

Last week, some owners were experimenting with high prices to see if the market would pay them. Laurence S. Moss, an economist at Babson College in Wellesley, Mass., said they should be allowed to do so, since sellers who get out of line should quickly find their business drying up. He allowed, though, that perhaps some sellers might not be "pure of heart and inspired by Biblical verse."

Bremont, the gas-station comptroller with an office in Catonsville, owns one station and helps to manage prices for 16 others. Her challenge on Friday, after wholesale prices spiked 35 cents a gallon overnight, was to set retail prices low enough to be competitive but high enough to discourage customers from lining up and sucking every station dry, as they did at four stations on Wednesday. Late Friday, she had settled on prices ranging from $3.59 to $3.98. The latter price, at a station near Ravens Stadium in Baltimore, was "a controlled effort to calm people down" by discouraging lines, she said.

"Raising the prices is better than running out of gas," Bremont said. "The customer's perception is if you run out of gas, there's something really wrong with the station."

Most people understand that higher prices limit a scarce resource to those who really need it and can pay. There's a second role for rising prices. "The other part of this is calling forth more supply," Lave said.

Even as gas prices spiked last week in the United States, the wheels of global capitalism began to turn.

European drivers, it seems, have been switching to diesel for several years, and many European refineries have spare capacity to produce gasoline. Realizing how much profit they might earn in the volatile U.S. market, gas producers rushed throughout the week to book as many as 25 vast tankers, driving some ocean-freight rates up more than 50 percent in days. "This really is a scramble," said Claire Grierson, an analyst with a London freight brokerage.

Well before September is out, those tankers are expected to be chugging toward U.S. ports, loaded with millions of gallons of gasoline.

"Right now our wholesale prices are so high we're going to be sucking in gasoline from everywhere," said Forbes, the Catholic University economist. "Which is what we want," supply increasing to meet demand.

Staff writer Michael Rosenwald contributed to this report.