By the looks of the headlines, JPMorgan's (JPM 1.44%) purchase of Washington Mutual and Bear Stearns during the housing market collapse in 2008 didn't work out very well for the bank. But when you dig into the numbers, the acquisitions (legal costs included) that helped the bank achieve scale and earnings power on par with model bank Wells Fargo (WFC -0.26%)were likely a steal.

Why not value the acquisitions?
Wall Street Journal's MoneyBeat dug into the numbers to investigate whether or not JPMorgan's acquisitions during the financial crises were a good deal or not, despite all the surfacing legal fees. But, unfortunately, they stopped short of providing an answer.

To know whether or not Washington Mutual and Bear Stearns were worth the trouble, we need to find the underlying value of the acquisition and compare it to the company's total upfront purchase price and prospective legal costs. Sure, pegging an exact number on the true value of these acquisitions is impossible. And even getting close would be extremely difficult. But even getting just a ballpark, conservative estimate would be helpful for investors -- so why not try?

Valuing WaMu and Stearns
From this point forward, let's think of JPMorgan's acquisitions of Washington Mutual and Bear Stearns as one business called WaMu Stearns.

To get an idea of what WaMu Stearns may be worth, let's take a look at the incremental earnings gained after the acquisition. JPMorgan's annual profits have jumped by about $5 billion since before the recession; but we'll attribute just $3 to $4 billion of this incremental net income to the synergies gained from the acquisition of WaMu Stearns.

But is this incremental net income growing? Probably. JPMorgan's total earnings have averaged growth of 32% annually for the last three years and 3.5% annually over the last five years. So there certainly doesn't seem to be anything dragging on the company's earnings growth.

So, basically, WaMu Stearns could have added about $3 to $4 billion of sustainable, growing net income to the bottom line. If we slap on the industry average price-to-earnings ratio of 14.8, we're looking at a $44 to $59 business. Interestingly, a discounted cash flow valuation estimating annual earnings of $3 billion to grow at about 3% annually would give us a fair value for the business in the same ballpark: $44 billion.

So, was WaMu Stearns worth all the trouble? Probably. JPMorgan paid about $3.4 billion for Washington Mutual and Bear Stearns combined and MoneyBeat estimates related legal fees to land in the ballpark of $19 billion in total.

Did JPMorgan steal Washington Mutual and Bear Stearns at a 50% discount to fair value?

Facts we'll never know
JPMorgan's performance since it purchased Washington Mutual and Bear Stearns has been impressive. Though, we'll likely never know how much of that is attributable to these acquisitions, there's no denying the bank's solid performance since 2008.

Not only does JPMorgan now boast meaningful scale as the biggest bank measured by assets and deposits, but it's even growing both EPS and book value per share faster than Wells Fargo.

JPM EPS Diluted TTM Chart

Even so, likely due to sour headlines that will soon dissolve into the past, JPMorgan trades at just one times book value while Wells Fargo trades at 1.5 times book value. If Wells Fargo isn't overvalued (and I don't think it is), could JP Morgan be undervalued?

Legal costs included (and probably all intangible damage to reputation, too), JPMorgan's purchase of Washington Mutual and Bear Stearns could actually provide upside for JPMorgan stock once the mess is behind us. Mr. Market is known for his short sightedness; could JPMorgan's cheap stock price today end up being a prime example of his irrationality tomorrow?