NEW YORK — Warren Buffett has made bets on railroads before, but now he's all in. The billionaire investor's Berkshire Hathaway Inc. on Tuesday agreed to buy Burlington Northern Santa Fe Corp., making a $34 billion bet on the future of the U.S. economy.

Burlington Northern, the nation's second-largest railroad, is the biggest hauler of food products like corn, and coal for electricity, making it an indicator of the country's economic health. The railroad also ships a large amount of consumer goods — including items imported from Asia — from big Western ports like Los Angeles and Seattle.

Analysts say Buffett is planting both feet in an industry that is poised to grow as the economy gets back on solid ground. It would be the biggest acquisition ever for Berkshire Hathaway Inc.

Berkshire Hathaway already owns about 22 percent of Burlington Northern, and will pay $100 a share in cash and stock for the rest of the company. That was 31.5 percent premium on Burlington Northern's Monday closing price. The stock shot up over 28 percent Tuesday, to $97.66 in afternoon trading.

Shareholders have the option to convert their stock for a cash payment of $100 per share or receive Berkshire Class A or Class B common stock. Up to 60 percent of the deal is cash and 40 percent is in stock.

"Berkshire's $34 billion investment in BNSF is a huge bet on that company, CEO Matt Rose and his team, and the railroad industry," Buffett said in a statement.

"Most important of all, however, it's an all-in wager on the economic future of the United States. I love these bets," he said.

Berkshire's board also approved a 50-for-1 split of its Class B common stock for holders of smaller amounts of Burlington shares who opt for a share exchange instead of cash. The Class B shares rose $67.20, or 2.1 percent, to $3332.23 on Tuesday.

Berkshire owns stock in two other major railroads — about 1 percent of the outstanding shares of Union Pacific Corp. and less than 1 percent of Norfolk Southern Corp., as of June 30. Buffett started investing in railroads in 2007, but has said he realized a few years late that railroads had become an appealing investment.

He thinks railroads are a key economic indicator because of the amount of retail and manufactured goods they haul across the country. "They do it in a cost-effective way and extraordinarily environmentally friendly way," he told CNBC. "I basically believe this country will prosper and you'll have more people moving more goods 10 and 20 and 30 years from now, and the rails should benefit."

Last week Burlington Northern reported third-quarter profit dropped 30 percent from a year earlier. Burlington Northern made almost a third of its money in the last quarter from shipments of consumer products from the West to major hubs like St. Louis, Kansas City and Chicago.

It's next largest segment was coal, at 27 percent of revenue, followed by industrial products — like farm equipment, lumber and chemicals — at 21 percent. The agricultural products segment — 20 percent of its total revenue — includes major crops like corn, wheat and soybeans — much of that exported to China.

Burlington Northern serves more of the nation's major grain-producing regions than any other railroad.

Burlington has been one of the least optimistic among major railroads about the pace of economic recovery. CEO Matt Rose said consumers will be the driver of any improvement in the economy, but no one is buying yet. And coal shipments to power plants have fallen off sharply because of lower electricity demand. Burlington Northern hauls enough coal to power one out of every 10 homes in the U.S.

The coal hauled by Burlington Northern is mined from places like the Powder River Basin in Wyoming and Montana. It's lower in sulfur than the coal found in the eastern U.S., so its less polluting and in greater demand now that stricter emissions standards are being imposed on coal plants.

Berkshire owns major utilities that rely on coal through its MidAmerican Energy Holdings Co.

Analysts say Buffett is looking for an investment that will reap rewards for many years into the future, and isn't so concerned about immediate gains.

"(Buffett is) buying at the trough — things aren't going to get much worse. He's getting in at a good time," said Art Hatfield, an analyst with investment firm Morgan Keegan.

Berkshire's biggest acquisition before BNSF was the $16 billion stock purchase of reinsurance giant General Re announced in 1998.

Hatfield said he believes Buffett went for Burlington Northern in part because of its good management team, an important aspect in any of the billionaire's deals.

Hatfield also said that Burlington Northern has been more progressive than its peers in developing new technology, making it more profitable. Major railroads have been able to slash costs during the recession by cutting jobs, parking railcars, improving train speeds and other moves that improved efficiency.

Railroads are much more energy-efficient than trucks because they use much less fuel. An average Burlington Northern train hauls as much freight as 280 trucks. Rails are also favored by some shippers because they can carry things that can't travel on highways, like hazardous chemicals.

Burlington Northern cut its total expenses by nearly a third in the last quarter. Labor costs fell by 17 percent from a year ago. Burlington Northern has drastically reduced its employees since 2007, as the recession caused freight demand to plummet. The company had about 3,700 fewer workers at the end of the third quarter than at the same time a year ago.

Copyright 2009 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.