US stocks rise in midday trading; Coca-Cola gains after earnings beat analysts' forecasts

The U.S. stock market is edging higher as investors welcome some positive earnings surprises from big companies.

The Standard & Poor's 500 rose 10 points, or 0.5 percent, to 2,057 as of 11:45 a.m. Eastern time Tuesday.

The Dow Jones industrial average gained 77 points, or 0.4 percent, to 17,806. The Nasdaq rose 35 points, or 0.8 percent, to 4,761.

Coca-Cola rose 3 percent after the company reported a better-than-expected quarterly profit. Coke trimmed costs and fetched higher prices for its drinks in North America.

General Motors gained 2.5 percent after an activist investor said he would seek a seat on the company's board and intended to push for a stock buyback.

Energy stocks slumped as the price of oil fell. U.S. crude lost 4 percent to $50.80 a barrel.