2010-11-25

Lame duck mode

I'm quitting Google. I have a couple of offers already, but I'm looking for a promising Ireland-based startup that could benefit from having someone like me around. Who wants to interview an ex-SRE?

2010-05-08

The Single Transferable Vote in four easy pieces

It wasn't long before pointy-haired talking heads appeared on the BBC to bad-mouth proportional representation. Here's a simple guide to explain proportional representation by the single transferable vote (the style mentioned in the UK Liberal Democrats' manifesto). It assumes that you're already familiar with plurality voting (first past the post) as it's practised in the UK and the USA.

Start with plurality voting. Each voter marks a ballot in support of a candidate, and the candidate with the most ballots wins.

First reform: If nobody gets 50%, eliminate the bottom candidate and try again.

If someone gets more than half the vote, they've won. But what happens when nobody gets there? In plurality voting, the candidate who's furthest ahead gets elected anyway — this can elect a massively unpopular candidate if the opposition is split among several candidates! In STV, when nobody gets enough votes to be elected, you eliminate the candidate with the fewest votes. Then you start all over again as if that candidate hadn't been on the ballot paper. You can think of this as getting your vote refunded to you so you can cast it again if the election didn't produce a proper result the first time.

Second reform: Preference voting.

It would be a major pain if everyone had to keep coming back day after day to vote again as candidates get eliminated. A much better idea is to get each voter to rank all the candidates in order of preference. That is, you mark a 1 (not an X) by the candidate you want to vote for, then you mark 2 by the candidate you'd vote for if your first preference was eliminated, then mark 3 by the candidate you'd vote for if 1 & 2 were both eliminated, and so on until you don't care any more. Now, when a candidate is eliminated, the ballot papers for that candidate can be re-examined so that each one is transferred to the voter's second choice. This is quick and simple to administer but it relies on voters' ability to write down a sequence of numbers in ascending order — a test failed by about 1% of voters in Ireland in every election.

So far, these two reforms have given us the Alternative Vote system, sometimes called the Instant Runoff Vote system. It eliminates the need for voters to hold their noses and vote for the lesser of two evils. Instead, you can cast your first-preference vote for a candidate you genuinely support, and use your second preference to arrange for your vote to transfer to someone who will probably have a chance of being elected. No more tactical voting, and you don't ever have to worry about wasting your vote on an also-ran. Now, let's do something about proportional representation.

Third reform: Multi-member constituencies.

Plurality voting systems are not proportional because everyone who didn't vote for the winner goes unrepresented in parliament. With only two parties (or an alternative-vote system) this can be up to 50% of the voters — in the UK, it's usually more. As a general rule, the more people are unrepresented, the more seats are disproportionately allotted to the larger parties. In STV, this fraction is kept low by returning 3–5 members of parliament from each constituency. This limits the unrepresented fraction to 17-25%, which is a great improvement.

To be elected in a 3-member constituency, you need to get over 25% of the vote. In a 4-member constituency, you need over 20%. In a 5-seater, you need more than 16 2/3%. The formula giving this winning threshold (called the quota) is 100% / (1 + number of seats). (There are variants that use different formulae, but I'm describing the simple system used in Ireland.)

Now you have several local MPs, and they have to compete with each other for voter approval throughout their term. They hate this. It's great.

Fourth reform: Transfer surplus votes.

This is the tricky bit. If a party gets 50% of the vote in a 4-seat constituency, they should win 2 of the seats if the result is to be proportional. But if one of their candidates gets 45% of the vote and the other gets 5%, it's unlikely that second candidate will get elected. This needs to be corrected.

The solution is to transfer elected candidates' surplus votes (the extra ones they had after reaching the quota) in the same way that eliminated candidates' votes are transferred. The trouble is this: which ballot papers get transferred, and which ones don't?

The simplest thing is to pick them randomly: if the quota is 10,000 votes and a candidate gets 12,000 votes, then 2,000 ballot papers are randomly chosen to be the lucky ones that are transferred as the surplus; the unlucky remainder sit out the rest of the election.

The best thing is to apply a fractional discount to the ballot papers and transfer them all. Using the same numbers, each of the 12,000 ballot papers would be marked (for example, with a sticker) to indicate that each one was worth only 1/6 of a vote, and they would all be transferred. Together their value is (12,000 × 1/6) votes, which equals 2,000 votes.

(In Ireland, we do something which is neither simple nor right. You probably don't want to know. If you really do want to know, search for last received subparcel and Woodall free riding.)

Recounting in this system is much simpler than you might imagine. As the count progresses and votes are transferred and discounted or sampled, the physical ballot papers are bundled and piled separately. Recounting means checking each bundle to make sure that it contains the number of papers it's supposed to and that it contains no miscategorized ballots — the rest is simple arithmetic.

There is some dispute over what should happen to transferred votes when the next preference is a candidate who has already been elected. It isn't important which exact system is used so long as those votes don't get a free onward transfer without being subject to the same discounting or random selection that the other ballots for that elected candidate had to suffer. (Ireland, again, does this wrong.)

One final warning about STV: If you end up with a government who ruins the economy, you can no longer blame your antiquated, easily-abused voting system. There is therefore no easy way to avoid the unpleasant conclusion that you got the government that you deserved, good and hard. Cognitive dissonance will keep people searching for a more palatable explanation, which might not be a healthy one for the nation.

2010-03-01

PoS3

As an owner of a Sony Playstation 3 console and a user of the Playstation Store, I have recently joined the Registration of the trophy information could not be completed. The game will quit. (8001050F) club. When this first appeared, the system time reset to Dec 31 and a decade ago. Now I can't sign in to the Playstation Network or even run Assassin's Creed 2 (a game with no network features). Sadly, resetting the time manually and trying again didn't fix anything. Neither did disabling the Internet connection setting. So it looks like the major symptoms are not causes. Something else is broken.

The timing (2010/03/01) and the clock-reset have led to widespread speculation that it's a Y2.01K event, which seems plausible. It's reinforced by the news that this doesn't affect newer ("slim") PS3.

I have a horrible feeling that Sony is trying to put off confirming another rumour: that the clock-reset has tripped a DRM wire, and that the PS3s are now defying their rightful owners in the mistaken belief that we are all freeloaders. Part of me hopes this is the case, because it will be a large stake in the heart of this trespass-on-owner's-property DRM that has become popular in recent years. We might even get a judicial precedent out of it.

Another part of me just wishes the best of luck to my unknown colleagues in Sony who are doubtless trying desperately to save the product line. Good luck, guys.