40 years ago, more or less: my first application

As the calendar clicks around, I’m reminded of an odd anniversary. Roughly 40 years ago – maybe late 1968, perhaps early 1969 – I wrote my first serious piece of software: a real application, used by real people, and constructed as part of my paid employment. I thought it might be worth revisiting that event.
The first thing you have to understand is that I’d had no computer-related education at all. The closest I came at the Royal Grammar School, High Wycombe, was an after-school seminar in the School Library, when somebody delivered a talk on computers. I’ve forgotten the content of the presentation completely; I only remember that the speaker passed around a core memory module for us to look at. (Hands up those who don’t know what “core memory” is, or how it works.) In the spring of 1968 I applied to Essex University to read Economics, and that summer I took GCE A Levels in Economics, Maths (A+S), and Physics. However I had already decided that it would be useful to spend what is now termed a “gap year” before going to university, in order to get some experience of the real world. Fortune (or nepotism) was in my favor, and I was accepted at the UKAEA Harwell to spend a year as a “Mathematics Assistant”.
I started in September 1968, and lived in a hostel (a barracks, really) in Abingdon. I was working for the Programmes Anaysis Unit (PAU), a group that was trying to understand the economic impact of government-sponsored research and development initiatives. We were interested in how quickly innovation spread through a marketplace, and what the return on investment looked like. I was the only assistant in a team of a couple of dozen eminent scientists and economists. They understood the policy issues, and most understood the mathematics. The challenge was gathering the data and interpreting it.
I started out on issues related to ROI. The models typically involved calculating the year-by-year impact of an investment, with each annual contribution discounted due to monetary deflation and substitution. I worked up a family of models of increasing complexity; for each one, I planned to accumulate the discounted annual contributions until the marginal return was less than some epsilon. But how to run them?
I was put in charge of the department’s Wang Programmable Calculator. The programming model was similar to more recent programmable calculators from TI and HP. The program memory essentially stored keystrokes, which were executed just as if you’d pressed them. Keystroke steps were numbered, and there were conditional and unconditional branch operations. For the Wang, the “program memory” was a pre-scored card, from which “chads” were punched out with a stylus; the card was then “read” in a device that looked like a small toaster. The output display used Nixie tubes
I programmed up my first model. It ran to completion in 5 minutes. My “second order” model took 30 minutes to finish. The “third order” model ran for four hours. When the “fourth order” model had not converged after an overnight run, I knew that I needed some better technology. My team leader, a physicist who had never recovered from the fleshpots of Cairo during the 8th Army campaign of 1942, directed me to the computing centre. There a rather startled young man with a huge red beard thrust a copy of “McCracken on Fortran” into my hand, created an account for me on the IBM 360/65, and showed me where the card punches were. Two days later, I’d completed all of the ROI calculations, and I was hooked.
In those first programs I used the 360 as a glorified version of the Wang calculator. I didn’t have to manage data sets, or design complex algorithms, or do anything for output beyond printing a single number. But the next job was different. Several PAU teams were interested in how technologies were taken up by a marketplace, and then (as now) it was assumed that adoption tended to follow an S-curve. Today, curve-fitting is a standard feature of every maths library, but in 1968 we were making it up as we went along. Furthermore we weren’t simply throwing a best-fit curve through a bunch of points: we had a number of exogenous constraints that we had to respect.
One of my colleagues came up with a nice set of linear transformations for the primary equations (Sigmoid and Gompertz), which meant that I could vary one parameter (usually the asymptote, which was constrained anyway) and use a linear fit to generate the other values. I demonstrated experimentally that graphing the residual errors against the asymptotes had a single minimum, so I was able to use a simple bisection approach to find the best fit. Some of the data sets were too big to fit in memory, so I added a buffered input reader to stream the data from the disk (or was it a drum?).
My first version of the program simply output the parameters of the S curve and the residual errors. This was OK for the mathematicians, but unsatisfactory for the policy wonks. I made friends with the red-bearded guy in the computer centre (who would later be my lecturer at Essex University!), and discovered that the IBM 360/65 was equipped for COM, or Computer Output on Microfilm. I cut-and-pasted some code from the COM system documentation, and augmented my application with full graphical output, showing the original data points (or bucketed samples thereof) and the various s-curves that corresponded to the different constraints.
By this point, I was more or less lost to the PAU. While I kept doing minor tasks for them, I spent 80% of my time in the computer centre, and by the time I left in June, 1969, I was helping teams from all over Harwell with their applications. I’d also moved on from punched cards to a teletype-based RJE system, which was only one step away from being a real interactive system. (For that, I had to wait until I encountered the PDP-10 in 1970.)
Meanwhile my application was used for a number of years. When I returned to a different branch of Harwell in the summer of 1971, I was asked by my old team to make several small enhancements. Naturally, I looked at the code I had written, and was mortified at how primitive it was. But it was my first, and self-taught to boot, so I cut myself some slack and fixed it.

Three excellent additions for a freethinker's library

I’ve just finished reading three books on a common theme: losing one’s (Christian) religion and becoming an atheist. All three are excellent, but each approaches the topic from a very different perspective. I thought I might review them all together, and post the combined review on each book at Amazon. I don’t know if this is consistent with the Amazon review policy, but never mind.
The first book is Godless: How an Evangelical Preacher Became One of America’s Leading Atheists by Dan Barker. I was slightly put off by the subtitle: “How an evangelical preacher became one of America’s leading atheists.” After all, one of the key points about atheism – and one that we have to keep reminding theists about – is that atheism is not an organized body of belief, it’s no more a religion than “bald” is a hair colour. So how can anyone be a “leading atheist”? Who’s being led? However if one substitutes “prominent” or “influential” for “leading”, we can let that pass. And Barker is certainly influential: he’s co-president of the Freedom From Religion Foundation, which is one of the most active groups working to uphold the Constitutional prohibition on church-state entanglement, and seeking to counteract the negative image of atheism in this country.
The second book that I considered was William Lobdell’s Losing My Religion: How I Lost My Faith Reporting on Religion in America-and Found Unexpected Peace. Lobdell is an award-winning journalist who covered religion for the Los Angeles Times. After writing about many aspects of religion for many years, he finally decided to write about his own journey.
The last volume in this trilogy was Why I Became an Atheist: A Former Preacher Rejects Christianity, by John Loftus. Like Barker, Loftus was also an evangelical preacher, but although the arc of his experience was similar to Barker’s, the result is a very different kind of book.
Let me begin by saying that each of these books is really good, and deserves a place in the library of anyone who is interested in the contemporary debate between religion and atheism. I hesitate to rank them, or recommend one over another; nevertheless I find myself compelled to do so. Of the three, Lobdell’s “Losing My Religion” is the most essential, for two reasons. First, he is an excellent writer, and his prose is simply a delight to read. Secondly, he concentrates on his personal experience in a way that I haven’t encountered before in books by atheists. Both Loftus and Barker set out to tell their story and argue their case, albeit in different ways, and each draws on writers as diverse as Dennett, Wells, Price, Martin, Shermer, Carrier and Nielsen in setting forth their arguments. Lobdell just wants to recount his own story, and what he has learned from it. He’s not interested in converting anyone, or scoring debating points. As he writes,

“To borrow Buddha’s analogy, I’ve just spent eight years crossing a river in a raft of my own construction, and now I’m standing on a new shore. My raft was made not of dharma, like Buddhism’s, but of things I gathered along the way: knowledge, maturity, humility, critical thinking and the willingness to face the world as it is, and not how I wish it to be. I don’t know what the future holds in this new land. I don’t see myself crossing the river back to Christianity… [or] adopting a new religion. My disbelief in a personal God now seems cemented to my soul. Other kinds of spirituality seem equally improbable. Besides, I like my life on this unexplored shore.”

For Lobdell, the thing which provoked his crisis of faith was people: the yawning gulf between the ideals of a religion and the lives of those who practice and – especially – lead it. The horrific abuse of young people by Catholic priests, and the way it was covered up, refutes the claims of religion in many different ways. In particular, it challenges believers to justify theodicy (the “problem of evil”), as well as the Dostoievskian idea of religion as a bastion against the chaos of amorality. In contrast, for Barker and Loftus, the unravelling of their fundamentalist faiths was due to ideas: to the incoherence of religious dogma, and its incompatibility with science and reason.
Both Loftus and Barker were preachers. There are many distinct aspects to being a preacher: the performance artist, leading a collective act of worship; the scribe and teacher, explaining and interpreting the texts and practices of the faith; and the counsellor and confessor. All of these roles have roots in the shamanic and magical. As a believer, Barker was a performance artist, and he remains so in his newly found unbelief. He encourages the closeted skeptic, and fights fiercely for the rights of the non-religious. Loftus is a scribe: the apologist, the teacher. He was the defender of faith against its critics, and with the detailed knowledge that he acquired in this role, he has become the sharpest critic of religious apology.. Each of their books reflects the way that they interpreted the role of preacher.
Both Barker and Loftus seek to encourage those who seek affirmation of their skepticism or unbelief. Barker concentrates on the emotional, the social: “you are not alone”, “you are not a bad person”. Loftus focuses on the ideas, the dogma: the Bible is riddled with inconsistencies, the supposedly biographical accounts in the New Testament are demonstrably fictitious, the attempts by contemporary theologians to construct a coherent interpretation of the contradictory mess are failures, and so forth. If you have read some of the authorities that Loftus cites – Mackie, Martin, et al – I would still recommend his book, because he pulls all of the threads together in a compact and accessible manner. If you are unfamiliar with the literature, Loftus may be all you need. (Add Hitchens for spice, of course!)
I recommend all three books.

Reality bites

While religious delusion seems to be on the increase back in Blighty, here in the US things are trending – modestly – in the opposite direction:

the percentage of Americans who believe that religion can answer society’s problems is at an all-time low, with only 53 percent saying religion “can answer all or most of today’s problems.”

[…]

Meanwhile, over the last several decades, the percentage of those who perceive religion as “largely old-fashioned and out of date” has been on a continuous rise. The latest poll found that 28 percent believe it’s old-fashioned.

But even so… 53 percent? That’s a dangerous level of delusion…

(Via Freethinker.

Harvard art at the Sackler

More photos.

Monet: The Gare Saint-Lazare: Arrival of a train (1877)
Monet: "The Gare Saint-Lazare: Arrival of a train" (1877)
Harvard University has embarked on a major renovation of its art museums, particularly the Fogg Museum on Quincy Street. During the reconstruction, they’ve consolidated some of their pieces in the smaller Sackler Museum on Broadway. On a beautiful (but chilly) morning, we decided to take the #66 bus over to Harvard Yard and see what the resulting exhibitions were like. Photography is (mostly) allowed, and the results can be found here. Yes, the first picture is of the Memorial Hall, not of the Sackler, but MemHall is always photogenic.
The high points: the extraordinary multimedia installation by Leonardo Drew; the Monet shown at the right, and a carved stone panel that matches a series of rubbings that Merry has had for years.
(I have to say that I’m really enjoying this Panasonic DMC-TZ4. 8.1MP is ample, and I rarely have to venture out of “iA” automation mode to get the picture I want. It’s a delight to use; the only design flaw is that the microphone is on the top surface, on the left, so sometimes I’ll block it when I’m shooting video.)

For family and friends

I’m in Brookline, Massachusetts for a week, and yesterday we went up to Lynn to see my daughter, her husband, and the two grandchildren. Normally at the end of December Lynn would be deep in snow, but yesterday the temperature reached 64F, and when we arrived the kids were playing in the yard. I took lots of pictures (posted here) as well as some nice video clips.

In the evening, Merry and I went for a walk by the Leverett Pond. I had brought my camera, but the light was failing and there seemed to be nothing much worth capturing. And then Merry saw a flash of white in the reeds: a heron. I tried full optical zoom (10x) on my Panasonic Lumix, but it was still rather small. I had always been told that electronic zoom wasn’t worth using, but I decided to try the “E-Zoom” feature to get up to 15.9x. I was impressed with how well the image stabilization worked at that level. You can see the results starting here. In the final shot the heron is actually taking off, which it was hard to capture with a 1/15 sec. exposure!

"Snow packed" by design – FAIL!

I’ve only been up to work a couple of times since the snow and ice first settled on Seattle. Even though I simply have to walk across the street from my apartment and take a shuttle bus up the hill, it’s a risky and stressful business. To someone from Boston, familiar with how urban snow removal is supposed to work, the scene is bizarre. The streets are covered in thick, deeply rutted ice. The sidewalks are mostly patches of slick ice and piled snow. Riding on the shuttle bus is a series of spine-jarring bumps, interspersed with barely-controlled sprints across the ice. And the reason? No salt. From the Seattle Times:

To hear the city’s spin, Seattle’s road crews are making “great progress” in clearing the ice-caked streets. But it turns out “plowed streets” in Seattle actually means “snow-packed,” as in there’s snow and ice left on major arterials by design.

“We’e trying to create a hard-packed surface,” said Alex Wiggins, chief of staff for the Seattle Department of Transportation. “It doesn’t look like anything you’d find in Chicago or New York.”

Damn right. Any DPW chief in the north-east who did such a shitty job of clearing the streets would be fired on the spot.

The city’s approach means crews clear the roads enough for all-wheel and four-wheel-drive vehicles, or those with front-wheel drive cars as long as they are using chains, Wiggins said.

The icy streets are the result of Seattle’s refusal to use salt, an effective ice-buster used by the state Department of Transportation and cities accustomed to dealing with heavy winter snows.

Fearing the environmental impact of salt, Seattle is relying on sanding instead. The trouble is that if you put enough sand down to actually make a difference, it clogs storm drains and creates nasty dust in the spring. The result: Seattle uses such a small amount of sand that it makes almost no difference. And they couldn’t really lay down very much sand (or salt) anyway: while Boston has 700 snow plows, Seattle has just 27.
By the way, Seattle’s police cars are all rear-wheel drive. Even with chains, they have difficulty getting along on major arteries, and most secondary streets are impassable to them. Let’s hope that the bad guys aren’t smart enough to buy AWD vehicles….
UPDATE: Responding to Jon’s comment: I do not wish to imply that Seattle should run out and acquire 700 snow plows and thousands of tons of salt to cope with a once-every-20-year event. That would be dumb. What I’m saying is that (a) the city should be honest about this reality, and (b) that it should use established best practices in using the limited resources that it does have available. Using sand without salt is just bad practice: the sand blocks storm drains, and pollutes. Salt – at least in the quantities that Seattle can afford! – is not going to be an environmental hazard.
Claiming that “we’re trying to create a hard-packed surface,” and “we decided not to utilize salt because it’s not a healthy addition to Puget Sound” is either dishonest, or stupid, or both.

More stupidity from back home in the UK

Not only is religion being co-opted by politicians in the UK (or is it the other way round?); it appears that creationism is making inroads. As The Bad Astronomer reports

A survey in the UK shows that about 1/3 of the teachers in England and Wales think creationism should be taught in science. About half think it shouldn’t be (one assumes the rest have no opinion), while 2/3 of the teachers think it should at least be discussed.

70% of science teachers think creationism should not be taught, which sounds good until you realize that means 30% of science teachers think it should be.

This story also provides a great example of how the same facts can be presented in diametrically opposite ways. The headline in The Daily Express read “THIRD OF TEACHERS WANT CREATIONISM”, while the Ipsos MORI report of the actual study was titled “Teachers Dismiss Calls For Creationism To Be Taught In School Science Lessons”.