The other notebook

Last time I mentioned there was a second notebook, on a Hamiltonian for two molecular fragments. Here it is: sixty-two pages, 1996, same first year of doctoral study.

This one isn’t mine in any originating sense, and the first page says so. The Hamiltonian belongs to Brocks, van der Avoird, Sutcliffe and Tennyson, who published it in Molecular Physics in 1983. What the notebook contains is a reconstruction of it, from the beginning, by someone who had decided that reading it was not going to be enough.

The problem is two molecules coming apart. You want to track how each fragment tumbles and how they orbit one another, without hauling around every coordinate in the system. The trick Brocks and company use is to nail your reference frame to the line joining the two centres of mass. That costs you one of the three angles you’d normally need and buys an enormous simplification.

It also breaks something. The total angular momentum you get out of that frame isn’t angular momentum. Its components don’t commute the way they must. Its square isn’t the sum of its squares. It looks like the real thing and behaves like the real thing in most of the places you’d check, and then it doesn’t.

On page thirty-seven the kid notices. He writes down both failures, cites the appendix where the original authors say the same, and gives the object a name — a pseudo-angular momentum operator. Then, against the second failure, he writes see later.

Fourteen pages on, he comes back and proves it. Fifty-four terms, which he expands by hand, and which collapse to four. The square differs from the sum of squares by exactly one stray term, and that term turns out to be absorbable: wedge a sine between the two halves of the middle factor and the discrepancy regenerates itself for free. The anomaly isn’t an anomaly. It’s the weight that belongs to the coordinates, showing up as a correction because he’d written the operator without it.

I would believe a twenty-one-year-old who spotted the problem. I am less sure I’d believe one who flagged it forward and then kept the appointment.

Claude and I checked the whole thing, thirty years late — read every line, re-derive it independently, don’t accept a result because the next page assumes it.

Nine slips in sixty-two pages, and they’re all one kind of slip. A symbol goes missing in transit: three dropped squares on page three, a minus sign mislaid on page ten, an ħ/i that falls off a summary line. In every case the next line has it back. Nothing is ever wrong for longer than it takes to write the following equation.

One exception, on page fifty-seven, where a factor of two gets carried twice into a boxed result and stays there. It didn’t reach print; the published version has it right.

There are four places where he’s gone back to a finished page, found a slip, struck it out — and then, not trusting the strike-out, written the correction again on the facing blank page with an arrow pointing at it. (!) should read. There was no marker, no supervisor, no deadline, and no reader. He corrected himself twice anyway.

The notebook ends with a target rather than a result: the Schrödinger equation for the unimolecular dissociation of ketene may be attacked. Then QED, double-underlined, which is a confident thing to write at the end of something nobody was going to see.

Three years later that Hamiltonian is equation (1) of a paper in the Journal of Chemical Physics with my name on it. I checked this week, out of curiosity. The last box in the notebook, restricted to the case the paper actually computes, reduces to the paper’s equation (7).

The notebook is a PDF now.


Last time I asked whether this sort of work was necessary or whether it was ritual, and said I hoped the answer was that people still do it.

This notebook answers the question, at least for me. The Krylov one made me competent and never appeared anywhere. This one made me competent and then turned straight into a paper — not because re-deriving a published Hamiltonian is publishable, but because somebody had to take a general result for two rigid fragments and bend it around methylene and carbon monoxide in particular. You can only bend something you have taken apart.

So it wasn’t ritual. It was the load-bearing part, and it’s completely invisible in the output. The paper cites Brocks et al., as it should. The sixty-two pages that made the citation usable appear nowhere, and in the ordinary run of things they go into a box in a garage and then into landfill.

What I keep returning to is the see later. He wrote a note to a version of himself fourteen pages in the future and that version turned up. Thirty years on I’ve done the same thing from much further away, and found him waiting, having left the working out where I’d find it.

Marking some homework

Another box in the garage, another notebook.

This one is from 1996, my first year of doctoral study, and it runs to thirty pages of Krylov subspace methods — conjugate gradient, SYMMLQ and MINRES — worked from first principles out of a 1975 paper by Paige and Saunders.

These are methods for solving Ax = b when A is far too large to invert. You don’t solve the system. You build a small subspace, find the best answer available inside it, then grow the subspace and go again. MINRES is the one that comes with a guarantee: the error never gets worse. You can stop whenever you like and know you haven’t gone backwards.

I did it by hand from the paper. No internet. A biro, a lot of evenings, cheap instant coffee, and a serum nicotine level I am not presently proud of.

Claude and I checked it, thirty years late. Two passes — read every line and re-derive it, then implement the recurrences exactly as written and run them against a direct solve.

The kid held up. I’ll keep calling him that — thirty years is enough distance for the third person, and it lets me hand him the credit and keep the mistakes.

All three algorithms land on the exact answer to about fifteen decimal places, on well-behaved systems and on the nasty indefinite ones that make conjugate gradient fall over.

There are four errors in thirty pages, and not one of them is a wrong answer. Every one is a place where I asserted something true without a valid argument for it — a proof by obviously, where the obvious thing happened to be right. That is the better direction to fail in, and roughly what the next three years were for.

Twice he writes something down and admits he hasn’t earned it. I presume this could be sought by a little induction. I recommend verifying this progression formulation before implementing it! Both turn out to be correct. Knowing which of your own steps you haven’t proved is not nothing at twenty-one.

My favourite thing in there isn’t a mistake at all. Paige and Saunders describe a certain 2×2 matrix as a rotation. On page 8 the twenty-one-year-old has stopped, taken its determinant, got −1, and noted that it is in fact a reflection. He was right — and it pays, because reflections are their own inverse, and he leans on exactly that twice in the pages that follow. He didn’t take the paper’s word for it, and got something for the trouble.

The whole thirty pages exist to reach one line. Everything on the right of it is a sine, and no sine is bigger than one, so the residual is a shrinking product and cannot grow. The quantity that makes conjugate gradient blow up — a division by a cosine — cancels in the very last step.

I don’t remember writing the detail. I remember the nights.

The arithmetic is still good, and the notebook is a PDF now.


I’m not posting this out of vanity, and it isn’t a back-in-my-day grumble. There’s a point in it, and some questions.

Thirty years ago the price of a technical PhD was building your own toolbox. Not reading about the tools — deriving them, from the original papers, until you knew why they worked. This notebook and one other, on a Hamiltonian for two molecular fragments, levelled a small rainforest in scratch paper before I wrote out the 90+ pages of neat final versions.

None of it went into the thesis. Not a line. The algebra would have made far better eye candy than most of what did.

So: does anyone still work this way? Was it necessary, or was it ritual? And where does that work go, given it made me competent and made no publication?

I ask in hope rather than complaint. I want the answer to be yes, they still do — because I think that is how you build a scientist. You put in the work and it makes your mind stronger, even when the particular quest has nothing to do with where you end up.

A Maclaurin in my garage?

Rummaging through my garage, I found a box of old notebooks. One of them has three pages dated 11 April 2005.

I’d been in a seminar. I have no memory of what the seminar was about (probably some boring corporate stuff) and I’d clearly stopped listening early. What I did instead, over about an hour, was work out how to tell whether a list of numbers had come from a polynomial — and if so, which one.

The method goes like this. Write the numbers in a row. Difference each neighbouring pair to get a shorter row. Do it again. Keep going until the row is constant. The number of passes gives you the degree; that constant, divided by the same number factorial, gives you the leading coefficient. Subtract the term off and go round again for the next one down.

So 13.5, 33, 74.5, 147, 259.5, 421 collapses to 9, 9, 9 after three passes. 9 ÷ 3! = 1.5. Peel off 1.5x³, repeat, and out comes 1.5x³ + 2x² + 3x + 7.

Which is correct. Claude and I checked, twenty-one years late. The arithmetic holds and so does the method.

Then we went looking for whoever got there first, because I’d written, in that same hour, “I am sure this has been considered by someone else many moons ago.” Fair — though centuries would have been a better word than moons.

It’s Newton and Gregory, in the 1670s and 80s. Not Babbage, which is where I’d have guessed: Babbage’s Difference Engine ran the same idea forwards, grinding out tables from differences it already had. I was running it backwards, recovering the polynomial from its output. The engine isn’t the theorem.

Just because people did it 300 years before doesn’t make me wrong. I did this from scratch — no Wikipedia, no Google, just a biro (remember those?) and a seminar I’d disengaged from. Looking a thing up and reconstructing it are different exercises, and only one of them tells you whether you understood it.

And I’d signed off with one more line: “I think this process is ‘Maclaurin in reverse’!”

Colin Maclaurin — Scot, mathematician, dead since 1746 — has his name on the series you get when you expand a function around zero. What I had no way of knowing without leaving that seminar is that Brook Taylor derived the whole family of those series from the calculus of finite differences, in 1715. The discrete came first. The smooth version fell out of it as a limit.

Which makes that line less a quip than a conjecture. And a correct one — more or less a statement of Newton’s forward-difference formula, arrived at by someone who was bored.

No McLaren in the garage, then. But a Maclaurin appreciates.

Full write-up, with the proof I said would “have to wait for a bit”

Persymmetry, eventually

Back in my chemistry-PhD days — modelling how molecules fly apart — I kept running into a tidy sort of matrix called a circulant. I spotted a small pattern hiding in them and, around 2011, wrote it up. Then life did its thing: work, moves, the usual entropy. The write-up went in a drawer, and somewhere along the way I lost the original .tex file completely.

This year, with my stack finally empty (see: Writing again), I dug it out, rebuilt it from an ancient PDF, and checked the maths until the computer and I agreed to about twelve decimal places. Then I sent it to a journal. Desk-rejected — no review. I tried a second, a third, and a fourth.

Nobody quite warns you that this kind of rejection isn’t a ruling that you’re wrong. It’s a ruling that you’re not new enough. The result is correct, and apparently rather elegant — but circulants have been thoroughly adored by mathematicians for a century, and “correct and elegant” doesn’t always earn a slice of a journal’s attention. Fair enough.

I could have kept knocking on doors. I didn’t fancy it. (arXiv, the usual home for these things, now wants an institutional sponsor I don’t have — the perks of being an unaffiliated, semi-retired bloke who does crowd control for beer Sprite money.) So I did the unglamorous, oddly liberating thing and published it myself, with a proper DOI, free for anyone to read.

It’s finished. It exists. It has my name on it and a permanent address. That’ll do.

→ Spectral persymmetry of complex circulant and skew-circulant matrices

Binomial compression algorithm

Over a decade ago, I had to fly for work quite frequently. Streaming wasn’t really a thing back then, which left me only reading and writing to alleviate boredom. Once in a while, I would mix things up and think about maths problems.

I recently unified some of those airline thoughts; Python makes prototyping easy. I have opened up my GitHub repo a little. Constructive feedback is encouraged.

Edit (Jan 2026): I swapped from Python to Go. Email me for repo details.