Post Reply 
How much LISP is in RPL?
04-21-2014, 08:58 PM (This post was last modified: 04-21-2014 08:59 PM by Matt Agajanian.)
Post: #1
How much LISP is in RPL?
Hi all.

How much (and to what capacity) of LISP is in the RPL for both the 48GX and 50G?
Find all posts by this user
Quote this message in a reply
04-21-2014, 11:42 PM
Post: #2
RE: How much LISP is in RPL?
(04-21-2014 08:58 PM)Matt Agajanian Wrote:  How much (and to what capacity) of LISP is in the RPL for both the 48GX and 50G?

Lisp uses prefix notation, so instead of 3 4 + they write (+ 3 4). Thus regarding the syntax there's not much in common. You see a lot of parentheses leading to the famous quote by Larry Wall:
Quote:Lisp has all the visual appeal of oatmeal with fingernail clippings mixed in.

However both 48GX and 50G provide some operations on lists e.g. STREAM which acts similar to reduce:
Code:
(reduce #'+ '(1 2 3 4)) => 10

And then functions are first-class citizens both in Lisp and RPL which is always nice.

Cheers
Thomas
Find all posts by this user
Quote this message in a reply
04-21-2014, 11:53 PM
Post: #3
RE: How much LISP is in RPL?
So, if RPL is primarily postfix and contains a minutely small subset of Lisp commands, how did RPL come to be known as Reverse Polish Lisp?
Find all posts by this user
Quote this message in a reply
04-22-2014, 12:12 AM
Post: #4
RE: How much LISP is in RPL?
(04-21-2014 11:53 PM)Matt Agajanian Wrote:  how did RPL come to be known as Reverse Polish Lisp?

http://www.faqs.org/faqs/hp/hp48-faq/part2:
Quote: RPL is the name of the language used to program the HP48 and
HP-28 series calculators. RPL stands for "Reverse Polish Lisp".
It's interesting to note that an HP Journal article incorrectly
described RPL as "ROM-based Procedural Language".

From Bill Wickes:

RPL stands for Reverse Polish Lisp. In the early days of RPL
development, we got tired of calling the unnamed system "the new
system," and one of the development team came up with "RPL,"
both as a play on "RPN" which has been the loved/hated hallmark
of HP calcs forever, and as an accurate indication of the
derivation of the language from Forth and Lisp.

RPL was never particularly intended to be a public term; at the
time of the HP Journal article (August 1987) on the HP 28C there
was an attempt to create a less whimsical name--hence "ROM-based
procedural language," which preserved the initials but had a
more dignified sound. The development team never calls it
anything but (the initials) RPL. You can choose either of the
two full-word versions that you prefer. Or how about 'Rich
People's Language?'
Find all posts by this user
Quote this message in a reply
04-22-2014, 12:46 AM
Post: #5
RE: How much LISP is in RPL?
Fair enough. Thanks for the refresher.
Find all posts by this user
Quote this message in a reply
04-22-2014, 01:35 AM
Post: #6
RE: How much LISP is in RPL?
Another quote from Bill Wickes:

Quote:"BEGINNINGS
The HP- 28C project had its origins about 2-1/2 years ago, as the HP-71 application ROM projects were winding down. At that time, the team that had produced the 71 Math and FORTH/Assembler ROMs turned their attention to designing a calculator operating system. We were convinced that the next generation of calculators should support symbolic mathematics-- the ability to use calculator operations on quantities represented by symbols that don’t first have to be converted to numbers.
After some study, it became clear that the HP 71 and the HP 41C operating systems and user languages are unsuited for this purpose, because of their lack of any method of applying functions to unevaluated expressions (programs). Likewise, PC-based systems and languages that support symbolic math are too profligate of ROM and RAM to be practical for a handheld.

In the end, we began developing a new operating system customized for our requirements. This development was completed about a year later, and we turned our attention to the implementation of a symbolic math calculator. Meanwhile, the HP-18C project had begun a parallel development, and became the first product based upon our new operating system. It uses the same internal language and execution logic as the HP-28C, even though its external user interface is quite different. Although the 18C does not provide any symbolic math capability directly to the user, the Solver does perform some rudimentary symbolic manipulations as part of its "direct" solve.

The new operating system and language is based upon a combination of FORTH and LISP and is known informally at HP as "RPL" (for Reverse-Polish LISP). Although FORTH’s rigid memory management and utter lack of user protection make it unsuitable as a calculator language, it happens that its threaded interpretation logic and unlimited data and return stacks are ideal for manipulation and evaluation of symbolic expressions. RPL execution is based on a generalization of the FORTH "inner loop." (in fact, the bit-bangers among you may be interested to know that the Saturn CPU in the new products has a new opcode. PC=(A), to optimize threaded execution)

LISP is the traditional language used for implementation of computer symbolic math. RPL borrow heavily from LISP, particularly in its implementation of list manipulations and lambda variables (local variables in the HP-28C terminology).

The basic user interface of the HP-28C was laid out in a 3-day team meeting that took place in January, 1985, as the operating system development was in its final stages. Formal work on the HP- 28C firmware was begun in May, and completed in June 1986. "

Extract from "The HP-28C: AN INSIDER'S PERSPECTIVE - William C. Wickes, HP-28C Project Manager" , published in HPX Exchange V1N1 January/February 1987.
Find all posts by this user
Quote this message in a reply
04-22-2014, 01:46 AM
Post: #7
RE: How much LISP is in RPL?
(04-22-2014 01:35 AM)Didier Lachieze Wrote:  Another quote from Bill Wickes:

Quote:"BEGINNINGS
The HP- 28C project had its origins about 2-1/2 years ago, as the HP-71 application ROM projects were winding down. At that time, the team that had produced the 71 Math and FORTH/Assembler ROMs turned their attention to designing a calculator operating system. We were convinced that the next generation of calculators should support symbolic mathematics-- the ability to use calculator operations on quantities represented by symbols that don’t first have to be converted to numbers.
After some study, it became clear that the HP 71 and the HP 41C operating systems and user languages are unsuited for this purpose, because of their lack of any method of applying functions to unevaluated expressions (programs). Likewise, PC-based systems and languages that support symbolic math are too profligate of ROM and RAM to be practical for a handheld.

In the end, we began developing a new operating system customized for our requirements. This development was completed about a year later, and we turned our attention to the implementation of a symbolic math calculator. Meanwhile, the HP-18C project had begun a parallel development, and became the first product based upon our new operating system. It uses the same internal language and execution logic as the HP-28C, even though its external user interface is quite different. Although the 18C does not provide any symbolic math capability directly to the user, the Solver does perform some rudimentary symbolic manipulations as part of its "direct" solve.

The new operating system and language is based upon a combination of FORTH and LISP and is known informally at HP as "RPL" (for Reverse-Polish LISP). Although FORTH’s rigid memory management and utter lack of user protection make it unsuitable as a calculator language, it happens that its threaded interpretation logic and unlimited data and return stacks are ideal for manipulation and evaluation of symbolic expressions. RPL execution is based on a generalization of the FORTH "inner loop." (in fact, the bit-bangers among you may be interested to know that the Saturn CPU in the new products has a new opcode. PC=(A), to optimize threaded execution)

LISP is the traditional language used for implementation of computer symbolic math. RPL borrow heavily from LISP, particularly in its implementation of list manipulations and lambda variables (local variables in the HP-28C terminology).

The basic user interface of the HP-28C was laid out in a 3-day team meeting that took place in January, 1985, as the operating system development was in its final stages. Formal work on the HP- 28C firmware was begun in May, and completed in June 1986. "

Extract from "The HP-28C: AN INSIDER'S PERSPECTIVE - William C. Wickes, HP-28C Project Manager" , published in HPX Exchange V1N1 January/February 1987.

Didier,

Thanks for this in-depth history lesson as well!
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: