Friday, April 16, 2010

Organic Software is not Good for You

Imagine a tree growing in your garden; visualise the branches of the tree, the way they grow in many different directions. Consider the height of the tree and how it looks silhouetted against the clouds.  Now imagine building a tree house in that tree. In your mind, your tree suddenly has branches that are thick enough to support the house; it has a branch that forks out of the trunk where you can conveniently place it and the tree is tall enough for the house to need a rope ladder. Lucky for your tree house project, your tree was constructed in your mind and it could undergo significant, easy change in order for the project to proceed.

In the real world it’s not that simple. Things need to be planned. You can’t build a tree house in any tree.
Now imagine that the tree house is a new requirement in an application and the tree is the original piece of software. If the tree wasn’t ‘designed’ for a tree house, then you’ve got a problem on your hands. There are many ‘tree houses’ that have been built in pine trees; supported only by gum poles and rope. So, what’s the point? Systems that have grown organically out of a single requirement often fail due to the original system not being built for the task it has to now execute.

A Good Design is Important.

There are many aspects to software design and many varying methodologies. My intention is not to discuss the pros and cons of these varying methods or to recommend a specific one. It is just to emphasise the important part of design is not which methodology you choose; just that you choose one.

You might be surprised to find that a great many applications start their life has a collection of "hacks". By hacks, I mean pieces of code that have been forced to work together using creative methods and techniques. Interestingly, the developers who write the code are usually not bad programmers; on the contrary, they are normally exceptionally talented. The problem is, without adequate planning, decisions made at the beginning of the project often have unforeseen consequences. These can include an unwieldy UI, poor performance, over-sized data files, overly complex processing and un-maintainable code.

An answer to these unforeseen consequences is, as you may have guessed, to create a good design. A good design needs to take all the facets of the system into consideration; these facets include (but are not limited to)

  • User Requirements
  • Information and Process Flows
  • User Interface prototypes
  • Internal Data Structures
  • External Data Dependencies
  • Location of the user and the delivery method



Why then do many developers only look at a small part of the design process (if at all)? Most of the time, they are of the belief that they will be able to deliver the application faster without going through the design phase.

The problem is that they are right; well at least for the first few phases of the project. Most good programmers can create a basic system without spending much time thinking about it holistically. The easily understood requirements can be put together in a relatively short amount of time and non-technical stakeholders will perceive that the project is progressing well. The problems start as the application grows. Assumptions that were made in ignorance at the beginning of the project hamper progress, and workarounds are put in place. Later in the project, these workarounds further hamper progress. It is a downward spiral into the abyss of an un-maintainable system. The old adage that the first 80% of the system takes 20% of the time to complete and the last 20% of the system takes 80% of the time to complete applies.

So just remember, it’s easy to build a pine tree; but almost impossible to put a tree house in a pine tree.

Tuesday, March 30, 2010

How can we solve the power problem?

I've been thinking about the electricity problem, and as far as I can tell the situation that we find ourselves in boils down to two basic things:
  1. Eskom don’t have enough capital to expand capacity, and
  2. Consumers are using electricity wastefully
I think I’ve come up with a solution that addresses both problems; It involves solar geysers – but a better plan than the current rebate system.
  1. Scrap the current solar geyser rebate system; it doesn’t work*
  2. Allow Eskom to increase the tariff per kw/h, but
  3. If you have a solar geyser you get a reduced tariff per kw/h
This will encourage business and home owners to go out and buy solar geysers because they want to benefit the lower electricity tariff. It will also reduce the strain on the existing grid because less people will be heating water using the power grid. The reduced strain on the grid will reduce the pressure on Eskom to rapidly expand the power grid which will reduce the cost.

A self reinforcing loop.

The selling point could be that if you do get a solar geyser, not only will you be using less electricity, the amount you pay for the running your other appliances will be less. A double whammy reduction on your bill.

If we believe the stats that a solar geyser reduces your electric bill by 40-50% then this plan could work.

* I recently had a solar geyser installed by a registered supplier (Teljoy solar). The way it seems to work is that all the suppliers quote you on the actual geyser and the installation. What they don’t tell you is that if you want to get the rebate, you have to have a Eskom approved electrician come and install an Eskom approved timer. The cost of this comes in just over the rebate; so it actually costs you a little extra to qualify for the rebate. (Just to be clear, it’s important that you do get a timer installed, as it greatly improves the effectiveness of the solar geyser. Luckily I already had one installed on my regular electric geyser)

Monday, March 29, 2010

A Solution to the Carnage on our Roads

Yesterday, driving to work on the N1 south, and was passed by an old Toyota Cressida doing about 160 km/h. It was obvious that he had no regard for the rules of the road, because he was also talking on his cell phone.

This got me thinking… what will make this guy start driving responsibly? It was then that I realised that there is no incentive for people in South Africa to obey the rules of the road. There is a threat of a fine, but most people just adopt the attitude “It will never happen to me” or “If I get a fine I can just talk my way out of it”.

Before we can try to solve the problem, we have to ask ourselves what the role of the traffic department is. Is it to fine as many people as possible in order to achieve some kind of budget, or is it to ensure the safety of people on the road? As far as I am concerned, it is the latter. The traffic department should be responsible for ensuring the safety of people on the road.

Which brings me to my idea...What is the ultimate motivating factor that drives human beings? Incentive. Incentive is what drives us. It makes us wake up in the morning and get out of bed. So why not incentivise
good driving habits?

This Easter, the police should pull over people who are travelling at the speed limit, stopping at stop streets, driving on the correct side of the road and reward them for obeying the rules.

The reward could be something as simple as “free road tax for a year” or a “free road worthy test”... or a police escort through the morning traffic! It would be like the lottery a 1 in 60 million chance of winning, but you still enter. That is you obey the rules of the road.

There would have to be some rules, like; if you have outstanding traffic fines you are excluded; if you get any traffic fines in the following 3 months you loose the benefit; etc...

Ok, so this idea screams “please abuse me”, but maybe it’s worth giving it a go. It’s time the traffic department started being proactive about road safety and not viewing it as a budget item that needs to be “achieved”

Gated Communities in Gauteng

I recently had the displeasure of finding that one of my routes to the office had been closed by the residents association of the suburb i was driving through. I wasn't the only poor schmuck that was blighted by the closure. The road was crammed with people doing U-turns.

After I had vented my anger on the steering wheel of my car and finished thinking about the best way to blow up the offending gate, I started pondering what I could realistically do about it. The starting point was the "welcome to bordeaux" board that kindly gave me a web site address for the residents association. (I had plenty of time to read all the details on the board because of the mad traffic jam caused by all the closed roads).

The website was a trove of information. Email addresses and phone numbers of the all committee members; addresses... A little googleing turned up a few more details; photos, work addresses, and a facebook group. Bingo!

So, step one was a quick email to all the members (copied to the JRA and some influential radio personalities) voicing my disbelief in the closure of the roads. Step two was a post to the facebook page. I expected my complaint to be immediately put in file 13, but was surprised when the first reply popped into my inbox.

The ensuing mail storm basically revealed that they wanted the roads closed because there was too much "alien" traffic in the suburb; they believed that criminals were too stupid to use the roads that they left open and that i should just go away because it was "legal" anyway.

Ok, so crims are often fairly retarded, but i think this assumption takes the cake (we'll leave the discussion of the merits of closing suburbs for another day). Too much traffic in the suburb? I had to laugh at this one. Aren't roads supposed to be used by cars (alien or not), and anyway they are public roads. As for the legality of the closure; the chairman of the residents association was not forthcoming when i asked for the court ruling as it was "with the lawyers in whiteriver". Obviously she hadn't heard of faxes, scanners, email; which is odd since i was communicating with her via her blackberry.

It was, however, the post on facebook that returned the most interesting result... As it turns out, the residents association didn't have the backing of all of the people living in the suburb. In fact there were a lot of people living in the suburb who were opposed to the road closures. In fact they claimed that they were bullied into the closures by the committee.

Facebook also provided me with a copy of the court ruling (uploaded by one of the disgruntled residents). As pointed out by the poster, the court ruling was interpreted by the residents association the way they wanted to interpret it. In short they don't really have a leg to stand on.

So whats my point? Everything is not as it seems on the surface... if you have the misfortune of getting stuck because of a road closure, don't just accept it. Do something (that doesn't include explosives) about it!

"Throughout history it has been the inaction of those who could have acted, the indifference of those who should have known better, the silence of the voice of justice when it mattered most, that has made it possible for evil to triumph."

Footnote:
If you want to see all the details, join the facebook group "Bordeaux Residents Against Gates"