So what'll it be: Dayton or San Francisco?

Alright, so that's not the most common choice for young people getting ready to start their lives. But it's an instructive question.

Dayton is the most affordable housing market in the United States, according to Trulia chief economist Jed Kolko , while San Francisco is the least affordable place to live in America. But the San Francisco-San Jose area has a better record of social mobility than just about any region in the country, according to Harvard economist Raj Chetty . In other words, a variety of factors make it the best place for young person to work his or her way into the middle class and beyond. As for Dayton and other Ohio cities, they account for four of the 12 worst cities for that same measure of upward mobility.

The Dayton-SF dilemma isn't about Ohio vs. California. It's about a broader dilemma for young workers and, in particular, young couples looking to buy a home, raise children, and achieve the American Dream. The cities with the least affordable housing often have the best social mobility. And the cities with the worst social mobility often have the most affordable housing. When good jobs for the middle class and affordable homes are living in different cities, it represents a slow-motion splintering of the American Dream.

In 2013, Chetty and a phalanx of economists produced a one-of-a-kind study on intergenerational mobility —that is, the odds that low-income households can work their way into the middle class and above. Comparing social mobility by metro area, they discovered that the American Dream is alive in many cities , likeSalt Lake City, Pittsburgh, and San Jose. But it's dying in others, particularly across the southeast and the Rust Belt, where cities are spread out, segregated, and blighted by bad schools and broken families.

But many young people aren't choosing to move to a city because they've heard that a Harvard economist said it was really good for intergenerational mobility. They move for more short-term financial reasons. They want to live affordably. As Kolko explains, "the five most affordable markets are in Ohio, Indiana, and upstate New York... the South is relatively affordable too." *

But now look what happens when you compare Chetty's map of economic opportunity (red is bad) ...