Oil prices rose Wednesday as the dollar continued to weaken and stocks tried to hold their ground after Tuesday's big rally. Benchmark crude added 41 cents to settle at $83.23 a barrel on the New York Mercantile Exchange.

Gasoline pump prices climbed as well, to a national average of $2.751 for a gallon of regular, according to AAA, Wright Express and oil Price Information Service. That's up almost two cents from Tuesday and 29 cents higher than a year ago.

Gas has been following oil higher over the past week as stock markets rallied and the dollar fell. Crude traders often look to stock markets as a measure of overall investor sentiment, while oil, priced in dollars, gets cheaper for investors with foreign currencies when the dollar drops. The dollar continued its decline against the euro on Wednesday. The connection between the two currencies has been one of the closest indicators of the direction of oil prices recently.

Stock markets tried to hold on to Tuesday's sizable gains. The Dow Jones Industrial Average finished about 23 points higher. The NASDAQ and the S&P 500 were down a little.

The Energy Information Administration said that crude inventories increased last week by 3.1 million barrels, or 0.9 percent, to 360.9 million barrels. That is 7 percent above year-ago levels. Analysts expected a drop of 1.3 million barrels, according to a survey by Platts, the energy information arm of McGraw-Hill Cos.

Platts senior oil analyst Linda Rafield said the rise in crude supplies was the result of a slowdown in refinery operations, which allowed inventories to build. The EIA report said refineries operated at 83.1 percent of capacity, down 2.7 percent from the previous week.

Although the increase in crude supplies did not seem to faze traders, energy consultants Cameron Hanover noted that the "DOE report and then Friday morning's monthly unemployment numbers could really make or break the course of this market. We seem to have a bull market, although crude still needs to break and settle (preferably twice) above $83.00."

Most analysts expect the jobless data to show the U.S. economy is not creating a significant amount of jobs. "Based on the fundamental data, the market is still amply supplied with crude oil," Commerzbank said in a report, adding that a "majority of OPEC members prefer a price range from $70 to $80."

More tropical storms are brewing in the Caribbean, although current forecasts do not put them on a course to disrupt oil and gas production in the Gulf of Mexico. Natural gas rose 12.2 cents to settle at $3.865 per 1,000 cubic feet.

In other Nymex trading in November contracts, heating oil gained 0.52 cent to settle at $2.3078 a gallon and gasoline added 3.04 cents to settle at $2.1559 a gallon.

In London, Brent crude rose 22 cents to settle at $85.06 a barrel on the ICE Futures exchange.