Monday, May 30, 2011

Nothing Is Free!

What's so great about the "free market"? The phrase sounds great because it has the word "free" in it and everyone knows that's good. Plus there's "market" and we all know that markets are a natural and efficient way to get things done, don't we? As I said, it sounds great in principal but there is one small matter to consider: is the free market real, and even if it is real is it the best solution?

The reason I have chosen this subject is because of a free trade deal our government is currently considering with the US and it looks as if one of the casualties of this miracle of modern economics might be New Zealand's drug buying agency, Pharmac.

Pharmac was set up to coordinate the purchase of drugs for the country's hospitals and other medical institutions, to find the best price for required drugs, and to decide which drugs should be subsidised by the state. It has saved the New Zealand taxpayer one billion dollars per year but the drug companies don't like it of course, because it interferes with their corrupt and immoral profit taking at the expense of everyone else.

So they are dredging up the old nonsense of "free markets" saying that Pharmac interferes with this process. Maybe it does and in that case many free market zealots would say it should be removed to preserve the purity of the free process. But as I have said many times before: the free market doesn't work now, it never will work, and anyone who bothers to look will see it hasn't worked in the past either.

Sure, it sounds like a great idea in principle. After all, who doesn't want "freedom"? The problem with the type of freedom pushed by libertarian fanatics is that it isn't real. By transferring control to the market all we have done is hand control of our fate from politicians and bureaucrats to corporations and CEOs.

For example, in the case of Pharmac we have a bureaucratic organisation ultimately controlled by the government which decides how the country's drug purchasing should be organised. That doesn't sound that attractive but consider the alternative: pricing and availability being controlled by big foreign corporates and their CEOs.

I know which I would prefer. At least the local bureaucrats and politicians are under some sort of control by the voting public. Large, mostly American, corporations are totally beyond our control. And what is the prime motivation of these differing systems? The corporations are clearly after profit and very little else while Pharmac has no real profit motive and while it may be a bureaucracy at least it is one with the best interests of the country as it's central reason for existing. When Australia stopped using their similar agency (after pressure from America) they paid billions per year extra in drug costs.

The libertarian dogmatists will answer this with the assertion that the free market will sort it all out. If a drug is deficient in some way (including price) when sourced from one company then people will just buy it from a competitor. Yes, in principle that might be true, but in practice it rarely is. Corporations are expert at using political pressure, collusion with their supposed competitors, and questionable marketing techniques to maximise their own profits and this bypasses the markets some people have so much faith in.

It's no surprise that the libertarian movement is anti-science in many ways (for example libertarians often reject the reality of global warming) because their ridiculous beliefs would never hold up to examination by the scientific method. It's easy to claim that markets always create efficient systems where the consumer wins but I don't see a lot of empirical evidence supporting that idea.

I will agree that sometimes the market does work fairly well. In areas where there are many alternatives, no monopolistic control, and minimal influence from companies on politics the "free" markets can work adequately. But I would never trust them for something that really matters.

We can survive in the situation where consumer goods come from a market-driven system with all of it's inefficiencies and problems but there are things which are too important to leave to the market and health would probably be at the top of the list. I would also include other important infrastructural items such as education, electricity, water, and communications. I would also prefer to see these controlled by a government bureaucracy rather than giving big corporations control.

We have a drug purchasing system in New Zealand which works quite well (unlike a lot of other aspects of our health system) and it would be unfortunate if this government threw that away purely for ideological reasons. Unfortunately, that is probably exactly what they are going to do.

Tuesday, May 24, 2011

Alternative Policies

The New Zealand government's budget is still in the news here and more recently the opposition have offered some alternative policies. So how do the two approaches compare?

Basically the National government has taken the path of cutting spending and selling assets. Whether this is a good idea or not is open to debate but one thing is clear: it's exactly what you expect from a conservative government and no one should be surprised they have done it.

On the surface it seems reasonable that if you are borrowing to balance the budget then reducing spending is the obvious solution. But I would say let's go back a step and see why all that borrowing is necessary. Is it because there is too much spending or is it because there is not enough income? Of course, it's probably both.

A significant contributing factor to the current deficit must be the income lost through the tax cuts to the rich the government introduced shortly after coming into power. They said we would all be better off because reducing taxes leads to greater investment and productivity. Apparently not.

So what have we gained? The rich have even more than they did in the past and are making even less contribution to society than they ever did, while the low to middle income groups are increasingly compensating for those losses and are still being told they must be more frugal and more productive in the future.

Why? So that the rich can get even richer while contributing nothing? Seems fair.

The opposition have released some policy details and two ideas have got particular attention. The first is giving tax credits for research and development, and the second is increasing the minimum wage. Do these ideas have merit?

Of course they do. The government disputes the figures and predicts all sorts of dire consequences of course, but that means nothing. It's their job to criticise any alternative policies and their credibility is low. So let's look at these ideas without a prior political perspective (well maybe that's unrealistic but let's try anyway!).

What's wrong with taxing the rich a bit more, making farmers who pollute our environment pay their fair share, and offering tax incentives for any individual or company which invests in research and development? It seems fair to me. The idea of cutting tax to the rich is to improve our economy but why not do that more directly through tax breaks for R&D. If the rich are really making contributions to society in that area they can get their tax back through the refunds instead of just getting it as a right.

And what about the minimum wage? Some people say increasing it from $13 to $15 per hour will cause massive unemployment because employers won't be able to afford the extra. Any employer who can't afford the cost of a couple of cups of coffee per day probably won't survive long anyway so what's the problem? Thirteen dollars per hour equates to $27,000 per year. No one should be asked to survive on that in a modern, rich western nation like New Zealand.

And if companies are hiring people they are presumably doing it because they need them. Won't they still need them after this very moderate increase? So why would they suddenly be unemployed? Also, the argument that more experienced people will be hired instead doesn't make sense. Either way it's one person employed. What exactly is the problem here?

The fact is the employers are just greedy. Economies benefit from a slave labour force which will work for next to nothing and many employers and many in this conservative government want exactly that, despite their propaganda to the contrary.

To be fair there probably would be a few situations where companies are just on the border of survival and might need to reduce their staff if the minimum wage was increased but I think the effect would be far less than what the government claims. And common human decency dictates we should provide everyone with an income that allows them to live with some dignity.

If lower minimum wages are so good why not reduce them even more? Would that not inspire the economic miracle of capitalism and the free market to make us all richer? What a joke. That little fairy tale should be well and truly discredited by now.

Finally there is the argument I heard this morning that people shouldn't get higher wages unless they "increase productivity". This seems to be a catch phrase parroted by employers and conservatives but none of them seem to be able to say exactly what it means. How can a teenager serving at McDonalds increase their productivity? How can someone caring for the elderly get more productive? It's just another pathetic excuse offered by the greedies to excuse their lack of generosity to the people who actually do the work.

So the government's budget wasn't actually that bad. It totally lacked any positive ideas, it was a poor attempt at improving our economy, but it's what we expect from a government with no worthwhile policies at all. But it could be a lot worse. Often the best thing a bad government can do is nothing, or nothing significant, and that's what seems to have happened here.

Sunday, May 22, 2011

Epic Fail

There's a phrase which has been common in popular culture for a while now. It's "epic fail" which is used to describe a situation when someone does something so stupid, says something so pathetic, or gets things in general so badly wrong that it's a joke. And what could be more worthy of this phrase than a failed prediction of the end of the world?

I can answer that. What could be more worthy is that prediction from someone who has already made the same prediction in the past and failed. Actually there's an even better answer: the phrase "epic fail" really belongs to someone who predicts the end of the world when it doesn't happen even though he has failed with the same prediction in the past and the same prediction by thousands of others has also failed and the prediction is based on superstitious nonsense from a silly old book.

Yes, that's the ultimate "epic fail" and it belongs to a clown by the name of Harold Camping who told us the rapture would happen today. His prediction was based on the Bible too, so how could it possibly be wrong? Wow, this situation just brings out the most sarcastic and cutting comments from skeptics and atheists. And rightly so because fundamentalism is just a pathetic but dangerous joke, and this illustrates that fact very well.

As I said above, there have been thousands of predictions of the end of the world in the past and none (so far) have turned out to be true, although some of the people making the claims have made statements like: the world did end but we just didn't notice (usually because it was a "spiritual" end or some similar unsubstantiated garbage).

So time after time the Bible fails as a source of prophecy. I have done some research on this because some of my religious friends think the alleged prophecies in the Bible make a strong case for the validity of Christianity. But it's all rubbish. Not only is is rubbish but it's obvious, pathetic, childish rubbish.

Here are a few of the tricks the Bible uses to make prophecies look real: the prophecies are written after the events they were meant to predict; the events prophesied are made up to fit the prophecy; or the prophecies are so vague that many future events could be warped to try to make them fit.

So yes, the Bible is a silly old book. It's also a rather boring old book: it's repetitive, badly written and generally lacks literary merit. And it's extremely dishonest because it's full of deliberate lies. Plus it's dangerous because it encourages many people to do stupid things and it encourages some to do evil things.

Of course it doesn't matter how many times the Bible's supporters fail, it will still be seen as the unerring word of God by many. Why? Because that's what they have been told they have to believe. They haven't thought about it. They haven't tested this rather radical claim. They just accept it like the mindless sheep they are. And that isn't an insult because they want to be mindless sheep. Why? Because the Bible tells them to!

So most of these fools deserve nothing but contempt and they are getting plenty. I have seen a lot of news items describing this latest failure of Biblical prophecy in condescending and amusing terms. Of course it is unfortunate that some people have wasted their time and money in supporting something which was obviously untrue from the very beginning. And those who have spent all of their savings because they didn't think they would need them after today deserve a certain amount of sympathy as well as contempt.

But it's hard to be too sympathetic because anyone who is prepared to use the brain they think their god gave them can easily see the truth. If they failed to use that (alleged) god given faculty then they can hardly expect too much commiseration from those who do.

I wonder what the believers thought when the apocalypse failed to materialise. Did they think they have been left behind because they are unworthy? Did they think they have been deliberately fooled by Camping? Or did they think there has been just a slight miscalculation and they should look forward to another date in the future instead?

Whatever their response it isn't good. Although there is one possible positive result: that they realise the whole belief system they are involved with is fake to its very core and they should get out. But I suspect few, if any, will do that!

Thursday, May 19, 2011

It Worked!

I'm not going to comment on the pathetic excuse for a budget our (New Zealand) government had the temerity to release today. I'll think about it for a while and then comment. Maybe after that time I will have seen some merit in it, or more likely it will seem even worse than it does now!

No, in this entry I want to comment on something far more positive: how well my server transition went yesterday. For a few years now my main web server has been an old Power Mac G4 and I wanted to upgrade to something slightly more modern: a Power Mac G5 (yes, I did say it was only slightly more modern).

The problem is that my server runs 8 web sites, although only one is very substantial, and has many databases running in the background. There are also some custom configurations it requires to run. Of course I wanted the web sites to be down for the minimum amount of time during the transition. Oh, and to make things slightly more complicated I had to do all this in my spare time between doing "real work".

There was one factor on my side though: I was using Macs!

As you can probably tell from my triumphant tone (and the title of this blog) it worked really well! All of the web sites are running correctly. The databases (including this blogging system) are all running as expected, and the new system is significantly faster than the old one (although the upstream speed of my internet connection is still a bit slow for this purpose).

So I installed new hardware, a much more modern operating system, new versions of PHP, MySQL, and Apache, and the latest versions of all the web sites, plus I maintained the data (over a million records) from all of the databases with a total down time of about 2 minutes. And now, 24 hours later, I haven't found any problems.

So that's my happy computer story. On most days I encounter enough weird computer problems which I have to waste a lot of time to solve, so it's nice to win for a change!

Wednesday, May 18, 2011

Arrogance Ignorance Stupidity

Today I listened to several podcasts on the topic of global climate change. It was interesting to hear the reasoned views presented especially when compared to the indefensible nonsense argued by most climate change deniers. I would challenge anyone to listen to the interview with James Hansen and still think climate change deserves serious doubt. He handled all the usual objections with ease although I do have to concede that the interviewer was playing devil's advocate more than acting as a serious adversary.

There are several types of people who don't accept climate change: the ignorant who follow their preferred leaders who themselves are either ignorant or have a political objective; the dogmatic (such as libertarians) who simply cannot accept that control of business is necessary for the greater good; the politically motivated who see climate change as a view supported by the left and therefore cannot accept it whatever the facts; and those who have genuine doubts who, in most cases, aren't as familiar with the facts as they should be to make those judgements.

So in general all of the people who are against global warming are in fact deniers rather than genuine skeptics. That's why I generally refuse to refer to them as global warming skeptics. I am a skeptic on a number of subjects but skeptics do accept theories which have good supporting evidence and global warming clearly fits into this category. Therefore I am very offended at calling deniers "skeptics". They don't deserve that label.

One of the more interesting points I heard made concerned libertarians. When I use that term I mean people who want a free market, who trust the market (whatever that is) to sort out all problems, and who want the minimum (or zero) regulation. These people often refer to groups who want to protect the environment as being ideologically driven and of following a religion. I agree, some environmentalists do fit into that category, but the ironic thing is that the libertarians themselves are at least as bad. Their ridiculous idea that the free market is the answer to almost any problem is pure nonsense and should surely count as a religion accepted on faith more than a genuine political or economic theory supported by facts.

Rejection of global warming exists at several levels. First, some people reject the idea that the climate is warming at all. Second, others accept that warming is happening but reject the theory that humans are the primary cause. Third, some say it is true and may or may not be human caused but is a good (or neutral) phenomenon anyway. And finally, some accept the truth and cause and concede it is bad but think there is nothing we can realistically do about it, either because the problem is too big from a practical or political perspective or that the economic cost of action is too great.

As time has passed and the evidence has grown I have become convinced that global warming is happening, that there is very strong evidence that it is primarily caused by human activity, and that the overall outcome will be negative. But until now I was less sure about whether there was anything that could be done about it. After listening to Hansen I think there actually is something that could be done but I still don't think it will be done because governments of the world rarely do what is right: they are too involved with short term political cycles to make the big changes necessary.

Hansen thinks a carbon tax is the answer. The money which was taken would be redistributed evenly to all the citizens of the country where it was taken and any imports from countries who don't run a similar scheme would be taxed at the border.

I'm no economist but superficially it seems like a great idea. There are two major objections to carbon taxes: first, the extra costs would be passed on to consumers (users of electricity from coal powered stations for example) and would therefore not count as a real disincentive at all; and second, countries with no carbon tax would have a huge advantage over those who do, again creating a totally counterproductive situation.

But if the tax takings are redistributed to everyone then the consumers have the ability to pay the extra charges, unless they source their power from a carbon neutral source in which case they will be better off. And any country who doesn't tax carbon producing industries will have them taxed anyway when they export their products. The only difference is the country doing the importing will get the tax instead of the country of origin. That seems like a reasonable incentive to apply a tax, wouldn't you say?

Maybe the only reason this sort of scheme hasn't been applied is pure self-serving arrogance, ignorance, and stupidity. Higher tax policies are sabotaged by business interests. That's arrogant (actually it's just evil in a situation like this). Taxes designed to create a specific economic or social outcome are rejected because people don't understand the big picture. That's ignorant. And all taxes are unpopular even when the majority are better off as a result. That's stupid.

Unfortunately I think there will be no real action on this for just the reasons I have mentioned above. Ironically China is taking the whole situation far more seriously and is investing in new technologies (although they are still building a lot of new coal burning power stations) so it could be a less "free" country which has the real advantage when action really does become necessary.

Of course, by then it will be too late. It possibly already is. Arrogance, ignorance, and stupidity. It's a hard combination to beat!

Wednesday, May 11, 2011

Geek Jokes

Some of my recent blog entries have been a bit intense, bitter, and angry. So it's time for something a bit lighter! I was reading through my collection of geeky (science and programming related) jokes and thought I might share some of them here. I would also like to explain the jokes, just in case the reader doesn't have a technical background.

I have a lot of geek jokes so I thought I would stick to the sub-genre of "a [insert anything here] walks into a bar" type jokes. Most of these involve rather corny puns (for which I apologise in advance) but some are also quite clever. So, here they are...

Joke: A neutron walks into a bar and orders a drink. Upon being asked the price, the bartender responded, "For you? No charge."

Explanation: This one should be fairly obvious to anyone with even a basic knowledge of science. It's a pun based on the fact that neutrons have no (electromagnetic) charge so the bartender doesn't charge for the drink... Yeah, fairly lame, but some of the others are even worse!

Here's a related joke which I'll let you figure out: One atom says to another atom... "I think I've lost an electron.." The other says... "Are you sure?" He says... "I'm positive."

Joke: So he leaves. The bartender says "We don't serve your kind here." A tachyon walks into a bar.

Explanation: This one is a lot more difficult. A tachyon is a theoretical particle which travels faster than light, therefore it travels backwards in time. So the whole joke is also backwards. Pretty cool huh? One of my favourites actually.

Here's a related joke: To get to the same side. Why did the tachyon cross the Mobius strip? (it has two clever bits - I'll let you figure out the second).

Joke: A superconductor walks into a bar, the bartender says, "Hey, get out, we don't serve your kind here". The superconductor leaves without any resistance.

Explanation: Superconductors are perfect conductors of electricity so their electrical resistance is zero, so they have no resistance. Another double meaning.

Joke: A noble gas walks into a bar. The bartender says "we don't serve your type here". The noble gas does not react.

Explanation: This one requires a little bit of knowledge of chemistry. Noble gases are elements which rarely react with other elements to form molecules, therefore we have the old double meaning again with the word "react".

Joke: An infrared photon walks into a bar and says "is it hot in here or is it just me".

Explanation: Ah yes, is this funny? The original joke said "proton" but I thought "photon" made more sense. Infrared photons are generated by heat sources, so... Yeah, you must be getting the general theme by now!

Joke: A logic gate walks into a bar. Not.

Explanation: A logic gate is a computer science construct (or a real electronic component) which performs a logical operation on true/false values. So an "and" gate is true if A and B are both true, an "or" gate is true if either A or B (or both) are true, and a "not" gate is true if A is false. Yes, you need to be a real geek to like that one.

Joke: A byte walks into a bar and asks for a beer. The barman asks him "hey, what's wrong?" The byte replies with a sad face "parity error". Yeah, the barman says, you look a bit off.

Explanation: another "inside" computer geek joke. Parity is a way to check the validity of data by adding an extra bit (0 or 1 value) onto the end of the real data. Typically a character might be represented by the first 7 bits of a byte and the last bit (bytes are always 8 bits) is used as a check of whether the character is valid. If the bit gives a bad result it's called a parity error.

Of course, parity is the source for a lot of jokes. Here's another: What's got feathers and goes "Pieces of seven, pieces of seven" A parroty error.

Here's another computer geek joke which I'll leave the reader to figure out: There are only 10 types of people in the world: those who understand binary, and those who
don't.

If you got that one you should also get this one: Why do programmers always get Christmas and Halloween mixed up? Because Dec 25 == Oct 31.

Joke: Two neutrinos walk through a bar...

Explanation: Neutrinos are almost massless and don't interact much with anything. They can easily pass through the whole Earth so they wouldn't be stopped by just a bar, would they?

Joke: A statistician walks into your average bar. The bartender says "we don't serve your type here". The statistician says "you're just mean".

Explanation: The word "mean" has multiple meanings. The bartender is using it in the context of "unkind" but a statistician would use it as a more correct term for the word "average".

Joke: A font walks into a bar and the bartender yells "We don't want your type in here!".

Explanation: The word "type" has about 8 meanings. One is the letters that are formed by a font. I guess different fonts produce different type...

Joke: Schrodinger's cat walked into a bar... and didn't.

Explanation: This cat is part of a famous thought experiment created by Erwin Schrodinger, one of the people involved in early quantum theory. The cat was described as being in two states (both dead and alive) while in a box containing poison which might be released by a quantum event (I must emphasise that this was a thought experiment and no actual cats were harmed!) so the joke makes sense when you know that. Doesn't it?

Joke: Three strings walk into a bar. The first one says "I'll have a beer." The second says "I'll also have a beer.' The third one says 'I'll have a shot of vodkadjfjd lskbtj dkl#fla%dkfyej rwejfojp#akjfdi fl[ajeig/iojd@jfa!ljfkldj." The bartender looks at the first two strings and asks "what's up with him". They reply "Oh don't worry about him, he's not null terminated."

Explanation: When I read the first part of this I thought it was about the strings from string theory but it soon became obvious it was about strings (sequences of characters) used in programming. In the C programming language the end of the string (because they can be any length) is marked with a null character (character number zero). So if a string is missing this terminator the program will display whatever junk happens to exist at the end of the real string. The technical aspect of this is clear, why it is a joke less so!

Joke: A molecular biologist walks into a bar, and the bartender asks, "AGCAAAAGCGGAATAAU?" The biologist replies, "I'm going to need a translation."

Explanation: The letters refer to a sequence of bases, the "language" of molecular biology. Translation is both a process of converting from one language into another and a biological process for converting sequences in DNA (or the mRNA which is produced from them) into proteins, so it's a joke, isn't it?

So that's my collection of jokes. I hope you enjoyed them. By the way, I did all the explanations from my own knowledge of science and technology without any access to extra reference material so I hope I got them right. Any alternative explanations would be very welcome in the comments.

Tuesday, May 10, 2011

Freedom Fighter?

Are some subjects so sensitive that we shouldn't even have an open discussion about them? If that class of subjects exists does it extend to entirely political events? Should it? Specifically what I am asking is whether it's possible to discuss the life and actions of Osama bin Laden in any way except that approved by the official western propaganda machine: that is that he was a murderous villain.

Controversial New Zealand politician and Mana Party leader Hone Harawira recently commented that he thought bin Laden fought for rights, for land, and for freedom of his people. That is a far more positive opinion that the official line allows and he later apologised for the comment.

But should he have? I'm not saying that I think bin Laden really was a hero, or that he was motivated by a genuine wish to free his people, or even that he deserves much respect. What I am asking is should we approach dissenting opinions by forcing apologies or should we try to show where the argument is wrong?

Ironically a major reason given for fighting terrorism is to preserve freedom yet it seems that freedom doesn't extend to offering any opinions other than that one which is officially sanctioned by the Americans and their allies.

Maori commentator, Ranginui Walker was surprised about the apology and said he thought Harawira was "right on" in his appraisal of bin Laden. Yet he went on during an interview I recently heard to contradict the idea of bin Laden being a freedom fighter and basically agreed he was a terrorist. But at the end of the interview he compared him to Che Guevara, surely the revolutionary with the most positive public profile.

So which is it? Freedom fighter, or murderous terrorist... or both? Clearly it depends on what perspective you look at the subject from. Ranginui Walker is an activist for Maori rights and sees western forces (for example British, American, and New Zealand settlers) as representatives of empires he describes as "bathed in blood". So he identifies with individuals fighting for the rights of who he sees as the oppressed. I don't agree with his opinion (or Harawira's) but I do think it is good that they have made their ideas public and I don't think they should be forced to apologise for them.

If bin Laden's actions are genuinely as evil as most western leaders say then that will be obvious to everyone and opinions contradicting this view can be easily dismissed. But refusing to even look at the possibility that those opinions have merit is almost like saying the establishment doesn't want the issue even discussed. As I said, if the situation is as clear as claimed what would be the harm? It's almost as if there is a fear that the simple "good guys versus bad guys" story which has been created will be destroyed if we look at it too closely!

For the people who do promote a more nuanced view on the subject the consensus seems to be that al Qaeda is an organisation fighting for what it sees as freedom but it is totally deluded regarding the way to achieve its aims. What sort of organisation tries to ensure peace by promoting violence? And how can it achieve freedom by imposing oppressive rules based on the most archaic interpretations of Islam?

So I don't think Harawira should have apologised. And the prime minister simply labelling them as "ridiculous" or "misguided" without really saying why is just intellectually lazy (no surprises there). What should have happened is that someone should have explained why his opinions give bin Laden too much credit. But just labelling him a terrorist and leaving it at that isn't enough. Closing down the debate won't change anyone's point of view: it will just make people with views contrary to the official propaganda keep quiet about them and that can't be good.

Thursday, May 5, 2011

Below the Surface

A couple of weeks ago I completed a 3 day programming course which covered writing iPhone and iPad apps. I have been a programmer for many years and have written hundreds of real programs - some of them even worked - but recently I have mainly done web programming, created dynamic web sites, and built databases using the PHP language and MySQL as the underlying data source.

Writing web programs certainly has some challenges but to me it seems simple compared to writing an iPhone application. On the other hand I do remember having problems when I first started programming on various new platforms. To write a program for the classic Mac for example (I'm talking about pre-Mac OS X days now!) took about 1,000 lines of code just to provide the basic functions (a window, menu bar, editing functions, etc) before you could even start on the real functionality.

With the iPhone you get all of that, plus a lot more, for free. You can "write" a simple web browser with about 10 lines of code for example. Sure, that's because Apple provides the core browser functions for you just to connect in to your app, but it's still impressive. To write one for the classic Mac would probably take about 100,000 lines!

The problem I have is those 10 lines. In some ways 1000 lines of simpler low-level code is easier than 10 lines of very obscure code. Actually I should clarify that. Objective C code is easy to read (it's very verbose) once you understand some of its odd syntax, but not necessarily easy to write. I find that I'm not sure why some code is there even though I can tell what it does!

But, as I said, that could be just because of lack of familiarity. The programming course I did (or didn't do because I never turned up to lectures because I already knew it all!) when I was a student for the extremely simple and clear language Pascal went for months. This course for a language with 100 times the functions was just 3 days. That's a fairly intense learning curve!

But enough of this geeky stuff, what is my real point here? I am just contemplating the complexity that lies beneath the surface of modern computing equipment. It's not limited to the iPhone and iPad of course: the Mac has a very similar system underlying it, and so do devices based on other operating systems. In fact the iPhone system is based on the Mac system, with a touch layer instead of a mouse and keyboard layer on top (roughly speaking).

Programming the iPhone is challenging because Apple provide so much functionality in the operating system and allow access to those functions through an elegant and extremely rich development environment, so there's just a lot you need to know.

So although the iPhone is a beautiful piece of hardware there would be a case to say that the software it runs is even more beautiful and valuable. After the course this is more apparent because when I use apps on my iPhone and iPad now I have a better idea of what's really happening in the background. That complexity, elegance, speed, and reliability really is an impressive achievement (one which other companies are yet to match in my opinion).

Hardware, no matter how good it is, is only useful if it can be easily accessed by the user. That's where the operating system software becomes important. But many people don't see that layer. They think they are accessing the hardware directly. Let me give an example here. The iPhone's GPS only gives an instantaneous reading of its current position. But the system is smart enough to change that into a speed and direction. It also provides an estimate using cell tower triangulation and other techniques if the GPS isn't available or the device doesn't have one. And it does a lot of other stuff as well. Without the software the GPS would be just like the early handheld devices which simply displayed latitude and longitude.

People should remember these points when they try to criticise the price of Apple's products. The effort that goes in to the software is probably several times greater than what goes into the hardware (although, again I don't want to detract from the brilliance of the hardware design) and that is rarely considered by many critics. People just don't understand that there's a lot more to the iPhone (and iPad and Mac) than what they see on the surface.

Tuesday, May 3, 2011

Was It Worth It?

Twitter really showed its value in the latest big news event: the death of Osama bin Laden. The incidents were tweeted as they happened, many people first learned about the news through Twitter, and there has been a lot of commentary (OK sure, most of it was completely useless) since the news broke. At its peak Twitter delivered 4000 tweets per second on the subject. Of course, like many internet information sources the problem is to find the useful signal amongst the noise.

One of my favourite tweets on the death of bin Laden was this: "So it took you 10 years, 2 wars, 919,967 deaths, 1,188,263,000,000 US dollars and finally Osama is dead! was it really worth it America?" Good question.

As I said yesterday, from a practical perspective it clearly wasn't worth it. Many people think terrorism will increase as a result of bin Laden's death. Ironically almost every political figure has said the opposite but I think most are too scared to say anything contrary to the official American line of propaganda. But the public obviously can see through this because according to a Herald poll when asked "is the world a safer place now bin Laden is dead?" 77% (including me) said no and only 23% said yes.

Obviously it has been a great psychological boost for the US. A power which seems to be slowly losing its prime position in the world has received a short-lived reason to celebrate. Again as I said yesterday, I think these celebrations are in extremely bad taste but what else has America still got?

So the answer to the question seems to be that it wasn't worth it, although the question is unfair because no one has said that the sole purpose of the "war on terror" was to eliminate bin Laden. But whether it is worth it considering the other current outcomes is also highly doubtful, plus there's the old question of whether the end can justify the means even if the end is itself worthwhile.

The rhetoric is certainly intense from many groups in society. Who sent his naive foot soldiers out to sacrifice themselves while he stayed safe? Who lived in luxury while the people doing his work had to make do with basic living conditions? Who was motivated by religious and political dogma all of which is highly dubious? Who used secrecy to preserve his own life at great expense to others? Who sacrificed women and children for his own political ambitions?

The answer most people would give is Osama bin Laden but, when you think about it, all of those criticisms could easily apply to the leader of America as well, especially to George Bush. On the other hand many people would point out that the conflict began after the 9/11 attacks and America was simply retaliating against an aggressor. So it's hard to be too sympathetic to whatever losses al Qaeda have suffered, including the loss of their leader.

Over one trillion dollars is a lot of money. When I think about how that could have been used for scientific and technological progress instead of war I find it difficult to join the celebrations that many Americans have enjoyed. It's yet another example of the great lie many modern governments tell us: that they can't afford (put whatever worthwhile program you want here). It's not true. They can afford to pay for science, or health, or welfare, or education, or many other worthwhile things. They just have to put a higher priority on these things than they do on war, or rescuing private financial institutions, or whatever other wasteful activities they are engaged in.

A trillion dollars to achieve very little, to probably make the world less safe, to kill almost a million (mostly innocent) people. Was it worth it? How could it be?

Monday, May 2, 2011

Celebrating Death

Anyone who initiates violent acts against another group or country should expect retaliation and deserves no sympathy if he is the victim of violence too. But it's also unpleasant to see the death of any person treated as a political victory or as a reason for joyous celebration.

If the death of Osama bin Laden is a good thing then the celebrations should be suitably restrained. Political rhetoric, celebrations in the streets, and nationalistic fervour are totally inappropriate. The same Americans celebrating bin Laden's death are repulsed by similar behaviour in Islamic countries. Isn't that a double standard?

Sure the 9/11 attacks were a terrible and unjustifiable action, but were they any worse than American air strikes on civilians in many countries around the world? I can't see the difference except that the Americans are supposed to be our friends.

Practically the death of bin Laden it is irrelevant, in fact it is more likely to cause violence rather than reduce it. Many of the fanatical terrorists will be inspired by the martyrdom of their leader. So this is a symbolic victory for the Americans but maybe it is the same for their enemies.

The celebrations in the street in America are sickening. Is this really the greatest Christian nation in the world? Would Jesus condone the celebration of death this way, even of an enemy? Of course not: what hideous hypocrisy.

I don't want to see terrorism flourish and that's why I think the current military action against terrorists - and any other random group the western powers don't like - isn't the right thing to do. And celebrating anyone's death - even if it's of an immoral and violent enemy - just isn't right.