Home | Articles |     Share This Page
Programming Handheld Calculators

A reminiscence about programming in the era before personal computers

— All content Copyright © 2012, P. LutusMessage Page

Introduction | HP-25 | HP-67/97 | Perspective | Digression | References | Reader Feedback

(double-click any word to see its definition)

Introduction

During online conversations I've mentioned that, before personal computers became available — before the Apple II (1977) and others that followed it — I programmed handheld calculators and published the results in magazine articles. Some readers have asked me to describe those days, which I must confess now seem like prehistory.

My reasons for acquiring programmable calculators were (1) I wanted to produce mathematical results I couldn't manage by hand computation, (2) I wanted to solve problems related to my work on the NASA Space Shuttle, and (3) I wanted to learn more mathematics, in particular the math of physical modeling like planetary orbits.

My activities and articles about programmable calculators lasted until I acquired an Apple II in 1977 (a story told here), after which everything changed — I was able to solve problems more easily and on a larger scale, I began to write more ambitious programs including Apple Writer, and my second career in computer science began.

In spite of the fact that I now have a lot of computers around, my fascination with handheld programmable calculators remains. In deference to old traditions, I always have a few Hewlett-Packard calculators ready at hand for various tasks — I still find them a convenient and congenial way to get useful results.

But let me describe the world before the personal computer, when a programmable calculator was the only way I could acquire applied math results, and a time when I was prepared to spend a lot of money for the privilege.

HP-25

The HP-25 wasn't my first programmable calculator — my first was an HP-65, but I didn't create any memorable programs with it. When I acquired the HP-25 I was sufficiently experienced to write up my results and get them published.


Figure 1: Hewlett-Packard HP-25
Image courtesy Hewlett-Packard

The HP-25, introduced in 1975, was priced at US$195, equivalent to about US$832 in 2012 dollars (inflation calculator), so these handheld marvels were by no means cheap. Because at the time I was working for a NASA subcontractor designing man-rated hardware for the Space Shuttle, I had a need for the calculator's abilities, and I could afford it.

I first used this calculator to solve work-related problems like the dynamic behavior of the inductors in my high-efficiency spacecraft power inverters. To get those results I wrote some numerical differential equation solvers, relatively simple iterative solutions to electronic circuit problems.

Remember that the HP-25 didn't have any way to save its results — the user was required to type in programs at the keyboard, and if the unit was turned off or the battery died, so did the program. This means the user spent a lot of time entering the same commands.

As I became more familiar with the HP-25 I began to write more ambitious programs that relied on iterative differential equation solvers, including an orbital model of the earth, the moon and a spacecraft that was supposed to fly from an earth orbit to the moon and land without crashing. The user would type in thruster values to make the journey and hopefully not smash into the moon or fly away into space, never to return.

After I played with this program for a while, it occurred to me that other HP-25 owners might want to play with it too, so I wrote an article that I submitted to Popular Electronics magazine, which accepted it. Here are scanned images of the article that resulted:

In retrospect, the most memorable part of this article was the fact that the "display" was a piece of graph paper — the user needed to put pencil marks on a paper graph in order to see what was going on. Here's a picture of the orbital graph I included with the article:


Figure 2: Space Flight program "display"

I include this picture so modern readers will realize how much has changed in 40 years. On seeing my article in Popular Electronics, like-minded people had no hesitation about sitting down with a programmable calculator, typing in 50 program steps by hand, then spending hours plotting the position of an imaginary spacecraft on a piece of graph paper. We called it a "computer game".

I ended up writing a number of programs and articles about the HP-25, but the difficulty of typing in a new program each time one wanted to change tasks was quite onerous. Hewlett-Packard realized this, so they introduced a much better calculator series, the HP-67/97.

HP-67/97

I acquired an HP-67 in 1976, a year before the first Apple II appeared on the scene. (The HP-97 was the same calculator with a thermal printer.) The new model cost US$450 in 1976, equivalent to US$1,186 in 2012 dollars. As before, I needed the device and, because of my NASA work, I could afford it.


Figure 3: HP-67
Image courtesy Hewlett-Packard

See the two slots along the right edge near the top of the calculator? Those accepted magnetic strips that contained program instructions and data, so once the user had created a program (or purchased a program), he didn't have to type it in again. The magnetic strip reader/writer units were temperamental and sometimes failed, but overall they represented a terrific improvement over the earlier calculators.

By the time I acquired my HP-67 I was ready to write more ambitious programs, in particular because I knew I wouldn't have to re-enter the program each time I wanted to use or change it. The HP-67 had a larger program capacity than the HP-25 (224 steps instead of 49), and the magnetic strips could contain data as well as program steps. This meant I could write a program that required a table of data.

My first published HP-67 program was a solar position / sunrise-sunset calculator, published in the magazine Optical Spectra in 1977:

This program produced quite a lot of correspondence with those who either wanted to use it in the field with their own HP-67 calculators, or who wanted to convert the algorithm into conventional computer languages for use in mainframe machines. One of the latter was a member of JPL's technical staff, who wanted to rewrite it in FORTRAN for use in a JPL solar energy project (link).

My next program was a bit more ambitious — a planetary ephemeris, a model of the solar system. This program actually required more than the HP-67 could provide (mostly because of tables of orbital data, not program steps), so users were obliged to model the solar system in sections — one magnetic card for the inner planets, one for the outer planets.

This program was also published in Optical Spectra magazine in 1977:

As with the solar position program, the article's publication created a lot of correspondence, including inquiries from JPL and its consultants asking about mathematical details and correcting some errors in the original published data tables (example).

Modern readers might wonder why JPL would be interested in a small planetary ephemeris program like this, given that they have a roomful of supercomputers to help them. Well, remember this was in 1977, before there were any personal computers, and a time when mainframe computers were difficult to access. At that time, to obtain a computed result, one had to punch a set of 80-column cards, submit it to the computer center (imagine a giant, noisy room that mere mortals were not allowed to enter), and a day later, receive the results, correct any errors, and start over.

Given these difficulties, and given that programmable calculators had just made their appearance, any calculator programs that performed astronomical or cosmological computations were a matter of great interest in the aerospace field — instead of dealing with the computer department and a 24-hour delay, one could get reasonably accurate results in seconds, using a device that sat on one's desk. In the context of the times, this bordered on the miraculous.

The planetary ephemeris program required three cards, only two of which could be used at a time (as explained above, the solar system was computed in sections). So it seems that, in a matter of months, I had exceeded the storage capacity of the HP-67 and wanted more.

What happened to my wish for more computer power? Well, one evening I was sitting in my tiny, wood-heated cabin in rural Oregon, reading a copy of Scientific American by a kerosene lantern. As I leafed through the magazine, I saw an advertisement for the Apple II. Wow, I thought, a personal computer — finally! The next day I ordered one. With a full 4 kilobytes of RAM, it was priced at US$1,298, which in 2012 dollars is almost US$5,000. That purchase leads to a story I tell here.

Perspective

While I was programming Hewlett-Packard calculators in the mid-1970s, Steve Wozniak was offering HP the opportunity to develop and sell his Apple I prototype personal computer. Over time he offered HP management his design five times, only to be turned down five times. He then reluctantly quit HP and, with his friend Steve Jobs, founded Apple Computer. I met them shortly thereafter and they agreed to sell my word processing program, later named Apple Writer.

Much later HP entered the personal computer business with machines compatible with the industry standard PC architecture introduced by IBM in 1981. But with respect to personal computers, HP has always been a "me-too" manufacturer of products they didn't bring into existence. One wonders what might have happened if HP management had been able to see the future potential of the personal computer, in particular because they had pioneered high-quality programmable calculators, products that in my opinion still set the standard for quality and reliability.

To me this is a story of a classic missed opportunity. By accepting Steve Wozniak's offer HP could have placed themselves at the vanguard of the personal computer field, a position they occupied (and still occupy) with their excellent programmable calculators. But it was not to be.



Figure 4: My Apple II (after a few customizations)

Long before it was possible, I imagined having my own full-fledged computer. For me, a programmable calculator was a steppingstone to ... something else, something I could imagine but couldn't build. Something that would do away with having to draw graphs on paper, having to enter computer instructions one by one into a processor that could contain at most 49 instructions.

I imagined being able to share mathematical ideas — pictures, equations, words — in a beautiful way, in a way that would help people see how beautiful mathematics is. I assumed that was far off in the future, but I thought it was a possibility within my lifetime.

Well, I got my wish, and as an Oscar Wilde saying goes, "When the gods wish to punish us, they answer our prayers." I didn't imagine that people would take computers and make them as much as possible like television, but they did.

Obviously I like modern computing, I can make it work for me, but at the same time, I feel a bit of nostalgia for programmable calculators — tiny processors that don't spam you, that don't try to take over your life. Processors that deliver small, clear results, without fanfare or subterfuge.

Digression

My primary reasons for writing this article are to record a bit of personal history, describe programming before the personal computer, and reminisce a bit. But I have another reason — some of my regular readers know there's an article about me on Wikipedia, but that article is likely to be deleted (update: it's gone — see below). The stated reason for deleting it is because it doesn't have enough references for its claims — for example, that I wrote a solar system model that was used by JPL during the Viking lander mission. Wikipedia rightly requires documentation for any claims made in its articles, and until this article, the article you're reading, that claim wasn't documented. It is now, by this article and by its attached correspondence. Nevertheless, once I saw that the article was being considered for removal, I added my own vote in favor of deletion. Why? Because it had become a cheap sounding board for people annoyed at my positions on controversial topics, particularly psychology and stockbrokers.

That's the real reason the self-appointed editors over at Wikipedia moved to delete the article (remember that anyone can sign up and edit Wikipedia articles). I've been tracking the article since it first appeared in 2006, and there have been any number of efforts to delete or destroy the article by people of varying levels of skill. One of the cleverer tactics has been to delete the list of references, wait 24 hours, then argue for the article's deletion on the ground that the article's claims have no references — that's been tried several times.

What's behind this? Why does anyone care so much about a short article that describes my activities? Well, I've noticed a correlation between my publishing something about psychology (I'm a critic of psychology's theoretical basis and practice, example: Psychology and Alchemy) and a subsequent effort to delete the Wikipedia article. Apparently some psychologists or fans of psychology think it's an appropriate response to criticism of their field — not to debate the issues honestly in public forums — but to try to remove any references to the critic.

The single best thing about Wikipedia is that anyone can edit it. That's also the single worst thing. It was my hope that a Wikipedia editor, one who doesn't care that I'm a psychology critic, would add a footnote reference to this article's documentation in the Wikipedia article, thereby removing an excuse to delete the article. That wouldn't have solved the problem, because I plan to continue criticizing psychology, but it would have made it harder to justify future attacks.

Update: Through a combination of my efforts and that of others, and since I couldn't protect it from vandalism, the Wikipedia article has been deleted. During my research on this topic, I encountered this almost identical incident:

Seth Finkelstein reported in an article in The Guardian on his efforts to remove his own biography page from Wikipedia, simply because it was subjected to defamation:

"Wikipedia has a short biography of me, originally added in February 2004, mostly concerned with my internet civil liberties achievements. After discovering in May 2006 that it had been vandalised in March, possibly by a long-time opponent, and that the attack had been subsequently propagated to many other sites which (legally) repackage Wikipedia's content, the article's existence seemed to me overall to be harmful rather than helpful. For people who are not very prominent, Wikipedia biographies can be an "attractive nuisance". It says, to every troll, vandal, and score-settler: "Here's an article about a person where you can, with no accountability whatsoever, write any libel, defamation, or smear. It won't be a marginal comment with the social status of an inconsequential rant, but rather will be made prominent about the person, and reputation-laundered with the institutional status of an encyclopedia."

In the same article Finkelstein recounts how he voted his own biography as "not notable enough" in order to have it removed from Wikipedia.

As explained above, once I saw how often opponents of my views on psychology tried to rewrite or delete my Wikipedia article, I took the same action for the same reason. Those who want to read a short biographical note, one not subject to controversy or vandalism, may click here.

What does this mean about Wikipedia? It means that controversial issues and people won't be described fairly, or sometimes at all. The idea behind Wikipedia is that it's a people's encyclopedia, not an ivory tower production. The problem with this egalitarian ideal is that special interests can, and do, struggle to see their particular outlook become the only outlook in the pages of Wikipedia. And, since my view of psychology is quickly becoming the majority view, psychologists found themselves unable to argue against that position using reason and fair tactics. So, just as when they chose to study psychology in college, they took the low road, the easy path — they resorted to gangster tactics.

But I'm not the victim — truth is. I ask my readers to be cautious when reading Wikipedia's articles: ask yourself whether the issue being discussed is in any way controversial. If it is, you should be very skeptical of the article's content. There's a reason many schools won't accept Wikipedia as a research source — many of the articles are in fact editorials for a particular outlook, or they have been edited so often by competing factions that they no longer bear any relation to the original topic.

References
Reader Feedback

First Steps | My 16th Birthday

First Steps
I was a teenager in South Africa when I read your Popular Electronics article on programming the Spaceflight game. I did not have a programmable calculator but used the idea to calculate and draw orbits on graph paper. What an eye opener. When my older brother found me a used TI-59 in the mid 1970s, this was the first program I wrote. Many years and many computers later, this memory stands out in the joy that computing and science and logic can bring to a young kid with no engineers or scientists to talk to. I now work at Los Alamos National Lab Applied Math group. One project is in collaboration with the Office of Science to develop the infrastructure for the first exascale machines. This can be cool work but I often seek to merely recapture that original joy of your article in Popular Electronics. I Just wanted to say thanks for your excellent & inspiring work over so many years. You're most welcome, and thanks for writing! You just made my day — I like and appreciate the thought that I might have given someone a small nudge in the direction of an analytical, scientific world view.

Thanks again.
My 16th Birthday
I recently read your article, Programming Handheld Calculators (A reminiscence about programming in the era before personal computers) and it back a lot of fond memories for me. The program that you submitted to Popular Electronics magazine (Space Flight) really fired my imagination with what could be done with a programmable calculator. I had been saving for almost two years and was already planning to buying my HP-25 in June 1977 on my 16th birthday. This article in Popular Electronics (which came out in May) just added to the fever. After I bought my HP-25 I ended up playing with your program for hours plotting the orbits around various sized planets. Looking back it was a magical time in my life. I just wanted to say thank you. You're most welcome! I've been hearing from a number of readers who got their first exposure to computers and to creative mathematics by buying a programmable calculator and by reading my early articles on the topic. It's encouraging that those articles might have inspired people to learn some mathematics of a creative and fun kind.

From a modern perspective, I think having to draw orbits on a piece of paper had a kind of purity to it — you were immersed in a dry numerical world with none of the flash of modern displays and high-speed processing. Then I think about Isaac Newton, who worked out elliptical orbits on paper with no artificial help at all, just the counsel of his inner world.

Thanks for writing!

Home | Articles |     Share This Page