Colins Blog 2007

   
Recent changes
Table of contents
Links to this page
FRONT PAGE / INDEX

See also:

2007/11/29 Killing Bugs

I was thinking of writing something about the film "Mr and Mrs Smith", and how these days somehow it seems all right to talk about killing people for a living. It also seems all right to kill loads and loads of people in a dramatic, slightly comedic shootout.

How has this happened? How has killing people become entertainment?

And why is it all right to write code with bugs?

Well, perhaps it's a little overkill (sic) to talk about having bugs in code and killing people as being somehow similar. To do so is perhaps to show the same moral ambiguity as the producers/writers/directors who think wholesale death and destruction is entertaining.

Still, it made me think.

We all know that it's hard to write bug-free code. Some even go so far as to say that no code is truly bug-free. It's also observed that if you want a bug-free system then you need to verify the compiler, and the hardware, and use radiation hardened hardware, and even then you can't be sure there wasn't some glitch somewhere.

No, you can't be sure.

But nor should you accept the casual errors that could be caught by a different mindset. Part of the problem might be that people repeat over and over again that bug-free code is impossible, and that attitude somehow gets mutated into:

OK, so no one says that, but sometimes that's what it looks like. See for yourself. How much code do you write beforeyou test it? Aren't you just writing code, then catching bugs later?

Once Upon A Time it was drilled into students, and it was all over the literature, that the cost of finding bugs increases literally exponentially for each stage of work. It's cheap to catch a bug in the initial design, and hideously expensive after the system has been deployed. Clearly it makes sense not to debug code, but to avoid having the bugs in the first place.

And maybe that's the real value of agile techniques. In particular, Extreme Programming (XP) requires comprehensive, ubiquitous Unit Tests, because it allows, in fact requires, refactoring of code after each change to make it simpler.

XP also emphasises micro- implementation of features. Allied with Test Driven Design (TDD), tests should be written before code, then all the tests should be run to confirm that the code still passes them all, before it's checked back in and allowed to go live.

XP is often ridiculed for its self-admitted extreme attitude to known good practices. Is it denied that these practices are good? No. Is it denied that they are insufficiently practised? No. So why should we not use peer review of code? Why should we not have automated tests for our code? Why should we not remove duplication from code by abstracting out common functionality?

Why should we not do everything we can to avoid putting the bugs into the code in the first place?

Maybe we just need a change of emphasis. Maybe it shouldn't be called Extreme Programming. Maybe it's just the ABC of programming:

Avoid Buggy Code.

How? Well, here are some suggestions:

Hmm. That's starting to sound a lot like XP.


2007/07/26 Play time ...

I've been playing with my Site Map and Site Map Expt. I'm not sure it's any use, but it's an interesting exercise, and I'm learning things.

I'm especially learning that this site really is a big amorphous blob, and while there are "hub" pages ( Juggling, Mathematics, etc. ) there is no real structure.

But that's OK. I like it.

See also Random Quotations and Science Based Quotations, links I put here to connect them to the rest of the site.


2007/07/21 Doing without the crutches ...

After one of my Speaking Engagements I told my host that it was possible to make a dodecahedron out of 30 identically folded pieces of paper. The one I was thinking of is shown on the Paper Dodecahedron page.

The problem was, I couldn't remember how to do it ...

It was just so annoying. I folded a couple of modules and spent ages and ages trying to work out how to put them together. I couldn't. Then on the way back to the station that I realised I was missing the central fold. Damn.

Anyway, the question is, how can we keep our knowledge fresh? We can't review everything every day, but how can we keep our knowledge available and at our fingertips?

The internet is a fantastic resource. Search engines are just as fantastic, and maybe that's the future. But surely we should keep our own facilities sharp.

How?


2007/07/14 Context

A vegan friend of mine was on a walking holiday with some friends. They stopped at a youth hostel, and in the morning were gathering for breakfast. As always, some were morning people, and some less so, so arrivals were, let's say, sporadic.

My friend was tucking into a large bowl of muesli (as a vegan he tends to eat very large meals, and then still graze in between) when one of the other chaps came down and started looking for something. Neil asked what he was looking for, and the chap replied "Where did you find the milk?" Neil said, "I didn't - I used fruit juice."

The chap was aghast, absolutely horrified. Finally he exclaimed in utter disbelief, "You put fruit juice in your coffee!!!"

No, Neil had put fruit juice on his muesli. As always, he'd had his coffee black. However, the miscommunication shows that there are times when context is important. Sometimes it's critical.

The Germans are often criticised for being overly concerned with the planning and detail of an endeavour. Communications seem to be excessive, redundant, repetitive, and generally painful. They seem almost to be patronising in their repetition of well-known and previously agreed facts.

The French, by contrast, are often thought (especially by the Germans!) to be slapdash, brief to the point of being rude and dismissive. They often take for granted that you already know what they are referring to, and will understand their points from the merest hint.

These are sweeping generalisation, of course, and like all generalisations are prone to be false in any given case. But the general idea is sound. Some people assume less context, and their communications are heavy, staid, overly complex, and dull. Others assume less context, and are efficient, but run the risk of being completely mis-understood.

As can so often be the case, there is no right answer to this - it's a question of balance. Good balance requires good feedback.

Communication should be two-way.

That's why good writing is so hard.


2007/07/03 Worse off, despite leading...

Suppose a tennis player has a 95% chance of winning a given point on their serve. Amazingly, they have less chance of winning the game from 40:30 than they have from Love All, even though 40:30 means they are in front!

For reference, with 95% chance on each point, you have 99.991% chance of winning the game from love all, but "only" a 99.986% chance from 40:30. That's 0.005% less.

Miniscule, true, but you'd think it shouldn't happen at all.

This is the sort of puzzle that intrigues me. You can't believe it, then you do the sums and it turns out to be true! How amazing is that! Surely this is the sort of thing to inspire kids to study maths, to find out why it happens.

Then again, maybe not. Maybe some kids will be intrigued, but maybe others will have a strong adverse reaction. "Surely," they might say, "This is nonsense, and only goes to show how irrelevant maths is to everyday life. It can't be true, I won't believe it, and maths is stupid for claiming things like this."

Hmm. Perhaps some things aren't good advertising, even when they are true. The point is, though, that it is exactly this sort of result that shows we need mathematics. When your intuition leads you astray, maths can come to the rescue. It's maths that can confirm or refute apparently bizarre claims, and save you from wasting time, wasting money, and in extreme cases, can save lives.

If the last point seems a little OTT, wait till I tell you about the mathematics that would have prevented two pointless suicides.

Next time.


2007/06/19 Maths Attack!

images/ThalesTheorem.gif
See Thales Theorem.

2007/06/18 Pirates Of The Baroque

http://www.piersadams.com/images/indexRPwhole.jpg
Who are these strange people?
Went to another Red Priest performance/concert yesterday. Fantastic. Another bravuro performance that brought the music to life in an extraordinary way. There's a review on the Pirates Of The Baroque page.

The Red Priest pages on this site have now been reorganised a little. We now have the previous review on a separate page, with the Red Priest page itself reserved for more generic information. We've also added a Red Priest Concert Schedule page, so we can see where the concerts are in case there's a chance we can get to another one.

We certainly want to ...


2007/06/10 Science teaching in crisis?

http://news.bbc.co.uk/1/hi/education/6722653.stm
According to the BBC one in four schools do not have specialist physics teachers, and the government is failing to recognise and address the seriousness of the science teacher shortage in England's schools.

Let's look at some of the figures quoted.

Yes. Government figures for "new science teachers" include people signing up to start a textiles teaching course.

In 2006 it was, for the first time, possible to get a breakdown of teacher recruitment by subject.

But why do teachers leave? Well, try this:

There's more here:

It is suggested that a million children are now being taught physics by people who are not physics teachers. That's not only not fair on the children, it's not fair on the teachers.

Tony Blair has urged young people to become scientists. He said Britain must encourage young people who want to "change the world" to become scientists, and stressed the
http://news.bbc.co.uk/1/hi/education/6112402.stm
importance of Britain's knowledge-based economy. To keep it competitive, he said, more scientific pioneering was needed.

Despite this, during Mr Blair's time in power the numbers of young people studying physics and chemistry have dwindled by a fifth. And now a quarter of schools have no qualified physics teachers. This is a deficiency he acknowledges, but says he's trying to put it right.

Perhaps he believes that. Perhaps he's saying it because he thinks there are votes in it. Perhaps he's been told it's important. Who knows! Who knows what politicians really believe.

The government has many initiatives that are claimed to be targetted at improving science education, but until the students themselves see the subjects as important, interesting and exciting, nothing will happen.

Without interesting, exciting and able teachers, how can that happen?

Maths and physics can be among the most exciting subjects in the world. How can we get that message across? OK, so students find science and maths hard, but why do they think they're boring?

Dont Blame The Students. They need to see that science and maths are worth the effort.


2007/05/04 See Two And A Half Men


2007/05/02 I had thought better of the BBC.

Recently the BBC reported how schools are encouraging students to drop maths because it's hard, and makes the school look bad when they don't get good grades.

Leading on from that, they also reported how the Royal Society of Chemistry had set a challenge taken from Chinese university entrance tests.

The BBC followed this up with a report on the winner in their NewsNight programme.

I was astounded and appalled at the treatment this got. The entire issue was treated as a joke, and fun made of the person who won the prize. The slant was "You must be a genius", and the underlying attitude was clearly scornful, wrapped up with a good dollop of sarcasm.

At a time when the BBC themselves are reporting that standards in mathematics are dropping, that students are abandoning mathematics for easier subjects, and that science in general is in decline in the UK, how can they then produce and air a report in which the entire question of ability in maths is subjected to ridicule?

Perhaps the BBC doesn't think it actually has much influence. Perhaps it thinks that the images it portrays are largely irrelevant. Perhaps it thinks that ridiculing ability in maths won't affect the way people see the subject.

Or then again, perhaps it's full of media types who themselves can't do maths, and therefore have to poke fun at anyone who can. No wonder students are opting for easier subjects, when their attitudes are shaped by such heavily anti-science biased media.

I really had thought better of the BBC.


2007/04/25 Don't Blame the Students, Part II

Back in August 2006 I wrote Dont Blame The Students, pointing out that they were behaving rationally when they chose to drop maths and take easier subjects. It now seems that my points are being raised yet again, this time by the Royal Society of Chemistry.

It seems that their Chief executive, Richard Pike, has written a paper entitled "Why League Tables Have to Go" in which he says:

  • "Schools and students are reluctant to consider A-level mathematics to age 18, because the subject is regarded as difficult, and with league tables and university entrance governed by A-level points, easier subjects are taken."
  • "Increasingly, universities are having to mount remedial sessions for incoming science undergraduates because their maths skills are so limited, with many having stopped formal lessons in mathematics two years earlier at the GCSE level."

The Government counters, saying that the numbers of pupils studying science, maths and further maths was increasing.

So why are universities having to run remedial maths courses?

As I said earlier, Dont Blame The Students.


2007/04/21 What's the difference between ...

As I was doing some vocabulary work on the Lojban Language the other day I started to think about the differences between some otherwise very similar objects. What exactly is the difference between, say, a leaflet, pamphlet and booklet? What exactly is the difference between a bottle and a jar?

The one that prompted this little musing was this:

As I thought about this I canvassed others for their ideas and opinions, and there were two common threads.

Seems right and reasonable to me.

So why does McDonalds call itself a restaurant?


2007/04/19 And you are ... exactly ??

I've been thinking about this for a long time, and dealing today with my Spam Table has brought it to the surface ...

In the Regency period (1811-1820), probably much before, and certainly through the Edwardian period (1901-1910) it was, amongst the better circle, simply "not done" to speak to someone without first having been introduced. The rules were really quite rigid, with some leeway, and approaching someone without an introduction was a severe breach of the social norms.

In these "enlightened" times we rather look down on the rigid formality of the Regency, Victorian and Edwardian periods, but consider this. Many people are now implementing a similarly severe system for their email. More and more when I email someone, even someone of long-standing acquaintance but whom I've never emailed, I'm getting back an automated

"Who are you, and why should I listen to you?"

Of course in this case it's usually just enough to prove that I'm a person and not a robot, but it could be more severe, and it could be that we're turning full circle. Perhaps we should fall back to trusting only those who are personally recommended to us. Perhaps we should rely on "Friend of a Friend" networks, to ensure that we reclaim the usefulness of email.

Why not instigate a plugin protocol that lets us pass around email addresses with "certificates" saying who has recommended them. We can then implement a "trust" metric on that, so only trusted emails are let through to the inner sanctum. Other "throw-away" email addresses can be used for casual acquaintances, that may subsequently be "upgraded" to a more trusted status.


2007/04/18 Languages revisited ...

Just a quick note. I've started looking at the Lojban Language again for various reasons. Amongst others, it's potentially a great source of challenge cryptographic-style puzzles, and at the same time may provide a way for more mathematically inclined people to get into and interested in languages.

This relates, of course, to my thoughts on Learning Languages.


2007/02/21 Spam, spam, spam, spam, ...

I've been analysing the spam I've been getting lately, mostly in the hopes of improving my filters. I currently get around 2000 spam emails a day, and wading through them leaves me needing a shower.

You can see the graphs of spam volumes on Spam Table and Spam Graphs. The problem is largely of my own making, of course. I need people to be able to contact me in order to invite me to speak for them, so I need to advertise me contact details. Those are then harvested by spammers, and there we have thousands of unwanted emails every day.

I've put some filters in place, and currently only about 1% of spams get to my inbox. But how do I know if any legitimate emails have been filtered out? The nagging doubts remain.

Still, with the current growth of spam shown by the graphs, someone, somewhere will have to do something soon. In the meantime I'll tune my filters to get rid of the worst, and be ruthless with the rest. So if you send me email and I don't reply, maybe it didn't get through. Try again with a longer, more specific message.


2007/01/14 Updates ...

I've come to the conclusion that I'm not writing enough on this "blog". part of the problem is that I don't think my thoughts are sufficiently profound to inflict on the world, and part is that I don't get a lot of time.

But not having enough time is partly because I feel that I need to write important things, and I don't have the time to craft it.

So instead I'm going to write what I think about things that people might find interesting, and not worry so much about it being important or momentous.

Let's see what that does ...


Contents

 

Links on this page

 
Site hosted by Colin and Rachel Wright:
  • Maths, Design, Juggling, Computing,
  • Embroidery, Proof-reading,
  • and other clever stuff.

Suggest a change ( <-- What does this mean?) / Send me email
Front Page / All pages by date / Site overview / Top of page

Universally Browser Friendly     Quotation from
Tim Berners-Lee
    Valid HTML 3.2!