Holiday Reading #2

book-reviews

After the rather dreary spy novels, time for something a bit more fluffy.


The simplex algorithm: warm-up

constraintsmathematics

Pathetically slow in starting work on my little constraints project as I am, here’s the first of what should be a long series of posts...

One of the constraint solvers I’m looking at starting from, Cassowary, uses what is essentially an extended version of one of the most venerable of optimisation algorithms, Dantzig’s simplex algorithm. I’m going to start off thinking a little bit about the general setup of the kind of linear programming problems that the simplex algorithm is designed to solve, just to get a geometrical feeling for how these algorithms work and to understand the issues that might arise from relaxing some of the assumptions used in them.


Holiday Reading #1

book-reviews

I did a spot of reading over the Christmas and New Year holidays. In fact, reading was more or less all I did. Apart from walking the dog, spending time with Rita and eating myself silly. I read enough to write a lot of book review posts, but I’ll restrain myself to three or so... First off, spy stories.


AI Class Wrap-up

AI

One thing that came to an end over the Christmas holidays was the Stanford Artificial Intelligence course. The final exam was on the weekend of 17/18 December and final grades were distributed a couple of days later.

Overall, it was an interesting experience, and I certainly learnt some things. The instructors (Peter Norvig and Sebastian Thrun) were enthusiastic and clearly extremely knowledgeable, and they took on an extremely challenging task in trying to run an online class for tens of thousands of students. For that, I’m very grateful. There are a few things that weren’t 100% ideal about the presentation of the class material, but that’s to be expected the first time out with something like this.

The highlight of the course was definitely Sebastian’s presentation of his work on self-driving cars. I’d heard a bit about the DARPA Grand Challenge before, but I hadn’t known about the progress that the Stanford team had made with self-driving cars in traffic. That’s really impressive work, and Sebastian did a nice job of relating the algorithms used for guiding cars to the simplified versions considered in the class.


Thirty Day Challenges

colophonia

Looking for a prod to jolt me out of an (involuntary) 45 day blogging hiatus, I’m going to follow a scheme that Rita is using quite successfully: the Thirty Day Challenge. The idea is simple. Just do that thing, whatever it is, every day for thirty days. The timescale is short enough not to be daunting, but long enough to be habit-forming. Or that’s the theory anyway.

I have a few things lined up, including a slew of book reviews of my holiday reading and the creakingly slow commencement of my constraints project, but we’ll see how it goes.

OK, one down, 29 to go. That wasn’t so hard after all!


Oh Canada...

regrets

I miss Canada.

I miss sea kayaking.

I miss mountain biking.

I miss CrossFit Taranis and all the awesome people there.

We moved to France. Dumbasses. We exchanged a fantastic life in Canada for what? Basically: cheese. Feel free to mock us. We deserve it.


A project: Constraints

constraintshaskellprogramming

I’ve recently started making some tiny contributions to Brent Yorgey’s Haskell diagrams library, mostly bug fixes. The bug fixes are primarily just a way of familiarising myself with the diagrams codebase though. I have my eye on a rather chunkier task in the open issues list. That’s writing a constraints solver for diagram layout. I’ve been interested in this sort of problem for some time, and have never had a good reason to get down to it, so I’m going to see what I can come up with.

And I’m going to try something I’ve not done before, which is to document experiments, design and development as blog articles. It may all turn out to be hideously embarrassing, it may end up that none of what I do actually makes it into the mainstream of the diagrams library, but having to write about what I’m doing will keep me honest, force me to be clear about what I’m doing, and will provide an incentive to work on this stuff.


Saturday Morning Linkfest

Haskell

Stanford CS240h: Functional Systems in Haskell
Stanford is really pushing e-learning at the moment, what with the AI, machine learning and database classes that the engineering department is running. This is another good course with content available online.

Reddit: What does your company use Haskell for?
What it says on the tin: quite a few people chime in. Seems like Haskell isn’t so much of an “academic-only” language any more!

Storage and Identification of Cabalized Packages
Very helpful guide to GHC package management from Albert Lai.

Unused constraints in GHC
This week, we spotted an interesting thing in some of the diagrams code. There are a bunch of places where an earlier implementation of a feature required certain type class constraints. With a more recent implementation, that requirement has now gone away, but the constraints remain in the code. That makes using these particular functions trickier than it needs to be. We’d like for the compiler to warn about these extra un-needed constraints, since otherwise they just hang around like a bad smell. Brent describes it as “a nice project for someone wanting to dig into hacking on GHC”...

The other culture

Money (via Crooked Timber)
Where does it come from? There’s a nice little Just-So story that money arose naturally out of barter economies as a natural consequence of Immutable Economic Laws. It’s thus slightly embarrassing that anthropologists haven’t found any evidence at all for barter economies of the required type. Cue immense academic pissing contest, of course. Read it all. It’s good.

Cool stuff

Visual 6502
Remember the 6502? Come on, no need to be shy. The other 8-bit processor from the 1980s. I was a Z80 boy myself, but I did a bit of 6502 assembler programming back in the day (for my A-Level computer studies project, I wrote a little data capture package for an infra-red spectrometer in our school’s chemistry lab using the A/D ports on a BBC Micro). Any other fans of retro 8-bit should take a look at this site. They’re building sub-gate-level simulations and visualisations of old microprocessors. The visualisations are very neat, but the way they’re doing it is the kicker–working directly from dies, they’re photographing them, doing some image analysis to get the patterns of the chip layers out and using these to build transistor-level models of the chips. Lots of fun!

Circos
You may have seen those super sweet circular charts floating around in some biology papers in Nature or Science. This is where they’re made, and you can make them too.

Quasicrystal animations
This is “Haskell” too, but it lives in “Cool stuff”.


Friday photo #4

photos

Kairouan Great Mosque

Great Mosque, Kairouan, Tunisia. April, 2005.


In Defence Of Dogs

book-reviewsdogs

Science dog is tired

by John Bradshaw

Those of us who live with small furry friends have a vested interest in understanding what our beasties are thinking. They don’t talk, they won’t use SurveyMonkey, and they sometimes act like they’re not human at all, no matter how we might like to think of them as little people in dog costumes. But never fear. There is a whole industry out there that promises to help you interpret your dog’s slightest ear flick and nose twitch, that will allow you to correct all “undesirable” canine behaviours back to the acceptable human norms, that will turn you into a veritable Dr. Dolittle.

Just one little problem. Most of what you read is wrong, and quite a lot of it is harmful. Dominate your dog! Tame the wolf in your home! Show your pooch who’s boss! All complete crap, based on romantic story-telling and what makes good TV, rather than on decent science.

In In Defence Of Dogs, John Bradshaw, a researcher in canine behaviour at the University of Bristol (although he has appeared on TV, including The Colbert Report!) presents some of the recent thinking on dog behaviour, based on, of all things, scientific research.


Blowing Stuff Up! For SCIENCE!!!

science

via the MIT Technology Review Physics arXiv Blog

Everything’s better in slow-motion, right? And everything’s even more betterer in super-slow-slow-slow slow-mo, am I right? (You know I’m right.) It turns out that if you have a high-speed (10,000 fps!) camera and a pile of C4 explosive, you can make some pretty cool movies. You can read about it here.

Particle jets

On a less explodey note, two other vids from this year’s Gallery are also pretty outstanding:

Bouncing balls

Bouncing balls on water!

Freezing drop

Freezey trees!


AI Class: Teaching the horde...

AI

Week four of the Stanford Introduction to AI class was about, well, what was it about? It was a bit of a mish-mash. Some stuff about logic, some stuff about planning. Nothing I can really pin some experiments on, so I’ve been thinking a bit about the format of the course instead.


Hippo in da house...

I kept trying to tell Rita that a hippo would make a perfect pet. She didn’t believe me. But then she sent me this. Point proven, I think you will agree...


Mathematics and Logic

book-reviewsmathematics

by Mark Kac & Stanislaw Ulam

This interesting little book, published in 1968, is the result of a collaboration between two of the great figures of 20th century mathematics. Although known mostly for his work on the Manhattan Project and later associated applied mathematics efforts (I first learnt of his work after being told to read about the Fermi-Pasta-Ulam problem by my PhD supervisor), Ulam began his career as a pure mathematician, working on problems in general topology. (His autobiography, Adventures of a Mathematician, is well worth a read.) Kac, best known for asking “Can one hear the shape of a drum?”, made major contributions to probability theory. Kac and Ulam got to know each other in Poland, then both made the move to the United States during the Second World War.


Calming Signals

dogs

What does it mean when your dog yawns at you? She’s tired? She’s bored? She’s embarrassed of your choice of socks? If you don’t know, you probably want to read Turid Rugaas’s book about the body language signals that dogs use to display unease and to calm each other down.