EasyManua.ls Logo

HP HP-28S - STACK Menu

HP HP-28S
49 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
HP-28S
STACK Menu
General The stack of the HP-28S behaves similar to the stack of many other RPN
(Reverse Polish Notation) calculators like the HP-41. However, there are
important differences:
In theory the stack can hold an arbitrary number of elements. (Practically,
the number is limited by the available memory.)
In particular, the stack can be empty. In this case commands that
take arguments from the stack will cause an error. This is different
from the 4-level stack used in other HP calculators: There the stack
registers always contain numbers.
When dropping data from the stack the content of the highest stack
level is not duplicated. Thus, it is not possible to perform "calculations
with a constant" as usual.
To avoid a rapidly growing stack virtually all comands remove all of
their arguments from the stack before the results are pushed onto the
stack.
Different from normal RPN calculators there is a command line. It
supports advanced editing features but also introduces slight differences
in behaviour as compared to normal RPN, see example below.
Periodically erase unneeded stack objects (use CLEAR located on the "0" key)
because a large number will slow down execution speed.
Examples All examples assume an initially empty stack.
1 2 + results in 3. Except for the result the stack is empty.
1 2 + 'X' STO stores the result (3) in variable X. The stack is empty
because like all other commands STO removes its arguments from the stack
(the value and the variable name).
1 ENTER 2 ENTER + results in 3 and an otherwise empty stack. On a
normal RPN calculator the result would be 4 in stack level 1 and 1 in level 2.
This is because the 2
nd
ENTER moves the input value (2) from the command
line to stack level 1 only.
1 ENTER 2 ENTER ENTER + returns 1 and 4 because the 3
rd
ENTER acts
as a DUP which duplicates the element in stack level 1.
1 ENTER 2 DUP + also returns 1 and 4 because DUP explicitly duplicates
the 2.
Note that ENTER is not a command! It merely tells the calculator to evaluate
the command line. If the command line is empty it executes the DUP
command as a convenience.
DROP Above the "9" key: Discard the object in stack level 1 and shift all other
values one stack level down.
SWAP Shifted "" key: Exchange the object in level 1 and 2 without evaluating
them.
ROLL Shifted DROP key: Move a specified stack object onto the top of the stack.
Example: 10 20 30 40 50 3 ROLL
Moves the 3
rd
stack object (30) to the top of the stack. After the operation the
stack looks like this: 10 20 40 50 30
DUP Same as ENTER with an empty command line: Shift up objects in the stack by
1 level. The object in level 1 is duplicated into level 2.
OVER Pushes a copy of the element in stack level 2 onto the stack. Example:
16

Other manuals for HP HP-28S

Related product manuals