Culinary statistics

Food chart

The above demonstrates why I find myself eating so many Kimchi Noodle Bowls and cheese sandwiches. It also helps to reveal why the avocados I eat tend to be either unripe or over-ripe, though the shape of the blue curve is the inverse of what would be rational (barring the sheer drop at the end).

Heat: How to Stop the Planet from Burning

Ottawa wooden sculpture

During the past two years, I have been reading about climate change for several hours every day. During that span of time, I have read dozens of books and hundreds of articles. Quite possibly, none were as thought-provoking as George Monbiot’s Heat: How to Stop the Planet from Burning. If you are at all serious about understanding the issue of global warming, it is essential reading. He may not be right (indeed, it would be far preferable for him to be wrong) but he will definitely make you think.

His project is an ambitious one. Having decided that global temperatures must not be allowed to rise by more than 2°C on average, he works out what that would mean for Britain. Since British emissions per capita are way above the world average, a fair system would require much heavier cuts there than elsewhere. Canada’s per-capita emissions are even worse.

Here is a smattering of what he says will be required by 2030:

  • A power grid dominated by renewables and natural gas plants with carbon capture and storage.
  • Dramatically, dramatically tightened building regulations – making most houses either ‘passive’ in their non-use of heating or cooling or capable of producing their heat and power from piped-in hydrogen, possibly supplemented by solar.
  • Most private automobile travel replaced by a buses or non-motorized transport, both within and between cities.
  • An end to cheap air travel: no more low cost flights, with massive total cuts in the number of both short and long-haul flights.

The last is the result of a complete lack of alternative technologies that can deliver the kind of emission reductions required. Even if all other emissions were cut to zero, growth in air travel would make that one sector break his total limit by 2030.

Suffice it to say, Monbiot is not in the main stream of this debate. The Stern consensus is that climate change can be dealt with at moderate cost. Even if Monbiot’s ideas are entirely possible, in terms of engineering, one cannot help but doubt that any political party in a democratic state could successfully implement them. The impulse to defend the status quo may turn him into a Cassandra.

In fifty years, it is possible that people will look back at this book and laugh. Alternatively, It may be that they look back on Monbiot as one guy who had approximately the right idea while everyone else (Gore and company included) were in denial. The answer seems to depend upon (a) whether emissions need to be cut as much and as quickly as he thinks and (b) how bad it will actually be if they are not. It is pretty easy to do the math on the first of those, at least for any desired greenhouse gas concentration or temperature change. The latter is harder to assess. Regardless of which proves to be closer to the truth, this is a book I wholeheartedly endorse for anyone trying to keep abreast of the climate change issue.

Diesel and axles

Every morning, I get woken up at 6:30am as the first major rumblings of morning traffic overwhelm my earplugs. You would expect this to be a negative feature of my new dwelling, but it is actually quite a wonderful one, in its way. You see, I get woken up, look at my phone, and realize that I can sleep for another hour and a half and still have time to shower, eat breakfast, and be at my desk by 9:00am.

Even when I went to sleep just two hours before the truck-induced waking, having those ninety minutes feels like a luxury.

Strengthening substitution ciphers

Fountain in Gatineau

The biggest problem with substitution ciphers (those that replace each letter with a particular other letter or symbol) is that they are vulnerable to frequency analysis. In any language, some letters are more common than others. By matching up the most common symbols with what you know the most common letters are, you can begin deciphering the message. Likewise, you can use rules like ‘a rare letter than almost always appears to the left of one specific more common letter is probably a Q.’ What is needed to strengthen such ciphers is a language in which words have no such ‘personality.’ Here is how to do it:

First, take all the short words (less than three letters) and assign them a random three digit code. Lengthening very short words further strengthens this approach because short words are the most vulnerable to frequency analysis; a single letter sitting with spaces on either side is probably ‘a’ or ‘i.’ Using three digit groups and 26 letters, you can assign 17,576 words. Now, take as many words from the whole language as you want to be able to use. For the sake of completeness, let’s use the entire Oxford English Dictionary. The 456,976 possible four letter groups more than suffice to cover every word in it, leaving some space for technical terms that we may want to encrypt but which might not be included. If we need even more possibilities, there are 11,881,376 five letter combinations.

This approach is cryptographically valuable for a number of reasons. Since the codes representing words have a random collection of letters, the letter frequency in a ‘translated’ message is also random. You no longer need to worry that some English letters are more common than others. Just as important, there are none of the ‘Q’ type rules by which to later attack the substitution cipher. The dictionary of equivalencies would not need to be secret; indeed, it should be widely available. Having the dictionary does not make encrypted messages more vulnerable, since they will have passed through a substitution cipher before being distributed and are fundamentally more robust to the cryptoanalysis of substitution ciphers than a message enciphered from standard English would be.

In the era of modern algorithms like AES, I doubt there is any need for the above system. Still, I wonder if there are any historical examples of this approach being used. If you have a computer to do the code-for-word and word-for-code substitutions, it would be quite a low effort mechanism to increase security.

Bad design and the Nokia 6275i

The way my Nokia 6275i stores text messages is very stupid. To begin with, it can hold 100 of them. Whether the internal memory (32 megabytes) is completely full or empty, that is the number. The message “hi” uses up a slot, just like any other message would. If you can use the internal memory for photos or videos or ringtones, why can’t you use it for text messages? 32 megabytes is enough for several novels worth of text.

Also ill considered is how it deals with the limit. You have three choices. You can set up the phone so that, once it is full, it explains this fact to you whenever someone sends you a message, which it does not store. Alternatively, you can tell it to automatically delete messages from your inbox, sent items, or both. If you set it to overwrite inbox, it slowly fills with sent messages, until you have 99 messages in the sent folder and can only keep one in your inbox at a time. If you set it to overwrite sent items, the converse occurs. If you set it to overwrite both, it lets the inbox fill while still deleting all sent messages. Keeping at least the last five of each would be far more sensible. Often, you send someone a message and – an hour later – get a response that only makes sense if you still have (or still remember) exactly what your original message said.

If you want to ensure that a particular message not be deleted, you can put it in your ‘archive.’ It still uses up one of your 100 slots, but at least it will not be deleted by the over-writing algorithm.

Finally, if anyone sends a message of more than 160 characters, it just deletes all the text beyond that. Every Nokia phone I had previously would split overly long messages into multiple versions. With this phone, written conversations with some people take on the feeling of reading a heavily censored CIA document.

To Nokia’s software engineers: please try to be less obtuse in how you design the critical functions of your phones. Those of us who send more than thirty text messages a day consider it a key feature. A few sensible changes will leave your customers a lot less annoyed.

Peak power, storage, and renewables

Power tower

One characteristic of electricity poses severe challenges both for the drive towards lower carbon emissions and towards more power based on renewables: the fact that supply must precisely match demand at all times. On account of this, power plants are divided into two categories – base plants, which constantly provide the amount of power normally demanded by homes and businesses, and peaker plants, which provide some extra juice when everyone decides to turn on the air conditioning at once.

The first reason this is a problem is that peaker plants are much less efficient. It is costly to build an efficient oil or gas plant, and it just isn’t worth it to do so for one that runs relatively rarely. The second problem is more to do with the inconsistent nature of renewable power; the wind does not always blow and the sun does not always shine. As such, we need enough on-demand energy (usually based on fossil fuels) to fill the gap between what windmills can produce at time X and what consumers demand then. Plants on standby may not use much fossil fuel, but maintaining and operating them uses resources in a way that makes renewable options less appealing than otherwise.

The answer is obviously energy storage. We can build dams with two reservoirs, one uphill from the other. When power is in excess, we can pump water from the low reservoir to the high one. It can then be passed through turbines at times of peak demand to recover energy. Apparently, this can be done with efficiency of about 85%. Other options along these lines would be to have clusters of offshore wind turbines that use electrolysis to make hydrogen from seawater. That can be piped or carried to shore and used to produce carbon-free energy.

To me, it seems like another option is to use technology and incentives to help moderate power demand. If there are industries that can use a lot of power or a little, switching easily, then should be encouraged to become part of the swing capacity. It may even be worthwhile to store energy as heat in sinks or as kinetic energy in flywheels. If houses could heat or cool a block of material at the time when power is cheapest, then use that potential for heating or cooling across the day, we might need less peak capacity.

Some kind of competition for inventing fossil-fuel-free peak-power solutions may well be in order. If the technology exists, and there is enough of a cost differential between times of highest and lowest demand, it may well transpire that infrastructure can be built to normalize power demand on the scale of days, or even weeks.

Happy birthday Dad

Today is my father’s fiftieth birthday. Unfortunately, the circumstances of employment have placed us 5,000 kilometres apart, with my mother closer to me than to him at the moment. Hopefully, he and my brothers will be able to get up to something exciting in Vancouver.

All the friends of mine who know my father know what a unique and energetic individual he is. Whenever I am in Vancouver, he tries to recruit me for 6:00am hikes every other day. Hopefully, the near future will include a few of them, some wilderness canoeing, or another expedition like the one we made to Turkey.

In any case: mnohiya lita, joyeux anniversaire, and many happy returns.

The Khazzoom-Brookes Postulate

Ottawa war memorial

Reading through George Monbiot’s Heat, I encountered the idea of the Khazzoom-Brookes Postulate for the first time. The postulate relates to the effect of increasing energy efficiency on total energy usage and holds thas as the energy efficiency of industrial processes increases, total energy use actually rises as well. While initially counter-intuitive, the idea does seem to have some validity. If the energy cost of producing one tonne of aluminum falls from $5000 to $4000, you would expect aluminum companies to produce more. After all, their profit margin will have widened, all else being the same. The Celsias blog cites another example: if Boeing’s new 787 Dreamliner is 20% more fuel efficient, that just means that ticket prices will fall and more people will fly. Greenhouse gas emissions will stay the same or rise.

As Monbiot acknowledges, the postulate is controversial. It is certainly decidedly inconvenient for all the people who trot out ‘increased energy efficiency’ as the first (painless) means to combat climate change. Increased energy efficiency may be great for various reasons of convenience and enjoyment, but the postulate and accompanying logic does give one reason to doubt whether it can have a positive effect on reducing greenhouse gas emissions.