It's impossible not to be fascinated by the fallout over the hole blown in Northern Rock's finances by - apparently - its reliance on money which relied on loans which came from derivatives built on bonds issued against sub-prime loans in the US. (Something like that.)

What's been overlooked is that so much of this was a software-driven problem in the first place. Yet unlike most software issues, this stuff worked perfectly well. It didn't break. It did exactly what it was meant to all the time. The problem for the designers of the software, and the people who used it, was that there was one factor they couldn't program in: the people who'd be affected by its decisions.

When the software said to take the loans, the bankers did. There had to be some knowledge that some sub-prime mortgages would never last to maturity - that's got to be factored in to any risky loan. But what hadn't been foreseen was how people would react on hearing how many of those loans failed. It produced a feedback loop which might be positive or negative. And any engineer will tell you there's a world of difference between systems based on the two.

It's easy to lose sight of how software-driven today's money market is. An interesting post by Paul Kedrosky points out that hedge funds are the new software companies - while what we usually think of as "software" companies are actually marketing arms with a small software house attached.

"Here is a factoid that jumped out at me yesterday, one having to do with the ratio of software developers to non-developers at a major quant fund versus a major software company," he wrote: "Oracle (56,000 empl.): 1 - 8 (one developer for every eight employees); [hedge fund] Renaissance Technologies (178 empl.): 2 -3 (two developers for every three employees)".

Scary, surely. Renaissance Technologies says that it has "a long record of producing superior returns for our clients by adhering to mathematical and statistical methods in the design and execution of our investment programs. We currently have more than 260 employees, and manage over $30bn."

I don't know whether Kedrosky or the website is correct - I suspect the $30bn has shrunk a bit, but it's still looking for programmers with "Bachelor's, Master's, or Ph.D. in Computer Science, Mathematics, or Physics", experience in C++ in Unix, who'd like to earn between $125,000 and $250,000. You do have to go and live in Long Island, though.

The problem with these models, however, is that they cannot cope with the wayward patterns of humans. We fib to people who are selling us the chance to buy a house. The people selling us the chance to buy the house, meanwhile, fib to us about the interest rate. (Many sub-prime loans were on an "Adjustable Rate Mortgage, which leapt in cost after a year or two.) And so worthless loans were created.

Then when the people who are on solid loans, or are creditors - like so many of the Northern Rock customers who queued up - hear about this, and react in a chaotic manner.

It's that unpredictable element that throws the feedback loop completely out - and no amount of programming will be able to forecast it exactly. Even if you could find someone smart enough to want to live in Long Island who could also somehow put the "human element" into your financial forecasts, you'd only be able to get approximations of the truth - rough estimates of how many adjustable-rate mortgages will turn sour, or how people will react to hearing that their mortgage lender is built on uncertain foundations.

Actually, statisticians know a technique for working out what outputs these random inputs can produce: you keep trying the calculation until you see what makes it go mad. It's like predicting the weather - probably it won't rain, but there might be a thunderstorm.

Given the way that the markets have swung from panic to reassurance and back again, and the way they've been playing with the money, the name of this technique is apposite: it's called the Monte Carlo method.