dw2

1 January 2012

Planning for optimal ‘flow’ in an uncertain world

Filed under: Agile, books, critical chain, flow, lean, predictability — David Wood @ 1:44 pm

In a world with enormous uncertainty, what is the best planning methodology?

I’ve long been sceptical about elaborate planning – hence my enthusiasm for what’s often called ‘agile‘ and ‘lean‘ development processes.  Indeed, I devoted a significant chunk of my book “Symbian for software leaders – principles of successful smartphone development projects” to comparing and contrasting the “plan is king” approach to an agile approach.

But the passage of time accumulates deeper insight.  Key thinkers in this field now refer to “second generation lean product development”.  Perhaps paramount among these thinkers is the veteran analyst of best practice in new product development, Donald Reinertsen.  I’ve been influenced by his ideas more than once in my career already:

  • In the early 1990s, while I was a software engineering manager at Psion, my boss at the time recommended I read Reinertsen’s “Developing Products in Half the Time“. It was great advice!
  • In the early 200xs, while I was EVP at Symbian, I remember enjoying insights from Reinsertsen’s “Managing the Design Factory“.

I was recently pleased to discover Reinertsen has put pen to paper again.  The result is “The Principles of Product Development Flow: Second Generation Lean Product Development“.

The following Amazon.com review of the latest book, by Maurice Hagar, persuaded me to purchase that book:

This new standard on lean product and software development challenges orthodox thinking on every side and is required reading. It’s fairly technical and not an easy read but well worth the effort.

For the traditionalist, add to cart if you want to learn:

  • Why prioritizing work “on the basis of project profitability measures like return on investment (ROI)” is a mistake
  • Why we should manage queues instead of timelines
  • Why “trying to estimate the amount of work in queue” is a waste of time
  • Why our focus on efficiency, capacity utilization, and preventing and correcting deviations from the plan “are fundamentally wrong”
  • Why “systematic top-down design of the entire system” is risky
  • Why bottom-up estimating is flawed
  • Why reducing defects may be costing us money
  • Why we should “watch the work product, not the worker”
  • Why rewarding specialization is a bad idea
  • Why centralizing control in project management offices and information systems is dangerous
  • Why a bad decision made rapidly “is far better” than the right decision made late and “one of the biggest mistakes a leader could make is to stifle initiative”
  •  Why communicating failures is more important than communicating successes

For the Agilist, add to cart if you want to learn:

  • Why command-and-control is essential to prevent misalignment, local optimization, chaos, even disaster
  • Why traditional conformance to a plan and strong change control and risk management is sometimes preferable to adaptive management
  • Why the economies of scale from centralized, shared resources are sometimes preferable to dedicated teams
  • Why clear roles and boundaries are sometimes preferable to swarming “the way five-year-olds approach soccer”
  • Why predictable behavior is more important than shared values for building trust and teamwork
  • Why even professionals should have synchronized coffee breaks…

Even in the first few pages, I’ve found some cracking good quotes.

Here’s one on economics and “the cost of late changes”:

Our central premise is that we do product development to make money.  This economic goal permits us to use economic thinking and allows us to see many issues with a fresh point of view.  It illuminates the grave problems with the current orthodoxy.

The current orthodoxy does not focus on understanding deeper economic relationships.  Instead, it is, at best, based on observing correlations between pairs of proxy variables.  For example, it observes that late design changes have higher costs than early design changes, and prescribes front-loading problem solving.  This ignores the fact that late changes can also create enormous economic value.  The economic effect of a late change can only be evaluated by considering its complete economic impact.

And on “worship of conformance”:

In addition to deeply misunderstanding variability, today’s product developers have deep-rooted misconceptions on how to react to this variability.  They believe that they should always strive to make actual performance conform to the original plan.  They assume that the benefit of correcting a deviation from the plan will always exceed the cost of doing so.  This places completely unwarranted trust in the original plan, and it blocks companies from exploiting emergent opportunities.  Such behaviour makes no economic sense.

We live in an uncertain world.  We must recognise that our original plan was based on noisy data, viewed from a long time-horizon…  Emergent information completely changes the economics of our original choice.  In such cases, blindly insisting on conformance to the original plan destroys economic value.

To manage product development effectively, we must recognise that valuable new information is constantly arriving throughout the development cycle.  Rather than remaining frozen in time, locked to the original plan, we must learn to make good economic choices using this emerging information.

Conformance to the original plan has become another obstacle blocking our ability to make good economic choices.  Once again, we have a case of a proxy variable, conformance, obscuring the real issue, which is making good economic decisions…

Next, on flow control and the sequencing of tasks:

We are interested in finding economically optimum sequences for tasks.  Current practices use fairly crude approaches to sequencing.

For example, it suggests that if subsystem B depends on subsystem A, it would be better to sequence the design of A first.  This logic optimises efficiency as a proxy variable.  When we consider overall economics, as we do in this book, we often reach different conclusions.  For example, it may be better to develop both A and B simultaneously, despite the risk of inefficient rework, because parallel development can save cycle time.

In this book, our model for flow control will not be manufacturing systems, since these systems primarily deal with predictable and homogeneous flows.  Instead, we will look at lessons that can be learned from telecommunications networks and computer operating systems.  Both of these domains have decades of experience dealing with non-homogeneous and highly variable flows.

Finally, on fast feedback:

Developers rely on feedback to influence subsequent choices.  Or, at least, they should.  Unfortunately, our current orthodoxy views feedback as an element of an undesirable rework loop.  It asserts that we should prevent the need for rework by having engineers design things right the first time.

We will present a radically different view, suggesting that feedback is what permits us to operate our product development process effectively in a very noisy environment.  Feedback allows us to efficiently adapt to unpredictability.

To be clear, Reinertsen’s book doesn’t just point out issues with what he calls “current practice” or “orthodoxy”.  He also points out shortcomings in various first generation lean models, such as Eliyahu Goldratt’s “Critical Chain” methodology (as described in Goldratt’s “Theory of Constraints”), and Kanban.  For example, in discussing the minimisation of Work In Process (WIP) inventory, Reinertsen says the following:

WIP constraints are a powerful way to gain control over cycle time in the presence of variability.  This is particularly important where variability accumulates, such as in product development…

We will discuss two common methods of constraining WIP: the kanban system and Goldratt’s Theory of Constraints.  These methods are relatively static.  We will also examine how telecommunications networks use WIP constraints in a much more dynamic way.  Once again, telecommunications networks are interesting to us as product developers, because they deal successfully with inherently high variability.

Hopefully that’s a good set of tasters for what will follow!

5 April 2010

The ascent of money: huge opportunities and huge risks

Filed under: books, Economics, predictability — David Wood @ 9:36 pm

The turning point of the American Civil War.  The defeat of Napoleon.  The lead-up to the French Revolution.  The decline of Imperial Spain.  These chapters of history all have intriguing back stories – according to Harvard professor Niall Ferguson, in his book “The Ascent of Money: A Financial History of the World“.

The back stories, each time, refer to the strengths and weakness of evolving financial systems.

Appreciating these back stories isn’t just an intellectual curiosity.  It provides rich context for the view that financial systems are sophisticated and complex entities that deserve much wider understanding.  Without this understanding, it’s all too easy for people to hold one or other overly-simplistic understanding of financial systems, such as:

  • Financial systems are all fundamentally flawed;
  • Financial systems are all fundamentally beneficial;
  • There are “sure thing” investments which people can learn about;
  • Financial systems should be picked apart – the world would be better off without them;
  • Markets are inherently insane;
  • Markets are inherently sane;
  • Bankers (and their ilk) deserve our scorn;
  • Bankers (and their ilk) deserve our deep gratitude.

As the book progresses, Ferguson sweeps forwards and backwards throughout history, gradually building up a fuller picture of evolving financial systems:

  • The banking system;
  • Government bonds;
  • Stock markets;
  • Insurance and securities;
  • The housing market;
  • Hedge funds;
  • Globalisation;
  • The growing role of China in financial systems.

Like me, Ferguson was born in Scotland.  I was struck by the number of Scots-born heroes and villains the book introduces, including an infamous Glaswegian loan shark, the creators of the first true insurance company, officers of the companies involved in the Anglo-China “Opium Wars”, and Andrew Law – instigator in France of one of history’s first great stock market bubbles.  Of course, many non-Scots have starring roles too – including Shakespeare’s Shylock, the Medicis, the Rothschilds, George Soros, the managers of Enron, Milton Friedman, and John Maynard Keynes.

Time and again, Ferguson highlights lessons for the present day.  Yes, new financial systems can liberate great amounts of creativity.  Innovation in financial systems can provide significant benefits for society.  But, at the same time, financial systems can be mis-managed, with dreadful consequences.  One major contributory cause of mis-managing these systems is when people lack a proper historical perspective – for example, when the experience of leading financiers is just of times of growth, rather than times of savage decline.

Among many fascinating episodes covered in the book, I found two to be particularly chilling:

  • The astonishing (in retrospect) over-confidence of observers in the period leading up to the First World War, that any such war could not possibly happen;
  • The astonishing (in retrospect) over-confidence of the managers of the Long Term Capital Management (LTCM) hedge fund, that their fund could not possibly fail.

Veteran journalist Hamish McRae describes some of the pre-WWI thinking in his review of Ferguson’s book in The Independent:

The 19th-century globalisation ended with the catastrophe of the First World War. It is really scary to realise how unaware people were of the fragility of those times. In 1910, the British journalist Norman Angell published The Great Illusion, in which he argued that war between the great powers had become an economic impossibility because of “the delicate interdependence of international finance”.

In spring 1914 an international commission reported on the Balkan Wars of 1912-13. The British member of the commission, Henry Noel Brailsford, wrote: “In Europe the epoch of conquest is over and save in the Balkans perhaps on the fringes of the Austrian and Russian empires, it is as certain as anything in politics that the frontiers of our national states are finally drawn. My own belief is that there will be no more war among the six powers.”

And Ferguson re-tells the story of LTCM in his online article “Wall Street Lays Another Egg” (which also covers many of the other themes from his book):

…how exactly do you price a derivative? What precisely is an option worth? The answers to those questions required a revolution in financial theory. From an academic point of view, what this revolution achieved was highly impressive. But the events of the 1990s, as the rise of quantitative finance replaced preppies with quants (quantitative analysts) all along Wall Street, revealed a new truth: those whom the gods want to destroy they first teach math.

Working closely with Fischer Black, of the consulting firm Arthur D. Little, M.I.T.’s Myron Scholes invented a groundbreaking new theory of pricing options, to which his colleague Robert Merton also contributed. (Scholes and Merton would share the 1997 Nobel Prize in economics.) They reasoned that a call option’s value depended on six variables: the current market price of the stock (S), the agreed future price at which the stock could be bought (L), the time until the expiration date of the option (t), the risk-free rate of return in the economy as a whole (r), the probability that the option will be exercised (N), and—the crucial variable—the expected volatility of the stock, i.e., the likely fluctuations of its price between the time of purchase and the expiration date (s). With wonderful mathematical wizardry, the quants reduced the price of a call option to this formula (the Black-Scholes formula).

Feeling a bit baffled? Can’t follow the algebra? That was just fine by the quants. To make money from this magic formula, they needed markets to be full of people who didn’t have a clue about how to price options but relied instead on their (seldom accurate) gut instincts. They also needed a great deal of computing power, a force which had been transforming the financial markets since the early 1980s. Their final requirement was a partner with some market savvy in order to make the leap from the faculty club to the trading floor. Black, who would soon be struck down by cancer, could not be that partner. But John Meriwether could. The former head of the bond-arbitrage group at Salomon Brothers, Meriwether had made his first fortune in the wake of the S&L meltdown of the late 1980s. The hedge fund he created with Scholes and Merton in 1994 was called Long-Term Capital Management.

In its brief, four-year life, Long-Term was the brightest star in the hedge-fund firmament, generating mind-blowing returns for its elite club of investors and even more money for its founders. Needless to say, the firm did more than just trade options, though selling puts on the stock market became such a big part of its business that it was nicknamed “the central bank of volatility” by banks buying insurance against a big stock-market sell-off. In fact, the partners were simultaneously pursuing multiple trading strategies, about 100 of them, with a total of 7,600 positions. This conformed to a second key rule of the new mathematical finance: the virtue of diversification, a principle that had been formalized by Harry M. Markowitz, of the Rand Corporation. Diversification was all about having a multitude of uncorrelated positions. One might go wrong, or even two. But thousands just could not go wrong simultaneously.

The mathematics were reassuring. According to the firm’s “Value at Risk” models, it would take a 10-s (in other words, 10-standard-deviation) event to cause the firm to lose all its capital in a single year. But the probability of such an event, according to the quants, was 1 in 10^24—or effectively zero. Indeed, the models said the most Long-Term was likely to lose in a single day was $45 million. For that reason, the partners felt no compunction about leveraging their trades. At the end of August 1997, the fund’s capital was $6.7 billion, but the debt-financed assets on its balance sheet amounted to $126 billion, a ratio of assets to capital of 19 to 1.

There is no need to rehearse here the story of Long-Term’s downfall, which was precipitated by a Russian debt default. Suffice it to say that on Friday, August 21, 1998, the firm lost $550 million—15 percent of its entire capital, and vastly more than its mathematical models had said was possible. The key point is to appreciate why the quants were so wrong.

The problem lay with the assumptions that underlie so much of mathematical finance. In order to construct their models, the quants had to postulate a planet where the inhabitants were omniscient and perfectly rational; where they instantly absorbed all new information and used it to maximize profits; where they never stopped trading; where markets were continuous, frictionless, and completely liquid. Financial markets on this planet followed a “random walk,” meaning that each day’s prices were quite unrelated to the previous day’s, but reflected no more and no less than all the relevant information currently available. The returns on this planet’s stock market were normally distributed along the bell curve, with most years clustered closely around the mean, and two-thirds of them within one standard deviation of the mean. On such a planet, a “six standard deviation” sell-off would be about as common as a person shorter than one foot in our world. It would happen only once in four million years of trading.

But Long-Term was not located on Planet Finance. It was based in Greenwich, Connecticut, on Planet Earth, a place inhabited by emotional human beings, always capable of flipping suddenly and en masse from greed to fear. In the case of Long-Term, the herding problem was acute, because many other firms had begun trying to copy Long-Term’s strategies in the hope of replicating its stellar performance. When things began to go wrong, there was a truly bovine stampede for the exits. The result was a massive, synchronized downturn in virtually all asset markets. Diversification was no defense in such a crisis. As one leading London hedge-fund manager later put it to Meriwether, “John, you were the correlation.”

There was, however, another reason why Long-Term failed. The quants’ Value at Risk models had implied that the loss the firm suffered in August 1998 was so unlikely that it ought never to have happened in the entire life of the universe. But that was because the models were working with just five years of data. If they had gone back even 11 years, they would have captured the 1987 stock-market crash. If they had gone back 80 years they would have captured the last great Russian default, after the 1917 revolution. Meriwether himself, born in 1947, ruefully observed, “If I had lived through the Depression, I would have been in a better position to understand events.” To put it bluntly, the Nobel Prize winners knew plenty of mathematics but not enough history.

These episodes should remind us of the fragility of our current situation.  Indeed, as one of many potential future scenarios, Ferguson candidly discusses the prospects for a serious breakdown in relations between China and the west, akin to the breakdown of relations that precipitated the First World War.

In summary: I recommend this book, not only because it is full of intriguing anecdotes, but because it will help to raise awareness of the complex impacts of financial systems.  It will help boost general literacy about all aspects of money – and should, therefore, help us to be more effective in how collectively manage financial innovation.

Note: There are two editions of this book: one released in 2008, and one released in 2009.  The latter has a fuller account of the recent global financial crisis, and for that reason, is the better one to read.

1 October 2008

The student syndrome

Filed under: Agile, critical chain, Essay contest, predictability — David Wood @ 5:13 pm

Entries for Symbian’s 2008 Student Essay Contest have just closed. The deadline for submission of entries was midnight (GMT) on 30 September 2008.

The contest has been advertised since June. What proportion of all the entries do you suppose were submitted in the final six hours before the deadline expired? (Bear in mind that, out of a total competition duration of more than three months, six hours is about 1/400 of the available time.)

I’ll give the answer at the end of this article. It surprised me – though I ought to have anticipated the outcome. After all, for many years I’ve been telling people about “The Student Syndrome”.

I became familiar with the concept of the student syndrome some years ago, while reading Eliyahu Goldratt’s fine business-oriented novel “The Critical Chain“:

Like all Goldratt’s novels, Critical Chain mixes human interest with some intriguing ways of analysing business-critical topics. The ideas in these books had a big influence on the evolution of my own views about how to incorporate responsiveness and agility into large software projects where customers are heavily reliant on the software being delivered at pre-agreed dates.

Here’s what I said on the topic of “variable task estimates” in the chapter “Managing plans and change” in my own 2005 book “Symbian for software leaders“:


A smartphone project plan is made up from a large number of estimates for how long it will take to complete individual tasks. If the task involves novel work, or novel circumstances, or a novel integration environment, you can have a wide range of estimates for the length of time required.

It’s similar to estimating how long you will take to complete an unfamiliar journey in a busy city with potentially unreliable transport infrastructure. Let’s say that, if you are lucky, you might complete the journey in just 20 minutes. Perhaps 30 minutes is the most likely time duration. But in view of potential traffic hold-ups or train delays, you could take as long as one hour, or (in case of underground train derailments) even two hours or longer. So there’s a range of estimates, with the distribution curve having a long tail on the right hand side: there’s a non-negligible probability that the task will take at least twice as long as the individual most likely outcome.

It’s often the same with estimating the length of time for a task within a project plan.

Now imagine that the company culture puts a strong emphasis on fulfilling commitments, and never missing deadlines. If developers are asked to state a length of time in which they have (say) 95% confidence they will finish the task, they are likely to give an answer that is at least twice as long as the individual most likely outcome. They do so because:


  • Customers may make large financial decisions dependent on the estimate – on the assumption that it will be met;
  • Bonus payments to developers may depend on hitting the target;
  • The developers have to plan on unforeseen task interference (and other changes);
  • Any estimate the developers provide may get squashed down by aggressive senior managers (so they’d better pad their estimate in advance, making it even longer).

Ironically, even though such estimates are designed to be fulfilled around 95% of the time, they typically end up being fulfilled only around 50% of the time. This fact deserves some careful reflection. Even though the estimates were generous, it seems (at first sight) that they were not generous enough. In fact, here’s what happens:

  • In fulfilment of “Parkinson’s Law”, tasks expand to fill the available time. Developers can always find ways to improve and optimise their solutions – adding extra test cases, considering alternative algorithms and generalisations, and so forth;
  • Because there’s a perception (in at least the beginning of the time period) of there being ample time, developers often put off becoming fully involved in their tasks. This is sometimes called “the student syndrome”, from the observation that most students do most of the preparation for an exam in the time period just before the exam. The time lost in this way can never be regained;
  • Because there’s a perception of there being ample time, developers can become involved in other activities at the same time. However, these other activities often last longer than intended. So the developer ends up multi-tasking between two (or more) activities. But multi-tasking involves significant task setup time – time to become deeply involved in each different task (time to enter “flow mode” for the task). So yet more time is wasted;
  • Critically, even when a task is ready to finish earlier than expected, the project plan can rarely take advantage of this fact. The people who were scheduled for the next task probably aren’t ready to start it earlier than anticipated. So an early finish by one task rarely translates into an early start by the next task. On the other hand, a late finish by one task inevitably means a late start for the next start. This task asymmetry drives the whole schedule later.

In conclusion, in a company whose culture puts a strong emphasis upon fulfilling commitments and never missing deadlines, the agreed schedules are built from estimations up to twice as long as the individually most likely outcome, and even so, they often miss even these extended deadlines…

This line of analysis is one I’ve run through scores of times, in discussions with people, in the last four or five years. It feeds into the argument that the best way to ensure customer satisfaction and predictable delivery, is, counter-intuitively, to focus more on software quality, interim customer feedback, agile project management, self-motivated teams, and general principles of excellence in software development, than on schedule management itself.

It’s in line with what Steve McConnell says,

  • IBM discovered 20 years ago that projects that focused on attaining the shortest schedules had high frequencies of cost and schedule overruns;
  • Projects that focused on achieving high quality had the best schedules and the highest productivities.

Symbian’s experience over many years bears out the same conclusion. The more we’ve focused on achieving high quality, the better we’ve become with both schedule management and internal developer productivity.

As for the results of the student syndrome applied to the Symbian Essay Contest:

  • 54% of the essays submitted to the competition were received in the final six hours (approximately the final 1/400 of the time available)
  • Indeed, 16% of the essays submitted were received in the final 60 minutes.

That’s an impressively asymmetric distribution! (It also means that the competition judges will have to work harder than they had been expecting, right up to the penultimate day of the contest…)

Theme: Silver is the New Black. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.

Join 36 other followers