Bringing APL To The Masses: The History Of The IBM 5100

The IBM 5100, image from December 1975 issue of BYTE.

The 1970s was a somewhat awkward phase for the computer industry — as hulking, room-sized mainframes became ever smaller and the concept of home and portable computers more capable than a basic calculator began to gain traction. Amidst all of this, two interpreted programming languages saw themselves being used the most: BASIC and APL, with the latter being IBM’s programming language of choice for its mainframes. The advantages of being able to run APL on a single-user, portable system, eventually led to the IBM 5100. Its story is succinctly summarized by [Bradford Morgan White] in a recent article.

The IBM PALM processor.
The IBM PALM processor.

Although probably not well-known to the average computer use, APL (A Programming Language) is a multi-dimensional array-based language that uses a range of special graphic symbols that are often imprinted on the keyboard for ease of entry.

It excels at concisely describing complex functions, such as the example provided on the APL Wikipedia entry for picking 6 pseudo-random, non-repeating integers between 1 and 40 and sorting them in ascending order:

x[x6?40]

Part of what made it possible to bring the power of APL processing to a portable system like the IBM 5100 was the IBM PALM processor, which implemented an emulator in microcode to allow e.g. running System/360 APL code on a 5100, as well as BASIC.

Despite [Bradford]’s claim that the 5100 was not a commercial success, it’s important to remember the target market. With a price tag of tens of thousands of (inflation-adjusted 2023) dollars, it bridged the gap between a multi-user mainframe with APL and far less capable single-user systems that generally only managed BASIC. This is reflected in that the Commodore SuperPET supported APL, and the 5100 was followed by the 5110 and 5120 systems, and that today you can download GNU APL which implements the ISO/IEC 13751:2001 (APL2) standard.

We’ve previously looked at the Canadian-made MCM/70, another portable APL machine that embodied the cyberdeck aesthetic before William Gibson even gave it a name.

Top image: The IBM 5100, image from December 1975 issue of BYTE.

Thanks to [Stephen Walters] for the tip.

42 thoughts on “Bringing APL To The Masses: The History Of The IBM 5100

  1. I loved that machine! Used the 5100 in 1976 at IBM Rochester as a summer intern working on a machine to write servo tracks onto hard disk platters.

    APL is a great language, but it is essentially “write-only”.

  2. I learned APL in the mid 70s.

    It was a time when software was very new, and not much was known about (computer) language theory or software reliability. The main programming language was Fortran, and C didn’t exist.

    IBM did a study of programming errors, and decided that the number of errors per programmer was a constant factor of the number of lines written. To their surprise, writing in different languages didn’t affect the number of errors – only the number of lines written.

    So for a program with a fixed specification, a programmer writing in assembler would generate a lot of errors, and writing in Fortran would generate about 1/5 as many errors since one Fortran line is equivalent to 3 to 5 assembler lines.

    Their conclusion was that an extremely terse language would result in fewer programming errors, and that was the basis for APL: an extremely terse language that would result in fewer programming errors.

    https://dl.acm.org/doi/pdf/10.1145/586015.586019

    Apropos of nothing, I use Perl and like it a lot. Unlike other languages it was designed by a linguist and not an engineer, with the goal of being able to do things that programmers typically want to do instead of just mimicking the CPU.

    Perl suffers from the same problem as APL, in that it’s harder to learn. The CPU mirror languages can be learned in a week, but you spend the rest of your life learning all the library interfaces. Taking C++ as an example, the actual language is just a mirror of the CPU and pretty simple – a handful of operators plus function calls. Everything that you actually want to use is implemented in a library and these are many, varied, complex, and difficult to remember.

    Python feels like a simplistic Perl implemented by a college student. The library architecture is now so complicated that you need a framework architecture (conda) to switch to the correct library versions to run a program! I don’t know how Python has managed to last this long.

        1. That’s definitely interesting, but as I’ve seen more than one microperl threads on perlmonks spanning countless years, I’m not holding my breath.

          But perhaps I’ll be surprised…

    1. “Their conclusion was that an extremely terse language would result in fewer programming errors, and that was the basis for APL: an extremely terse language that would result in fewer programming errors.”

      But did it? I suspect not!

      1. APL had the well-earned reputation of being a “write-only” language. Even APL experts had difficulties understanding code they had written weeks or even days earlier. Its terse notation combined with its oddball order of evaluation led to some interesting programs.

        Iverson devised APL as a notation for teaching algorithms and published a textbook before any implementations were available. The first actual implementation of APL was done on an IBM 7090 in the early 1960’s. IBM found APL useful for specifying instruction set architectures. Brooks and Blaauw published a comprehensive survey of computer architectures using APL notation.

    2. Interesting that low programming errors was a design goal.

      I recall APL being described like this:
      If you put two APL programmers in a room, they will immediately show each other an APL program consisting of a single line and say:
      ‘I bet you can’t figure out what this program does!’

      So, it seemed that APL was the polar opposite of BASIC; a simple “beginner” language. APL was a language for computer geniuses, maybe, but at a time when computer programmers were relatively rare. It was a self-selecting dataset, perhaps.

      1. agreed!

        trying to wring a one-liner solution to ever-more-complex problems was an irresistible challenge. besides exchanging dazzlers, it was great to be awestruck looking at your own code, after just a couple of minutes :-)

        some “upgrades” in this kind of activity were doing it without defining functions or, best of all, without any variables.

        still have some wallpaper lying around in a box somewhere… must go look for it

      2. Indeed! Exchanging one-liners for ever-more-complex problems was an irresistible – and very intense – challenge. Even just gazing at your own code in bewilderment, after a couple of minutes of writing it, was lots of fun.

        Some “upgrades” to such code were, e.g., doing it without defining any functions and, even better, with no variables whatsoever. :-D

      1. C++ resulted from a mute programmer dropping a PDP11 on his foot, swearing at 110baud through the ASR33, and discovering that it almost compiled, and if he just added a few more symbols it would surely be a working program.
        I spent a couple of years programming C++, and even by the end I frequently still just swapped punctuation symbols until the error messages stopped.

    3. “and that was the basis for APL”

      Actually that was *not* the basis for APL. Ken Iverson’s “A Programming Language” was and is the basis for APL, both in terms of syntax and structure, history, and initial implementation at IBM

  3. Still have my IBM Model M keyboard with the APL keyset. The original version that had only the symbols printed on the caps, no regular characters. Surprised its not worth way more than it is. Weird language, wrote some great ahead-of-its-time vector graphics programs with it for the Hercules Monochrome graphics card.

  4. I love APL. It was the first programming language I learned. In high school circa 1970 we had an APL/360 terminal. I later also used APL/1130 with it’s “crypto-shift” keyboard at Tenney Engineering. I never used it on a 5100.

  5. I have an IBM Selectric Ball with the APL Character Set, salvaged from a IBM 2741 Selectric Terminal that communicated at 134.5 baud, supposedly because someone had done a study that determined that was the fastest you could run it without causing excessive wear on the mechanical linkages.

  6. The Computer History Museum has an IBM 5100 in its collection. There is a very good description of the machine in the catalog. (I wrote it.) To read it click Explore->Collection->Seach Collections and enter the description “IBM 5100” or the catalog number 102636445.

  7. For APL’s 50th anniversary, the Computer History Museum got IBM’s permission to release the APL\360 sources for non-commercial use. They are available here:

    https://computerhistory.org/blog/the-apl-programming-language-source-code/

    Some ex-IBMers got APL\360 binaries running on a web-based IBM 360 simulator a number of years before the sources were released. The simulator includes a 2741 terminal emulator with the APL character set. I saw a demo a while back. Looked really nice! (Alas, I haven’t had time to track down where/how to experience that work.)

  8. IBM 5100 ran a commercial/industrial BASIC along with the HP 9800 and Wang 2200.

    Intel MCS BASIC-52 more resembles the above BASICs, imo.

    Implementing BASICS: How BASICs Work twice-taught course at Sandia National Laboratories helped get posters positions where fig-Forth embedded controller work on 8085 and 8051 done.

    Sandia management between ~1982 through 1992 supported this work because
    software finished on time , worked reliably compared to previous assembler weapons software.

    HP 9800 BASIC used for weapon systems testers.

    Then in ~1991 management told that c/c++ was the only software technology to use.

  9. Sometime in the early 80’s I bought a VideoBrain home computer from a clearinghouse for $99. It came with a few cartridges including one of APL. No documentation. No internet to turn to. No results.

  10. The professor specified the language for assignments after I submitted one done in APL, it was 10 lines, 7 were comments. The other students handed in 800 line pascal programs.

  11. My high school installed a number of CBM 8032s in the computer lab. They also had a PET 4016 and a SuperPET (8096?). I was allowed to take the SuperPET home on break one year.

    I loved playing on that system and became facinated by APL. I bought a few books on APL and tried getting versions for the systems I had over the years, but I never really learned it.

    There was a switch to use the 6502 or 6809 CPU. You could also have the boot autoswitch. The Waterloo floppies were all for the 6809. University of Waterloo created several programming languages for it.
    IIRC Waterloo Pascal was interpreted and very slow. I don’t remember if Fortran. There was also BASIC and maybe Cobol?

Leave a Reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.