I usually prefer dividends to stock buybacks. You can bank dividends -- or, better still, reinvest them, creating nine-figure fortunes over the course of decades.

But there are times when a buyback is not only appropriate, but also smart. This is one of those times for Stock Advisor selection Biogen Idec (NASDAQ:BIIB).

Biogen, a major drugmaker, announced late Tuesday that it will spend as much as $3 billion in a Dutch auction to repurchase and retire as much as 16% of its outstanding shares. Investors may opt to tender stock for between $47 and $53 a stub. 

Funding will come through a combination of $1.5 billion in cash (Biogen has $2.8 billion cash and investments on hand now) and $1.5 billion in new debt.

I don't usually like to see firms go into hock to repurchase equity. Here, it makes sense for two reasons. First, there's free cash flow. Biogen produces plenty of it.

Free Cash Flow

TTM

2006

2005

2004

Actual (in millions)

$777.2

$643.0

$571.1

$367.0

Source: Capital IQ, a division of Standard & Poor's.

If history serves, it should take Biogen no more than two years to pay off the $1.5 billion it expects to owe. That's what a pair of blockbuster drugs -- Rituxan, which is sold in tandem with Genentech (NYSE:DNA), and Avonex -- can do.

Second, there's valuation. When David Gardner picked Biogen for Stock Advisor, the company was worth about $22 billion. Today, despite putting up good numbers in each of the past three quarters, Biogen is worth just $18 billion. (Amgen (NASDAQ:AMGN), for reference, is a $64 billion company.)

Now, either David is crazy, or Biogen is trading at a discount.

If he's right -- and my experience suggests that he is -- then management is snapping up shares at exactly the right moment, when they're undervalued and able to earn a lot more than the 5% Biogen's cash would earn sitting in a bank vault.

Or, in simple English: It's a chance for management to deliver huge returns to long-suffering shareholders. I'm glad the company's doing it.

Diagnose your portfolio with related Foolishness:

Biogen Idec is a Stock Advisor pick. Get 30 days of free access to the entire portfolio, which is beating the market by nearly 38%.

Fool contributor Tim Beyers, ranked 4,160 out of more than 29,500 rated players in Motley Fool CAPS, didn't own shares in any of the companies mentioned in this article at the time of publication. Tim's portfolio holdings can be found at his Fool profile. His thoughts on Foolishness and investing may be found in his blog. The Motley Fool's disclosure policy enjoys spring showers more than spring flowers.