A technician takes a sample of crude oil from a well operated by Venezuela's state-owned oil company in Morichal, Venezuela. Ramon Sahmkow | AFP | Getty Images

Venezuela has the world's largest proven oil reserves—more than 297 billion barrels. But despite the tremendous windfall a resource like that should provide, Venezuela's economy is in free fall. Read More Creating inflation is easy. Just look at Venezuela

Why is Venezuela's economy such a wreck? It's a problem with much deeper and broader roots than just the turmoil in oil markets. Here's the answer in five charts:

Oil production is declining. The chart above, part of a presentation from professor Francisco Monaldi at Harvard University's Kennedy School of Government, shows that back in the '90s, Venezuela was producing nearly 3.5 million barrels of oil per day. But then Hugo Chavez came to power in 1999, and he curtailed investment in the energy sector, using the money instead for social programs. Read MoreWhy Cuba is Venezuela's biggest loser

That's led to a sharp decline in production, to only 2.6 million barrels per day. Even worse, Venezuela doesn't get paid for almost half of the oil (1.2 million barrels) it produces because it's given away to places like Cuba, or supplied to the domestic market at below-market prices.

The government, previously under Chavez and now Nicolas Maduro, spends far more than just the money it gets from oil revenue. Government spending as a percentage of GDP is the highest in all of Latin America, and rose substantially from 2011 to 2012.

With all that spending, despite high oil prices, Venezuela incurred massive deficits. This chart shows that even as oil hit record prices, providing a windfall in revenue, the country managed to have a deficit of more than 17 percent of GDP in 2012.



In order to spend more than it earned, Venezuela has borrowed money—lots of it. Foreign stands at $106 billion.