Tanking is a sin as old as time—or the NBA's lottery system, at least. But the science behind it has become more sophisticated than ever.