Rob Heaton
Rob Heaton

Software Engineer
One track lover/Down a two-way lane

Quantum Annealing, or, Do Weird Stuff

11 Feb 2013

To some degree, in some way, on some level of consciousness, people try to optimise their lives. We try and work out what amount and type of food, sleep, drink, work, rest, play and people make us happiest. Depending on the level of fixation and bloody-mindedness of the individual, these investigations are conducted with a certain level of deliberateness. Some pay detailed attention and draw careful inferences, some give little conscious mind, and the Quantified Self guys measure Chi-Square correlation between their breakfast and their socks.

To change the subject somewhat, a hill-climbing algorithm is one where you try to find the maximum point of a function, such as the amount of sleep you should have per night, in the same way that you might crudely try and reach the top of a mountain.

  • Work out which direction takes you most steeply upwards
  • Walk 1 step thataway
  • Repeat steps 1 and 2 until…
  • If all directions lead downwards then you must be at the top of the mountain. Have your sandwiches.

On mountains with a single peak, this process will be an effective if at times bizarre sherpa. But on some pathological ranges you risk hiking your way up to a “local maximum” – a point higher than all its surroundings (satisfying step 4), but lower than another “global maximum” point a small valley away. It’s as though you were hiking in dense fog – you can only make very short-sighted judgements about the overall map of the terrain.

Hill climbing computer scientists trek their ways out of local minima by quantum annealing. In an energy- and fibre-providing nutshell, a quantum annealing hill climb is one where you climb the hill as above, but occasionally teleport a few hundred metres to the North East to see what things are like over there. If you end up somewhere higher than where you came from, you stay and continue the ascent, otherwise you beam yourself back and keep climbing. You explore a richer cross-section of the range, and so will in all probabilty reach the very peak of the mountain, fog be damned.

The pedestrian, step-by-step hill-climbing approach is guaranteed to get you somewhere that is better than the obvious alternatives. Maybe getting up at 6:45 is better for you than getting up at 6:30 or 7:00. You get a small jump start on the day ahead, but still get a big chunk of sleep. The traditional mountaineer inside you looks left and right and decides to hang up his pickaxe.

But then the mad, quantum annealing scientist climbing quietly alongside him seizes the pickaxe and drives it into his partner’s foot, seriously but not fatally wounding him. He decides that tomorrow you will wake at 2:30am and see what that is like.

It is horrible and results in disaster, acrinmony and lawsuits. No matter. You go back to getting up at 6:45 for the next week, and then Dr. Mephisto decides that tomorrow you will rise at 5am. You aren’t happy about this, but he’s got a pickaxe.

5am turns out to be incredible. There’s very little point in waking up a few minutes earlier here and there, which is why the conventional climber pitched camp at 6:45, but the big slug of extra time that 5am gives you opens up crazy possibilities you could never have dreamed off. You thank the doctor and set to work on your first novel.

Maybe working from home, working from someone else’s home, giving up gluten, taking up gluten, wearing a hat or wearing 4 hats will make something awesome happen for you. Even if things seem pretty good where you are now, you might be stuck on a trifling mound whilst a towering peak looms over you just a few foggy metres away. Practice quantum annealing. Do weird stuff in case it works.

Get more posts like this: