Creating Programs on a Computer Using Local Variables

Creating Programs on a Computer Using Local Variables
Save the edited version of SPH in the variable. Then, to verify that the changes were saved, view SPH in the
command line.
`J!%SPH%
@%SPH% ˜
Press − to stop viewing.
Creating Programs on a Computer
It is convenient to create programs and other objects on a computer and then load them into the calculator.
If you are creating programs on a computer, you can include “comments” in the computer version of the program.
To include a comment in a program:
Enclose the comment text between two @ characters.
or
Enclose the comment text between one @ character and the end of the line.
Whenever the calculator processes text entered in the command line — either from keyboard entry or transferred
from a computer — it strips away the @ characters and the text they surround. However, @ characters are not
affected if they’re inside a string.
Using Local Variables
The program SPH in the previous example uses global variables for data storage and recall. There are disadvantages
to using global variables in programs:
After program execution, global variables that you no longer need to use must be purged if you want to clear the
VAR menu and free user memory.
You must explicitly store data in global variables prior to program execution, or have the program execute STO.
Local variables address the disadvantages of global variables in programs. Local variables are temporary variables
created by a program. They exist only while the program is being executed and cannot be used outside the program.
They never appear in the VAR menu. In addition, local variables are accessed faster than global variables. (By
convention, this manual uses lowercase names for local variables.) A compiled local variable is a form of local
variable that can be used outside of the program that creates it. See “Compiled Local Variables” on page 1-10 for
more information.
Creating Local Variables
In a program, a local variable structure creates local variables.
To enter a local variable structure in a program:
1. Enter the → command (press @é).
2. Enter one or more variable names.
3. Enter a defining procedure (an algebraic or program object) that uses the names.
« → name1 name2 … namen ' algebraic ' »
or
« → name1 name2 … namen « program » »
When the → command is executed in a program, n values are taken from the stack and assigned to variables name1
name2, …. namen.
RPL Programming 1-7
Example: Enter a program SPH that calculates the volume of a spherical cap of height h within a sphere of radius
R using values stored in variables H and R.
1 2
V = --- πh ( 3r – h )
3
In this and following chapters on programming, “stack diagrams” show what arguments must be on the stack
before a program is executed and what results the program leaves on the stack. Here’s the stack diagram for SPH.
Level 1
→
Level 1
→
volume
The diagram indicates that SPH takes no arguments from the stack and returns the volume of the spherical cap to
level 1. (SPH assumes that you’ve stored the numerical value for the radius in variable R and the numerical value for
the height in variable H. These are global variables — they exist outside the program.)
Program listings are shown with program steps in the left column and associated comments in the right column.
Remember, you can either press the command keys or type in the command names to key in the program. In this
first listing, the keystrokes are also shown.
Program:
Keys:
Comments:
«
@%
Begins the program.
'1/3
O1 /3
Begins the algebraic expression
to calculate the volume.
*π*H^2
*!ì Multiplies by ̟h2.
*H Q2
*(3*R-H)'
*!Ü Multiplies by 3r - h, completing
3 * R - the calculation and ending the
expression.
H ™™
→NUM
@ï
»
`
OSPH K
Converts the expression with π
to a number.
Ends the program.
Puts the program on the stack.
Stores the program in variable
SPH.
RPL Programming 1-5
Fibonacci Numbers..................................................................................................................................................................2-1
FIB1 (Fibonacci Numbers, Recursive Version)...........................................................................................................2-1
FIB2 (Fibonacci Numbers, Loop Version....................................................................................................................2-2
FIBT (Comparing Program-Execution Time) .............................................................................................................2-4
Displaying a Binary Integer.....................................................................................................................................................2-5
PAD (Pad with Leading Spaces).....................................................................................................................................2-5
PRESERVE (Save and Restore Previous Status) ........................................................................................................2-6
BDISP (Binary Display)...................................................................................................................................................2-7
Median of Statistics Data ......................................................................................................................................................2-10
%TILE (Percentile of a list) ..........................................................................................................................................2-10
MEDIAN (Median of Statistics Data).........................................................................................................................2-11
Expanding and Collecting Completely................................................................................................................................2-13
MULTI (Multiple Execution) .......................................................................................................................................2-14
EXCO (Expand and Collect Completely) ..................................................................................................................2-15
Minimum and Maximum Array Elements..........................................................................................................................2-16
MNX (Minimum or Maximum Element—Version 1) .............................................................................................2-16
MNX2 (Minimum or Maximum Element—Version 2) ...........................................................................................2-18
Applying a Program to an Array..........................................................................................................................................2-20
Converting Between Number Bases ...................................................................................................................................2-22
Verifying Program Arguments .............................................................................................................................................2-24
NAMES (Check List for Exactly Two Names) .........................................................................................................2-25
NAMES...................................................................................................................................................................................2-26
Converting Procedures from Algebraic to RPN ...............................................................................................................2-27
Bessel Functions .....................................................................................................................................................................2-29
Animation of Successive Taylor’s Polynomials .................................................................................................................2-31
SINTP (Converting a Plot to a Graphics Object) .....................................................................................................2-31
Techniques used in SINTP ...........................................................................................................................................2-31
SETTS (Superimposing Taylor’s polynomials) ..........................................................................................................2-32
TSA (Animating Taylor’s Polynomials).......................................................................................................................2-33
Programmatic Use of Statistics and Plotting......................................................................................................................2-34
Trace Mode .............................................................................................................................................................................2-37
Inverse-Function Solver ........................................................................................................................................................2-38
Animating a Graphical Image...............................................................................................................................................2-39
3. Full Command and Function Reference..................................................................................................................................3-1
ABCUV......................................................................................................................................................................................3-5
ABS.............................................................................................................................................................................................3-5
ACK............................................................................................................................................................................................3-5
ACKALL ...................................................................................................................................................................................3-6
ACOS .........................................................................................................................................................................................3-6
ACOS2S.....................................................................................................................................................................................3-7
ACOSH......................................................................................................................................................................................3-8
ADD...........................................................................................................................................................................................3-9
ADDTMOD .............................................................................................................................................................................3-9
ADDTOREAL.......................................................................................................................................................................3-10
ALGB.......................................................................................................................................................................................3-10
ALOG ......................................................................................................................................................................................3-10
AMORT...................................................................................................................................................................................3-11
AND.........................................................................................................................................................................................3-11
ANIMATE..............................................................................................................................................................................3-12
ANS ..........................................................................................................................................................................................3-12
APPLY .....................................................................................................................................................................................3-13
ARC ..........................................................................................................................................................................................3-13
ARCHIVE...............................................................................................................................................................................3-14
ARG..........................................................................................................................................................................................3-14
ARIT.........................................................................................................................................................................................3-15
ARRY→...................................................................................................................................................................................3-15
Contents - 2
Entering and Executing Programs
A program is an object — it occupies one level on the stack, and you can store it in a variable.
To enter a program:
1. Press @%.The PRG annunciator appears, indicating program-entry mode is active.
2. Enter the commands and other objects (with appropriate delimiters) in order for the operations you want the
program to execute.
Press # to separate consecutive numbers.
Press ™ to move past closing delimiters.
3. Optional: Press @ë (newline) to start a new line in the command line at any time.
4. Press ` to put the program on the stack.
In Program-entry mode (PRG annunciator on), command keys aren’t executed — they’re entered in the command
line instead. Only nonprogrammable operations such as ƒ and J are executed.
Line breaks are discarded when you press `.
To enter commands and other objects in a program:
Press the keyboard or menu key for the command or object. All commands can also be selected from the
@µ list.
This guide assumes that Flag –117 is clear, so that you see menus rather than choose boxes wherever possible. Also RPN mode should
be set.
or
Type the characters using the alpha keyboard.
Refer to the calculator’s User’s Guide for how to use the alpha keyboard.
In this guide an abbreviated convention is used whereby invocations of the alpha keyboard are not always shown. In the next example we
show:
OVOLK where the alpha “VOL” can be entered as shown:
O~~VOL ~K (assuming Flag –60 is clear).
To store or name a program:
1. Enter the program on the stack.
2. Enter the variable name (with ' delimiters) and press K.
You can choose descriptive names for programs. Here are some ideas of what the name can describe:
The calculation or action. Examples: SPH (spherical-cap volume), SORTLIST (sort a list).
The input and output. Examples: X→FX (x to f (x)), RH→V (radius-and -height to volume).
The technique. Example: SPHLV (spherical-cap volume using local variables).
To execute a program:
Press J then the menu key for the program name.
or
Enter the program name (with no delimiters) and press `.
or
Put the program name in level 1 and press N.
or
Put the program object in level 1 and press N.
RPL Programming 1-3
→COL .....................................................................................................................................................................................3-39
COL→ .....................................................................................................................................................................................3-39
COL–........................................................................................................................................................................................3-39
COL+.......................................................................................................................................................................................3-40
COLCT ....................................................................................................................................................................................3-40
COLLECT...............................................................................................................................................................................3-40
COLΣ.......................................................................................................................................................................................3-41
COMB......................................................................................................................................................................................3-41
CON .........................................................................................................................................................................................3-41
COND .....................................................................................................................................................................................3-42
CONIC ....................................................................................................................................................................................3-43
CONJ .......................................................................................................................................................................................3-43
CONLIB..................................................................................................................................................................................3-44
CONST....................................................................................................................................................................................3-44
CONSTANTS ........................................................................................................................................................................3-44
CONT ......................................................................................................................................................................................3-45
CONVERT .............................................................................................................................................................................3-45
CORR.......................................................................................................................................................................................3-45
COS ..........................................................................................................................................................................................3-46
COSH.......................................................................................................................................................................................3-46
COV .........................................................................................................................................................................................3-46
CR .............................................................................................................................................................................................3-47
CRDIR .....................................................................................................................................................................................3-47
CROSS .....................................................................................................................................................................................3-47
CSWP .......................................................................................................................................................................................3-47
CURL .......................................................................................................................................................................................3-48
CYCLOTOMIC .....................................................................................................................................................................3-48
CYLIN .....................................................................................................................................................................................3-48
C→PX......................................................................................................................................................................................3-49
C→R.........................................................................................................................................................................................3-49
DARCY....................................................................................................................................................................................3-49
DATE.......................................................................................................................................................................................3-49
→DATE..................................................................................................................................................................................3-50
DATE+....................................................................................................................................................................................3-50
DBUG......................................................................................................................................................................................3-50
DDAYS....................................................................................................................................................................................3-51
DEC..........................................................................................................................................................................................3-51
DECR.......................................................................................................................................................................................3-51
DEDICACE ...........................................................................................................................................................................3-52
DEF..........................................................................................................................................................................................3-52
DEFINE..................................................................................................................................................................................3-52
DEG.........................................................................................................................................................................................3-53
DEGREE ................................................................................................................................................................................3-53
DELALARM ..........................................................................................................................................................................3-53
DELAY....................................................................................................................................................................................3-54
DELKEYS ..............................................................................................................................................................................3-54
DEPND...................................................................................................................................................................................3-55
DEPTH....................................................................................................................................................................................3-55
DERIV.....................................................................................................................................................................................3-56
DERVX ...................................................................................................................................................................................3-56
DESOLVE..............................................................................................................................................................................3-56
DET..........................................................................................................................................................................................3-57
DETACH ................................................................................................................................................................................3-57
DIAG→...................................................................................................................................................................................3-58
→DIAG...................................................................................................................................................................................3-58
DIAGMAP..............................................................................................................................................................................3-58
Contents - 4
1
1.RPL Programming
If you’ve used a calculator or computer before, you’re probably familiar with the idea of programs. Generally
speaking, a program is something that gets the calculator or computer to do certain tasks for you — more than a
built-in command might do. In the HP 48gII, HP 49g+, and HP 50g calculators, a program is an object that does the
same thing.
Understanding Programming
A calculator program is an object with « » delimiters containing a sequence of numbers, commands, and other
objects you want to execute automatically to perform a task.
For example, a program that takes a number from the stack, finds its factorial, and divides the result by 2 would
look like this: « ! 2 / » or
«
!
2
/
»
The Contents of a Program
As mentioned above, a program contains a sequence of objects. As each object is processed in a program, the action
depends on the type of object, as summarized below.
Actions for Certain Objects in Programs
Object
Command
Number
Algebraic or `Algebraic`
String
List
Program
Global name (quoted)
Global name (unquoted)
Local name (quoted)
Local name (unquoted)
Action
Executed.
Put on the stack.
Algebraic put on the stack.
Put on the stack.
Put on the stack.
Put on the stack.
Put on the stack.
Program executed.
Name evaluated.
Directory becomes current.
Other object put on the stack.
Put on the stack.
Contents put on the stack
As you can see from this table, most types of objects are simply put on the stack — but built-in commands and
programs called by name cause execution. The following examples show the results of executing programs containing
different sequences of objects.
RPL Programming 1-1
EXP2POW..............................................................................................................................................................................3-79
EXPAN....................................................................................................................................................................................3-79
EXPAND ................................................................................................................................................................................3-80
EXPANDMOD .....................................................................................................................................................................3-80
EXPFIT ...................................................................................................................................................................................3-81
EXPLN ....................................................................................................................................................................................3-81
EXPM ......................................................................................................................................................................................3-81
EYEPT.....................................................................................................................................................................................3-81
F0λ ............................................................................................................................................................................................3-82
FACT........................................................................................................................................................................................3-82
FACTOR .................................................................................................................................................................................3-82
FACTORMOD ......................................................................................................................................................................3-83
FACTORS...............................................................................................................................................................................3-83
FANNING..............................................................................................................................................................................3-84
FAST3D...................................................................................................................................................................................3-84
FCOEF ....................................................................................................................................................................................3-85
FC?............................................................................................................................................................................................3-85
FC?C.........................................................................................................................................................................................3-85
FDISTRIB...............................................................................................................................................................................3-86
FFT ...........................................................................................................................................................................................3-86
FILER ......................................................................................................................................................................................3-87
FINDALARM ........................................................................................................................................................................3-87
FINISH....................................................................................................................................................................................3-87
FIX............................................................................................................................................................................................3-87
FLASHEVAL .........................................................................................................................................................................3-88
FLOOR....................................................................................................................................................................................3-88
FONT6 ....................................................................................................................................................................................3-88
FONT7 ....................................................................................................................................................................................3-89
FONT8 ....................................................................................................................................................................................3-89
FONT→..................................................................................................................................................................................3-89
→FONT..................................................................................................................................................................................3-89
FOR ..........................................................................................................................................................................................3-90
FOURIER ...............................................................................................................................................................................3-91
FP..............................................................................................................................................................................................3-91
FREE........................................................................................................................................................................................3-91
FREEZE..................................................................................................................................................................................3-91
FROOTS .................................................................................................................................................................................3-92
FS?.............................................................................................................................................................................................3-92
FS?C..........................................................................................................................................................................................3-93
FUNCTION ...........................................................................................................................................................................3-93
FXND ......................................................................................................................................................................................3-94
GAMMA..................................................................................................................................................................................3-95
GAUSS.....................................................................................................................................................................................3-95
GBASIS....................................................................................................................................................................................3-95
GCD .........................................................................................................................................................................................3-96
GCDMOD ..............................................................................................................................................................................3-96
GET..........................................................................................................................................................................................3-96
GETI ........................................................................................................................................................................................3-97
GOR .........................................................................................................................................................................................3-98
GRAD......................................................................................................................................................................................3-98
GRAMSCHMIDT .................................................................................................................................................................3-99
GRAPH ...................................................................................................................................................................................3-99
GREDUCE.............................................................................................................................................................................3-99
GRIDMAP............................................................................................................................................................................3-100
→GROB................................................................................................................................................................................3-100
GROB ....................................................................................................................................................................................3-101
Contents - 6
A.
B.
C.
D.
BetaTesting ........................................................................................................................................................................6-3
CD→...................................................................................................................................................................................6-3
→CD...................................................................................................................................................................................6-4
COMP→ ............................................................................................................................................................................6-4
CRC.....................................................................................................................................................................................6-4
CRLIB.................................................................................................................................................................................6-4
ER........................................................................................................................................................................................6-4
H→......................................................................................................................................................................................6-4
→H......................................................................................................................................................................................6-5
H→A ..................................................................................................................................................................................6-5
H→S ...................................................................................................................................................................................6-5
LC~C ..................................................................................................................................................................................6-5
LR~R ..................................................................................................................................................................................6-5
→LST .................................................................................................................................................................................6-6
MAKESTR ........................................................................................................................................................................6-6
PEEK..................................................................................................................................................................................6-6
PEEKARM........................................................................................................................................................................6-6
POKE.................................................................................................................................................................................6-6
POKEARM .......................................................................................................................................................................6-7
→PRG ................................................................................................................................................................................6-7
→RAM ...............................................................................................................................................................................6-7
R~SB...................................................................................................................................................................................6-7
SB~B...................................................................................................................................................................................6-7
SERIAL ..............................................................................................................................................................................6-8
S→H ...................................................................................................................................................................................6-8
S~N.....................................................................................................................................................................................6-8
SREV ..................................................................................................................................................................................6-8
→S2.....................................................................................................................................................................................6-8
XLIB~ ................................................................................................................................................................................6-9
CRLIB – Create Library Command ......................................................................................................................................6-9
Extension program .........................................................................................................................................................6-10
MASD – The Machine Language and System RPL Compiler........................................................................................6-11
Introduction.....................................................................................................................................................................6-11
Saturn ASM mode...........................................................................................................................................................6-19
ARM mode.......................................................................................................................................................................6-30
System RPL mode...........................................................................................................................................................6-35
Example of a Saturn assembly language program using the MASD compiler.............................................................6-38
Example of an ARM assembly language program using the MASD compiler ............................................................6-39
Disassemblers..........................................................................................................................................................................6-41
ASM→..............................................................................................................................................................................6-41
ARM→ .............................................................................................................................................................................6-41
The Entry Point Library: Extable ........................................................................................................................................6-42
nop.....................................................................................................................................................................................6-42
GETNAME.....................................................................................................................................................................6-42
GETADR.........................................................................................................................................................................6-42
GETNAMES...................................................................................................................................................................6-42
Library 257...............................................................................................................................................................................6-42
Error and Status Messages .............................................................................................................................................A-1
Tables of Units and Constants....................................................................................................................................... B-1
System Flags...................................................................................................................................................................... C-1
Reserved Variables.......................................................................................................................................................... D-1
System Reserved Variables.....................................................................................................................................................D-1
Contents of the System Reserved Variables........................................................................................................................D-2
αENTER...................................................................................................................................................................................D-2
Contents - 19
KER........................................................................................................................................................................................3-123
KERRM .................................................................................................................................................................................3-123
KEY........................................................................................................................................................................................3-123
KEYEVAL............................................................................................................................................................................3-124
→KEYTIME........................................................................................................................................................................3-124
KEYTIME→........................................................................................................................................................................3-125
KGET ....................................................................................................................................................................................3-125
KILL.......................................................................................................................................................................................3-125
LABEL...................................................................................................................................................................................3-125
LAGRANGE........................................................................................................................................................................3-126
LANGUAGE→...................................................................................................................................................................3-126
→LANGUAGE...................................................................................................................................................................3-126
LAP.........................................................................................................................................................................................3-127
LAPL ......................................................................................................................................................................................3-127
LAST ......................................................................................................................................................................................3-127
LASTARG.............................................................................................................................................................................3-128
LCD→ ...................................................................................................................................................................................3-128
→LCD ...................................................................................................................................................................................3-128
LCM........................................................................................................................................................................................3-128
LCXM ....................................................................................................................................................................................3-129
LDEC.....................................................................................................................................................................................3-129
LEGENDRE........................................................................................................................................................................3-130
LGCD ....................................................................................................................................................................................3-130
LIBEVAL ..............................................................................................................................................................................3-130
LIBS........................................................................................................................................................................................3-130
lim ...........................................................................................................................................................................................3-131
LIMIT.....................................................................................................................................................................................3-131
LIN .........................................................................................................................................................................................3-131
LINE ......................................................................................................................................................................................3-132
ΣLINE....................................................................................................................................................................................3-132
LINFIT ..................................................................................................................................................................................3-132
LININ ....................................................................................................................................................................................3-133
LINSOLVE...........................................................................................................................................................................3-133
LIST→ ...................................................................................................................................................................................3-133
→LIST ...................................................................................................................................................................................3-133
∆LIST.....................................................................................................................................................................................3-134
ΠLIST ....................................................................................................................................................................................3-134
ΣLIST.....................................................................................................................................................................................3-134
LN...........................................................................................................................................................................................3-134
LNAME.................................................................................................................................................................................3-136
LNCOLLECT ......................................................................................................................................................................3-136
LNP1 ......................................................................................................................................................................................3-136
LOCAL ..................................................................................................................................................................................3-137
LOG .......................................................................................................................................................................................3-137
LOGFIT ................................................................................................................................................................................3-138
LQ...........................................................................................................................................................................................3-138
LR............................................................................................................................................................................................3-138
LSQ.........................................................................................................................................................................................3-139
LU ...........................................................................................................................................................................................3-139
LVAR .....................................................................................................................................................................................3-140
MAD.......................................................................................................................................................................................3-140
MAIN.....................................................................................................................................................................................3-141
MANT....................................................................................................................................................................................3-141
MAP........................................................................................................................................................................................3-141
↓MATCH...............................................................................................................................................................................3-141
↑MATCH...............................................................................................................................................................................3-142
Contents - 8
Series and Parallel C (2, 7) .............................................................................................................................................5-12
Series and Parallel L (2, 8)..............................................................................................................................................5-13
Capacitive Energy (2, 9) .................................................................................................................................................5-13
Inductive Energy (2, 10) ................................................................................................................................................5-13
RLC Current Delay (2, 11) ............................................................................................................................................5-14
DC Capacitor Current (2, 12) .......................................................................................................................................5-14
Capacitor Charge (2, 13) ................................................................................................................................................5-14
DC Inductor Voltage (2, 14) .........................................................................................................................................5-15
RC Transient (2, 15) .......................................................................................................................................................5-15
RL Transient (2, 16)........................................................................................................................................................5-15
Resonant Frequency (2, 17)...........................................................................................................................................5-16
Plate Capacitor (2, 18) ....................................................................................................................................................5-16
Cylindrical Capacitor (2,19) ...........................................................................................................................................5-16
Solenoid Inductance (2, 20)...........................................................................................................................................5-17
Toroid Inductance (2, 21)..............................................................................................................................................5-17
Sinusoidal Voltage (2, 22) ..............................................................................................................................................5-18
Sinusoidal Current (2, 23) ..............................................................................................................................................5-18
Fluids (3) ..................................................................................................................................................................................5-18
Pressure at Depth (3, 1) .................................................................................................................................................5-19
Bernoulli Equation (3, 2) ...............................................................................................................................................5-19
Flow with Losses (3, 3) ..................................................................................................................................................5-20
Flow in Full Pipes (3, 4).................................................................................................................................................5-21
Forces and Energy (4)............................................................................................................................................................5-21
Linear Mechanics (4, 1)..................................................................................................................................................5-22
Angular Mechanics (4, 2) ...............................................................................................................................................5-23
Centripetal Force (4, 3) ..................................................................................................................................................5-23
Hooke’s Law (4, 4)..........................................................................................................................................................5-23
1D Elastic Collisions (4, 5)............................................................................................................................................5-24
Drag Force (4, 6).............................................................................................................................................................5-24
Law of Gravitation (4, 7) ...............................................................................................................................................5-24
Mass-Energy Relation (4, 8) ..........................................................................................................................................5-24
Gases (5) ..................................................................................................................................................................................5-25
Ideal Gas Law (5, 1)........................................................................................................................................................5-25
Ideal Gas State Change (5, 2) ........................................................................................................................................5-26
Isothermal Expansion (5, 3)..........................................................................................................................................5-26
Polytropic Processes (5, 4).............................................................................................................................................5-26
Isentropic Flow (5, 5) .....................................................................................................................................................5-26
Real Gas Law (5, 6).........................................................................................................................................................5-27
Real Gas State Change (5, 7) .........................................................................................................................................5-27
Kinetic Theory (5, 8) ......................................................................................................................................................5-28
Heat Transfer (6) ....................................................................................................................................................................5-28
Heat Capacity (6, 1) ........................................................................................................................................................5-29
Thermal Expansion (6, 2) ..............................................................................................................................................5-29
Conduction (6, 3) ............................................................................................................................................................5-29
Convection (6, 4).............................................................................................................................................................5-30
Conduction + Convection (6, 5) ..................................................................................................................................5-30
Black Body Radiation (6, 6)...........................................................................................................................................5-31
Magnetism (7) .........................................................................................................................................................................5-31
Straight Wire (7, 1)..........................................................................................................................................................5-32
Force between Wires (7, 2)............................................................................................................................................5-32
Magnetic (B) Field in Solenoid (7, 3) ...........................................................................................................................5-33
Magnetic (B) Field in Toroid (7, 4) ..............................................................................................................................5-33
Motion (8)................................................................................................................................................................................5-34
Linear Motion (8, 1)........................................................................................................................................................5-35
Object in Free Fall (8, 2)................................................................................................................................................5-35
Projectile Motion (8, 3) ..................................................................................................................................................5-35
Contents - 17
PA2B2 ....................................................................................................................................................................................3-162
PARAMETRIC ....................................................................................................................................................................3-162
PARITY.................................................................................................................................................................................3-163
PARSURFACE.....................................................................................................................................................................3-164
PARTFRAC ..........................................................................................................................................................................3-164
PATH.....................................................................................................................................................................................3-165
PCAR......................................................................................................................................................................................3-165
PCOEF ..................................................................................................................................................................................3-165
PCONTOUR........................................................................................................................................................................3-166
PCOV.....................................................................................................................................................................................3-166
PDIM .....................................................................................................................................................................................3-167
PERINFO .............................................................................................................................................................................3-167
PERM.....................................................................................................................................................................................3-167
PERTBL ................................................................................................................................................................................3-168
PEVAL...................................................................................................................................................................................3-168
PGDIR...................................................................................................................................................................................3-168
PICK.......................................................................................................................................................................................3-168
PICK3 ....................................................................................................................................................................................3-168
PICT .......................................................................................................................................................................................3-169
PICTURE..............................................................................................................................................................................3-169
PINIT.....................................................................................................................................................................................3-169
PIX?........................................................................................................................................................................................3-170
PIXOFF.................................................................................................................................................................................3-170
PIXON...................................................................................................................................................................................3-170
PKT ........................................................................................................................................................................................3-170
PLOT .....................................................................................................................................................................................3-171
PLOTADD ...........................................................................................................................................................................3-171
PMAX ....................................................................................................................................................................................3-171
PMIN .....................................................................................................................................................................................3-171
PMINI....................................................................................................................................................................................3-172
POLAR ..................................................................................................................................................................................3-172
POLYNOMIAL...................................................................................................................................................................3-173
POP ........................................................................................................................................................................................3-173
POS.........................................................................................................................................................................................3-174
POTENTIAL .......................................................................................................................................................................3-174
POWEXPAND....................................................................................................................................................................3-174
POWMOD............................................................................................................................................................................3-175
PR1 .........................................................................................................................................................................................3-175
PREDV..................................................................................................................................................................................3-176
PREDX..................................................................................................................................................................................3-176
PREDY..................................................................................................................................................................................3-177
PREVAL................................................................................................................................................................................3-177
PREVPRIME........................................................................................................................................................................3-178
PRLCD...................................................................................................................................................................................3-178
PROMPT...............................................................................................................................................................................3-178
PROMPTSTO ......................................................................................................................................................................3-178
PROOT..................................................................................................................................................................................3-179
PROPFRAC..........................................................................................................................................................................3-179
PRST.......................................................................................................................................................................................3-180
PRSTC....................................................................................................................................................................................3-180
PRVAR...................................................................................................................................................................................3-180
PSDEV...................................................................................................................................................................................3-181
PSI...........................................................................................................................................................................................3-181
Psi............................................................................................................................................................................................3-181
PTAYL...................................................................................................................................................................................3-182
PTPROP ................................................................................................................................................................................3-182
Contents - 10
UPDIR ...................................................................................................................................................................................3-265
UTPC .....................................................................................................................................................................................3-265
UTPF......................................................................................................................................................................................3-266
UTPN.....................................................................................................................................................................................3-266
UTPT......................................................................................................................................................................................3-267
UVAL.....................................................................................................................................................................................3-267
V→ .........................................................................................................................................................................................3-267
→V2 .......................................................................................................................................................................................3-268
→V3 .......................................................................................................................................................................................3-268
VANDERMONDE ............................................................................................................................................................3-269
VAR........................................................................................................................................................................................3-269
VARS......................................................................................................................................................................................3-270
VER ........................................................................................................................................................................................3-270
VERSION .............................................................................................................................................................................3-270
VISIT......................................................................................................................................................................................3-271
VISITB...................................................................................................................................................................................3-271
VPOTENTIAL ....................................................................................................................................................................3-271
VTYPE...................................................................................................................................................................................3-272
*W ...........................................................................................................................................................................................3-272
WAIT .....................................................................................................................................................................................3-272
WHILE ..................................................................................................................................................................................3-273
WIREFRAME ......................................................................................................................................................................3-273
WSLOG .................................................................................................................................................................................3-274
ΣX...........................................................................................................................................................................................3-275
ΣX2.........................................................................................................................................................................................3-275
ΣX^2 ......................................................................................................................................................................................3-276
XCOL.....................................................................................................................................................................................3-276
XGET ....................................................................................................................................................................................3-276
XMIT......................................................................................................................................................................................3-276
XNUM ...................................................................................................................................................................................3-277
XOR .......................................................................................................................................................................................3-277
XPON ....................................................................................................................................................................................3-278
XPUT .....................................................................................................................................................................................3-278
XQ ..........................................................................................................................................................................................3-278
XRECV..................................................................................................................................................................................3-279
XRNG....................................................................................................................................................................................3-279
XROOT.................................................................................................................................................................................3-279
XSEND..................................................................................................................................................................................3-280
XSERV...................................................................................................................................................................................3-280
XVOL.....................................................................................................................................................................................3-281
XXRNG.................................................................................................................................................................................3-281
ΣXY........................................................................................................................................................................................3-281
ΣX*Y......................................................................................................................................................................................3-281
ΣY ...........................................................................................................................................................................................3-282
ΣY2.........................................................................................................................................................................................3-282
ΣY^2.......................................................................................................................................................................................3-282
YCOL.....................................................................................................................................................................................3-282
YRNG ....................................................................................................................................................................................3-283
YSLICE..................................................................................................................................................................................3-283
YVOL.....................................................................................................................................................................................3-284
YYRNG .................................................................................................................................................................................3-284
ZEROS ..................................................................................................................................................................................3-284
ZFACTOR ............................................................................................................................................................................3-285
ZVOL.....................................................................................................................................................................................3-285
^ (Power) ...........................................................................................................................................................................3-285
| (Where) ...........................................................................................................................................................................3-286
Contents - 15
RND .......................................................................................................................................................................................3-205
RNRM....................................................................................................................................................................................3-206
ROLL .....................................................................................................................................................................................3-206
ROLLD..................................................................................................................................................................................3-206
ROMUPLOAD ....................................................................................................................................................................3-206
ROOT ....................................................................................................................................................................................3-207
ROT........................................................................................................................................................................................3-207
ROW– ....................................................................................................................................................................................3-207
ROW+ ...................................................................................................................................................................................3-208
ROW→..................................................................................................................................................................................3-208
→ROW..................................................................................................................................................................................3-208
RPL>......................................................................................................................................................................................3-209
RR ...........................................................................................................................................................................................3-209
RRB ........................................................................................................................................................................................3-209
rref...........................................................................................................................................................................................3-210
RREF......................................................................................................................................................................................3-210
RREFMOD...........................................................................................................................................................................3-211
RRK........................................................................................................................................................................................3-211
RRKSTEP .............................................................................................................................................................................3-212
RSBERR ................................................................................................................................................................................3-213
RSD ........................................................................................................................................................................................3-213
RSWP .....................................................................................................................................................................................3-214
RULES ...................................................................................................................................................................................3-214
R→B.......................................................................................................................................................................................3-214
R→C.......................................................................................................................................................................................3-215
R→D ......................................................................................................................................................................................3-215
R→I........................................................................................................................................................................................3-215
SAME.....................................................................................................................................................................................3-215
SBRK......................................................................................................................................................................................3-216
SCALE ...................................................................................................................................................................................3-216
SCALEH................................................................................................................................................................................3-216
SCALEW ...............................................................................................................................................................................3-216
SCATRPLOT........................................................................................................................................................................3-217
SCATTER .............................................................................................................................................................................3-217
SCHUR ..................................................................................................................................................................................3-218
SCI ..........................................................................................................................................................................................3-218
SCLΣ ......................................................................................................................................................................................3-218
SCONJ ...................................................................................................................................................................................3-219
SCROLL ................................................................................................................................................................................3-219
SDEV .....................................................................................................................................................................................3-219
SEND.....................................................................................................................................................................................3-219
SEQ ........................................................................................................................................................................................3-220
SERIES ..................................................................................................................................................................................3-220
SERVER................................................................................................................................................................................3-221
SEVAL ...................................................................................................................................................................................3-221
SF ............................................................................................................................................................................................3-221
SHOW....................................................................................................................................................................................3-222
SIDENS.................................................................................................................................................................................3-222
SIGMA...................................................................................................................................................................................3-222
SIGMAVX ............................................................................................................................................................................3-223
SIGN ......................................................................................................................................................................................3-223
SIGNTAB .............................................................................................................................................................................3-224
SIMP2.....................................................................................................................................................................................3-224
SIMPLIFY.............................................................................................................................................................................3-225
SIN..........................................................................................................................................................................................3-225
SINCOS.................................................................................................................................................................................3-225
Contents - 12
SINH ......................................................................................................................................................................................3-226
SINV.......................................................................................................................................................................................3-226
SIZE .......................................................................................................................................................................................3-226
SL ............................................................................................................................................................................................3-227
SLB .........................................................................................................................................................................................3-227
SLOPEFIELD......................................................................................................................................................................3-227
SNEG.....................................................................................................................................................................................3-228
SNRM.....................................................................................................................................................................................3-228
SOLVE...................................................................................................................................................................................3-229
SOLVEQN ...........................................................................................................................................................................3-229
SOLVER................................................................................................................................................................................3-230
SOLVEVX ............................................................................................................................................................................3-230
SORT......................................................................................................................................................................................3-230
SPHERE................................................................................................................................................................................3-231
SQ ...........................................................................................................................................................................................3-231
SR............................................................................................................................................................................................3-231
SRAD .....................................................................................................................................................................................3-231
SRB .........................................................................................................................................................................................3-232
SRECV...................................................................................................................................................................................3-232
SREPL....................................................................................................................................................................................3-233
SST..........................................................................................................................................................................................3-233
SST↓........................................................................................................................................................................................3-233
START ...................................................................................................................................................................................3-234
STD ........................................................................................................................................................................................3-234
STEP ......................................................................................................................................................................................3-235
STEQ .....................................................................................................................................................................................3-235
STIME....................................................................................................................................................................................3-235
STO ........................................................................................................................................................................................3-236
STOALARM.........................................................................................................................................................................3-236
STOF......................................................................................................................................................................................3-237
STOKEYS.............................................................................................................................................................................3-237
STORE...................................................................................................................................................................................3-238
STOVX ..................................................................................................................................................................................3-238
STO+ .....................................................................................................................................................................................3-238
STO– ......................................................................................................................................................................................3-239
STO* ......................................................................................................................................................................................3-239
STO/ ......................................................................................................................................................................................3-239
STOΣ......................................................................................................................................................................................3-240
STR→.....................................................................................................................................................................................3-240
→STR.....................................................................................................................................................................................3-240
STREAM ...............................................................................................................................................................................3-241
STRM .....................................................................................................................................................................................3-241
STURM ..................................................................................................................................................................................3-241
STURMAB ............................................................................................................................................................................3-242
STWS......................................................................................................................................................................................3-242
SUB.........................................................................................................................................................................................3-242
SUBST....................................................................................................................................................................................3-243
SUBTMOD ...........................................................................................................................................................................3-243
SVD ........................................................................................................................................................................................3-244
SVL .........................................................................................................................................................................................3-244
SWAP .....................................................................................................................................................................................3-244
SYSEVAL..............................................................................................................................................................................3-245
SYLVESTER ........................................................................................................................................................................3-245
SYST2MAT...........................................................................................................................................................................3-245
%T ..........................................................................................................................................................................................3-246
TABVAL ...............................................................................................................................................................................3-246
Contents - 13
Example: In the following program excerpt, the defining procedure for local variables d, e, and f calls a program
that you previously created and stored in global variable P1.
Continue the program.
Program:
Comments:
!=
«
:
→ a b c
«
a b + c +
→ d e f
'P1+a/(d*e+f)'
Defines local variables d, e, f.
Local variables a, b, c and d, e, f are available
in this procedure. The defining procedure
executes the program stored in variable P1.
a c / »
:
»
The six local variables are not available in program P1 because they didn’t exist when you created P1. The objects
stored in the local variables are available to program P1 only if you put those objects on the stack for P1 to use or
store those objects in global variables.
Conversely, program P1 can create its own local variable structure (with any names, such as a, c, and f, for example)
without conflicting with the local variables of the same name in the procedure that calls P1. It is possible to create a
special type of local variable that can be used in other programs or subroutines. This type of local variable is called a
compiled local variable.
Compiled Local Variables
Global variables use up memory, and local variables can’t be used outside of the program they were created in.
Compiled local variables bridge the gap between these two variable types. To programs, compiled local variables
look like global variables, but to the calculator they act like local variables. This means you can create a compiled
local variable in a local variable structure, use it in any other program that is called within that structure, and when
the program finishes, the variable is gone.
Compiled local variables have a special naming convention: they must begin with a ←. For example,
«
Note that when program execution is suspended by PROMPT, you can execute calculator operations just as you did
before you started the program. If the outer radius b of the torus in the previous example is measured as 0.83 feet,
you can convert that value to inches while the program is suspended for data input by pressing .83 `12 *, then
!=.
Using DISP FREEZE HALT, CONT for Input
DISP FREEZE HALT lets you control the entire display during input, and allows the user to use normal keyboard
operations during input.
To enter DISP FREEZE HALT in a program:
1. Enter a string or other object to be displayed as a prompt.
2. Enter a number specifying the line to display it on.
3. Enter the DISP command (PRG OUT menu).
4. Enter a number specifying the areas of the display to “freeze.”
5. Enter the FREEZE command (PRG OUT menu).
6. Enter the HALT command (PRG OUT menu).
« … prompt-object display-line DISP
freeze-area FREEZE HALT … »
DISP displays an object in a specified line of the display. DISP takes two arguments from the stack: an object from
level 2, and a display-line number 1 through 7 from level 1. If the object is a string, it’s displayed without the ""
delimiters. The display created by DISP persists only as long as the program continues execution — if the program
ends or is suspended by HALT, the calculator returns to the normal stack environment and updates the display.
However, you can use FREEZE to retain the prompt display.
FREEZE “freezes” display areas so they aren’t updated until a key press. Argument n in level 1 is the sum of the
codes for the areas to be frozen: 1 for the status area, 2 for the stack/command line area, 4 for the menu area.
HALT suspends program execution at the location of the HALT command and turns on the HALT annunciator.
Calculator control is returned to the keyboard for normal operations.
When execution resumes, the input remains on the stack as entered.
→ ←y
To respond to HALT while running a program:
'IFTE(←y<0,BELOW,ABOVE)'
1. Enter your input — you can use keyboard operations to calculate the input.
2. Press !=.
»
The variable ←y is a compiled local variable that can be used in the two programs BELOW and ABOVE.
Example: If you execute this program segment
Creating User-Defined Functions as Programs
« "ABCDEFGHI" CLLCD 3 DISP 2 FREEZE HALT »
The display looks like this:
The defining procedure for a local variable structure can be either an algebraic or program object.
A program that consists solely of a local variable structure whose defining procedure is an algebraic expression is a
user-defined function.
1-10 RPL Programming
RPL Programming 1-39
If neither object is an algebraic or a name, returns 1. if the two objects are the same type and have the same value,
or 0. otherwise. For example, if 6 is stored in X, X 5 < puts 6 and 5 on the stack, then removes them and
returns 0.. (Lists and programs are considered to have same value if the objects they contain are identical. For
strings, “less than” means “alphabetically previous.”)
If one object is an algebraic (or name) and the other object is an algebraic (or name) or a number, returns an
expression that must be evaluated to get a test result based on numeric values. For example, if 6 is stored in X,
'X' 5 < returns 'X<5', then →NUM returns 0..
(Note that == is used for comparisons, while = separates two sides of an equation.)
SAME returns 1. (true) if two objects are identical. For example, 'X+3' 4 SAME returns 0. regardless of the value
of X because the algebraic 'X+3' is not identical to the real number 4. Binary integers must have the same
wordsize and the same value to be identical. For all object types other than algebraics, names, and binary integers,
SAME works just like ==.
Input
A program can stop for user input, then resume execution, or can use choose boxes or input forms (dialog boxes)
for input. You can use several commands to get input:
PROMPT (!=to resume).
DISP FREEZE HALT (!=to resume).
INPUT (`to resume).
INFORM
CHOOSE
Data Input Commands
You can use any comparison function (except SAME) in an algebraic by putting it between its two arguments. For
example, if 6 is stored in X, 'X<5' →NUM returns 0..
Key
Using Logical Functions
Logical functions return a test result based on the outcomes of one or two previously executed tests. Note that
these four functions interpret any nonzero argument as a true result.
Logical Functions
Keys
Programmable
Command
AND
%OR%
OR
%XOR%
XOR
%NOT%
NOT
Returns 1. (true) only if both
arguments are true (0. otherwise).
Returns 1. (true) if either or both
arguments are true (0. otherwise).
Returns 1. (true) if either argument,
but not both, is true (0. otherwise).
Description
!°L %IN% :
%INFOR%
INFORM
Creates a user-defined input form.
%NOVAL%
NOVAL
Place holder for the INFORM command. Returned when a value is not present in
an input form field.
%CHOOS%
CHOOSE
%KEY%
KEY
Returns a test result to level 1 and, if a key is pressed, the location of that key (level
2).
%WAIT%
WAIT
Suspends program execution for a specified duration (in seconds, level 1).
%INPUT%
INPUT
Suspends program execution for data input.
%PROMP%
PROMPT
Description
!°%TEST% L
%AND%
Command
Creates a user-defined choose box.
Halts program execution for data input.
Using PROMPT, CONT for Input
PROMPT uses the status area for prompting, and allows the user to use normal keyboard operations during input.
Returns 1. (true) if the argument is 0
(false); otherwise, returns 0. (false).
To enter PROMPT in a program:
AND, OR, and XOR combine two test results. For example, if 4 is stored in Y, Y 8 < 5 AND returns 1.. First,
Y 8 < returns 1. to the stack. AND removes 1. and 5 from the stack, interpreting both as true results, and returns
1. to the stack.
1. Enter a string ( with "" delimiters) to be displayed as a prompt in the status area.
2. Enter the PROMPT command (PRG IN menu).
« … "prompt-string" PROMPT … »
NOT returns the logical inverse of a test result. For example, if 1 is stored in X and 2 is stored in Y, X Y < NOT
returns 0.
PROMPT takes a string argument from level 1, displays the string (without the "" delimiters) in the status area, and
halts program execution. Calculator control is returned to the keyboard.
You can use AND, OR, and XOR in algebraics as infix functions. For example, '3<5 XOR 4>7'
returns 1.
When execution resumes, the input is left on the stack as entered.
NUM
You can use NOT as a prefix function in algebraics. For example, 'NOT Z‰4' →NUM returns 0. if Z = 2.
To respond to PROMPT while running a program:
1. Enter your input — you can use keyboard operations to calculate the input.
2. Press !=.
The message remains until you press `or − or until you update the status area.
1-12 RPL Programming
RPL Programming 1-37
« … IF test-clause
THEN true-clause ELSE false-clause END … »
Making an Error Trap
IF … THEN … ELSE … END executes either the true-clause sequence of commands if the test-clause is true, or the
false-clause sequence of commands if the test-clause is false. If the test-clause is an algebraic, it’s automatically evaluated
to a number — you don’t need →NUM or EVAL.
You can construct an error trap with one of the following conditional structures:
IFERR … THEN … END.
IFERR … THEN … ELSE … END.
IF begins the test-clause, which leaves a test result on the stack. THEN removes the test result from the stack. If the
value is nonzero, the true-clause is executed — otherwise, the false-clause is executed. After the appropriate clause is
executed, execution resumes following END. See “Conditional Examples” on page 1-15.
The syntax for this structure is
« … IFERR trap-clause THEN error-clause END … »
To enter IF 7 THEN 7 ELSE 7 END in a program:
Press !°%BRCH% @%#IF#% .
The IFTE Function
The algebraic syntax for this function is 'IFTE( test, true-clause, false-clause)'
If test evaluates true, the true-clause algebraic is evaluated — otherwise, the false-clause algebraic is evaluated.
You can also use the IFTE function with stack syntax. It takes three arguments: a test-result in level 3, a true-clause
object in level 2, and a false-clause object in level 1. See “Conditional Examples” on page 1-15.
To enter IFTE in a program or in an algebraic:
Press !°%BRCH% L!%IFTE% .
The CASE 7 END Structure
The syntax for this structure is
« … CASE
The IFERR 7 THEN 7 END Structure
The commands in the error-clause are executed only if an error is generated during execution of the trap-clause. If
an error occurs in the trap-clause, the error is ignored, the remainder of the trap-clause is skipped, and program
execution jumps to the error-clause. If no errors occur in the trap-clause, the error-clause is skipped and execution
resumes after the END command.
To enter IFERR 7 THEN 7 END in a program:
Press !°LL %ERROR% !%IFERR%.
Example: The following program takes any number of vectors or arrays from the stack and adds them to the
statistics matrix. However, the program stops with an error if a vector or array with a different number of columns
is encountered. In addition, if only vectors or arrays with the same number of columns are on the stack, the
program stops with an error after the last vector or array has been removed from the stack.
« WHILE DUP TYPE 3 == REPEAT Σ+ END »
In the following revised version, the program simply attempts to add the level 1 object to the statistics matrix until
an error occurs. Then, it ends by displaying the message DONE.
test-clause1 THEN true-clause1 END
Program:
test-clause2 THEN truet-clause2 END
...
«
test-clausen THEN true-clausen END
default-clause (optional)
END … »
The CASE … END structure lets you execute a series of test-clause commands, then execute the appropriate trueclause sequence of commands. The first test that returns a true result causes execution of the corresponding trueclause, ending the CASE … END structure. Optionally, you can include after the last test a default-clause that’s
executed if all the tests evaluate to false. If a test-clause is an algebraic, it’s automatically evaluated to a number —
you don’t need →NUM or EVAL.
When CASE is executed, test-clause1 is evaluated. If the test is true, true-clause1 is executed, and execution skips to
END. If test-clause1 is false, execution proceeds to test-clause2. Execution within the CASE structure continues
until a true-clause is executed, or until all the test-clauses evaluate to false. If a default clause is included, it’s
executed if all the test-clauses evaluate to false. See “Conditional Examples” below.
1-14 RPL Programming
Comments:
IFERR
Starts the trap-clause.
WHILE
1
REPEAT
Σ+
END
THEN
"DONE" 1 DISP
1 FREEZE
The WHILE structure repeats
indefinitely, adding the vectors
and arrays to the statistics matrix
until an error occurs.
END
»
Starts the error clause. If an error
occurs in the WHILE structure,
displays the message DONE in
the status area.
Ends the error structure.
RPL Programming 1-35
Example: Two Conditional Actions. This program takes a value x from the stack and calculates (sin x)/x. At x
= 0 the division would error, so the program returns the limit value 1 in this case.
« → x « IF 'x‹0' THEN x SIN x / ELSE 1 END » »
The following version uses IFTE algebraic syntax:
« → x 'IFTE(x‹0,SIN(x)/x,1' »
Example: Two Conditional Actions. This program multiplies two numbers together if they’re both nonzero —
otherwise, it returns the string “ZERO”.
Program:
Comments:
«
→ n1 n2
Creates the local variables.
«
IF
'n1‹0 AND n2‹0'
THEN
n1 n2 *
Starts the defining procedure.
Starts the test clause.
Tests n1 and n2.
If both numbers are nonzero, multiplies the two
values.
Otherwise, returns the string ZERO.
ELSE
"ZERO"
END
»
»
Ends the conditional.
Comments:
«
IF
DUP2
SAME
THEN
DROP
'V1' STO
ELSE
'V1' STO
'V2' STO
END
Key
Programmable
Command
Description
!°LL%RUN% :
%DBUG%
DBUG
Starts program execution, then suspends it as if HALT were the first
program command. Takes as its argument the program or program name
in level 1.
Executes the next object or command in the suspended program.
%SST%
%SST°%
Same as %SST%, except if the next program step is a subroutine, single-steps
to the first step in that subroutine.
%NEXT%
Displays the next one or two objects, but does not execute them. The
display persists until the next keystroke.
%HALT%
HALT
Suspends program execution at the location of the HALT command in
the program.
%KILL%
KILL
Cancels all suspended programs and turns off the HLT annunciator.
!=
CONT
Resumes execution of a halted program.
Ends the defining procedure.
Example: Two Conditional Actions. This program tests if two numbers on the stack have the same value. If
so, it drops one of the numbers and stores the other in variable V1 — otherwise, it stores the number from level 1
in V1 and the number from level 2 in V2.
Program:
Single-Step Operations
For the test clause, copies the numbers in levels 1 and
2 and tests if they have the same value.
For the true clause, drops one of the numbers and
stores the other in V1.
For the false clause, stores the level 1 number in V1
and the level 2 number in V2.
Ends the conditional structure.
»
`
Puts the program on the stack.
OTST K
Stores it in TST.
Enter the numbers 26 and 52, then execute TST to compare their values. Because the two numbers aren’t equal, the
VAR menu now contains two new variables V1 and V2.
Trapping Errors
If you attempt an invalid operation from the keyboard, the operation is not executed and an error message appears.
For example, if you execute + with a vector and a real number on the stack, the calculator returns the message +
Error: Bad Argument Type and returns the arguments to the stack (if Last Arguments is enabled).
In a program, the same thing happens, but program execution is also aborted. If you anticipate error conditions,
your program can process them without interrupting execution.
For simple programs, you can run the program again if it stops with an error. For other programs, you can design
them to trap errors and continue executing. You can also create user-defined errors to trap certain conditions in
programs. The error trapping commands are located in the PRG ERROR menu.
Causing and Analyzing Errors
Many conditions are automatically recognized by the calculator as error conditions — and they’re automatically
treated as errors in programs.
You can also define conditions that cause errors. You can cause a user-defined error (with a user-defined error message)
— or you can cause a built-in error. Normally, you’ll include a conditional or loop structure with a test for the error
condition — and if it occurs, you’ll cause the user-defined or built-in error to occur.
To cause a user-defined error to occur in a program:
1. Enter a string (with "" delimiters) containing the desired error message.
2. Enter the DOERR command (PRG ERROR menu).
26 `52 J %TST%
1-16 RPL Programming
RPL Programming 1-33
The START 7 NEXT Structure
Single-Stepping through a Program
The syntax for this structure is
« … start finish START loop-clause NEXT … »
START … NEXT executes the loop-clause sequence of commands one time for each number in the range start to
finish. The loop-clause is always executed at least once.
Syntax
Flowchart
Start
finish
1:Start
2:finish
START
counter=start
Store finish
To single-step from the start of a program:
1. Put the program or program name in level 1 (or the command line).
2. Press !°LL%RUN% %DBUG% to start and immediately suspend execution. HLT appears in the status area.
3. Take any action:
To see the next program step displayed in the status area and then executed, press %SST%.
To display but not execute the next one or two program steps, press %NEXT%.
To continue with normal execution, press !=.
To abandon further execution, press %KILL%.
4. Repeat the previous step as desired.
To turn off the HALT annunciator at any time:
Body of loop
loop-clause
It’s easier to understand how a program works if you execute it step by step, observing the effect of each step.
Doing this can help you debug your own programs or understand programs written by others.
Press !°LL %RUN% %KILL%.
counter = counter + 1
Example: Execute program TORSV step by step. Use a = 6 and b = 8.
NEXT
Is
counter ≤ finish?
yes
Select the VAR menu and enter the data. Enter the program name and start the debugging. HLT indicates program
execution is suspended.
@· J6 `8 `O%TORSV%
no
START 7 NEXT Structure
START takes two numbers (start and finish) from the stack and stores them as the starting and ending values for a
loop counter. Then, the loop-clause is executed. NEXT increments the counter by 1 and tests to see if its value is
less than or equal to finish. If so, the loop-clause is executed again — otherwise, execution resumes following
NEXT.
!°LL%RUN% %DBUG%
Display and execute the first program step. Notice that it takes the two arguments from the stack and stored
them in local variables a and b.
%SST%
To enter START 7 NEXT in a program:
Press !°%BRCH% !%START%.
Example: The following program creates a list containing 10 copies of the string "ABC":
« 1 10 START "ABC" NEXT 10 →LIST »
Continue single-stepping until the status area shows the current directory. Watch the stack and status area
as you single-step through the program.
%SST% … %SST%.
1-18 RPL Programming
RPL Programming 1-31
The FOR 7 NEXT Structure
To recall the current flag states:
The syntax for this structure is
« … start finish FOR counter loop-clause NEXT … »
FOR … NEXT executes the loop-clause program segment one time for each number in the range start to finish,
using local variable counter as the loop counter. You can use this variable in the loop-clause. The loop-clause is
always executed at least once.
Syntax
Flowchart
Start
finish
1:Start
2:finish
Execute RCLF (!°L %MODES% %FLAG% L%RCLF% ).
RCLF returns a list containing four 64-bit binary integers representing the current states of the lower and upper
groups of system and user flags:
{ #nsystem-lower #nuser-lower #nsystem-upper #nuser-upper }
To change the current flag states:
1. Enter the flag-state argument — see below
2. Execute STOF (!°L %MODES% %FLAG% L%STOF% ).
STOF sets the current states of flags based on the flag-state argument:
# ns
Changes the states of only the system flags.
{ #ns-lower #nu-lower #ns-upper #nu-upper} Changes the states of the system and user flags.
FOR
loop-clause
counter=start
Store finish
Example: The program PRESERVE on page 2-6 uses RCLF and STOF.
Body of loop
Using Subroutines
Because a program is itself an object, it can be used in another program as a subroutine. When program B is used by
program A, program A calls program B, and program B is a subroutine in program A.
counter = counter + 1
NEXT
Is
counter ≤ finish?
yes
Example: The program TORSA calculates the surface area of a torus of inner radius a and outer radius b. TORSA
is used as a subroutine in a second program TORSV, which calculates the volume of a torus.
no
FOR 7 NEXT Structure
FOR takes start and finish from the stack as the beginning and ending values for the loop counter, then creates the
local variable counter as a loop counter. Then the loop-clause is executed — counter can appear within the loop-clause.
NEXT increments counter by one, and then tests whether its value is less than or equal to finish. If so, the loop-clause is
repeated (with the new value of counter) — otherwise, execution resumes following NEXT. When the loop is exited,
counter is purged.
The surface area and volume are calculated by
To enter FOR 7 NEXT in a program:
Here are the stack diagram and program listing for TORSA.
2
2
2
A = π (b – a )
(The quantity
2
2
2
π (b – a )
1 2 2
2
V = --- π ( b – a ) ( b – a )
4
in the second equation is the surface area of a torus calculated by TORSA.)
Press !°%BRCH% ! %FOR%.
Example: The following program places the squares of the integers 1 through 5 on the stack:
« 1 5 FOR j j SQ NEXT »
Example: The following program takes the value x from the stack and computes the integer powers i of x. For
example, when x =12 and start and finish are 3 and 5 respectively, the program returns 123, 124 and 125. It requires as
inputs start and finish in level 3 and 2, and x in level 1. (→ x removes x from the stack, leaving start and finish there
as arguments for FOR.)
Level 2
Level 1
→
Level 1
a
b
→
surface area
« → x « FOR n 'x^n' EVAL NEXT » »
1-20 RPL Programming
RPL Programming 1-29
Example: The following program takes n from the stack, and returns the series of numbers 1, 2, 4, 8, 16, …, n. If n
isn’t in the series, the program stops at the last value less than n.
« 1 SWAP FOR n n n STEP »
The first n is the local variable declaration for the FOR loop. The second n is put on the stack each iteration of the
loop. The third n is used by STEP as the step increment.
Using Flags
You can use flags to control calculator behavior and program execution. You can think of a flag as a switch that is
either on (set) or off (clear). You can test a flag’s state within a conditional or loop structure to make a decision.
Because certain flags have unique meanings for the calculator, flag tests expand a program’s decision-making
capabilities beyond that available with comparison and logical functions.
Using Indefinite Loop Structures
Types of Flags
The DO 7 UNTIL 7 END Structure
The calculator has two types of flags:
System flags. Flags –1 through –128. These flags have predefined meanings for the calculator.
User flags. Flags 1 through 128. User flags are, for the most part, not used by any built-in operations. What they
mean depends entirely on how the program uses them.
The syntax for this structure is
« … DO loop-clause UNTIL test-clause END … »
DO… UNTIL… END executes the loop-clause sequence repeatedly until test-clause returns a true (nonzero) result.
Because the test-clause is executed after the loop-clause, the loop-clause is always executed at least once.
Syntax
Flowchart
Appendix C lists the 128 system flags and their definitions. For example, system flag –40 controls the clock display
— when this flag is clear (the default state), the clock is not displayed — when this flag is set, the clock is displayed.
(When you press %CLK% in the H%MISC% menu, you are setting or clearing flag –40.)
Note that for these calculators, there are no display annunciators to indicate that user flags 1 through 5 are set, like
the older HP 48S-series and HP 48G-series calculators.
DO
loop-clause
Body of loop
UNTIL
TEST
Setting, Clearing, and Testing Flags
Flag commands take a flag number from the stack — an integer 1 through 128 (for user flags) or –1 through –128
(for system flags).
To set, clear, or test a flag:
test-clause
1: test result
END
Is test
result non-zero?
1. Enter the flag number (positive or negative).
2. Execute the flag command — see the table below.
Flag Commands
no
yes
DO 7 UNTIL 7 END Structure
DO starts execution of the loop-clause. UNTIL marks the end of the loop-clause. The test-clause leaves a test
result on the stack. END removes the test result from the stack. If its value is zero, the loop-clause is executed again
— otherwise, execution resumes following END. If the argument of END is an algebraic or a name, it’s
automatically evaluated to a number.
Key
Programmable
Command
!°%TEST% LL:
%SF%
SF
Sets the flag.
%CF%
CF
Clears the flag.
%FS?%
FS?
Returns 1. (true) if the flag is set, or
0. (false) if the flag is clear.
%FC?%
FC?
Returns 1. (true) if the flag is clear,
or 0. (false) if the flag is set.
%FS?C%
FS?C
Tests the flag (returns true if the
flag is set), then clears the flag.
%FC?C%
FC?C
Tests the flag (returns true if the
flag is clear), then clears the flag.
To enter DO 7 UNTIL 7 END in a program:
Press !°%BRCH% ! %DO%.
1-22 RPL Programming
Description
RPL Programming 1-27
The WHILE 7 REPEAT 7 END Structure
Using Loop Counters
The syntax for this structure is
« … WHILE test-clause REPEAT loop-clause END … »
WHILE … REPEAT … END repeatedly evaluates test-clause and executes the loop-clause sequence if the test is true.
Because the test-clause is executed before the loop-clause, the loop-clause is not executed if the test is initially false.
Syntax
Flowchart
For certain problems you may need a counter inside a loop structure to keep track of the number of loops. (This
counter isn’t related to the counter variable in a FOR … NEXT/STEP structure.) You can use any global or local
variable as a counter. You can use the INCR or DECR command to increment or decrement the counter value and
put its new value on the stack.
The syntax for INCR and DECR is
« … 'variable' INCR … »
or
« … 'variable' DECR … »
WHILE
To enter INCR or DECR in a program:
TEST
test-clause
1: test result
REPEAT
no
Is test
result non-zero?
yes
loop-clause
Body of loop
Press !° #MEM# %ARITH% %INCR% or %DECR%.
The INCR and DECR commands take a global or local variable name (with ' delimiters) as their argument — the
variable must contain a real number. The command does the following:
1. Changes the value stored in the variable by +1 or -1.
2. Returns the new value to the stack.
Example: If c contains the value 5, then 'c' INCR stores 6 in c and returns 6 to the stack.
Example: The following program takes a maximum of five vectors from the stack and adds them to the current
statistics matrix.
Program:
Comments:
«
END
WHILE 7 REPEAT 7 END Structure
WHILE starts execution of the test-clause, which returns a test result to the stack. REPEAT takes the value from
the stack. If the value is nonzero, execution continues with the loop-clause-otherwise, execution resumes following
END. If the argument of REPEAT is an algebraic or a name, it’s automatically evaluated to a number.
To enter WHILE 7 REPEAT 7 END in a program:
Press !°%BRCH% ! %WHILE%.
Example: The following program starts with a number on the stack, and repeatedly performs a division by 2 as
long as the result is evenly divisible. For example, starting with the number 24, the program computes 12, then 6,
then 3.
« WHILE DUP 2 MOD 0 == REPEAT 2 / DUP END DROP »
Example: The following program takes any number of vectors or arrays from the stack and adds them to the
statistics matrix. (The vectors and arrays must have the same number of columns.)
0 → c
Stores 0 in local variable c.
«
WHILE
DUP TYPE 3 ==
Starts the defining procedure.
Starts the test clause.
Returns true if level 1 contains a vector.
'c' INCR
5 ‰
AND
REPEAT
Σ+
END
»
»
Increments and returns the value in c.
Returns true if the counter c≤5.
Returns true if the two previous test
results are true.
Adds the vector to ΣDAT.
Ends the structure.
Ends the defining procedure.
WHILE … REPEAT … END is used instead of DO … UNTIL … END because the test must be done before
the addition. (If only vectors or arrays with the same number of columns are on the stack, the program errors after
the last vector or array is added to the statistics matrix.)
« WHILE DUP TYPE 3 == REPEAT Σ+ END »
1-24 RPL Programming
RPL Programming 1-25
To include INPUT options:
Use a list (with {} delimiters) as the command-line argument for INPUT. The list can contain one more of the
following:
Command-line string (with "" delimiters).
Cursor position as a real number or as a list containing two real numbers.
Operating options ALG, Œ, or V.
EXCO (Expand and Collect Completely)
EXCO repeatedly executes EXPAN on an algebraic until the algebraic doesn’t change, then repeatedly executes
COLCT until the algebraic doesn’t change. In some cases the result will be a number.
Expressions with many products of sums or with powers can take many iterations of EXPAN to expand
completely, resulting in a long execution time for EXCO.
In its general form, the level 1 argument for INPUT is a list that specifies the content and interpretation of the
command line. The list can contain one or more of the following parameters in any order:
Level 1
→
Level 1
'algebraic'
→
'algebraic'
'algebraic'
→
z
{ "command-line" cursor-position operating-options }
“Command-line”
Cursor-position
Specifies the content of the command line when the program pauses. Embedded
newline characters produce multiple lines in the display. (If not included, the
command line is blank.)
Specifies the position of the cursor in the command line and its type. (If not
included, an insert cursor is at the end of the command line.)
A real number n specifies the nth character in the first row (line) of the command
line. Zero specifies the end of the command-line string. A positive number
specifies the insert cursor — a negative number specifies the replace cursor.
A list {row character} specifies the row and character position. Row 1 is the first
row (line) of the command line. Characters count from
Techniques used in EXCO
Subroutines. EXCO calls the program MULTI twice. It is more efficient to create program MULTI and simply
call its name twice than write each step in MULTI two times.
Required Programs
MULTI (Multiple Execution) repeatedly executes the programs that EXCO provides as arguments.
EXCO program listing
Program:
the left end of each row — character 0 specifies the end of the row. A positive row
number specifies the insert cursor — a negative row number specifies the replace
cursor.
operating-options
Specify the input setup and processing using zero or more of these unquoted names:
ALG activates Algebraic/Program-entry mode (for algebraic syntax). (If not
included, Program-entry mode is active.)
Œ (~…a) specifies alpha lock. (If not included, alpha is inactive.)
V verifies whether the result string (without the "" delimiters) is a valid object or
sequence of objects. If the result string isn’t valid, INPUT displays the Invalid
Syntax message and prompts again for data. (if not included, syntax isn’t
checked.)
To design the command-line string for INPUT:
For simple input, use a string that produces a valid object:
Use an empty string
Use a :label : tag.
Use a @ text @ comment.
For special input, use a string that produces a recognizable pattern.
After the user enters input in the command line and presses ` to resume execution, the contents of the
command line are returned to level 1 as the result string. The result string normally contains the original commandline string, too. If you design the command-line string carefully, you can ease the process of extracting the input
data.
1-42 RPL Programming
Comments:
«
« EXPAN »
Puts a program on the stack as
the level 1 argument for MULTI.
The program executes the
EXPAN command.
MULTI
Executes EXPAN until the
algebraic object doesn’t change.
« COLCT »
Puts another program on the
stack for MULTI. The program
executes the COLCT command.
MULTI
Executes COLCT until the
algebraic object doesn’t change.
»
`OEXCO K
Stores the program in EXCO.
Checksum: # 41162d
Bytes:
65.5
Example: Expand and collect completely the expression:
2
3x(4y + z) + (8x – 5z)
Enter the expression.
O3 * X *
RPL Programming Examples 2-15
Execute TINPUT to calculate the surface area of a torus of inner radius a = 10 and outer radius b = 20.
Program:
J %TINPU%
Comments:
Combines all the medians into an m-element vector.
Restores ΣDAT to its previous value.
m →ARRY
s STOΣ
Ends the defining procedure.
»
»
`OMEDIAN K
Stores the program in MEDIAN.
Key in the value for a, press ˜ to move the cursor to the next prompt, then key in the value for b.
Checksum: # 256d
Bytes:
140
10 ˜20
Example: Calculate the median of the following data.
18
4
3
11
31
20
Continue program execution.
12
7
2
1
48
17
There are two columns of data, so MEDIAN will return a two-element vector.
`
Enter the matrix.
Example: The following program executes INPUT to prompt for a social security number, then extracts two
strings: the first three digits and last four digits. The level 1 argument for INPUT specifies:
A command-line string with dashes.
The replace cursor positioned at the start of the prompt string ( –1). This lets the user “fill in” the command line
string, using ™to skip over the dashes in the pattern.
By default, no verification of object syntax — the dashes make the content invalid as objects
Level 1
‚Ù%OK% %EDIT%
18 `12 `˜šš
4 `7 `
3 `2 `
11 `1 `
31 `48 `
→
Level 2
Level 1
→
“last four digits“
“first three digits“
20 `17 `
` %OK%
The matrix is now stored in ΣDAT.
Calculate the median.
J %MEDIA%
Clear approximate mode (set exact mode) before going on to the next example.
Expanding and Collecting Completely
This section contains two programs:
MULTI repeats a program until the program has no effect on its argument.
EXCO calls MULTI to completely expand and collect an algebraic.
1-44 RPL Programming
RPL Programming Examples 2-13
You can specify a help message and the type of data that must be entered in field by entering field specifications as
lists. For example, { { "Name:" "Enter your name" 2 } } defines the Name field, displays
Enter your name across the bottom of the input form, and accepts only object type 2 (strings) as input.
To set up a choose box:
1. Enter a title string for the choose box.
2. Enter a list of items. If this is a list of two-element lists, the first element is displayed in the choose box, and the
second element is returned to level 2 when OK is pressed.
3. Enter a position number for the default highlighted item. (0 makes a view-only choose box.)
4. Execute the CHOOSE command.
Techniques used in %TILE
FLOOR and CEIL. For an integer, FLOOR and CEIL both return that integer; for a noninteger, FLOOR and
CEIL return successive integers that bracket the noninteger.
SORT. The SORT command sorts the list elements into ascending order.
%TILE program listing
Program:
Comments:
«
Example: Enter a title "FIRST ONE" `.
Enter a list of items { ONE TWO THREE } `.
Enter a position number for default highlighted value 3 `.
Execute CHOOSE (!°L%IN% %CHOOS%).
SWAP SORT
DUP SIZE
Brings the list to level 1 and sorts it.
Copies the list, then finds its size.
1 + ROT %
Calculates the position of the specified percentile.
DUP2
Makes a copy of the list and the percentile.
Example: The following choose box appears:
FLOOR
Rounds the position to the lower integer.
1 MAX OVER SIZE MIN
Ensures it is between 1 and the size of the list.
GET
ROT ROT
Gets the corresponding number.
Moves the list to level 1.
CEIL
Rounds the position to the upper integer.
1 MAX OVER SIZE MIN
Ensures it is between 1 and the size of the list.
Example: The following program uses input forms, choose boxes, and message boxes to create a simple phone list
database.
Program:
Comments:
«
'NAMES' VTYPE
IF -1 ==
THEN { } 'NAMES' STO
END
WHILE
"PHONELIST OPTIONS:"
{
{ "ADD A NAME" 1 }
{ "VIEW A NUMBER" 2 }
} 1 CHOOSE
REPEAT → c «
CASE c 1 ==
THEN
WHILE
1-46 RPL Programming
Checks if the name list
(NAMES) exists, if not, creates
an empty one.
While cancel is not pressed,
creates a choose box that lists
the database options. When
OK is pressed, the second
item in the list pair is returned
to the stack.
Stores the returned value in c.
Case 1 (ADD name), while
cancel is not pressed, do the
following:
Gets the corresponding number.
Calculates the average of the two numbers.
GET
+ 2 /
»
`O%TILE K
Stores the program in %TILE.
Checksum: # 3805d
Bytes:
92.5
Example: Calculate the median of the list {8 3 1 5 2}.
!ä8 3 1 5 2`
J50 %©TILE%
MEDIAN (Median of Statistics Data)
MEDIAN returns a vector containing the medians of the columns of the statistics data. Note that for a sorted list
with an odd number of elements, the median is the value of the center element; for a list with an even number of
elements, the median is the average value of the elements just above and below the center.
Level 1
→
Level 1
→
[ x1 x2 xm ]
RPL Programming Examples 2-11
You can delete names and numbers by editing the NAMES variable.
To improve upon this program, create a delete name routine.
BDISP program listing
Program:
Beeping to Get Attention
Comments:
«
To enter BEEP in a program:
Begins the main nested program.
«
1. Enter a number that specifies the tone frequency in hertz.
2. Enter a number that specifies the tone duration in seconds.
3. Enter the BEEP command (!°L%OUT% L menu).
« … frequency duration BEEP … »
DUP
Makes a copy of n.
-55 CF
Clears flag –55 to enable LASTARG.
Begins error trap.
IFERR
R→B
BEEP takes two arguments from the stack: the tone frequency from level 2 and the tone duration from level 1.
Example: The following edited version of TPROMPT sounds a 440-hertz, one-half-second tone at the prompt for
data input.
Program:
Comments:
«
"ENTER a, b IN ORDER:"
440 .5 BEEP
PROMPT
TORSA
Sounds a tone just
before the prompt for
data input.
»
THEN
END
If an error occurs, do nothing (no commands in
the THEN clause).
→ n
«
CLLCD
Creates a local variable n and begins the defining
program.
Clears the display.
« BIN »
« OCT »
Nested program for BIN.
Nested program for OCT.
« DEC »
Nested program for DEC.
« HEX »
Nested program for HEX.
1 4
FOR j
Stopping a Program for Keystroke Input
Converts n to a binary integer.
Sets the counter limits.
Starts the loop with counter j.
EVAL
Executes one of the nested base programs
(initially for HEX).
n →STR
Makes a string showing n in the current base.
Using WAIT for Keystroke Input
PAD
Pads the string to 22 characters.
The WAIT command normally suspends execution for a specified number of seconds. However, you can specify
that it wait indefinitely until a key is pressed.
j DISP
Displays the string in the jth line.
A program can stop for keystroke input — it can wait for the user to press a key. You can do this with the WAIT
and KEY commands.
To enter WAIT in a program
To stop without changing the display, enter 0 and the WAIT command (PRG IN menu).
To stop and display the current menu, enter –1 and the WAIT command (PRG IN menu).
WAIT takes the 0 or –1 from level 1, then suspends execution until a valid keystroke is executed.
For an argument of –1, WAIT displays the currently specified menu. This lets you build and display a menu of user
choices while the program is paused. (A menu built with MENU or TMENU is not normally displayed until the
program ends or is halted.)
When execution resumes, the three-digit key location number of the pressed key is left on the stack. This number
indicates the row, column, and shift level of the key.
To respond to WAIT while running a program:
Press any valid keystroke. (A prefix key such as !or ~ by itself is not a valid keystroke.)
1-48 RPL Programming
NEXT
»
Increments j and repeats the loop.
Ends the defining program.
3 FREEZE
Freezes the status and stack areas.
»
PRESERVE
Ends the main nested program.
Stores the current flag status, executes the main
nested program, and restores the status.
»
`OBDISP K
Stores the program in BDISP.
Checksum: # 22884d
Bytes:
187
RPL Programming Examples 2-9
Labeling Output with Tags
PRESERVE program listing
To label a result with a tag:
Program:
1. Put the output object on the stack.
2. Enter a tag — a string, a quoted name, or a number.
3. Enter the →TAG command (PRG TYPE menu).
Comments:
«
RCLF
Recalls the list of four 64-bit
binary integers representing the
status of the 128 system flags and
128 user flags.
→ f
Stores the list in local variable f.
«
Begins the defining procedure.
« … object tag →TAG … »
→TAG takes two arguments — an object and a tag — from the stack and return a tagged object.
Example: The following program TTAG is identical to TINPUT, except that it returns the result as AREA: value.
Program:
«
"Key in a, b"
{ ":a::b:" {1 0} V }
INPUT OBJ→
TORSA
"AREA"
→TAG
Comments:
THEN
f STOF ERRN DOERR
Enters the tag (a string).
Uses the program result
and string to create the
tagged object.
END
Stores the program in
TTAG.
Execute TTAG to calculate the area of a torus of inner radius a = 1.5 and outer radius b = 1.85. The answer is
returned as a tagged object.
J %TTAG% 1.5 ˜1.85 `
Labeling and Displaying Output as Strings
To label and display a result as a string:
1. Put the output object on the stack.
2. Enter the →STR command (PRG TYPE menu).
3. Enter a string to label the object (with "" delimiters).
4. Enter the SWAP + commands to swap and concatenate the strings.
5. Enter a number specifying the line to display the string on.
6. Enter the DISP command (PRG OUT menu).
« … object →STR label SWAP + line DISP … »
DISP displays a string without its "" delimiters.
1-50 RPL Programming
Puts the list back on the stack,
then restores the status of all flags.
Ends the defining procedure.
f STOF
»
`OTTAG ‰
Starts the error trap.
Executes the program placed on
the stack as the level 1 argument.
If the program caused an error,
restores flags, shows the error, and
aborts execution.
Ends the error routine.
IFERR
EVAL
»
»
Stores the program in
PRESERVE.
`OPRESERVE K
Checksum: # 26834d
Bytes:
71
PRESERVE is demonstrated in the program BDISP.
BDISP (Binary Display)
BDISP displays a real or binary number in HEX, DEC, OCT, and BIN bases.
Level 1
→
Level 1
#n
→
#n
n
→
n
RPL Programming Examples 2-7
You must acknowledge a message box by pressing %OK% or −.
Using Menus with Programs
You can use menus with programs for different purposes:
Menu-based input. A program can set up a menu to get input during a halt in a program and then resume
executing the same program.
Menu-based application. A program can set up a menu and finish executing, leaving the menu to start
executing other related programs.
To set up a built-in or library menu:
1. Enter the menu number.
2. Enter the MENU command (MODES MENU menu).
To set up a custom menu:
1. Enter a list (with { } delimiters) or the name of a list defining the menu actions. If a list of two element lists is
given, the first element appears in the menu, but it is the second element that is returned to the stack when the
menu key is pressed. This second element can itself be a list with up to 3 objects, one for the menu key, one for the
left shift menu key and one for the right shift menu key.
2. Activate the menu:
To save the menu as the CST menu, enter the MENU command (MODES MENU menu).
To make the menu temporary, enter the TMENU command (MODES MENU menu).
The menu isn’t displayed until program execution halts.
Menu numbers for built-in menus are listed in Appendix H. Library menus also have numbers — the library
number serves as the menu number. So you can activate applications menus (such as the SOLVE and PLOT
menus) and other menus (such as the VAR and CST menus) in programs. The menus behave just as they do during
normal keyboard operations.
You create a custom menu to cause the behavior you need in your program — see the topics that follow. You can
save the menu as the CST menu, so the user can get it again by pressing !£. Or you can make it temporary —
it remains active (even after execution stops), but only until a new menu is selected — and it doesn’t affect the
contents of variable CST.
Example: Calculate F13 and compare the execution time for the two methods.
Select the VAR menu and do the calculation.
J
13 %FIBT%
F13 is 233. FIB2 takes fewer seconds to execute than FIB1 (far fewer if n is large). (The times required for the
calculations depend on the contents of memory and other factors, so you may not get the exact times shown above.)
Displaying a Binary Integer
This section contains three programs:
PAD is a utility program that converts an object to a string for right-justified display.
PRESERVE is a utility program for use in programs that change the calculator’s status (angle mode, binary base,
and so on).
BDISP displays a binary integer in HEX, DEC, OCT, and BIN bases. It calls PAD to show the displayed
numbers right-justified, and it calls PRESERVE to preserve the binary base.
PAD (Pad with Leading Spaces)
PAD converts an object to a string, and if the string contains fewer than 22 characters, adds spaces to the beginning
of the string till the string reaches 22 characters.
When a short string is displayed with DISP, it appears left-justified: its first character appears at the left end of the
display. By adding spaces to the beginning of a short string, PAD moves the string to the right. When the string
(including leading spaces) reaches 22 characters, it appears right-justified: its last character appears at the right end of
the display. PAD has no effect on longer strings.
To specify a particular page of a menu, enter the number as m.pp, where m is the menu number and pp is the page
number (such as 94.02 for page 2 of the TIME menu). If page pp doesn’t exist, page 1 is displayed (94 gives page 1
of the TIME menu).
Level 1
→
Level 1
object
→
"object"
Example: Enter 69 MENU to get page 1 of the MODES MISC menu.
Enter 69.02 MENU to get page 2 of the MODES MISC menu.
To restore the previous menu:
Execute 0 MENU.
To recall the menu number for the current menu:
Execute the RCLMENU command (MODES MENU menu).
Techniques used in PAD
WHILE…REPEAT…END (indefinite loop). The WHILE clause contains a test that executes the REPEAT
clause and tests again (if true) or skips the REPEAT clause and exits (if false).
String operations. PAD demonstrates how to convert an object to string form, count the number of characters,
and combine two strings.
Using Menus for Input
To display a menu for input in a program:
1. Set up the menu — see the previous section.
2. Enter a command sequence that halts execution (such as DISP, PROMPT, or HALT).
1-52 RPL Programming
RPL Programming Examples 2-5
1.25 !æ
FIB2 program listing
Example: The following program, EIZ, constructs a custom menu to emulate the HP Solve application for a
capacitive electrical circuit. The program uses the equation E = IZ, where E is the voltage, I is the current, and Z is
the impedance.
Program:
→ n
«
IF n 1 ‰
THEN n
ELSE
Because the voltage, current, and impedance are complex numbers, you can’t use the HP Solve application to find
solutions. The custom menu in EIZ assigns a direct solution to the left-shifted menu key for each variable, and
assigns store and recall functions to the unshifted and right-shifted keys — the actions are analogous to the HP Solve
application. The custom menu is automatically stored in CST, replacing the previous custom menu — you can press
!£ to restore the menu.
Program:
Comments:
«
Puts F0 and F1 on the stack.
From 2 to n does the following loop:
{ "I" { « 'I' STO »
« E Z / DUP 'I' STO
"I:"SWAP + CLLCD
1 DISP 3 FREEZE »
« I » } }
Builds menu key 2.
`O FIB2 K
{ "Z"{ « 'Z' STO »
« E I / DUP 'Z' STO
"Z:" SWAP + CLLCD
1 DISP 3 FREEZE »
« Z » } }
Builds menu key 3.
Copies the latest F (initially F1)
ROT
Gets the previous F (initially F0)
+
Calculates the next F (initially F2)
NEXT
Repeats the loop.
SWAP DROP
Drops Fn-1.
END
Ends the ELSE clause.
Ends the defining procedure.
Stores the program in FIB2.
Checksum: # 23902d (press O%FIB2% !°#MEM# %BYTES%)
Bytes:
89
Example: Calculate F6 and F10.
}
Ends the list.
Calculate F6.
MENU
Displays the custom menu.
J
»
`OEIZ ‰
If n ≤ 1,
then Fn = n;
otherwise …
2 n
START
DUP
»
»
{
{ "E" { « 'E' STO »
« I Z * DUP 'E' STO
"E: " SWAP + CLLCD
1 DISP 3 FREEZE »
« E » } }
Creates a local variable structure.
0 1
Sets Degrees mode. Sets flags –15 and –16 to
display complex numbers in polar form. Sets
the display mode to 2 Fix.
Starts the custom menu list.
Builds menu key 1 for E.
Unshifted action: stores the object in E. Leftshift action: calculates I × Z, stores it in E, and
displays it with a label. Right-shift action: recalls
the object in E.
DEG -15 SF -16 SF
2 FIX
Comments:
«
Stores the program in EIZ.
6 %FIB2%
Calculate F10.
For a 10-volt power supply at phase angle 0°, you measure a current of 0.37-amp at phase angle 68°. Find the
impedance of the circuit using EIZ.
10 %FIB2%
@·J%EIZ%
Key in the voltage value.
!Ü10 [email protected] 0
1-54 RPL Programming
RPL Programming Examples 2-3
2
2.RPL Programming Examples
The programs in this chapter demonstrate basic programming concepts. These programs are intended to improve
your programming skills, and to provide supplementary functions for your calculator.
At the end of each program, the program’s checksum and size in bytes are listed to help make sure you typed the
program in correctly. (The checksum is a binary integer that uniquely identifies the program based on its contents).
To make sure you’ve keyed the program in correctly, store it in its name, put the name in level 1, then execute the
BYTES command (!°#MEM# %BYTES%). This returns the program’s checksum to level 2, and its size in bytes
to level 1. (If you execute BYTES with the program object in level 1, you’ll get a different byte count.)
The examples in this chapter assume the calculator is in its initial, default condition — they assume you haven’t
changed any of the calculator’s operating modes, with the exception of selecting RPN mode. (To reset the calculator
to this condition, see “Memory Reset” in chapter 5 of the HP 48G Series User's Guide.)
Each program listing in this chapter gives the following information:
A brief description of the program.
A syntax diagram (where needed) showing the program’s required inputs and resulting outputs.
Discussion of special programming techniques in the program.
Any other programs needed.
The program listing.
The program’s checksum and byte size.
Fibonacci Numbers
This section includes three programs that calculate Fibonacci numbers:
FIB1 is a user-defined function that is defined recursively (that is, its defining procedure contains its own name).
FIB1 is short.
FIB2 is a user-defined function with a definite loop. It’s longer and more complicated than FIB1, but faster.
FIBT calls both FIB1 and FIB2 and calculates the execution time of each subprogram.
FIB1 and FIB2 demonstrate an approach to calculating the nth Fibonacci number Fn, where:
F0 = 0, F1 = 1, Fn = Fn-1 + Fn-2
FIB1 (Fibonacci Numbers, Recursive Version)
Level 1
→
Level 1
n
→
Fn
RPL Programming Examples 2-1
Enter the matrix.
!²
12 `56 `˜šš
Access:
Flags:
Input/Output:
45 `1 `
9 `14 `
`
View these graphs with domain and range reversed to see how the domain of COS is restricted to
make an inverse function possible. Consider the vertical band in the lower graph as the restricted
domain Z = (x, y). COS sends this domain onto the whole complex plane in the range
W = (u, v) = COS(x, y) in the upper graph.
!¾
( ¾ is the left-shift of the T key).
Principal Solution (–1), Numerical Results (–3), Angle Mode (–17, –18)
Select the VAR menu and execute MNX.
Level 1/Argument 1
J %MNX%
See also:
Level 1/Item 1
z
→
acos z
'symb'
→
'ACOS(symb)'
ASIN, ATAN, COS, ISOL
Find the maximum element.
%MAX%
MNX2 (Minimum or Maximum Element—Version 2)
Given an array on the stack, MNX2 finds the minimum or maximum element in the array. MNX2 uses a different
approach than MNX: it executes OBJ→ to break the array into individual elements on the stack for testing, rather
than executing GETI to index through the array.
Level 1
→
Level2
Level 1
[[ array ]]
→
[[ array ]]
Z max or Z min
Techniques used in MNX2
FOR…NEXT (definite loop). The initial counter value is 1. The final counter value is nm –1, where nm is the
number of elements in the array. The loop-clause contains the sort instructions.
User flag for logic control. User flag 10 defines the sort: When flag 10 is set, MNX2 finds the maximum
element; when flag 10 is clear, it finds the minimum element. You determine the status of flag 10 at the beginning
of the program.
Nested conditional. An IF…THEN…END conditional is nested in the FOR…NEXT loop, and determines
the following:
Whether to maintain the current minimum or maximum element, or make the current element the new
minimum or maximum.
The sense of the comparison of elements (either < or >) based on the status of flag 10.
Logical function. MNX2 executes XOR (exclusive OR) to test the combined state of the relative value of the two
elements and the status of flag 10.
Custom menu. MNX2 builds a custom menu that lets you choose whether to sort for the minimum or
maximum element. Key 1, labeled %MAX%, sets flag 10. Key 2, labeled %MIN%, clears flag 10.
2-18 RPL Programming Examples
ACOS2S
Type:
Command
Description:
Transforms an expression by replacing acos(x) in subexpressions with π/2–asin(x).
Access:
Trigonometry, …Ñ
Input:
The expression to transform.
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Simplify the following expression:
Full Command and Function Reference 3-7
!²
ABCUV
Type:
Command
Description:
Returns a solution in polynomials u and v of au+bv =c where a and b are polynomials in the
current CAS independent variable, and c is a value.
9 `14 `
Access:
Arithmetic, !Þ POLYNOMIAL
`
Input:
Level 3/Argument 1: The polynomial corresponding to a.
Level 2/Argument 2: The polynomial corresponding to b.
Level 1/Argument 3: The value corresponding to c.
Output:
Level 2/Item 1: The solution corresponding to u.
Level 1/Item 2: The solution corresponding to v.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find a solution in polynomials u and v for the following equation:
12 `56 `˜šš
45 `1 `
Select the VAR menu and execute MNX2.
J %MNX2%
Find the minimum element.
%MIN%
2
2
( x + x + 1 )u + ( x + 4 ) V = 13
Command:
Result:
Applying a Program to an Array
See also:
APLY makes use of list processing to transform each element of an array according to a desired procedure.
ABS
Type:
Description:
The procedure applied to each element must be a program that takes exactly one argument (i.e. the element) and
returns exactly one result (i.e. the transformed element).
The procedure assumes flag –55 to be clear, and unexpected results could be returned if flag –55 is set.
ABCUV(X^2+X+1,X^2+4,13)
{-(X+3),X+4}
IABCUV, EGCD
Function
Absolute Value Function: Returns the absolute value of its argument.
ABS has a derivative (SIGN) but not an inverse.
In the case of an array, ABS returns the Frobenius (Euclidean) norm of the array, defined as the
square root of the sum of the squares of the absolute values of all n elements. That is:
n
Level 2
Level 1
→
Level 1
[ array ]
« program »
→
[[ array ]] or {{ array }}
Techniques used in APLY
Manipulating Meta-Objects. Meta-objects are composite objects like arrays and lists that have been disassembled
on the stack. APLY illustrates several approaches to manipulating the elements and dimensions of such objects.
∑
i=1
Access:
!Ê
Flags:
Numerical Results (–3)
Input/Output:
Program:
«
→ a p
«
2-20 RPL Programming Examples
See also:
Comments:
Store the array and program in local variables.
Begin the main local variable structure.
2
( Ê is the left-shift of the /key).
Level 1/Argument 1
Application of List Processing. APLY makes use of DOSUBS (although DOLIST might also have been used)
to perform the actual transformation of array elements.
Using an IFERR…THEN…ELSE…END Structure. The entire symbolic pseudo-array case is handled
within a error structure — triggered when the →ARRY command generates an error when symbolic elements are
present.
Using Flags. User flag 1 is used to track the case when the input array is a vector.
APLY program listing
zi
ACK
Type:
Description:
Level 1/Item 1
x
→
|x|
(x,y)
→
x +y
2
2
x_unit
→
|x|_unit
[array]
→
||array||
'symb'
→
'ABS(symb)'
NEG, SIGN
Command
Acknowledge Alarm Command: Acknowledges the oldest past-due alarm.
ACK clears the alert annunciator if there are both no other past-due alarms and no other active
alert sources (such as a low battery condition).
Full Command and Function Reference 3-5
Program:
Comments:
Repeat loop for the next row.
Gather rows into a list, forming a list of lists
(symbolic pseudo-array).
Close the local variable structure and end the
IFERR…THEN…END structure. Clear flag 1
before exiting the program.
NEXT
n →LIST
»
END 1 CF
»
»
Stores the program in APLY.
`OAPLY K
Checksum: # 11132d
Bytes:
314
Example: Apply the function, f(x) = Ax3-7 to each element x of the vector [ 3 -2 4 ].
!Ô3†2W†4`
Computer Algebra System Commands and Functions
The Computer Algebra System, or CAS, is a collection of operations that can be applied to algebraic expressions.
The calculator’s operations can be used with numbers to produce numeric results, or with symbols to produce
algebraic expressions. Algebraic expressions and equations can be written using the Equation Writer too. Algebraic
expressions and symbolic operations on them, called computer algebra operations, are introduced in Chapter 5 of
the User’s Manual.
Further explanations of computer algebra operations, are given in the User’s Guide, whereas this part of the
Advanced User’s Guide lists the computer algebra operations that can be applied to symbolic expressions, with a
description of each one listed.
These operations perform tasks such as rearrangement of trigonometric and logarithmic functions, or manipulation
of polynomials, series and matrices. They are referred to as the “Computer Algebra System” or the CAS. Many of
the CAS operations are of particular use in Linear Algebra applications and in Vector Algebra. The CAS on the
calculator allows it to provide many of the features of the Computer Algebra Systems used on laptop and desktop
computers.
Note: The Computer Algebra System should not be confused with Algebraic mode, which is one of the calculator’s
operating modes. The CAS works with algebraic (or symbolic) expressions, which can be entered and used in
Algebraic mode or in RPN mode.
Classification of Operations
‚å 3 QA *7 -
The command dictionary contains commands, functions, and analytic functions. Commands are calculator operations that
can be executed from a program. Functions are commands that can be included in algebraic objects. Analytic
functions are functions for which the calculator provides an inverse and a derivative. There are also four nonprogrammable operations (DBUG, NEXT, SST, and SST↓) that are included with the programmable commands as a
convenience because they are used interactively while programming.
`J %APLY%
H#DISP ˜˜
(select small stack display to see
all vector elements.)
Converting Between Number Bases
nBASE converts a positive decimal number (x) into a tagged string representation of the equivalent value in a
different number base (b). Both x and b must be real numbers. nBASE automatically rounds both arguments to the
nearest integer.
Level 2
Level 1
→
Level 1
x
b
→
x baseb: "string"
When working with functions or commands within the Equation Writer:
• When you apply a function to an expression, the function becomes part of the expression. You need to ensure
that the expression is selected, then press N to apply the function to the selection.
• When you apply a command to an expression in Equation Writer, it is evaluated immediately.
The definitions of the abbreviations used for argument and result objects are contained in the following table,
“Terms Used in Stack Diagrams.” Often, descriptive subscripts are added to convey more information.
Techniques used in nBASE
String Concatenation and Character Manipulation. nBASE makes use of several string and character
manipulation techniques to build up the result string.
Tagged Output. nBASE labels (“tags”) the output string with its original arguments so that the output is a
complete record of the command.
Indefinite Loops. nBASE accomplishes most of its work using indefinite loops — both DO...UNTIL...END
and WHILE...REPEAT...END loops.
2-22 RPL Programming Examples
Full Command and Function Reference 3-3
3
Program:
UNTIL 'm' EVAL 0 ==
END
IF 1 FS?C
THEN "0" +
Comments:
Repeat the DO...UNTIL loop until m =
0 (i.e. all decimal value have been
accounted for).
Is flag 1 set? Clear the flag after the test.
Then add a placeholding zero to the
result string.
WHILE i 'k' EVAL
- 0 ‹
Begin WHILE...REPEAT loop to
determine if additional placeholding
zeros are needed.
Loop repeats as long as i≠k.
REPEAT "0" +
1 'k' STO+
Add an additional placeholding zero and
increment k before repeating the testclause.
End the WHILE...REPEAT...END
loop, the IF...THEN...END structure,
and the inner local variable structure.
End the outermost
IF...THEN...ELSE...END structure and
create the label string and tag the result
string using the original arguments.
END
END
»
" base" b +
n SWAP + →TAG
f STOF
Restore original flag settings.
»
Introduction
This chapter details the calculator’s commands and functions.
These listings include the following information:
a brief definition of what the command or function does
additional information about how it works and how to use it
the key to press to gain access to it
any flags that may affect how it works
a stack diagram showing the arguments it requires (if any)
related commands or functions
How to Access Commands and Functions
Many of the commands and functions in this reference are not located on the calculator’s keyboard and are accessed
by pressing …µ. This is the right-shifted function of the Pkey, which is the fourth key from the left on
the fourth row of keys from the top. Once accessed, the function or command’s name is found by pressing the
~key and then using the letter keys to spell out the function or command’s name. Usually, pressing the first letter
of the command will move the catalog list close enough to the function to use the ˜key to find the function.
For functions or commands (or symbols) that are located on the calculator’s keyboard as shifted functions of other
keys (such as …µ above), the proper shift key is shown followed by a font symbol indicating the function,
command or symbol written above the key.
In some cases, access is shown with two keys with an ampersand (&) in between, such as !&H. This notation
means that you must press the first key and hold it down while then pressing the second key at the same time.
»
`OnBASE K
3.Full Command and Function Reference
Stores the program in nBASE.
Checksum: # 54850d
Bytes:
433
Example: Convert 100010 to base 23.
1000 `23 J %NBASE%
Verifying Program Arguments
The two utility programs in this section verify that the argument to a program is the correct object type.
NAMES verifies that a list argument contains exactly two names.
VFY verifies that the argument is either a name or a list containing exactly two names. It calls NAMES if the
argument is a list.
You can modify these utilities to verify other object types and object content.
The next few pages explain how to read the stack diagrams in the command reference, how commands are
alphabetized, and the meaning of command classifications at the upper right corner of each stack diagram.
How to Read Stack Diagrams
Many entries in the command reference include a stack diagram. This is a table showing the arguments that the
command, function, or analytic function takes from the stack in RPN mode or from the argument order in algebraic
mode, and the results that it returns to the stack (in RPN mode) or displays (in algebraic mode; if there is more than
one output, they are written to a list). The “→” character (pronounced “to” as in “to list” for →LIST) in the table
separates the arguments from the results. The stack diagram for a command may contain more than one “argument
→ result” line, reflecting all possible combinations of arguments and results for that command.
Consider this example:
ACOS
Type:
Analytic Function
Input/Output:
Level 1/Argument 1
Level 1/Item 1
z
→
acos z
'symb'
→
'ACOS(symb)'
This diagram indicates that the analytic function ACOS (Arc Cosine) takes a single argument from level 1 and returns
one result (to level 1). ACOS can take either a real or complex number or an algebraic object as its argument. In the
2-24 RPL Programming Examples
Full Command and Function Reference 3-1
Example: Find the value of x for which X→FX equals 599.5. Use a guess in the vicinity of 1.
Checksum: # 10752d
Bytes:
141.5
Start by keying in X→FX :
@å@é x †O3.7
NAMES is demonstrated in the program VFY.
*x Q3 +4.5 * x Q2
VFY (Verify Program Argument)
VFY verifies that an argument on the stack is either a name or a list that contains exactly two names.
+3.9 *x +5 `
Level 1
→
Level 1
'name'
→
'name'
{ valid list }
→
{ valid list }
{ invalid list }
→
{ invalid list } (and error message in status area)
O J %X²FX% `
invalid object
→
invalid object (and error message in status area)
599.5 ` 1 %ROOTR%
Store the program in X→FX, then enter the program name, the y-value 599.5, and the guess 1, and execute
ROOTR:
O X→FX K
Techniques used in VFY
Utility programs. VFY by itself has little use. However, it can be used with minor modifications by other
programs to verify that specific object types are valid arguments.
CASE…END case structure). VFY uses a case structure to determine if the argument is a list or a name.
Structured programming. If the argument is a list, VFY calls NAMES to verify that the list contains exactly
two names.
Local variable structure. VFY stores its argument in a local variable so that it can be passed to NAMES if
necessary.
Logical function. VFY uses NOT to display an error message.
Required Programs
NAMES
NAMES verifies that a list argument contains exactly two names.
VFY program listing
Program:
«
DUP
DTAG
→ argm
«
CASE
argm TYPE 5. SAME
THEN
argm NAMES
END
2-26 RPL Programming Examples
Animating a Graphical Image
Program WALK shows a small person walking across the display. It animates this custom graphical image by
incrementing the image position in a loop structure.
Techniques used in WALK
Custom graphical image. (Note that the programmer compiles the full information content of the graphical
image before writing the program by building the image interactively in the Graphics environment and then
returning it to the command line.)
FOR…STEP (definite loop). WALK uses this loop to animate the graphical image. The ending value for the
loop is MAXR. Since the counter value cannot exceed MAXR, the loop executes indefinitely.
WALK program listing
Comments:
Copies the original argument to leave on
the stack.
Removes any tags from the argument for
subsequent testing.
Stores the argument in local variable argm.
Begins the defining procedure.
Begins the case structure.
Tests if the argument is a list.
If so, puts the argument back on the stack
and calls NAMES to verify that the list is
valid, then leaves the CASE structure.
Program:
«
GROB 9 15 E300
140015001C001400E300
8000C110AA0094009000
4100220014102800
→ walk
«
ERASE { # 0d # 0d }
PVIEW
Comments:
Puts the graphical image of the
walker in the command line.
(Note that the hexadecimal
portion of the graphics object is
a continuous integer
E300...2800. The
linebreaks do not represent
spaces.)
Creates local variable walk
containing the graphics object.
Clears PICT, then displays it.
RPL Programming Examples 2-39
Techniques used in →RPN
Recursion. The →RPN program calls itself as a subroutine. This powerful technique works just like calling
another subroutine as long as the stack contains the proper arguments before the program calls itself. In this case
the level 1 argument is tested first to be sure that it is an algebraic expression before →RPN is called again.
Object Type-Checking. →RPN uses conditional branching that depends on the object type of the level 1
object.
Nested program Structures. →RPN nests IF…THEN…END structures inside FOR…NEXT loops inside a
IF…THEN… ELSE…END structure.
List Concatenation. The result list of objects in RPN order is built by using the ability of the + command to
sequentially append additional elements to a list. This is a handy technique for gathering results from a looping
procedure.
Trace Mode
This section contains two programs, αENTER and ßENTER, which together provide “trace mode” for the
calculator using an external printer. To turn on “trace mode,” set flag –63 and activate User mode. To turn off
“trace mode,” clear flag –63 or turn off User mode.
Techniques used in αENTER and ßENTER
Vectored ENTER. Setting flag –63 and activating User mode turns on vectored ENTER. When vectored
ENTER is turned on and variable αENTER exists, the command-line text is put on the stack as a string and
αENTER is evaluated. Then, if variable ßENTER exists, the command that triggered the command-line
processing is put on the stack as a string and ßENTER is evaluated.
αENTER program listing
→RPN program listing
Program:
Program:
Comments:
«
OBJ→
IF OVER
THEN → n f
«
1 n
FOR i
IF DUP TYPE 9. SAME
THEN →RPN
END n ROLLD
NEXT
IF DUP TYPE 5. ‹
THEN 1 →LIST
END
IF n 1 >
THEN 2 n
START +
NEXT
END f +
»
ELSE 1 →LIST SWAP DROP
END
PR1
OBJ→
Take the expression apart.
If the argument count is nonzero, then
store the count and the function.
Begins local variable defining procedure.
Begins FOR…NEXT loop, which
converts any algebraic arguments to lists.
Tests whether argument is an algebraic.
If argument is an algebraic, convert it to a
list first.
Roll down the stack to prepare for the
next argument.
Repeat the loop for the next argument.
Tests to see if level 1 object is a list.
If not a list, then convert it to one.
Ends the IF…THEN…END structure.
Tests to see if there is more than one
argument.
Prints the command line text,
then converts the string to an
object and evaluates it.
»
`O αENTER K
Stores the program in αENTER.
(Press ~‚A to type α. You
must use this name.)
Checksum: # 127d
Bytes:
25.5
ßENTER program listing
Program:
Comments:
«
PR1 DROP
PRSTC
Prints the command that caused
the processing, then drops it and
prints the stack in compact form.
»
`O ßENTER K
Combine all of the arguments into a list.
Append the function to the end of the list.
End the local variable defining procedure.
For functions with no arguments,
converts to a simple list.
End the IF…THEN… ELSE…END
structure.
Comments:
«
Stores the program in ßENTER.
(Press ~‚B to type ß. You
must use this name.)
Checksum: # 31902d
Bytes:
28
»
`O→RPN K
2-28 RPL Programming Examples
Stores the program in →RPN.
RPL Programming Examples 2-37
BER program listing
Program:
Program:
Comments:
«
→ x
Creates local variable x.
«
'x/2' →NUM 2 1
→ xover2 j sum
«
DO
sum
'sum+(-1)^(j/2)*
xover2^(2*j)/SQ(j!)'
EVAL
2 'j' STO+
DUP 'sum' STO
UNTIL
==
END
sum
»
»
»
`OBER K
Checksum: # 15837d
Bytes:
203
Example: Calculate BER(3).
J
3 %BER%
Calculate BER(2) in algebraic syntax.
O %BER% !Ü2
N
2-30 RPL Programming Examples
Begins outer defining procedure.
Enters x/2, the first counter value, and
the first term of the series, then creates
local variables.
Begins inner defining procedure.
Begins the loop.
Recalls the old sum and calculates the
new sum.
Increments the counter.
Stores the new sum.
Ends the loop clause.
Tests the old and new sums.
Ends the loop.
Recalls the sum.
Ends inner defining procedure.
Ends outer defining procedure.
Stores the program in BER.
Comments:
(66,32) 20 0 6.28 ARC
Draws the circle.
PICT RCL →LCD
Displays the empty circle.
RCLΣ TOT /
Recalls the statistics data matrix,
computes totals, and calculates the
proportions.
Converts the proportions to
percentages.
DUP 100 *
→ prcnts
Stores the percentage matrix in prcnts.
«
2 π →NUM * *
0
Multiplies the proportion matrix by
2π, and enters the initial angle (0).
→ prop angle
Stores the angle matrix in prop and
angle in angle.
«
prop SIZE OBJ→
DROP SWAP
FOR n
(66,32) prop n GET
'angle' STO+
Sets up 1 to m as loop counter range.
Begins loop-clause.
Puts the center of the circle on the
stack, then gets the nth value from
the proportion matrix and adds it to
angle.
angle COS angle SIN
R→C 20 * OVER +
LINE
Computes the endpoint and draws
the line for the nth slice.
PICT RCL
angle prop n GET
2 / - DUP DUP
COS SWAP SIN R→C
26 * (66,32) +
SWAP
CASE
Recalls PICT to the stack.
For labeling the slice, computes the
midpoint of the arc of the slice.
DUP 1.5 ‰
THEN
DROP
END
DUP 4.4 ‰
THEN
DROP 15 END
5 <
THEN
(3,2) +
END
END
Starts the CASE structure to test
angle and determine the offset value
for the label.
From 0 to 1.5 radians, doesn’t offset
the label.
From 1.5 to 4.4 radians, offsets the
label 15 user units left.
From 4.4 to 5 radians, offsets the
label 3 units right and 2 units up.
Ends the CASE structure.
RPL Programming Examples 2-35
SETTS (Superimposing Taylor’s polynomials)
SETTS superimposes successive Taylor’s polynomials on a sine curve and stores each graphics object in a list.
TSA (Animating Taylor’s Polynomials)
TSA displays in succession each graphics object created in SETTS.
Techniques used in SETTS
Structured programming. SETTS calls SINTP to build a sine curve and convert it to a graphics object.
FOR…STEP (definite loop). SETTS calculates successive Taylor’s polynomials for the sine function in a
definite loop. The loop counter serves as the value of the order of each polynomial.
Programmatic use of PLOT commands. SETTS draws a plot of each Taylor’s polynomial.
Manipulation of graphics objects. SETTS converts each Taylor’s polynomial plot into a graphics object. Then
it executes + to combine each graphics object with the sine curve stored in SINT, creating nine new graphics
objects, each the superposition of a Taylor’s polynomial on a sine curve. SETTS then puts the nine new graphics
objects, and the sine curve graphics object itself, in a list.
Techniques used in TSA
Passing a global variable. Because SETTS takes several minutes to execute, TSA does not call SETTS. Instead,
you must first execute SETTS to create the global variable TSL containing the list of graphics objects. TSA
simply executes that global variable to put the list on the stack.
ANIMATE. TSA uses the ANIMATE command to display in succession each graphics object from the list.
TSA program listing
Program:
Comments:
«
SETTS program listing
TSL OBJ→
Program:
Comments:
«
Puts the list TSL on the
stack and converts it to 10
graphics objects and the list
count.
Set up the parameters for
ANIMATE.
SINTP
Plots a sine curve and stores
the graphics object in SINT.
{ { #0 #0 } .5 0 } +
1 17 FOR n
Sets the range for the FOR
loop using local variable n.
ANIMATE
Displays the graphics in
succession.
'SIN(X)' 'X' n TAYLR
STEQ ERASE DRAW
Plots the Taylor’s polynomial
of order n.
11 DROPN
Removes the graphics objects
and list count from the stack.
PICT RCL SINT +
Returns the plot to the stack
as a graphics object and
executes + to superimpose
the sine plot from SINT.
2 STEP
SINT
10 →LIST
'TSL' STO
`OTSA K
Stores the program in TSA.
Increments the loop counter
n by 2 and repeats the loop.
Checksum: # 24644d
Bytes:
92.5
Puts the sine curve graphics
object on the stack, then
builds a list containing it and
the nine graphics objects
created in the loop. Stores the
list in TSL.
Example: Execute SETTS and TSA to build and display in succession a series of Taylor’s polynomial
approximations of the sine function.
»
`OSETTS K
»
Ensure Radians mode is set and execute SETTS to build the list of graphics objects. (SETTS takes several minutes
to execute.) Then execute TSA to display each plot in succession. The display shows TSA in progress.
!&H %!ANGLE% %!RAD% ( if necessary)
J %SETTS%
Stores the program in
SETTS.
%TSA%
Checksum: # 41304d
Bytes:
130.5
SETTS is demonstrated in the program TSA.
2-32 RPL Programming Examples
Press − to stop the animation. Press !&H %!ANGLE% %!DEG% to restore Degrees mode if desired.
RPL Programming Examples 2-33
Flags:
Example:
Command:
Result:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
→COL
Type:
Description:
Express the result of the following addition in modulo 7.
(x2+3x+6)+(9x+3)
Note: Before trying this example, use the CAS modes input form to set the modulo to 7.
Access:
ADDTMOD(X^2+3*X+6,9*X+3)
X^2-2*X+2
Input/Output:
ADDTOREAL
Type:
Command
Description:
Level 1/Argument 1
Adds specified global names to the reserved variable REALASSUME. This is a list of the global
variables that will be treated by some CAS operations as real numbers when Complex mode is set.
If a variable is already in the REALASSSUME list, this command removes any additional
assumptions made on it by ASSUME.
Access:
Catalog, …µ
Input:
Level 1/Item 1: The name of the global variable to be added to the REALASSUME list, or a list
of names.
Output:
No output in RPN mode, NOVAL in Algebraic mode.
Flags:
If the “all variables are real” flag is set (flag –128 set), ADDTOREAL will not add anything to the
REALASSUME list, as all variables are assumed real anyway. In this case it will only remove
further assumptions made by ASSUME.
See also:
ASSUME, DEF, STORE, UNASSUME, UNBIND
See also:
COL→
Type:
Description:
Access:
ALGB
[ vector ]col1
[ vector ]coln
ncolcount
[ vector ]
COL→, →ROW, ROW→
→
element1
elementn
nelementcount
Level 1/Item 3
Command
Columns to Matrix Command: Transforms a series of column vectors and a column count into a
matrix containing those columns, or transforms a sequence of numbers and an element count into
a vector with those numbers as elements.
All vectors must have the same length. The column or element count is rounded to the nearest
integer.
!´MATRIX COL COL→
( ´ is the left-shift of the Pkey).
CREATE COLUMN COL→
Ln+1/A1 ...
Description:
Displays a menu or list of CAS algebraic operations.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
See also:
ARIT, CONSTANTS, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR, MODULAR,
POLYNOMIAL, REWRITE, TESTS, TRIGO
COL–
Type:
Description:
( Ø is the left-shift of the 5key).
L2/A2
L1/An+1
Level 1/Item 1
[ vector ]col1
[ vector ]coln
ncolcount
→
element1
elementn
nelementcount
→
[[ matrix ]]
[ vector ]
L = Level; A = Argument; I = item
Analytic Function
Common Antilogarithm Analytic Function: Returns the common antilogarithm; that is, 10 raised
to the given power.
For complex arguments: 10(x,y) = ecx cos cy + i ecx sin cy where c = ln 10.
!Â
( Â is the left-shift of the V key).
Numerical Results (–3)
Level 1/Argument 1
See also:
Level 2/Item 2
→
!Ø
Command
Access:
Flags:
Input/Output:
Leveln+1/Item 1 ...
[[ matrix ]]
Input/Output:
Type:
ALOG
Type:
Description:
Command
Matrix to Columns Command: Transforms a matrix into a series of column vectors and returns
the vectors and a column count, or transforms a vector into its elements and returns the elements
and an element count.
→COL introduces no rounding error.
!´MATRIX COL →COL
( ´ is the left-shift of the Pkey).
!Ø CREATE COLUMN →COL ( Ø is the left-shift of the 5key).
Access:
→
10z
'symb'
→
'ALOG(symb)'
Command
Delete Column Command: Deletes column n of a matrix (or element n of a vector), and returns
the modified matrix (or vector) and the deleted column (or element).
n is rounded to the nearest integer.
!´MATRIX COL COL( ´ is the left-shift of the Pkey).
!Ø
CREATE COLUMN COL-
( Ø is the left-shift of the 5key).
Input/Output:
Level 2/Argument 1
Level 1/Item 1
z
→COL, →ROW, ROW→
See also:
Level 1/Argument 2
Level 2/Item 1
Level 1/Item 2
[[ matrix ]]1
ncolumn
→
[[ matrix ]]2
[ vector ]column
[ vector ]1
nelement
→
[ vector ]2
elementn
COL+, CSWP, ROW+, ROW–
EXP, LN, LOG
3-10 Full Command and Function Reference
Full Command and Function Reference 3-39
Input/Output:
See also:
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
#n1
#n2
→
#n3
“string1”
“string2”
→
“string3”
T/F1
T/F2
→
0/1
T/F
'symb'
→
'T/F AND symb'
'symb'
T/F
→
'symb AND T/F''
'symb1'
NOT, OR, XOR
'symb2'
→
'symb1 AND symb2'
Access:
Input/Output:
Command
Animate Command: Displays graphic objects in sequence.
ANIMATE displays a series of graphics objects (or variables containing them) one after the other.
You can use a list to specify the area of the screen you want to animate (pixel coordinates #X and
#Y), the number of seconds before the next grob is displayed (delay), and the number of times the
sequence is run (rep). If rep is set to 0, the sequence is played approximately one million times
(1,048,575 cycles), or until you press − (the $ key).
If you use a list on level 1, all parameters must be present.
If the list specifier is not used, the delay between each grob will default to 0.1 second.
The animation displays PICT while displaying the grobs. The grobs and the animate parameters
are left on the stack.
!°LGROBLANIMATE
( °is the left-shift of the Nkey).
Ln+1.../A1
L1/An+1
L1/I1
grobn...grob1
ngrobs
→
same stack
grobn...grob1
{ n {#X#Y } delay rep }
→
same stack
L = Level, A = Argument, I = item
See also:
ANS
Type:
Description:
Access:
Input/Output:
The following program draws half a cylinder and rotates it:
« PARSURFACE { 'COS(X)' 'SIN(X)' Y }
STEQ
« I 180 I + XXRNG ERASE DRAW PICT RCL »
I 0 359 8 SEQ OBJ ANIMATE DROPN »
This program also illustrates the use of SEQ and PARSURFACE. You can adjust the increment
value used with SEQ (8 is used here) to change the number of images drawn by the program, or
to use less memory.
BLANK, →GROB
Command
Recalls the nth answer from history, where n is an integer, in algebraic mode only. When called
directly from the keybard in RPN mode, it takes no input and performs the LASTARG
command. When the command name is typed manually in RPN mode, it performs PICK, with
the exception that any stack levels containing null-tagged expressions (surrounded by `
3-12 Full Command and Function Reference
Command
Clear Command: Removes all objects from the stack or history.
To recover a cleared stack or history, press …¯ (the right-shift of the Mkey) before
executing any other operation. There is no programmable command to recover the stack or
history.
…·
(·is the right-shift of the ƒkey).
Leveln/Argument 1 ... Level 1/Argumentn
objn ...obj1
See also:
ANIMATE
Type:
Description:
Example:
CLEAR
Type:
Description:
CLKADJ
Type:
Description:
Access:
Input/Output:
Leveln/Item 1 ... Level 1/Itemn
→
CLVAR, PURGE
Command
Adjust System Clock Command: Adjusts the system time by x clock ticks, where 8192 clock ticks
equal 1 second. If x is positive, x clock ticks are added to the system time. If x is negative, x clock
ticks are subtracted from the system time. If X>10^12, it will be changed to 10^12 ticks (which is
approximately 3.87 years).
…ÓTOOLS LLCLKADJ
( Ó is the right-shift of the 9 key).
Level 1/Argument 1
x
See also:
Level 1/Item 1
→
→TIME
CLLCD
Type:
Description:
Command
Clear LCD Command: Clears (blanks) the stack display.
The menu labels continue to be displayed after execution of CLLCD.
When executed from a program, the blank display persists only until the keyboard is ready for
input. To cause the blank display to persist until a key is pressed, execute FREEZE after
executing CLLCD. (When executed from the keyboard, CLLCD automatically freezes the display.)
Access:
!°LOUT CLLCD
( °is the left-shift of the Nkey).
Input/Output: None
Example:
Evaluating « CLLCD 7 FREEZE » blanks the display (except the menu labels), then
freezes the entire display.
See also:
DISP, FREEZE
CLOSEIO
Type:
Description:
Command
Close I/O Port Command: Closes the serial port, and clears the input buffer and any error
messages for KERRM.
When the calculator turns off, it automatically closes the serial port, but does not clear KERRM.
Therefore, CLOSEIO is not needed to close the port, but can conserve power without turning
off the calculator.
Executing Kermit protocol commands automatically clears the input buffer; however, executing
non-Kermit commands (such as SRECV and XMIT) does not.
CLOSEIO also clears error messages from KERRM. This can be useful when debugging.
Full Command and Function Reference 3-37
Access:
Flags:
!°LPICT ARC
( °is the left-shift of the Nkey).
Angle Mode (–17 and –18). The setting of flags –17 and –18 determine the interpretation of xθ1
and xθ2 (degrees, radians, or grads).
Example:
11
15
Input/Output:
Level 4/Argument 1 Level 3/Argument 2 Level 2/Argument 3 Level 1/Argument 4
(x, y)
Flags:
See also:
ARCHIVE
Type:
Description:
{ #n,#m }
Angle Mode (–17 and –18)
BOX, LINE, TLINE
Level 1/Item 1
xradius
x θ1
x θ2
→
#nradius
x θ1
x θ2
→
Command:
Result:
Command
Archive HOME Command: Creates a backup copy of the HOME directory (that is, all variables),
the user-key assignments, and the alarm catalog in the specified backup object (:nport:name) in RAM
or flash ROM.
The specified port number can be 0 through 3, where 3 is the SD card. (Port 3 only applies to the
HP 50g and 49g+.) An error will result if there is not enough memory in the specified port to
copy the HOME directory.
If the backup object is “:IO:name”, then the copied directory is transmitted in binary via Kermit
protocol through the current I/O port to the specified filename.
To save flag settings, execute RCLF and store the resulting list in a variable.
CHOOSE
Type:
Description:
See also:
ARG
Type:
Description:
Access:
Flags:
Input/Output:
Level 1/Item 1
:nport :name
→
:IO :name
→
RESTORE
Access:
Input/Output:
Function
Argument Function: Returns the (real) polar angle θ of a complex number (x, y).
The polar angle θ is equal to:
• atan y/x for x ≥ 0
• atan y/x + π sign y for x < 0, Radians mode
• atan y/x + 180 sign y for x < 0, Degrees mode
• atan y/x + 200 sign y for x < 0, Grads mode
A real argument x is treated as the complex argument (x,0).
…Ë
(Ë is the right-shift of the /key).
Angle mode (–17, –18)
Level 1/Argument 1
See also:
Level 1/Item 1
(x, y)
→
θ
'symb'
→
'ARG(symb)'


CHOLESKY  1 1 
 15
1 1
0 2
Command
Create User-Defined Choose Box Command: Creates a user-defined choose box.
CHOOSE creates a standard single-choice choose box based on the following specifications:
Variable
Access:
!°MEMORYLARCHIVE
( °is the left-shift of the Nkey).
Flags:
I/O Device (–33), I/O Messages (–39), I/O Device for Wire (–78) if the argument is “:IO:name”.
Input/Output:
Level 1/Argument 1
Find the Cholesky factorization of:
Function
“prompt”
A message that appears at the top of choose box. If “prompt” is an
empty string (“”), no message is displayed.
{c1 … cn}
Definitions that appear within the choose box. A choice definition
(cx) can have two formats.
• obj, any object
• { objdisplay objresult }, the object to be displayed followed by the result
returned to the stack if that object is selected.
npos
The position number of an item definition. This item is highlighted
when the choose box appears. If npos = 0, no item is highlighted, and
the choose box can be used to view items only.
If you choose an item from the choose box and press OK, CHOOSE returns the result (or the
object itself if no result is specified) to level 2 and 1 to level 1. If you press −, CHOOSE
returns 0. Also, if npos = 0, CHOOSE returns 0.
!°LIN CHOOSE
( °is the left-shift of the Nkey).
L3/A1
L2/A2
L1/A3
“prompt”
{ c1 ... cn }
npos
→
“prompt”
{ c1 ... cn }
npos
→
L2/I1
L1/I2
obj or result
“1”
“0”
L = Level; A = Argument; I = item
Example:
See also:
CHR
Type:
Description:
CHOOSE with the following three lines as input would produce a three-line choose box:
"Select a Program"
{ { "Pie Chart" «PIE» } { "Inverse Function" «ROOTR» }
{ "Animate Taylor" «TSA» } }
1
INFORM, NOVAL
Command
Character Command: Returns a string representing the character corresponding to the character
code n.
ATAN
3-14 Full Command and Function Reference
Full Command and Function Reference 3-35
The inverse of SIN is a relation, not a function, since SIN sends more than one argument to the
same result. The inverse relation for SIN is expressed by ISOL as the general solution:
ASIN(Z)*(-1)^n1+π*n1
The function ASIN is the inverse of a part of SIN, a part defined by restricting the domain of SIN
such that:
• each argument is sent to a distinct result, and
• each possible result is achieved.
The points in this restricted domain of SIN are called the principal values of the inverse relation.
ASIN in its entirety is called the principal branch of the inverse relation, and the points sent by
ASIN to the boundary of the restricted domain of SIN form the branch cuts of ASIN.
The principal branch used by the calculator for ASIN was chosen because it is analytic in the
regions where the arguments of the real-valued inverse function are defined. The branch cut for the
complex-valued arc sine function occurs where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graphs below show the domain and range of ASIN. The graph of the domain shows where
the branch cuts occur: the heavy solid line marks one side of a cut, while the feathered lines mark
the other side of a cut. The graph of the range shows where each side of each cut is mapped
under the function. These graphs show the inverse relation ASIN(Z)*(–1)^n1+π*n1 for the case
n1=0. For other values of n1, the vertical band in the lower graph is translated to the right (for n1
positive) or to the left (for n1 negative). Taken together, the bands cover the whole complex
plane, which is the domain of SIN.
View these graphs with domain and range reversed to see how the domain of SIN is restricted to
make an inverse function possible. Consider the vertical band in the lower graph as the restricted
domain Z = (x, y). SIN sends this domain onto the whole complex plane in the range
W = (u, v) = SIN(x, y) in the upper graph.
CEIL
Type:
Function
Description:
Ceiling Function: Returns the smallest integer greater than or equal to the argument.
Access:
!´REAL LL CEIL
( ´ is the left-shift of the Pkey).
Flags:
Numerical Results (–3)
Input/Output:
Level 1/Argument 1
See also:
CENTR
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
x
→
n
x_unit
→
n_unit
'symb'
→
'CEIL(symb)'
FLOOR, IP, RND, TRNC
Command
Center Command: Adjusts the first two parameters in the reserved variable PPAR, (xmin, ymin) and
(xmax, ymax), so that the point represented by the argument (x, y) is the plot center. On the HP 50g
and 49g+, the center pixel is in row 40, column 65 when PICT is its default size (131 × 80). On
the 48gII, the center pixel is in row 32, column 65 when PICT is its default size (131 × 64).
If the argument is a real number x, CENTR makes the point (x,0) the plot center.
…µCENTR
Level 1/Argument 1
See also:
CF
Type:
Description:
Level 1/Item 1
(x, y)
→
x
→
SCALE
Command
Clear Flag Command: Clears the specified user or system flag.
User flags are numbered 1 through 128. System flags are numbered –1 through –128. See
Appendix C for a listing of the calculator’s system flags and their flag numbers.
Access:
!°TESTLLCF
Input/Output:
( °is the left-shift of the Nkey).
Level 1/Argument 1
nflagnumber
See also:
%CH
Type:
Description:
Access:
Flags:
!¼
( ¼is the left-shift of the Skey).
Principal Solution (–1), Numerical Results (–3), Angle Mode (–17, –18)
3-16 Full Command and Function Reference
Access:
Flags:
Level 1/Item 1
→
FC?, FC?C, FS?, FS?C, SF
Function
Percent Change Function: Returns the percent change from x to y as a percentage of x.
If both arguments are unit objects, the units must be consistent with each other. The dimensions
of a unit object are dropped from the result, but units are part of the calculation.
For more information on using temperature units with arithmetic functions, refer to the keyword
entry of +.
!´REAL %CH
Numerical Results (–3)
( ´ is the left-shift of the Pkey).
Full Command and Function Reference 3-33
The principal branch used by the calculator for ASINH was chosen because it is analytic in the
regions where the arguments of the real-valued function are defined. The branch cut for the
complex-valued ASINH function occurs where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graph for ASINH can be found from the graph for ASIN (see ASIN) and the relationship
asinh z = –i asin iz.
Access:
…ÑHYPERBOLIC ASINH
(Ñ is the right-shift of the 8key).
Flags:
Principal Solution (–1), Numerical Results (–3)
Input/Output:
Level 1/Argument 1
z
See also:
ASN
Type:
Description:
'symb'
ACOSH, ATANH, ISOL, SINH
Level 1/Item 1
→
asinh z
→
'ASINH(symb)'
Command
Assign Command: Defines a single key on the user keyboard by assigning the given object to the
key xkey, which is specified as rc.pf.
The argument xkey is a real number rc.pf specifying the key by its row number r, column number c,
shift plane p and shift-and-hold flag f. A value of f=0 represents a normal shifted key assignment
(where the shift is released prior to pressing the key); whereby f=1 corresponds to a shift-andhold key assignment indicated by “&” in the table below (where the shift is held while pressing
the key). The legal values for p and f are as follows:
Value of
.pf
Shift
Value
of .pf
Shift
( ãis the right-shift of the 3key).
Access:
…ãB→R
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output:
Level 1/Argument 1
Unshifted [key]
.20
!(left-shifted) [key]
.21
! & [key]
.30
…(right-shifted) [key]
.31
… & [key]
.40
~(alpha-shifted) [key]
.41
~& [key]
.50
~!(alpha left-shifted) [key]
.51
~!& [key]
.60
~…(alpha right-shifted) [key]
.61
~…& [key]
Once ASN has been executed, pressing a given key in User or 1-User mode executes the userassigned object. The user key assignment remains in effect until the assignment is altered by ASN,
STOKEYS, or DELKEYS. Keys without user assignments maintain their standard definitions.
If the argument obj is the name SKEY, then the specified key is restored to its standard key
assignment on the user keyboard. This is meaningful only when all standard key assignments had
been suppressed (for the user keyboard) by the command S DELKEYS (see DELKEYS).
To make multiple key assignments simultaneously, use STOKEYS. To delete key assignments, use
DELKEYS.
Level 1/Item 1
→
#n
See also:
C$
Type:
Description:
n
R→B
Access:
Example 1:
Command
Counted String Command: Enters C$ on the command line to help with the manual entry of a
string object. Must be followed by a number indicating the number of characters to include in the
strings, or an additional $ to indicate that the rest of the command line is a single string. There
must be exactly one separator character after the second $ and before the body of the string.
If the declared length is greater than the number of characters actually available, the string is
automatically truncated to the correct length.
None. Must be typed in.
C$ 3 a"b returns "a"b" on level 1.
Example 2:
C$ 3abcdef returns "abc" on level 2 and 'def' on level 1 (assuming def is undefined).
Example 3:
C$ $ abcdef returns "abcdef" on level 1.
C2P
Type:
Description:
Command
Takes a list of cycles as an argument, and returns the equivalent permutation. In other words,
finds a permutation from its cyclical decomposition.
Output:
Example:
Command:
Result:
Arithmetic, !ÞPERMUTATION
A list of cycles equivalent to a permutation. For example, the list {1,3,5} defines a cycle C, such
that C(1)=3, C(3)=5 and C(5)=1, while items 2 and 4 are not changed. This could be followed by
{2,4} which defines a cycle C, such that C(2)=4, and C(4)=2.
A list representing the permutation equivalent to the cycles.
Convert the cycles given by {{1,3,5},{2,4}} into a permutation:
C2P({{1,3,5},{2,4}})
{3,4,5,2,1}
See also:
P2C, CIRC
Access:
Input:
.00 or .10
3-18 Full Command and Function Reference
If # n ≥ # 1000000000000 (base 10), only the 12 most significant decimal digits are preserved in
the resulting mantissa.
CASCFG
Type:
Command
Description:
Restores the default CAS mode settings. This command is almost equivalent to pressing L
!RESET, then selecting “Reset all” and pressing !!OK!, when the CAS Modes input form is displayed.
The difference is that CASCFG sets the modulus value to 13, whereas “Reset all” sets the
modulus to 3.
Access:
Catalog, …µ
Full Command and Function Reference 3-31
Input:
Level 1/Item 1: An expression giving the name of the global variable to be added to the
REALASSUME list, and the assumption to be placed on it, or a list of such assumptions.
Output:
Level 1/Item 1: The input expression or list of expressions.
Example:
Add the CAS assumption that the global variable Z is real and positive. Note that ASSUME will
replace Z>0 with Z≥0, which does not guarantee that Z is positive, so Z≥MINR is used instead,
which guarantees that Z is greater than or equal to the smallest positive number the calculator
recognizes.
Command:
Result:
See also:
ATAN
Type:
Description:
BINS
Type:
Description:
ASSUME(Z≥MINR)
Z≥MINR
ADDTOREAL, UNASSUME
Analytic Function
Arc Tangent Analytic Function: Returns the value of the angle having the given tangent.
For a real argument, the result ranges from –90 to +90 degrees (–π/2 to +π/2 radians; –100 to
+100 grads).
The inverse of TAN is a relation, not a function, since TAN sends more than one argument to the
same result. The inverse relation for TAN is expressed by ISOL as the general solution:
ATAN(Z)+π*n1
The function ATAN is the inverse of a part of TAN, a part defined by restricting the domain of
TAN such that:
• each argument is sent to a distinct result, and
• each possible result is achieved.
The points in this restricted domain of TAN are called the principal values of the inverse relation.
ATAN in its entirety is called the principal branch of the inverse relation, and the points sent by
ATAN to the boundary of the restricted domain of TAN form the branch cuts of ATAN.
The principal branch used by the calculator for ATAN was chosen because it is analytic in the
regions where the arguments of the real-valued inverse function are defined. The branch cuts for
the complex-valued arc tangent function occur where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graphs below show the domain and range of ATAN. The graph of the domain shows where
the branch cuts occur: the heavy solid line marks one side of a cut, while the feathered lines mark
the other side of a cut. The graph of the range shows where each side of each cut is mapped
under the function.
These graphs show the inverse relation ATAN(Z)+π*n1 for the case n1 = 0. For other values of
n1, the vertical band in the lower graph is translated to the right (for n1 positive) or to the left (for
n1 negative). Together, the bands cover the whole complex plane, the domain of TAN.
View these graphs with domain and range reversed to see how the domain of TAN is restricted to
make an inverse function possible. Consider the vertical band in the lower graph as the restricted
domain Z = (x, y). TAN sends this domain onto the whole complex plane in the range W = (u,
v) = TAN(x, y) in the upper graph.
x – x m in
n f r e q b in n = IP -----------------x w i d th
for xmin ≤ x ≤ xmax, where xmax = xmin + (nbins)(xwidth).
Access:
…µBINS
Input/Output:
L3/A1
L2/A2
L1/A3
xmin
xwidth
nbins
→
L2/I1
L1/I2
[[ nbin 1 ... nbin n ]]
[ nbin L nbin R]
L = Level; A = Argument; I = item
Example:
See also:
BLANK
Type:
Description:
Access:
Input/Output:
See also:
BOX
Type:
Description:
Access:
3-20 Full Command and Function Reference
Command
Sort into Frequency Bins Command: Sorts the elements of the independent column (XCOL) of
the current statistics matrix (the reserved variable ΣDAT) into (nbins + 2) bins, where the left edge
of bin 1 starts at value xmin and each bin has width xwidth.
BINS returns a matrix containing the frequency of occurrences in each bin, and a 2-element array
containing the frequency of occurrences falling below or above the defined range of x-values. The
array can be stored into the reserved variable ΣDAT and used to plot a bar histogram of the bin
data (for example, by executing BARPLOT).
For each element x in ΣDAT, the nth bin count nfreq bin n is incremented, where:
If the independent column of ΣDAT contains the following data:
7 2 3 1 4 6 9 0 1 1 3 5 13 2 6 9 5 8 5
1 2 5 BINS returns [[ 5 ][ 3 ][ 5 ][ 2 ][ 2 ]] and [ 1 1 ]
The data has been sorted into 5 bins of width 2, starting at x-value 1 and ending at x-value 11.
The first element of the matrix shows that 5 x-values (2 1 1 1 2) fell in bin 1, where bin 1 ranges
from x-value 1 through 2.99999999999. The vector shows that one x-value was less than xmin (0),
and one was greater than xmax (13).
BARPLOT, XCOL
Command
Blank Graphics Object Command: Creates a blank graphics object of the specified width and
height.
!°LGROB BLANK
( °is the left-shift of the Nkey).
Level 2/Argument 1
Level 1/Argument 2
#nwidth
#mheight
Level 1/Item 1
→
grobblank
→GROB, LCD→
Command Operation
Box Command: Draws in PICT a box whose opposite corners are defined by the specified pixel
or user-unit coordinates.
!°LPICT BOX
( °is the left-shift of the Nkey).
Full Command and Function Reference 3-29
ATANH
Type:
Description:
Access:
Flags:
Input/Output:
Analytic Function
Arc Hyperbolic Tangent Analytic Function: Returns the inverse hyperbolic tangent of the
argument.
For real arguments |x| > 1, ATANH returns the complex result obtained for the argument (x, 0).
For a real argument x=±1, an Infinite Result exception occurs. If flag –22 is set (no error), the
sign of the result (MAXR) matches that of the argument.
The inverse of TANH is a relation, not a function, since TANH sends more than one argument to
the same result. The inverse relation for TANH is expressed by ISOL as the general solution;
ATANH(Z)+π*i*n1
The function ATANH is the inverse of a part of TANH, a part defined by restricting the domain
of TANH such that:
• each argument is sent to a distinct result, and
• each possible result is achieved.
The points in this restricted domain of TANH are called the principal values of the inverse relation.
ATANH in its entirety is called the principal branch of the inverse relation, and the points sent by
ATANH to the boundary of the restricted domain of TANH form the branch cuts of ATANH.
The principal branch used by the calculator for ATANH was chosen because it is analytic in the
regions where the arguments of the real-valued function are defined. The branch cut for the
complex-valued ATANH function occurs where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graph for ATANH can be found from the graph for ATAN (see ATAN) and the relationship
atanh z = –i atan iz.
…ÑHYPERBOLIC ATAN
(Ñ is the right-shift of the 8key).
Principal Solution (–1), Numerical Results (–3), Infinite Result Exception (–22)
Level 1/Argument 1
z
See also:
ATICK
Type:
Description:
Access:
'symb'
ACOSH, ASINH, ISOL, TANH
Level 1/Item 1
• ptype is a command name specifying the plot type. Executing the command BAR places the
command name BAR in PPAR.
• depend is a name specifying a label for the vertical axis. The default value is Y.
A bar is drawn for each element of the column in ΣDAT. Its width is specified by res and its
height is the value of the element. The location of the first bar can be specified by indep;
otherwise, the value in (xmin, ymin) is used.
Access:
…µBAR
Input/Output: None
See also:
CONIC, DIFFEQ, FUNCTION, GRIDMAP, HISTOGRAM, PARAMETRIC,
PARSURFACE, PCONTOUR, POLAR, SCATTER, SLOPEFIELD, TRUTH, WIREFRAME,
YSLICE
BARPLOT
Type:
Description:
Access:
Input:
Output:
See also:
Command
Draw Bar Plot Command: Plots a bar chart of the specified column of the current statistics matrix
(reserved variable ΣDAT).
The data column to be plotted is specified by XCOL and is stored as the first parameter in
reserved variable ΣPAR. The default column is 1. Data can be positive or negative, resulting in
bars above or below the axis. The y-axis is autoscaled, and the plot type is set to BAR.
When BARPLOT is executed from a program, the resulting plot does not persist unless
PICTURE, PVIEW (with an empty list argument), or FREEZE is subsequently executed.
…µBARPLOT
None
A bar chart based on ΣDAT.
FREEZE, HISTPLOT, PICTURE, PVIEW, SCATRPLOT, XCOL
BASIS
Type:
Command
Description:
Determines the basis of a sub-space of the n-space Rn.
→
atanh z
Access:
Matrices, !Ø LVECTOR
→
'ATANH(symb)'
Input:
Output:
Flags:
A list of vectors defining a vector sub-space of Rn.
A list containing the vectors of a basis of the vector sub-space.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Command
Axes Tick-Mark Command: Sets the axes tick-mark annotation in the reserved variable PPAR.
Given x, ATICK sets the tick-mark annotation to x units on both the x- and the y-axis. For
example, 2 would place tick-marks every 2 units on both axes.
Given #n, ATICK sets the tick-mark annotation to #n pixels on both the x- and the y-axis. For
example, #5 would place tick-marks every 5 pixels on both axes.
Given { x y }, ATICK sets the tick-mark unit annotation for each axis individually. For example,
{ 10 3 } would mark the x-axis at every multiple of 10 units, and the y-axis at every multiple of 3
units.
Given { #n #m } ATICK sets the tick-mark pixel annotation for each axis individually. For
example, {#6 #2 } would mark the x-axis every 6 pixels, and the y-axis every 2 pixels.
Example:
Command:
Result:
See also:
BAUD
Type:
Description:
Access:
Find the vectors that form a basis of the sub-space defined by [1,2,3], [1,1,1], and [2,3,4]
BASIS({[1,2,3],[1,1,1],[2,3,4]})
{[1,0,-1],[0,1,2]}
IBASIS
Command
Baud Rate Command: Specifies bit-transfer rate.
Legal baud rates are 2400, 4800, 9600, 14400, 19200, 38400, 57600 and 115200 (default).
…µBAUD
…µATICK
3-22 Full Command and Function Reference
Full Command and Function Reference 3-27
Result:
AUTO
Type:
Description:
Command
Autoscale Command: Calculates a y-axis display range, or an x- and y-axis display range.
The action of AUTO depends on the plot type as follows:
Plot Type
Scaling Action
FUNCTION
Samples the equation in EQ at 40 values of the independent
variable, equally spaced through the x-axis plotting range, discards
points that return ±∞, then sets the y-axis display range to include
the maximum, minimum, and origin.
CONIC
Sets the y-axis scale equal to the x-axis scale.
POLAR
Samples the equation in EQ at 40 values of the independent
variable, equally spaced through the plotting range, discards
points that return ±∞, then sets both the x- and y-axis display
ranges in the same manner as for plot type FUNCTION.
Access:
…µAXES
Input/Output:
Level 1/Argument 1
Example:
Level 1/Item 1
(x, y)
→
{ (x, y) atick “x-axis label” “y-axis label” }
→
The command sequence
{ (0,0) 2 "t" "y" } AXES LABEL
specifies an axes intersection at (0,0), tick-mark annotation every 2 units, and puts the labels t and y
PICT. The labels are positioned to identify the horizontal and vertical axes respectively.
ATICK, DRAW, DRAX, LABEL
PARAMETRIC
Same as POLAR.
TRUTH
No action.
AXL
Sets the x-axis display range from 0 to the number of elements in
ΣDAT, plus 1. Sets the y-range to the minimum and maximum of
the elements. The x-axis is always included.
Type:
Command
Description:
Converts a list to an array, or an array to a list.
Access:
Convert, !Ú
Sets the x-axis display range to the minimum and maximum of
the elements in ΣDAT. Sets the y-axis display range from 0 to the
number of rows in ΣDAT.
Input:
A list or an array.
Output:
If the input is a list, returns the corresponding array. If the input is an array, returns the
corresponding list.
Example:
Convert the following matrix to a list:
BAR
HISTOGRAM
SCATTER
Sets the x-axis display range to the minimum and maximum of
the independent variable column (XCOL) in ΣDAT. Sets the yaxis display range to the minimum and maximum of the
dependent variable column (YCOL).
AUTO does not affect 3D plots.
AUTO actually calculates a y-axis display range and then expands that range so that the menu
labels do not obscure the resultant plot.
AUTO does not draw a plot — execute DRAW to do so.
Access:
…µAUTO
Input/Output: None
See also:
DRAW, SCALEH, SCALE, SCLΣ, SCALEW, XRNG, YRNG
AXES
Type:
Description:
The argument for AXES (a complex number or list) is stored as the fifth parameter in the
reserved variable PPAR. How the argument is used depends on the type of object it is:
• If the argument is a complex number, it replaces the current entry in PPAR.
• If the argument is a list containing any or all of the above variables, only variables that are
specified are affected.
atick has the same format as the argument for the ATICK command. This is the variable that is
affected by the ATICK command.
The default value for AXES is (0,0).
Axes labels are not displayed in PICT until subsequent execution of LABEL.
1 2 3
4 5 6
Command
Axes Command: Specifies the intersection coordinates of the x- and y-axes, tick-mark annotation,
and the labels for the x- and y-axes. This information is stored in the reserved variable PPAR.
3-24 Full Command and Function Reference
See also:
MATRIX CONVERT,
or matrices !Ø
OPERATIONS
01
10
Command:
Result:
See also:
AXL([[0,1][1,0]])
{{0,1},{1,0}}
AXM, AXQ
AXM
Type:
Command
Description:
Converts a numeric array (object type 3) to a symbolic matrix (object type 29), or a symbolic
matrix to a numeric array.
Access:
Matrices, !Ø
OPERATIONS
Input:
A numeric array or a symbolic matrix.
Output:
The corresponding symbolic matrix or numeric array.
Full Command and Function Reference 3-25
Access:
The constant value is a real or complex number taken from argument 2/level 1. The resulting
array is either a new array, or an existing array with its elements replaced by the constant,
depending on the object in argument 1/level 2.
• Creating a new array: If argument 1/level 2 contains a list of one or two integers, CON returns
a new array. If the list contains a single integer ncolumns, CON returns a constant vector with n
elements. If the list contains two integers nrows and mcolumns, CON returns a constant matrix with
n rows and m columns.
• Replacing the elements of an existing array: If argument 1/level 2 contains an array, CON
returns an array of the same dimensions, with each element equal to the constant. If the
constant is a complex number, the original array must also be complex.
• If argument 1/level 2 contains a name, the name must identify a variable that contains an array.
In this case, the elements of the array are replaced by the constant. If the constant is a complex
number, the original array must also be complex.
( ´ is the left-shift of the Pkey).
!´MATRIX MAKE CON
!Ø CREATE CON
( Ø is the left-shift of the 5key).
Input/Output:
Example 1:
Example 2:
See also:
COND
Type:
Description:
Access:
Level 1/Argument 2
Level 1/Item 1
{ ncolumns }
zconstant
→
[ vectorconstant ]
{ nrows mcolumns }
zconstant
→
[[ matrixconstant ]]
[ R-array ]
xconstant
→
[ R-arrayconstant ]
[ C-array ]
zconstant
→
[ C-arrayconstant ]
→
'name'
zconstant
{ 2 2 } 6 CON returns the matrix [[ 6 6 ][ 6 6 ]].
[ (2,4) (7,9) ] 3 CON returns the complex vector [ (3,0) (3,0) ].
IDN
Command
Condition Number Command: Returns the 1-norm (column norm) condition number of a square
matrix.
The condition number of a matrix is the product of the norm of the matrix and the norm of the
inverse of the matrix. COND uses the 1-norm and computes the condition number of the matrix
without computing the inverse of the matrix.
The condition number expresses the sensitivity of the problem of solving a system of linear
equations having coefficients represented by the elements of the matrix (this includes inverting
the matrix). That is, it indicates how much an error in the inputs may be magnified in the outputs
of calculations using the matrix.
In many linear algebra computations, the base 10 logarithm of the condition number of the matrix
is an estimate of the number of digits of precision that might be lost in computations using that
matrix. A reasonable rule of thumb is that the number of digits of accuracy in the result is
approximately MIN(12,15–log10(COND)).
!´MATRIX NORMALIZE COND ( ´ is the left-shift of the Pkey).
!Ø
OPERATIONS COND
( Ø is the left-shift of the 5key).
Input/Output:
Level 1/Argument 1
[[ matrix ]]m×n
3-42 Full Command and Function Reference
Level 1/Item 1
→
L1
obj2
obj1
→
L4
L3
L2
L1
obj2
obj1
obj2
obj1
L = Level
See also:
DUP, DUPN, PICK
DUPDUP
Type:
Description:
Access:
RPL Command
Duplicates an object twice. Same as DUP DUP.
!°STACK LL DUPDUP
( °is the left-shift of the Nkey).
ISTACK LL DUPDUP
Input/Output:
Level 1
Input/Output:
Level 2/Argument 1
L2
See also:
DUPN
Type:
Description:
Access:
→
obj
DUP, NDUPN, DUPN, DUP2
Level 3
Level 2
Level 1
obj
obj
obj
RPL Command
Duplicate n Objects Command: Takes an integer n from level 1 of the stack, and returns copies of
the objects on stack levels 2 through n + 1.
!°STACK LL DUPN
( °is the left-shift of the Nkey).
ISTACK LL DUPN
Input/Output:
See also:
D→R
Type:
Description:
Access:
Flags:
Input/Output:
Li+1
Li …L3
L2
L1
obj1
obj2 … obji–1
obji
n
→
Li+n
Li+n–1 ... L2
L1
obj1
obj2 ... obji–1
obji
L = Level
DUP, DUP2, PICK
Function
Degrees to Radians Function: Converts a real number representing an angle in degrees to its
equivalent in radians.
This function operates independently of the angle mode.
!´REAL LL D→R
( ´ is the left-shift of the Pkey).
Numerical Results (–3)
Level 1/Argument 1
Level 1/Item 1
x
→
(π/180)x
'symb'
→
'D→R(symb)'
See also:
R→D
e
Type:
Description:
Function
e Function: Returns the symbolic constant e or its numerical representation, 2.71828182846.
xconditionnumber
Full Command and Function Reference 3-71
DROITE
Input/Output:
Level 1/Argument 1
Level 1/Item 1
x
→
x
(x, y)
→
(x, –y)
[ R-array ]
→
[ R-array ]
[ C-array ]1
→
[ C-array ]2
See also:
→
'symb'
'CONJ(symb)'
[ (3,4) (7,2) ] CONJ returns [ (3,-4) (7,-2) ]
A square matrix A containing complex elements is said to be Hermitian if AH = A, where AH is
the same as a normal transpose except that the complex conjugate of each element is used. The
following program returns 1 if the input matrix is Hermitian, and a 0 if it is not.
« DUP TRN CONJ SAME »
ABS, IM, RE, SCONJ, SIGN
CONLIB
Type:
Description:
Command
Open Constants Library Command: Opens the Constants Library catalog.
Example 1:
Example 2:
Type:
Function
Description:
Returns an equation for the line through two given points in a plane. For more than two points,
LAGRANGE will fit a polynomial.
Access:
Catalog, …µ
Input:
Level 2/Argument 1: The first point, in the form a+b *i, or (a,b), where a and b must be numbers,
or variables or expressions that evaluate to numbers.
Level 1/Argument 2: The second point, in the form c+d *i, or (c,d), where c and d must be
numbers, or variables or expressions that evaluate to numbers.
Output:
Level 1/Item 1: An equation for the straight line through the two points. The general form is
Y=(d-b)/(c-a)*(X-a)+b.
Flags:
Numeric mode must not be set (flag –3 clear).
Complex mode must be set (flag –103 set).
In algebraic mode, if any of a, b, c, d are variables, they will be converted to their numeric values,
even if “argument to symbolic” mode is set (flag –3 clear). In RPN mode, they will be returned as
variables. If ALG mode is set and “constants to numeric” mode is selected (flag –2 set) ̟ and e
used in inputs will be converted to their real number approximations, otherwise they will be
returned in symbolic form.
Access:
GCONSTANTS LIBRARY
Input/Output: None
See also:
CONST
Example 1:
Command:
Result:
DROITE((1, 2), (3, 4))
CONST
Type:
Description:
Example 2:
Command:
Find a symbolic equation for the straight line through the points (π, e), (e, π).
With “constants to symbolic ” mode selected and exact mode set, type:
Access:
Flags:
Input/Output:
Function
Constant Value Command: Returns the value of a constant.
CONST returns the value of the specified constant. It chooses the unit type depending on flag 60:
SI if clear, English if set, and uses the units depending on flag 61: units if clear, no units if set.
See “Tables of Units and Constants” in appendix B of this reference for a list of the constants
available in the Constants Library.
…µCONST
Units Type (60), Units Usage (61)
Level 1/Argument 1
'name'
See also:
→
x
CONSTANTS
Type:
Command
Description:
Displays a menu or list of CAS symbolic constants.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
Input/Output: None
See also:
Y=X-1.+2.
DROITE(π+e*i, e+π*i)
Result:
Y=(π-e)/(e-π)*(X-π)+e
See also:
LAGRANGE
DROP
Type:
Description:
Access:
RPL Command
Drop Object Command: Removes the level 1 object from the stack.
!°STACK DROP
( °is the left-shift of the Nkey).
ISTACK DROP
Level 1/Item 1
CONLIB
Find an equation for the straight line through the points (1, 2), (3, 4).
ƒ in RPN mode executes DROP when no command line is present.
Input/Output:
Level 1
obj
Level 1
→
See also:
CLEAR, DROPN, DROP2
DROP2
Type:
Description:
Access:
RPL Command
Drop 2 Objects Command: Removes the first two objects from the stack.
!°STACK LL DROP2
( °is the left-shift of the Nkey).
ISTACK LL DROP2
ALGB, ARIT, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR, MODULAR,
POLYNOMIAL, REWRITE, TESTS, TRIGO
3-44 Full Command and Function Reference
Full Command and Function Reference 3-69
COS
Type:
Description:
Analytic Function
Cosine Analytic Function: Returns the cosine of the argument.
For real arguments, the current angle mode determines the number’s interpretation as an angle,
unless the angular units are specified.
For complex arguments, cos(x + iy) = cosx coshy – i sinx sinhy.
If the argument for COS is a unit object, then the specified angular unit overrides the angle mode
to determine the result. Integration and differentiation, on the other hand, always observe the
angle mode. Therefore, to correctly integrate or differentiate expressions containing COS with a
unit object, the angle mode must be set to Radians (since this is a “neutral” mode).
Access:
Input/Output:
command ENDSUB. Both of these commands return an Undefined Local Name error if
executed when DOSUBS is not active.
DOSUBS returns the Invalid User Function error if the object at level 1/argument 3 is a user
program that does not contain only one command and does not have a user-defined function
structure. DOSUBS also returns the Wrong Argument Count error if the object at level
1/argument 3 is a command that does not accept 1 to 5 arguments of specific types (DUP, ROT,
or →LIST, for example).
!°LIST PROCEDURES DOSUBS ( °is the left-shift of the Nkey).
Access:
T
Flags:
Numerical Results (–3), Angle Mode (–17, –18)
Input/Output:
Level 1/Argument 1
See also:
COSH
Type:
Description:
Access:
Level 1/Item 1
« program »
→
Level 1/Item 1
{ list }2
{ list }1
n
command
→
{ list }2
{ list }1
n
name
→
{ list }2
{ list }2
cos z
{ list }1
« program »
→
'symb'
→
'COS(symb)'
{ list }1
command
→
{ list }2
x_unitangular
→
cos (x_unitangular)
→
{ list }2
ACOS, SIN, TAN
Example 1:
Analytic Function
Hyperbolic Cosine Analytic Function: Returns the hyperbolic cosine of the argument.
For complex arguments, cosh(x + iy) = coshx cosy + i sinhx siny.
(Ñ is the right-shift of the 8key).
…ÑHYPERBOLIC COSH
Example 2:
Example 3:
( ´is the left-shift of the Pkey).
Level 1/Item 1
z
→
cosh z
'symb'
→
'COSH(symb)'
ACOSH, SINH, TANH
Command
Covariance Command: Returns the sample covariance of the independent and dependent data
columns in the current statistics matrix (reserved variable ΣDAT).
The columns are specified by the first two elements in reserved variable ΣPAR, set by XCOL and
YCOL respectively. If ΣPAR does not exist, COV creates it and sets the elements to their default
values (1 and 2).
The covariance is calculated with the following formula:
See also:
DOT
Type:
Description:
Access:
n
1
------------ ∑ ( x in 1 – x n 1 ) ( x in 2 – x n 2 )
n – 1i = 1
Access:
Level 1/Argument 3
n
→
Level 1/Argument 1
COV
Type:
Description:
Level 2/Argument 2
{ list }1
z
!´HYPERBOLIC COSH
Flags:
Numerical Results (–3)
Input/Output:
See also:
Level 3/Argument 1
where x in1 is the ith coordinate value in column n1, x in2 is the ith coordinate value in the column
xn1mean of the data in column n1,
n2 ,
is the
is thexnmean
of the data in column n2, and n is the
2
number of data points.
…µCOV
3-46 Full Command and Function Reference
{ list }1
name
{ A B C D E } « - » DOSUBS returns
{ 'A-B' 'B-C' 'C-D' 'D-E' }.
{ A B C } 2 « DUP * * » DOSUBS returns
{ 'A*(B*B)' 'B*(C*C)' }.
Entering
{ 1 2 3 4 5 } « → a b
« CASE 'NSUB==1' THEN a END
'NSUB==ENDSUB' THEN b END
'a+b' EVAL END » » DOSUBS
returns { 1 5 7 5 }.
DOLIST, ENDSUB, NSUB, STREAM
Command
Dot Product Command: Returns the dot product A•B of two arrays A and B, calculated as the
sum of the products of the corresponding elements of the two arrays.
Both arrays must have the same dimensions.
Some authorities define the dot product of two complex arrays as the sum of the products of the
conjugated elements of one array with their corresponding elements from the other array. The
calculator uses the ordinary products without conjugation. If you prefer the alternative definition,
apply CONJ to one array before using DOT.
!Ø LVECTOR DOT
!´VECTOR DOT
( Ø is the left-shift of the 5key).
( ´ is the left-shift of the Pkey).
Input/Output:
Example:
See also:
Level 2/Argument 1
Level 1/Argument 2
[ array A ]
[ array B ]
Level 1/Item 1
→
x
[ 1 2 3 ][ 4 5 6 ] DOT returns 32 (by calculating 1 x 4 + 2 x 5 + 3 x 6).
CNRM, CROSS, DET, RNRM
Full Command and Function Reference 3-67
Access:
!Ø
CREATE COLUMN CSWP
!´MATRIX COL CSWP
( Ø is the left-shift of the 5key).
Input/Output:
( ´ is the left-shift of the Pkey).
Level 1/Argument 1
See also:
Level 3/Argument 1
Level 2/Argument 2
Level 1/Argument 3
[[ matrix ]]1
ncolumni
ncolumnj
→
[[ matrix ]]2
nelementi
nelementj
→
[ vector ]2
[ vector ]1
COL+, COL–, RSWP
Level 1/Item 1
CURL
Type:
Description:
Function
Access:
Calculus, !ÖDERIV. & INTEG.
Input:
Level 2/Argument 1: A three-dimensional vector function of three variables.
Level 1/Argument 2: An array comprising the three variables.
Returns the curl of a three-dimensional vector function.
Output:
The curl of the vector function with respect to the specified variables.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Find the curl of the following vector function:
2
2
2
v = x yi + x yj + y zk
˜
˜
˜
Command:
Result:
See Also:
Example:
Command:
Result:
CYLIN
Type:
Description:
See also:
DOERR
Type:
Description:
Access:
Input/Output:
DIV, HESS, VPOTENTIAL
Example:
See also:
DOLIST
Type:
Description:
CYCLOTOMIC(20)
X^8-X^6+X^4-X^2+1
Command
Cylindrical Mode Command: Sets Cylindrical coordinate mode.
CYLIN clears flag –15 and sets flag –16.
In Cylindrical mode, vectors are displayed as polar components. Therefore, a 3D vector would
appear as [ R €θ Z ].
3-48 Full Command and Function Reference
Command
Do Error Command: Executes a “user-specified” error, causing a program to behave exactly as if
a normal error had occurred during program execution.
DOERR causes a program to behave exactly as if a normal error has occurred during program
execution. The error message depends on the argument provided to DOERR:
• nerror or #nerror display the corresponding built-in error message.
• "error" displays the contents of the string. (A subsequent execution of ERRM returns "error".
ERRN returns # 70000h.)
• 0 abandons program execution with an ‘interrupted’ error message (ERRN = #13Fh).
• 0 DOERR is equivalent to pressing −.
!°LLERROR DOERR
( °is the left-shift of the Nkey).
nerror
[Z*2*Y,0,Y*2*X-X^2]
Arithmetic, !ÞPOLYNOMIAL
A non-negative integer n
The cyclotomic polynomial of order n.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Find the 20th cyclotomic polynomial.
→
UNTIL
END
T/F →
The following program counts down from 100 to 0 and leaves the integers 100 to 0 on the stack:
« 100 'A' STO A DO 'A' DECR UNTIL 'A==0' END 'A' PURGE »
END, UNTIL, WHILE
Level 1/Argument 1
CURL([X^2*Y, X^2*Y, Y^2*Z],[X,Y,Z])
CYCLOTOMIC
Type:
Function
Description:
Returns the cyclotomic polynomial of order n. This is the polynomial whose roots are all the nth
roots of 1, except those that are also roots of 1 for smaller values of n. For example, if n is 4, the
4th roots of 1 are {1, i, -1, -i}, but 1 is the 1st root of 1 and –1 is a 2nd root of 1, so only i and -i are
left, giving the polynomial (x-i)(x+i) = x2+1.
Access:
Input:
Output:
Flags:
Example:
Level 1/Item 1
→
DO
Input/Output:
Access:
Level 1/Item 1
→
#nerror
→
“error”
→
→
0
The following program takes a number from the stack and returns an error if the number is
greater than 10:
« → X « CASE 'X>10' THEN "X IS TOO BIG" DOERR END END » »
ERRM, ERRN, ERR0
Command
Do to List Command: Applies commands, programs, or user-defined functions to lists.
The number of lists, n, can be omitted when the first or level 1 argument is any of the following:
• A command.
• A program containing exactly one command (e.g. « DUP »)
• A program conforming to the structure of a user-defined function.
The final argument 1 (or level 1 object) can be a local or global name that refers to a program or
command.
All lists must be the same length l. The program is executed l times: on the ith iteration, n objects
each taken from the ith position in each list are entered on the stack in the same order as in their
original lists, and the program is executed. The results from each execution are left on the stack.
After the final iteration, any new results are combined into a single list.
!°LIST PROCEDURES DOLIST ( °is the left-shift of the Nkey).
Full Command and Function Reference 3-65
Flags:
Date Format (–42)
Input/Output:
Flags:
Level 1/Argument 1
Example:
See also:
→DATE
Type:
Description:
Access:
Flags:
Input/Output:
Level 1/Item 1
→
date
If the current date is May 12, 2010, if flag –42 is clear, and if the display mode is Standard, DATE
returns 5.12201. (The trailing zeros are dropped.)
DATE+, DDAYS, TIME, TSTR
Command
Set Date Command: Sets the system date to date.
date has the form MM.DDYYYY or DD.MMYYYY, depending on the state of flag –42. MM is
month, DD is day, and YYYY is year. If YYYY is not supplied, the current specification for the
year is used. The range of allowable dates is January 1, 2000 to December 31, 2090. Inputs
between January 1, 1991 and December 31, 1999 are silently rejected by →DATE; no error is
reported and the system date is left unchanged.
…ÓTOOLS →DATE
( Ó is the right-shift of the 9 key).
…&9 →DATE
Date Format (–42)
Level 1/Argument 1
Level 1/Item 1
Example:
→
date
If flag –42 is set and the current system year is 2005, then 28.07 →DATE sets the system date as
July 28, 2005.
See also:
→TIME
DATE+
Type:
Description:
Access:
Flags:
Input/Output:
See also:
DBUG
Type:
Description:
Access:
Command
Date Addition Command: Returns a past or future date, given a date in argument 1/level 2 and a
number of days in argument 2/level 1. If xdays is negative, DATE+ calculates a past date. The
range of allowable dates is October 15, 1582, to December 31, 9999.
…ÓTOOLS L DATE+
…&9 LDATE+
Date Format (–42)
( Ó is the right-shift of the 9 key).
Level 2/Argument 1
Level 1/Argument 2
date1
xdays
Level 1/Item 1
→
datenew
DATE, DDAYS
Operation
Debug Operation: Starts program execution, then suspends it as if HALT were the first program
command.
DBUG is programmable.
!°LLRUN DBUG
3-50 Full Command and Function Reference
( °is the left-shift of the Nkey).
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
3
Example:
Command:
Result:
x +4
------------2
Find the result of x – 1 , modulo 3.
DIV2MOD(X^3+4,X^2-1)
{X X+1}
DIVIS
Type:
Description:
Command
Access:
Arithmetic, !Þor PARITH
Returns a list of divisors of a polynomial or an integer.
Input:
A polynomial or an integer.
Output:
A list containing the expressions or integers that exactly divide into the input.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Find the divisors of the following polynomial:
2
x + 3x + 2
Command:
Result:
DIVIS(X^2+3*X+2)
{1,X+1,X+2,X^2+3*X+2}
See also:
DIV2
DIVMOD
Type:
Description:
Function
Access:
Arithmetic, !Þ MODULO
Input:
Level 2/Argument 1: The dividend.
Level 1/Argument 2: The divisor.
Divides two expressions modulo the current modulus.
Output:
The quotient of the terms modulo the current modulus.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Command:
Result:
Modulo 3, divide 5x2+4x+2 by x2+1.
DIVPC
Type:
Description:
DIVMOD(5*X^2+4*X+2,X^2+1)
-((X^2-X+1)/X^2+1))
Command
Returns a Taylor polynomial for the quotient of two polynomial expressions.
Access:
Calculus, !Ö LIMITS & SERIES
Input:
Level 3/Argument 1: The numerator expression.
Level 2/Argument 2: The denominator expression.
Level 1/Argument 3: The degree of the Taylor polynomial.
Output:
The Taylor polynomial at x = 0 of the quotient of the two expressions, to the specified degree.
Full Command and Function Reference 3-63
DEDICACE
Type:
Function
Description:
Displays a greeting from the CAS team and dedication to all HP calculator users.
Access:
Catalog, …µ
Example:
In algebraic mode, the message can be extended. Try: DEDICACE(Salutations)
DEF
Type:
Description:
Function
Defines a variable or a function. Works like the DEFINE command, except that it returns a result
and can be included in an algebraic expression. Given an expression as input, DEF stores the
expression, unlike STORE which evaluates the expression and stores the numerical value.
Access:
Catalog, …µ
Input:
Level 1/Argument 1: An expression of the form
name=expression or
name(name1, … namen)=expression(name1,… name n)
In the first case, name is the name of a variable, and expression is an expression or a number to be
stored in the variable. If the variable does not exist, it is created in the current directory. In the
second case, name is the name of a variable that will be treated as a function, name1 to namen are
formal variables used to define inputs the function will take.
Output:
Level 1/Item 1: Unlike DEFINE, which returns NOVAL in Algebraic mode, and no result in
RPN mode, DEF returns the expression used as the input.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example 1:
Define a new function that calculates:
(a-b)/(a+b)
Command:
Result:
See also:
DEFINE, STORE
Access:
Flags:
Level 2/Argument 1
NEW(2,1)
1/3
Command
Define Variable or Function Command: Stores the expression on the right side of the = in the
variable specified on the left side, or creates a user-defined function.
If the left side of the equation is name only, DEFINE stores exp in the variable name.
If the left side of the equation is name followed by parenthetical arguments name1 … namen,
DEFINE creates a user-defined function and stores it in the variable name.
!à
( àis the left-shift of the 2key).
Numerical Results (–3)
3-52 Full Command and Function Reference
Level 1/Argument 2
Level 1/Item 1
→
Example:
See also:
DISPXY
Type:
Description:
Access:
Input/Output:
obj
n
The program
« "ENTER Data Now" 1 DISP 7 FREEZE HALT »
displays ENTER Data Now at the top of the display, “freezes” the entire display, and halts.
DISPXY, FREEZE, HALT, INPUT, PROMPT
Command
Display Command: Displays obj at the specified screen coordinates using a specified font size.
The list argument expects exactly two binary integers to specify the X and Y coordinates. The
level one integer argument n will display the obj using a small font if n is 1 and using the system
font if n is 2.
To facilitate the display of messages, strings are displayed without the surrounding " " delimiters.
All other objects are displayed in the same form as would be used if the object were in level 1 in
the multiline display format. If the object display requires more than one display line, the display
starts at coordinate #x #y, and continues down the display either to the end of the object or the
bottom of the display. NOTE: DISPXY is not useful for displaying grobs.
The object displayed by DISPXY persists in the display only until the keyboard is ready for input.
The FREEZE command can be used to cause the object to persist in the display until a key is
pressed.
( °is the left-shift of the Nkey).
!°LOUT DISPXY
Level 3/Argument 1
NEW(A,B)=(A-B)/(A+B)
Check that the newly defined function works:
( °is the left-shift of the Nkey).
Access:
!°LOUT DISP
Input/Output:
DEF(NEW(A,B)=(A-B)/(A+B))
Example 2:
Command:
Result:
DEFINE
Type:
Description:
for input. The FREEZE command can be used to cause the object to persist in the display until a
key is pressed.
See also:
DISTRIB
Type:
Description:
Access:
Input:
Output:
Flags:
Level 2/Argument 2
obj
{ list }
DISP, FREEZE, HALT, INPUT, PROMPT
Level 1/Argument 3
n
Level 1/Item 1
→
Command
Applies one step of the distributive property of multiplication and division with respect to
addition and subtraction. Used for single-stepping through a multi-step distribution.
!Ú REWRITE
An expression.
An equivalent expression that results from applying the distributive property of multiplication
over addition one time.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Expand (X+1)( X-1)( X+2).
Example:
Command:
Result:
DISTRIB((X+1)*(X-1)*(X+2))
See also:
FDISTRIB
X*(X-1)*(X+2)+1*(X-1)*(X+2)
Full Command and Function Reference 3-61
…&9 ALRM DELALARM
Input/Output:
Level 1/Argument 1
See also:
DELAY
Type:
Description:
nindex
FINDALARM, RCLALARM, STOALARM
Level 1/Item 1
Result:
Command
Delay Command: Specifies how many seconds the calculator waits between sending lines of
information to the printer.
Setting flag –34 directs printer output to the serial port. In this case, flag –33 must be clear.
If flag –34 is set and transmit pacing is enabled (nonzero) in reserved variable IOPAR, then
XON/XOFF handshaking controls data transmission and the delay setting has no effect.
xdelay specifies the delay time in seconds. The default delay is 0 seconds. The maximum delay is 6.9
seconds. (The sign of xdelay is ignored, so –4 DELAY is equivalent to 4 DELAY.)
The delay setting is the first parameter in the reserved variable PRTPAR.
A shorter delay setting can be useful when the calculator sends multiple lines of information to
your printer (for example, when printing a program). To optimize printing efficiency, set the delay
just longer than the time the printhead requires to print one line of information.
If you set the delay shorter than the time to print one line, you may lose information. Also, as the
batteries in the printer lose their charge, the printhead slows down, and, if you have previously
decreased the delay, you may have to increase it to avoid losing information. (Battery discharge
will not cause the printhead to slow to more than the 1.8-second default delay setting.)
Level 1/Argument 1
DELKEYS
Type:
Description:
or DIAGMAP([[1,1],[0,2]],exp(X))
→
Access:
…µDELAY
Flags:
I/O Device (–33), Printing Device (–34), I/O Device for Wire (–78)
Input/Output:
See also:
Command:
Level 1/Item 1
→
xdelay
CR, OLDPRT, PRLCD, PRST, PRSTC, PRVAR, PR1
Access:
Command
Delete Key Assignments Command: Clears user-defined key assignments.
The argument xkey is a real number rc.p specifying the key by its row number, its column number,
and its plane (shift). For a definition of plane, see ASN.
Specifying 0 for xkey clears all user key assignments and restores the standard key assignments.
Specifying S as the argument for DELKEYS suppresses all standard key assignments on the user
keyboard. This makes keys without user key assignments inactive on the user keyboard. (You can
make exceptions using ASN, or restore them all using STOKEYS.) If you are stuck in User mode
— probably with a “locked” keyboard — because you have reassigned or suppressed the keys
necessary to cancel User mode, do a system halt (“warm start”): press and hold ‡ and C
simultaneously, releasing C first. This cancels User mode.
Deleted user key assignments still take up from 2.5 to 62.5 bytes of memory each. You can free
this memory by packing your user key assignments by executing RCLKEYS 0 DELKEYS
STOKEYS.
!&H KEYS DELKEYS
Flags:
!°L MODES KEYS DELKEYS ( °is the left-shift of the Nkey).
User-Mode Lock (–61) and User Mode (–62) affect the status of the user keyboard.
3-54 Full Command and Function Reference


DIAGMAP  1 1 , << → X<<EXP(X) >> >>
 0 2

EXP ( 1 ) – EXP ( 1 ) + EXP ( 2 )
0
EXP ( 2 )
DIFF
Type:
Command
Description:
Displays a menu or list containing the CAS commands for differential calculus, including
commands for working with series.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
ALGB, ARIT, CONSTANTS, EXP&LN, INTEGER, MAIN, MATHS, MATR, MODULAR,
POLYNOMIAL, REWRITE, TESTS, TRIGO
DIFFEQ
Type:
Description:
Command
Differential Equation Plot Type Command: Sets the plot type to DIFFEQ.
When the plot type is DIFFEQ and the reserved variable EQ does not contain a list, the initial
value problem is solved and plotted over an interval using the Runge–Kutta–Fehlberg (4,5)
method. The plotting parameters are specified in the reserved variable PPAR, which has the
following form:
{ (xmin, ymin) (xmax, ymax) indep res axes ptype depend }
For plot type DIFFEQ, the elements of PPAR are used as follows:
• (xmin, ymin) is a complex number specifying the lower left corner of PICT (the lower left
corner of the display range). The default value is (–6.5,–3.1) for the HP 48gII and (–6.5,–3.9)
for the HP 50g and 49g+.
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
• indep is a list, { X x0 xf }, containing a name that specifies the independent variable, and two
numbers that specify the initial and final values for the independent variable. The default values
for these elements are { X 0 xmax }.
• res is a real number specifying the maximum interval, in user-unit coordinates, between values of
the independent variable. The default value is 0. If res does not equal zero, then the maximum
interval is res. If res equals zero, the maximum interval is unlimited.
• axes is a list containing one or more of the following, in the order listed: a complex number
specifying the user-unit coordinates of the plot origin, a list specifying the tick-mark annotation,
and two strings specifying labels for the horizontal and vertical axes. If the solution is realvalued, these strings can specify the dependent or the independent variable; if the solution is
vector valued, the strings can specify a solution component:
– 0 specifies the dependent variable (X)
– 1 specifies the dependent variable (Y)
– n specifies a solution component Yn
Full Command and Function Reference 3-59
See also:
CLEAR, DROPN
DERIV
Result:
See also:
Type:
Function
Description:
Returns the partial derivatives of a function, with respect to the specified variables.
Access:
Calculus, P CALCULUS or !ÖDERIV. & INTEG.
Input:
Level 2/Argument 1: A function or a list of functions.
Level 1/Argument 2: A variable, or a vector of variables. The variable or variables must not exist
as variables stored in the current directory nor directories above it.
Output:
The derivative, or a vector of the derivatives, of the function or functions.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Find the gradient of the following function of the spatial variables x, y, and z:
2
(See the description of dn and Chapter 16 of the User’s Guide for an explanation of the use of
“d1” for a derivative.)
DET
Type:
Description:
2
2x y + 3y z + zx
Command:
DERIV(2*X^2*Y+3*Y^2*Z+Z*X, [X,Y,Z])
EXPAND(ANS(1))
Result:
[4*Y*X+Z,2*X^2+6*Z*Y,X+3*Y^2]
See also:
DERVX, dn, ∂, POTENTIAL
DERVX
Type:
Description:
Function
Access:
Calculus, !Ö or P CALCULUS or !ÖDERIV. & INTEG.
Input:
The function or list of functions to be differentiated.
Returns the derivative of a function with respect to the current variable. This variable must not
exist as a variable stored in the current directory path.
Output:
The derivative, or a vector of the derivatives, of the function or functions.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Access:
Command
Determinant Function: Returns the determinant of a square matrix.
The argument matrix must be square. DET computes the determinant of 1 × 1 and 2 × 2
matrices directly from the defining expression for the determinant. DET computes the
determinant of a larger matrix by computing the Crout LU decomposition of the matrix and
accumulating the product of the decomposition’s diagonal elements.
Since floating-point division is used to do this, the computed determinant of an integer matrix is
often not an integer, even though the actual determinant of an integer matrix must be an integer.
DET corrects this by rounding the computed determinant to an integer value. This technique is
also used for noninteger matrices with determinants having fewer than 15 nonzero digits: the
computed determinant is rounded at the appropriate digit position to restore some or all of the
accuracy lost to floating-point arithmetic.
This refining technique can cause the computed determinant to exhibit discontinuity. To avoid
this, you can disable the refinement by setting flag –54.
!Ø OPERATIONS DET
( Ø is the left-shift of the 5key).
Example:
DERIV, dn, ∂
Command
See also:
Solves certain first-order ordinary differential equations with respect to the current variable.
Access:
Symbolic solve, !Î or calculus, !ÖDIFFERENTIAL EQNS.
Input:
Level 2/Argument 1: A first-order differential equation.
Level 1/Argument 2: The function to solve for.
DETACH
Type:
Description:
Output:
The solution to the equation, either y as a function of x or x as a function of y, or x and y as
functions of a parameter.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Solve the following differential equation:
Level 1/Item 1
→
[[ matrix ]]
xdeterminant
For a square matrix A, the minor of element aij is the determinant of the submatrix that remains
after deleting row i and column j from the original matrix. Given a square matrix in level 3, i in
level 2, and j in level 1, the following program, MINOR determines the minor of the submatrix:
« → M row col
« M row ROW- DROP col COL- DROP DET »
»
For example, entering [[ 1 2 3 ][ 4 5 6 ][ 7 8 9 ]] 2 3 MINOR
returns -6.
CNRM, CROSS, DOT, RNRM
Command
Detach Library Command: Detaches the library with the specified number from the current
directory. Each library has a unique number. If a port number is specified, it is ignored.
A library object attached to a non-HOME directory is automatically detached (without using
DETACH) whenever a new library object is attached there.
Access:
…µDETACH
Input/Output:
Level 1/Argument 1
3x
DESOLVE(d1Y(X)+2*Y(X)=EXP(3*X),Y(X))
See also:
3-56 Full Command and Function Reference
( ´ is the left-shift of the Pkey).
Level 1/Argument 1
See also:
y′ ( x ) + 2 y ( x ) = e
dn, LDEC
!´NORMALIZE DET
Flags:
Tiny Element (–54)
Input/Output:
DESOLVE
Type:
Description:
Command:
{Y(X)=(1/5*EXP(5*X)+cC0)*(1/EXP(X)^2)}
Level 1/Item 1
nlibrary
→
:nport :nlibrary
→
ATTACH, LIBS, PURGE
Full Command and Function Reference 3-57
See the IF, CASE, IFERR, DO, and WHILE keyword entries for more information.
Access:
!°BRANCH IF/CASE/DO/WHILE END ( °is the left-shift of the Nkey).
Input/Output: None
See also:
IF, CASE, DO, ELSE, IFERR, REPEAT, THEN, UNTIL, WHILE
ENDSUB
Type:
Description:
Command
Ending Sublist Command: Provides a way to access the total number of sublists contained in the
list used by DOSUBS.
Returns an Undefined Local Name error if executed when DOSUBS is not active.
Access:
!°LIST PROCEDURES ENDSUB
( °is the left-shift of the Nkey).
Input/Output: None
Example:
The following program subtracts the number of elements in a list from each element in the list
« → a « a 1 « ENDSUB - » » DOSUBS »
See also:
DOSUBS, NSUB
ENG
Type:
Description:
Access:
Command
Engineering Mode Command: Sets the number display format to engineering mode, which
displays one to three digits to the left of the fraction mark (decimal point) and an exponent that is
a multiple of three. The total number of significant digits displayed is n + 1.
Engineering mode uses n + 1 significant digits, where 0 ≤ n ≤ 11. (Values for n outside this range
are rounded up or down.) A number is displayed or printed as follows:
(sign) mantissa E (sign) exponent
where the mantissa is of the form (nn)n.(n…) (with up to 12 digits total) and the exponent has one
to three digits.
A number with an exponent of –499 is displayed automatically in scientific mode.
!&H
FMT ENG
!°L MODES FMT ENG
Level 1/Argument 1
See also:
HEAD
Type:
Description:
Access:
Level 1/Item 1
→
n
The number 103.6 in Engineering mode with five significant digits (n=4) would appear as
103.60E0. This same number with one significant digit (n=0) would appear as 100.E0.
FIX, SCI, STD
EPSX0
( °is the left-shift of the Nkey).
Command
First Listed Element Command: Returns the first element of a list or string.
!°LCHARS LHEAD
!°LIST ELEMEN LHEAD
( °is the left-shift of the Nkey).
( °is the left-shift of the Nkey).
…± LHEAD
(± is the right-shift of the Nkey).
Input/Output:
Level 1/Argument 1
{ obj1, ... ,objn }
Example 1:
Example 2:
See also:
Level 1/Item 1
→
obj1
→
“string”
“element1”
"Dead" HEAD returns "D".
The following program takes a list of coordinates { A B C } that define a right triangle, and finds
the length of the hypotenuse AC:
« DUP HEAD SWAP REVLIST HEAD - ABS »
For example, entering { (0,0) (0,3) (3,4) } returns 5.
TAIL
HEADER→
Type:
Command
Description:
Header size: Returns the current size of the header in lines.
Access:
…µHEADER→
Input/Output:
Level 1/Argument 1
( °is the left-shift of the Nkey).
Input/Output:
Example:
Access:
!°LL RUN & DEBUG HALT
Input/Output: None
See also:
CONT, KILL
Level 1/Item 1
→
See also:
Header size
→HEADER
→HEADER
Type:
Command
Description:
Header size: Sets the current size of the header in lines: to 0, 1, or 2 lines.
Access:
…µ→HEADER
Input/Output:
Level 1/Argument 1
Level 1/Item 1
Type:
Function
Description:
Replaces all coefficients in a polynomial that have an absolute value less than that held in the
CASDIR variable EPS, with 0. The default value of EPS is 1E-10, which can be changed by
storing a new number in the variable EPS in the CASDIR directory; this must be less than 1.
See also:
Access:
Catalog, …µ
Type:
Command
Input:
A polynomial.
Description:
Output:
The polynomial with conforming coefficients replaced with 0.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Similar to CASCMD, displays a list of CAS operations. Selecting one with OK displays help for it,
an example of the operation, and the option to copy the example to the command line. More
details are given in Appendix C and Appendix H of the User’s Guide.
Catalog, …µ, or tools IL
CASCMD
3-74 Full Command and Function Reference
Header size
→
HEADER→
HELP
Access:
See also:
Full Command and Function Reference 3-103
ERR0
Type:
Description:
Input/Output:
Command
Clear Last Error Number Command: Clears the last error number so that a subsequent execution
of ERRN returns # 0h, and clears the last error message.
( °is the left-shift of the Nkey).
Access:
!°LLERROR ERR0
Input/Output: None
See also:
DOERR, ERRM, ERRN
Example:
ERRM
Type:
Description:
See also:
→LCD, LCD→
GROB
Type:
Description:
Access:
Command
Enters GROB on the command line to help with the manual entry of a graphic object.
…µGROB
Access:
Input/Output:
Command
Error Message Command: Returns a string containing the error message of the most recent
calculator error.
ERRM returns the string for an error generated by DOERR. If the argument to DOERR was 0,
the string returned by ERRM is ‘Interrupted’.
!°LL ERROR ERRM
( °is the left-shift of the Nkey).
See also:
ERRN
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
→
“error message”
The program « IFERR + THEN ERRM END » returns "Bad Argument Type" to level 1
if improper arguments (for example, a complex number and a binary integer) are in levels 1 and 2.
DOERR, ERRN, ERR0
Command
Error Number Command: Returns the error number of the most recent calculator error.
If the most recent error was generated by DOERR with a string argument, ERRN returns
#70000h. If the most recent error was generated by DOERR with a binary integer argument,
ERRN returns that binary integer. (If the most recent error was generated by DOERR with a real
number argument, ERRN returns the binary integer conversion of the real number.) The only
exceptions to these rules are 0 DOERR and #0 DOERR, both of which set ERRN to #31Fh and
ERRM to ‘Interrupted’.
( °is the left-shift of the Nkey).
!°LL ERROR ERRN
Level 1/Argument 1
See also:
EULER
Type:
Description:
ncharsize
Level 1/Item 1
→
grob
This program:
« 'Y=3*X^2' 0 →GROB PICT STO { } PVIEW »
returns a graphics object to the stack representing the Equation Writer application picture of
'Y=3*X^2', then stores the graphics object in PICT and shows it in the graphics display with
scrolling activated.
Type:
Description:
Command
Combines two graphic objects by appending the second argument onto the bottom of the first.
Access:
PGRAPH GROBADD
!ÖGRAPH GROBADD
GXOR
Type:
Description:
#nerror
The program « IFERR + THEN ERRN END » returns # 202h to level 1 if improper
arguments (for example, a complex number and a binary integer) are in levels 1 and 2.
DOERR, ERRM, ERR0
Function
!ÞINTEGER
Input:
A non-negative integer, or an expression that evaluates to a non-negative integer.
Output:
The number of positive integers, less than, and co-prime with, the integer.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
3-76 Full Command and Function Reference
Level 2/Argument 1
Level 1/Argument 2
GROB1
GROB2
Example:
Level 1/Item 1
→
GROB3
Command
Graphics Exclusive OR Command: Superimposes grob1 onto grobtarget or PICT, with the upper left
corner pixel of grob1 positioned at the specified coordinate in grobtarget or PICT.
GXOR is used for creating cursors, for example, to make the cursor image appear dark on a light
background and light on a dark background. Executing GXOR again with the same image
restores the original picture.
GXOR uses a logical exclusive OR to determine the state of the pixels (on or off) in the
overlapping portion of the argument graphics objects.
Any portion of grob1 that extends past grobtarget or PICT is truncated.
If the first (level 3) argument (the target graphics object) is any graphics object other than PICT,
then grobresult is returned to the stack. If the first (level 3) argument is PICT, no result is returned to
the stack.
Access:
!°L GROB GXOR
Input/Output:
For a given integer, returns the number of integers less than the integer that are co-prime with the
integer. (Euler’s Φ function.)
Access:
( Ö is the left-shift of the 4key).
Input/Output:
Level 1/Item 1
→
Example:
Level 1/Argument 2
obj
GROBADD
Level 1/Argument 1
Example:
Level 2/Argument 1
( °is the left-shift of the Nkey).
Level 3/Argument 1
Level 2/Argument 2
Level 1/Argument 3
grobtarget
grobtarget
PICT
PICT
{ #n, #m }
(x, y)
{ #n, #m }
(x, y)
grob1
grob1
grob1
grob1
Level 1/Item 1
→
→
→
→
grobresult
grobresult
This program:
« ERASE PICT NEG PICT { # 0d # 0d }
Full Command and Function Reference 3-101
Input/Output: None
See also:
DEG, RAD
Access:
Catalog, …µ
Input:
An equation.
Output:
Level 2/Item 1: The expression to the left of the “=” sign in the original equation, or, if the input
is an expression and not an equation, the independent variable.
Level 1/Item 2: The expression to the right of the “=” sign in the original equation, or, if the
input is an expression, the expression.
Flags:
Access:
Matrices, !Ø LVECTOR
Input:
Level 2/Argument 1: A vector representing a basis of a vector space.
Level 1/Argument 2: A function that defines a scalar product in that space. This can be given as a
program, or as the name of a variable containing the definition of the function.
EXLR(SIN(X)=5*X+Y)
Output:
An orthonormal base of the vector space with respect to the given scalar product.
{SIN(X), 5*X+Y}
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find an orthonormal base for the vector space with base [1, 1+X] with respect to the scalar
product defined by :
Numeric mode must not be set (flag –3 clear).
In Algebraic mode (flag –95 set), the output expressions are evaluated (variables are replaced by
numeric values) before the result is returned.
Example:
Command:
Result:
Split the following equation into its two component expressions: sin(x)=5x+y
See also:
FXND
EXP&LN
Type:
Command
Description:
Displays a menu or list of the CAS exponential and logarithmic operations.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
ALGB, ARIT, CONSTANTS, DIFF, INTEGER, MAIN, MATHS, MATR, MODULAR,
POLYNOMIAL, REWRITE, TESTS, TRIGO
EXP
Type:
Description:
Analytic Function
Exponential Analytic Function: Returns the exponential, or natural antilogarithm, of the
argument; that is, e raised to the given power.
EXP uses extended precision constants and a special algorithm to compute its result to full 12digit precision for all arguments that do not trigger an underflow or overflow error.
EXP provides a more accurate result for the exponential than can be obtained by using e Q.
The difference in accuracy increases as z increases. For example:
z
3
10
EXP(z)
ez
20.0855369232
22026.4657948
20.0855369232
22026.4657949
100
2.68811714182E43
2.68811714191E43
500
1.40359221785E217
1.40359221809E217
1000
1.9707111402E434
1.9707111469E434
For complex arguments: e(x,y) = excosy + iexsiny
Access:
Flags:
GRAMSCHMIDT
Command
Description:
Finds an orthonormal base of a vector space with respect to a given scalar product.
Type:
!¸
Numerical Results (–3)
P⋅Q =
Command:
Result:
GRAPH
Type:
Description:
GRAMSCHMIDT([1,1+X], « → P Q « PREVAL(INTVX(P*Q),-1,1) » »)
1
X
------- -------------2 1--- ⋅ 6
3
Command
Picture Environment Command: Selects the Picture environment
GRAPH is provided for compatibility with the HP 28 series. GRAPH is the same as PICTURE;
see its listing for details.
GREDUCE
Type:
Command
Description:
Reduces a polynomial with respect to a Grœbner basis.
Access:
Catalog, …µ
Input:
Level 3/Argument 1: A vector of polynomials in several variables.
Level 2/Argument 2: A vector of polynomials that is a Grœbner basis in the same variables.
Level 1/Argument 3: A vector giving the names of the variables.
Output:
Level 1/Item 1: A vector containing the input polynomial reduced with respect to the Grœbner
basis, up to a constant; as with GBASIS, fractions in the result are avoided.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Reduce the polynomial:
x2y – xy – 1
with respect to the Grœbner basis (obtained in the example for GBASIS):
x, 2y3 – 1
( ¸is the left-shift of the Qkey).
Command:
3-78 Full Command and Function Reference
1
∫ – 1 P ( x ) ⋅ Q ( x ) dx
GREDUCE(X^2*Y–X*Y–1, [X,2*Y^3–1], [X,Y])
Full Command and Function Reference 3-99
Flags:
Numerical Results (–3), Exact Mode (–105)
Input/Output:
Access:
!°LIST ELEMENTS GET
Input/Output:
Level 1/Argument 1
Example 1:
Example 2:
See also:
EXPAND
Type:
Description:
Access:
Level 1/Item 1
x
→
x
'symb1'
→
'symb2'
nposition
[[ matrix ]]
{ nrow, mcolumn }
→
zget
'namematrix'
nposition
→
zget
'namematrix'
{ nrow, mcolumn }
→
zget
[ vector ]
nposition
→
zget
[ vector ]
{nposition }
→
zget
Command
'namevector'
nposition
→
zget
Expands and simplifies an algebraic expression. This command is similar to the EXPAN
command (which is included to ensure backward-compatibility with the HP 48-series calculators),
except that EXPAND does more a more in-depth analysis and often does a better job at
simplifying an expression than EXPAN.
'namevector'
{nposition }
→
zget
Algebra, …×or PALG
→
(x, y)
'A^(B+C)' EXPAN returns 'A^C*A^B'
'(X+Y)^2' EXPAN returns 'X^2+2*Y*X+Y^2'
COLCT, EXPAND, ISOL, QUAD, SHOW
An expression, or an array of expressions.
The expanded and simplified expression or array of expressions.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Simplify the following expression:
(x, y)
2
( x + 2x + 1 )
------------------------------x+1
{ list }
nposition
→
objget
{ list }
{nposition }
→
objget
'namelist'
nposition
→
objget
GETI
Type:
Description:
Access:
Flags:
'namelist'
{nposition }
objget
[[ 2 3 7 ][ 3 2 9 ][ 2 1 3 ] { 2 3 } GET returns 9.
[[ 2 3 7 ][ 3 2 9 ][ 2 1 3 ] 8 GET returns 1.
{ A B C D E } { 1 } GET returns 'A'.
GETI, PUT, PUTI
Command
Get and Increment Index Command: Returns from the argument 1/level 2 array or list (or named
array or list) the real or complex number zget or object objget whose position is specified in
argument 2/level 1, along with the first (level 2) argument and the next position in that argument.
For matrices, the position is incremented in row order.
!°LIST ELEMENTS GETI
( °is the left-shift of the Nkey).
Index Wrap Indicator (–64)
!ÞMODULO
Input:
An expression, or an array of expressions.
Output:
The expanded and simplified expression, or array of expressions, modulo the current modulus.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Expand the following expression and give the result modulo 3:
Command:
Result:
Example 1:
Example 2:
Example 3:
See also:
X+1
EXPAN
zget
→
EXPAND((X^2+2*X+1)/(X+1))
EXPANDMOD
Type:
Function
Description:
Expands and simplifies an algebraic expression, or an array of expressions, modulo the current
modulus.
Access:
Level 1/Item 1
[[ matrix ]]
Output:
See also:
Level 1/Argument 2
→
Input:
Command:
Result:
Level 2/Argument 1
( °is the left-shift of the Nkey).
( x + 3 )( x + 4 )
EXPANDMOD((X+3)*(X+4))
X^2+X
3-80 Full Command and Function Reference
Full Command and Function Reference 3-97
Access:
Input/Output:
xpoint, ypoint, and zpoint are real numbers that set the x-, y-, and z-coordinates as the eye-point from
which to view a 3D plot’s view volume. The y-coordinate must always be 1 unit less than the view
volume’s nearest point (ynear of YVOL). These coordinates are stored in the reserved variable
VPAR.
…µEYEPT
F0λ
Type:
Description:
Access:
Flags:
Input/Output:
FACT
Type:
Description:
Access:
Flags:
Input/Output:
Level 2/Argument 2
Level 1/Argument 3
xpoint
ypoint
zpoint
NUMX, NUMY, XVOL, XXRNG, YVOL, YYRNG, ZVOL
Level 1/Item 1
→
Function
Black Body Emissive Power Function: Returns the fraction of total black-body emissive power at
temperature xT between wavelengths 0 and ylambda. If units are not specified, ylambda has implied
units of meters and xT has implied units of K.
F0λ returns a dimensionless fraction.
…µ F0λ
Numerical Results (–3)
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
ylambda
xT
→
xpower
ylambda
'symb'
→
'F0λ(ylambda,symb)'
'symb'
xT
→
'F0λ(symb,xT)'
'symb1'
'symb2'
→
'F0λ(symb1,symb2)'
Command
Factorial (Gamma) Function: FACT is the same as ! and is provided for compatibility with the HP
28. See !.
…µFACT
Numerical Results (–3), Underflow Exception (–20), Overflow Exception (–21)
Level 1/Argument 1
See also:
Function
Evaluate the Γ function at the given point. For a positive integer x, Γ(x) is equal to (x +1)!
GAMMA differs from the FACT and ! functions because it allows complex arguments. The Γ
function is defined by
Γ(x ) =
Level 3/Argument 1
See also:
GAMMA
Type:
Description:
Level 1/Item 1
+∞ – t
∫0
e ⋅t
x–1
dt
.
Access:
Input:
Output:
Flags:
!´LSPECIAL
A real or complex number, x.
Γ(x). If the input x is an integer greater than 100, returns the symbolic expression GAMMA(x).
If the Underflow Exception (–20) or Overflow Exception (–21) flags are set then underflow or
overflow conditions give errors, otherwise they give zero or the maximum real number the
calculator can express.
Complex mode must be set (flag –103 set) if x is complex.
See also:
FACT, PSI, Psi, !
GAUSS
Type:
Command
Description:
Returns the diagonal representation of a quadratic form.
Access:
Matrices, !Ø
Input:
Level 2/Argument 1: The quadratic form.
Level 1/Argument 2: A vector containing the independent variables.
Output:
Level 4/Item 1: An array of the coefficients of the diagonal.
Level 3/Item 2: A matrix, P, such that the quadratic form is represented as PTDP, where the
diagonal matrix D contains the coefficients of the diagonal representation.
Level 2/Item 3: The diagonal representation of the quadratic form.
Level 1/Item 4: The vector of the variables.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find the Gaussian symbolic quadratic form of the following:
QUADRATIC FORM
2
x + 2axy
Command:
Result:
See also:
GAUSS(X^2+2*A*X*Y,[X,Y])
{[1,-A^2], [[1,A][0,1]], -(A^2*Y^2)+(A*Y+X)^2,[X,Y]}
AXQ, QXA
n
→
n!
x
→
Γ(x + 1)
Type:
Command
'symb'
→
'(symb)!'
Description:
Returns a set of polynomials that are a Grœbner basis G of the ideal I generated from an input set
of polynomials F.
GBASIS
COMB, PERM, !
Access:
Catalog, …µ
Command
Input:
Factorizes a polynomial or an integer:
• The function expresses a polynomial as the product of irreducible polynomials.
• The function expresses an integer as the product of prime numbers.
Level 2/Argument 1: A vector F of polynomials in several variables.
Level 1/Argument 2: A vector giving the names of the variables.
Output:
Level 1/Item 1: A vector containing the resulting set G of polynomials. The command attempts
to order the polynomials as given in the vector of variable names.
FACTOR
Type:
Description:
Access:
Algebra, …×or PALG or !ÞPOLY
3-82 Full Command and Function Reference
Full Command and Function Reference 3-95
FANNING
Type:
Description:
Access:
Flags:
Input/Output:
See also:
FAST3D
Type:
Description:
Function
Fanning Friction Factor Function: Calculates the Fanning friction factor of certain fluid flows.
FANNING calculates the Fanning friction factor, a correction factor for the frictional effects of
fluid flows having constant temperature, cross-section, velocity, and viscosity (a typical pipe flow,
for example). xx/D is the relative roughness (the ratio of the conduit roughness to its diameter). yRe
is the Reynolds number. The function uses different computation routines for laminar flow (Re ≤
2100) and turbulent flow (Re > 2100). xx/D and yRe must be real numbers or unit objects that
reduce to dimensionless numbers, and both numbers must be greater than 0.
…µFANNING
Numerical Results (–3)
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
xx/D
yRe
→
xfanning
xx/D
'symb'
→
'FANNING(xx/D,symb)'
'symb'
yRe
→
'FANNING(symb,yRe)'
'symb1'
'symb2'
→
'FANNING(symb1,symb2)'
DARCY
Command
Fast 3D Plot Type Command: Sets the plot type to FAST 3D.
When plot type is set to FAST3D, the DRAW command plots an image graph of a 3-vectorvalued function of two variables. FAST3D requires values in the reserved variables EQ, VPAR,
and PPAR.
VPAR is made up of the following elements:
{ xleft,xright, ynear, yfar,zlow,zhigh,xmin,xmax, ymin, ymax,xeye, yeye,zeye,xstep, ystep }
For plot type FAST3D, the elements of VPAR are used as follows:
• xleft and xright are real numbers that specify the width of the view space.
• ynear and yfar are real numbers that specify the depth of the view space.
• zlow and zhigh are real numbers that specify the height of the view space.
• xmin and xmax are not used.
• ymin and ymax are not used.
• xeye, yeye, and zeye are are not used.
• xstep and ystep are real numbers that set the number of x-coordinates versus the number of ycoordinates plotted.
The plotting parameters are specified in the reserved variable PPAR, which has this form:
{ (xmin, ymin),(xmax, ymax),indep,res,axes,ptype,depend }
For plot type FAST3D, the elements of PPAR are used as follows:
• (xmin, ymin) is not used.
• (xmax, ymax) is not used.
• indep is a name specifying the independent variable. The default value of indep is X.
• res is not used.
• axes is not used.
• ptype is a command name specifying the plot type. Executing the command FAST3D places the
name FAST3D in ptype.
• depend is a name specifying the dependent variable. The default value is Y.
3-84 Full Command and Function Reference
!° LMODES FLAG FS?
!& H FLAG FS?
( °is the left-shift of the Nkey).
Input/Output:
Level 1/Argument 1
See also:
FS?C
Type:
Description:
Access:
Level 1/Item 1
→
nflag number
0/1
CF, FC?, FC?C, FS?C, SF
Command
Flag Set? Clear Command: Tests whether the system or user flag specified by nflag number is set, and
returns a corresponding test result: 1 (true) if the flag is set or 0 (false) if the flag is clear. After
testing, clears the flag.
!°TEST LLFS?C
( °is the left-shift of the Nkey).
!° LMODES FLAG FS?C
( °is the left-shift of the Nkey).
!& H FLAG FS?C
Input/Output:
Level 1/Argument 1
nflag number
Example:
See also:
FUNCTION
Type:
Description:
Level 1/Item 1
→
0/1
If flag –44 is set, -44 FS?C returns 1 to level 1 and clears flag –44.
CF, FC?, FC?C, FS?, SF
Command
Function Plot Type Command: Sets the plot type to FUNCTION.
When the plot type is FUNCTION, the DRAW command plots the current equation as a realvalued function of one real variable. The current equation is specified in the reserved variable EQ.
The plotting parameters are specified in the reserved variable PPAR, which has the form:
{ (xmin, ymin) (xmax, ymax) indep res axes ptype depend }
For plot type FUNCTION, the elements of PPAR are used as follows:
• (xmin, ymin) is a complex number specifying the lower left corner of PICT (the lower left corner
of the display range). The default value is (–6.5,–3.1) for the HP 48gII and (–6.5,–3.9) for the
HP 50g and 49g+.
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
• indep is a name specifying the independent variable, or a list containing such a name and two
numbers specifying the minimum and maximum values for the independent variable (the
plotting range). The default value of indep is X.
• res is a real number specifying the interval (in user-unit coordinates) between plotted values of
the independent variable, or a binary integer specifying the interval in pixels. The default value is
0, which specifies an interval of 1 pixel.
• axes is a list containing one or more of the following, in the order listed: a complex number
specifying the user-unit coordinates of the plot origin, a list specifying the tick-mark annotation,
and two strings specifying labels for the horizontal and vertical axes. The default value is (0,0).
• ptype is a command name specifying the plot type. Executing the command FUNCTION places
the name FUNCTION in PPAR.
• depend is a name specifying a label for the vertical axis. The default value is Y.
The current equation is plotted as a function of the variable specified in indep. The minimum and
maximum values of the independent variable (the plotting range) can be specified in indep;
Full Command and Function Reference 3-93
FOURIER
Input/Output:
Level 1/Argument 1
Example:
See also:
FDISTRIB
Type:
Description:
Access:
Level 1/Item 1
→
nflag number
If flag –44 is set, -44 FC?C returns 0 to level 1 and clears flag –44.
CF, FC?, FS? FS?C, SF
0/1
Description:
Returns the nth coefficient of a complex Fourier series expansion. The PERIOD variable must be in
the CAS directory, CASDIR, or in current path, and set to hold L, the period of the input
function. The expression is expanded in terms of the current CAS variable.
Calculus !ÖDERIV. & INTEG.
Input:
Performs a full distribution of multiplication and division with respect to addition and subtraction
in a single step.
Level 1/Argument 2: An expression in terms of the current variable
Level 2/Argument 1: The number, n, of the coefficient to return.
Output:
The nth Fourier coefficient of the expression.
!Ú
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Complex mode must be set, that is, flag –103 must be set.
Command
REWRITE
An expression.
Output:
An equivalent expression that results from fully applying the distributive property of
multiplication and division over addition and subtraction.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Command:
Result:
Expand (X+1)(X-1)(X+2):
FDISTRIB((X+1)*(X-1)*(X+2))
X*(X*X)+2*(X*X)+(-(X*(1*X))+-(2*(1*X)))+ (X*(X*1)+2*(X*1)+
(-(X*(1*1))+-(2*(1*1))))
FFT
Type:
Description:
Function
Access:
Input:
See also:
Type:
DISTRIB
Command
Discrete Fourier Transform Command: Computes the one- or two-dimensional discrete Fourier
transform of an array.
If the argument is an N-vector or an N × 1 or 1 × N matrix, FFT computes the one-dimensional
transform. If the argument is an M × N matrix, FFT computes the two-dimensional transform. M
and N must be integral powers of 2.
The one-dimensional discrete Fourier transform of an N-vector X is the N-vector Y where:
–1
Yk =
∑
n=0
Xn
2πi kn
– --------------e ,
i =
–1
for k = 0, 1, …, N – 1.
The two dimensional discrete Fourier transform of an M × N matrix X is the M × N matrix Y
where:
M–1 –1
Y kl =
∑
∑
m=0 n=0
xm ne
2 πik m 2πi ln
– ---------------- – -----------------
M e
,
i =
–1
for k = 0, 1, …, M – 1 and l = 0, 1, …, N – 1.
The discrete Fourier transform and its inverse are defined for any positive sequence length.
However, the calculation can be performed very rapidly when the sequence length is a power of
two, and the resulting algorithms are called the fast Fourier transform (FFT) and inverse fast
Fourier transform (IFFT).
The FFT command uses truncated 15-digit arithmetic and intermediate storage, then rounds the
result to 12-digit precision.
3-86 Full Command and Function Reference
Example:
Obtain the Fourier coefficient as below, with the default value of 2π in the PERIOD variable in
CASDIR, and simplify it with EXPAND:
Command:
FOURIER(X^2,0)
EXPAND(ANS(1))
Result:
4/3* π^2
FP
Type:
Description:
Access:
Flags:
Input/Output:
Function
Fractional Part Function: Returns the fractional part of the argument.
The result has the same sign as the argument.
!´REAL LFP
( ´ is the left-shift of the Pkey).
Numerical Results (–3)
Level 1/Argument 1
x
x_unit
'symb'
Level 1/Item 1
→
→
→
y
y_unit
'FP(symb)'
Example 1:
Example 2:
See also:
-32.3 FP returns -.3.
32.3_m FP returns .3_m.
IP
FREE
Type:
Description:
Access:
Command
Do not use this command, a carry-over from the HP 48SX for handling plug-in RAM cards.
…µ FREE
FREEZE
Type:
Description:
Command
Freeze Display Command: Freezes the part of the display specified by ndisplay area, so that it is not
updated until a key is pressed.
Normally, the stack display is updated as soon as the calculator is ready for data input. For
example, when HALT stops a running program, or when a program ends, any displayed messages
are cleared. The FREEZE command “freezes” a part or all of the display so that it is not updated
until a key is pressed. This allows, for example, a prompting message to persist after a program
halts to await data input.
ndisplay area is the sum of the value codes for the areas to be frozen:
Full Command and Function Reference 3-91
Access:
Fix mode shows n digits to the right of the fraction mark (decimal point), where 0 ≤ n ≤ 11.
(Values for n outside this range are rounded to the nearest integer.) A number is displayed or
printed as (sign) mantissa, where the mantissa can be of any form. However, the calculator
automatically displays a number in scientific mode if either of the following is true:
• The number of digits to be displayed exceeds 12.
• A nonzero value rounded to n decimal places otherwise would be displayed as zero.
! & HFMT FIX
!°LMODES FMT FIX
( °is the left-shift of the Nkey).
Input/Output:
Level 1/Argument 1
Example:
See also:
#nfunction is of the form ffffbbbh, where bbb is the bank ID, and ffff is the function number.
…µFLASHEVAL
Level 1/Argument 1
FLOOR
Type:
Description:
Access:
Flags:
Input/Output:
#nfunction
EVAL, LIBEVAL, SYSEVAL
Level 1/Item 1
→
Function
Floor Function: Returns the greatest integer that is less than or equal to the argument.
!´REAL LL FLOOR
( ´ is the left-shift of the Pkey).
Numerical Results (–3)
Level 1/Argument 1
Example 1:
Example 2:
See also:
FONT6
Type:
Description:
Level 1/Item 1
x
→
n
x_unit
→
n_unit
'symb'
→
'FLOOR(symb)'
3.2 FLOOR returns 3.
-3.2 FLOOR returns –4.
CEIL, IP, RND, TRNC
Function
Font Function: Returns the system FONT6 object. You use this in conjunction with the
→FONT command to set the system font to type 6.
3-88 Full Command and Function Reference
Level 1/Item 1
→
See also:
FONT7
Type:
Description:
Access:
Input/Output:
Function
Font Function: Returns the system FONT7 object. You use this in conjunction with the
→FONT command to set the system font to type 7.
…µFONT7
Level 1/Item 1
→
FONT8
Type:
Description:
Access:
Input/Output:
Function
Font Function: Returns the system FONT8 object. You use this in conjunction with the
→FONT command to set the system font to type 8.
…µ FONT8
Level 1/Item 1
→
FONT→
Type:
Description:
Access:
Input/Output:
Function
Returns the current system font.
…µ FONT→
Level 1/Item 1
→
→FONT
Type:
Description:
Font object
FONT6, FONT7, →FONT, FONT→
Level 1/Argument 1
See also:
Font object
FONT6, FONT8, →FONT, FONT→
Level 1/Argument 1
See also:
Font object
FONT7, FONT8, →FONT, FONT→
Level 1/Argument 1
See also:
WARNING: Use extreme care when executing this function. Using
FLASHEVAL with random addresses will almost always cause a memory loss.
Do not use this function unless you know what you are doing.
See also:
Level 1/Argument 1
Level 1/Item 1
→
n
The number 103.6 in Fix mode to four decimal places would appear as 103.6000.
SCI, STD
FLASHEVAL
Type:
Command
Description:
Evaluate Flash Function Command: Evaluates unnamed Flash functions.
Access:
Input/Output:
Access:
…µ FONT6
Input/Output:
Font object
FONT6, FONT7, FONT8, →FONT
Function
Set font Function: Sets the system font. You use this in conjunction with one of the three font
commands to set the system font. Valid input is any font object (TYPE 30) of size 6, 7, or 8.
Access:
…µ →FONT
Input/Output:
Level 1/Argument 1
See also:
Font object
FONT6, FONT7, FONT8, FONT→
Level 1/Item 1
→
Full Command and Function Reference 3-89
• depend is a name specifying a label for the vertical axis. The default value is Y.
The frequency of the data is plotted as bars, where each bar represents a collection of data points.
The base of each bar spans the values of the data points, and the height indicates the number of
data points. The width of each bar is specified by res. The overall maximum and minimum values
for the data can be specified by indep; otherwise, the values in (xmin, ymin) and (xmax, ymax) are used.
For x = 0 or (0, 0), an Infinite Result exception occurs, or, if flag –22 is set, –MAXR is returned.
The inverse of EXP is a relation, not a function, since EXP sends more than one argument to the
same result. The inverse relation for EXP is the general solution:
LN(Z)+2*π*i*n1
The function LN is the inverse of a part of EXP, a part defined by restricting the domain of EXP
such that: each argument is sent to a distinct result, and each possible result is achieved.
The points in this restricted domain of EXP are called the principal values of the inverse relation.
LN in its entirety is called the principal branch of the inverse relation, and the points sent by LN to
the boundary of the restricted domain of EXP form the branch cuts of LN.
The principal branch used by the calculator for LN was chosen because it is analytic in the regions
where the arguments of the real-valued inverse function are defined. The branch cut for the
complex-valued natural log function occurs where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graphs below show the domain and range of LN. The graph of the domain shows where the
branch cut occurs: the heavy solid line marks one side of the cut, while the feathered lines mark
the other side of the cut. The graph of the range shows where each side of the cut is mapped
under the function.
These graphs show the inverse relation LN(Z)+2*π*i*n1 for the case n1=0. For other values of
n1, the horizontal band in the lower graph is translated up (for n1 positive) or down (for n1
negative). Taken together, the bands cover the whole complex plane, which is the domain of
EXP.
Access:
…µ HISTOGRAM
Input/Output: None
See also:
BAR, CONIC, DIFFEQ, FUNCTION, GRIDMAP, PARAMETRIC, PARSURFACE,
PCONTOUR, POLAR, SCATTER, SLOPEFIELD, TRUTH, WIREFRAME, YSLICE
HISTPLOT
Type:
Description:
Command
Draw Histogram Plot Command: Plots a frequency histogram of the specified column in the
current statistics matrix (reserved variable ΣDAT).
The data column to be plotted is specified by XCOL and is stored as the first parameter in the
reserved variable ΣPAR. If no data column is specified, column 1 is selected by default. The y-axis
is autoscaled and the plot type is set to HISTOGRAM.
HISTPLOT plots relative frequencies, using 13 bins as the default number of partitions. The RES
command lets you specify a different number of bins by specifying the bin width. To plot a
frequency histogram with numerical frequencies, store the frequencies in ΣDAT and execute BINS
and then BARPLOT.
When HISTPLOT is executed from a program, the graphics display, which shows the resultant
plot, does not persist unless PICTURE, PVIEW (with an empty list argument), or FREEZE is
subsequently executed.
Access:
…µ HISTPLOT
Input/Output: None
See also:
BARPLOT, BINS, FREEZE, PICTURE, PVIEW, RES, SCATRPLOT, XCOL
HMS–
Type:
Description:
Access:
Command
Hours-Minutes-Seconds Minus Command: Returns the difference of two real numbers, where the
arguments and the result are interpreted in hours-minutes-seconds format.
The format for HMS (a time or an angle) is H.MMSSs, where:
• H is zero or more digits representing the integer part of the number (hours or degrees).
• MM are two digits representing the number of minutes.
• SS are two digits representing the number of seconds.
• s is zero or more digits (as many as allowed by the current display mode) representing the
decimal fractional part of seconds.
…ÓTools LHMS–
( Ó is the right-shift of the 9 key).
…& 9LHMS–
Input/Output:
Level 2/Argument 1
See also:
HMS+
Type:
Description:
Level 1/Argument 2
HMS1
HMS→, →HMS, HMS+
HMS2
Level 1/Item 1
→
HMS1 – HMS2
Command
Hours-Minutes-Seconds Plus Command: Returns the sum of two real numbers, where the
arguments and the result are interpreted in hours-minutes-seconds format.
3-106 Full Command and Function Reference
Access:
Flags:
You can view these graphs with domain and range reversed to see how the domain of EXP is
restricted to make an inverse function possible. Consider the vertical band in the lower graph as the
restricted domain Z = (x,y). EXP sends this domain onto the whole complex plane in the range
W = (u,v) = EXP(x,y) in the upper graph.
…¹
(¹is the right-shift of the Qkey).
Principal Solution (–1), Numerical Results (–3), Infinite Result Exception (–22)
Full Command and Function Reference 3-135
HOME
Type:
Description:
Access:
Command
HOME Directory Command: Makes the HOME directory the current directory.
…µ HOME
!& J
Input/Output: None
See also:
CRDIR, PATH, PGDIR, UPDIR
Input/Output: None
See also:
BESTFIT, EXPFIT, LOGFIT, LR, PWRFIT
LININ
Type:
Description:
HORNER
Access:
Input/Output:
Function
Linear Test Function: Tests whether an algebraic is structurally linear for a given variable.
If any two subexpressions containing a variable (name) are combined only with addition and
subtraction, and any subexpression containing the variable is at most multiplied or divided by
another factor not containing the variable, the algebraic (symb) is determined to be linear for that
variable. LININ returns a 1 if the algebraic is linear for the variable, and a 0 if not.
!°TEST !«LININ
( °is the left-shift of the Nkey).
Type:
Command
Description:
Executes a Horner scheme on a polynomial. That is, for a given polynomial P, and a number r,
HORNER returns QUOT(P/(x–r)), r and also P(r)
Access:
Arithmetic, !ÞPOLY L
Input:
Level 2/Argument 1: A polynomial, P.
Level 1/Argument 2: A number, r.
Output:
Level 3/Item 1: QUOT(P/(x–r))
Level 2/Item 2: r
Level 1/Item 3: P(r), the remainder of the division process.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Type:
Command
Description:
Solves a system of linear equations.
For r = 3, find the result of executing a Horner scheme on the following polynomial:
Access:
Symbolic solve, !Î, PSOLVE, !Ø
Input:
Level 2/Argument 1: An array of equations.
Level1/Argument 2: A vector of the variables to solve for.
Output:
Level 3/Item 1: The system of equations, as a list containing the inputs as above.
Level 2/Item 2: A list of the pivot points.
Level 1/Item 3: The solution.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
See also:
DESOLVE, SOLVE, MSLV
Example:
Example 1:
Example 2:
2
i
Type:
Description:
Access:
Flags:
Input/Output:
HORNER(X^2+X+1,3)
(X+4,3,13)
Function
i Function: Returns the symbolic constant i or its numerical representation, (0, 1).
!¥
(¥is the left-shift of the Ikey).
Symbolic Constants (–2), Numerical Results (–3)
Level 1/Argument 1
See also:
Level 1/Argument 2
Level 1/Item 1
→
'symb'
'name'
0/1
'(X+1)*(Y^-2^Z)+(X/(3-Z^3)' 'X' LININ returns 1.
'(X^2-1)/(X+1)' 'X' LININ returns 0.
(Although this equation yields a linear equation when factored, LININ tests the equation as
described above.)
LINSOLVE
x +x+1
Command:
Results:
Level 2/Argument 1
Level 1/Item 1
→
'i'
→
(0,1)
e, MAXR, MINR, π
LIST→
Type:
Description:
Access:
Input/Output:
IABCUV
LIN-S
Command
List to Stack Command: Takes a list of n objects and returns each object to a separate level, and
returns the total number of objects to item n+1 (stack level 1).
The command OBJ→ also provides this function.
…µ LIST→
Level 1/Argument 1
Leveln+1/Item1 ...
Level2/Itemn
Level1/Itemn+1
objn
n
Type:
Command
Description:
Returns a solution in integers u and v of au + bv = c, where a, b, and c are integers.
See also:
→
{ obj1, ...,objn }
obj1 ...
ARRY→, DTAG, EQ→, →LIST, OBJ→, STR→
Access:
Arithmetic, !ÞINTEGER
Input:
Level 3/Argument 1: the value of a.
Level 2/Argument 2: the value of b.
Level 1/Argument 3: the value of c.
→LIST
Type:
Description:
Access:
Command
Stack to List Command: Takes n specified objects and returns a list of those objects.
!°TYPE →LIST
( °is the left-shift of the Nkey).
!°LIST →LIST
3-108 Full Command and Function Reference
( °is the left-shift of the Nkey).
Full Command and Function Reference 3-133
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Use integration by parts to calculate the following:
∫ x cos ( x ) dx
Command 1: Apply the IBP command in RPN mode:
Level 2: X*COS(X)
Level 1: SIN(X)
Result:
Level 2: SIN(X)*X
Level 1: -SIN(X)
Command 2: Apply the INTVX command to level 1, -SIN(X)
Result:
Level 2: SIN(X)*X
Level 1: COS(X)
Access:
…µ LIBS
Input/Output:
Level 1/Argument 1
See also:
ATTACH, DETACH
lim
Type:
Description:
Function
Calculus, !Ö LIMITS&SERIES
Input:
Level 2/Argument 1: An expression.
Level 1/Argument 2: An expression of the form x = y, where x is the variable and y is the value at
which the limit is to be evaluated. If the variable approaching a value is the current CAS variable,
it is sufficient to give its value alone. The ∞ symbol provided by the calculator can be used to set
the limiting value at plus or minus infinity.
INTVX, INT, PREVAL, RISCH
ICHINREM
Type:
Description:
Solves a system of two congruences in integers using the Chinese Remainder theorem.
Access:
Arithmetic, !ÞINTEGER
Input:
Level 2/Argument 1: A vector of the first value and the modulus.
Level 1/Argument 2: A vector of the second value and the modulus.
Output:
A vector of the solution.
Flags:
Example:
Command:
Results:
See also:
IDN
Type:
Description:
Command
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Solve the following system of congruences:
x ≡ 2 Modulo 3
x ≡ 1 Modulo 5
Output:
The limit of the expression at the limit point.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find the following limit:
n
n
–y
 lim  x-------------- x → y x – y -
Command:
Result:
See also:
CHINREM
Command
Identity Matrix Command: Returns an identity matrix; that is, a square matrix with its diagonal
elements equal to 1 and its off-diagonal elements equal to 0.
The result is either a new square matrix, or an existing square matrix with its elements replaced by
the elements of the identity matrix, according to the argument.
• Creating a new matrix: If the argument is a real number n, a new real identity matrix is returned,
with its number of rows and number of columns equal to n.
• Replacing the elements of an existing matrix: If the argument is a square matrix, an identity
matrix of the same dimensions is returned. If the original matrix is complex, the resulting
identity matrix will also be complex, with diagonal values (1,0).
3-110 Full Command and Function Reference
lim((X^N-Y^N)/(X-Y), X=Y)
N*EXP(N*LN(Y))/Y
SERIES
LIMIT
Type:
Function
Description:
Returns the limit of a function as its argument approaches a specified value. This function is
identical to the lim function, described above, and is included to ensure backward-compatibility
with the HP 49G calculator.
Access:
Catalog, …µ
LIN
Type:
Description:
Command
Access:
…× or Exponential and logarithm, !Ð or PALG, or !Ú
PLEXPLN.
ICHINREM([2,3],[1,5])
[-4, 15]
{“title”, nlib, nport, ...,“title”, nlib, nport }
Returns the limit of a function as its argument approaches a specified value. Expands and
simplifies an algebraic expression.
Access:
Command 3: Press + to add the result to the value at level 2 to obtain the final result.
SIN(X)*(X)+COS(X)
Result:
See also:
Level 1/Item 1
→
Linearizes expressions involving exponential terms.
Input:
An expression.
Output:
The linearized expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
REWRITE, or
Full Command and Function Reference 3-131
See also:
IF
Type:
Description:
ABCUV, EGCD, IABCUV
Command Operation
IF Conditional Structure Command: Starts IF … THEN … END and IF … THEN … ELSE …
END conditional structures.
Conditional structures, used in combination with program tests, enable a program to make decisions.
• IF … THEN … END executes a sequence of commands only if a test returns a nonzero (true)
result. The syntax is:
IF test-clause THEN true-clause END
IF begins the test clause, which must return a test result to the stack. THEN removes the test
result from the stack. If the value is nonzero, the true clause is executed. Otherwise, program
execution resumes following END.
• IF … THEN … ELSE … END executes one sequence of commands if a test returns a true
(nonzero) result, or another sequence of commands if that test returns a false (zero) result. The
syntax is:
IF test-clause THEN true-clause ELSE false-clause END
IF begins the test clause, which must return a test result to the stack. THEN removes the test
result from the stack. If the value is nonzero, the true clause is executed. Otherwise, the false
clause is executed. After the appropriate clause is executed, execution resumes following END.
In RPL mode, the test clause can be a command sequence (for example, A B ‰) or an algebraic
(for example, 'A‰B'). If the test clause is an algebraic, it is automatically evaluated to a number
(→NUM or EVAL isn’t necessary).
Access:
!°BRANCH IF
Input/Output:
( °is the left-shift of the Nkey).
Level 1/Argument 1
Level 1/Item 1
→
IF
THEN
T/F
See also:
IFERR
Type:
Description:
END
CASE, ELSE, END, IFERR, THEN
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find the least common multiple of the following two expressions:
2
x –1
x–1
Command:
Results:
See also:
T/F
→
→
→
Command
If Error Conditional Structure Command: Starts IFERR … THEN … END and IFERR …
THEN … ELSE … END error trapping structures.
Error trapping structures enable program execution to continue after a “trapped” error occurs.
• IFERR … THEN … END executes a sequence of commands if an error occurs. The syntax of
IFERR … THEN … END is:
3-112 Full Command and Function Reference
X^2-1
GCD
LCXM
Command
Description:
From a program with two arguments, builds a matrix with the specified number of rows and
columns, with aij = f(i,j).
Access:
Catalog, …µ
Input:
Level 3/Argument 1: The number of rows you want in the resulting matrix.
Level 2/Argument 2: The number of columns you want in the resulting matrix.
Level 1/Argument 3: A program that uses two arguments. An expression with the two variables I,
J can be used instead.
Output:
The resulting matrix.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Command:
Build a 2 × 3 matrix with aij=i+2j.
LDEC
Type:
Description:
LCXM(2,3,« →I J 'I+2*J'»)
3 5 7
4 6 8
Command
Solves a linear differential equation with constant coefficients, or a system of first order linear
differential equations with constant coefficients.
Access:
Symbolic solve, !Îor PSOLVER or !ÖDIFF
Input:
Level 2/Argument 1: For a single equation, the function forming the right hand side of the
equation. For a system of equations, an array comprising the terms not containing the dependent
variables.
Level 1/Argument 2: For one equation, the auxiliary polynomial. For a system of equations, the
matrix of coefficients of the dependent variables.
Output:
The solution.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
IFERR trap-clause THEN error-clause END
If an error occurs during execution of the trap clause:
1 The error is ignored.
2 The remainder of the trap clause is discarded.
LCM(X^2-1,X-1)
Type:
Result:
IF
ELSE
The least common multiple of the objects.
Flags:
→
END
THEN
Output:
Example:
Command:
Solve 2sin(x), with the auxiliary polynomial x2+1:
LDEC(2*SIN(X),X^2+1)
Full Command and Function Reference 3-129
Access:
!´LFFT IFFT
Input/Output:
( ´ is the left-shift of the Pkey).
Level 1/Argument 1
Level 1/Item 1
→
[ array ]1
See also:
IFT
Type:
Description:
Command
IF-THEN Command: Executes obj if T/F is nonzero. Discards obj if T/F is zero.
IFT lets you execute in stack syntax the decision-making process of the IF … THEN … END
conditional structure. The “true clause” is obj in argument 2 (level 1).
Access:
!°BRANCH IFT
Input/Output:
Level 2/Argument 1
Example:
See also:
IFTE
Type:
Description:
Access:
Input/Output:
Example 2:
See also:
( °is the left-shift of the Nkey).
Level 1/Argument 2
Level 1/Item 1
→
T/F
obj
It depends!
« X 0 > "Positive" IFT » puts "Positive" in level 1 if X contains a positive
real number.
IFTE
Function
IF-THEN-ELSE Function: Executes the obj in argument 2 or level 2 if T/F is nonzero. Executes
the obj in argument 3 or level 1 if T/F is zero.
IFTE lets you execute in stack syntax the decision-making process of the IF … THEN … ELSE
… END conditional structure. The “true clause” is objtrue in argument 2 or level 2. The “false
clause” is objfalse in argument 3 or level 1.
IFTE is also allowed in algebraic expressions, with the following syntax:
IFTE(test,true-clause,false-clause)
When an algebraic containing IFTE is evaluated, its first argument test is evaluated to a test result.
If it returns a nonzero real number, true-clause is evaluated. If it returns zero, false-clause is evaluated.
!°BRANCH LIFTE
( °is the left-shift of the Nkey).
Level 3/Argument 1
Example 1:
[ array ]2
FFT
Level 2/Argument 2
Level 1/Argument 3
Level 1/Item 1
→
T/F
objtrue
objfalse
It depends!
The command sequence X 0 Š "Positive" "Negative" IFTE leaves
"Positive" on the stack if X contains a non-negative real number, or "Negative" if
X contains a negative real number.
The algebraic 'IFTE(X‹0,SIN(X)/X,1)' returns the value of sin(x)/x, even for x = 0,
which would normally cause an Infinite Result error.
IFT
LAP
Type:
Function
Description:
Performs a Laplace transform on an expression with respect to the current default variable.
Access:
Calculus, !Ö DIFFERENTIAL EQNS
Input:
An expression.
Output:
The Laplace transform of the expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
Find the Laplace transform of ex.
See also:
ILAP, LAPL
ILAP
Function
Description:
Returns the inverse Laplace transform of an expression. The expression must evaluate to a
rational fraction.
3-114 Full Command and Function Reference
1/(X-1)
LAPL
Type:
Command
Description:
Returns the Laplacian of a function with respect to a list of variables.
Access:
!Ö DERIV & INTEG L
Input:
Level 2/Argument 1:An expression.
Level 1/Argument 2: A vector of variables.
Output:
The Laplacian of the expression with respect to the variables.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Find, and simplify, the Laplacian of the following expression:
x
e cos ( zy )
Command:
Result:
See also:
LAST
Type:
Description:
Access:
Flags:
Input/Output:
LAPL(EXP(X)*COS(Z*Y),[X,Y,Z])
EXPAND(ANS(1))
-((Y^2+Z^2-1)*EXP(X)*COS(Z*Y))
LAP, ILAP
Command
Returns copies of the arguments of the most recently executed command.
LAST is provided for compatibility with the HP 28S. LAST is the same as LASTARG.
None. Must be typed in.
Last Arguments (–55)
Level 1
→
See also:
Type:
LAP(EXP(X))
Level n
7
Level 1
objn
…
obj1
ANS, LASTARG
Full Command and Function Reference 3-127
INCR
Type:
Description:
Access:
Input/Output:
Command
Increment Command: Takes a variable, adds 1, stores the new value back into the original
variable, and returns the new value.
The value in name must be a real number or an integer.
!°MEMORY ARITHMETIC INCR ( °is the left-shift of the Nkey).
Level 1/Argument 1
Example:
See also:
INDEP
Type:
Description:
KEYTIME→
Type:
Description:
Access:
Input/Output:
Level 1/Argument 1
Level 1/Item 1
→
'name'
If 35.7 is stored in A, 'A' INCR returns 36.7.
DECR
xincrement
KGET
Type:
Description:
Access:
Flags:
Input/Output:
→
{ global }
→
{ global xstart xend }
→
{xstart xend }
→
xend
→
xstart
See also:
INFORM
Type:
Description:
Level 1/Item 1
'global'
DEPND
Command
User-Defined Dialog Box Command: Creates a user-defined input form (dialog box).
INFORM creates a standard dialog box based upon the following specifications:
Variable
“title”
Function
Title. This appears at the top of the dialog box.
3-116 Full Command and Function Reference
See also:
time
→KEYTIME
Command
Kermit Get Command: Used by a local Kermit to get a Kermit server to transmit the named
object(s).
To rename an object when the local device gets it, include the old and new names in an embedded
list. For example, {{ AAA BBB }} KGET gets the variable named AAA but changes its name to
BBB. {{ AAA BBB } CCC } KGET gets AAA as BBB and gets CCC under its own name. (If the
original name is not legal on the calculator, enter it as a string.)
…µ KGET
I/O Device (–33), RECV Overwrite (–36), I/O Messages (–39), I/O Device for Wire (–78)
Level 1/Argument 1
Access:
…µ INDEP
Input/Output:
Level 1/Argument 2
Level 1/Item 1
→
See also:
Command
Independent Variable Command: Specifies the independent variable and its plotting range.
The specification for the independent variable name and its plotting range is stored as the third
parameter in the reserved variable PPAR. If the argument to INDEP is a:
• Global variable name, that name replaces the independent variable entry in PPAR.
• List containing a global name, that name replaces the independent variable name but leaves
unchanged any existing plotting range.
• List containing a global name and two real numbers, that list replaces the independent variable
entry.
• List containing two real numbers, or two real numbers from levels 1 and 2, those two numbers
specify a new plotting range, leaving the independent variable name unchanged. (LASTARG
returns a list, even if the two numbers were entered separately.)
The default entry is X.
Level 2/Argument 1
Command
Displays the current keytime value.
Keytime is the time after a keypress during which further keypresses will not be actioned. It is
measured in ticks. If you experience key bounce, you can increase the value of keytime.
…µ KEYTIME→
Level 1/Item 1
→
'name'
→
“name”
→
{ nameold namenew }
→
{ name1 ... namen }
→
{{ nameold namenew } name ... }
BAUD, CKSM, FINISH, PARITY, RECN, RECV, SEND, SERVER, TRANSIO
KILL
Type:
Description:
Command
Cancel Halted Programs Command: Cancels all currently halted programs. If KILL is executed
within a program, that program is also canceled.
Canceled programs cannot be resumed.
KILL cancels only halted programs and the program from which KILL was executed, if any.
Commands that halt programs are HALT and PROMPT.
Suspended programs cannot be canceled. Commands that suspend programs are INPUT and
WAIT.
Access:
!°LL RUN & DEBUG KILL
( °is the left-shift of the Nkey).
Input/Output: None
See also:
CONT, DOERR, HALT, PROMPT
LABEL
Type:
Description:
Command
Label Axes Command: Labels axes in PICT with x- and y-axis variable names and with the
minimum and maximum values of the display ranges.
The horizontal axis name is chosen in the following priority order:
1. If the axes parameter in the reserved variable PPAR is a list, then the x-axis element from that
list is used.
Full Command and Function Reference 3-125
Access:
Input/Output:
See also:
In its general form, the second argument (level 1) for INPUT is a list that specifies the content
and interpretation of the command line. The list can contain one or more of the following
parameters, in any order:
• "command-line prompt", whose contents are placed on the command line for prompting when the
program pauses.
• Either a real number, or a list containing two real numbers, that specifies the initial cursor position on
the command line:
– A real number n at the nth character from the left end of the first row (line) of the command
line. A positive n specifies the insert cursor; a negative n specifies the replace cursor. 0 specifies
the end of the command-line string.
– A list that specifies the initial row and column position of the cursor: the first number in the
list specifies a row in the command line (1 specifies the first row of the command line); the
second number counts by characters from the left end of the specified line. 0 specifies the end
of the command-line string in the specified row. A positive row number specifies the insert
cursor; a negative row number specifies the replace cursor.
• One or more of the parameters ALG, α, or V, entered as unquoted names:
– ALG activates Algebraic/Program-entry mode.
– α specifies alpha lock.
– V verifies if the characters in the result string "result", without the " delimiters, compose a
valid object or objects. If the result-string characters do not compose a valid object or objects,
INPUT displays the Invalid Syntax warning and prompts again for data.
You can choose to specify as few as one of the argument 2 (level 1) list parameters. The default
states for these parameters are:
• Blank command line.
• Insert cursor placed at the end of the command-line prompt string.
• Program-entry mode.
• Result string not checked for invalid syntax.
If you specify only a command-line prompt string for the second argument (level 1), you don’t
need to put it in a list.
!°LIN INPUT
( °is the left-shift of the Nkey).
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
“stack prompt”
“command-line prompt”
→
“result”
“stack prompt”
{ listcommand-line }
→
“result”
vector or a list of Jordan chains, each of them ending with an "Eigen:"-tagged eigenvector).
Level 1/Item 4: An array of the eigenvalues, with multiplicities
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
Perform the following diagonalization:
INT
Function
Description:
Calculates the antiderivative of a function for a given variable, at a given point.
Access:
Catalog, …µ
Input:
Level 3/Argument 1: A function.
Level 2/Argument 2: The variable to obtain the derivative with respect to.
Level 1/Argument 3: The point at which to calculate the antiderivative. This point can be a
variable or an expression.
Output:
The antiderivative of the function for the given variable, at the point you specified.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
3-118 Full Command and Function Reference
{X^2-2*X,
X^2-2*X,
{0: [1,-1]}, 2: [1,1]}
[0,2]}
KER
Type:
Command
Description:
Computes the basis of the kernel of a linear application f.
Access:
Matrices, !Ø
Input:
A matrix representing a linear application f in terms of the standard basis.
Output:
A list of vectors representing a basis of the kernel (also called the nullspace) of f.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Find the kernel of
LINEAR APPL
112
213
314
Example:
Command:
Result:
KER([1,1,2][2,1,3][3,1,4])
See also:
BASIS, IMAGE
KERRM
Type:
Description:
PROMPT, STR→
Type:
JORDAN([1,1][1,1])
Access:
Input/Output:
{[1,1,-1]}
Command
Kermit Error Message Command: Returns the text of the most recent Kermit error packet.
If a Kermit transfer fails due to an error packet sent from the connected Kermit device to the
calculator, then executing KERRM retrieves and displays the error message. (Kermit errors not in
packets are retrieved by ERRM rather than KERRM.)
…µ KERRM
Level 1/Argument 1
Level 1/Item 1
→
See also:
KEY
Type:
Description:
“error message”
FINISH, KGET, PKT, RECN, RECV, SEND, SERVER
Command
Key Command: Returns a test result and, if a key is pressed, returns the row-column location xn m
of that key.
KEY returns a false result (0) to item 2 (stack level 1) until a key is pressed. When a key is pressed,
it returns a true result (1) to item 2 (stack level 1) and xn m to item 1 (stack level 2). The result xn m
is a two- or three-digit number that identifies the row and column location of the key just pressed.
Full Command and Function Reference 3-123
Input/Output:
Level 1/Argument 1
See also:
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
See also:
QUOT, IDIV2
Level 1/Item 1
z
→
1/z
[[ matrix ]]
→
[[ matrix ]]–1
'symb'
→
'INV(symb)'
x_unit
→
1/x_1/unit
SINV, /
IREMAINDER
Type:
Function
Description:
Returns the remainder of an integer division.
Access:
PARITH or Arithmetic, !ÞINTEGER L
Input:
Level 2/Argument 1: The numerator.
Level 1/Argument 2: The denominator.
INVMOD
Type:
Description:
Function
Performs modular inversion on an object modulo the current modulus.
Output:
The remainder.
Access:
Arithmetic, !ÞMODULO L
Flags:
Input:
An object.
Output:
The modular inverse of the object.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
IDIV2
Example:
Solve the following for x, modulo the default modulus, 13.
Command:
Result:
IP
Type:
Description:
Access:
Flags:
Input/Output:
See also:
( 2x ≡ 1 )
INVMOD(2)
-6
Function
Integer Part Function: Returns the integer part of its argument.
The result has the same sign as the argument.
( ´ is the left-shift of the Pkey).
!´ REALL IP
Numerical Results (–3)
Level 1/Argument 1
Example:
See also:
IQUOT
Type:
Description:
ISOL
Type:
Description:
Level 1/Item 1
Access:
Flags:
Input/Output:
Command
Isolate Variable Command: Returns an algebraic symb2 that rearranges symb1 to “isolate” the first
occurrence of variable global.
The result symb2 is an equation of the form global = expression. If global appears more than once,
then symb2 is effectively the right side of an equation obtained by rearranging and solving symb1 to
isolate the first occurrence of global on the left side of the equation.
If symb1 is an expression, it is treated as the left side of an equation symb1 = 0.
If global appears in the argument of a function within symb1, that function must be an analytic
function, that is, a function for which the calculator provides an inverse. Thus ISOL cannot solve
IP(x)=0 for x, since IP has no inverse.
ISOL is identical to SOLVE.
!ÎISOL
( Îis the left-shift of the 7key).
Principal Solution (–1), Numerical Results (–3)
x
→
n
Level 2/Argument 1
x_unit
→
n_unit
'symb'
32.3_m IP returns 32_m.
FP
→
'IP(symb)'
'symb1'
'global'
COLCT, EXPAN, QUAD, SHOW, SOLVE
Function
Returns the integer quotient (or Euclidean quotient) of two integers. That is, given two integers, a
and b, returns the integer q, such that:
a = qb + r, and 0 ≤ r < b
Access:
PARITH or Arithmetic, !ÞINTEGER L
Input:
Level 2/Argument 1: The dividend.
Level 1/Argument 2: The divisor.
Output:
The integer quotient.
3-120 Full Command and Function Reference
See also:
Level 1/Argument 2
Level 1/Item 1
→
'symb2'
ISOM
Type:
Command
Description:
Determine the characteristics of a 2-d or 3-d linear isometry.
Access:
Matrices, !Ø LINEAR APPL
Input:
A square matrix representing a linear isometry.
Output:
A vector and/or an angle that represent the symmetry of the matrix, and 1 (for a direct isometry)
or –1 (for an indirect isometry).
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Full Command and Function Reference 3-121
Input/Output:
Level 1/Argument 1
See also:
LOGFIT
Type:
Description:
Level 1/Item 1
z
→
log z
'symb'
→
'LOG(symb)'
Access:
…µ PCOV
Input/Output:
Level 1/Argument 1
ALOG, EXP, ISOL, LN
See also:
Command
Logarithmic Curve Fit Command: Stores LOGFIT as the fifth parameter in the reserved variable
ΣPAR, indicating that subsequent executions of LR are to use the logarithmic curve-fitting model.
LINFIT is the default specification in ΣPAR.
PDIM
Type:
Description:
Access:
…µ LOGFIT
Input/Output: None
See also:
BESTFIT, EXPFIT, LINFIT, LR, PWRFIT
LQ
Type:
Description:
Access:
Command
LQ Factorization of a Matrix Command: Returns the LQ factorization of an m × n matrix.
LQ factors an m × n matrix A into three matrices:
• L is a lower m × n trapezoidal matrix.
• Q is an n × n orthogonal matrix.
• P is a m × m permutation matrix.
Where P × A = L × Q.
!Ø FACTORIZATION LQ
( Ø is the left-shift of the 5key).
!´ MATRIX FACTORS LQ
( ´ is the left-shift of the Pkey).
Input/Output:
Level 1/Argument 1
[[ matrix ]]A
See also:
LR
Type:
Description:
→
Level 3/Item 1
Level 2/Item 2
Level 1/Item 3
[[ matrix ]]L
[[ matrix ]]Q
[[ matrix ]]P
LSQ, QR
Command
Linear Regression Command: Uses the currently selected statistical model to calculate the linear
regression coefficients (intercept and slope) for the selected dependent and independent variables
in the current statistics matrix (reserved variable ΣDAT).
The columns of independent and dependent data are specified by the first two elements in the
reserved variable ΣPAR, set by XCOL and YCOL, respectively. (The default independent and
dependent columns are 1 and 2.) The selected statistical model is the fifth element in ΣPAR. LR
stores the intercept and slope (untagged) as the third and fourth elements, respectively, in ΣPAR.
The coefficients of the exponential (EXPFIT), logarithmic (LOGFIT), and power (PWRFIT)
models are calculated using transformations that allow the data to be fitted by standard linear
regression. The equations for these transformations appear in the table below, where b is the
intercept and m is the slope. The logarithmic model requires positive x-values (XCOL), the
exponential model requires positive y-values (YCOL), and the power model requires positive xand y-values.
xpcovariance
COLΣ, CORR, COV, PREDX, PREDY, XCOL, YCOL
Command
PICT Dimension Command: Replaces PICT with a blank PICT of the specified dimensions.
If the arguments are complex numbers, PDIM changes the size of PICT and makes the arguments
the new values of (xmin, ymin) and (xmax, ymax) in the reserved variable PPAR. Thus, the scale of a
subsequent plot is not changed. If the arguments are binary integers, PPAR remains unchanged,
so the scale of a subsequent plot is changed.
PICT cannot be smaller than 131 pixels wide × 80 pixels high on the HP 50g and 49g+ (64 pixels
high on the HP 48gII) nor wider than 2048 pixels (height is unlimited).
Access:
!°PICT PDIM
Input/Output:
( °is the left-shift of the Nkey).
Level 2/Argument 1
Level 1/Argument 2
(xmin, ymin)
#nwidth
(xmax, ymax)
#mheight
Level 1/Item 1
→
→
See also:
PMAX, PMIN
PERINFO
Type:
Description:
Access:
Input/Output:
See also:
Command
Displays the Periodic Table version and copyright information. It doesn’t affect the stack.
G PERIODIC TABLE PERINFO
None
MOLWT, PERTBL, PTPROP
PERM
Type:
Description:
Function
Permutations Function: Returns the number of possible permutations of n items taken m at a
time.
The formula used to calculate Pn,m is:
n!
P n, m = -------------------( n – m )!
The arguments n and m must each be less than 1012. If n < m, zero is returned.
Access:
!´LPROBABILITY PERM
Flags:
Numerical Results (–3)
Input/Output:
See also:
3-138 Full Command and Function Reference
Level 1/Item 1
→
( ´ is the left-shift of the Pkey).
Level 2/Argument 1
Level 1/Argument 2
n
'symbn'
n
'symbn'
m
m
'symbm'
'symbm'
Level 1/Item 1
→
→
→
→
Pn,m
'PERM(symbn,m)'
'PERM(n, symbm)'
'PERM(symbn,symbm)'
COMB, FACT, !
Full Command and Function Reference 3-167
Input/Output:
Result:
Level 1/Argument 1
See also:
[[ matrix ]]A
DET, INV, LSQ, /
→
Level 3/Item 1
Level 2/Item 2
Level 1/Item 3
[[ matrix ]]L
[[ matrix ]]U
[[ matrix ]]P
LVAR
See also:
PATH
Type:
Description:
1/2/(X-1)+-1/2/(X+1)
PROPFRAC
Command
Current Path Command: Returns a list specifying the path to the current directory.
The first directory is always HOME, and the last directory is always the current directory.
If a program needs to switch to a specific directory, it can do so by evaluating a directory list, such
as one created earlier by PATH.
( °is the left-shift of the Nkey).
!°MEMORY DIRECTORY PATH
Type:
Command
Description:
Returns a list of variables in an algebraic object. Differs from LNAME above in that functions of
variables, such as COS(X) or LN(AB) are returned, instead of the variable names, X or AB. INV()
and SQ() are not treated as functions. Compare the example here with the same example in
LNAME.
Access:
Catalog, …µ
Input:
An algebraic object.
See also:
Output:
Level 2/Item 1: The algebraic object.
Level 1/Item 2: A list which includes both the original expression and a vector containing the
variable names. Variable names include functions of variables, as described above. The names are
sorted by length, longest first, and ones of equal length are sorted alphabetically.
Type:
Command
Description:
Returns the characteristic polynomial of an n × n matrix.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Access:
Matrices, !Ø L EIGENVECTORS
Input:
A square matrix.
Output:
The characteristic polynomial of the matrix.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Find the characteristic polynomial of the following matrix:
Flags:
List the variables and function names in the expression COS(B)/2*A + MYFUNC(PQ) + 1/T.
LVAR(COS(B)/2*A + MYFUNC(PQ) + INV(T))
See also:
LNAME
MAD
Type:
Description:
Command
{COS(B)/2*A + MYFUNC(PQ) + 1/T, [MYFUNC(PQ),COS(B),A,T]}
Returns details of a square matrix, including the information needed to obtain the adjoint matrix.
The adjoint matrix is obtained by multiplying the inverse matrix by the determinant.
Matrices, !Ø
Level 1/Argument 1
OPERATIONS L
Command:
Result:
A square matrix
Output:
Level 4/Item 1: The determinant.
Level 3/Item 2: The formal inverse.
Level 2/Item 3: The matrix coefficients of the polynomial, p, defined by
(xi–a)p(x)=m(x)i, where a is the matrix, and m is the characteristic polynomial of a.
Level 1/Item 4: The characteristic polynomial.
PCOEF
Type:
Description:
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Obtain the adjoint matrix of:
See also:
MAD([[0, -1][1, 0]])
{1,[[0, 1][-1, 0]],{[[1, 0][0, 1]], [[0, -1][1, 0]]}, X^2+1}
The determinant is 1, so the adjoint is the second item[[0, 1][-1, 0]].
LNAME
3-140 Full Command and Function Reference
CRDIR, HOME, PGDIR, UPDIR
5 8 16
4 1 8
– 4 – 4 – 11
Input:
0 –1
1 0
{ HOME directory-name1 ... directory-namen }
PCAR
See also:
Command:
Result:
Level 1/Item 1
→
Example:
Command:
Result:
Access:
Access:
Input/Output:
Access:
Input/Output:
PCAR([[5,8,16][4,1,8][-4,-4,-11]])
X^3+5*X^2+3*X-9
JORDAN, PMINI
Command
Monic Polynomial Coefficients Command: Returns the coefficients of a monic polynomial (a
polynomial with a leading coefficient of 1) having specific roots.
The argument must be a real or complex array of length n containing the polynomial’s roots. The
result is a real or complex vector of length n+1 containing the coefficients listed from highest
order to lowest, with a leading coefficient of 1.
!Þ POLYNOMIAL LL PCOEF
( Þis the left-shift of the 1key).
Level 1/Argument 1
Example:
Command:
Result:
See also:
Level 1/Item 1
[ array ]roots
Find the polynomial that has the roots 2, –3, 4, –5:
→
[ array ]coefficients
[ 2 –3 4 –5 ] PCOEF
[ 1 2 –25 –26 120 ], representing the polynomial x4 + 2x3 - 25x2 - 26x + 120.
PEVAL, PROOT
Full Command and Function Reference 3-165
The pattern 'symbpat' and replacement 'symbrepl' can be normal expressions; for example, you can
replace .5 with 'SIN(π/6)'. You can also use a “wildcard” in the pattern (to match any
subexpression) and in the replacement (to represent that expression). A wildcard is a name that
begins with &, such as the name '&A', used in replacing 'SIN(&A+&B)' with
'SIN(&A)*COS(&B)+COS(&A)*SIN(&B)'. Multiple occurrences of a particular wildcard in a
pattern must match identical subexpressions.
↓MATCH works from top down; that is, it checks the entire expression first. This approach
works well for expansion. An expression expanded during one execution of ↓MATCH will
contain additional subexpressions, and those subexpressions can be expanded by another
execution of ↓MATCH. Several expressions can be expanded by one execution of ↓MATCH
provided none is a subexpression of any other.
Access:
…µ↓MATCH
Input/Output:
Example 1:
Level 2/Argument 1
Level 1/Argument 2
'symb1'
{ 'symbpat' 'symbrepl' }
Level 2/Item 1
→
'symb2'
Level 1/Item
0/1
→
'symb1'
{ 'symbpat' 'symbrepl' 'symbcond' }
'symb2'
0/1
.5 { .5 'SIN(π/6)' } ↓MATCH returns 'SIN(π/6)' to level 2 and 1 to level
1.
Example 2: 'SIN(U+V)' { 'SIN(&A+&B)'
'SIN(&A)*COS(&B)+COS(&A)*SIN(&B)' } ↓MATCH returns
'SIN(U)*COS(V)+COS(U)*SIN(V)' to level 2 and 1 to level 1.
Example 3: This sequence: 'SIN(5*Z)' { 'SIN(&A+&B)'
'Σ(K=0,&A,COMB(&A,K)*SIN(K*π)*COS(&B^(&A-K)*SIN(&B)^K)'
'ABS(IP(&A))==&A' } ↓MATCH returns
'Σ(K=0,5,COMB(5,K)*SIN(K*π)*COS(Z^(5-K)*SIN(Z)^K)' to level 2
and 1 to level 1.
See also:
↑MATCH
Type:
Description:
Access:
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
• indep is a list containing a name that specifies the independent variable, and two numbers
specifying the minimum and maximum values for the independent variable (the plotting range).
Note that the default value is X. If X is not modified and included in a list with a plotting
range, the values in (xmin, ymin) and (xmax, ymax) are used as the plotting range, which generally
leads to meaningless results.
• res is a real number specifying the interval, in user-unit coordinates, between values of the
independent variable. The default value is 0, which specifies an interval equal to 1/130 of the
difference between the maximum and minimum values in indep (the plotting range).
• axes is a list containing one or more of the following, in the order listed: a complex number
specifying the user-unit coordinates of the plot origin, a list specifying the tick-mark annotation,
and two strings specifying labels for the horizontal and vertical axes. The default value is (0,0).
• ptype is a command name specifying the plot type. Executing the command PARAMETRIC
places the name PARAMETRIC in PPAR.
• depend is a name specifying a label for the vertical axis. The default value is Y.
The contents of EQ must be an expression or program; it cannot be an equation. It is evaluated
for each value of the independent variable. The results, which must be complex numbers, give the
coordinates of the points to be plotted. Lines are drawn between plotted points unless flag –31 is
set.
Access:
…µ PARAMETRIC
Flags:
Simultaneous Plotting (–28), Curve Filling (–31)
Input/Output: None
See also:
BAR, CONIC, DIFFEQ, FUNCTION, GRIDMAP, HISTOGRAM, PARSURFACE,
PCONTOUR, POLAR, SCATTER, SLOPEFIELD, TRUTH, WIREFRAME, YSLICE
PARITY
Type:
Description:
↑MATCH
Command
Bottom-Up Match and Replace Command: Rewrites an expression.
↑MATCH rewrites expressions or subexpressions that match a specified pattern 'symbpat'. An
optional condition, 'symbcond', can further restrict whether a rewrite occurs. A test result is also
returned to indicate if command execution produced a rewrite; 1 if it did, 0 if it did not.
The pattern 'symbpat' and replacement 'symbrepl' can be normal expressions; for example, you can
replace 'SIN(π/6)' with '1/2'. You can also use a “wildcard” in the pattern (to match any
subexpression) and in the replacement (to represent that expression). A wildcard is a name that
begins with &, such as the name '&A', used in replacing 'SIN(&A+π)' with '–SIN(&A)'. Multiple
occurrences of a particular wildcard in a pattern must match identical subexpressions.
↑MATCH works from bottom up; that is, it checks the lowest level (most deeply nested)
subexpressions first. This approach works well for simplification. A subexpression simplified
during one execution of ↑MATCH will be a simpler argument of its parent expression, so the
parent expression can be simplified by another execution of ↑MATCH.
Several subexpressions can be simplified by one execution of ↑MATCH provided none is a
subexpression of any other.
…µ↑MATCH
3-142 Full Command and Function Reference
Access:
Input/Output:
Command
Parity Command: Sets the parity value in the reserved variable IOPAR.
Legal values are shown below. A negative value means the calculator does not check parity on
bytes received during Kermit transfers or with SRECV. Parity is still used during data
transmission, however.
n-Value
Meaning
0
no parity (the default value)
1
odd parity
2
even parity
3
mark
4
space
For more information, refer to the reserved variable IOPAR in appendix D, “Reserved
Variables”.
…µPARITY
Level 1/Argument 1
nparity
See also:
Level 1/Item 1
→
BAUD, CKSM, TRANSIO
Full Command and Function Reference 3-163
Example 1:
10 -23 MAX returns 10.
bit1
bit2
bit1 OR bit2
Example 2:
-10 -23 MAX returns -10.
0
0
0
Example 3:
1_m 9_cm MAX returns 1_m.
0
1
1
MIN
1
0
1
1
1
1
See also:
MAXR
Type:
Description:
Access:
Flags:
Input/Output:
Function
Maximum Real Function: Returns the symbolic constant MAXR or its numerical representation
9.99999999999E499.
MAXR is the largest real number that can be represented by the calculator.
!´L CONSTANTS LMAXR ( ´ is the left-shift of the Pkey).
Symbolic Constants (–2), Numerical Results (–3)
Level 1/Argument 1
See also:
MAXΣ
Σ
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
→
'MAXR'
→
9.99999999999E499
e, i, MINR, π
MCALC
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
→
xmax
→
[xmax1 xmax2 ... xmaxm ]
BINS, MEAN, MINΣ, SDEV, TOT, VAR
Command
Make Calculated Value Command: Designates a variable as a calculated variable for the multipleequation solver.
MCALC designates a single variable, a list of variables, or all variables as calculated values.
…µ MCALC
Level 1/Argument 1
See also:
Access:
Flags:
Input/Output:
(ãis the right-shift of the 3key).
…ãL LOGIC OR
!° TEST L OR
( °is the left-shift of the Nkey).
Numerical Results (–3), Binary Integer Wordsize (–5 through –10)
Command
Maximum Sigma Command: Finds the maximum coordinate value in each of the m columns of
the current statistical matrix (reserved value ΣDAT).
The maxima are returned as a vector of m real numbers, or as a single real number if m = 1.
…µ MAXΣ
Level 1/Argument 1
See also:
• An argument that is a string is treated as a sequence of bits, using 8 bits per character (that is,
using the binary version of the character code). The two string arguments must be the same
length.
When the arguments are real numbers or symbolics, OR simply does a true/false test. The result
is 1 (true) if either or both arguments are nonzero; it is 0 (false) if both arguments are zero. This
test is usually done to compare two test results.
If either or both of the arguments are algebraic objects, then the result is an algebraic of the form
symb1 OR symb2. Execute →NUM (or set flag –3 before executing OR) to produce a numeric
result from the algebraic result.
See also:
ORDER
Type:
Description:
Level 2/Argument 1
Level 1/Argument 2
#n1
#n2
→
Level 1/Item 1
#n3
“string1”
“string2”
→
“string3”
T/F1
T/F2
→
0/1
T/F
'symb'
→
'T/F OR symb'
'symb'
T/F
→
'symb OR T/F'
'symb1'
'symb2'
→
'symb1 OR symb2'
AND, NOT, XOR
Command
Order Variables Command: Reorders the variables in the current directory (shown in the VAR
menu) to the order specified.
The names that appear first in the list will be the first to appear in the VAR menu. Variables not
specified in the list are placed after the reordered variables.
If the list includes the name of a large subdirectory, there may be insufficient memory to execute
ORDER.
Access:
!°MEMORY DIRECTORY L ORDER
Input/Output:
( °is the left-shift of the Nkey).
Level 1/Argument 1
Level 1/Item 1
{ global1 ... globaln }
Level 1/Item 1
→
'name'
→
{ list }
→
See also:
VARS
"ALL"
→
OVER
Type:
Description:
RPL command
Over Command: Returns a copy to stack level 1 of the object in level 2.
MUSER
3-144 Full Command and Function Reference
Full Command and Function Reference 3-161
Access:
than a list or name containing a list is supplied to MENU, a Bad Argument Type error will occur
when the calculator attempts to display the custom menu.
A full list of all menus can be found in Appendix H of this reference.
!&H [MENU] MENU
!°LIST OBJ→
…&NL OBJ→
!°LCHARS LOBJ→
!°LMODES [MENU] MENU ( °is the left-shift of the Nkey).
xmenu
Example 1:
Example 2:
Example 3:
Example 4:
See also:
Level 1/Item 1
→
→
{ obj1, ... ,objn }
→
obj1
[ x1, ... ,xn ]
→
{ listdefinition }
→
[[ x1 1, ... ,xm n ]]
'namedefinition'
→
“obj”
→
'symb'
→
x_unit
→
→
obj
5 MENU displays the first page of the MTH MATR NORM menu.
48.02 MENU displays the second page of the UNITS MASS menu.
{ A 123 "ABC" } MENU displays the custom menu defined by the list argument.
'MYMENU' MENU displays the custom menu defined by the name argument.
RCLMENU, TMENU
Description:
Displays a function key menu of computer algebra commands in a specified range.
Access:
Catalog, …µ
Input:
Level 2/Argument 1: The number of the first command in the range to be displayed.
Level 1/Argument 2: The number of the last command in the range to be displayed.
Arguments below 0 are treated as 0; arguments above 140 are treated as 140.
Output:
On the function key menu, the computer algebra commands in the range specified. NOVAL is
returned in Algebraic mode.
This list gives the number of each operation that can be displayed by the command. The complete
menu below can be generated by MENUXY(0,140). Items 127 through to 135 allow access from
the top row of keys to CAS menus.
EXPAND
TAYLOR0
PREVAL
LDEC
SINCOS
TRIGTAN
ASIN2C
REMAINDER
ABCUV
PTAYL
ISPRIME?
FROOTS
REF
SYLVESTER
HILBERT
LEGENDRE
TABVAR
MAP
(x, y)
→
Example:
Command
Number
0-5
6-11
12-17
18-23
24-29
30-35
36-41
42-47
48-53
54-59
60-65
66-71
72-77
78-83
84-89
90-95
96-101
102-107
Leveln+1/Item1
Level 1/Argument 1
MENUXY
Type:
( °is the left-shift of the Nkey).
Input/Output:
Input/Output:
Level 1/Argument 1
( °is the left-shift of the Nkey).
FACTOR
SERIES
RISCH
TEXPAND
TLIN
TAN2SC
ACOS2S
IREMAINDER
IABCUV
HORNER
NEXTPRIME
FACTORS
AXM
PCAR
LCXM
TCHEBYCHEFF
TABVAL
XNUM
Operation
SUBST
SOLVEVX
DERIV
LIN
TCOLLECT
HALFTAN
DIV2
GCD
LGCD
EULER
PREVPRIME
DIVIS
AXL
JORDAN
DIV
HERMITE
DIVPC
XQ
3-146 Full Command and Function Reference
DERVX
PLOT
DESOLVE
TSIMP
TRIG
TAN2SC2
IDIV2
LCM
SIMP2
PA2B2
SOLVE
TRAN
QXA
MAD
CURL
LAGRANGE
TRUNC
REORDER
INTVX
PLOTADD
LAP
LNCOLLECT
TRIGCOS
ATAN2S
QUOT
EGCD
PARTFRAC
CHINREM
ZEROS
HADAMARD
AXQ
LINSOLVE
LAPL
FOURIER
SEVAL
LVAR
lim
IBP
ILAP
EXPLN
TRIGSIN
ASIN2T
IQUOT
IEGCD
PROPFRAC
ICHINREM
FCOEF
rref
GAUSS
VANDERMONDE
HESS
SIGNTAB
TEVAL
FXND
See also:
Level2/Itemn
Level1/Itemn+1
x
y
…
objn
n
x1
…
xn
{n}
x1 1
…
xm n
{ m, n }
evaluated object
arg1 ... argn
…
n
'function'
x
1_unit
→
:tag:obj
obj
The command sequence '„(0,1,SIN(X),X)' OBJ→ returns:
6:
0
first argument
5:
1
second argument
4: 'SIN(X)'
third argument
3:
'X'
fourth argument
2:
4
number of arguments for „
1:
„
function name
ARRY→, C→R, DTAG, EQ→, LIST→, R→C, STR→, →TAG
“tag”
OCT
Type:
Description:
Command
Octal Mode Command: Selects octal base for binary integer operations.
(The default base is decimal.) Binary integers require the prefix #. Binary integers entered and
returned in octal base automatically show the suffix o. If the current base is not octal, enter an
octal number by ending it with o. It will be displayed in the current base when entered. The
current base does not affect the internal representation of binary integers as unsigned binary
numbers.
Access:
…ãOCT
(ã is the right-shift of the 3key).
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output: None
See also:
BIN, DEC, HEX, RCWS, STWS
OFF
Type:
Description:
Command
Off Command: Turns off the calculator.
When executed from a program, that program will resume execution when the calculator is turned
on. This provides a programmable “autostart.” ( i.e., a programmable …ç).
Access:
„°LLRUNL OFF
( °is the left-shift of the Nkey).
Input/Output: None
See also:
CONT, HALT, KILL
OLDPRT
Type:
Description:
Command
Modifies the remapping string in the reserved variable PRTPAR so that the extended character set
of the calculator matches that of the HP 82240A Infrared Printer.
Full Command and Function Reference 3-159
Use the number or arrow keys to cross the battlefield one square at a time (use 7, 9, 1,
and 3to move diagonally.) You can exit the game at any time by pressing −(the $ key).
To interrupt and save a game, press K. This creates a variable MHpar in the current directory
and ends the game. If MHpar exists when you start MINEHUNT, the interrupted game resumes
and MHpar is purged.
You can change the number of mines in the battlefield by creating a variable named Nmines
containing the desired number. Nmines must contain a real number (1 to 64). If Nmines is negative,
the mines are visible during the game (allowing you to cheat).
Access:
G EQUATION LIBRARY UTILS MINEHUNT
Input/Output: None.
MINIFONT→
Type:
Command
Description:
Minifont: Returns the font that is set as the minifont.
Access:
…µ MINIFONT→
Input/Output:
Font object
Access:
See also:
MINR
Type:
Description:
Access:
Flags:
Command
Number of Sublist Command: Provides a way to access the current sublist position during an
iteration of a program or command applied using DOSUBS.
Returns an Undefined Local Name error if executed when DOSUBS is not active.
( °is the left-shift of the Nkey).
!°LIST PROCEDURES NSUB
Level 1/Argument 1
Command
Multiple-equation Menu Initialization Command. Creates the reserved variable Mpar, which
includes the equations in EQ and the variables in these equations.
…µMINIT
MITM, MROOT, MSOLVR
Function
Minimum Real Function: Returns the symbolic constant MINR or its numerical representation,
1.00000000000E–499.
MINR is the smallest positive real number that can be represented by the calculator.
!´LCONSTANTS LMINR ( ´ is the left-shift of the Pkey).
Symbolic Constants (–2), Numerical Results (–3)
Level 1/Item 1
→
→
See also:
→NUM
Type:
Description:
Access:
Input/Output:
Command
Evaluate to Number Command. Evaluates a symbolic argument object (other than a list) and
returns the numerical result.
→NUM repeatedly evaluates a symbolic argument until a numerical result is achieved. The effect is
the same as evaluating a symbolic argument in Numerical Result Mode (flag –3 set).
… →NUM
(→NUM is the right-shift of the `key).
objsymb
NUM
Type:
Description:
nposition
DOSUBS, ENDSUB
Level 1/Argument 1
See also:
nrows
ΣX, ΣXY, ΣX2, ΣY, ΣY2
Level 1/Item 1
MINIFONT→
3-148 Full Command and Function Reference
See also:
Access:
Input/Output:
Level 1/Argument 1
Level 1/Item 1
→
NSUB
Type:
Description:
→MINIFONT
Type:
Command
Description:
Minifont: Sets the font that is used as the minifont.
Access:
…µ →MINIFONT
Input/Output:
MINIT
Type:
Description:
Command
Number of Rows Command: Returns the number of rows in the current statistical matrix
(reserved variable ΣDAT).
…µ NΣ
Level 1/Argument 1
→
See also:
NΣ
Type:
Description:
( °is the left-shift of the Nkey).
Level 1/Item 1
→MINIFONT
Font object
Access:
!°L IN NOVAL
Input/Output: None
See also:
INFORM
Access:
Input/Output:
Level 1/Argument 1
See also:
NOVAL is used to mark an empty field in a user-defined dialog box created with the INFORM
command. INFORM defines fields sequentially. If default values are used for those fields, the
defaults must be defined in the same order as the fields were defined. To skip over (not provide
defaults for) some of the fields, use the NOVAL command.
After INFORM terminates, NOVAL is returned if a field is empty and OK or ` is selected.
Level 1/Item 1
→
z
EVAL
Command
Character Number Command: Returns the character code n for the first character in the string.
The character codes are an extension of ISO 8859/1. Codes 128 through 159 are unique to the
calculators.
Full Command and Function Reference 3-157
Example 2:
Command:
Result:
See also:
MOD
Type:
Description:
Access:
Flags:
Input/Output:
Find the matrix for a rotation with axis [1 1 1] and angle π/3 radians combined with a reflection in
the plane x + y + z = 0
MKISOM({ [1, 1, 1],π/3}, -1) then simplify with EXPAND(ANS(1))
0 –1 0
0 0 –1
–1 0 0
See also:
NEWOB
Type:
Description:
ISOM
Function
Modulo Function: Returns a remainder defined by: x mod y = x – y floor (x/y)
Mod (x, y) is periodic in x with period y. Mod (x, y) lies in the interval [0, y) for y > 0 and in (y, 0]
for y < 0.
Algebraic syntax: argument 1 MOD argument 2
!´REAL MOD
( ´ is the left-shift of the Pkey).
!ÞMODUL L MOD
( Þ is the left-shift of the 1key).
Numerical Results (–3)
Level 2/Argument 1
See also:
FLOOR, /
MODSTO
Type:
Description:
Command
Level 1/Argument 2
Level 1/Item 1
x
y
→
x mod y
x
'symb'
→
'MOD(x, symb)'
'symb'
x
→
'MOD(symb, x)'
'symb1'
'symb2'
→
'MOD(symb1, symb2)'
Changes the modulo setting to the specified number. The number that you set is reflected in the
CAS Modes input form. Negative numbers are replaced by their positive value, 0 and 1 are
replaced by 2.
Access:
Flags:
ABS, CONJ, NOT, SIGN
Command
New Object Command: Creates a new copy of the specified object.
NEWOB has two main uses:
• NEWOB enables the purging of a library or backup object that has been recalled from a port.
NEWOB creates a new, separate copy of the object in memory, thereby allowing the original
copy to be purged.
• Creating a new copy of an object that originated in a larger composite object (such as a list)
allows you to recover the memory associated with the larger object when that larger object is no
longer needed.
( °is the left-shift of the Nkey).
!°MEMORY NEWOB
Last Arguments (–55). In order for NEWOB to immediately release the memory occupied by the
original copy, flag –55 must be set so that the copy is not saved as a last argument.
Input/Output:
Level 1/Argument 1
Example 1:
Example 2:
See also:
Level 1/Item 1
→
obj
obj
:0:BKUP1 RCL NEWOB :0:BKUP1 PURGE recalls and purges the backup object
BKUP1.
3 GET NEWOB retrieves the third element out of a list on the stack, recovering the memory
occupied by the whole list.
MEM, PURGE
NEXT
Type:
Description:
Command
NEXT Command: Ends definite loop structures.
See the FOR and START keyword entries for more information.
Access:
!°BRANCH START/FOR NEXT ( °is the left-shift of the Nkey).
Input/Output: None
See also:
FOR, START, STEP
Access:
Arithmetic, !Þ MODULO L
Input:
The modulo value that you want to set, an integer or an expression that evaluates to an integer.
Output:
The modulo setting is changed to the specified number. In Algebraic mode, NOVAL is returned
as argument 1.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
NEXT
Type:
Description:
Access:
Input/Output:
See also:
Type:
Command
Type:
Function
Description:
Displays a menu or list of the CAS modulo operations.
Description:
Access:
Catalog, …µ
Given an integer, returns the next prime number larger than the integer. Like ISPRIME?, it uses a
pseudoprime check for large numbers.
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
Access:
Arithmetic, !Þ INTEGER L
Input:
An integer or an expression that evaluates to an integer.
ALGB, ARIT, CONSTANTS, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR,
POLYNOMIAL, REWRITE, TESTS, TRIGO
Output:
The next prime number larger than the integer.
Example:
Find the closest, larger prime number to 145.
MODULAR
See also:
Operation
NEXT Operation: Returns but does not execute the next one or two steps of a program.
„°LLRUN NEXT
( °is the left-shift of the Nkey).
None
SST, SST↓
NEXTPRIME
3-150 Full Command and Function Reference
Full Command and Function Reference 3-155
variable Mpar that is used during the solution process. Mpar contains the equation set plus
additional information. See appendix D, “Reserved Variables”, for information about Mpar.
Input/Output:
Level 1/Argument 1
See also:
“message”
CHOOSE, INFORM, PROMPT
Level 1/Item 1
→
MSLV
MULTMOD
Type:
Command
Description:
Numerically approximates a solution to a system of equations. Searches for a solution accurate to
12 digits, regardless of the display setting. Underdetermined and overdetermined systems are
rejected. Complex solutions will be looked for if any of the inputs contain complex values. If a
single expression or equation is to be solved, use SOLVE instead, or for linear equations, use
LINSOLVE. This command is similar to MSOLVR, but is more appropriate for use with the
CAS as it automates the solution instead of working through a menu. Step-by-step mode is
available with this command.
Access:
Numeric solve, …Ï or catalog, …µ
Input:
Level 3/Argument 1: A vector containing the equations or expressions (assumed equal to zero) to
solve.
Level 2/Argument 2: A vector containing the variables to solve for
Level 1/Argument 3: A vector containing initial guesses
Output:
Level 3/Item 1: The vector containing the equations to solve.
Level 2/Item 2: The vector containing the variables to solve for
Level 1/Item 3: A vector representing an approximate solution to the system of equations.
Flags:
Exact mode must be set (flag –105 clear), The calculator will set approximate mode and will look
for approximate results if exact results are not found.
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Complex mode must be set (flag –103 set) if complex results are wanted.
Step-by-step mode can be set (flag –100 set).
Example:
Command:
Results:
See also:
MSOLVR
Type:
Description:
Access:
…µ MSOLVR
Input/Output: None
See also:
EQNLIB, MCALC, MINIT, MITM, MROOT, MSLV, MUSER
Type:
Function
Description:
Performs modular multiplication of two objects, modulo the current modulus.
Access:
Arithmetic, !Þ MODULO L
Input:
Level 2/Argument 1: A number or an expression.
Level 1/Argument 2: A number or an expression.
Output:
The result of modular multiplication of the two objects, modulo the current modulus.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
Find the product of 2x and 38x2, modulo the default modulus, 3.
MUSER
Type:
Description:
Access:
Input/Output:
MULTMOD(2*X,38*X^2)
X^3
Command
Make User-Defined Variable Command: Designates a variable as user-defined for the multipleequation solver.
MUSER designates a single variable, a list of variables, or all variables as user-defined.
…µ MUSER
Level 1/Argument 1
Find x and y values, allowing for complex solutions, that solve the following two equations. The
first equation is an expression equal to zero, so only the expression needs to be given. Setting the
second expression equal to a complex number forces the solver to look for complex solutions:
sin(x)+y=0, x+sin(y)=1:
MSLV('[SIN(X)+Y, X+SIN(Y)=(1,0)]', '[X,Y]', [0,0])
('[SIN(X)+Y, X+SIN(Y)=(1,0)]', '[X,Y]', [(1.82384112611,0.),
See also:
(-.968154636174,0.)])
DESOLVE, LINSOLVE, MSOLVR, SOLVE
→NDISP
Type:
Description:
Command
Multiple Equation Solver Command: Gets the multiple-equation solver variable menu for the set
of equations defined by Mpar.
The multiple-equation solver application can solve a set of two or more equations for unknown
variables by finding the roots of each equation, one at a time.
The Multiple-Equation Solver uses the list of equations stored in EQ. “Equations” in this context
includes programs, expressions, and variable names that evaluate to a single value. The MultipleEquation Solver requires that EQ contain more than one equation — that is, the HP Solve
application would include the NXEQ menu label for EQ. The solver uses EQ to create a reserved
Access:
Input/Output:
3-152 Full Command and Function Reference
Level 1/Item 1
'name'
→
{ list }
→
"ALL"
→
MCALC
Command
Sets the number of program lines displayed on the screen.
The default value on the calculator is 9. On the HP 50g and 49g+ a value of 12 should be set for
→NDISP, which will allow more of these models’ taller screen to be used when the font is
FONT7, FONT6, or the MINIFONT. Also, note that the →NDISP setting is reset to 9 at every
warmstart. Including << 12 →NDISP >> in 'STARTUP' will automatically reset the value to 12.
…µ →NDISP
Level 1/Argument 1
n
Level 1/Item 1
→
Full Command and Function Reference 3-153
Input/Output: None
REORDER
PIX?
Type:
Description:
Type:
Function
Description:
Given a polynomial expression and a variable, reorders the variables in the expression in the order
of powers set on the CAS Modes screen, that is, either in increasing or decreasing order.
Command
Pixel On? Command: Tests whether the specified pixel in PICT is on; returns 1 (true) if the pixel
is on, and 0 (false) if the pixel is off.
Access:
!° LPICT L PIX?
Input/Output:
( °is the left-shift of the Nkey).
Level 1/Argument 1
See also:
Level 1/Item 1
(x,y)
→
0/1
{ #n #m }
→
0/1
Level 1/Argument 1
Level 1/Item 1
(x,y)
→
{ #n #m }
→
See also:
PIXON, PIX?
PIXON
Type:
Description:
Command
Pixel On Command: Turns on the pixel at the specified coordinate in PICT.
Access:
!°LPICT LPIXON
Input/Output:
( °is the left-shift of the Nkey).
Level 1/Argument 1
PKT
Type:
Description:
Access:
Catalog, …µ
Input:
Level 2/Argument 1: The polynomial expression.
Level 1/Argument 2: The variable with respect to which the reordering is performed.
Output:
The reordered expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Complex mode must be set (flag –103 set) if the polynomial contains complex terms.
The polynomial terms order flag (flag –114) must be set for increasing power order, or clear (the
default) for decreasing power order.
Example:
Reorder the polynomial x2 + 2y2 +2x +3y in order of powers of y. Assume that increasing power
mode has been set in the CAS modes.
PIXON, PIXOFF
PIXOFF
Type:
Command
Description:
Pixel Off Command: Turns off the pixel at the specified coordinate in PICT.
( °is the left-shift of the Nkey).
Access:
!°LPICT L PIXOFF
Input/Output:
See also:
Access:
Level 1/Item 1
(x,y)
→
{ #n #m }
→
Command:
Result:
REPEAT
Type:
Description:
3-170 Full Command and Function Reference
2*Y^2+3*Y+(X^2+2*X)
Command
REPEAT Command: Starts loop clause in WHILE … REPEAT … END indefinite loop
structure.
See the WHILE entry for more information.
Access:
!°BRANCH WHILE REPEAT
Input/Output: None
See also:
END, WHILE
REPL
Type:
Description:
PIXOFF, PIX?
Command
Packet Command: Used to send command “packets” (and receive requested data) to a Kermit
server.
To send calculator objects, use SEND.
PKT allows additional commands to be sent to a Kermit server.
The packet data, packet type, and the response to the packet transmission are all in string form.
PKT first does an I (initialization) packet exchange with the Kermit server, then sends the server a
packet constructed from the data and packet-type arguments supplied to PKT. The response to
PKT will be either an acknowledging string (possibly blank) or an error packet (see KERRM).
For the type argument, only the first letter is significant.
…µ PKT
REORDER(X^2+2*Y^2+2*X+6+3*Y, Y)
Access:
( °is the left-shift of the Nkey).
Command
Replace Command: Replaces a portion of the target object (first input) with a specified object
(third input), beginning at a specified position (second input).
For arrays, nposition counts in row order. For matrices, nposition specifies the new location of the
upper left-hand element of the replacement matrix.
For graphics objects, the upper left corner of grob1 is positioned at the user-unit or pixel
coordinates (x,y) or { #n #m }. From there, it overwrites a rectangular portion of grobtarget or
PICT. If grob1 extends past grobtarget or PICT in either direction, it is truncated in that direction. If
the specified coordinate is not on the target graphics object, the target graphics object does not
change.
!°LIST REPL
( °is the left-shift of the Nkey).
Full Command and Function Reference 3-199
Access:
…µ PMIN
Input/Output:
Input/Output:
Level 1/Argument 1
Level 1/Argument 1
See also:
PMINI
Type:
Command
Description:
Finds the minimal polynomial of a matrix.
Access:
Matrices, ! Ø LEIGENVECTORS
See also:
Input:
An nxn matrix A.
Output:
A matrix whose first zero-row contains the minimal polynomial of A. In step-by-step mode,
PMINI shows the row-reduction steps.
RECN
Type:
Description:
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Step-by-step mode can be set (flag –100 set).
Example:
Command:
Find the minimal polynomial of
01
10
:
PMINI([[0,1][1,0]])
1 0 0 1
0 1 1 0
Access:
Flags:
See also:
POLAR
Type:
Description:
→
x
→
x
(x,y)
→
x
[ R-array ]
→
[ R-array ]
[ C-array ]
→
[ R-array ]
'symb'
→
'RE(symb')
C→R, IM, R→C
Command
Receive Renamed Object Command: Prepares the calculator to receive a file from another Kermit
server device, and to store the file in a specified variable.
RECN is identical to RECV except that the name under which the received data is stored is
specified.
…µ RECN
I/O Device flag (–33), I/O Data Format (–35), RECV Overwrite (–36), I/O Messages (–39), I/O
Device for Wire (–78)
Input/Output:
1
X
Level 1/Argument 1
2
Result:
x
x_unit
Level 1/Item 1
→
(x,y)
PDIM, PMAX, XRNG, YRNG
0 0 0 0 X –1
So, the minimal polynomial is X2-1, as it is in the first row to contain entirely
zeros, except for the result.
See also:
JORDAN, PCAR
Command
Polar Plot Type Command: Sets the plot type to POLAR.
When the plot type is POLAR, the DRAW command plots the current equation in polar
coordinates, where the independent variable is the polar angle and the dependent variable is the
radius. The current equation is specified in the reserved variable EQ.
The plotting parameters are specified in the reserved variable PPAR, which has this form:
{ (xmin, ymin) (xmax, ymax) indep res axes ptype depend }
For plot type POLAR, the elements of PPAR are used as follows:
• (xmin, ymin) is a complex number specifying the lower left corner of PICT (the lower left corner
of the display range). The default value is (–6.5,–3.1) for the HP 48gII and (–6.5,–3.9) for the
HP 50g and 49g+.
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
• indep is a name specifying the independent variable, or a list containing such a name and two
numbers specifying the minimum and maximum values for the independent variable (the
plotting range). The default value of indep is X.
RECT
Type:
Description:
Access:
Command
Rectangular Mode Command: Sets Rectangular coordinate mode.
RECT clears flags –15 and –16.
In Rectangular mode, vectors are displayed as rectangular components. Therefore, a 3D vector
would appear as [X Y Z].
„&H ANGLE RECT
„°L MODES ANGLE RECT
Input/Output: None
See also:
CYLIN, SPHERE
RECV
Type:
Description:
Level 1/Item 1
→
'name'
→
“name”
BAUD, CKSM, CLOSEIO, FINISH, KERRM, KGET, PARITY, RECV, SEND, SERVER,
TRANSIO
„´VECTOR L RECT
Access:
3-172 Full Command and Function Reference
Level 1/Item 1
( ´is the left-shift of the Pkey).
( °is the left-shift of the Nkey).
Command
Receive Object Command: Instructs the calculator to look for a named file from another Kermit
server device. The received file is stored in a variable named by the sender.
Since the calculator does not normally look for incoming Kermit files, you must use RECV to tell
it to do so.
…µ RECV
Full Command and Function Reference 3-197
POS
Type:
Description:
Access:
Command
Position Command: Returns the position of a substring within a string or the position of an
object within a list.
If there is no match for obj or substring, POS returns zero.
!°LCHARS POS
( °is the left-shift of the Nkey).
!°LIST ELEM POS
Executing RCLMENU when the current menu is a user-defined menu (build by TMENU)
returns 0.01 (in 2 Fix mode), indicating “Last menu”.
Access:
Input/Output:
Level 1/Argument 1
( °is the left-shift of the Nkey).
@& N POS
Level 2/Argument 1
Level 1/Argument 2
“string”
“substring”
→
Level 1/Item 1
n
obj
→
n
Level 1/Item 1
→
Example:
See also:
Input/Output:
„&HMENU RCLMENU
„°LMODES MENU RCLMENU( °is the left-shift of the Nkey).
xmenu
If the third page of the PRG STACK menu is currently active, RCLMENU returns 73.03.
MENU, TMENU
RCLVX
Type:
Command
Description:
Returns the name or list of names stored in the current CAS variable. This is the same action as
recalling the contents of the variable VX in the CASDIR directory.
See also:
{ list }
CHR, NUM, REPL, SIZE, SUB
POTENTIAL
Type:
Access:
Catalog, …µ
Command
Input:
None.
Find the potential field function describing a field whose vector gradient is input. This command
is the opposite of DERIV. Given a vector V it attempts to return a function U such that grad U
is equal to V; ∇U = V . For this to be possible, CURL(V) must be zero, otherwise the command
reports a “Bad Argument Value” error. Step-by-step mode is available with this command.
Output:
Level 1/Item 1: The name of the current CAS variable.
See also:
STOVX
Description:
Access:
Catalog, …µ
Input:
Level 2/Argument 1: A vector V of expressions.
Level 1/Argument 2: A vector of the names of the variables.
Output:
Level 1/Item 1: A function U of the variables that is the potential from which V is derived. An
arbitrary constant can be added, the command does not do this.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Step-by-step mode can be set (flag –100 set).
Example:
To confirm that this command is the opposite of DERIV, use the output of the example in
DERIV, and show that the result is the same as the input given in the DERIV example. Find the
function of the spatial variables x, y, and z whose gradient is:
(4xy+z)i + (2x2 + 6yz)j + (x+3y2)k
Command:
POTENTIAL([4*X*Y+Z, 2*X^2+6*Y*Z, X+3*Y^2], [X,Y,Z])
EXPAND(ANS(1))
Result:
2*Y*X^2+Z*X+3*Z*Y^2
See also:
DERIV, VPOTENTIAL
POWEXPAND
Type:
Function
Description:
Rewrites an expression raised to a power as a product. If followed by repeated execution of
DISTRIB allows an expression to be expanded fully, step by step.
Access:
!Ú
REWRITE L
Input:
An expression raised to a power.
3-174 Full Command and Function Reference
RCLΣ
Type:
Description:
Access:
Input/Output:
Command
Recall Sigma Command: Returns the current statistical matrix (the contents of reserved variable
ΣDAT) from the current directory.
To recall ΣDAT from the parent directory (when ΣDAT doesn’t exist in the current directory),
evaluate the name ΣDAT.
…µ RCLΣ (or …ΣDAT after pressing J)
Level 1/Argument 1
Level 1/Item 1
→
obj
See also:
CLΣ, STOΣ, Σ+, Σ–
RCWS
Type:
Description:
Access:
Flags:
Input/Output:
Command
Recall Wordsize Command: Returns the current wordsize in bits (1 through 64).
…ãL RCWS
(ã is the right-shift of the 3key).
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Level 1/Argument 1
Level 1/Item 1
→
See also:
RDM
Type:
Description:
n
BIN, DEC, HEX, OCT, STWS
Command
Redimension Array Command: Rearranges the elements of the argument according to specified
dimensions.
Full Command and Function Reference 3-195
Access:
Flags:
Input/Output:
Access:
Level 1/Argument 1
See also:
PREDV
Type:
Description:
Level 1/Item 1
→
object
CR, DELAY, OLDPRT, PRLCD, PRST, PRSTC, PRVAR
object
Command
Predicted y-Value Command: Returns the predicted dependent-variable value ydependent, based on
the independent-variable value xindependent, the currently selected statistical model, and the current
regression coefficients in the reserved variable ΣPAR.
PREDV is the same as PREDY. See PREDY.
Level 1/Argument 1
xindependent
PREDX
Type:
Description:
( Ø is the left-shift of the 5key).
!´ MATRIX ROW RCIJ
( ´ is the left-shift of the Pkey).
Input/Output:
See also:
RCL
Type:
Description:
Level 1/Item 1
→
!Ø CREATE ROW RCIJ
Level 4/Argument 1 Level 3/Argument 2 Level 2/Argument 3 Level 1/Argument 4
Access:
…µ PREDV
Input/Output:
See also:
by a constant xfactor, adds this product to element j of the vector, and returns the modified vector.
RCIJ rounds the row numbers to the nearest integer, and treats vector arguments as column
vectors.
…µ PR1
I/O Device (–33), Printing Device (–34), Double-spaced Printing (–37), Linefeed (–38), I/O
Device for Wire (–78). If flag –34 is set, flag –33 must be clear.
ydependent
PREDY
Command
Predicted x-Value Command: Returns the predicted independent-variable value xindependent, based
on the dependent-variable value ydependent, the currently selected statistical model, and the current
regression coefficients in the reserved variable ΣPAR.
The value is predicted using the regression coefficients most recently computed with LR and
stored in the reserved variable ΣPAR. For the linear statistical model, the equation used is this:
ydependent = (mxindependent) + b
where m is the slope (the third element in ΣPAR) and b is the intercept (the fourth element in
ΣPAR).
For the other statistical models, the equations used by PREDX are listed in the LR entry.
If PREDX is executed without having previously generated regression coefficients in ΣPAR, a
default value of zero is used for both regression coefficients, and an error results.
Example:
See also:
3-176 Full Command and Function Reference
nrow i
nrow j
[ vector ]1
xfactor
nelement i
nelement j
Access:
!©
Input/Output:
RCLALARM
Type:
Description:
→
[ vector ]2
( ©is the left-shift of the Kkey).
Level 1/Argument 1
See also:
Level 1/Item 1
→ [[ matrix ]]2
Command Operation
Recall Command: Returns the unevaluated contents of a specified variable.
RCL searches the entire current path, starting with the current directory. To search a different
path, specify { path name }, where path is the new path to the variable name. The path subdirectory
does not become the current subdirectory (unlike EVAL).
To recall a library or backup object, tag the library number or backup name with the appropriate
port number (nport), which must be an integer in the range 0 to 3. Recalling a backup object brings
a copy of its contents to the stack, not the entire backup object.
To search for a backup object, replace the port number with the wildcard character &, in which
case the calculator will search (in order) ports 0 through 3, and the main memory for the named
backup object.
You can specify a port (that is, nport) in one of two ways:
• H, 0, 1, 2, or 3
• H, R, E, F, or SD
In each case, the ports are home, RAM, extended RAM, flash memory, and the plug-in SD card
slot, respectively.
Level 1/Item 1
→
ydependent
xindependent
Given five columns of data in ΣDAT, the command sequence:
2 XCOL 5 YCOL LOGFIT LR 23 PREDX
sets column 2 as the independent variable column, sets column 5 as the dependent variable
column, and sets the logarithmic statistical model. It then executes LR, generating intercept and
slope regression coefficients, and storing them in ΣPAR. Then, given a dependent value of 23, it
returns a predicted independent value based on the regression coefficients and the statistical
model.
COLΣ, CORR, COV, EXPFIT, ΣLINE, LINFIT, LOGFIT, LR, PREDY, PWRFIT, XCOL,
YCOL
xfactor
RCI
Access:
…µ PREDX
Input/Output:
Level 1/Argument 1
[[ matrix ]]1
Level 1/Item 1
'obj'
→
obj
PICT
→
grob
:nport :nlibrary
→
obj
:nport :namebackup
→
obj
:nport :{ path }
→
obj
STO
Command
Recall Alarm Command: Recalls a specified alarm.
objaction is the alarm execution action. If an execution action was not specified, objaction defaults to
an empty string.
xrepeat is the repeat interval in clock ticks, where 1 clock tick equals 1/8192 second. If a repeat
interval was not specified, the default is 0.
Full Command and Function Reference 3-193
Result:
135/4
PREVPRIME
Type:
Function
Description:
Given an integer, finds the closest prime number smaller than the integer. Like ISPRIME?, it uses
a pseudoprime check for large numbers.
Access:
Arithmetic, !Þ INTEGER L
Input:
An integer or an expression that evaluates to an integer.
Output:
The closest prime number smaller than the integer.
Example:
Command:
Result:
PREVPRIME(145)
See also:
ISPRIME?, NEXTPRIME
Access:
!´ MATRIX NORMALIZE L RANK
Flags:
Singular Value (–54)
Input/Output:
Find the closest, smaller prime number to 145.
[[ matrix ]]
139
See also:
Command
Print LCD Command: Prints a pixel-by-pixel image of the current display (excluding the
annunciators).
The width of the printed image of characters in the display is narrower using PRLCD than using a
print command such as PR1. The difference results from the spacing between characters. On the
display there is a single blank column between characters, and PRLCD prints this spacing. Print
commands such as PR1 print two blank columns between adjacent characters.
Access:
…µ PRLCD
Flags:
I/O Device (–33), Printing Device (–34), Double-spaced Printing (–37), Linefeed (–38). Flag –38
must be clear, I/O Device for Wire (–78). If flag –34 is set, flag –33 must be clear.
Input/Output: None
Example:
The command sequence ERASE DRAW PRLCD clears PICT, plots the current equation, then
prints the graphics display.
See also:
CR, DELAY, OLDPRT, PRST, PRSTC, PRVAR, PR1
Access:
Input/Output:
Command
Prompt Command: Displays the contents of “prompt” in the status area, and halts program
execution.
PROMPT is equivalent to 1 DISP 1 FREEZE HALT.
!°LIN LPROMPT
( °is the left-shift of the Nkey).
Level 1/Argument 1
See also:
( ´ is the left-shift of the Pkey).
Level 1/Argument 1
PRLCD
Type:
Description:
PROMPT
Type:
Description:
Rank is computed by calculating the singular values of the matrix and counting the number of
non-negligible values. If all computed singular values are zero, RANK returns zero. Otherwise
RANK consults flag –54 as follows:
• If flag –54 is clear (the default), RANK counts all computed singular values that are less than or
equal to 1.E–14 times the largest computed singular value.
• If flag –54 is set, RANK counts all nonzero computed singular values.
!Ø OPERATIONS L RANK
( Ø is the left-shift of the 5key).
RANM
Type:
Description:
Access:
Level 1/Item 1
→
Nrank
LQ, LSQ, QR
Command
Random Matrix Command: Returns a matrix of specified dimensions that contains random
integers in the range –9 through 9.
The probability of a particular nonzero digit occurring is 0.05; the probability of 0 occurring is 0.1.
( Ø is the left-shift of the 5key).
!Ø CREATE LLRANM
!´MATRIX MAKE RANM
( ´ is the left-shift of the Pkey).
Input/Output:
Level 1/Argument 1
See also:
RATIO
Type:
Description:
Access:
Level 1/Item 1
{mn}
→
[[ random matrix ]]m×n
[[ matrix ]]m×n
→
[[ random matrix ]]m×n
RAND, RDZ
Function
Prefix Divide Function: Prefix form of / (divide).
RATIO is identical to / (divide), except that, in algebraic syntax, RATIO is a prefix function, while
/ is an infix function. For example, RATIO(A,2) is equivalent to A/2.
…µ RATIO
Level 1/Item 1
→
“prompt”
CONT, DISP, FREEZE, HALT, INFORM, INPUT, MSGBOX
PROMPTSTO
Type:
Command
Description:
Prompt Command: Creates a variable with the name supplied as an argument, prompts for a
value, and stores the value you enter in the variable.
Access:
…µPROMPTSTO
3-178 Full Command and Function Reference
Full Command and Function Reference 3-191
PRST
Type:
Description:
Input/Output:
Command
Print Stack Command: Prints all objects in the stack, starting with the object on the highest level.
Objects are printed in multiline printer format. See the PR1 entry for a description of multiline
printer format.
Access:
…µ PRST
Flags:
I/O Device (–33), Printing Device (–34), Double-spaced Printing (–37), Linefeed (–38), I/O
Device for Wire (–78). If flag –34 is set, flag –33 must be clear. Generally, flag –38 should be
clear.
Input/Output: None
See also:
CR, DELAY, OLDPRT, PRLCD, PRSTC, PRVAR, PR1
PRSTC
Type:
Description:
Command
Print Stack (Compact) Command: Prints in compact form all objects in the stack, starting with the
object on the highest level.
If flag –34 is set (printer output directed to the serial port), flag –33 must be clear.
When flag –38 is set, linefeeds are not added at the end of each print line. Generally, flag –38
should be clear for execution of PRSTC.
Compact printer format is the same as compact display format. Multiline objects are truncated
and appear on one line only.
…µ PRSTC
I/O Device (–33), Printing Device (–34), Double-spaced Printing (–37), Linefeed (–38), I/O
Device for Wire (–78)
Input/Output: None
See also:
CR, DELAY, OLDPRT, PRLCD, PRST, PRVAR, PR1
Access:
Flags:
PRVAR
Type:
Description:
Access:
Flags:
Command
Print Variable Command: Searches the current directory path or port for the specified variables
and prints the name and contents of each variable.
Objects are printed in multiline printer format. See the PR1 entry for a description of multiline
printer format.
If flag –34 is set (printer output directed to the serial port), flag –33 must be clear.
When flag –38 is set, linefeeds are not added at the end of each print line. Generally, flag –38
should be clear for execution of PRVAR.
…µ PRVAR
I/O Device (–33), Printing Device (–34), Double-spaced Printing (–37), Linefeed (–38), I/O
Device for Wire (–78). If flag –34 is set, flag –33 must be clear. Generally, flag –38 should be
clear.
Input/Output:
Level 1/Argument 1
See also:
Level 2/Argument 1
See also:
Level 1/Item 1
→
'symb2'
QUOT
Function
Type:
Description:
Returns the quotient part of the Euclidean division of two polynomials.
Access:
Arithmetic, !Þ POLYNOMIAL !«
Input:
Level 2/Argument 1: The numerator polynomial.
Level 1/Argument 2: The denominator polynomial.
Output:
The quotient of the Euclidean division.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
3
2
2
Find the quotient of the division of x + 6 x + 11 x + 6 by x + 5 x + 6 .
Example:
Command:
Result:
QUOT(X^3+6*X^2+11*X+6, X^2+5*X+6)
X+1
REMAINDER, DIV2, IQUOT
See also:
QUOTE
Type:
Description:
Access:
Input/Output:
Function
Quote Argument Function: Returns its argument unevaluated.
When an algebraic expression is evaluated, the arguments to a function in the expression are
evaluated before the function. For example, when SIN(X) is evaluated, the name X is evaluated
first, and the result is placed on the stack as the argument for SIN.
This process creates a problem for functions that require symbolic arguments. For example, the
integration function requires as one of its arguments a name specifying the variable of integration.
If evaluating an integral expression caused the name to be evaluated, the result of evaluation
would be left on the stack for the integral, rather than the name itself. To avoid this problem, the
calculator automatically (and invisibly) quotes such arguments. When the quoted argument is
evaluated, the unquoted argument is returned.
If a user-defined function takes symbolic arguments, quote the arguments using QUOTE.
…µQUOTE
Level 1/Argument 1
Example:
Level 1/Item 1
→
'name'
→
{ name1 name2 ... }
→
:nport : 'global'
CR, DELAY, OLDPRT, PR1, PRLCD, PRST, PRSTC
See also:
3-180 Full Command and Function Reference
Level 1/Argument 2
'symb1'
'global'
COLCT, EXPAN, ISOL, SHOW, SOLVE
Level 1/Item 1
→
obj
obj
The following user-defined function ArcLen calculates the arc length of a function:
« → start end expr var
« start end expr var ˆ SQ 1 + ƒ var »
»
`OArcLen K
To use this user-defined function in an algebraic expression, the symbolic arguments must be
quoted:
'ArcLen(0,π,QUOTE(SIN(X)),QUOTE(X))'
APPLY, | (Where)
Full Command and Function Reference 3-189
PTAYL
Type:
Description:
Returns the Taylor polynomial at x = a for a specified polynomial.
Access:
Arithmetic, !Þ POLYNOMIAL LL
Input:
Level 2/Argument 1: A polynomial, P.
Level 1/Argument 2: A number, a.
Output:
A polynomial, Q such that Q(x – a)=P(x).
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
PTPROP
Type:
Description:
Access:
Flags:
Input/Output:
Example 1:
Example 2:
See also:
PURGE
Type:
Description:
PX→C
Type:
Description:
Function
Access:
Input/Output:
Level 1/Argument 1
{ #n #m }
See also:
→Q
Type:
Description:
Find the polynomial Q(x) such that
Q(x-2)=x2+3x+2.
PTAYL(X^2+3*X+2, 2)
X^2+7*X+12
Function
Returns the specified property for the specified element. It takes the element’s atomic number or
symbol as a name (with certain restrictions) and the property number. It returns the property,
usually a value or a string. It chooses to use or not use units according to the Units Usage flag
(flag 61: SI units if clear, no units if set). If you use PTPROP as an algebraic function, you must
use the symbol to define the element — you can’t use its atomic number.
See Appendix B for a full list of available properties.
G PERIODIC TABLE PTPROP
Units Usage (61)
Level 2
Level 1
'symb'
x
Level 1
→
“string” or x or x_unit or 'name'
→
y
x
“string” or x or x_unit or 'name'
The command sequence 'Hg' 6 PTPROP returns "[Xe]4f14·5d10·6s2".
The command sequence 79 8 PTPROP returns 1337.58 when flag 61 is set.
MOLWT, PERINFO, PERTBL
Command
Purge Command: Purges the named variables or empty subdirectories from the current directory.
PURGE executed in a program does not save its argument for recovery by LASTARG.
To empty a named directory before purging it, use PGDIR.
To help prepare a list of variables for purging, use VARS.
Purging PICT replaces the current graphics object with a 0 × 0 graphics object.
If a list of objects (with global names, backup objects, library objects, or PICT) for purging
contains an invalid object, then the objects preceding the invalid object are purged, and the error
Bad Argument Type occurs.
To purge a library or backup object, tag the library number or backup name with the appropriate
port number (:nport), which must be in the range from 0 to 3. For a backup object, the port
3-182 Full Command and Function Reference
Command
Pixel to Complex Command: Converts the specified pixel coordinates to user-unit coordinates.
The user-unit coordinates are derived from the (xmin, ymin) and (xmax, ymax) parameters in the
reserved variable PPAR. The coordinates correspond to the geometrical center of the pixel.
( °is the left-shift of the Nkey).
!°LPICT LPX→C
Level 1/Item 1
→
(x,y)
C→PX
Command
To Quotient Command: Returns a rational form of the argument.
The rational result is a “best guess”, since there might be more than one rational expression
consistent with the argument. →Q finds a quotient of integers that agrees with the argument to
within the number of decimal places specified by the display format mode.
→Q also acts on numbers that are part of algebraic expressions or equations.
Access:
„Ú REWRITE L→Q
(Ú is the left-shift of the 6key).
Flags:
Number Display Format (–45 to –50)
Input/Output:
Level 1/Argument 1
Example:
See also:
→Qπ
Type:
Description:
Access:
Flags:
x
(x,y)
'symb1'
'Y+2.5' →Q returns 'Y+5/2'
→Qπ, /, XQ
Level 1/Item 1
→
→
→
'a/b'
'a/b + c/d*i'
'symb2'
Command
To Quotient Times π Command: Returns a rational form of the argument, or a rational form of
the argument with π, square roots, natural logs, and exponentials factored out, whichever yields
the smaller denominator.
The rational result is a “best guess”, since there might be more than one rational expression
consistent with the argument. →Qπ finds a quotient of integers that agrees with the argument to
the number of decimal places specified by the display format mode.
→Qπ also acts on numbers that are part of algebraic expressions or equations.
For a complex argument, the real or imaginary part (or both) can have π as a factor.
„Ú REWRITE L →Qπ
(Ú is the left-shift of the 6key).
Number Display Format (–45 to –50)
Full Command and Function Reference 3-187
Input/Output:
Input/Output:
Level 3/Argument 1
Level 2/Argument 2
Level 1/Argument 3
Level 1/Item 1
[[ matrix ]]1
nposition
zput
→
[[ matrix ]]2
[[ matrix ]]1
{ nrow mcol }
zput
→
[[ matrix ]]2
'namematrix'
nposition
zput
→
'namematrix'
{ nrow mcol }
zput
→
[ vector ]1
nposition
zput
→
[ vector ]2
[ vector ]1
{ nposition }
zput
→
[ vector ]2
'namevector'
nposition
zput
→
'namevector'
{ nposition }
zput
→
{ list }1
nposition
objput
→
{ list }2
{ list }1
{ nposition }
objput
→
{ list }2
→
nposition
objput
→
'namelist'
{ nposition }
objput
This command sequence:
[[ 2 3 4 ][ 4 1 2 ]] { 1 3 } 96 PUT returns
[[ 2 3 96 ][ 4 1 2 ]].
The command sequence:
[[ 2 3 4 ][ 4 1 2 ]] 5 96 PUT returns [[ 2 3 4 ][ 4 96 2 ]].
The command sequence:
{ A B C D E } { 3 } 'Z' PUT returns { A B Z D E }.
GET, GETI, PUTI
L3/A1
'namelist'
Example 1:
Example 2:
Example 3:
See also:
PUTI
Type:
Description:
Access:
Flags:
Command
Put and Increment Index Command: Replaces the object at a specified position (second input) in
a specified array or list (first input) with a specified object (third input), returning a new array or
list together with the next position in the array or list.
For matrices, the position is incremented in row order.
Unlike PUT, PUTI returns a named array or list. This enables a subsequent execution of PUTI at
the next position of a named array or list.
!°LIST ELEMENTS PUTI
( °is the left-shift of the Nkey).
Index Wrap Indicator (–64)
L2/A2
L1/A3
[[ matrix ]]1
nposition1
zput
→
[[ matrix ]]2
nposition2
[[ matrix ]]1
{ nrow mcol }1
zput
→
[[ matrix ]]2
{ nrow mcol }2
L1/I2
'namematrix'
nposition1
zput
→
'namematrix'
nposition2
'namematrix'
{ nrow mcol }1
zput
→
'namematrix'
{ nrow mcol }2
[ vector ]1
nposition1
zput
→
[ vector ]2
nposition2
[ vector ]2
{ nposition2 }
[ vector ]1
{ nposition1 }
zput
→
'namevector'
nposition1
zput
→
'namevector'
nposition2
'namevector'
{ nposition1 }
zput
→
'namevector'
{ nposition2 }
{ list }1
nposition1
objput
→
{ list }2
nposition2
{ list }1
{ nposition1 }
objput
→
{ list }2
{ nposition2 }
'namelist'
nposition1
objput
→
'namelist'
nposition2
'namelist'
{ nposition1 }
objput
→
'namelist'
{ nposition2 }
L = Level; A = Argument; I = item
Example:
See also:
PVAR
Type:
Description:
The following program uses PUTI and flag –64 to replace A, B, and C in the list with X.
« { A B C } DO 'X' PUTI UNTIL -64 FS? END »
GET, GETI, PUT
Command
Population Variance Command: Calculates the population variance of the coordinate values in
each of the m columns in the current statistics matrix (ΣDAT).
The population variance (equal to the square of the population standard deviation) is returned as a
vector of m real numbers, or as a single real number if m = 1. The population variances are
computed using this formula:
n
2
1
--- ∑ ( x k – x )
nk = 1
where xk is the kth coordinate value in a column, x is the mean of the data in this column, and n is
the number of data points.
Access:
…µ PVAR
Input/Output:
Level 1/Argument 1
See also:
PVARS
Type:
Description:
3-184 Full Command and Function Reference
L2/I1
Level 1/Item 1
→
xpvariance
→
[ xpvariance1, ...,xpvariancem ]
MEAN, PCOV, PSDEV, SDEV, VAR
Command
Port-Variables Command: Returns a list of the backup objects (:nport:name) and the library objects
(:nport:nlibrary) in the specified port. Also returns the available memory size (RAM).
The port number, nport, must be in the range from 0 to 2.
Full Command and Function Reference 3-185
Flags:
Example:
Command:
Result:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Complex mode must be set (flag –103 set) if either input contains complex terms.
Obtain the resultant of the two polynomials
x3-px+q and 3x2-p.
27*Q^2-4*P^3
REVLIST
Type:
Command
Description:
Reverse List Command: Reverses the order of the elements in a list.
Access:
!°LIST PROCEDURES REVLIST ( °is the left-shift of the Nkey).
Input/Output:
Level 1/Argument 1
See also:
Level 1/Argument 1
Level 1/Item 1
→
{ obj1 ... objn }
SORT
Command
Description:
Displays a menu or list of CAS operations that rewrite expressions.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
Command
Spherical Mode Command: Sets spherical coordinate mode.
SPHERE sets flags –15 and –16.
In spherical mode, vectors are displayed as polar components.
Access:
„&H ANGLE SPHERE
Input/Output: None
See also:
CYLIN, RECT
SQ
Type:
Description:
Analytic function
Square Analytic Function: Returns the square of the argument.
The square of a complex argument (x, y) is the complex number (x2 – y2, 2xy).
Matrix arguments must be square.
Access:
!º
Flags:
Numerical Results (–3)
Input/Output:
RISCH
Function
Description:
Performs symbolic integration on a function using the Risch algorithm. RISCH is similar to the
INTVX command, except that it allows you to specify the variable of integration.
Access:
Input:
Calculus !Ö DERIV. & INTEG L.
Level 2/Argument 1: The function to integrate.
Level 1/Argument 2: The variable of integration.
The antiderivative of the function with respect to the variable.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Output:
Flags:
Example:
Find the antiderivative of the following function, with respect to y:
See also:
SR
Type:
Description:
Access:
Flags:
Input/Output:
See also:
3-202 Full Command and Function Reference
z2
x_unit
→
x2_unit2
[[ matrix ]]
→
[[ matrix × matrix ]]
'symb'
→
'SQ(symb)'
!´ BASE L BIT SR
( ´ is the left-shift of the Pkey).
…ã L BIT SR
(ã is the right-shift of the 3key).
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Level 1/Argument 1
RISCH(Y^2-3*Y+2,Y)
IBP, INT, INTVX
→
Command
Shift Right Command: Shifts a binary integer one bit to the right.
The least significant bit is shifted out to the right and lost, while the most significant bit is
regenerated as a zero. SR is equivalent to binary division by 2.
2
1/3*Y^3-3*(1/2*Y^2)+2*Y
Level 1/Item 1
z
√, ^
y + 3y + 2
Command:
Result:
( º is the left-shift of the Rkey).
Level 1/Argument 1
ALGB, ARIT, CONSTANTS, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR,
MODULAR, POLYNOMIAL, TESTS, TRIGO
Type:
{ list }2
REVLIST
SPHERE
Type:
Description:
REWRITE
Type:
Level 1/Item 1
→
{ list }1
See also:
RESULTANT(X^3-P*X+Q, 3*X^2-P)
{ objn ... obj1 }
Input/Output:
#n1
Level 1/Item 1
→
See also:
ASR, SL, SLB, SRB
SRAD
Type:
Description:
Command
Spectral Radius Command: Returns the spectral radius of a square matrix.
#n2
Full Command and Function Reference 3-231
• error displays the absolute error for that step. A zero error indicates that the Runge–Kutta–
Fehlberg method failed and that Euler’s method was used instead.
The absolute error is the absolute value of the estimated error for a scalar problem, and the row
(infinity) norm of the estimated error vector for a vector problem. (The latter is a bound on the
maximum error of any component of the solution.)
L2/A1
L1/A2
{ list }
h
→
L4/I1
L3/I2
L2/I3
L1/I4
{ list }
h
ydelta
error
Command
Next Solution Step for RKF Command: Computes the next solution step (hnext) to an initial value
problem for a differential equation.
The arguments and results are as follows:
• { list } contains three items in this order: the independent (t) and solution (y) variables, and the
right-hand side of the differential equation (or a variable where the expression is stored).
• xtol sets the tolerance value.
• h specifies the initial candidate step.
• hnext is the next candidate step.
The independent and solution variables must have values stored in them. RKFSTEP steps these
variables to the next point upon completion.
Note that the actual step used by RKFSTEP will be less than the input value h if the global error
tolerance is not satisfied by that value. If a stringent global error tolerance forces RKFSTEP to
reduce its stepsize to the point that the Runge–Kutta–Fehlberg methods fails, then RKFSTEP
will use the Euler method to compute the next solution step and will consider the error tolerance
satisfied. The Runge-Kutta-Fehlberg method will fail if the current independent variable is zero
and the stepsize ≤ 1.3 × 10-498 or if the variable is nonzero and the stepsize is 1.3 × 10-10 times its
magnitude.
{ list }
L2/An
L1/An+1
xtol
h
→
L3/I1
L2/I2
L1/I3
{ list }
xtol
hnext
L = Level; A = Argument; I = item
Access:
Flags:
→
xspectralnorm
Finds zeros of an expression equated to 0, or solves an equation.
Symbolic solve, !Î, P SOLVE, …×L
Input:
Level 2/Argument 1: The expression or equation. A list of equations and expressions can be
given too, each will be solved for the same variable.
Level 1/Argument 2: The variable to solve for.
Output:
A zero or solution, or a list of zeros or solutions.
Flags:
Radians mode must be set (flag –17 set).
If exact mode is set (flag –105 clear) and there are no exact solutions, the command returns a null
list even when there are approximate solutions.
Radians mode must be set (flag –17 set).
If complex mode is set (flag –103 set) then SOLVE will search for complex roots as well as real
ones. Complex roots are displayed according to the coordinate system selected.
Example 1:
Find the zeros of the following expression:
3
x –x–9
Command:
Result:
Example 2:
Command:
3-204 Full Command and Function Reference
SOLVE(X^3-X-9,X)
X=2.24004098747
Find the real and complex roots of the two equations:
4
2
x – 1=3 ,
x – A= 0
Clear numeric mode, clear approximate mode, set complex mode, set rectangular mode, enter:
SOLVE({X^4-1=3,X^2-A=0},X)
Result:
{{X=√2×i,X=√2×-1,X=-(√2×i),X=√2},
{X=√A×-1,X=√A}} Note that in this case, imaginary solutions for X are returned, even if X is in
REALASSUME.
SOLVEQN
Type:
Description:
RKF, RKFERR, RRK, RRKSTEP, RSBERR
Command
Rotate Left Command: Rotates a binary integer one bit to the left.
The leftmost bit of #n1 becomes the rightmost bit of #n2.
… ãBIT RL
(ã is the right-shift of the 3key).
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Command
Access:
See also:
L3/A1
RL
Type:
Description:
Level 1/Item 1
[ array ]
ABS, CNRM, COND, RNRM, SRAD, TRACE
Description:
RKF, RKFSTEP, RRK, RRKSTEP, RSBERR
Access:
…µ RKFS
Input/Output:
See also:
See also:
Type:
L = Level; A = Argument; I = item
RKFSTEP
Type:
Description:
Level 1/Argument 1
SOLVE
Access:
…µ RKFE
Input/Output:
See also:
Input/Output:
Access:
Flags:
Flags:
DESOLVE, LDEC, LINSOLVE, MSLV, QUAD, SOLVEVX
Command
Starts the appropriate solver for a specified set of equations.
SOLVEQN sets up and starts the appropriate solver for the specified set of equations, bypassing
the Equation Library catalogs. It sets EQ (and Mpar if more than one equation is being solved),
sets the unit options according to flags 60 and 61, and starts the appropriate solver.
SOLVEQN uses subject and title numbers (levels 3 and 2) and a “PICT” option (level 1) and
returns nothing. Subject and title numbers are listed in chapter 5. For example, a 2 in level 3 and a
9 in level 2 would specify the Electricity category and Capacitive Energy set of equations. If the
“PICT” option is 0, PICT is not affected; otherwise, the equation picture (if any) is copied into
PICT.
…µ SOLVEQN
Unit Type (60), Units Usage (61)
Units Type (60), Units Usage (61)
Full Command and Function Reference 3-229
See also:
RNRM
Type:
Description:
Access:
TRNC
Input/Output:
Level 1/Argument 1
Command
Row Norm Command: Returns the row norm (infinity norm) of its argument array.
The row norm is the maximum (over all rows) of the sums of the absolute values of all elements
in each row. For a vector, the row norm is the largest absolute value of any of its elements.
!Ø OPERATIONS LRNRM ( Ø is the left-shift of the 5key).
!´ MATRIX NORMALIZE RNRM ( ´ is the left-shift of the Pkey).
Input/Output:
Level 1/Argument 1
See also:
ROLL
Type:
Description:
Level 1/Item 1
→
[ array ]
CNRM, CROSS, DET, DOT
See also:
RPL command
Roll Objects Command: Moves the contents of a specified level to level 1, and rolls upwards the
portion of the stack beneath the specified level.
In RPN mode, 3 ROLL is equivalent to ROT.
Access:
!°STACK LROLL
Input/Output:
Ln+1... L2
objn ... obj1
( °is the left-shift of the Nkey).
Access:
L1
→
n
Ln ...
L2
L1
objn–1 ...
obj1
objn
L = Level
See also:
ROLLD
Type:
Description:
L1
n (obj1)
→
Ln
Ln–1 ...
L1
obj1
objn ...
obj2
L = Level
OVER, PICK, ROLL, ROT, SWAP
ROMUPLOAD
Type:
Command
Description:
This command remains from earlier HP graphing calculators and should not be used. It was used
to transfer the ROM from one HP 49G to another.
Access:
…µ ROMUPLOAD
3-206 Full Command and Function Reference
n
{ list }
→
n
[ vector ]
→
{n}
[[ matrix ]]
→
{ n m}
'symb'
→
grob
→
#nwidth
#mheight
→
#nwidth
#mheight
n
→
n
Command
Shift Left Command: Shift a binary integer one bit to the left.
The most significant bit is shifted out to the left and lost, while the least significant bit is
regenerated as a zero. SL is equivalent to binary multiplication by 2, truncated to the current
wordsize.
!´ BASE LBIT SL
( ´ is the left-shift of the Pkey).
…ãL BIT SL
(ã is the right-shift of the 3key).
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output:
#n1
( °is the left-shift of the Nkey).
Ln+1... L2
n
→
Level 1/Argument 1
RPL command
Roll Down Command: Moves the contents of level 2 to a specified level, n, and rolls downward
the portion of the stack beneath the specified level.
objn ... obj2
→
integer
x_unit
CHR, NUM, POS, REPL, SUB
OVER, PICK, ROLLD, ROT, SWAP
Access:
!°STACK LROLLD
Input/Output:
See also:
SL
Type:
Description:
Level 1/Item 2
“string”
PICT
xrow norm
Level 2/Item 1
See also:
SLB
Type:
Description:
Access:
Flags:
Input/Output:
Level 1/Item 1
→
Command
Shift Left Byte Command: Shifts a binary integer one byte to the left.
The most significant byte is shifted out to the left and lost, while the least significant byte is
regenerated as zero. SLB is equivalent to binary multiplication by 28 (256) (or executing SL eight
times), truncated to the current wordsize.
!´ BASE LBYTE SLB
( ´ is the left-shift of the Pkey).
(ã is the right-shift of the 3key).
…ãL BYTE SLB
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Level 1/Argument 1
#n1
See also:
#n2
ASR, SLB, SR, SRB
Level 1/Item 1
→
#n2
ASR, SL, SR, SRB
SLOPEFIELD
Type:
Command
Description:
SLOPEFIELD Plot Type Command: Sets the plot type to SLOPEFIELD.
Full Command and Function Reference 3-227
ROW+
Type:
Description:
Access:
See also:
Command
Insert Row Command: Inserts an array into a matrix (or one or more numbers into a vector) at
the position indicated by nindex, and returns the modified matrix (or vector).
The inserted array must have the same number of columns as the target array.
nindex is rounded to the nearest integer. The original array is redimensioned to include the new
columns or elements, and the elements at and below the insertion point are shifted down.
!Ø
( Ø is the left-shift of the 5key).
CRREATE ROW ROW+
!´ MATRIX ROW ROW+
( ´ is the left-shift of the Pkey).
Input/Output:
See also:
ROW→
Type:
Description:
Access:
Level 3/Argument 1
Level 2/Argument 2
Level 1/Argument 3
[[ matrix ]]1
[[ matrix ]]2
nindex
→
[[ matrix ]]3
[[ matrix ]]1
[ vector ]row
nindex
→
[[ matrix ]]2
nelement
nindex
→
[ vector ]2
[ vector ]1
COL–, COL+, ROW–, RSWP
!´ MATRIX ROW ROW→
SIMPLIFY
Type:
Simplifies an expression.
Access:
!Ú
Input:
An expression
Output:
An equivalent simplified expression. SIMPLIFY follows an extensive built-in set of rules, but
these might not give exactly the simplification the user expects.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Example:
Command:
Result:
Simplify
4*COS(X)^2 - 2
See also:
COLLECT, EXPAND
SIN
Type:
Description:
( ´ is the left-shift of the Pkey).
Input/Output:
Ln+1/A1 7
L2/An
L1/An+1
[ vector ]row 1 +
[ vector ]row n
nrow count
→
Level 1/Item 1
[[ matrix ]]
element1 +
elementn
nelement count
→
[ vector ]column
Command
Description:
Level 1/Item 1
Command
Rows to Matrix Command: Transforms a series of row vectors and a row count into a matrix
containing those rows, or transforms a sequence of numbers and an element count into a vector
with those numbers as elements.
( Ø is the left-shift of the 5key).
!Ø CREATE ROW ROW→
EGCD
Access:
Flags:
Input/Output:
REWRITE L
SI ( 3 ⋅ X ) + SI ( 7 ⋅ X )
---------------------------------------------------------SI ( 5 ⋅ X )
SIMPLIFY((SIN(3*X)+SIN(7*X))/SIN(5*X))
Analytic function
Sine Analytic Function: Returns the sine of the argument.
For real arguments, the current angle mode determines the number’s units, unless angular units
are specified.
For complex arguments, sin(x + iy) = sinx coshy + i cosx sinhy.
If the argument for SIN is a unit object, then the specified angular unit overrides the angle mode
to determine the result. Integration and differentiation, on the other hand, always observe the
angle mode. Therefore, to correctly integrate or differentiate expressions containing SIN with a
unit object, the angle mode must be set to radians (since this is a “neutral” mode).
S
Numerical Results (–3), Angle Mode (–17, –18)
L = Level; A = Argument; I = item
See also:
→ROW
Type:
Description:
Access:
Level 1/Argument 1
→COL, COL→, →ROW
z
→
sin z
x_unitangular
→
sin(x_unitangular)
'symb'
→
'SIN(symb)'
Command
Matrix to Rows Command: Transforms a matrix into a series of row vectors, returning the
vectors and row count, or transforms a vector into its elements, returning the elements and
element count.
!Ø CREATE ROW →ROW
( Ø is the left-shift of the 5key).
Type:
Command
!´ MATRIX ROW →ROW
Description:
Converts complex logarithmic and exponential expressions to expressions with trigonometric
terms.
( ´ is the left-shift of the Pkey).
See also:
L1/Argument1
[[ matrix ]]
→
[ vector ]
→
Ln+1/I1 7 L2/In
L1/In+1
Access:
Trigonometry, …ÑL, PLEXPLN
[ vector ]row n … [ vector ]row n
nrowcount
Input:
An expression with complex linear and exponential terms.
nelementcount
Output:
The expression with logarithmic and exponential subexpressions converted to trigonometric and
inverse trigonometric expressions.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
element1 … elementn
L =Level; A = Argument; I = Item
→COL, COL→, ROW→
3-208 Full Command and Function Reference
ASIN, COS, TAN
SINCOS
Input/Output:
See also:
Level 1/Item 1
Full Command and Function Reference 3-225
G(x + 1) – G(x) = f(x)
where x is the specified variable.
rref
Type:
Command
Description:
Reduces a matrix to row-reduced echelon form, and provides a list of pivot points.
Access:
!ÖDERIV L
Access:
PSOLVE, Matrices, !Ø
Input:
Input:
A matrix.
Level 2/Argument 1: A function
Level 1/Argument 2: The variable to calculate the antiderivative with respect to.
Level 2/Item 1: The pivot points.
Output:
Output:
The discrete antiderivative of the function.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Obtain the discrete antiderivative with respect to the variable y of the expression:
2x-2y
LINEAR SYSTEMS
Level 1/Item 2: An equivalent matrix in row reduced echelon form.
Flags:
Example:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear)
If flag –126 is clear (the default), row reduction is done with the last column. If the flag is set, row
reduction is done without reducing the last column, but the last column will be modified by the
reduction of the rest of the matrix.
Reduce to row-reduced echelon form, and find the pivot points, for the matrix:
2 1
3 4
Command:
Result:
Command:
Result:
See also:
SIGMA(2*X-2*Y,Y)
-(Y^2 –(2*X+1)*Y)
SIGMAVX, RISCH
SIGMAVX
rref([[2,1][3,4]])
Type:
Function
{Pivots: {5,1.,2,1.},[[10,0][0,5]]}
Description:
Calculates the discrete antiderivative of a function f with respect to the current variable. This is a
function G such that:
G(x + 1) – G(x) = f(x)
where x is the current variable.
See also:
RREFMOD
RREF
Type:
Description:
Command
Access:
!ÖDERIV LL
Reduces a matrix to row-reduced echelon form. The reduction is carried out completely, so a
square matrix is reduced to an identity matrix. Step-by-step mode can be used to show how the
reduction proceeds.
Input:
Level 1/Argument 1: A function.
Output:
The discrete antiderivative of the function.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Obtain the discrete antiderivative with respect to the current variable x of the expression:
2x-2y
Access:
Matrices, !Ø LINEAR SYSTEMS, !´ MATRX
Input:
A matrix.
Output:
An equivalent matrix in row reduced echelon form.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Step-by-step mode can be set (flag –100 set).
Example:
Command:
Result:
See also:
FACTR
Solve the system of linear equations:
3x + 4y = 5
5x + 6y = 7
by reducing the augmented matrix that represents this system.
RREF([[3, 4, 5] [ 5, 6, 7]])
[[1, 0, -1] [0, 1, 2]]
This reduced matrix represents the system:
1x + 0y = –1
0x + 1y = 2
so that the solution is x = –1, y = 2 .
rref, RREFMOD
Command:
Result:
See also:
SIGN
Type:
Description:
SIGMAVX(2*X-2*Y)
X^2 –(2*Y+1)*X
SIGMA, RISCH
Function
Sign Function: Returns the sign of a real number argument, the sign of the numerical part of a
unit object argument, or the unit vector in the direction of a complex number argument.
For real number and unit object arguments, the sign is defined as +1 for positive arguments, –1
for negative arguments. In exact mode, the sign for argument 0 is undefined (?). In approximate
mode, the sign for argument 0 is 0. SIGN in the !´menu returns the sign of a number, while
SIGN in the …ß menu returns the unit vector of a complex number.
For a complex argument:
x
iy
SIGN ( x + iy ) = --------------------- + --------------------2
2
2
2
x +y
x +y
3-210 Full Command and Function Reference
Full Command and Function Reference 3-223
The derivative of the function with respect to y (∂f/∂y) is –4y, and the derivative of the function
− 2t
with respect to t (∂f/∂t) is
.
(1 + t 2 ) 2
1. Store the independent variable’s initial value, 0, in T.
2. Store the dependent variable’s initial value, 0, in Y.
1
3. Store the expression,
− 2 y 2 , in F.
1+ t 2
4. Store ∂f/∂y, –4y, in FY.
− 2t
5. Store ∂f/∂t,
, in FT.
(1 + t 2 ) 2
6. Enter these five items in a list: { T Y F FY FT }.
7. Enter the tolerance. Use estimated decimal place accuracy as a guideline for choosing a
tolerance: 0.00001.
8. Enter the final value for the independent variable: 8.
The stack should look like this:
{ T Y F FY FT }
See also:
RRKSTEP
Type:
Description:
.00001
8
9. Press RRK. The variable T now contains 8, and Y now contains the value .123077277659.
The actual answer is .123076923077, so the calculated answer has an error of approximately
.00000035, well within the specified tolerance.
RKF, RKFERR, RKFSTEP, RRKSTEP, RSBERR
Command
Next Solution Step and Method (RKF or RRK) Command: Computes the next solution step
(hnext) to an initial value problem for a differential equation, and displays the method used to arrive
at that result.
The arguments and results are as follows:
• { list } contains five items in this order:
– The independent variable (t).
– The solution variable (y).
– The right-hand side of the differential equation (or a variable where the expression is stored).
– The partial derivative of y'(t) with respect to the solution variable (or a variable where the
expression is stored).
– The partial derivative of y'(t) with respect to the independent variable (or a variable where the
expression is stored).
• xtol is the tolerance value.
• h specifies the initial candidate step.
• last specifies the last method used (RKF = 1, RRK = 2). If this is the first time you are using
RRKSTEP, enter 0.
• current displays the current method used to arrive at the next step.
• hnext is the next candidate step.
The independent and solution variables must have values stored in them. RRKSTEP steps these
variables to the next point upon completion.
Note that the actual step used by RRKSTEP will be less than the input value h if the global error
tolerance is not satisfied by that value. If a stringent global error tolerance forces RRKSTEP to
reduce its stepsize to the point that the Runge–Kutta–Fehlberg or Rosenbrock methods fails, then
3-212 Full Command and Function Reference
Level 1/Argument 3: The order for the series expansion. The minimum value is 2, and the
maximum value is 20.
Output:
Level 2/Item 1: A list containing the limit as a value and as the equivalent expression, an
expression approximating the function near the limit point, and the order of the remainder. These
are expressed in terms of a small parameter h.
Level 1/Item 2: An expression for h in terms of the original variable.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
Obtain the second order Taylor series expansion of ln(x) at x=1.
See also:
TAYLOR0
SERIES(LN(X),1,2)
{{Limit: 0, Equiv: h, Expans: -1/2*h^2+h, Remain: h^3}, h=X- 1}
SERVER
Type:
Description:
Command
Server Mode Command: Selects Kermit Server mode.
A Kermit server (a Kermit device in Server mode) passively processes requests sent to it by the
local Kermit. The server receives data in response to SEND, transmits data in response to
KGET, terminates Server mode in response to FINISH or LOGOUT, and transmits a directory
listing in response to a generic directory request.
Access:
…µ SERVER
Flags:
I/O Device (–33), I/O Data Format (–35), RECV Overwrite (–36), I/O Messages (–39), I/O
Device for Wire (–78)
Input/Output: None
See also:
BAUD, CKSM, FINISH, KERRM, KGET, PARITY, PKT, RECN, RECV, SEND, TRANSIO
SEVAL
Type:
Function
Description:
Simplifies the given expression. Simplifies the expression except at the highest level, and also
evaluates any existing variables that the expression contains and substitutes these back into the
expression.
Access:
Catalog, …µ
Input:
Level 1/Argument 1: An algebraic expression.
Output:
The expression simplified and with existing variables evaluated.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
With π stored in the variable Y, and the variables X and Z not in the current path, simplify the
following expression. Note that the top-level simplification is not carried out.
Sin(3x – y + 2z – (2x – z)) – Sin(x – 2y + (y + 3z))
Command:
Result:
SEVAL(SIN(3*X-Y+2*Z-(2*X-Z)) - SIN(X-2*Y+(Y+3*Z))
See also:
EXPAND, SIMPLIFY
SF
Type:
Description:
Command
Set Flag Command: Sets a specified user or system flag.
-SIN(π –(X+3*Z)) -SIN(π –(X+3*Z))
Full Command and Function Reference 3-221
• B and Z must both be vectors or both be matrices.
• B and Z must have the same number of columns if they are matrices.
RSD is typically used for computing a correction to Z, where Z has been obtained as an
approximation to the solution X to the system of equations AX = B.
Access:
!Ø
OPERATIONS LRSD
( Ø is the left-shift of the 5key).
!´ MATRIX LRSD
( ´ is the left-shift of the Pkey).
Access:
…µ SCLΣ
Input/Output: None
See also:
AUTO, SCATRPLOT
SCONJ
Type:
Description:
Input/Output:
Level 3/Argument 1
See also:
RSWP
Type:
Description:
Access:
Level 2/Argument 2
Level 1/Argument 3
Level 1/Item 1
[ vector ]B
[[ matrix ]]A
[ vector ]Z
→
[[ matrix ]]B
[[ matrix ]]A
[[ matrix ]]Z
→
[ vector ]B–AZ
[[ matrix ]]B–AZ
Access:
Input/Output:
Command
Store Conjugate Command: Conjugates the contents of a named object.
The named object must be a number, an array, or an algebraic object. For information on
conjugation, see CONJ.
!°MEMORY ARITHMETIC LSCONJ ( °is the left-shift of the Nkey).
Level 1/Argument 1
DET, IDN
See also:
Command
Row Swap Command: Swaps rows i and j of a matrix and returns the modified matrix, or swaps
elements i and j of a vector and returns the modified vector.
Row numbers are rounded to the nearest integer. Vector arguments are treated as column vectors.
( Ø is the left-shift of the 5key).
!Ø CREATE ROW LRSWP
!´ MATRIX ROW LRSWP
( ´ is the left-shift of the Pkey).
SCROLL
Type:
Description:
CONJ, SINV, SNEG
Command
Displays any object. This is the programmable equivalent of pressing I%VIEW% and is the best
way to view any object larger than the screen, such as complicated algebraic expressions.
Access:
…µ SCROLL
Input/Output:
Input/Output:
Level 1/Argument 1
Level 3/Argument 1
Level 2/Argument 2
Level 1/Argument 3
Level 1/Item 1
[[ matrix ]]1
nrow i
nrow j
→
[[ matrix ]]2
nelement i
nelement j
→
[ vector ]2
See also:
[ vector ]1
CSWP, ROW+, ROW–
RULES
Type:
Description:
Access:
Input/Output:
Command
Displays a list of names of individuals involved with the HP 49G calculator project.
…µ RULES
None
R→B
Type:
Description:
Command
Real to Binary Command: Converts a positive real to its binary integer equivalent.
For any value of n ≤ 0, the result is # 0. For any value of n ≥ 1.84467440738E19 (base 10), the
result is # FFFFFFFFFFFFFFFF (base 16).
Level 1/Argument 1
n
B→R
3-214 Full Command and Function Reference
Level 1/Item 1
→
#n
Level 1/Item 1
→
Grob
SDEV
Type:
Description:
Command
Standard Deviation Command: Calculates the sample standard deviation of each of the m
columns of coordinate values in the current statistics matrix (reserved variable ΣDAT).
SDEV returns a vector of m real numbers, or a single real number if m = 1. The standard
deviation (the square root of the variances) is computed using this formula:
2
1 n
------------ ∑ ( x i – x )
n – 1i = 1
where xi is the ith coordinate value in a column,
the number of data points.
x
is the mean of the data in this column, and n is
Access:
…µ SDEV
Input/Output:
Access:
…ãR→B
(ã is the right-shift of the 3key).
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output:
See also:
Level 1/Item 1
→
'name'
Level 1/Argument 1
Level 1/Item 1
→
xsdev
→
[ xsdev 1 xsdev 2 ... xsdev m ]
See also:
MAXΣ, MEAN, MINΣ, PSDEV, PVAR, TOT, VAR
SEND
Type:
Description:
Command
Send Object Command: Sends a copy of the named objects to a Kermit device.
Full Command and Function Reference 3-219
Executing SCALEW changes the x-axis display range—the xmin and xmax components of the first
two complex numbers in the reserved variable PPAR. The plot origin (the user-unit coordinate of
the center pixel) is not changed.
Input/Output:
Level 2/Argument 1
Example 1:
Example 2:
Example 3:
See also:
Level 1/Argument 2
obj1
obj2
{ A B } (4,5) SAME returns 0.
{ A B } { B A } SAME returns 0.
"CATS" "CATS" SAME returns 1.
TYPE, ==
Level 1/Item 1
→
0/1
Level 1/Argument 1
xfactor
See also:
SBRK
Type:
Description:
Command
Serial Break Command: Interrupts serial transmission or reception.
SBRK is typically used when a problem occurs in a serial data transmission.
Access:
…µ SBRK
Flags:
I/O Device (–33), I/O Device for Wire (–78)
Input/Output: None
See also:
BUFLEN, SRECV, STIME, XMIT
SCALE
Type:
Description:
Command
Scale Plot Command: Adjusts the first two parameters in PPAR, (xmin, ymin) and (xmax, ymax), so
that xscale and yscale are the new plot horizontal and vertical scales, and the center point doesn’t
change.
The scale in either direction is the number of user units per tick mark. The default scale in both
directions is 1 user-unit per tick mark.
Access:
…µ SCALE
Input/Output:
Level 2/Argument 1
See also:
SCALEH
Type:
Description:
Access:
Input/Output:
Level 1/Argument 2
xscale
yscale
AUTO, CENTR, SCALEH, SCALEW
Level 1/Item 1
→
Command
Multiply Height Command: Multiplies the vertical plot scale by xfactor.
Executing SCALEH changes the y-axis display range — the ymin and ymax components of the first
two complex numbers in the reserved variable PPAR. The plot origin (the user-unit coordinate of
the center pixel) is not changed.
…µSCALEH
Level 1/Argument 1
xfactor
Level 1/Item 1
→
See also:
AUTO, SCALEW, YRNG
SCALEW
Type:
Description:
Command
Multiply Width Command: Multiplies the horizontal plot scale by xfactor.
3-216 Full Command and Function Reference
Access:
…µSCALEW
Input/Output:
Level 1/Item 1
→
AUTO, SCALEH, XRNG
SCATRPLOT
Type:
Command
Description:
Draw Scatter Plot Command: Draws a scatterplot of (x, y) data points from the specified columns
of the current statistics matrix (reserved variable ΣDAT ).
The data columns plotted are specified by XCOL and YCOL, and are stored as the first two
parameters in the reserved variable ΣPAR. If no data columns are specified, columns 1
(independent) and 2 (dependent) are selected by default. The y-axis is autoscaled and the plot type
is set to SCATTER.
When SCATRPLOT is executed from a program, the resulting display does not persist unless
PICTURE or PVIEW is subsequently executed.
Access:
…µ SCATRPLOT
Input/Output: None
Example: The following program plots a scatter plot of the data in columns 3 and 4 of ΣDAT, draws a best fit
line, and displays the plot:
« 3 XCOL 4 YCOL SCATRPLOT BESTFIT ΣLINE STEQ
FUNCTION DRAW { # 0d # 0d } PVIEW 7 FREEZE »
See also:
BARPLOT, PICTURE, HISTPLOT, PVIEW, SCLΣ, XCOL, YCOL
SCATTER
Type:
Description:
Command
Scatter Plot Type Command: Sets the plot type to SCATTER.
When the plot type is SCATTER, the DRAW command plots points by obtaining x and y
coordinates from two columns of the current statistics matrix (reserved variable ΣDAT). The
columns are specified by the first and second parameters in the reserved variable ΣPAR (using the
XCOL and YCOL commands). The plotting parameters are specified in the reserved variable
PPAR, which has this form:
{ (xmin, ymin), (xmax, ymax), indep, res, axes, ptype, depend }
For plot type SCATTER, the elements of PPAR are used as follows:
• (xmin, ymin) is a complex number specifying the lower left corner of PICT (the lower left corner
of the display range). The default value is (–6.5,–3.1) for the HP 48gII and (–6.5,–3.9) for the
HP 50g and 49g+.
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
• indep is a name specifying the independent variable. The default value of indep is X.
• res is not used.
• axes is a list containing one or more of the following, in the order listed: a complex number
specifying the user-unit coordinates of the plot origin, a list specifying the tick-mark annotation,
and two strings specifying labels for the horizontal and vertical axes. The default value is (0,0).
Full Command and Function Reference 3-217
See also:
START
Type:
Description:
Access:
Input/Output:
NEXT, SST
Command Operation
START Definite Loop Structure Command: Begins START … NEXT and START … STEP
definite loop structures.
Definite loop structures execute a command or sequence of commands a specified number of times.
• START … NEXT executes a portion of a program a specified number of times.
The RPL syntax is this: xstart xfinish START loop-clause NEXT
The algebraic syntax is this: START(xstart xfinish) loop-clause NEXT
START takes two numbers (xstart and xfinish) from the stack and stores them as the starting and
ending values for a loop counter. Then the loop clause is executed. NEXT increments the
counter by 1 and tests to see if its value is less than or equal to xfinish. If so, the loop clause is
executed again. Notice that the loop clause is always executed at least once.
• START … STEP works just like START … NEXT, except that it can use an increment value
other than 1. The RPL syntax is this: xstart xfinish START loop-clause xincrement STEP
The algebraic syntax is this: START (xstart xfinish) loop-clause STEP(xincrement)
START takes two numbers (xstart and xfinish) from the stack and stores them as the starting
and ending values for the loop counter. Then the loop clause is executed. STEP takes
xincrement from the stack and increments the counter by that value. If the argument of STEP
is an algebraic or a name, it is automatically evaluated to a number.
The increment value can be positive or negative:
– If positive, the loop is executed again when the counter is less than or equal to xfinish.
– If negative, the loop is executed when the counter is greater than or equal to xfinish.
!°BRANCH START
( °is the left-shift of the Nkey).
Level 2/Argument 1
Level 1/Argument 2
START xstart
xfinish
See also:
STD
Type:
Description:
STEP
FOR, NEXT, STEP
→
→
NEXT
STEP
Level 1/Item 1
xincrement
→
'symbincrement'
→
Command
Standard Mode Command: Sets the number display format to standard mode.
Executing STD has the same effect as clearing flags –49 and –50.
Standard format (ANSI Minimal BASIC Standard X3J2) produces the following results when
displaying or printing a number.
• Numbers that can be represented exactly as integers with 12 or fewer digits are displayed
without a fraction mark or exponent. Zero is displayed as 0.
• Numbers that can be represented exactly with 12 or fewer digits, but not as integers, are
displayed with a fraction mark but no exponent. Leading zeros to the left of the fraction mark
and trailing zeros to the right of the fraction mark are omitted.
• All other numbers are displayed in scientific notation (see SCI) with both a fraction mark (with
one number to the left) and an exponent (of one or three digits). There are no leading or trailing
zeros.
In algebraic objects, integers less than 103 are always displayed in standard mode.
3-234 Full Command and Function Reference
UFACT
Type:
Command
Description:
Factor Unit Command: Factors the level 1 unit from the unit expression of the level 2 unit object.
Access:
!Ú UNITS TOOLS UFACT
( Ú is the left-shift of the 6key).
Input/Output:
Level 2/Argument 1
Example:
See also:
Level 1/Argument 2
x1_unit1
x2_unit2
1_W 1_N UFACT returns 1_N*m/s.
CONVERT, UBASE, →UNIT, UVAL
Level 1/Item 1
→
x3_unit2*unit3
UFL1→MINIF
Type:
Command
Description:
Converts a UFL1 (universal font library) fontset to a minifont compatible with the calculator.
You specify the fontset and give it an ID (0–255). The font must be a 6-by-4 font.
Access:
…µUFL1→MINIF
Input/Output:
Level 2/Argument 1
See also:
objfontset
→MINIFONT, MINIFONT→
Level 1/Argument 2
nID
Level 1/Item 1
→ The font converted to minifont.
UNASSIGN
Type:
Command
Description:
Removes global variables and returns their values. This is an algebraic version of the PURGE
command.
Access:
Catalog, …µ
Input:
Level 1/Item 1: The name of a global variable, or a list of global names, to be purged.
Output:
Level 1/Item 1: The value or list of values that were stored in the now purged variables. If a
variable does not exist, or is not in the current directory path, it is not removed, and its name is
returned.
Flags:
The status of the purge confirm flag (flag –76) is ignored, variables are purged with no request for
confirmation.
Example:
Try to remove the global variable U, which contains 17.5, and the global variable V, which is not
on the current directory path.
Command:
Result:
UNASSIGN({U, V})
{17.5, V}
See also:
ADDTOREAL, ASSUME, DEF, LOCAL, PURGE, STO, STORE, UNASSUME, UNBIND
UNASSUME
Type:
Description:
Command
Access:
Removes all assumptions on specified global variables, whether created by default, by
ADDTOREAL or by ASSUME. Does this by removing the variable names from the list
REALASSUME. Returns the variable names. To remove assumptions on a variable but leave it in
REALASSUME, use ADDTOREAL instead of UNASSUME.
Catalog, …µ
Full Command and Function Reference 3-263
Input/Output:
Input/Output:
Level 1/Argument 1
→
xseconds
See also:
STO
Type:
Description:
Access:
Input/Output:
0
BUFLEN, CLOSEIO, SBRK, SRECV, XMIT
See also:
STOALARM
Type:
Description:
→
Example:
See also:
Command
Store Command: Stores an object into a specified variable or object.
Storing a graphics object into PICT makes it the current graphics object.
To create a backup object, store the obj into the desired backup location (identified as
:nport:namebackup). STO will not overwrite an existing backup object.
To store backup objects and library objects, specify a port number (0 through 3).
After storing a library object in a port, it must then be attached to its directory before it can be
used. The easiest way to do this is to execute a warm start (by pressing $& C). This also
causes the calculator to perform a system halt, which clears the stack, the LAST stack, and all local
variables.
STO can also replace a single element of an array or list stored in a variable. Specify the variable in
level 1 as name(index), which is a user function with index as the argument. The index can be n or
n,m, where n specifies the row position in a vector or list, and n,m specifies the row-and-column
position in a matrix.
K
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
→
obj
'name'
grob
PICT
→
obj
:nport :namebackup
→
obj
'name(index)'
→
backup
nport
→
nport
→
library
Example 1:
Example 2:
Example 3:
Level 1/Item 1
→
library
:nport :nlibrary
'A+B+C+D' 'SUMAD' STO stores the expression A+B+C+D in the variable SUMAD.
5 'A(3)' STO stores the integer 5 in the third element in a list or vector A.
2 'A(3,5)' STO stores the integer 2 in the element in the third row and fifth column of
matrix A.
DEFINE, RCL, →, Command
Store Alarm Command: Stores an alarm in the system alarm list and returns its alarm index
number.
If the argument is a real number xtime, the alarm date will be the current system date by default.
If objaction is a string, the alarm is an appointment alarm, and the string is the alarm message. If
objaction is any other object type, the alarm is a control alarm, and the object is executed when the
alarm comes due.
xrepeat is the repeat interval for the alarm in clock ticks, where 8192 ticks equals 1 second.
TVARS
Type:
Description:
Access:
Input/Output:
Level 1/Argument 2
date
time
Level 1/Item 1
→
“DOW DATE TIME“
With flags –42 and –41 clear, 2.061990 14.55 TSTR returns
"TUE 02/06/90 02:55:00P".
DATE, TICKS, TIME
Command
Typed Variables Command: Lists all global variables in the current directory that contain objects
of the specified types.
If the current directory contains no variables of the specified types, TVARS returns an empty list.
For a table of the object-type numbers, see the entry for TYPE.
!° MEMORY DIRECTORY LTVARS ( °is the left-shift of the Nkey).
Level 1/Argument 1
Level 1/Item 1
ntype
→
{ global ... }
{ ntype ...}
→
{ global ... }
See also:
PVARS, TYPE, VARS
TVM
Type:
Description:
Access:
Input/Output:
See also:
Command
TVM Menu Command: Displays the TVM Solver menu.
…µ TVM
None
AMORT, TVMBEG, TVMEND, TVMROOT
TVMBEG
Type:
Description:
Command
Payment at Start of Period Command: Specifies that TVM calculations treat payments as being
made at the beginning of the compounding periods.
Access:
…µ TVMBEG
Input/Output: None
See also:
AMORT, TVM, TVMEND, TVMROOT
TVMEND
Type:
Description:
Command
Payment at End of Period Command: Specifies that TVM calculations treat payments as being
made at the end of the compounding periods.
Access:
…µ TVMEND
Input/Output: None
See also:
AMORT, TVM, TVMBEG, TVMROOT
TVMROOT
Type:
Description:
Access:
3-236 Full Command and Function Reference
Level 2/Argument 1
Command
TVM Root Command: Solves for the specified TVM variable using values from the remaining
TVM variables.
…µ TVMROOT
Full Command and Function Reference 3-261
Input/Output:
Input/Output:
Level 2/Argument 1
Level 1/Argument 2
{ obj1, xkey 1, ... objn, xkey n }
→
z1
ntruncate
→
z2
{ S, obj1, xkey 1, ... objn, xkey n }
→
z1
'symbtruncate'
→
'TRNC(z1,symbtruncate)'
'S'
→
'symb1'
ntruncate
→
'TRNC(symb1,ntruncate)'
'symb1'
'symbtruncate'
→
'TRNC(symb1,symbtruncate)'
[ array ]1
ntruncate
→
[ array ]2
x_unit
ntruncate
→
y_unit
Level 1/Argument 1
See also:
Level 1/Item 1
ASN, DELKEYS, RCLKEYS
STORE
Type:
Function
Description:
Stores a number in a global variable. Given an expression as input, STORE evaluates the
expression and stores the numerical value, unlike DEF which stores the expression.
Access:
Catalog, …µ
Input:
Level 2/Argument 1: A number or an expression that evaluates to a numeric value.
Level 1/Argument 2: The name of the variable in which the number is to be stored. If this
variable does not already exist in the current directory path then it is created.
Example 1:
Example 2:
See also:
Level 1/Item 1
→
x_unit
'symbtruncate'
'TRNC(x_unit,symbtruncate)'
(4.5792,8.1275) 2 TRNC returns (4.57,8.12).
[ 2.34907 3.96351 2.73453 ] -2 TRNC returns [ 2.3 3.9 2.7 ].
RND
TRUNC
Function
Description:
Truncates a series expansion.
Output:
Level 1/Item 1: The number to which the first argument is evaluated, and which is stored in the
variable.
Type:
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Access:
Catalog, …µ
Input:
Level 2/Argument 1: The expression that you want to truncate.
Level 1/Argument 2: The expression to truncate with respect to.
Output:
The expression from Level 2/Argument 1, with terms of order greater than or equal to the order
of the expression in Level 1/Argument 2 removed.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Command:
Result:
Store in variable Z the result of calculating 17*Y. Assume that Y contains the integer number 2.
See also:
DEF, DEFINE, UNASSIGN
STORE(17*Y, Z)
34
STOVX
Type:
Command
Description:
Stores a name or list of names in the current CAS variable. This is the same as storing into the VX
variable in the CASDIR directory. By default, the CAS variable is called X; this command allows a
program to change that name.
Access:
Catalog, …µ
Input:
Level 1/Argument 1: A name or list of names.
Output:
None in RPN mode, NOVAL in Algebraic mode.
See also:
RCLVX
STO+
Type:
Description:
Access:
Command
Store Plus Command: Adds a number or other object to the contents of a specified variable.
The object on the stack and the object in the variable must be suitable for addition to each other.
STO+ can add any combination of objects suitable for addition.
Using STO+ to add two arrays (where obj is an array and name is the global name of an array)
requires less memory than using the stack to add them.
!°MEMORY ARITHMETIC STO+
( °is the left-shift of the Nkey).
3-238 Full Command and Function Reference
Expand the expression (x+1)7, and remove all terms in x4 and higher powers of x
Example:
Command:
Result:
TRUNC((X+1)^7,X^4)
See also:
DIVPC, EXPAND, SERIES
TRUTH
Type:
Description:
35*X^3+21*X^2+7*X+1
Command
Truth Plot Type Command: Sets the plot type to TRUTH.
When the plot type is TRUTH, the DRAW command plots the current equation as a truth-valued
function of two real variables. The current equation is specified in the reserved variable EQ. The
plotting parameters are specified in the reserved variable PPAR, which has this form:
{ (xmin, ymin) (xmax, ymax) indep res axes ptype depend }
For plot type TRUTH, the elements of PPAR are used as follows:
• (xmin, ymin) is a complex number specifying the lower left corner of PICT (the lower left corner
of the display range). The default value is (–6.5,–3.1) for the HP 48gII and (–6.5,–3.9) for the
HP 50g and 49g+.
• (xmax, ymax) is a complex number specifying the upper right corner of PICT (the upper right
corner of the display range). The default value is (6.5,3.2) for the HP 48gII and (6.5,4.0) for the
HP 50g and 49g+.
Full Command and Function Reference 3-259
Access:
Input/Output:
See also:
STOΣ
Type:
Description:
Access:
Input/Output:
Using STO/ to divide one array by another array or to divide an array by a number (where obj is
an array or a number and name is the global name of an array) requires less memory than using the
stack to divide them.
!°MEMORY ARITHMETIC STO/ ( °is the left-shift of the Nkey).
Level 2/Argument 1
Level 1/Argument 2
obj
'name'
'name'
STO+, STO–, STO*, /
obj
Level 1/Item 1
→
→
Access:
Input/Output:
→STR
Type:
Description:
Access:
Flags:
Command
Description:
Simplifies a trigonometric expression by applying the identity:
2
Level 1/Item 1
→
CLΣ, RCLΣ, Σ+, Σ–
Command
Evaluate String Command: Evaluates the text of a string as if the text were entered from the
command line.
OBJ→ also includes this function. STR→ is included for compatibility with the HP 28S.
…µ STR→
Level 1/Argument 1
See also:
TRIGCOS, TRIGSIN, TRIGTAN
TRIGCOS
Type:
2
( sin x ) + ( cos x ) = 1
Command
Store Sigma Command: Stores obj in the reserved variable ΣDAT.
STOΣ accepts any object and stores it in ΣDAT. However, if the object is not a matrix or the
name of a variable containing a matrix, an Invalid ΣDATA error occurs upon subsequent
execution of a statistics command.
…µ STOΣ
obj
STR→
Type:
Description:
See also:
Returns only cosine terms if possible.
Level 1/Argument 1
See also:
Result:
2
1
L N( X + 1 ) + 2 × i × A TA N --
 x
-----------------------------------------------------------------------------2
“obj”
ARRY→, DTAG, EQ→, LIST→, OBJ→, →STR
Level 1/Item 1
→
evaluated-object
Access:
Trigonometry, …ÑLL
Input:
An expression with trigonometric terms.
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
See also:
TRIG, TRIGSIN, TRIGTAN
TRIGO
Type:
Command
Description:
Displays a menu or list containing the CAS commands for transforming trigonometric
expressions.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
ALGB, ARIT, CONSTANTS, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR,
MODULAR, POLYNOMIAL, REWRITE, TESTS
TRIGSIN
Type:
Command
Description:
Simplifies a trigonometric expression by applying the identity:
2
2
( sin x ) + ( cos x ) = 1
Command
Object to String Command: Converts any object to string form.
The full-precision internal form of a number is not necessarily represented in the result string. To
ensure that →STR preserves the full precision of a number, select Standard number display
format or a wordsize of 64 bits (or both) before executing →STR.
The result string includes the entire object, even if the displayed form of the object is too large to
fit in the display.
If the argument object is normally displayed in two or more lines, the result string will contain
newline characters (character 10) at the end of each line. The newlines are displayed as the
character ␍.
If the argument object is already a string, →STR returns the string.
…µ →STR
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12), Number Display
Format (–49, –50)
3-240 Full Command and Function Reference
Returns only sine terms if possible.
Access:
Trigonometry, …ÑLL
Input:
An expression with trigonometric terms.
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
See also:
TRIG, TRIGCOS, TRIGTAN
TRIGTAN
Type:
Command
Description:
Replaces sine and cosine terms in a trigonometric expression with tangent terms.
Full Command and Function Reference 3-257
See also:
STURMAB
Type:
STURMAB
TMENU
Type:
Description:
Command
Description:
For a polynomial P and a closed interval [a, b], STURMAB determines the number of zeroes P has
in [a, b]
Access:
Arithmetic, !ÞPOLYNOMIAL !«
Input:
A polynomial P
Output:
A list containing a number that is the same sign as P(a) and the number of zeroes P has in [a, b].
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Access:
Input/Output:
Level 1/Argument 1
For the polynomial:
3
x +2
in the interval [-2,0] find the sign at the lower bound, and the number of zeroes
Command:
Result:
See also:
STWS
Type:
Description:
Access:
STURMAB(X^3+2, -2, 0)
{-6,1}
STURM, ZEROS
Command
Set Wordsize Command: Sets the current binary integer wordsize to n bits, where n is a value
from 1 through 64 (the default is 64).
Values of n less than 1 or greater than 64 are interpreted as 1 or 64, respectively.
If the wordsize is smaller than an integer entered on the command line, then the most significant
bits are not displayed upon entry. The truncated bits are still present internally (unless they exceed
64), but they are not used for calculations and they are lost when a command uses this binary
integer as an argument.
Results that exceed the given wordsize are also truncated to the wordsize.
!´ BASE LSTWS
Level 1/Argument 1
n
SUB
Type:
Description:
Example 1:
Example 2:
Example 3:
Example 4:
Example 5:
See also:
TOT
Type:
Description:
Access:
Input/Output:
#n
BIN, DEC, HEX, OCT, RCWS
Level 1/Item 1
→
→
Level 1/Item 1
xmenu
→
{ listdefinition }
→
→
'namedefinition'
7 TMENU displays the first page of the MTH MATR menu.
48.02 TMENU displays the second page of the UNITS MASS menu.
256 TMENU displays the first page of commands in library 256.
{ A 123 "ABC" } TMENU displays the custom menu defined by the list argument.
'MYMENU' TMENU displays the custom menu defined by the name argument.
MENU, RCLMENU
Command
Total Command: Computes the sum of each of the m columns of coordinate values in the current
statistics matrix (reserved variable ΣDAT).
The sums are returned as a vector of m real numbers, or as a single real number if m = 1.
…µ TOT
Level 1/Argument 1
Level 1/Item 1
→
( ´ is the left-shift of the Pkey).
… ã STWS
(ã is the right-shift of the 3key).
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output:
See also:
Command
Temporary Menu Command: Displays a built-in menu, library menu, or user-defined menu.
TMENU works just like MENU, except for user-defined menus (specified by a list or by the
name of a variable that contains a list). Such menus are displayed like a custom menu and work
like a custom menu, but are not stored in reserved variable CST. Thus, a menu defined and
displayed by TMENU cannot be redisplayed by evaluating CST.
See Appendix H for a list of the calculator’s built-in menus and the corresponding menu
numbers (xmenu).
„&H MENU TMENU
See also:
TRACE
Type:
Description:
Access:
→
MAXΣ, MINΣ, MEAN, PSDEV, PVAR, SDEV, VAR
xsum
[ xsum 1, xsum 2, ... ,xsum m ]
Command
Matrix Trace Command: Returns the trace of a square matrix.
The trace of a square matrix is the sum of its diagonal elements.
!Ø OPERATIONS LL TRACE
( Ø is the left-shift of the 5key).
!´MATRIX NORMALIZE L TRACE
( ´ is the left-shift of the Pkey).
Input/Output:
Command Operation
Subset Command: Returns the portion of a string or list defined by specified positions, or returns
the rectangular portion of a graphics object or PICT defined by two corner pixel coordinates.
If nend position is less than nstart position, SUB returns an empty string or list. Values of n less than 1 are
treated as 1; values of n exceeding the length of the string or list are treated as that length.
For graphics objects, a user-unit coordinate less than the minimum user-unit coordinate of the
graphics object is treated as that minimum. A pixel or user-unit coordinate greater than the
maximum pixel or user-unit coordinate of the graphics object is treated as that maximum.
3-242 Full Command and Function Reference
Level 1/Argument 1
[[ matrix ]]n×n
See also:
TRAN
Type:
Description:
Level 1/Item 1
→
xtrace
CONJ, DET, IDN
Command
Transpose Matrix Command: Returns the transpose of a matrix.
Same as TRN, but without conjugation of complex numbers.
Full Command and Function Reference 3-255
Input:
Level 2/Argument 1: The object or number to be subtracted from.
Level 1/Argument 2: The object or number to subtract.
Output:
The result of the subtraction, modulo the current modulus.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
SVD
Type:
Description:
TICKS
Type:
Command
Description:
Ticks Command: Returns the system time as a binary integer, in units of 1/8192 second.
Access:
…ÓTOOLS TICKS
( Ó is the right-shift of the 9 key).
Input/Output:
Level 1/Argument 1
Command
Singular Value Decomposition Command: Returns the singular value decomposition of an m × n
matrix.
SVD decomposes A into 2 matrices and a vector. U is an m × m orthogonal matrix, V is an n × n
orthogonal matrix, and S is a real vector, such that A = U × diag(S) × V . S has length MIN(m,n)
and contains the singular values of A in nonincreasing order. The matrix diag(S) is an m×n
diagonal matrix containing the singular values S.
The computed results should minimize (within computational precision):
Example:
See also:
TIME
Type:
Description:
A – U ⋅ diag ( S ) ⋅ V
--------------------------------------------------min ( m, n ) ⋅ A
where diag(S) denotes the m × n diagonal matrix containing the singular values S.
Access:
!Ø
FACTORIZATION SVD
(Ø is the left-shift of the 5key).
!´ MATRIX FACTORS SVD
( ´ is the left-shift of the Pkey).
Access:
Input/Output:
Command
Time Command: Returns the system time in the form HH.MMSSs.
time has the form HH.MMSSs, where HH is hours, MM is minutes, SS is seconds, and s is zero or
more digits (as many as allowed by the current display mode) representing fractional seconds. time
is always returned in 24-hour format, regardless of the state of the Clock Format flag (–41).
…Ó TOOLS TIME
(Ó is the right-shift of the 9 key).
Level 1/Argument 1
Input/Output:
SVL
Type:
Description:
Access:
[[ matrix ]]A
DIAG→, MIN, SVL
→
Level 3/Item 1
Level 2/Item 2
Level 1/Item 3
[[ matrix ]]U
[[ matrix ]]V
[ vector ]S
Command
Singular Values Command: Returns the singular values of an m × n matrix.
SLV returns a real vector that contains the singular values of an m × n matrix in non-increasing
order. The vector has length MIN(m,n).
!Ø FACTORIZATION LSVL (Ø is the left-shift of the 5key).
See also:
→TIME
Type:
Description:
Access:
Input/Output:
Command
Set System Time Command: Sets the system time.
time must have the form HH.MMSSs, where HH is hours, MM is minutes, SS is seconds, and s is
zero or more digits (as many as allowed by the current display mode) representing fractional
seconds. time must use 24-hour format.
…ÓTOOLS →TIME
(Ó is the right-shift of the 9 key).
Level 1/Argument 1
time
See also:
Level 1/Argument 1
Level 1/Item 1
→
[[ matrix ]]
See also:
MIN, SVD
SWAP
Type:
Description:
RPL Command
Swap Objects Command: Swaps the position of the two inputs.
!°STACK SWAP
TINC
Type:
Description:
[ vector ]
( °is the left-shift of the Nkey).
™ in RPN mode executes SWAP when no command line is present.
Access:
Flags:
Input/Output:
Level 2
obj1
3-244 Full Command and Function Reference
Level 1
obj2
→
Level 2
Level 1
obj2
obj1
time
DATE, TICKS, TSTR
!´ MATRIX FACTORS LSVL ( ´ is the left-shift of the Pkey).
Input/Output:
Access:
Level 1/Item 1
→
Level 1/Argument 1
See also:
Level 1/Item 1
→
#ntime
If the result from a previous invocation from TICKS is on level 1 of the stack, then the command
sequence TICKS SWAP - B->R 8192 / returns a real number whose value is the
elapsed time in seconds between the two invocations.
TIME
Level 1/Item 1
→
CLKADJ, →DATE
Function
Temperature Increment Command: Calculates a temperature increment.
TINC adds a temperature increment (not an actual temperature) to a point on a temperature scale.
Use a negative increment to subtract the increment from the temperature. xinitial or x_unit1 is the
initial temperature, and ydelta or y_unit2delta is the temperature increment. The returned temperature
is the resulting final temperature. If unit objects are given, the final temperature is returned as a
unit object with the same units as x_unit1. If real numbers are given, the final temperature is
returned as a real number.
…µ TINC
Numerical Results (–3)
Full Command and Function Reference 3-253
Example:
Command:
Result:
%T
Type:
Description:
Access:
Flags:
Input/Output:
Example 1:
Example 2:
See also:
TABVAL
Type:
Description:
Convert this system to a matrix:
TCOLLECT
X–Y=0
2X + Y = 5
Type:
Command
Description:
Linearizes products in a trigonometric expression by collecting sine and cosine terms, and by
combining sine and cosine terms of the same argument.
Access:
Trigonometry, …ÑL
SYST2MAT([X-Y, 2*X+Y=5],[X, Y])
1 –1 0
2 1 –5
Function
Percent of Total Function: Returns the percent of the first argument that is represented by the
second argument.
If both arguments are unit objects, the units must be consistent with each other.
The dimensions of a unit object are dropped from the result, but units are part of the calculation.
For more information on using temperature units with arithmetic functions, refer to the entry for
+.
!´ REAL %T
( ´ is the left-shift of the Pkey).
Numerical Results (–3)
Level 2/Argument 1
Level 1/Argument 2
x
y
→
100y/x
x
'symb'
→
'%T(x,symb)'
'symb'
x
→
'%T(symb,x)'
'symb1'
'symb2'
→
'%T(symb1, symb2)'
x_unit1
y_unit2
→
100y_unit2/x_unit1
x_unit
'symb'
→
'%T(x_unit,symb)'
→
'symb'
x_unit
'%T(symb,x_unit)'
1_m 500_cm %T returns 500, because 500 cm represents 500% of 1 m.
100_K 50_K %T returns 50.
+, %, %CH
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Collect terms in the expression:
sin 2x + cos 2x
Command:
Result:
See also:
TCOLLECT(SIN(2*X)+COS(2*X))
√2*COS(2*X-π/4)
TEXPAND, TLIN
TDELTA
Type:
Description:
Access:
Flags:
Input/Output:
Function
Temperature Delta Function: Calculates a temperature change.
TDELTA subtracts two points on a temperature scale, yielding a temperature increment (not an
actual temperature). x or x_unit1 is the final temperature, and y or y_unit2 is the initial
temperature. If unit objects are given, the increment is returned as a unit object with the same
units as x_unit1. If real numbers are given, the increment is returned as a real number.
…µ TDELTA
Numerical Results (–3)
For an expression and a list of values, stores the expression in EQ, and returns the results of
substituting the values for the current variable in the expression.
PGRAPH L, !ÖGRAPHL
Level 2/Argument 1: An algebraic expression in terms of the current variable.
Level 1/Argument 2: A list of values for which the expression is to be evaluated.
Example:
Command:
The simplified expression.
Command
Input:
Flags:
An expression with trigonometric terms.
Output:
Level 1/Item 1
Access:
Output:
Input:
Level 2/Item 1: The algebraic expression.
Level 1/Item 2: A list containing two lists: a list of the values and a list of the corresponding
results.
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Substitute 1, 2, and 3 into
2
x +1
See also:
3-246 Full Command and Function Reference
Level 1/Argument 2
x
y
→
Level 1/Item 1
x_unit1
x_unit2
→
x_unit1delta
x_unit
'symb'
→
'TDELTA(x_unit, symb)'
xdelta
'symb'
y_unit
→
'TDELTA(symb, y_unit)'
'symb1'
'symb2'
→
'TDELTA(symb1, symb2)'
TINC
TESTS
Type:
Command
Description:
Displays a menu or list containing the ASSUME and UNASSUME commands, and tests that can
be included in algebraic expressions.
Access:
Catalog, …µ
Flags:
If the CHOOSE boxes flag is clear (flag –117 clear), displays the operations as a numbered list. If
the flag is set, displays the operations as a menu of function keys.
See also:
ALGB, ARIT, CONSTANTS, DIFF, EXP&LN, INTEGER, MAIN, MATHS, MATR,
MODULAR, POLYNOMIAL, REWRITE, TRIGO
.
TABVAL(X^2+1,{1, 2, 3})
Level 2/Argument 1
Full Command and Function Reference 3-251
See also:
TAN
Type:
Description:
HEAD
Analytic function
Tangent Analytic Function: Returns the tangent of the argument.
For real arguments, the current angle mode determines the number’s interpretation as an angle,
unless the angular units are specified.
For a real argument that is an odd-integer multiple of 90 in Degrees mode, an Infinite Result
exception occurs. If flag –22 is set (no error), the sign of the result (MAXR) matches that of the
argument.
For complex arguments:
( sin x) ( cos x ) + i ( sinh y ) ( cosh y )
tan ( x + iy ) = -----------------------------------------------------------------------------2
2
sin h y + cos x
Access:
Flags:
Input/Output:
See also:
Level 1/Item 1
z
→
tan z
'symb'
→
'TAN(symb)'
x_unitangular
→
tan (x_unitangular)
ATAN, COS, SIN
An expression
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
Example:
Replace tan(x) terms in the function:
( tan ( x ) ) 2
Command:
Result:
See also:
If the argument for TAN is a unit object, then the specified angular unit overrides the angle mode
to determine the result. Integration and differentiation, on the other hand, always observe the
angle mode. Therefore, to correctly integrate or differentiate expressions containing TAN with a
unit object, the angle mode must be set to Radians (since this is a “neutral” mode).
U
Numerical Results (–3), Angle Mode (–17, –18), Infinite Result Exception (–22)
Level 1/Argument 1
Input:
Replaces tan(x) terms in an expression with sin(2x)/1+cos(2x) terms.
Access:
PTRIG, Trigonometry, …ÑL
Input:
An expression
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
In previous versions of the CAS, if flag –116 was set (Prefer sin()), then TAN2SC2 replaced tan(x)
terms with: 1 – cos(2x)/sin(2x). This action is now performed by the TAN2CS2 command.
Example:
Replace tan(x) terms in the function:
Access:
Catalog, …µ
See also:
Input:
An expression
Output:
The transformed expression.
Flags:
Exact mode must be set (flag –105 clear).
Numeric mode must not be set (flag –3 clear).
Radians mode must be set (flag –17 set).
TANH
Type:
Description:
( tan ( x ) ) 2
Replaces tan(x) terms in an expression with (1-cos(2x))/sin(2x) terms.
Replace tan(x) terms in the function:
Command:
Result:
TAN2CS2(TAN(X)^2)
((1-COS(2*X))/SIN(2*X))^2
Access:
Flags:
Input/Output:
Command
Access:
PTRIG, Trigonometry, …ÑL
(SIN(2*X)/(1+COS(2*X)))^2
HALFTAN, TAN2CS2, TAN2SC
Analytic function
Hyperbolic Tangent Analytic Function: Returns the hyperbolic tangent of the argument.
For complex arguments,
…Ñ HYPERBOLIC TANH
(Ñ is the right-shift of the 8key).
!´ HYPERBOLIC TANH
Numerical Results (–3)
( ´ is the left-shift of the Pkey).
Level 1/Argument 1
TAN2SC, TAN2SC2
TAN2SC
Type:
Description:
TAN2SC2(TAN(X)^2)
sinh 2x + i sin 2y
tanh ( x + iy ) = --------------------------------------cosh 2x + cos 2y
( tan ( x ) ) 2
See also:
Command
Description:
Command
Command:
Result:
(SIN(X)/COS(X))^2
HALFTAN, TAN2CS2, TAN2SC2
TAN2SC2
Type:
TAN2CS2
Type:
Description:
Example:
TAN2SC(TAN(X)^2)
See also:
Level 1/Item 1
z
→
tanh z
'symb'
→
'TANH(symb)'
ATANH, COSH, SINH
Replaces tan(x) sub-expressions with sin(x)/cos(x).
3-248 Full Command and Function Reference
Full Command and Function Reference 3-249
Input/Output:
Level 2/Argument 1
See also:
UTPF
Type:
Description:
Level 1/Argument 2
n
UTPF, UTPN, UTPT
Level 1/Item 1
→
x
utpc(n,x)
Command
Upper Snedecor’s F Distribution Command: Returns the probability utpf(n1, n2, x) that a
Snedecor’s F random variable is greater than x, where n1 and n2 are the numerator and
denominator degrees of freedom of the F distribution.
The defining equations for utpf(n1, n2, x) are these:
• For x ≥ 0:
1
n
 ----n 
n1
----2
2
n1 + n2
Γ  -----------------
2
-----------------------------n 1  n 2

Γ  ----- Γ  -----
2
2
∞
∫x t
n1 – 2
-------------2
( n1 + n2 )
n
1 +  ----1-  t
n 
2
– ---------------------2
dt
• For x < 0:
utp f ( n 1, n 2, x ) = 1
For any value z,
z
z
Γ  --- =  --- – 1 !
2
2
>
(Greater than)
Type:
Function
Description:
Greater Than Function: Tests whether one object is greater than another object.
The function > returns a true test result (1) if the first argument is greater than the second
argument, or a false test result (0) otherwise.
If one object is a symbolic (an algebraic or a name), and the other is a number or symbolic or unit
object, > returns a symbolic comparison expression that can be evaluated to return a test result.
For real numbers and binary integers, “greater than” means numerically greater (2 is greater than
1). For real numbers, “greater than” also means less negative (–1 is greater than –2).
For strings, “greater than” means alphabetically subsequent (“DEF” is greater than “ABC”;
“AAB” is greater than “AAA”; “AA” is greater than “A”). In general, characters are ordered
according to their character codes. This means, for example, that “a” is greater than “B”, since
“B” is character code 66, and “a” is character code 97.
For unit objects, the two objects must be dimensionally consistent and are converted to common
units for comparison. If you use simple temperature units, the calculator assumes the values
represent temperatures and not differences in temperatures. For compound temperature units, the
calculator assumes temperature units represent temperature differences. For more information on
using temperature units with arithmetic functions, refer to the entry for +.
…É
(É is the right-shift of the Ykey).
Access:
Flags:
Numerical Results (–3)
Input/Output:
Level 2/Argument 1
Level 1/Argument 2
x
#n1
“string1”
x
'symb'
'symb1'
x_unit1
x_unit
'symb'
y
#n2
“string2”
'symb'
x
'symb2'
y_unit2
'symb'
x_unit
, where ! is the calculator’s factorial command.
The values n1 and n2 are rounded to the nearest integers and, when rounded, must be positive.
Access:
!´ L PROBABILITY L UTPF
( ´ is the left-shift of the Pkey).
Input/Output:
Level 3/Argument 1
See also:
UTPN
Type:
Description:
Level 2/Argument 2
Level 1/Argument 3
n2
x
n1
UTPC, UTPN, UTPT
Level 1/Item 1
→
utpf(n1,n2,x)
See also:
Command
Upper Normal Distribution Command: Returns the probability utpn(m, v, x) that a normal
random variable is greater than x, where m and v are the mean and variance, respectively, of the
normal distribution.
For all x and m, and for v > 0, the defining equation is this:
2
1
utpn ( m, v, x ) = ------------2πv
(t – m)
∞ – -----------------2v
∫e
dt
x
For v = 0, UTPN returns 0 for x ≥ m, and 1 for x < m.
Access:
!´ L PROBABILITY L UTPN
3-266 Full Command and Function Reference
( ´ is the left-shift of the Pkey).
Level 1/Item 1
→
→
→
→
→
→
→
→
→
0/1
0/1
0/1
'x > symb'
'symb > x'
'symb1 > symb2'
0/1
'x_unit > symb'
'symb > x_unit'
<, ≤, ≥, ==, ≠
≥
(Greater than or Equal)
Type:
Function
Description:
Greater Than or Equal Function: Tests whether one object is greater than or equal to another
object.
The function ≥ returns a true test result (1) if the first argument is greater than or equal to the
second argument, or a false test result (0) otherwise.
If one object is a symbolic (an algebraic or a name), and the other is a number or symbolic or unit
object, ≥ returns a symbolic comparison expression that can be evaluated to return a test result.
For real numbers and binary integers, “greater than or equal to” means numerically equal or
greater (2 is greater than or equal to 1). For real numbers, “greater than or equal to” also means
equally or less negative (–1 is greater than or equal to –2).
For strings, “greater than or equal to” means alphabetically equal or subsequent (“DEF” is greater
than or equal to “ABC”; “AAB” is greater than or equal to “AAA”; “AA” is greater than or equal
to “A”). In general, characters are ordered according to their character codes. This means, for
Full Command and Function Reference 3-295
The calculator handles units by attaching the unit to a numeric value using the underscore symbol.
For example, the value of 3 kilometers is shown as 3_km, and is created by entering 3 and then
the underscore character, followed by attaching the kilometer unit.
Input/Output:
L1/A1
[xy]
[ xr, €ytheta ]
[ x1 , x2 , x3 ]
[ x1, €xtheta, xz ]
[ x1, €xtheta, €xphi ]
[ x1, x2, ..., xn ]
(x, y)
(xr, €ytheta)
→
→
→
→
→
→
→
→
Ln/I1 ... L3/In–2
L2/In–1
L1/In
x1
x1
x1
x1 ... xn–2
x
xr
x2
xtheta
xtheta
xn–1
x
xr
y
ytheta
x3
xz
xphi
xn
y
ytheta
L = Level; A = Argument; I = item
Example 1:
Example 2:
Example 3:
See also:
→V2
Type:
Description:
With flag –16 clear (Rectangular mode), (2,3) V→ returns 2 to level 2 and 1 to level 1.
With flag –15 clear and –16 set (Polar/Cylindrical mode), [ 2 €7 4 ] V→ returns 2 to
level 3, 7 to level 2, and 4 to level 1.
[ 9 7 5 3 ] V→ returns 9 to level 4, 7 to level 3, 5 to level 2, and 3 to level 1,
independent of the state of flags –15 and –16.
→V2, →V3
Command
Stack to Vector/Complex Number Command: Converts two specified numbers into a 2-element
vector or a complex number.
The result returned depends on the setting of flags –16 and –19, as shown in the following table:
Flag –19 clear
Flag –19 set
Flag –16 clear (Rectangular mode)
[xy]
(x, y)
Flag –16 set (Polar mode)
[x€y]
(x, € y)
Access:
!´ VECTOR →V2
( ´ is the left-shift of the Pkey).
Flags:
Coordinate System (–16), Complex Mode (–19)
Input/Output:
Level 2/Argument 1
Example 1:
Example 2:
See also:
→V3
Type:
Description:
Level 1/Argument 2
Level 1/Item 1
x
y
→
x
y
→
[x€y]
x
y
→
(x, y)
[xy]
Access:
Input:
Output:
…Ý
(Ý is the right-shift of the -key).
Numeric value
Numeric value ready for a unit attachment
«»
(Program delimiters)
Type:
Object
Description:
Program delimiter object: Enters a pair of program delimiter objects.
A program is a set of instructions enclosed by an open program object delimiter and a close
program object delimiter. These can be nested to have a program procedure enclosed within an
outer program object.
Access:
…å
(å is the right-shift of the +key).
Input:
None
Output:
A pair of program delimiters
<
(Less than)
Type:
Function
Description:
Less Than Function: Tests whether one object is less than another object.
The function < returns a true test result (1) if the first argument is less than the second argument,
or a false test result (0) otherwise.
If one object is a symbolic (an algebraic or a name), and the other is a number or symbolic or unit
object, < returns a symbolic comparison expression that can be evaluated to return a test result.
For real numbers and binary integers, “less than” means numerically smaller (1 is less than 2). For
real numbers, “less than” also means more negative (–2 is less than –1).
For strings, “less than” means alphabetically previous (“ABC” is less than “DEF”; “AAA” is less
than “AAB”; “A” is less than “AA”). In general, characters are ordered according to their
character codes. This means, for example, that “B” is less than “a”, since “B” is character code 66,
and “a” is character code 97.
For unit objects, the two objects must be dimensionally consistent, and are converted to common
units for comparison. If you use simple temperature units, the calculator assumes the values
represent temperatures and not differences in temperatures. For compound temperature units, the
calculator assumes temperature units represent temperature differences. For more information on
using temperature units with arithmetic functions, refer to the entry for +.
…Ç
(Ç is the right-shift of the Xkey above the 8).
Access:
Flags:
Numerical Results (–3)
→
x
y
(x, € y)
With flags –19 and –16 clear, 2 3 →V2 returns [ 2 3 ].
With flags –19 and –16 set (Polar/Spherical mode), 2 3 →V2 returns (2,€3).
V→, →V3
Command
Stack to 3-Element Vector Command: Converts three numbers into a 3-element vector.
The result returned depends on the coordinate mode used, as shown in the following table:
3-268 Full Command and Function Reference
Full Command and Function Reference 3-293
The variance (equal to the square of the standard deviation) is returned as a vector of m real
numbers, or as a single real number if m = 1. The variances are computed using this formula:
1
------------ ⋅
n–1
n
∑
(xi – x)
2
i=1
where xi is the ith coordinate value in a column,
the number of data points.
x
is the mean of the data in this column, and n is
flag –2 or flag –3 is set (to return numerical results), then evaluating 'SIN(π)' returns the numerical
approximation –2.06761537357E–13.
Access:
!ì
( ìis the left-shift of the #key).
Flags:
Symbolic Constants (–2), Numerical Results (–3)
Input/Output:
Level 1/Argument 1
Level 1/Item 1
Access:
…µ VAR
Input/Output:
Level 1/Argument 1
See also:
VARS
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
→
xvariance
→
[ xvariance1, ..., xvariancem ]
MAXΣ, MEAN, MINΣ, PSDEV, PVAR, SDEV, TOT
Command
Variables Command: Returns a list of the names of all variables in the VAR menu for the current
directory.
!° MEMORY DIRECTORY L VARS
( °is the left-shift of the Nkey).
Level 1/Argument 1
Level 1/Item 1
→
{ global1 ... globaln }
See also:
ORDER, PVARS, TVARS
VER
Type:
Description:
Command
Access:
Catalog, …µ
Input:
No input required.
Output:
A real number giving the version and release date of the Computer Algebra System software.
Flags:
The version and release date are given as a number of the form V.YYYYMMDD, so a display
mode showing at least 8 digits after the fraction mark is needed to display the result in full.
See also:
Level 1/Argument 1
→
3-270 Full Command and Function Reference
Level 2/Item 1
Level 1/Item 2
“version number”
“copyright message”
'̟'
→
3.14159265359…
e, i, MAXR, MINR, →Qπ
∂
(Derivative)
Type:
Function
Description:
Derivative Function: Takes the derivative of an expression, number, or unit object with respect to
a specified variable of differentiation.
When executed in stack syntax, ∂ executes a complete differentiation: the expression 'symb1' is
evaluated repeatedly until it contains no derivatives. As part of this process, if the variable of
differentiation name has a value, the final form of the expression substitutes that value substituted
for all occurrences of the variable.
The algebraic syntax for ∂ is '∂name(symb1'). When executed in algebraic syntax, ∂ executes a
stepwise differentiation of symb1, invoking the chain rule of differentiation — the result of one
evaluation of the expression is the derivative of the argument expression symb1, multiplied by a
new subexpression representing the derivative of symb1’s argument.
If ∂ is applied to a function for which the calculator does not provide a derivative, ∂ returns a new
function whose name is der followed by the original function name.
Access:
…¿
(¿is the right-shift of the Tkey).
Flags:
Numerical Results (–3)
Input/Output:
Returns the Computer Algebra System version number, and date of release.
VERSION
Type:
Command
Description:
Software Version Command: Displays the software version and copyright message.
Access:
…µ VERSION
Input/Output:
→
Example:
See also:
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
'symb1'
'name'
→
z
'name'
→
'symb2'
0
→
x_unit
'name'
0
In Radians mode, the command sequence 'ˆX(SIN(Y))' EVAL returns 0. When Y has
the value 'X^2', the command sequence 'SIN(Y)' 'X' ˆ returns
'COS(X^2)*(2*X)'. The differentiation has been executed in stack syntax, so that all of
the steps of differentiation have been carried out in a single operation.
TAYLOR, ∫, Σ
!
(Factorial)
Type:
Function
Description:
Factorial (Gamma) Function: Returns the factorial n! of a positive integer argument n, or the
gamma function Γ(x+1) of a non-integer argument x.
For x ≥ 253.1190554375 or n < 0, ! causes an overflow exception (if flag –21 is set, the exception
is treated as an error). For non-integer x ≤ –254.1082426465, ! causes an underflow exception (if
flag –20 is set, the exception is treated as an error).
In algebraic syntax, ! follows its argument. Thus the algebraic syntax for the factorial of 7 is 7!.
For non-integer arguments x, x! = Γ(x + 1), defined for x > –1 as:
Full Command and Function Reference 3-291
However, obtaining the curl of the above result, and then applying VPOTENTIAL to it again will
give the same result.
See also:
VTYPE
Type:
Description:
CURL, POTENTIAL
Command
Variable Type Command: Returns the type number of the object contained in the named variable.
If the named variable does not exist, VTYPE returns –1.
For a table of the objects’ type numbers, see the entry for TYPE.
Access:
!° TYPE L L VTYPE
Input/Output:
*W
Type:
Description:
WAIT
Type:
Description:
Access:
Access:
∞
Type:
Catalog, …µ, or ~…3
(Infinity)
Function
Description:
( °is the left-shift of the Nkey).
Level 1/Argument 1
See also:
example you could define $=1_? Then other currencies could be defined as multiples or fractions
of 1_? The calculator has symbols for Yen, Pounds and Euros; other currencies could be defined
using their names. The unit conversion system would then check conversions between them for
consistency because ? is recognized as a base unit.
Level 1/Item 1
Infinity: used to signify a numeric result that is infinite by the rules of arithmetic, such as the result
of dividing a non-zero number by zero. The calculator recognizes two kinds of infinity: signed
and unsigned. Evaluating '1/0' gives an unsigned infinity '∞'. Selecting infinity from the keyboard,
from the CHARS table, or from the catalog …µ returns '+∞' and the sign can be changed.
Calculations with the unsigned infinity return unsigned infinity or ? as their result. Calculations
with the signed infinity can return ordinary numeric results, as in the example. Positive infinity
and unsigned infinity are equal if tested with ==, but are not identical if tested with SAME.
'name'
→
ntype
:nport : namebackup
→
ntype
→
Access:
Keyboard, CHARS, or catalog, …µ
:nport : nlibrary
ntype
Flags:
Exact mode must be set (flag –105 clear),
and numeric mode must not be set (flag –3 clear) for mathematical operations to give ∞ as a
result, and for executing ∞ from the keyboard or catalog to give +∞ and not an error.
TYPE
Command
Multiply Width Command: Multiplies the horizontal plot scale by xfactor. *W is provided for
compatibility with the HP 48. *W is the same as SCALEW; see its listing for details.
Command
Wait Command: Suspends program execution for specified time, or until a key is pressed.
The function of WAIT depends on the argument, as follows:
• Argument x interrupts program execution for x seconds.
• Argument 0 suspends program execution until a valid key is pressed (see below). WAIT then
returns xkey, which defines where the pressed key is on the keyboard, and resumes program
execution.
xkey is a three-digit number that identifies a key’s location on the keyboard. See the entry for
ASN for a description of the format of xkey.
• Argument –1 works as with argument 0, except that the currently specified menu is also
displayed.
!, …, ~, ~!, and ~… are not by themselves valid keys.
Arguments 0 and –1 do not affect the display, so that messages persist even though the keyboard
is ready for input (FREEZE is not required).
Normally, the MENU command does not update the menu keys until a program halts or ends.
WAIT with argument –1 enables a previous execution of MENU to display that menu while the
program is suspended for a key press.
!° L IN WAIT
( °is the left-shift of the Nkey).
Example:
Command:
Results:
Find the arc tangent of minus infinity. Assume that radians mode is set.
ATAN(-∞)
-(π/2)
Σ
(Summation)
Type:
Function
Description:
Summation Function: Calculates the value of a finite series.
The summand argument smnd can be a real number, a complex number, a unit object, a local or
global name, or an algebraic object. The algebraic syntax for Σ differs from the stack syntax. The
algebraic syntax is: 'Σ(index=initial,final,summand)'
Access:
…½
(½ is the right-shift of the Skey).
Flags:
Symbolic Constants (–2), Numerical Results (–3)
Input/Output:
L4/A1
L3/A2
L2/A3
L1/A4
'indx'
xinit
xfinal
smnd
→
L1/I1
xsum
'indx'
'init'
xfinal
smnd
→
'Σ(indx = init, xfinal, smnd)'
'indx'
xinit
'final'
smnd
→
'Σ(indx = xinit, final, smnd)'
'indx'
'init'
'final'
smnd
→
'Σ(indx = init, final, smnd)'
L = Level; A = Argument; I = Item
Example:
See also:
The command sequence 'N' 1 5 'A^N' Σ returns
'(EXP(6*LN(A))-A)/(A-1)'.
TAYLR, ∫, ∂
Σ+
(Sigma Plus)
Type:
Command
Description:
Sigma Plus Command: Adds one or more data points to the current statistics matrix (reserved
variable ΣDAT).
For a statistics matrix with m columns, arguments for Σ+ can be entered several ways:
3-272 Full Command and Function Reference
Full Command and Function Reference 3-289
VPAR has the following form:
{ xleft, xright, ynear, yfar, zlow, zhigh, xmin, xmax, ymin, ymax, xeye, yeye, zeye, xstep, ystep }
For plot type WIREFRAME, the elements of VPAR are used as follows:
• xleft and xright are real numbers that specify the width of the view space.
• ynear and yfar are real numbers that specify the depth of the view space.
• zlow and zhigh are real numbers that specify the height of the view space.
• xmin and xmax are not used.
• ymin and ymax are not used.
• xeye, yeye, and zeye are real numbers that specify the point in space from which the graph is
viewed.
• xstep and ystep are real numbers that set the number of x-coordinates versus the number of ycoordinates plotted.
The plotting parameters are specified in the reserved variable PPAR, which has this form:
{ (xmin, ymin) (xmax, ymax) indep res axes ptype depend }
For plot type WIREFRAME, the elements of PPAR are used as follows:
• (xmin, ymin) is not used.
• (xmax, ymax) is not used.
• indep is a name specifying the independent variable. The default value of indep is X.
• res is not used.
• axes is not used.
• ptype is a name specifying the plot type. Executing the command WIREFRAME places the
command name WIREFRAME in ptype.
• depend is a name specifying the dependent variable. The default value is Y.
Access:
…µ WIREFRAME
Input/Output: None
See also:
BAR, CONIC DIFFEQ, FUNCTION, GRIDMAP, HISTOGRAM, PARAMETRIC,
PARSURFACE, PCONTOUR, POLAR, SCATTER, SLOPEFIELD, TRUTH, YSLICE
WSLOG
Type:
Description:
Command
Warmstart Log Command: Returns four strings recording the date, time, and cause of the four
most recent warmstart events.
Each string "logn" has the form "code–date time". The following table summarizes the legal values of
code and their meanings.
Code
Description
0
The warmstart log was cleared.
1
The interrupt system detected a very low battery condition at the battery contacts
(not the same as a low system voltage), and put the calculator in “Deep Sleep
mode” (with the system clock running). When $ is pressed after the battery voltage
is restored, the system warmstarts and puts a 1 in the log.
2
Hardware failed during transmission (timeout).
3
Run through address 0.
4
System time is corrupt
3-274 Full Command and Function Reference
The principal branch used by the calculator for √ was chosen because it is analytic in the regions
where the arguments of the real-valued inverse function are defined. The branch cut for the
complex-valued square root function occurs where the corresponding real-valued function is
undefined. The principal branch also preserves most of the important symmetries.
The graphs below show the domain and range of √. The graph of the domain shows where the
branch cut occurs: the heavy solid line marks one side of the cut, while the feathered lines mark
the other side of the cut. The graph of the range shows where each side of the cut is mapped
under the function.
Access:
Flags:
Input/Output:
These graphs show the inverse relation 's1*√Z' for the case s1=1. For the other value of s1, the
half-plane in the lower graph is rotated. Taken together, the half-planes cover the whole complex
plane, which is the domain of SQ.
View these graphs with domain and range reversed to see how the domain of SQ is restricted to
make an inverse function possible. Consider the half-plane in the lower graph as the restricted
domain Z = (x, y). SQ sends this domain onto the whole complex plane in the range W = (u, v) =
SQ(x, y) in the upper graph.
R
Principal Solution (–1), Numerical Results (–3)
Level 1/Argument 1
See also:
SQ, ^, ISOL
Level 1/Item 1
z
→
x_unit
→
'symb'
→
z
x unit
1⁄2
' ( symb ) '
Full Command and Function Reference 3-287
Access:
…µΣX2
Input/Output:
Level 1/Argument 1
Level 1/Item 1
→
See also:
ΣX^2
Type:
Description:
Sum of X2
NΣ, ΣX, XCOL, ΣXY, ΣY, ΣY2
Command
Sum of Squares of x-Values Command: Sums the squares of the values in the independentvariable column of the current statistical matrix. ΣX^2 is provided for compatibility with the HP
28. ΣX^2 is the same as ΣX2; see its listing for details.
Access:
XCOL
Type:
Description:
Access:
Input/Output:
Command
Independent Column Command: Specifies the independent-variable column of the current
statistics matrix (reserved variable ΣDAT).
The independent-variable column number is stored as the first parameter in the reserved variable
ΣPAR. The default independent-variable column number is 1.
XCOL will accept a noninteger real number and store it in ΣPAR, but subsequent commands that
utilize the XCOL specification in ΣPAR will cause an error.
…µXCOL
Level 1/Argument 1
See also:
XGET
Type:
Description:
Level 1/Item 1
→
ncol
BARPLOT, BESTFIT, COLΣ, CORR, COV, EXPFIT, HISTPLOT, LINFIT, LOGFIT, LR,
PREDX, PREDY, PWRFIT, SCATRPLOT, YCOL
Command
XModem Get Command: Retrieves a specified filename via XMODEM from another calculator.
The other calculator needs to be in server mode for the operation to work (G I/O FUNCTIONS
START SERVER).
Access:
…µ XGET
Input/Output:
Level 1/Argument 1
See also:
XMIT
Type:
Description:
ZFACTOR
Type:
Description:
Level 1/Item 1
→
'name'
BAUD, RECN, RECV, SEND, XRECV, XSERV, XPUT
Command
Serial Transmit Command: Sends a string serially without using Kermit protocol, and returns a
single digit that indicates whether the transmission was successful.
XMIT is useful for communicating with non-Kermit devices such as RS-232 printers.
If the transmission is successful, XMIT returns a 1. If the transmission is not successful, XMIT
returns the unsent portion of the string and a 0. Use ERRM to get the error message.
3-276 Full Command and Function Reference
Function
Gas Compressibility Z Factor Function: Calculates the gas compressibility correction factor for
non-ideal behavior of a hydrocarbon gas.
xTr is the reduced temperature: the ratio of the actual temperature (T) to the pseudocritical
temperature (Tc). (Calculate the ratio using absolute temperatures.) xTr must be between 1.05 and
3.0.
yPr is the reduced pressure: the ratio of the actual pressure (P) to the pseudocritical pressure (Pc).
yPr must be between 0 and 30.
xTr and yPr must be real numbers or unit objects that reduce to dimensionless numbers.
Access:
…µ ZFACTOR
Flags:
Numerical Results (–3)
Input/Output:
Level 2/Argument 1
ZVOL
Type:
Description:
Access:
Input/Output:
Level 1/Item 1
xTr
yPr
→
xTr
'symb'
→
xZfactor
'ZFACTOR(xTr,symb)'
'symb'
yPr
→
'ZFACTOR(symb,yPr)'
'symb1'
'symb2'
→
'ZFACTOR(symb1,symb2)'
Command
Z Volume Coordinates Command: Sets the height of the view volume in the reserved variable
VPAR.
xlow and xhigh are real numbers that set the z-coordinates for the view volume used in 3D plots.
These values are stored in the reserved variable VPAR.
…µ ZVOL
Level 2/Argument 1
See also:
Level 1/Argument 2
Level 1/Argument 2
xlow
xhigh
EYEPT, XVOL, XXRNG, YVOL, YYRNG
Level 1/Item 1
→
^
(Power)
Type:
Function
Description:
Power Analytic Function: Returns the value of the level 2 object raised to the power of the level 1
object. This can also apply to a square matrix raised to a whole-number power.
If either argument is complex, the result is complex.
The branch cuts and inverse relations for wz are determined by this relationship:
wz = exp(z(ln w))
Access:
Flags:
Q
Principal Solution (–1), Numerical Results (–3)
Full Command and Function Reference 3-285
!´ BASE L LOGIC XOR
( ´ is the left-shift of the Pkey).
Flags:
Binary Integer Wordsize (–5 through –10), Binary Integer Base (–11, –12)
Input/Output:
See also:
XPON
Type:
Description:
Level 2/Argument 1
Level 1/Argument 2
#n1
#n2
→
#n3
“string1”
“string2”
→
“string3”
T/F1
T/F2
→
0/1
T/F
'symb'
→
'T/F XOR symb'
'symb'
T/F
→
'symb XOR T/F'
'symb1'
'symb2'
→
'symb1 XOR symb2'
Level 1/Item 1
Function
Exponent Function: Returns the exponent of the argument.
( ´ is the left-shift of the Pkey).
x
Access:
Input/Output:
Level 1/Item 1
→
→
'symb'
1.2E34 XPON returns 34.
12.4E3 XPON returns 4.
'A*1E34' XPON returns 'XPON(A*1E34)'.
MANT, SIGN
Command
XModem Send Command: Sends a specified filename via XMODEM to a calculator. The
receiving calculator needs to be in Server mode (G I/O FUNCTIONS START SERVER).
…µ XPUT
Level 1/Argument 1
See also:
nexpon
'XPON(symb)'
Level 1/Item 1
→
'name'
BAUD, RECN, RECV, SEND XRECV, XSERV, XGET
XQ
Type:
Command
Description:
Converts a number, or a list of numbers in decimal format, to quotient (rational) format. Similar
to the →Qπ command, but also clears numeric constants mode (flag –2) and sets exact mode
(flag –105).
Access:
Catalog, …µ
Input:
A number, or a list of numbers.
Output:
The number or list of numbers in rational format. This rational number converts to the input
value to the accuracy of the current display setting.
3-278 Full Command and Function Reference
Command
y-Axis Display Range Command: Specifies the y-axis display range.
The y-axis display range is stored in the reserved variable PPAR as ymin and ymax in the complex
numbers (xmin, ymin) and (xmax, ymax). These complex numbers are the first two elements of PPAR
and specify the coordinates of the lower left and upper right corners of the display ranges.
The default values of ymin and ymax are –3.1 and 3.2, respectively for the HP 48gII and -3.9
and 4.0, respectively for the HP 50g and 49g+.
…µ YRNG
Level 2/Argument 1
See also:
Level 1/Argument 1
XPUT
Type:
Description:
Access:
Input/Output:
AND, NOT, OR
Access:
!´ REAL L XPON
Flags:
Numerical Results (–3)
Input/Output:
Example 1:
Example 2:
Example 3:
See also:
YRNG
Type:
Description:
Level 1/Argument 2
ymin
ymax
AUTO, PDIM, PMAX, PMIN, XRNG
Level 1/Item 1
→
YSLICE
Type:
Description:
Command
Y-Slice Plot Command: Sets the plot type to YSLICE.
When plot type is set YSLICE, the DRAW command plots a slicing view of a scalar function of
two variables. YSLICE requires values in the reserved variables EQ, VPAR, and PPAR.
VPAR has the following form:
{ xleft, xright, ynear, yfar, zlow, zhigh, xmin, xmax, ymin, ymax, xeye, yeye, zeye, xstep, ystep }
For plot type YSLICE, the elements of VPAR are used as follows:
• xleft and xright are real numbers that specify the width of the view space.
• ynear and yfar are real numbers that specify the depth of the view space.
• zlow and zhigh are real numbers that specify the height of the view space.
• xmin and xmax are not used.
• ymin and ymax are not used.
• xeye, yeye, and zeye are real numbers that specify the point in space from which the graph is
viewed.
• xstep determines the interval between plotted x-values within each “slice”.
• ystep determines the number of slices to draw.
The plotting parameters are specified in the reserved variable PPAR, which has this form:
{ (xmin, ymin), (xmax, ymax), indep, res, axes, ptype, depend }
For plot type YSLICE, the elements of PPAR are used as follows:
• (xmin, ymin) is not used.
• (xmax, ymax) is not used.
• indep is a name specifying the independent variable. The default value of indep is X.
• res is a real number specifying the interval, in user-unit coordinates, between plotted values of
the independent variable; or a binary integer specifying the interval in pixels. The default value is
0, which specifies an interval of 1 pixel.
• axes is not used.
• ptype is a command name specifying the plot type. Executing the command YSLICE places
YSLICE in ptype.
• depend is a name specifying the dependent variable. The default value is Y.
Access:
…µ YSLICE
Input/Output: None
See also:
BAR, CONIC, DIFFEQ, FUNCTION, GRIDMAP, HISTOGRAM, PARAMETRIC,
PARSURFACE, PCONTOUR, POLAR, SCATTER, SLOPEFIELD, TRUTH, WIREFRAME
Full Command and Function Reference 3-283
M Get the calculator memory
L: List the files in the current directory
Input/Output (RPN):
Level 2
Level 1
Level 1
y
x
→
x y
'symb1'
'symb2'
→
'XROOT(symb2,symb1)'
'symb'
x
→
'XROOT(x,symb)'
y
'symb'
→
'XROOT(symb,y)'
y_unit
x
→
y_unit
'symb'
→
x y
XSEND
Type:
Description:
Access:
Flags:
Input/Output:
Argument 2
_unit1/x
Level 1
See also:
XSERV
Type:
Description:
y x
y
x
→
'symb1'
'symb2'
→
'XROOT(symb1,symb2)'
'symb'
x
→
'XROOT(symb,x)'
y
'symb'
→
'XROOT(y,symb)'
x
y_unit
→
'symb'
y_unit
→
x y
_unit1/x
'name'
BAUD, RECN, RECV, SEND XRECV
Access:
Input/Output:
Level 1/Item 1
→
See also:
XXRNG
Type:
Description:
3-280 Full Command and Function Reference
Command
X Volume Coordinates Command: Sets the width of the view volume in the reserved variable
VPAR.
xleft and xright set the x-coordinates for the view volume used in 3D plots. These values are stored
in the reserved variable VPAR.
…µ XVOL
Level 1/Argument 2
xleft
xright
EYEPT, XXRNG, YVOL, YYRNG, ZVOL
Level 1/Item 1
→
Command
X Range of an Input Plane (Domain) Command: Specifies the x range of an input plane (domain)
for GRIDMAP and PARSURFACE plots.
xmin and xmax are real numbers that set the x-coordinates for the input plane. These values are
stored in the reserved variable VPAR.
Access:
…µ XXRNG
Input/Output:
Level 2/Argument 1
See also:
ΣXY
Type:
Description:
Access:
Input/Output:
Level 1/Argument 2
Level 1/Item 1
→
xmin
xmax
EYEPT, NUMX, NUMY, XVOL, YVOL, YYRNG, ZVOL
Command
Sum of X times Y command: Sums the products of each of the corresponding values in the
independent- and dependent-variable columns of the current statistical matrix (reserved variable
ΣDAT). The independent column is the column designated as XCOL and the dependent column
is the column designated as YCOL.
…µΣXY
Level 1/Argument 1
Level 1/Item 1
→
See also:
Command
XModem Server Command: Puts the calculator in XModem server mode. When in server mode,
the following commands are available:
P: Put a file in the calculator
G: Get a file from the calculator
E: Execute a command line
…µ XSERV
BAUD, RECN, RECV, SEND XRECV, XGET, XPUT
Level 2/Argument 1
'XROOT(symb,y_unit)'
Command
XModem Send Command: Sends a copy of the named object via XModem.
A receiving calculator must execute XRECV to receive an object via XModem.
The transfer occurs more quickly if you start the receiving XModem after executing XSEND.
Also, configuring the receiving modem not to do CRC checksums (if possible) will avoid a 30 to
60-second delay when starting the transfer.
If you are transferring data between two calculators, executing {AAA BBB CCC} XSEND
sends AAA, BBB, and CCC. You also need to use a list on the receiving end ({AAA BBB
CCC} XRECV, for example).
…µ XSEND
I/O Device (–33), I/O Device for Wire (–78)
Level 1/Argument 1
XVOL
Type:
Description:
'XROOT(symb,y_unit)'
Input/Output (ALG):
Argument 1
Access:
See also:
ΣX*Y
Type:
Description:
Sum of X*Y
NΣ, ΣX, XCOL, ΣXY, ΣX2, YCOL, ΣY2
Command
Sum of X times Y command: Sums the products of each of the corresponding values in the
independent- and dependent-variable columns of the current statistical matrix. ΣX*Y is provided
for compatibility with the HP 28. ΣX*Y is the same as ΣXY; see its listing for details.
Access:
Full Command and Function Reference 3-281
Voltage Divider (2, 3)
Input/Output:
See also:
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
z1
z2
→
z1 z2
[[ matrix ]]
[ array ]
→
[[ matrix × array ]]
z
[ array ]
→
[ z × array ]
[ array ]
z
→
[ array × z ]
z
'symb'
→
'z * symb'
'symb'
z
→
'symb * z'
'symb1'
'symb2'
→
'symb1 *symb2'
#n1
n2
→
#n3
n1
#n2
→
#n3
#n1
#n2
→
#n3
x_unit
y_unit
→
xy_unitx × unity
x
y_unit
→
xy_unit
x_unit
y
→
xy_unit
'symb'
x_unit
→
'symb * x_unit'
x_unit
'symb'
→
'x_unit * symb'
Equation:
R1
V1 = V ⋅  --------------------- 
 R1 + R2 
Example:
Given: R1=40_Ω, R2=10_Ω, V=100_V.
Solution: V1=80_V.
Current Divider (2, 4)
+, –, /, =
+
(Add)
Type:
Description:
Function
Add Analytic Function: Returns the sum of the arguments.
The sum of a real number a and a complex number (x, y) is the complex number (x+a, y).
The sum of two complex numbers (x1, y1) and (x2, y2) is the complex number (x1+x2, y1+y2).
The sum of a real array and a complex array is a complex array, where each element x of the real
array is treated as a complex element (x, 0). The arrays must have the same dimensions.
The sum of a binary integer and a real number is a binary integer that is the sum of the two
arguments, truncated to the current wordsize. (The real number is converted to a binary integer
before the addition.)
The sum of two binary integers is truncated to the current binary integer wordsize.
The sum of two unit objects is a unit object with the same dimensions as the second argument.
The units of the two arguments must be consistent.
The sum of two graphics objects is the same as the result of performing a logical OR, except that
the two graphics objects must have the same dimensions.
Common usage is ambiguous about some units of temperature. When ºC or ºF represents a
thermometer reading, then the temperature is a unit with an additive constant: 0 ºC = 273.15 K,
and 0ºF = 459.67ºR. But when ºC or ºF represents a difference in thermometer readings, then the
temperature is a unit with no additive constant: 1 ºC=1 K and 1 ºF =1 ºR.
The calculator assumes that the simple temperature units x_ºC and x_ºF represent thermometer
temperatures when used as arguments to the functions <, >, ≤, ≥, ==, and ≠. This means that, in
order to do the calculation, the calculator will first convert any Celsius temperature to Kelvin and
any Fahrenheit temperature to Rankine. (For other functions or compound temperature units, such
as x_ºC/min, the calculator assumes temperature units represent temperature differences, so there
is no additive constant involved, and hence no conversion.) The arithmetic operators +, –, %CH,
3-298 Full Command and Function Reference
Equation:
R2
I1 = I ⋅  --------------------- 
 R1 + R2 
Example:
Given: R1=10_Ω, R2=6_Ω, I=15_A.
Solution: I1=5.6250_A.
Wire Resistance (2, 5)
Equation:
ρ⋅L
R = ---------A
Equation Reference 5-11
Access:
Flags:
Input/Output:
Example 1:
Example 2:
Example 3:
See also:
The difference of two binary integers is a binary integer that is the sum of the first argument and
the two’s complement of the second argument.
The difference of two unit objects is a unit object with the same dimensions as the second
argument. The units of the two arguments must be consistent.
Common usage is ambiguous about some units of temperature. When ºC or ºF represents a
thermometer reading, then the temperature is a unit with an additive constant: 0 ºC = 273.15 K,
and 0 ºF = 459.67 ºR. But when ºC or ºF represents a difference in thermometer readings, then the
temperature is a unit with no additive constant: 1 ºC = 1 K and 1 ºF = 1 ºR.
The calculator assumes that the simple temperature units x_ºC and x_ºF represent thermometer
temperatures when used as arguments to the functions <, >, ≤, ≥, ==, and ≠. This means that, in
order to do the calculation, the calculator will first convert any Celsius temperature to Kelvin and
any Fahrenheit temperature to Rankine. (For other functions or compound temperature units, such
as x_ºC/min, the calculator assumes temperature units represent temperature differences, so there
is no additive constant involved, and hence no conversion.)
The arithmetic operators +, –, %, %CH, and %T treat temperatures as differences, without any
additive constant, but require both arguments to be either absolute (K and ºR), both ºC, or both
ºF. No other combinations are allowed.
Numerical Results (–3)
Level 1/Item 1
Electricity (2)
Variable
Description
∈r
Relative permittivity
µr
Relative permeability
ω
Angular frequency
ω0
Resonant angular frequency
φ
φp ,φs
ρ
Phase angle
Parallel and series phase angles
Resistivity
∆I
Current change
∆t
Time change
∆V
Voltage change
A
Level 2/Argument 1
Level 1/Argument 2
z1
z2
→
z1 – z2
C, C1, C2
[ array ]1
[ array ]2
→
[ array ]1–2
Cp,Cs
z
'symb'
→
'z – symb'
'symb'
z
→
'symb – z'
'symb1'
'symb2'
→
'symb1 – symb2'
#n1
n2
→
#n3
n1
#n2
→
#n3
Wire cross-section area (Wire Resistance), or Solenoid cross-section area
(Solenoid Inductance), or Plate area (Plate Capacitor)
Capacitance
Parallel and series capacitances
d
Plate separation
E
Energy
F
Force between charges
f
Frequency
#n1
#n2
→
#n3
f0
x1_unit1
y_unit2
→
(x2 – y)_unit2
I
Current, or Total current (Current Divider)
'symb'
x_unit
→
'symb – x_unit'
I1
Current in R1
→
x_unit
'symb'
'x_unit – symb'
25_ft 8_in - returns 292_in.
[[ 5 1 ][ 3 3 ]] [[ 2 1 ][ 0 1 ]] - returns
[[ 3 0 ][ 3 2 ]].
'TOTAL' 'PART' - returns 'TOTAL-PART'.
+, *, /, =
/
(Divide)
Type:
Function
Description:
Divide Analytic Function: Returns the quotient of the arguments: the first argument is divided by
the second argument.
A real number a divided by a complex number (x, y) returns:
Imax
L
Maximum current
Inductance, or Length (Wire Resistance, Cylindrical Capacitor)
L1,L2
Inductance
Lp,Ls
Parallel and series inductances
N
Number of turns
n
Number of turns per unit length
P
Power
q
Charge
q1,q2
3-300 Full Command and Function Reference
Resonant frequency
Point charge
Equation Reference 5-9
Common usage is ambiguous about some units of temperature. When ºC or ºF represents a
thermometer reading, then the temperature is a unit with an additive constant: 0 ºC = 273.15 K,
and 0ºF = 459.67ºR. But when ºC or ºF represents a difference in thermometer readings, then the
temperature is a unit with no additive constant: 1ºC=1 K and 1ºF = 1ºR.
The arithmetic operators +, –, %, %CH, and %T treat temperatures as differences, without any
additive constant. However, +, –, %CH, and %T require both arguments to be either absolute (K
and ºR), both ºC, or both ºF. No other combinations are allowed.
Access:
…Å
Flags:
Numerical Results (–3)
Input/Output:
(Å is the right-shift of the Wkey).
Level 2/Argument 1
See also:
Level 1/Argument 2
z1
z2
Level 1/Item 1
→
z1 = z2
'z = symb'
z
'symb'
→
'symb'
z
→
'symb = z'
'symb1'
'symb2'
→
'symb1 = symb2'
y_unit
x
→
y_unit1 = x
y_unit
x_unit
→
y_unit1 = x_unit
'symb'
x_unit
→
'symb = x_unit'
x_unit
DEFINE, EVAL, –
'symb'
→
'x_unit = symb'
==
(Logical Equality)
Type:
Function
Description:
Logical Equality Function: Tests if two objects are equal.
The function == returns a true result (1) if the two objects are the same type and have the same
value, or a false result (0) otherwise. Lists and programs are considered to have the same values if
the objects they contain are identical. If one object is algebraic (or a name), and the other is a
number (real or complex) or an algebraic, == returns a symbolic comparison expression that can
be evaluated to return a test result. Note that == is used for comparisons, while = separates two
sides of an equation. If the imaginary part of a complex number is 0, it is ignored when the
complex number is compared to a real number.
For unit objects, the two objects must be dimensionally consistent and are converted to common
units for comparison. If you use simple temperature units, the calculator assumes the values
represent temperatures and not differences in temperatures. For compound temperature units, the
calculator assumes temperature units represent temperature differences. For more information on
using temperature units with arithmetic functions, refer to the entry for +.
Access:
Flags:
Cantilever Deflection (1, 7)
!°TEST ==
Numerical Results (–3)
3-302 Full Command and Function Reference
( °is the left-shift of the Nkey).
Equation:
2
2
2
P⋅x
M⋅x
w⋅x
2
2
y = ----------------- ⋅ ( x – 3 ⋅ a ) + ----------------- – -------------------- ⋅ ( 6 ⋅ L – 4 ⋅ L ⋅ x + x )
6⋅E⋅I
2 ⋅ E ⋅ I 24 ⋅ E ⋅ I
Example:
Given: L=10_ft, E=29000000_psi, I=15_in^4, P=500_lbf, M=800_ft∗lbf, a=3_ft, c=6_ft, w=100_lbf/ft, x=8_ft.
Solution: y= -0.3316_in.
Cantilever Slope (1, 8)
Equation:
P⋅x
M⋅x
w⋅x
2
2
Θ = ----------------- ⋅ ( x – 2 ⋅ a ) + ------------ – ----------------- ⋅ ( 3 ⋅ L – 3 ⋅ L ⋅ x + x )
2⋅E⋅I
E⋅I 6⋅E⋅I
Example:
Given: L=10_ft, E=29000000_psi, I=15_in^4, P=500lbf, M=800_ft∗lbf, a=3_ft, c=6_ft, w=100_lbf/ft, x=8_ft.
Solution: Θ= -0.2652_°.
Cantilever Moment (1, 9)
Equation Reference 5-7
See also:
« → x y z 'x*y/2+z' »
is a user-defined function. Like a built-in function, a user-defined function can take its arguments
in stack syntax or algebraic syntax, and can take symbolic arguments. In addition, a user-defined
function is differentiable if its defining procedure is an algebraic expression that contains only
differentiable functions.
DEFINE, LOCAL, STO
Simple Deflection (1, 3)
;
(Semicolon)
Type:
Command
Description:
Drop Safe Command: Removes the level 1 object from the stack if there is one, otherwise does
nothing.
Access:
…&í when flag –51 is clear
( íis the right-shift of the #key)
…í when flag –51 is set
( íis the right-shift of the #key).
Equation:
y
Input/Output:
Level 1
obj
Level 1
P ⋅ (L – a ) ⋅ x
-------------------------------- ⋅ ( x
6 ⋅ L ⋅ E ⋅ I
2
+ (L – a)
2
2
– L
2
)
2
L
c
M ⋅ x
x
– ------------ ⋅  c – ----------- – --- – ----------- 
6 ⋅ L
3
2 ⋅ L
E ⋅ I
→
→
See also:
=
w ⋅ x
– -------------------- ⋅ ( L
24 ⋅ E ⋅ I
CLEAR, DROP, DROPN, DROP2
3
+ x
2
⋅ (x – 2 ⋅ L ))
Example:
Given: L=20_ft, E=29000000_psi, I=40_in^4, a=10_ft, P=674.427_lbf, c=17_ft, M=3687.81_ft∗lbf,
w=102.783_lbf/ft, x=9_ft.
Solution: y= -0.6005_in.
Simple Slope (1, 4)
Equation:
P ⋅ ( L – a)
2
2
2
Θ = ------------------------- ⋅ ( 3 ⋅ x + ( L – a ) – L )
6⋅L⋅E⋅I
2
2
M
x
L
c
– ---------- ⋅  c – ----------- – --- – ----------- 
E⋅I
2⋅L 3 2⋅L
w
3
2
– -------------------- ⋅ ( L + x ⋅ ( 4 ⋅ x – 6 ⋅ L ) )
24 ⋅ E ⋅ I
3-304 Full Command and Function Reference
Equation Reference 5-5
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
Many CAS commands will give numeric results instead of symbolic results if numeric mode is set instead of
being cleared. Though these results may be correct, they will not be what the user wants if a symbolic result
is needed. For this reason, the Flags section of most operation descriptions says that numeric mode should
not be set.
If approximate mode is set instead of exact mode, CAS commands will often give reasonable results, but
unexpected results can be obtained, because, for example, powers are real numbers, not integers, for
instance a cube will be treated as x3.0 instead of x3. For this reason, the Flags section of most operation
descriptions says that exact mode should be set. Some commands, like the numeric solvers, will only find
approximate solutions if approximate mode is set.
CAS operations are designed to work with integers if possible, and some CAS operations round their inputs
before using them. FIX 0 mode will round to whole numbers, losing accuracy. STD mode will retain full
accuracy, so it is the best display mode to use with the CAS and is used in most of the examples in this
chapter.
For the same reasons, the general solutions, symbolic constants and symbolic arguments flags (flags –1, –2
and –3) should normally be clear when working with the CAS.
Where possible, integer numbers should be used as input, not real numbers. The functions RND, CEIL and
FLOOR can round a real number to a whole real number, and RI will convert a whole real number to an
integer.
If complex inputs are given, approximate mode may need to be set to find solutions, and complex mode
must be set (flag –103 set).
Not only the trigonometry rewriting operations, but some other CAS operations require the angle mode to
be set to radians (flag –17 clear), even if it is not immediately obvious that this is so. For this reason, the
Flags section of many operation descriptions says that radians mode should be set.
Some CAS operations will work one step at a time if step-by-step mode is set (flag –100 set). If a result is
wanted immediately, and the calculator instead displays one step of the operation, cancel the operation, clear
flag –100, then repeat the operation.
If a mode needs to be changed for an operation to work, the calculator will by default ask if the mode can
be changed. If the Silent mode switch flag (flag –120) is set, the calculator changes the mode without asking.
If the mode switch disallowed flag (flag –123) is set, the mode will not be changed and an error will occur.
All the system flags from –99 to –128 are intended for use by the CAS. It is worth reading Appendix C in
the User’s Guide to learn the detailed effects of these flags on CAS operations and displays.
Remember that in RPN mode, symbolic expressions typed on the command line should be enclosed in
single quote marks ′x + y′. For clarity, it can be helpful to type expressions in single quote marks in
Algebraic mode too.
It is important to write symbolic expressions using the current variable. Some CAS operations will work
with this variable, but treat other variables simply as unknown numbers. If an expression has been entered
using a variable other than the current variable, it may be simpler to change the current variable in the CAS
MODES form, rather than rewrite the whole expression.
In algebraic mode (flag –95 set), some CAS commands will replace variables with their numeric values
before returning a result, even if “argument to symbolic” mode is set (flag –3 clear). In RPN mode, they will
be returned as variables. Some other CAS commands will always replace variables with their numeric results.
Because of the above, variables used in symbolic operations should not have the same names as variables
stored in the current directory/folder (or in directories above this directory). If, for example, x is the current
variable, and a variable called ′x′ exists in the current directory or in the HOME directory, then the value
stored in ′x′ might be used instead of the symbolic variable x.
The modulo value used in modulus calculations is 13 after the calculator is reset. If the CAS modes are reset
with CASCFG, the modulo is also 13, but if the modes are reset using !RESET as above, the modulo is 3,
otherwise it is the value most recently set. It is important to change this to the required value before carrying
out any modulus operations.
4-2 Computer Algebra System
Columns and Beams (1)
Variable
º
σcr
σmax
Description
Eccentricity (offset) of load
Critical stress
Maximum stress
θ
Slope at x
A
Cross-sectional area
a
Distance to point load
c
Distance to edge fiber (Eccentric Columns), or
Distance to applied moment (beams)
E
Modulus of elasticity
I
Moment of inertia
K
Effective length factor of column
L
Length of column or bean
M
Applied moment
Mx
Internal bending moment at x
P
Load (Eccentric Columns), or Point load (beams)
Pcr
Critical load
r
Radius of gyration
V
Shear force at x
w
Distributed load
x
Distance along beam
y
Deflection at x
For simply supported beams and cantilever beams (“Simple Deflection” through “Cantilever Shear”), the
calculations differ depending upon the location of x relative to the loads.
Applied loads are positive downward.
The applied moment is positive counterclockwise.
Deflection is positive upward.
Slope is positive counterclockwise
Internal bending moment is positive counterclockwise on the left-hand part.
Shear force is positive downward on the left-hand part.
Reference: 2.
Equation Reference 5-3
5
Computer algebra command categories listed by menu
CAS operations are listed here in order of the keyboard menus they appear in. These menus can be selected from
the CAS menu in G, or directly from the keyboard. A few CAS operations appear in more than one menu. Many
CAS commands are also available from the P menu, or from the „´ menu; these menus are not listed
here, to avoid duplication. The CAS has its own menu commands too, they are included in the alphabetical list of
commands. Operations that do not appear in any menu can be spelled out or selected from …µ.
Algebra commands, …×
COLLECT
..........................3-40
EXPAND
..........................3-80
FACTOR
..........................3-82
LIN
..........................3-131
LNCOLLECT .........................3-136
PARTFRAC ..........................3-164
SOLVE
..........................3-229
SUBST
..........................3-243
TEXPAND ..........................3-252
Arithmetic commands
Arithmetic Integer commands, !ÞINTEGER
EULER
..........................3-76
IABCUV
..........................3-108
IBERNOULLI..........................3-109
ICHINREM ..........................3-109
IDIV2
..........................3-111
IEGCD
..........................3-111
IQUOT
..........................3-120
IREMAINDER ........................3-121
ISPRIME?
..........................3-122
NEXTPRIME ..........................3-155
PA2B2
..........................3-162
PREVPRIME ..........................3-178
Arithmetic Polynomial commands, !ÞPOLYNOMIAL
ABCUV
..........................3-5
CHINREM ..........................3-34
CYCLOTOMIC .......................3-48
DIV2
..........................3-62
EGCD
..........................3-72
FACTOR
..........................3-82
FCOEF
..........................3-85
FROOTS
..........................3-92
GCD
..........................3-96
4-4 Computer Algebra System
5.Equation Reference
The Equation Library consists of 15 subjects and more than 100 titles. Each subject and title has a number that you
can use with SOLVEQN to specify the set of equations. These numbers are shown in parentheses after the
headings.
See the end of this section for references given in each subject. Remember that some equations are estimates and
assume certain conditions. See the references or other standard texts for assumptions and limitations of the
equations. Solutions in the examples have been rounded to four decimal places.
NOTE: You must set system flag –117 in order to enable the soft menus for Equation Library usage.
The next page is a handy one-page table of contents to the equations and groups within the library. The columns
headers provide the subject, the number of variables, the presence or absence of a picture, the number of equations
and the page number where the group can be found. The example shown below should be read as follows:
Subject, var (subj, title) Pic EQ Pg
COLUMNS AND BEAMS, 22 **********(1)***
Elastic Buckling (1,1)
Y
4 5-4
COLUMNS AND BEAMS, 22 **********(1)***
Columns and beams – The group header.
22 – The number of variables in the group.
(1) – Indicates that Columns and beams are the first group.
Elastic Buckling (1,1)
Y
4 5-4
Elastic Buckling – The subject area of the first set of equations.
(1,1) – Indicates that Elastic Buckling is the first subject area within the columns and beams group.
Y – Indicates that a picture is present for this subject area.
4 – Indicates that there are 4 equations in this subject area.
5-4 – Indicates this subject area can be found on page 5-4.
It is provided as a quick reference.
Equation Reference 5-1
Calculus commands
Derivation and integration commands, !ÖDERIV. & INTEG.
CURL
..........................3-48
DERIV
..........................3-56
DERVX
..........................3-56
DIV
..........................3-62
FOURIER
..........................3-91
HESS
..........................3-104
IBP
..........................3-109
INTVX
..........................3-119
LAPL
..........................3-127
PREVAL
..........................3-177
RISCH
..........................3-202
SIGMA
..........................3-222
SIGMAVX
..........................3-223
Limits and series commands, !ÖLIMITS & SERIES
DIVPC
..........................3-63
lim
..........................3-131
SERIES
..........................3-220
TAYLOR0
..........................3-250
TAYLR
..........................3-250
Differential equations commands, !ÖDIFFERENTIAL EQNS
DESOLVE ..........................3-56
ILAP
..........................3-114
LAP
..........................3-127
LDEC
..........................3-129
Graphing commands, !ÖGRAPH
DEFINE
..........................3-52
GROBADD ..........................3-101
PLOT
..........................3-171
PLOTADD ..........................3-171
SIGNTAB
..........................3-224
TABVAL
..........................3-246
TABVAR
..........................3-247
Other Calculus commands, !Ö
DERVX
..........................3-56
INTVX
..........................3-119
Matrix convert, !Ú MATRIX CONVERT
AXL
.......................... 3-25
AXQ
.......................... 3-26
QXA
.......................... 3-190
SYST2MAT .......................... 3-245
Other CAS operations, …µ
These operations are in other menus, as described in Access for each one, or can be accessed with
…µ.
Other mathematics operations
DEGREE
.......................... 3-53
DOMAIN
.......................... 3-66
DROITE
.......................... 3-69
dn
.......................... 3-64
EPSX0
.......................... 3-74
EXLR
.......................... 3-77
EXP2HYP
.......................... 3-79
FXND
.......................... 3-94
GBASIS
.......................... 3-95
GREDUCE .......................... 3-99
LCXM
.......................... 3-129
LIMIT
.......................... 3-131
LNAME
.......................... 3-136
LVAR
.......................... 3-140
MSLV
.......................... 3-152
P2C
.......................... 3-162
POTENTIAL .......................... 3-174
REORDER .......................... 3-199
RREFMOD .......................... 3-211
SEVAL
.......................... 3-221
TAN2CS2
.......................... 3-248
TCHEBYCHEFF ................... 3-250
TRUNC
.......................... 3-259
VPOTENTIAL ........................ 3-271
XNUM
.......................... 3-277
XQ
.......................... 3-278
?
.......................... 3-288
∞
.......................... 3-289
These two operations are available directly from the CALC menu as well as being in the Derivation and
Integration commands menu.
4-6 Computer Algebra System
Computer Algebra System 4-11
TRACE
TRAN
..........................3-255
..........................3-255
Symbolic solve commands, !Î
Operations, !Ø FACTORIZATION
LQ
..........................3-138
LU
..........................3-139
QR
..........................3-188
qr
..........................3-188
SCHUR
..........................3-218
SVD
..........................3-244
SVL
..........................3-244
Quadratic form, !Ø QUADRATIC FORM
AXQ
..........................3-26
CHOLESKY ..........................3-34
GAUSS
..........................3-95
QXA
..........................3-190
SYLVESTER ..........................3-245
Linear Systems, !Ø LINEAR SYSTEMS
LINSOLVE ..........................3-133
REF
..........................3-198
rref
..........................3-210
RREF
..........................3-210
SYST2MAT ..........................3-245
Linear Applications, !Ø
IMAGE
..........................3-115
ISOM
..........................3-121
KER
..........................3-123
MKISOM
..........................3-149
LINEAR APPL
Eigenvectors, !Ø EIGENVECTORS
DIAGMAP ..........................3-58
EGV
..........................3-73
EGVL
..........................3-73
JORDAN
..........................3-122
PCAR
..........................3-165
PMINI
..........................3-172
DESOLVE
ISOL
LDEC
LINSOLVE
SOLVEVX
SOLVE
ZEROS
.......................... 3-56
.......................... 3-121
.......................... 3-129
.......................... 3-133
.......................... 3-229
.......................... 3-229
.......................... 3-284
Trigonometry commands
Hyperbolic,
ACOSH
ASINH
ATANH
COSH
SINH
TANH
…Ñ HYPERBOLIC
.......................... 3-8
.......................... 3-17
.......................... 3-22
.......................... 3-46
.......................... 3-226
.......................... 3-249
Other Trigonometry commands, …Ñ
ACOS2S
.......................... 3-7
ASIN2C
.......................... 3-17
ASIN2T
.......................... 3-17
ATAN2S
.......................... 3-21
HALFTAN .......................... 3-102
SINCOS
.......................... 3-225
TAN2SC
.......................... 3-248
TAN2SC2
.......................... 3-249
TCOLLECT .......................... 3-251
TEXPAND .......................... 3-252
TLIN
.......................... 3-254
TRIG
.......................... 3-256
TRIGCOS
.......................... 3-257
TRIGSIN
.......................... 3-257
TRIGTAN
.......................... 3-257
TSIMP ....................................... 3-260
Vector, !Ø VECTOR
BASIS
..........................3-27
CROSS
..........................3-47
DOT
..........................3-67
GRAMSCHMIDT ...................3-99
IBASIS
..........................3-109
4-8 Computer Algebra System
Computer Algebra System 4-9
RLC Current Delay (2, 11)
Example:
Given: xm=10_cm, ω=15_r/s, φ=25_°, t=25_µs.
Solution: x=9.0615_cm, v= -0.6344_m/s, a= -20.3884_m/s^2, f= 2.3873_Hz.
Plane Geometry (11)
Variable
The phase delay (angle) is positive for current lagging voltage.
Equations:
1
1
-------- – ------XC XL
TA N( φp ) = ---------------------1
--R
XL – XC
TA N( φ s ) = ----------------------R
1
X C = -----------ω⋅C
XL = ω ⋅ L
ω = 2⋅π⋅f
Example:
Given: f= 1107_Hz, C=80_µf, L=20_ mH, R=5_Ω.
Solution: ω=672.3008_r/s, φs= -45.8292_°, φp= -5.8772_°, XC=18.5929_Ω, XL=13.4460_Ω.
DC Capacitor Current (2, 12)
These equations approximate the dc current required to charge the voltage on a capacitor in a certain time interval.
Equations:
∆V
I = C ⋅  -------- 
 ∆t 
∆V = – Vf – Vi
∆t = tf ⋅ ti
Example:
Given: C=15_µf, Vi=2.3_V, Vf=3.2_ V, I=10_A, ti=0_s.
Solution: ∆V=0.9000_V, ∆t=1.3500_µs, tf=1.3500_µs.
Capacitor Charge (2, 13)
Equation:
q = C⋅V
Description
β
Central angle of polygon
θ
Vertex angle of polygon
A
Area
b
Base length (Rectangle, Triangle), or
Length of semiaxis in x direction (Ellipse)
C
Circumference
d
Distance to rotation axis in y direction
h
Height (Rectangle, Triangle), or
Length of semiaxis in y direction (Ellipse)
I, Ix
Moment of inertia about x axis
Id
Moment of inertia in x direction at d
Iy
Moment of inertia about y axis
J
Polar moment of inertia at centroid
L
Side length of polygon
n
Number of sides
P
Perimeter
r
Radius
ri, ro
rs
Inside and outside radii
Distance to side of polygon
rv
Distance to vertex of polygon
v
Horizontal distance to vertex
Reference: 4.
Example:
Given: C=20_µF, V=100_V.
Solution: q=0.0020_C.
5-14 Equation Reference
Equation Reference 5-43
Solution: I=0.0072_A.
Mass-Spring System (10, 1)
Resonant Frequency (2, 17)
Equation:
1
L⋅C
ω 0 = ---------------
1
C
Qs = --- ⋅ --R
L
C
Qp = R ⋅ --L
ω 0 = 2 ⋅ π ⋅ f0
Example:
Given: L=500_mH, C=8_µF, R=10_ω.
Solution: ω0=500_r / s, Qs=25.0000, Qp=0.0400, f0=79.5775_Hz.
Equations:
Plate Capacitor (2, 18)
ω =
k
---m
2⋅π
T = ---------ω
ω = 2⋅π⋅f
Example:
Given: k=20_N/m, m=5_kg.
Solution: ω=2_r/s. T=3.1416_s, f=.3183_Hz.
Equation:
∈0 ⋅ ∈ r ⋅ A
C = -----------------------d
Simple Pendulum (10, 2)
Example:
Given: C=25_µF, ∈r=2.26, A=1_cm^2.
Solution: d=8.0042E-9_cm.
Cylindrical Capacitor (2,19)
Equations:
ω =
g
--L
2⋅π
T = ----------
ω
ω = 2⋅π⋅ f
Example:
Given: L=15_cm.
Solution: ω=8.0856_r/s. T= 0.7771_s, f=1.2869_Hz.
Equation:
2 ⋅ π ⋅∈ 0 ⋅∈ r ⋅ L
C = --------------------------------------ro
LN ---- 
 ri 
5-16 Equation Reference
Equation Reference 5-41
Sinusoidal Voltage (2, 22)
Spherical Reflection (9, 4)
Equations:
V = V ma x ⋅ S IN(ω ⋅ t + φ)
ω = 2⋅π⋅f
Example:
Given: Vmax=110_V, t=30_µs, f=60_Hz, φ=15_°.
Solution: ω=376.9911_r/s, V=29.6699_V.
Sinusoidal Current (2, 23)
Equations:
Equations:
I = Ima x ⋅ S IN( ω ⋅ t + φ)
Example:
Given: t=32_s, Imax=10_A, ω=636_r/s, φ=30_°.
Solution: I=9.5983_A, f=101.2225_Hz.
Fluids (3)
Variable
Roughness
Dynamic viscosity
ρ
Density
Height change
ΣK
Total fitting coefficients
D
D1, D2
h
hL
Example:
Given: u=10_cm, v=300_cm, r=19.35_cm.
Solution: m=-30, f=9.6774_cm.
Pressure change
∆y
A1,A2
–v
m = -----u
Spherical Refraction (9, 5)
µ
A
1
f = --- ⋅ r
2
Description
∈
∆P
1 1
1
--- + --- = --u v
f
ω = 2⋅π⋅f
Cross-sectional area
Equation:
n1 n2
n2 – n1
------ + ------ = -----------------u
v
r
Initial and final cross-sectional areas
Diameter
Initial and final diameters
Depth relative to P0 reference depth
Example:
Given: u=8_cm, v=12_cm, r=2_cm, n1=1.
Solution: n2=1.5000.
Head loss
L
Length
Thin Lens (9, 6)
M
Mass flow rate
r1 is for the front surface, and r2 is for the back surface.
n
Kinematic viscosity
P
Pressure at h
P0
P1, P2
Q
Reference pressure
Initial and final pressures
Volume flow rate
5-18 Equation Reference
Equation Reference 5-39
Equations:
2
2
∆P v 2 – v 1
------ + ----------------------- + g ⋅ ∆y = 0
2
ρ
2
A2 2
v 2 ⋅  1 –  -------  
A1
∆P
------ + -------------------------------------------- + g ⋅ ∆y = 0
2
ρ
2
A2 2
v 1 ⋅   -------  – 1
A1
∆P
------ + --------------------------------------------- + g ⋅ ∆y = 0
2
ρ
∆P = P 2 – P 1
∆y = y 2 – y 1
Optics (9)
Variable
M = ρ⋅Q
θ1
Angle of incidence
θ2
Angle of refraction
θB
Brewster angle
θc
Critical angle
f
Focal length
m
Magnification
Q = A1 – v1
Q = A2 – v2
2
2
π ⋅ D1
A 1 = ----------------4
π ⋅ D2
A 2 = ----------------4
Example:
Given: P2=25_psi, P1=75_psi, y2=35_ft, y1=0_fr, D1=18_in, ρ=64_lb/ft^3, v1=100_ft/s.
Solution: Q=10602.8752_ft^3/min, M=678584.0132_lb/min, v2=122.4213_ft/s, A2=207.8633_in^2,
D2=16.2684_in, A1=254.4690_in^2, ∆P= -50_psi, ∆y=35_ft.
Flow with Losses (3, 3)
Description
n, n1, n2
Index of refraction
r, r1, r2
Radius of curvature
u
Distance to object
v
Distance to image
These equations extend Bernoulli’s equation to include power input (or output) and head loss.
For reflection and refraction problems, the focal length and radius of curvature are positive in the direction of the
outgoing light (reflected or refracted). The object distance is positive in front of the surface. The image distance is
positive in the direction of the outgoing light (reflected or refracted). The magnification is positive for an upright
image. Reference: 3.
Law of Refraction (9, 1)
Equations:
2
2
∆P v 2 – v 1
M ⋅  ------ + ----------------------- + g ⋅ ∆y + h L = W
2
ρ
2
A2 2


v 2 ⋅  1 –  -------  
 ∆P

A1
M ⋅  ------ + -------------------------------------------- + g ⋅ ∆y + h L = W
2
 ρ



2
2
A1


v 1 ⋅   -------  – 1
 ∆P

A2
M ⋅  ------ + -------------------------------------------- + g ⋅ ∆y + h L = W
2
ρ



∆P = P 2 – P 1
∆y = y 2 – y 1
Q = A2 ⋅ v2
2
π ⋅ D1
A 1 = ----------------4
5-20 Equation Reference
M = ρ⋅Q
Equation:
n1 ⋅ S IN ( θ 1 ) = n2 ⋅ S IN( θ 2 )
Example:
Given: n1=1, n2=1.333, θ1=45_°.
Q = A1 ⋅ v1
2
Solution: θ2=32.0367_°.
π ⋅ D2
A 2 = ----------------4
Equation Reference 5-37
Linear Motion (8, 1)
Variable
A
Description
Equations:
Projected area relative to flow
ar
Centripetal acceleration at r
at
Tangential acceleration at r
Cd
Drag coefficient
E
Energy
F
Force at r or x, or Spring force (Hooke’s Law), or attractive
force (Law of Gravitation), or Drag force (Drag force)
I
Moment of inertia
k
Spring constant
Ki,Kf
N
Ni, Nf
P
Pavg
Given: x0=0_m, x=100_m, t=10_s, v0=1_m/s
2
1
y = y0 + v0 ⋅ t + --- ⋅ g ⋅ t
2
2
v = v0 + g ⋅ t
Example:
Given: y0=1000_ft, y=0_ft, v0=0_ft/s
Instantaneous power
Solution: t=7.8843_s, v= -253.6991_ft/s.
Time
Velocity
Projectile Motion (8, 3)
Final velocity
Initial velocity
Work
Displacement
Equations:
2
1
y = y 0 + v0 ⋅ S IN( θ 0 ) ⋅ t – -- ⋅ g ⋅ t
2
x = x 0 + v 0 ⋅ C OS ( θ 0 ) ⋅ t
Reference: 3.
2
v0
R = -------- ⋅ S IN( 2 ⋅ θ 0 )
g
Equations:
1
2
Ki = --- ⋅ m ⋅ vi
2
P = F⋅v
1
2
Kf = --- ⋅ m ⋅ vf
2
W
Pavg = ----t
vy = v 0 ⋅ S IN( θ 0 ) – g ⋅ t
vx = v 0 ⋅ C OS ( θ 0 )
Linear Mechanics (4, 1)
W = Kf – Ki
2
Initial and final rotational speeds
t
F = m⋅a
1
2
y = y0 + v ⋅ t + --- ⋅ g ⋅ t
2
Rotational speed
v
x
Object in Free Fall (8, 2)
v = v0 + 2 ⋅ g ⋅ ( y + y0 )
Mass
Radius from rotation axis, or
Separation distance (Law of Gravitation)
W
Solution: v=19_m/s, a=1.8_m/s^2.
Equations:
r
vi, v1i
v = v0 + a ⋅ t
Example:
Average power
vf, v1f, v2f
1
2
x = x0 + v ⋅ t + --- ⋅ a ⋅ t
2
1
x = x0 + --- ⋅ ( v0 + v ) ⋅ t
2
Initial and final kinetic energies
m, m1, m2
1
2
x = x0 + v0 ⋅ t + --- ⋅ a ⋅ t
2
W = F⋅x
vf = vi + a ⋅ t
Example:
Example:
Given: x0=0_ft, y0=0_ft, Θ 0 =45_°, v0=200_ft/s, t=10_s.
Solution: R=1243.2399_ft, vx=141.4214_ft/s, vy= -180.3186_ft/s, x=1414.2136_ft, y= -194.4864_ft.
Given: t=10_s, m=50_lb, a=12.5_ft/s^2, vi=0_ft/s.
Solution: vf=125_ft/s, x=625_ft, F=19.4256_lbf, Ki=0_ft∗lbf, Kf=12140.9961_ft∗lbf, W=12140.9961_ft∗lbf,
Pavg=2.2075_hp.
5-22 Equation Reference
Equation Reference 5-35
1D Elastic Collisions (4, 5)
Magnetic (B) Field in Solenoid (7, 3)
Equations:
Equation:
m1 – m2
v1f = ---------------------- ⋅ v1i
m1 + m2
B = µ0 ⋅ µr ⋅ I ⋅ n
2 ⋅ m1
v2f = ---------------------- ⋅ v1i
m1 + m 2
Example:
Example:
Given: m1=10_kg, m2=25_kg, vli=100_m/s.
Solution: v1f=-42.8571_m/s, v2f=57.1429_m/s.
Given: µr=10, n=50, I=1.25_A.
Solution: B=0.0785_T.
Magnetic (B) Field in Toroid (7, 4)
Drag Force (4, 6)
Equation:
2
ρ⋅v
F = C d ⋅  ------------  ⋅ A
 2 
Example:
Given: Cd=.05, ρ=1000_kg/m^3, A=7.5E6_cm^2, v=35_m/s.
Solution: F=22968750_N.
Law of Gravitation (4, 7)
Equation:
0⋅ r⋅I⋅N  2 
------------µ
--------------------- ⋅ --------------B = µ
 ro + r i 
2⋅π
Equation:
m1 ⋅ m2 
F = G ⋅  ------------------2


r
Example:
Example:
Given: µr=10, N=50, ri=5_cm, ro=7_cm, I=10_A.
Given: m1=2E15_kg, m2=2E18_kg, r=1000000_km.
Solution: B=1.6667E–2_T.
Solution: F=266903.6_N.
Mass-Energy Relation (4, 8)
Equation:
E = m⋅c
2
Example:
Given: m=9.1E-31_kg.
Solution: E=8.1787E-14_J.
5-24 Equation Reference
Equation Reference 5-33
Example:
Black Body Radiation (6, 6)
Given: T=16.85_°C, P=1_atm, V=25_1, MW=36_g/gmol.
(See “F0λ” in Chapter 3.)
Solution: n=1.0506_gmol, m=3.7820E-2_kg.
Ideal Gas State Change (5, 2)
Equation:
Pf ⋅ Vf
Pi ⋅ Vi
---------------- = ---------------Tf
Ti
Example:
Given: Pi=1.5_kPa, Pf=1.5kPa, Vi=2_l, Ti=100_°C, Tf=373.15_K.
Equations:
Solution: Vf=2_1.
eb = σ ⋅ T
Isothermal Expansion (5, 3)
e B1 2 f ⋅ e b
=
4
f = F0 λ ( λ 2 ; T ) – F0 λ ( λ 1 ; T )
λ ma x ⋅ T = c 3
q = eb ⋅ A
These equations apply to an ideal gas.
Example:
Equations:
Given: T=1000_°C, λ1=1000_nm, λ2=600_nm, A=1_cm^2.
Vf
W = n ⋅ R ⋅ T ⋅ LN  ------ 
 Vi 
m = n ⋅ MW
Solution: λmax=2276.0523_nm, eb=148984.2703_W/m^2, f=.0036, eb12=537.7264_W/m^2, q=14.8984_W.
Magnetism (7)
Example:
Given: Vi=2_l, Vf=125_l, T=300_°C, n=0.25_gmol, MW=64_g/gmol.
Solution: W=4926.4942_J, M=0.016_kg.
Polytropic Processes (5, 4)
These equations describe a reversible pressure-volume change of an ideal gas such that P ∗Vn is constant. Special
cases include isothermal processes (n=1), isentropic processes (n=k, the specific heat ratio), and constant-pressure
processes (n=0).
Equations:
Pf
Vf – n
----- =  ------ 
 Vi 
Pi
Tf
Pf
------ =  ----- 
 Pi 
Ti
n–1
-----------n
Example:
Given: Pi=15_psi, Pf=35_psi, Vi=1_ft^3, Vf=0.50_ft^3, Ti=75_°F.
Solution: n=1.2224, Tf=164.1117_°F.
Isentropic Flow (5, 5)
Variable
Description
µr
Relative permeability
B
Magnetic field
d
Separation distance
Fba
I, Ia, Ib
Force
Current
L
Length
N
Total number of turns
n
Number of turns per unit length
r
Distance from center of wire
ri, ro
rw
Inside and outside radii of toroid
Radius of wire
Reference: 3.
The calculation differs at velocities below and above Mach 1. The Mach number is based on the speed of sound in
the compressible fluid.
5-26 Equation Reference
Equation Reference 5-31
Kinetic Theory (5, 8)
Heat Capacity (6, 1)
These equations describe properties of an ideal gas.
Equations:
Equations:
Q = m ⋅ c ⋅ ∆T
2
n ⋅ MW ⋅ vrms
P = --------------------------------------3⋅V
vrms =
1
λ = --------------------------------------------------n ⋅ NA
2
2 ⋅ π ⋅  ---------------- ⋅ d
 V 
3⋅R⋅T
------------------MW
m = n ⋅ MW
Example:
Given: P=100_kPa, V=2_1, T=26.85_°C, MW=18_g/gmol, d=2.5_nm.
Q = m ⋅ c ⋅ ( Tf – Ti )
Example:
Given: ∆T=15_°C, Ti=0_°C, m=10_kg, Q=25_kJ.
Solution: Tf=15_°C, c=.1667_kJ/(kg∗K)
Thermal Expansion (6, 2)
Solution: vrms=644.7678_m/s, m=1.4433E–3_kg, n=0.0802_gmol, λ=1.4916_nm.
Heat Transfer (6)
Variable
α
δ
Description
Expansion coefficient
Elongation
λ1, λ2
Lower and upper wavelength limits
λmax
Wavelength of maximum emissive power
∆T
Temperature difference
A
Area
c
eb12
eb
f
h, h1,h3
Specific heat
Emissive power in the range λ1 to λ2
Total emissive power
Fraction of emissive power in the range λ1 to λ2
Convective heat-transfer coefficient
k, k1, k2, k3
Thermal conductivity
L, L1, L2, L3
Length
Equations:
δ = α ⋅ L ⋅ ∆T
Example:
Given: ∆T=15_°C, L=10_m, Tf=25_°C, δ=1_cm.
Solution: Ti=10_°C, α=6.6667E–5_1/°C.
Conduction (6, 3)
m
Mass
Q
Heat capacity
q
Heat transfer rate
T
Temperature
Tc
Cold surface temperature (Conduction), or
Cold fluid temperature
Hot surface temperature, or
Hot fluid temperature (Conduction + Convection)
Equations:
Initial and final temperature
Overall heat transfer coefficient
Example:
Th
Ti, Tf
U
References: 7, 9.
5-28 Equation Reference
δ = α ⋅ L ⋅ ( Tf – Ti )
k⋅A
q = ----------- ⋅ ∆T
L
k⋅A
q = ----------- ⋅ ( Th – Tc )
L
Given: Tc=25_°C, Th=75_°C, A=12.5_m^2, L=1.5_cm, k=0.12_W/ (m∗K)
Solution: q=5000_W, ∆T= 50_°C.
Equation Reference 5-29
Circular Ring (11, 5)
Define Error
ARM register expected
ARM invalid imediate
You can not do this operation in a DEFINE
No comments.
In ARM mode, constants must be representable on 8 bit with
an even number of rotation
Links
Links are secondary source files that MASD can be directed to compile (equivalent to the {$I} directive in Pascal
and #include in C). As there is no linking phase with MASD (like in C), a multi source project will usually have the
form of a main source file that contains a certain number of links.
Equations:
2
π
4
4
I = --- ⋅ ( ro – ri )
4
2
A = π ⋅ ( ro – ri )
π
4
4
J = --- ⋅ ( ro – ri )
2
Id = I + A ⋅ d
2
Example:
Given: ro=4_µ, ri=25.0Å, d=.1_mil.
Solution: A=3.0631E–7_cm^2, I=1.7038E–10_mm^4, J=3.4076E–10_mm^4, Id=3.0648E–10_mm^4.
Triangle (11, 6)
An example of main source would be:
"
'Constant_definition
'initialization
'graphic_functions
'other
@"
When a link call is encountered, MASD suspends compilation of the current source, compiles the new source and
then continues compiling the first one.
Program and data in the final object will be in the order in which MASD encounters the links.
Syntax in ASM and ARM mode:
'FileName
links the file called FileName.
Syntax in RPL mode:
INCLUDE FileName
links the file called FileName.
Notes:
1. A link can call other links
2. You can not use more than 64 links in your project
3. To know how MASD looks for files, see the File search section
4. Links are useful to cut projects in independent parts to allow fast and easy access to source code
5. It is beneficial to place all constants definitions at the beginning of the compilation process as this will speed up
compilation and give more flexibility
Equations:
b⋅h
A = ---------2
3
b⋅h
Ix = ------------36
2
2
2
P = b + v + h + ( b – v) + h
2
b⋅h
2
2
Iy = ---------- ⋅ ( b – b ⋅ v + v )
36
b⋅h
2
2
2
J = ---------- ⋅ ( h + b – b ⋅ v + v )
36
Id = Ix + A ⋅ d
Labels
A label is a marker in the program. The principal use of labels is to determine jump destinations.
2
Example:
Given: h=4.33012781892_in, v=2.5_in, P=15_in, d=2_in.
Solution: b=5.0000_in, Ix=11.2764_in^4, Iy=11.2764_in^4, J=22.5527_in^4, A=10.8253_in^2,
Id=54.5776_in^4.
A label is a set of less than 64 characters other than space, ‘+’, ‘-’, ‘*’ and ‘/’. A label begins with a star ‘*’ and
ends with a separation character.
Syntax in ASM and ARM mode:
*BigLoop
is the BigLoop label declaration.
Syntax in RPL mode:
LABEL BigLoop
is the BigLoop label declaration.
Be careful about upper and lower cases!
Three types of labels can be used:
• Global labels
A global label is a label that can be used everywhere in the project, like global variables in Pascal or C.
• Local labels
5-46 Equation Reference
The Development Library 6-13
Cylinder (12, 2)
MASD – The Machine Language and System RPL Compiler
MASD is used for compiling assembly language and System RPL.
Introduction
Warnings
The operating system can not control what a low level program is doing. Therefore, any programming error is likely
to cause the calculator to crash (with potential memory loss). A careful developer will always save source code in the
internal flash ROM or port 1 for protection before trying low level programs.
Equations:
2
2
A = 2⋅π⋅r +2⋅π⋅r⋅h
V = π⋅r ⋅h
1
2
Izz = --- ⋅ m ⋅ r
2
2
2
1
1
Ixx = --- ⋅ m ⋅ r + ------ ⋅ m ⋅ h
4
12
Id = Ixx + m ⋅ d
This document does not intend to be a programming course — it just presents the syntax of the compiler. Ample
resources are available on the web (www.hpcalc.org) to learn how to program the Saturn CPU in assembler, how to
program in System RPL or how to program in ARM assembly.
With the introduction of the new ARM based series of calculators, some new things have been included that are not
backward compatible with previous calculators. The careful programmer should be wary of this.
2
Starting MASD
Example:
To compile a program, put the source code on the level 1 of the stack and type ASM (the development library
must be attached) or use the ASM menu of the Development library.
Given: r=8.5_in, h=65_in, m=12000_lbs, d=2.5_in.
Solution: V=14753.7045_in^3, A=3925.4200_in^2, Izz=4441750_lb∗in^2, Izz=433500_lb∗in^2,
Id=4516750_lb∗in^2.
If you have a new version of MASD packaged as a library 259, the command to type is asm (note the lowercase).
Parallelepiped (12, 3)
MASD can be used to compile program in 3 different languages: Saturn ASM, ARM ASM and System RPL.
Although some things are common to all modes, some are not. As a programmer, you should always know the
current mode.
Modes
Compilation directives instructions are used to switch from one mode to another:
!ASM (switch to Saturn ASM mode, referred in the rest of this document as the Saturn mode)
!RPL (switch to System RPL mode)
!ARM (switches to ARM ASM mode)
In addition, in RPL mode,
CODE
% here we are in ASM mode
ENDCODE
Allows switching from RPL mode to Saturn mode (and generate an assembly program object)
Equations:
V = b⋅h⋅t
1
2
2
I = ------ ⋅ m ( h + t )
12
A = 2 ⋅ ( b ⋅ h + b ⋅ t + h ⋅ t)
Id = I + m ⋅ d
2
Example:
Given: b=36_in, h=12_in, t=72_in, m=83_lb, d=7_in.
Solution: V=31104_in^3, A=7776_IN^2, I=36852_lb∗in^2, Id=40919_lb∗in^2.
Syntax
MASD expects a character string (called source) on the stack level 1. A source is a set of instructions, comments,
and separation characters and ends with a carriage return and an @ character. MASD is case sensitive, so be careful,
as «loop» and «LOOP» are two different things for MASD. Separation characters are those with an ASCII
number below 32. They include spaces, tabs, line feed and carriage return.
In Saturn mode, some instructions need a parameter. Separation characters between an instruction and the
parameter are spaces, tabs, and points. Therefore A+B.A can be used instead of A+B A.
In ARM mode, parameters for the instruction are separated by spaces and commas. In Saturn or ARM mode,
comments can be placed everywhere and begin with % or ; and finish at the end of the current line.
In RPL mode, comments are delimited by ‘(’ ‘)’ as isolated characters and can be multi line. A line that starts with
a ‘*’ on the first character will also be considered a comment.
5-48 Equation Reference
The Development Library 6-11
Example:
Solid State Devices (13)
Variable
Description
αF
Forward common-base current gain
αR
Reverse common-base current gain
γ
Body factor
λ
Modulation parameter
µn
Electron mobility
φp
Length adjustment (PN Step Junctions), or
Channel encroachment (NMOS Transistors)
∆W
Width adjustment (PN Step Junctions), or
Width contraction (NMOS Transistors)
a
Channel thickness
Aj
Effective junction area
BV
Breakdown voltage
Cj
Junction capacitance per unit area
E1
Emax
Silicon dioxide capacitance per unit area
Breakdown-voltage field factor
Maximum electric field
G0
Channel conductance
gds
Output conductance
gm
Transconductance
I
Diode current
IB
Total base current
IC
Total collector current
ICEO
Collector current (collector-to-base open)
ICO
Collector current (emitter-to-base open)
ICS
Collector-to-base saturation current
ID, IDS
Drain current
x«
x»;@".
XLIB~
Description:
XLIB conversion command: Convert reals to an XLIB and vice versa.
Input/Output:
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
n
m
→
#n
n
→
Xlib
n
#n
→
Xlib
#n
#m
→
Level 1/Argument 1
Fermi potential
∆L
Cox
« » →S2 returns "!NO CODE!RPL::
Xlib
Xlib
Level 2/Item 1
→
Example 1:
Example 2:
Example 3:
Xlib
n
#314h #40h XLIB~ returns ZEROS.
1648 2 XLIB~ returns XLIB 1648 2.
{ SYLVESTER } OBJ→ DROP XLIB~ returns 788. 78..
Level 1/Item 2
m
CRLIB – Create Library Command
A library is one of the most complex objects in the calculator. One of the basic uses of a library is to group all the
files of an application.
In order to create a library, you must store in a directory all the variables that will be part of this library. Then, you
must store configuration information in some special variables.
The $TITLE variable must contain a character string defining the title of the library. This string must be less than
256 characters long. The first five characters will be used for the name that is shown in the library menu.
The $ROMID variable must contain the library number or your library. This number must be in the range 769 to
1791. In order to avoid conflicts, you should go to www.hpcalc.org to check whether the number is already in use.
This variable may contain either a real or an integer.
The $CONFIG variable contains the library configuration object which is run at warmstart. The basic action that
this program should perform is to attach the library to the home directory. Placing a real or an integer in the
$CONFIG variable will cause the CRLIB command to generate a default CONFIG object. This program must
leave the stack intact and is not allowed to produce errors.
The $VISIBLE variable contains a list of all the variables in the current directory that you want to have visible in the
library menu.
The $HIDDEN variable contains a list of all the variables in the current directory that you want to have invisible in
the library. They are generally subprograms of your application.
IE
Total emitter current
The $EXTPRG variable contains the name of the extension program of the library. This program must be either a
visible or an hidden object of the library. See the Extension program section below for more information.
IES
Emitter-to-base saturation current
Then, once you have specified the required variables, you can type CRLIB to create the library.
IS
Transistor saturation current
CRLIB places the library on level 1 of the stack.
J
Current density
5-50 Equation Reference
The Development Library 6-9
PN Step Junctions (13, 1)
These equations for a silicon PN-junction diode use a “two-sided step-junction” model–the doping density changes
abruptly at the junction. The equation assume the current density is determined by minority carries injected across
the depletion region and the PN junction is rectangular in its layout, The temperature should be between 77 and 500
K. (See “SIDENS” in Chapter 3.)
POKEARM
Description:
Memory write command: Writes bytes to a specified address in the ARM memory address space.
You can not write data in the Flash ROM using this command.
Writing data in memory randomly can cause all memory to be lost.
Input/Output:
Level 2/Argument 1
Level 1/Argument 2
Level 1/Item 1
→
Example:
#n
“string”
#7300000h "00804421" POKEARM writes the given four bytes to ARM memory
address 0x7300000.
→PRG
Description:
Equations:
Input/Output:
k⋅T
NA ⋅ ND
V b i = ---------- ⋅ L N  -------------2---------
q
ni
xd =
2 ⋅ ε si ⋅ ε 0
1
1
------------------------- ⋅ ( V b i – V a ) ⋅  -------- + --------
 N A N D
q
ε si ⋅ ε 0
C j = -----------------xd
2 ⋅ (Vbi – V a)
E m a x = ---------------------------------xd
2
1
1
ε si ⋅ ε 0 ⋅ E1
B V = -------------------------------- ⋅  -------- + --------
2⋅q
NA ND

J = Js ⋅ e

Create program command: This is equivalent to the RPL →LIST command, but it creates a
program object.
This command will also convert a symbolic or a list to a program object.
q-----⋅---V
-----ak⋅T

– 1

→RAM
A j = ( W + 2 ⋅ ∆W ) ⋅ ( L + 2 ⋅ ∆L )
π ⋅ ( W + L + 2 ⋅ ∆W + 2 ⋅ ∆L ) ⋅ x j + 2 ⋅ π ⋅ x j
Example 1:
Example 2:
2
Description:
I = J ⋅ Aj
Leveln+1/Argument1 7Level2/Argumentn
Level1/Argumentn+1
obj1 … objn
n
→
obj1, ...,objn
{obj1, ...,objn}
→
obj1, ...,objn
obj1, ...,objn
→
obj1, ...,objn
Level 1/Item 1
«, 3, 2, +, », 5 →PRG returns « 3 2 + ».
{ 3 2 + } →PRG returns 3 2 +.
Improved NEWOB command: Makes a copy of an object in RAM, wherever the object is.
This command allows you to copy a ROM object into RAM.
Input/Output:
Level 1/Argument 1
Example:
Given: ND=1E22_cm^–3, NA=1E15_1/cm^3, T=26.85_°C, Js=1E–6_µA/cm^2, Va=-20_V,
E1=3.3E5_V/cm, W=10_µ, ∆W=1_µ, L=10_µ, ∆L=1_µ, xj=2_µ.
Solution: Vbi=.9962_V, xd=5.2551_µ, Cj=2005.0141_pF/cm^2, Emax=79908.5240_V/cm, BV=358.0825_V,
J= -1.0E–12_A/cm^2, Aj=3.1993E–6_cm^2, I= -3.1993E–15_mA.
Example:
R~SB
Description:
Level 1/Item 1
→
obj1
obj2
{ SIN } OBJ→ DROP →RAM returns External … External.
Real to system binary conversion command: Converts a system binary to a real and a real to a
system binary.
Input/Output:
Level 1/Argument 1
Example:
SB~B
Description:
5-52 Equation Reference
Level 1/Item 1
n
→
¤n
integer
→
¤n
→
n
¤n
4893 R~SB returns ¤ 131Dh.
Binary integer to system binary conversion command: Converts a system binary to a binary
integer and a binary integer to a system binary.
The Development Library 6-7
Input/Output:
Level 1/Argument 1
Bipolar Transistors (13, 3)
These equations for an NPN silicon bipolar transistor are based on large-signal models developed by J.J. Ebers and
J.L. Moll. The offset-voltage calculation differs depending on whether the transistor is saturated or not. The
equations also include the special conditions when the emitter-base or collector-base junction is open, which are
convenient for measuring transistor parameters.
Example:
“string”
"8BA207CA93B2130" H→ returns π.
Level 1/Item 1
→
obj
→H
Description:
Object to hex command: Returns the hex representation of a object.
Input/Output:
Level 1/Argument 1
Example:
H→
→A
Description:
obj
π →H returns "8BA207CA93B2130".
Level 1/Item 1
→
“string”
String to address command: Returns the address represented by a 5 character hex string.
The hex representation of an address is a 5 character string where the address is written
backwards.
Input/Output:
Level 1/Argument 1
Equations:
q ⋅ VBE
q ⋅ VBE
q ⋅ VBC
q ⋅ V BE
 ------------------
 ------------------
k⋅T
k⋅T
IE = –IES ⋅  e
– 1 + αR ⋅ ICS ⋅  e
– 1




 -------------------
 ------------------
k⋅T
k⋅T
IC = –ICS ⋅  e
– 1 + αF ⋅ IES ⋅  e
– 1




IS = αR ⋅ IES
IS = αR ⋅ ICS
ICO = ICS ⋅ ( 1 – αF ⋅ αR )
IB + IE + IC = 0
Example:
H→
→S
Description:
Example:
Given: IES=1E–5_nA, ICS=2E–5_nA, T=26.85_°C, αF=.98, αR=.49, IC=1_mA, VBC= –10_V.
obj
Hex to string command: Returns the string whose data are represented by a hex string.
A hex string is a string that only contains the characters ‘0’ to ‘9’ and ‘A’ to ‘F’.
Level 1/Argument 1
“string1”
Example:
LC~C
Description:
Level 1/Item 1
→
“string2”
"15" S→H returns "Q".
Long complex to complex conversion command: Converts a long complex to a complex and a
complex to a long complex.
Input/Output:
Level 1/Argument 1
Solution: VBE=0.6553_V, IS=0.0000098_nA, ICO=0.000010396_nA, ICEO=0.0005198_nA,
(x,y)
IE= -1.0204_mA, IB=0.0204_mA, VCEsat=0_V.
JFETs (13, 4)
Example:
These equations for a silicon N-channel junction field-effect transistor (JFET) are based on the single-sided stepjunction approximation, which assumes the gates are heavily doped compared to the channel doping,. The draincurrent calculation differs depending on whether the gate-junction depletion-layer thickness is less than or greater
than the channel thickness. The equations assume the channel is uniformly doped and end effects (such as contact,
drain, and source resistances) are negligible. (See “SIDENS” in Chapter 3.)
LR~R
5-54 Equation Reference
Level 1/Item 1
→
Input/Output:
ICO
ICEO = ---------------1 – αF
IC

1 + ------ ⋅ ( 1 – αR ) 

k⋅T
IB
VCEsat = ----------- ⋅ LN  ------------------------------------------------------------
q
1 – αF
 αR ⋅  1 – IC
------ ⋅  ----------------  


IB  αF  
“string”
"C75A3" H→A returns #3A57Ch.
Level 1/Item 1
→
→
(x.Ey,z.Et)
(3.5,26.2) LC~C returns (3.5E0,2.62E1).
(x.Ey,z.Et)
(x,y)
Description:
Long real to real conversion command: Converts a long real to a real and a real to a long real.
Input/Output:
Level 1/Argument 1
Level 1/Item 1
x
→
x.Ey
integer
→
x.Ey
x.Ey
→
x
The Development Library 6-5
Stress Analysis (14)
Variable
ARM→
Description:
Description
δ
Elongation
∈
Normal strain
γ
Shear strain
Input/Output:
Level 1/Argument 1
φ
Angle of twist
Example:
σ
Normal stress
ASM
σ1
Maximum principal normal stress
Description:
σ2
Minimum principal normal stress
σavg
σx
σx1
Normal stress on place of maximum shear stress
σy1
Normal stress in rotated-y direction
τ
Shear stress
τ max
Maximum shear stress
τ x1y1
Rotated shear stress
τ xy
θ
θp1
θp2
θs
Angle to plane of maximum shear stress
A
Area
E
Modulus of elasticity
G
Shear modulus of elasticity
J
Polar moment of inertia
R0
[email protected]".
Level 1/Item 1
Example:
ASM→
Description:
"string"
"!NO CODE!RPL::
obj
Level 2/Item 1
Level 1/Item 2
obj
"debug string"
→
"string"
→
x«
"string"
x»;@" ASM returns « ».
{error list}
MASD Saturn assembly disassembler command: Disassembles a Code object or a range of
memory addresses containing Saturn machine language to produce the assembly language source
code. Read later in this chapter for more details.
Input/Output:
Level 1/Argument 1
Example:
Level 1/Item 1
→
Code
Code ASM→ might return "D0=AD0+5C=DAT0
AR0=C
"string"
A".
BetaTesting
Description:
Test string command: Returns a string useful for testing purposes.
Input/Output:
Level 1/Argument 1
Level 1/Item 1
→
L
Length
Example:
P
Load
CD→
→
r
Radius
T
Torque
“string”
BetaTesting returns "Sébastien Eric John…".
Description:
Code to hex command: Returns the hex representation of a code (Assembly program) object.
Input/Output:
Level 1/Argument 1
Reference: 2.
Example:
5-56 Equation Reference
obj
R0MOV
→
Level 1/Argument 1
Angle to plane of maximum principal normal stress
Angle to plane of minimum principal normal stress
R0
MASD assemble/compile command: Compiles a string containing System RPL, Saturn assembly,
or ARM assembly code into an object that the calculator can use.
Read later in this chapter for details on the format of the string.
"string"
Shear stress
Rotation angle
R0
Level 1/Argument 1
Normal stress in rotated-x direction
Normal stress in y direction
Level 1/Item 1
→
"string"
Code ARM→ might return "ADD
Input/Output:
Normal stress in x direction
σy
MASD ARM assembly disassembler command: Disassembles a Code object or a range of
memory addresses containing ARM machine language to produce the assembly language source
code.
Read later in this chapter for more details.
→
Code
Code CD→ may return "8F507621301641468…".
Level 1/Item 1
“string”
The Development Library 6-3
6
6.The Development Library
Introduction
Equations:
σ x +σ y σ x – σ y
σ x 1 = --------------------- + --------------------- ⋅ C OS ( 2 ⋅ θ ) + τx y ⋅ S IN( 2 ⋅ θ )
2
2
Built into the calculator is a set of functions not accessible to the user by default. These functions are in a library
that contains low level development tools mainly designed for use in developing System RPL and assembly
programs.
In order to enable this library, you must attach it with the command 256 ATTACH or by setting flag –86. When the
library is attached after the next warmstart (or reset), it appears in the APPS menu. You may reset the calculator by
pressing $and C at the same time.
σ x 1 +σ y 1 = σ x + σ y
σ x –σ y
τx 1 y 1 = –  ----------2----------- ⋅ S IN( 2 ⋅ θ ) + τx y ⋅ σ y
Example:
Given: σx=15000_kPa, σy=4755_kPa, τ xy=7500_kPa, θ=30_°.
Solution: σx1=18933.9405_kPa, σy1=821.0595_kPa, τ x1y1= -686.2151_kPa.
Note: The tools and programs in this library are extremely
powerful, and misusing them will cause memory loss.
Back up your calculator before trying these commands.
Mohr’s Circle (14, 4)
Equations:
2
σx + σy
σx–σy
σ 1 = --------------------- + --------------------- + ρx y
2
2
σ1+σ2 = σx+σy
τx y
S I N ( 2 ⋅ θ p 1 ) = --------------------------------------------------2
x – σ y 2
σ
 ----------2----------- + τx y
θ p 2 = θ p 1 + 90
σ1 – σ2
τm a x = --------------------
θ s = θ p 1 – 45
σx + σy
σ a v g = ---------------------
2
2
Example:
Given: σx=-5600_psi, σy=-18400_psi, τ xy=4800_psi.
Solution: σ1= -4000_psi, σ2= -20000_psi, θp1=18.4349_°, θp2=108.4349_°, τ max=8000_psi,
θs= -26.5651_°, σavg= -12000_psi.
5-58 Equation Reference
Equation Reference 6-1
References
Sound Waves (15, 3)
1. Dranchuk, P.M., R.A. Purvis, and D.B. Robinson. “Computer Calculations of Natural Gas Compressibility
Factors Using the Standing and Katz Correlation,” In Institute of Petroleum Technical Series, no. IP 74-008. 1974.
Equations:
v =
B
---
ρ
I
β = 10 ⋅ LOG ------ 
10
2
2
1
I = -- ⋅ ρ ⋅ v ⋅ ω ⋅ s m
2
ω = 2⋅π⋅f
Example:
Given: sm=10_cm, ω=6000_r/s, B=12500_kPa, ρ=65_kg/m^3.
Solution: v=438.5290_m/s, I=5130789412.97_W/m^2, β=217.018_dB, f=954.9297_Hz.
2. Gere, James M., and Stephen P. Timoshenko. Mechanics of Materials, 2d ed. PWS Engineering, Boston, 1984.
3. Halliday, David, and Robert Resnick. Fundamentals of Physics,
3d ed. John Wiley & Sons, 1988.
4. Meriam, J. L., and L. G. Kraige. Engineering Mechanics, 2d ed. John Wiley & Sons, 1986
5. Muller, Richard S., and Theodore I. Kamins. Device Electronics for Integrated Cicuits, 2d ed. John Wiley & Sons 1986.
6. Serghides, T. K. “Estimate Friction Factor Accurately,” In Chemical Engineering, Mar. 5, 1984.
7. Siegel, Robert, and John Howell. Thermal Radiation Heat Transfer, Vol. 1. National Aeronautics and Space
Administration, 1968.
8. Sze, S. Physics of Semiconductors, 2d ed. John Wiley & Sons, 1981.
9. Welty, Wicks, and Wilson. Fundamentals of Momentum, Heat and Mass Transfer. John Wiley & Sons, 1969.
5-60 Equation Reference
Equation Reference 5-61
•
•
•
•
•
•
•
•
Entries from the EXTABLE may be used. As the EXTABLE does not have the label names limitations
with operators, in ambiguous case (DUP+#5 may either be an addition DUP + 5, or an entry
‘DUP+#5’), add "" around the word: "DUP"+#5.
Calculations are done with 64 bits.
X divide by 0 = $FFFFFFFFFFFFFFFF.
In order to avoid wasting memory, MASD tries to compile expressions as soon as it sees them. If MASD
is not able to compile an expression directly, it’s compiled at the end of the compilation. In order to use
less memory, it’s a good idea to define your constants at the beginning of the sources so MASD can
compile expression using the constants directly.
The only operator symbols not allowed in labels are +, -, * and /; therefore, if you want to use a symbol
operator after a label, you must put the symbol between " in order to ‘limit’ the symbol. Meaningless
Example: "DUP"<<5.
A label/constant with strange char may be ‘protected’ between " chars.
The evaluation stack of MASD allows you to have around 10 pending computations (parenthesis,
operator priority).
MASD only works with integers. You can represent signed values using standard 2’s complement, but be
careful as all operators are unsigned.
MASD recognizes the following operators:
Operator
<<
>>
%
*
/
+
<
>
<=, ‰
>=, Š
=
#, ‹
&
!
^
Priority
7
7
6
5
5
4
4
3
3
3
3
3
3
2
1
1
Notes
Left Shift 1<<5 = $20
Right shift $20>>5 = 1
Modulo (remainder of division) X%0=0
Multiplication
Division X/0=$FFFFFFFFFFFFFFFF
Addition
Subtraction
Is smaller (true=1, false = 0)
Is greater (true=1, false = 0)
Is smaller or equal (true=1, false = 0)
Is greater or equal (true=1, false = 0)
Is equal (true = 1, false = 0)
Is different (true = 1, false = 0)
Logical and
Logical or
Logical xor
Note: Throughout this documentation, you will see discussions about expressions that can be “immediately”
evaluated. This refers to any expression that contains only number and labels/constants that have already been
declared.
Macros and includes
If data are to be included in a project, it can be entered in hex in a source file, using $. However, a simpler way is to
include data from an external file, called a macro. The macro file must be a character string, a graphic, a code object
or a list.
- In case of a string or a code, MASD includes only the data part (after the length) of the object
- In case of a graphic, only the graphic data will be included (no length, no dimensions)
6-16 The Development Library
Messages Listed Alphabetically (continued)
Message
Meaning
# (hex)
Implicit ( ) off
Implicit parentheses off.
207
Implicit ( ) on
Implicit parentheses on.
208
or ` pressed before all function
arguments supplied.
Attempted unit conversion with
incompatible units.
B02
Infinite Result
Math exception: Calculation such as 1/0
infinite result.
305
Inserting Column
Matrix Writer application is inserting a
column.
506
Inserting Row
Matrix Writer application is inserting a row.
505
Insufficient Memory
Not enough free memory to execute
operation.
001
Insufficient Σ Data
A Statistics command was executed when
ΣDAT did not contain enough data points
for calculation.
603
Interrupted
The HP Solve application or ROOT was
interrupted by −
A03
Invalid Array Element
`returned object of wrong type for
current matrix.
502
Invalid Card Data
Machine does not recognize data on plug-in
card.
008
Invalid Date
Date argument not real number in correct
format, or was out of range.
D01
Invalid Definition
Incorrect structure of equation argument
for DEFINE.
12C
Invalid Dimension
Array argument had wrong dimensions.
501
Invalid EQ
Attempted operation from FCN menu
when EQ did not contain algebraic, or,
attempted DRAW with CONIC plot type
when EQ did not contain algebraic.
607
Invalid IOPAR
IOPAR not a list, or one or more objects in
list missing or invalid.
C12
Invalid Mpar
Mpar variable not created by MINIT.
E401
Incomplete Subexpression
Inconsistent Units
™, ˜
206
Error and Status Messages A-3
!EVEN
!ADR
!COMPEXP
!STAT
!DBGINF
!JAZZ
!MASD
In absolute mode, cause an error if the directive is not on an even
address.
MASD will generate a source defining all constants and labels
used in the program instead of the program.
Cause MASD to calculate all previous expressions.
Display/update compilation statistics
Causes MASD to generate debugging information (see next
section for more information)
See local variable documentation in RPL mode
See local variable documentation in RPL mode
A
A. Error and Status Messages
The following table lists the most frequently encountered error and status messages on the calculator. They are
arranged alphabetically by name. The second table lists all the built-in messages numerically by message number.
Trailing spaces are indicated with a character.
Messages Listed Alphabetically
Message
The !DBGINF directive
If you put the !DBGINF directive into a MASD source, the assembler not only generates your compiled object, but
it also returns a string (on level 1) full of debug information. The structure of this string is as
follows:
Meaning
Acknowledged
Alarm acknowledged.
All Variables known
No unknowns to solve for.
Autoscaling
Calculator is autoscaling x- and/or y- axis.
5 Number of links (source files)
n*[
2 Number of characters
.. Name of link file
]
Awaiting Server Cmd.
Indicates Server mode active.
Bad Argument Type
One or more stack arguments were incorrect
type for operation.
5 Number of symbols (labels and constants)
n*[
2 Number of characters
.. Name of symbol
1 Type: 9=Label 2=Constant
for labels: 5 Address of label
for constants: 16 Value of constant
]
Bad Argument Value
Argument value out of operation’s range.
Bad Guess(es)
Guess(es) supplied to HP Solve application or
ROOT lie outside domain of equation.
5 DOCSTR
5 Length
5 Number of source→code associations
n*[
5 Offset in code (this list is sorted by offset)
2 Number of link this instruction comes from
5 Character offset in link where this instruction starts
]
Notes:
• If the source string is unnamed, i.e. in TEMPOB, the number of links is 00001 and the number of
characters is 00, immediately followed by the symbol table.
• The label symbol table is supposed to be an offset table. However the current MASD may sometimes place
addresses into this table. The “associations” table correctly contains offsets.
This instruction is intended for the case where someone decides to create a source level debugger.
6-18 The Development Library
# (hex)
619
E405
610
C0C
202
203
A01
Bad Molecular Formula
Formula is invalid or incomplete. Look for
mismatched parentheses or invalid element
names.
Bad Packet Block check
Computed packet checksum doesn’t match
checksum in packet.
C01
Can't Edit Null Char.
Attempted to edit a string containing character
ā (character code 0).
102
Circular Reference
Attempted to store a variable name into itself.
Connecting
Indicates verifying IR or serial connection.
Constant?
HP Solve application or ROOT returned same
value at every sample point of current
equation.
E501
129
C0A
A02
Error and Status Messages A-1
Other notes
You should read documentation on the internal structure of RPL objects (www.hpcalc.org has good
documentation)
Disassemblers
D0, D1, Ba and Da are used by the system (next RPL instruction pointer, RPL stack pointer (@@object on level 1
of the stack), start of free memory and free memory in 5 nibble blocks). The SAVE instruction will save these
registers in dedicated memory areas, the LOADRPL instruction will restore them and continue the execution in the
system.
ASM→
→
The ASM→ disassembler converts Saturn assembly into a source string.
Please consult documentation on memory mapping for more information.
The syntax used is MASD syntax, in mode 0-15. Each line contains an address and an instruction. If the system flag
–71 is set (with -71 SF), addresses are not shown, except for the destinations of jumps. In this case, the resulting
source may be then reassembled if needed.
New instructions
ASM→ can either disassemble a CODE object or the memory area between 2 given addresses (as binary integers).
In addition to the F fields, the following new instructions have been created:
Example:
r=s.f, r=r+s.f, r=r-s.f, r=r*s.f, r=r/s.f, r=r%s.f (modulo) r=-s-1.f (logical not), r=-s.f (mathematical not),
r=r<s.f (left shift), r=r>s.f (right shift), r=r^s.f (logical xor).
r=1.f (alias for r=r/r.f) has also been created.
AE734
AE73B
AE742
AE744
AE747
Notes:
-71 CF2 (default)
GOSBVL 0679B
LC 01000
C-A A
GONC AE742
GOVLNG 138B9
1. Any combination of the A, B, C and D registers can be used (notated r and s here)
-71 SF2
GOSBVL 0679B
LC 01000
*AE742
C-A A
GONC AE742
GOVLNG 138B9
2. All fields (including F1-F7 fields) are valid
3. MASD will always choose the shortest version of the instruction (e.g.: A=A+B.A will use the standard C0
encoding AND affect the carry)
4. The carry is not affected by these instructions.
Level 2
Binary integer (start address of the
memory area to disassemble)
The following additional new instructions have been added (see description in the ASM syntax section):
NATIVE? $hex
HST=1.x
?HST=1.x { }
SETFLD(1-7)
OFF
RPL2
KEYDN
CRTMP
BEEP2
GOSLOW
WSCREEN
SETTIME
SETLNED
SETOFFD
HSCREEN
UNCNFGD
GETTIME
REMON
SERIAL
OUTBYT
MOVEUP
MOVEDN
ARMSYS
ARMSAT
REMOFF
CONFIGD
BIGAPP?
RESETOS
REFRESHD
AUTOTEST
ACCESSSD
PORTTAG?
MIDAPP?
Skips
Skips are a first step from ML to a third generation language, even if they are only another way to write ASM
instructions.
Skips are wonderful as they allow you to:
- structure your program
- avoid using gotos
- make programs and piece of code that can be easily copied and pasted (because there is no label)
→
→
→
Level 1
String (disassemble between
the 2 address)
String
ARM→
→
The ARM→ disassembler converts ARM assembly into a source string.
Each line contains an address and an instruction. If the system flag –71 is set (with -71 SF), addresses are not
shown, except for the destinations of jumps. In this case, the resulting source may be then reassembled if needed.
ARM→ can either disassemble a CODE object (which does not make much sense at this point in time) or the
memory area between 2 given Saturn addresses (as binary integer).
Example:
874FF
87507
8750F
87517
8751F
87527
8752F
87537
-71 CF2 (default)
LDMGEIA R0 ! { R5 R6 R7 LP PC }
STMDB R5 { R5 R12 PC }
BL
87527
BLGE 87527
BGE
87527
ADD
R0 R0 R0
MOV
R0 R1
TST
R4 R5
Level 2
Binary integer (start address of the
memory area to disassemble)
6-20 The Development Library
Level 1
Binary integer end
address
Code object
Level 1
Binary integer end
address
Code object
-71 SF2
LDMGEIA R0 ! { R5 R6 R7 LP PC }
STMDB R5 { R5 R12 PC }
BL
876E3
BLGE 876E3
BGE
876E3
*876E3
ADD
R0 R0 R0
MOV
R0 R1
TST
R4 R5
@
→
→
→
Level 1
String (disassemble between
the 2 address)
String
The Development Library 6-41
Example of an ARM assembly language program using the MASD compiler
These instructions
Are equivalent to
{
*.Beg3
*.Beg2
*.Beg1
GOTO.Beg2
GOTO.Beg3
GOTO.End1
GOTO.End3
*.End1
*.End2
*.End3
{
{
UP2
UP3
EXIT1
EXIT3
}
}
}
Notes:
1. EXIT1 is equivalent to EXIT, and UP1 is equivalent to UP.
2. The same rules apply in ARM mode: EXITGE3 for example is a BGE for the exit label 3 blocks down
Using SKELSE, SKEC, SKENC, SKLSE instructions, two blocks create an IFNOT-THEN-ELSE structure.
These
instructions
Are equivalent to
Or in high-level
language
?A=0.A
SKIPYES
{
EXIT
UP
}
SKELSE
{
A+1.A
EXIT
UP
}
?A=0.A GOYES.Beg2
*.Beg1
GOTO.End2 % and not
End1
GOTO.Beg1
*.End1
GOTO.End2
*.Beg2
A+1.A
GOTO.End2
GOTO.Beg2
*.End2
IF NOT A=0 THEN
BEGIN
...
...
END
ELSE
BEGIN
...
...
...
END
Notes:
"!NO CODE !RPL
::
TURNMENUOFF
( turn into RPL mode)
( open a RPL program )
( remove the menu line )
CODE
% open an assembly program
%
%
%
%
%
%
%
%
%
%
this program takes control of the screen and
displays a Mandelbrot set using the standard algorithm
ie: for each point from x=-1.5 to 0.5,
for each point from y=-1 to 1
if any an, n<256 in the series
a0=x+iy (complex number), an+1=a0+an²
has an absolute value > 2, the point is not part of the set
the numbers are stored on 32 bits.
the numbers are shifted by 12 bits, the lower 12 bits representing
the decimal part of the number (in 1/4096)
SAVE
INTOFF
SKUB {
*start
% save the RPL pointers
% disable keyboard interrupts
% jump over the ARM code
!ARM
STMDB sp! {R4 R5 R6 R7 R8 LP}
% switch to ARM mode
% save registers in the stack
LDR R2, [R1, #2324]
%
%
%
%
LDR R3, [R1, #2340]
MOV R7 R2
MOV R8 R3
MOV R6 256
load R2=x (content of saturn
reg B, nibbles 0-7)
load R3=y (content of saturn
reg B, nibbles 0-7)
% copy X in r7
% copy Y in r8
% copy 256 in R6
{
MUL
MOV
MUL
MOV
1. SKELSE places a GOTO between the 2 blocks, SKEC places a GOC, SKENC a GONC and SKLSE places
nothing.
2. UPs are compiled directly when encountered while EXITs and block openings are compiled later on. You
can not have more than 64 pending EXITs and block openings simultaneously.
R4, R2, R2
R4 R4 >> 12
R5, R3, R3
R5 R5 >> 12
ADD LP R4 R5
CMP LP $4000
EXITGT
Tests
A test instruction (?A=0.A) may be followed by:
• A GOYES Label, → Label or -> Label instruction
• A -> { or → { instruction. In this case, the test is inverted and a skip block is open.
• A RTY or RTNYES instruction.
• A SKIPYES { or { instruction. In this case, a skip block is open.
• A GOTO, GOTOL, GOVLNG, GOSUB, GOSUBL or GOSBVL. In this case, the test is inverted and a proper
jump instruction is generated (ie: ?A=B.A GOTO A is compiled as ?A#B.A { GOTO A }.
• A EXIT or UP.
% r4= x² << 12
% r4= x²
% r5= y²
% LP = x² + y²
% if abs² an > 4
% exit
SUB R4 R4 R5
% r4= x²-y²
MUL R3 R2 R3
% R3= X*Y
ADD R2 R7 R4
% r2= X + x²-y² = new x
MOV R3 R3 >> 11
ADD R3 R8 R3
% r3= x*y*2
% r3= Y+2*x*y = new Y
SUBS R6 R6 1
UPNE
% decrement loop counter
% up if not 0
% we have looped 256 times and abs(An)<2, the point is in the set!
LDRB R6 [R1 2408]
% clear the flag ST0
BIC R6 R6 1
STRB R6 [R1 2408]
LDMIA sp! {R4 R5 R6 R7 R8 PC} % restore all registers and return
}
% we have reached a An where abs(An)>2,the point is out of the set
6-22 The Development Library
The Development Library 6-39
Syntax
Reg=Reg+Cst.f
Reg+Cst.f
Reg=Reg-Cst.f
Reg-Cst.f
Example
A=A+10.A
A+10.A
A=A-10.A
A-FOO.A
RegSR.f
ASR.W
RegSL.f
ASL.W
Reg1=Reg1<Reg2.f
Reg1<Reg2.f
Reg1=Reg1>Reg2.f
Reg1>Reg2.f
RegSRB.f
RegSRC
RegSLC
Reg1=Reg1&Reg2.f
Reg1&Reg2.f
Reg1=Reg1!Reg2.f
Reg1!Reg2.f
A=A<B.W
A=A>B.W
BSRB.X
ASRC
BSLC
A=A&B.X
A&C.B
A=A!B.X
A!C.B
Notes
Note 1: The Saturn processor is not able to add a constant greater than 16
to a register. If cst is greater than 16, MASD will generate as many
instructions as needed.
Note 2: Even if adding constants to a register is very useful, large values
should be avoided because this generates a large program. Prefer another
solution like LC(5) Cte A+C.A
Note 3: Adding a constant greater than 1 to a P, WP, XS or S field is a
bugged Saturn instruction (problem with carry propagation). Use these
instructions with care.
Note 4: After adding a constant greater than 16 to a register, the carry
should not be tested (because you do not know if the last generated
instruction generated the carry or not)
Note 5: You can put an expression instead of the constant (MASD must be
able to evaluate the expression right away). If the expression is negative,
MASD will invert the addition in a subtraction and vice versa.
Note 6: Be careful when using subtraction; it’s easy to be misled. A-5-6.A is
equivalent to A+1.A, not A-11.A because the instruction is: A-(5-6).A
Note 7: If using Fn fields, be careful if non nibble bounded masks are
used.
Shift register right by 4 bit on the specified field, set SB if bits are lost.
Note: this instruction is not available on the Fn fields
Shift register left by 4 bit on the specified field, set carry if bits are lost.
Note: this instruction is not available on the Fn fields
Shift register left by n bits (as defined by the value of Reg2) on the specified
field
Shift register right by n bits (as defined by the value of Reg2) on the
specified field
Shift register right by 1 bit on the specified field, set SB if bits are lost.
Circular right shift by 1 nibble
Circular left shift by 1 nibble
Logical and on the specified field
Logical or on the specified field
XxlibName
HXS Size Data
GROB Size Data
LIBDAT Size Data
BAK Size Data
LIB Size Data
EXT3 Size Data
ARRAY Size Data
LNKARRAY Size Data
MINIFON Size Data
ARRY2 Size Data
ARRY [ ... ]
ARRY [ [ . ] [ . ] ]
xRplName
CHR character
LABEL labelname
EXTERNAL name
xlibname
FEXTERNAL name
fptrname
CODE Size Data
CODE
Assembly stuff
ENDCODE
NIBB Size Data or
NIBHEX Data or
NIBBHEX Data or
CON(Size) Expr
INCLOB FileName
INCLUDE FileName
Reg1=Reg1^Reg2.f
Reg1^Reg2.f
Reg1=-Reg1.f
Reg1=-Reg1-1.f
Reg1=~Reg1.f
RReg=Reg.f
A=A^B.X
A^C.B
Logical xor on the specified field
C=-C.A
C=-C-1.A
C=~C.A
Mathematical not on the specified field
Logical not on the specified field
R0=A.W
Reg=RReg.f
A=R0.A
RegRRegEX.f
AR0EX.A
Data=Reg.f
Data=Reg.x
DAT1=C.A
DAT0=A.10
Reg= Data.f
Reg Data.x
C=DAT1.A
A=DAT0.10
Sets the specified field of RReg to the value of the specified field of Reg
Only A and C are valid for Reg.
If f is W, the shorter encoding of the instruction is used
Sets the specified field of Reg to the value of the specified field of RReg
Only A and C are valid for Reg.
If f is W, the shorter encoding of the instruction is used
Exchanged the value of the specified field of RReg with the value of the
specified field of Reg Only A and C are valid for Reg.
If f is W, the shorter encoding of the instruction is used
Write the content of the specified field of the specified register in the
memory location pointed by Data register (POKE)
Reg can only be A or C
Read the content of the memory location pointed by Data register in the
specified field of the REG register (PEEK)
Reg can only be A or C
6-24 The Development Library
LABEL label
EQU CstName ExpHex
EQUCP Interleave
CstName
DEFINE name ...
DIR
VARNAME name1 obj1
VARNAME name2 obj2
...
ENDDIR
XLIB identified by its name. If it is a standard calculator command
(like xDUP), the address is used instead of an XLIB object.
Binary integer ($02A4E), Size is in hexadecimal and Data is a set of
hexadecimal characters. Example: HXS 5 FFA21
GROB ($02B1E).
Library data ($02B88).
Backup ($02B62).
Library ($02B40).
Extended3 ($02BEE).
Array ($029E8).
Linked Array ($02A0A).
Minifont object
Array object
Array object, which can have 1 or 2 dimensions.
All objects in the array must be of same type
If RplName is an RPL instruction, compiles the RPL instruction (or
xlib depending on the instruction)
Character object. See rules on " for more information
Creates a label at this position. Use carefully
Equivalent to DEFINE name ROMPTR2 xlibname
Equivalent to DEFINE name FPTR2 fptrname
Code object ($02DCC).
Include a code object, change to ASM mode and close the code object
on the next ENDCODE.
Includes hexadecimal data directly (no prolog).
Includes the content of the file FileName.
Includes the source of the file FileName to be compiled (Like ' in ASM
mode).
Defines a label (like * in ASM mode).
Defines a constant (Like DC in ASM mode).
Defines a constant (Like DCCP in ASM mode).
Associate the data compiled between the name and the end of the line
with the name. After that, if the name is used again, the associated data
is placed in the compiled file
Creates a directory containing the objects in the given variables.
The Development Library 6-37
Syntax
Example
SB=1
XM=1
SR=1
MP=1
HST=a
?SB=1
?XM=1
?SR=1
?MP=1
?HST=1.a
P=a
P=P+1 P+1
P=P-1 P-1
?P=a ?P#a
P=C.a C=P.a
CPEX.a
C=C+P+1 C+P+1
GOTO label
GOTOL label
GOLONG Lab
GOVLNG hex
GOVLNG =Label
GOVLNG ="COMND"
GOSUB label
GOSUBL label
GOSBVL hex
GOSBVL =Label
GOSBVL ="COMND"
GOC label
GONC label
GOTOC label
GOTONC label
RTN
RTNSXM
RTNCC
RTNSC
RTNC
RTNNC
RTI
RTNYES RTY
C=RSTK
RSTK=C
OUT=CS
OUT=C
A=IN
C=IN
SETDEC SETHEX
UNCNGF CONFIG
RESET
SHUTDN
INTON INTOFF
RSI
GOINC label
GOINA label
$hhh...hhh
NIBHEX hhh...hh
$/hhhh...hhh
6-26 The Development Library
Notes
See above. This is only valid in emulated Saturn
System RPL mode
MASD can also compile System RPL programs (you should read the book “An Introduction to System RPL”
before trying to write System RPL programs).
The !RPL directive will switch MASD in RPL mode.
Note: if the Flag –92 is set, MASD starts in !RPL and !NO CODE mode.
The HP ≠ character can be used instead of #
Instructions
In RPL mode, MASD interprets instructions/tokens in the following order.
Reals and system binary
GOTO is limited to 1KB jumps
GOTOL can jump over 16KB of code
If the instruction is a decimal number, a system binary is created (MASD will try, if possible, to use the internally
defined system binary). If that number has a decimal point (in the middle, or starts with the decimal point), a real
number is created.
Unnamed local variables
This jumps to a specific address
If the instruction is a recall or a set of a local variables defined by {{ the correct instruction is generated.
GOSUB is limited to 1KB jumps
GOSUBL is limited to 16KB jumps
GOSBVL jumps to a specific address
A local environment is created using:
{{ var1 var2 ... varN }}
GO if Carry set (limited to 64 bytes)
GO if no carry (limited to 64 bytes)
Equivalent to SKNC { GOTO label }
Equivalent to SKC { GOTO label }
Return from subroutine (GOSUB call)
RTN + XM=1
RTN + set carry
RTN + clear carry
RTN if carry set
RTN if carry not set
Return from interrupt
Return if test true (see test section)
Pop value from RSTK in Ca
Push value from Ca in RSTK
Set the first 2 nibbles of the OUT register to the value of Cb
Set the OUT register to the value of C4
Copy the IN register in Ax or Cx (buggy instruction, do not use if you do
not know what you are doing)
Set the SPU in DECIMAL or HEXADECIMAL mode
Deconfigure/Configure memory modules
Deconfigure ALL memory modules
STOP the CPU waiting for an interrupt
Enable/disable keyboard interrupts
Reset interrupt system
Equivalent to LC(5)label-&. (& is the address of the instruction)
Equivalent to LA(5)label-& (& is the address of the instruction)
Includes hexadecimal data in the program. Example:
$12ACD545680B.
Includes hexadecimal data in reverse order. Example: $/123ABC is
equivalent to $CBA321.
with N<23
These variables have names during compile time, but they are implemented as unnamed local variables, which are
faster to access than named local variables.
A local variable is recalled by typing its name or with an optional ending @. Data can be stored in a local variable by
typing its name, with a leading or ending ! or a leading =.
Notes:
1.
Local variables are available until the next local definition.
2.
The local environment is not closed automatically; use ABND or other provided words.
Example:
{{ label1 label2 … labelN }} will become:
' NULLLAM <#N> NDUPN DOBIND (or 1LAMBIND if there is only one variable)
And:
label1
[email protected]
=label1
!label1
label1!
→
→
→
→
→
1GETLAM
1GETLAM
1PUTLAM
1PUTLAM
1PUTLAM
Program example:
::
{{ A B }}
B A!
ABND
;
::
' NULLLAM TWO NDUPN DOBIND
2GETLAM 1PUTLAM
ABND
;
Note that it is your responsibility to destroy the local environment using ABND and that MASD does not handle
multiple level of definition of local variables, nor does it destroy the current environment, even if ABND is used.
Variables defined this way will be valid until a new set of variables is defined.
The Development Library 6-35
Syntax
Example
RPL2
KEYDN
CRTMP
BEEP2
REMON
SERIAL
OUTBYT
MOVEUP
MOVEDN
ARMSYS
ARMSAT
REMOFF
GOSLOW
WSCREEN
SETTIME
SETLNED
6-28 The Development Library
Notes
Simulates a LOOP (A=DAT0.A D0+5 PC=(A)).
(C[A]) kbd peeks with immediate rtn CS if keydn.
Also - Sets DOUSEALARM flag if [ON][9] sequence.
Entry: P=0, HEX Mode, C[A]: #kbd peeks (loop count)
Abstract: Creates a hole in the tempob area of the specified size
+ 6 (5 for the link field and 1 for marker nibble).
Sets the link field of the “hole” to size+6 and adjusts
AVMEM, RSKTOP and TEMPTOP.
Entry Conditions: RPL variables in system RAM
C(A) contains desired size of hole
Exit Conditions: carry clear, RPL variables in system RAM
D1 → link field of hole, D0 → object position
B(A), C(A)= desired size+6
Error Exits: Returns with carry set when there’s not enough memory
to create a hole of size+6.
Entry: C[A]: d
;d=Beep duration (msec)
D[A]: f
;f=Beep frequency (hz)
P=0
Exit: CARRY:0
Enables the remote control mode (ON+R).
Copy serial number to address pointed to by D1 in Saturn memory.
Purpose: Send byte to IR printer
Entry: A[B]: Byte
Exit: CC, P=0, Byte Sent
Alters: P:0, CARRY:0, SETHEX.
Abstract: Used to move block of memory to higher address.
No check is made to ensure that the source and destination do not overlap.
Code is moved from high to low addresses.
Entry Conditions: D0 → end of source + 1
D1 → end of destination + 1
C(A) = number of nibs to move (unsigned)
Exit Conditions: HEX mode, P=0, carry clear
D0 → start of source
D1 → start of destination
Abstract: Used to move block of memory to lower address.
No check is made to ensure that the source and destination do not overlap.
Code is moved from lower to higher addresses.
Entry Conditions: D0 → start of source; D1 → start of destination; C(A)
= number of nibs to move (unsigned)
Exit Conditions: P=0, carry clear; D0 → end of source + 1; D1 → end of
destination + 1
Call a function at global dword address C[0-7]&~3.
The function takes should be of the form: U32 f(U32 pc, Chipset* c) { /*
put your code here */ return pc; }
Call a function at Saturn address C.A&~7.
The function should have the following format:
U32 f(U32 pc, Chipset* c) { /* put your code here */ return pc; }
In RAM asm, this means that as you enter the function, pc is in R0,
@Chipset is in R1 and the return address is in LP. R2 and R3 are free to
use, and R0 should normally not be modified except if you want to change
the PC when exiting the function.
Stops the remote control (ON+S).
Wait for (C[A]/183) ms.
Return how many columns the screen contains in Ca
Sets the RTC time from C[W] in ticks.
Set number of lines of disp0 from C[B], refresh display.
In all cases, Cte must be a decimal value or an expression that can be evaluated immediately.
A_mode can be:
Form
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
[Rn
+/-Cte]
+/-Rm]
+/-Rm LSL Cte]
+/-Rm < Cte]
+/-Rm LSR Cte]
+/-Rm > Cte]
+/-Rm ASR Cte]
+/-Rm >> Cte]
+/-Rm ROR Cte]
+/-Rm >>> Cte]
+/-Cte]!
[Rn +/-Rm]!
[Rn +/-Rm LSL Cte]!
[Rn +/-Rm < Cte]!
[Rn +/-Rm LSR Cte]!
[Rn +/-Rm > Cte]!
[Rn +/-Rm ASR Cte]!
[Rn +/-Rm >> Cte]!
[Rn +/-Rm ROR Cte]!
[Rn +/-Rm >>> Cte]!
[Rn] +/-Cte
[Rn] +/-Rm
[Rn]
[Rn]
[Rn]
[Rn]
[Rn]
[Rn]
[Rn]
[Rn]
+/-Rm
+/-Rm
+/-Rm
+/-Rm
+/-Rm
+/-Rm
+/-Rm
+/-Rm
LSL Cte
< Cte
LSR Cte
> Cte
ASR Cte
>> Cte
ROR Cte
>>> Cte
Description
Value of rn + or - constant
Value of rn + or – value of rm
Value of rn + or – value of rm shifted left
Value of rn + or – value of rm shifted right
Value of rn + or – value of rm shifted arithmetically right
Value of rn + or – value of rm rotated right
Value of rn + or – constant
Rn is updated with that value
Value of rn + or – value of rm
Rn is updated with that value
Value of rn + or – value of rm shifted left
Rn is updated with that value
Value of rn + or – value of rm shifted right
Rn is updated with that value
Value of rn + or – value of rm shifted arithmetically right
Rn is updated with that value
Value of rn + or – value of rm rotated right
Rn is updated with that value
The value used is the value of rn, but rn is then updated with Value of rn + or –
constant
The value used is the value of rn, but rn is then updated with Value of rn + or –
value of rm
The value used is the value of rn, but rn is then updated with Value of rn + or –
value of rm shifted left
The value used is the value of rn, but rn is then updated with Value of rn + or –
value of rm shifted right
The value used is the value of rn, but rn is then updated with Value of rn + or –
value of rm shifted arithmetically right
Value of rn + or – value of rm rotated right
Rn is updated with that value
ARMSAT instruction
When using the ARMSAT instruction, the Saturn pc is in register r0 and the address chipset structure that contains
the state of the Saturn CPU is in r1.
That structure has the following elements at the following offsets:
Offset
Element
0
P_U32 read_map[256+1]; read_map[x] points on the 2Kb of Saturn address space at
Saturn address x<<12
1028
P_U32 write_map[256+1]; read_map[x] points on the 2Kb of Saturn address space
at Saturn address x<<12 for write purpose (write_map[x]=0 if x points on some non
readable memory)
2056
enum ModulePriority top_map[256+1]; // Type of block on top, to know if new
configured block takes over
2316
REG A;
2324
REG B;
The Development Library 6-33
Instruction set
ARM mode
Note: For instruction names, the case does not matter.
ARM architecture
Register names are:
For all user intents and purposes the ARM CPU has sixteen 32 bit registers noted R0 to R15 (R15 is also the
program counter, R14 is the link register (ie: a BL (GOSUB) instruction copies the return address in R14 before
jumping, a Return From Subroutine is performed by doing MOV PC, LR), and R13 is the Stack pointer).
Setting the S flag on an instruction causes the instruction to modify the flags.
Each instruction can be conditionally executed depending on the value of 5 flags.
Every instruction is evaluated ONLY if the attached condition is true. By default, the instruction is always evaluated.
Each instruction can be told to modify or not modify these 5 flags (add the S suffix to the instruction).
Separation between arguments can be either ‘,’ or spaces.
Please read the ARM ARM (ARM Architecture and Reference Manual) for more information.
In the following examples, cond can be any of:
GT
LE
>
<=
}
LT
<=
}
}
GE
>=
UP<Cond>2
UP<Cond>3
EXIT<Cond>1
EXIT<Cond>3
LS
Unsigned
<=
{
*.Beg3
*.Beg2
*.Beg1
B<Cond>
B<Cond>
B<Cond>
B<Cond>
*.End1
*.End2
*.End3
HI
Unsigned >
{
VC
No
overflow
{
VS
Overflow
EXIT and UP can jump to the beginning or to the end of an upper-level block by specifying the number of blocks
to exit, after the UP or EXIT instructions.
These instructions
Are equivalent to
PL
Positive or 0
}
*.Beginning
B<Cond> .End
B<Cond>.Beginning
*.End
MI
Negative
EXIT<Cond>
UP<Cond>
CC
LO
Carry clear
<
{
CS
HS
Carry set,
unsigned
>=
Once blocks are defined, special instructions can be used in them. The instructions called EXIT and UP allow
jumping to the end or to the beginning of a block.
These instructions
are equivalent to
NE
Not equal
Skips
Skips are a first step from ML to a third generation language, even if they are only another way to write ASM
instructions.
Skips are wonderful as they allow you to:
- structure your program
- avoid using gotos
- make programs and piece of code that can be easily copied and past (because there is no label)
The foundation of Skips is the Block structure.
A block is enclosed in { and }, and can be nested within another block.
The following instructions deal with blocks.
SKIPS instructions
Equivalents
{ ... }
Defines a block (generates no code)
SK<Cond> { ... }
B<cond> .S... *.S
SKUB<Cond> { ... }
BL<cond> .S ... *.S
EQ
Equal
Please look at the ARMSAT Saturn instruction and the ARM mode documentation to see the instruction set and the
rules of calling ARM code from Saturn code.
R0, R1, R2, R3, R4, R5, R6, R7, R8, R9, R10, R11, R12, R13 (or SP), R14 (or LP or LR) and R15 (or PC).
And Oprnd can be of the form:
Description
Immediate value
Logical shift left
Logical shift right
Arithmetic shift right
Rotate right
Register
Logical shift left
Logical shift right
Arithmetic shift right
Rotate right
Form
Cte
Note: cte is encoded on 8 bits + a rotation right encoded
on 4 bits. This means that not every value is possible.
Rm LSL Cte
Rm < Cte
Rm LSR Cte
Rm > Cte
Rm ASR Cte
Rm >> Cte
Rm ROR Cte
Rm >>> Cte
Rm
Rm LSL Rs
Rm < Rs
Rm LSR Rs
Rm > Rs
Rm ASR Rs
Rm >> Rs
Rm ROR Rs
Rm >>> Rs
.Beg2
.Beg3
.End1
.End3
Note: EXIT1 is equivalent to EXIT, and UP1 is equivalent to UP.
6-30 The Development Library
The Development Library 6-31
Messages Listed Alphabetically (continued)
Message
Meaning
Non-Empty Directory
Attempted to purge non-empty directory.
Messages Listed Numerically (continued)
# (hex)
12B
Execution of HP Solve application, ROOT,
DRAW, or ∫ returned result other than real
number or unit.
Execution of HP Solve application, ROOT,
DRAW, or ∫ returned result other than real
number or unit.
Alarm list did not contain alarm specified
by alarm command.
D04
Nonexistent ΣDAT
Statistics command executed when ΣDAT
did not exist.
602
Object In Use
Attempted PURGE or STO into a backup
object when its stored object was in use.
009
Object Not in Port
Attempted to access a nonexistent backup
object or library.
00C
( OFF SCREEN )
Function value, root, extremum, or
intersection was not visible in current
display.
61F
Out of Memory
One or more objects must be purged to
continue calculator operation.
135
Non-Real Result
Non-Real Result
Nonexistent Alarm
12F
C10
Plot Type:
Label introducing current plot type.
61D
Port Closed
Possible I/R or serial hardware failure. Run
self-test.
C09
Port Not Available
Used a port command on an empty port, or
one containing ROM instead of RAM.
Attempted to execute a server command
that itself uses the I/O port.
00A
Positive Underflow
Math exception: Calculation returned
positive, non-zero result less than MINR.
301
Power Lost
Calculator turned on following a power
loss. Memory may have been corrupted.
006
Processing Command
Indicates processing of host command
packet.
C11
Packet #
Parity Error
A-6 Error and Status Messages
Message
BA4D
BA4E
BA4F
BA50
BA51
2400
BB01
BB02
BB03
BB04
BB05
BB06
BB07
BB08
BB09
BB0A
BB0B
BB0C
BB0D
BB0E
BB0F
BB10
BB11
BB12
BB13
BB14
BB15
BB16
BB17
BB18
BB19
BB1A
BB1B
BB1C
BB1D
BB1E
BB1F
BB20
BB21
1.Single-var…
4800
9600
USB
Serial
12F
Math exception: Calculation returned result
greater in absolute value than MAXR.
Indicates packet number during send or
receive.
Received bytes’ parity bit doesn’t match
current parity setting.
Overflow
# (hex)
303
C05
Statistics Prompts
2.Frequencies…
3.Fit data…
4.Summary stats…
SINGLE-VARIABLE STATISTICS
ΣDAT:
Type:
Mean
Std Dev
Variance
Total
Maximum
Minimum
Enter statistical data
Enter variable column
Choose statistics type
Calculate mean?
Calculate standard deviation?
Calculate variance?
Calculate column total?
Calculate column maximum?
Calculate column minimum?
Sample
Population
FREQUENCIES
X-Min:
Bin Count:
Bin Width:
Enter minimum first bin X value
Enter number of bins
Enter bin width
FIT DATA
X-Col:
Error and Status Messages A-35
Messages Listed Alphabetically (continued)
Message
Meaning
Undefined Constant
Undefined Element
The name supplied to CONST isn’t in the
Constants Library.
The element supplied to PTPROP doesn’t
exist.
# (hex)
E129
BA03
BA04
BA05
BA06
BA07
BA08
BA09
BA0A
BA0B
BA0C
BA0D
BA0E
BA0F
BA10
BA11
BA12
BA13
BA14
BA15
BA16
BA17
BA18
BA19
BA1A
BA1B
BA1C
BA1D
BA1E
BA1F
BA20
BA21
BA22
BA23
BA24
BA25
BA26
BA27
E502
Undefined FPTR Name
Executed a Flash Pointer that did not exist.
011
Undefined Local Name
Executed or recalled local name for which
corresponding local variable did not exist.
003
Undefined Name
Executed or recalled global name for which
corresponding variable did not exist.
204
Undefined Property
The property number supplied to PTPROP
isn’t in the Periodic Table
E503
Undefined Result
Calculation such as 0/0 generated
mathematically undefined result.
Undefined TVM Variable
The variable name supplised to
TVMROOT isn’t N, I%YR, PV, PMT, or
FV.
E607
Undefined XLIB Name
Executed an XLIB name when specified
library absent.
004
Warning:
Label introducing current status message.
007
Wrong Argument Count
User-defined function evaluated with an
incorrect number of parenthetical
arguments.
128
x and y-axis zoom.
Identifies zoom option.
627
x axis zoom.
Identifies zoom option.
625
x axis zoom
w/AUTO.
Identifies zoom option.
624
y axis zoom.
Identifies zoom option.
626
ZERO
Result returned by the HP Solve application
or ROOT is a root (a point at which current
equation evaluates to
304
A04
zero).
""
A-8 Error and Status Messages
Identifies no execution action when
%EXECS% pressed.
Messages Listed Numerically (continued)
# (hex)
61E
Message
3.Print display
4.Print…
5.Transfer…
6.Start Server
Enter names of vars to send
Vars in
SEND TO CALCULATOR
Port:
Dbl-Space
Delay:
Xlat:
Linef
Baud:
Parity:
Len:
Choose print port
Enter object(s) to print
Print extra space between lines?
Enter delay between lines
Choose character translations
Print linefeed between lines?
Choose baud rate
Choose parity
Enter printer line length
PRINT
Type:
OvrW
Fmt:
Chk:
Choose transfer port
Choose type of transfer
Enter names of vars to transfer
Choose transfer format
Choose checksum type
Overwrite existing variables?
TRANSFER
Local vars
Error and Status Messages A-33
Messages Listed Numerically (continued)
# (hex)
026
027
028
029
02A
02B
02C
02D
02E
101
102
103
104
106
107
108
109
10A
10B
10C
10D
10E
10F
110
111
112
113
114
115
116
117
118
119
11A
11B
11C
Message
Invalid File Mode
Disk Full
Disk Format Error
Disk Change
No SD card inserted
Not enough ARM memory
DOS call unsupported
DOS unknown error
Disk Protected
No Room to Save Stack
Can't Edit Null Char.
Invalid User Function
No Current Equation
Invalid Syntax
Real Number
Complex Number
String
Real Array
Complex Array
List
Global Name
Local Name
Program
Algebraic
Binary Integer
Graphic
Tagged
Unit
XLIB Name
Directory
Library
Backup
Function
Command
System Binary
Long Real
A-10 Error and Status Messages
Messages Listed Numerically (continued)
# (hex)
B99B
B99C
B99D
B99E
B99F
B9A0
B9A1
B9A2
B9A3
B9A4
B9A5
B9A6
B9A7
B9A8
B9A9
B9AA
B9AB
B9AC
B9AD
B9AE
B9AF
B9B0
B9B1
B9B2
B9B3
B9B4
B9B5
B9B6
B9B7
B9B8
B9B9
B9BA
B9BB
B9BC
B9BD
B9BE
Message
37 Double-space prnt
38 No linefeeds
39 No I/O messages
40 Show clock
41 24-hour clock
42 dd.mm.yy format
43 Don't reschedule
44 Save alarm
51 Fraction mark: ,
52 Show one line
53 Show all parens
54 Use tiny element
55 No last args
56 Standard beep off
57 Alarm beep off
58 Don't show INFO
59 Show names only
60 [Œ] locks Alpha
61 [USR] locks User
62 User keys on
63 Custom ENTER on
65 Level 1 multiline
66 Stk: 1 line str
67 Analog clock
68 AutoIndent
69 Infinite line edit
70 →GROB x lines str
71 No addresses
72 Stack:mini font
73 Edit:mini font
74 Left stack disp
75 Key click on
76 No purge confirm
79 Textbook off
80 EQW mini stk font
81 GRB Alg mini font
Error and Status Messages A-31
Messages Listed Numerically (continued)
# (hex)
141
142
143
144
145
146
147
148
149
14A
14B
14C
14D
14E
14F
150
151
Message
Symbolic Matrix
Font
Aplet
Extended Real
Extended Complex
FlashPtr
Extended Ptr
MiniFont
Extended 1
Extended 2
Extended 3
YES
NO
TRUE
FALSE
Are you sure?
Low Memory Condition
Please Wait...
Object Editing Messages
152
153
154
155
156
157
158
CATALOG
159
Result not editable in EQW
Nonexistent Find Pattern
Not Found
Nonexistent Replace Pattern
Can't Find Selection
Y= not available
Warning:
Changes will not be saved
Stack Errors and Messages
201
202
203
204
205
Too Few Arguments
206
Incomplete
Subexpression
207
Implicit () off
208
Implicit () on
Bad Argument Type
Bad Argument Value
Undefined Name
LASTARG Disabled
Equation Writer Application Messages
A-12 Error and Status Messages
Messages Listed Numerically (continued)
# (hex)
B951
B952
B953
B954
B955
B956
B957
B958
B959
B95A
B95B
B95C
B95D
B95E
B95F
B960
B961
B962
B963
B964
B965
B966
B967
B968
B969
B96A
B96B
B96C
B96D
B96E
B96F
B970
B971
B972
B973
B974
B975
Message
53 No extra parens
54 Tiny element → 0
55 Save last args
56 Standard beep on
57 Alarm beep on
58 Show INFO
59 Show variables
60 [Œ][Œ] locks
61 [USR][USR] locks
62 User keys off
63 Custom ENTER off
65 All multiline
66 Stack:x lines str
67 Digital clock
68 No AutoIndent
69 Line edit
70 →GROB 1 line str
71 Show addresses
72 Stack:current fnt
73 Edit:current font
74 Right stack disp
75 Key click off
76 Purge confirm
79 Textbook on
80 EQW cur stk font
81 GRB Alg cur font
82 EQW edit cur font
83 Display grobs on
85 Normal stk disp
90 CHOOSE:cur font
91 MTRW:matrix
92 MASD asm mode
94 Result = LASTCMD
95 RPN mode
97 List:horiz disp
98 Vector:horiz disp
99 CAS:quiet
Error and Status Messages A-29
Messages Listed Numerically (continued)
Messages Listed Numerically (continued)
# (hex)
61A
61B
61C
61D
61E
61F
620
621
622
623
624
625
626
627
628
629
62A
62B
62C
62D
62E
62F
Message
Enter alarm, press SET
Select repeat interval
I/O setup menu
Plot type:
""
(OFF SCREEN)
Invalid PTYPE
Name the stat data,
press ENTER
Enter value (zoom out
if>1), press ENTER
Copied to stack
x axis zoom w/AUTO.
x axis zoom.
y axis zoom.
x and y axis zoom.
IR/wire:
ASCII/binary:
baud:
parity:
checksum type:
translate code:
Enter matrix, then NEW
No Associated Numeric View
Mode and Plot Input Form Prompts
701
702
703
704
705
706
707
708
709
70A
70B
70C
70D
70E
Algebraic
RPN
Standard
Std
Fixed
Fix
Scientific
Sci
Engineering
Eng
Degrees
Radians
Grads
Rectangular
A-14 Error and Status Messages
# (hex)
B905
B906
B907
B908
B909
B90A
B90B
B90C
B90D
B90E
B90F
B910
B911
B912
B913
B914
B915
B916
B917
B918
B919
B91A
B91B
B91C
B91D
B91E
B91F
B920
B921
B922
B923
B924
B925
B926
B927
B928
B929
B92A
B92B
Message
Reset all
Valid object types:
Valid object type:
Any object
Real number
(Complex num)
"String"
[ Real array ]
[(Cmpl array)]
{ List }
Name
« Program »
'Algebraic'
# Binary int
_Unit object
Invalid object type
Invalid object value
Calculator Modes
Number Format:
Angle Measure:
Coord System:
Beep
Clock
FM,
Choose number display format
Enter decimal places to display
Choose angle measure
Choose coordinate system
Enable standard beep?
Display ticking clock?
Use comma as fraction mark?
Standard
Std
Fixed
Fix
Scientific
Sci
Engineering
Eng
Error and Status Messages A-27
Messages Listed Numerically (continued)
# (hex)
735
736
737
738
739
73A
73B
73C
73D
73E
73F
740
741
742
743
744
745
746
747
748
749
74A
74B
74C
74D
74E
74F
750
751
752
753
754
755
756
757
758
759
75A
Message
Edit in full page?
Automatically indent new lines?
Edit in EQW using small font?
Display EQW using small font?
Choose header height
Display ticking clock?
Analog clock?
DISPLAY MODES
Indep var:
Modulo:
Verbose
Step/Step
Complex
Approx
Incr Pow
Simp Non-Rational
Rigorous
Numeric
Enter independent variable name
Enter modulo value
Display calculus information?
Perform operations step by step?
Allow complex numbers?
Messages Listed Numerically (continued)
# (hex)
89A
89B
89C
89D
89E
89F
8A0
8A1
8A2
8A3
8A4
8A5
8A6
8A7
8A8
8A9
8AA
8AB
8AC
8AD
8AE
8AF
8B0
Perform approx calculations?
Increasing polynomial ordering?
Simplify non rational expr?
Don't simplify |X| to X?
Replace constants by values?
CAS MODES
Goto row:
Goto column:
Specify a row to go to
Specify a column to go to
Matrix Writer
Bad range value
Start:
Step:
901-90C
Message
FIND REPLACE
FIND
Goto Line:
Specify a line to go to
GOTO LINE
Goto Position:
Specify a position to go to
GOTO POSITION
H-Factor:
V-Factor:
Recenter on cursor
Enter horizontal zoom factor
Enter vertical zoom factor
Recenter plot on cursor?
ZOOM FACTOR
Object:
Name:
Directory
Enter New Object
Enter variable name
Create a new directory?
NEW VARIABLE
Select Object
Statistics Help Messages
(Help messages for Hypothesis Tests and Confidence
Intervals)
90D
Inconclusive result
A01
A02
A03
A04
A05
A06
A07
A08
A09
Bad Guess(es)
HP Solve Application Messages
Constant?
Interrupted
Zero
Sign Reversal
Extremum
Left
Right
Expr
Type:
A-16 Error and Status Messages
Error and Status Messages A-25
Messages Listed Numerically (continued)
# (hex)
781
782
783
784
785
786
787
788
789
78A
78B
78C
78D
78E
78F
790
791
792
793
794
795
796
797
798
799
79A
79B
79C
79D
79E
79F
7A0
7A1
7A2
7A3
7A4
7A5
7A6
7A7
Message
V-Tick:
Pixels
Depnd:
Save Animation
ΣDAT:
Col:
Cols:
F:
H-Var:
V-Var:
Stiff
ˆFˆY:
ˆFˆT:
Choose type of plot
Choose angle measure
Enter function(s) to plot
Enter independent variable name
Connect plot points?
Plot functions simultaneously?
Enter horizontal tick spacing
Enter vertical tick spacing
Tick spacing units are pixels?
Enter dependent variable name
Save slices animation?
Enter data to plot
Enter col to use for horizontal
Enter col to use for vertical
Enter horizontal variable
Enter vertical variable
Use stiff diff eq solver?
Enter derivative w.r.t. soln
Enter derivative w.r.t. indep
PLOT SETUP
H-View:
V-View:
Indep Low:
High:
Step:
Messages Listed Numerically (continued)
# (hex)
850
851
852
853
854
855
856
857
858
859
85A
85B
85C
85D
85E
85F
860
861
862
863
864
865
866
867
868
869
86A
86B
86C
86D
86E
86F
870
871
872
873
874
875
Message
N:
C:
Sample mean
Population standard deviation
Sample size
Confidence level
CONF. INT.: 1 µ, KNOWN ˜
1:
˜1:
N1:
C:
2:
˜2:
N2:
Sample mean for population 1
Std deviation for sample 1
Size of sample 1
Sample mean for population 2
Std deviation for sample 2
Size of sample 2
Confidence level
CONF. INT.: 2 µ, KNOWN ˜
x:
N:
C:
Sample success count
Sample size
Confidence level
CONF. INT.: 1 P
1:
N1:
C:
2:
N2:
Sample 1 success count
Sample 1 size
Sample 2 success count
Sample 2 size
Pixels
A-18 Error and Status Messages
Error and Status Messages A-23
Messages Listed Numerically (continued)
# (hex)
7CD
7CE
7CF
7D0
7D1
7D2
7D3
7D4
7D5
7D6
7D7
7D8
7D9
7DA
7DB
7DC
7DD
7DE
7DF
7E0
7E1
7E2
7E3
7E4
7E5
7E6
7E7
7E8
7E9
7EA
7EB
7EC
7ED
7EE
Message
Enter Z eyepoint coordinate
Enter absolute error tolerance
Enter minimum XX range value
Enter maximum XX range value
Enter minimum YY range value
Enter maximum YY range value
PLOT WINDOW
Default
FUNCTION
POLAR
PARAMETRIC
DIFF EQ
CONIC
TRUTH
HISTOGRAM
BAR
SCATTER
SLOPEFIELD
FAST3D
WIREFRAME
PS-CONTOUR
Y-SLICE
GRIDMAP
PR-SURFACE
PLOT WINDOW -
Enter minimum X view-volume val
Enter maximum X view-volume val
Enter minimum Y view-volume val
Enter maximum Y view-volume val
Enter indep var sample count
Enter depnd var sample count
Goto Level:
Specify a level to go to
HISTORY
Advanced Statistics Messages
801
802
803
Must be >= 0
Must be bewteen 0 and 1
µ0:
A-20 Error and Status Messages
Messages Listed Numerically (continued)
# (hex)
804
805
806
807
808
809
80A
80B
80C
80D
80E
80F
810
811
812
813
814
815
816
817
818
819
81A
81B
81C
81D
81E
81F
820
821
822
823
824
825
826
827
828
829
Message
:
N:
Œ:
˜:
Null hypothesis population mean
Sample mean
Sample Size
Significance level
Population standard deviation
Z-TEST: 1 µ, KNOWN ˜
Alternative Hypothesis
1:
˜1:
N1:
Œ:
2:
˜2:
N2:
Sample mean for population 1
Std deviation for population 1
Sample size for population 1
Significance level
Sample mean for population 2
Std deviation for population 2
Sample size for population 2
Z-TEST: 2 µ, KNOWN ˜
π0:
x:
N:
Œ:
Null hyp. population proportion
Success count
Sample size
Significance level
Z-TEST: 1 P
X1:
N1:
Œ:
Error and Status Messages A-21
Messages Listed Numerically (continued)
# (hex)
Four user flags are also used by the system:
Message
BC2A
BC2B
BC2C
BC2D
BC2E
BC2F
BC30
BC31
BC32
BC33
BC34
BC35
BC36
BC37
BC38
BC39
BC3A
BC3B
10 October
BD01
BD02
BD03
BD04
BD05
BD06
BD07
BD08
BD09
BD0A
BD0B
BD0C
BD0D
BD0E
BD0F
BD10
BD11
BD12
1.Integrate…
11 November
12 December
Week
Flag
60
Day
61
Hour
Minute
Second
Weeks
62
Days
Hours
Minutes
Seconds
Month/Day/Year
M/D/Y
63
User Flags
Description
Units Type.
Clear: The Equation Library and Constants Library use SI units.
Set: The Equation Library and Constants Library use English units.
Units Usage.
Clear: The Equation Library and Constants Library display units.
Set: The Equation Library and Constants Library do not display units.
Payment Mode.
Clear: The Time Value of Money solver uses End payment mode.
Set: The Time Value of Money solver uses Begin payment mode.
State Change Mode.
Clear: Must use the MUSE, MCAL, and ALL softkeys in the Multiple Equation
Solver to change the state of a variable from undefined to user-defined.
Set: Simply pressing a softkey in the Multiple Equation Solver toggles its
undefined/user-defined status, hiding the MUSE and MCAL softkeys, but
making it more difficult to retrieve the variable’s value.
Day.Month.Year
D.M.Y
ALARMS
Symbolic Application Prompts
2.Differentiate…
3.Taylor poly…
4.Isolate var…
5.Solve quad…
6.Manip expr…
INTEGRATE
Expr:
Var:
Result:
Enter expression
Enter variable name
Enter lower limit
Enter upper limit
Choose result type
Choose disp format for accuracy
DIFFERENTIATE
Value:
A-38 Error and Status Messages
System Flags C-9
Messages Listed Numerically (continued)
# (hex)
BE10
BE11
BE12
BE13
BE14
BE15
BE16
BE17
BE18
BE19
BE1A
BE1B
BE1C
BE1D
BE1E
BE1F
BE20
BE21
BE22
BE23
BE24
BE25
BE26
BE27
BE28
BE29
BE2A
BE2B
BE2C
BE2D
BE2E
BE2F
BE30
BE31
BE32
BE33
BE34
Message
Enter complex-valued func(s)
Flag
–94
Plot y'(t)=f(t,y)
Enter function of INDEP and SOLN
Enter derivative w.r.t. SOLN
–95
Enter derivative w.r.t. INDEP
Use Stiff diff eq solver?
ΣDat:
Col:
–96
–97
Wid:
Enter data to plot
Arrays in
–98
Enter column to plot
Enter bar width
–99
Cols:
Enter col to use for horizontal
Enter col to use for vertical
–100
Steps:
Enter indep var sample count
Enter dep var sample count
–101
–102
Plot Options
Lo:
Hi:
–103
Axes
Simult
Connect
–104
–105
Pixels
H-Tick:
V-Tick:
–106
Enter minimum indep var value
Enter maximum indep var value
Draw axes before plotting?
Connect plot points?
–107
–108
–109
Plot functions simultaneously?
Enter indep var increment
–110
Indep step units are pixels?
Enter horizontal tick spacing
Enter vertical tick spacing
A-40 Error and Status Messages
–111
System Flags (continued)
Description
Auto-saving.
Clear: In RPN mode, results are stored in LASTCMD.
Set: In RPN mode, results are not stored in LASTCMD.
Entry Mode.
Clear: RPN mode
Set (default): Algebraic mode.
Not used. (Originally intended to toggle the softmenu in the editor in the HP 49G,
though it was never implemented.)
Vertical Lists.
Clear: Lists on stack are displayed horizontally only, like the HP 48GX.
Set: Lists are displayed vertically.
Vertical Vectors.
Clear: Vectors on stack are displayed horizontally only, like the HP 48GX.
Set: Vectors are displayed vertically.
Verbose CAS Mode.
Clear: CAS concise mode.
Set: CAS verbose mode.
Step-by-step CAS Mode.
Clear: Step-by-step mode.
Set: Final result mode.
Internal use only. (Set if VXXL success).
GCD Computations.
Clear: GCD computations allowed.
Set: No GCD computations.
Real/Complex Mode.
Clear: Real mode. “R” annunciator in header.
Set: Complex mode. “C” annunciator in header.
Internal use only. (If set, LN→ –INV[–LN]]).
Exact/Approximate Mode.
Clear: Exact mode. “=” annunciator in header.
Set: Approximate mode, like the HP 48GX calculator. “~” annunciator in header.
TSIMP Calls.
Clear: TSIMP calls are allowed in SERIES.
Set: TSIMP calls are not allowed in SERIES.
Internal use only. (Modular computation).
Internal use only. (Testing remainder to be zero).
Numeric/Symbolic Factorization.
Clear: Numeric factorization is not allowed.
Set: Numeric factorization is allowed.
Large Matrices.
Clear: Use normal-size-matrix code, like the HP 48GX calculator.
Set: Use code optimized for large matrices.
Simplifying Inside Non-rational Expressions.
Clear: Recursive simplification in EXPAND and TSIMP.
Set: No recursive simplification in EXPAND and TSIMP.
System Flags C-7
Messages Listed Numerically (continued)
# (hex)
Message
BE5A
BE5B
BE5C
BE5D
BE5E
BE5F
BE60
BE61
BE62
BE63
BE64
BE65
BE66
BE67
BE68
BE69
BE6A
BE6B
BE6C
BE6D
BE6E
BE6F
BE70
BE71
BE72
BE73
BE74
BE75
BE76
BE77
Enter minimum XX range value
BF01
BF02
BF03
BF04
BF05
BF06
1.Solve equation…
Flag
–65
Enter maximum XX range value
Enter minimum YY range value
Enter maximum YY range value
XX and YY Plot Options
–66
Zoom Factors
H-Factor:
V-Factor:
–67
Recenter at Crosshairs
Enter horizontal zoom factor
Enter vertical zoom factor
–68
Recenter plot at crosshairs?
Reset plot
–69
Dflt
Auto
Function
–70
Polar
Conic
–71
Truth
Parametric
Diff Eq
Histogram
–72
Bar
Scatter
Slopefield
–73
Wireframe
Ps-Contour
–74
Y-Slice
Gridmap
Pr-Surface
–75
Solve Application Prompts
–76
2.Solve diff eq…
3.Solve poly…
4.Solve lin sys…
5.Solve finance…
SOLVE EQUATION
A-42 Error and Status Messages
–77
–78
System Flags (continued)
Description
Multi-line Mode.
Clear: Displays all levels over multiple lines.
Set: Displays only the first level over multiple lines.
Depends on flag –52.
Multi-line Strings.
Clear: Displays long strings in multiple lines.
Set: Displays long strings in single lines.
Depends on flags –52 and –65.
Digital Clock.
Clear: When the clock is displayed (see flag –40), it is digital-style.
Set: When the clock is displayed (see flag –40), it is analog-style.
Auto-indenting.
Clear: Command line does not automatically indent, like the HP 48GX.
Set: Command line automatically indents.
Full-screen Editing.
Clear: The cursor cannot move out of the text line, like the HP 48GX.
Set: Full-screen editing allowed.
Multi-line Text Grobs.
Clear: →GROB can accept only single-line strings. Newlines are turned into
blobs.
Set: →GROB can accept multi-line strings.
Disassembler Addresses.
Clear: Disassembler shows (non-re-assemblable) addresses.
Set: Disassembler does not show addresses.
Stack Font.
Clear: The stack display uses the current system font.
Set: The stack display uses mini-font.
Command Line Font.
Clear: Command line editing uses the current system font.
Set: Command line editing uses mini-font.
Stack Setting.
Clear: The stack is right-justified, like the HP 48GX calculator.
Set: The stack is left-justified.
Keystroke Beep.
Clear: Silent keyboard.
Set: Key click activated if flag –56 is clear.
File Manager Purge Confirmation.
Clear: File Manager purges need confirmation.
Set: No purge confirmation in File Manager.
Not used. (Originally intended to be a filer confirmation flag in the HP 49G,
though it was never implemented.)
I/O Device for wire. Used only when flag –33 is clear, and only on the HP 50g
and 48gII.
Clear: I/O directed to USB port.
Set: I/O directed to serial port.
System Flags C-5
Messages Listed Numerically (continued)
# (hex)
BF2C
BF2D
BF2E
BF2F
BF30
BF31
BF32
BF33
BF34
BF35
BF36
BF37
BF38
BF39
BF3A
BF3B
BF3C
BF3D
BF3E
BF3F
BF40
BF41
BF42
BF43
BF44
BF45
BF46
BF47
BF48
BF49
BF4A
BF4B
BF4C
BF4D
BF4E
BF4F
BF50
Message
Enter roots or press SOLVE
Flag
–36
Coefficients
Roots
SOLVE SYSTEM A·X=B
System Flags (continued)
Description
I/O Receive Overwrite.
Clear: If file name received by the calculator matches existing variable name, new
variable name with number extension is created to prevent overwrite.
Set: If file name received by the calculator matches existing variable name,
existing variable is overwritten.
A:
B:
–37
X:
Enter coefficients matrix A
Enter constants or press SOLVE
–38
Enter solutions or press SOLVE
Constants
–39
Solutions
N:
I%YR:
–40
PV:
PMT:
–41
P/YR:
FV:
Enter no. of payments or SOLVE
–42
Enter yearly int rate or SOLVE
Enter present value or SOLVE
–43
Enter payment amount or SOLVE
Enter no. of payments per year
Enter future value or SOLVE
–44
Choose when payments are made
Double-Spaced Printing.
Clear: Single-spaced printing.
Set: Double-spaced printing.
Line Feed.
Clear: Linefeed added at end of each print line.
Set: No linefeed added at end of each print line.
I/O Messages.
Clear: I/O messages displayed.
Set: I/O messages suppressed.
Clock Display.
Clear: Clock is not displayed.
Set: Ticking clock displayed at all times, provided the header height is 2.
Clock Format.
Clear: 12-hour clock.
Set: 24-hour clock.
Date Format.
Clear: Month/Day format.
Set: Day/Month format.
Repeat Alarm Not Rescheduled.
Clear: Unacknowledged repeat appointment alarms automatically rescheduled.
Set: Unacknowledged repeat appointment alarms not rescheduled.
Acknowledged Alarms Saved.
Clear: Acknowledged appointment alarms deleted from alarm list.
Set: Acknowledged appointment alarms saved in alarm list.
TIME VALUE OF MONEY
N
I%/YR
PV
PMT
FV
–45
through
–48
–49
thru
–50
End
Begin
Beg
–51
AMORTIZE
Payments:
Principal:
A-44 Error and Status Messages
–52
Number of Decimal Digits.
Combined states of flags –45 through –48 sets the number of decimal digits in
Fix, Scientific, and Engineering modes.
Number Display Format.
Standard: –49 clear, –50 clear.
Fix: –49 set, –50 clear.
Scientific: –49 clear, –50 set.
Engineering: –49 set, –50 set.
Fraction Mark.
Clear: Fraction mark is . (period).
Set: Fraction mark is , (comma).
Single-Line Display.
Clear: Display gives preference to object in level 1, using multiple lines of stack
display.
Set: Display of object in level 1 restricted to one line.
System Flags C-3
C
Messages Listed Numerically (continued)
# (hex)
DE1E
DE1F
DE20
DE21
DE22
DE23
DE24
DE25
DE26
DE27
DE28
DE29
DE2A
DE2B
DE2C
DE2D
DE2E
DE2F
DE30
DE31
DE32
DE33
DE34
DE35
DE36
DE37
DE38
DE39
DE3A
DE3B
DE3C
DE3D
DE3E
DE3F
DE40
DE41
DE42
Message
Z is not prime
Empty {} of equations
Not reducible to a rational expression
Non unary operator
User function
Non isolable operator
C. System Flags
This appendix lists the calculator’s system flags. You can set, clear, and test all flags, although certain flags are used
for specific purposes by the CAS and should not be altered. The default state of the flags is clear — except for flags
–17, –27, –34, –90, –95 and –128 and the Binary Integer Math flags (flags –5 through –12).
Not exact system
Parameters not allowed
CAS internal error
Invalid ^ for SERIES
Flag
–1
Operator not implemented (SERIES)
No variable in expr.
No solution found
–2
Invalid derivation arg
No solution in ring
Not a linear system
Can't derive int. var
Diff equation order>2
INT:invalid var change
Mode switch cancelled
No name in expression
Invalid user function
Can't find ODE type
Integer too large
Unable to find sign
Non-symmetric matrix
ATAN insufficent order
ASIN at infinity undef
Unsigned inf error
LN[Var] comparison err
Undef limit for var
Bounded var error
Got expr. indep of var
Can't state remainder
LN of neg argument
Insufficient order
ABS of non-signed 0
A-46 Error and Status Messages
System Flags
Description
Principal Solution.
Clear: Symbolic commands return a result representing all possible solutions.
Set: Symbolic commands return only the principal solution.
Symbolic Constants.
Clear: Symbolic constants (e, i, π, MAXR, and MINR) retain their symbolic form
when evaluated, unless the Numerical Results flag –3 is set.
Set: Symbolic constants evaluate to numbers, regardless of the state of the
Numerical results flag –3.
Numerical Results.
Clear: Functions with symbolic arguments, including symbolic constants, evaluate
to symbolic results.
Set: Functions with symbolic arguments, including symbolic constants, evaluate to
numbers.
Not used. (Originally intended to control the careful evaluation mode in the
–4
HP 48SX, though it was never implemented.)
Binary Integer Wordsize.
–5
through Combined states of flag –5 through –10 (the most significant bit) set the wordsize
from 1 to 64 bits.
–10
Binary Integer Base.
–11
HEX (default): –11 set, –12 set. DEC: –11 clear, –12 clear. OCT: –11 set, –12 clear.
and
–12
BIN: –11 clear, –12 set.
Not used.
–13
Financial Payment Mode.
–14
Clear: TVM calculations assume end-of-period payments.
Set: TVM calculations assume beginning-of-period payments.
Coordinate System.
–15
and
Rectangular: –16 clear.
–16
Polar/Cylindrical: –15 clear, –16 set.
Polar/Spherical: –15 set, –16 set.
Trigonometric Angle Mode.
–17
Radians (default): –17 set.
and
–18
Degrees: –17 clear, –18 clear.
Grads: –17 clear, –18 set.
Vector/Complex.
–19
Clear: →V2 creates a 2-dimensional vector from 2 real numbers.
Set: →V2 creates a complex number from 2 real numbers.
–3
System Flags C-1
Constants
Messages Listed Numerically (continued)
# (hex)
DE67
DE68
Message
Value in SI Units
Replacing strict with large inequality
NA (Avogadro’s number)
6.0221367 x 1023 1 / gmol
No valid environment stored
k (Boltzmann)
1.380658 x 10-23 J / K
Vm (molar volume)
22.4141 l / gmol
File Manager
R (universal gas)
8.31451 J / (gmol•K)
NO
StdT (standard temperature)
273.15 K
ABORT
StdP (standard pressure)
101.325 kPa
ALL
σ (Stefan-Boltzmann)
5.67051 x 10-8 W / (m2•K4)
YES
c (speed of light)
299792458 m/s
REN
ε0 (permittivity)
8.85418781761 x 10-12 F / m
Already Exists
µ0 (permeability)
1.25663706144 x 10-6 H / m
Overwrite ?
g (acceleration of gravity)
9.80665 m / s2
Rename
G (gravitation)
6.67259 x 10-11 m3 / (s2•kg)
PICK DESTINATION
h (Planck’s)
6.6260755 x 10-34 J•s
Are You Sure?
hbar (Dirac’s)
1.05457266 x 10-34 J•s
Search Mode OFF
q (electronic charge)
1.60217733 x 10-19 C
Search Mode ON
me (electron mass)
9.1093897 x 10-31 kg
New DIR?
qme (q/me ratio)
175881962000 C / kg
Sort by:
mp (proton mass)
1.6726231 x 10-27 kg
Original
mpme (mp/me ratio)
1836.152701
Type
α (fine structure)
0.00729735308
Name
ø (mag flux quantum)
2.06783461 x 10-15 Wb
Size
F (Faraday)
96485.309 C / gmol
Inv. Type
R∞ (Rydberg)
10973731.534 1/m
Inv. Name
a0 (Bohr radius)
0.0529177249 nm
Inv. Size
µB (Bohr magneton)
9.2740154 x 10-24 J / T
Sending with Xmodem:
µN (nuclear magneton)
5.0507866 x 10-27 J / T
EDIT
λ0 (photon wavelength)
1239.8425 nm
COPY
f0 (photon frequency)
2.4179883 x 1014 Hz
MOVE
λc (Compton wavelength)
0.00242631058 nm
RCL
rad (1 radian)
1r
EVAL
two̟ (2π radians)
6.28318530718 r
TREE
angl (€ in trig mode)
180 °
PURGE
c3 (Wien’s)
0.002897756 m•K
RENAME
kq (k/q)
0.00008617386 J / (K*C)
NEW
ε0q (ε0/q)
55263469.6 F / (m*C)
ORDER
qε0 (q*ε0)
1.4185978 x 10-30 F*C / m
SEND
εsi (dielectric constant)
11.9
εox (SiO2 dielectric constant)
3.9
I0 (ref intensity)
0.000000000001 W / m2
Filer Application Messages
DF01
DF02
DF03
DF04
DF05
DF06
DF07
DF08
DF09
DF0A
DF0B
DF0C
DF0D
DF0E
DF0F
DF10
DF11
DF12
DF13
DF14
DF15
DF16
DF17
DF18
DF19
DF1A
DF1B
DF1C
DF1D
DF1E
DF1F
DF20
DF21
DF22
Constant (Full Name)
A-48 Error and Status Messages
Tables of Units and Constants B-5
Messages Listed Numerically (continued)
# (hex)
E117
E118
E119
E11A
E11B
E11C
E11D
E11E
E11F
E120
E121
E122
E123
E124
E125
E126
E127
E128
E129
Bohr radius
Bohr magneton
nuclear magneton
photon wavelength
photon frequency
Compton wavelen
453.59237 mol
lbt (troy pound)
.3732417216 kg
lm (lumen)
1 cd•sr
lx (lux)
1 cd•sr / m2
lyr (light year)
9.46052840488 x 1015 m
1m
2π radians
1 x 10-6 m
€ in trig mode
mho (mho)
1 A2•s3 / kg•m2
Wien's
mi (international mile)
1609.344 m
k/q
mil (mil)
.0000254 m
“0/q
min (minute)
60 s
q*“0
miUS (US statute mile)
dielectric const
mmHg (millimeter of mercury (torr), 0 oC)
1609.34721869 m
133.322368421 kg / m•s2
SiO2 dielec cons
mol (mole)
1 mol
ref intensity
mph (miles per hour)
.44704 m / s
CONSTANTS LIBRARY
N (newton)
1 kg•m / s2
Undefined Constant
nmi (nautical mile)
1852 m
Ω (ohm)
1 kg•m2 / A2•s3
oz (ounce)
.028349523125 kg
ozfl (US fluid ounce)
2.95735295625 x 10-5 m3
ozt (troy ounce)
.311034768 kg
ozUK (UK fluid ounce)
2.8413075 x 10-5 m3
Starting Solver
OF
Keyword Conflict
No Picture Available
P (poise)
.1 kg / m•s
MINE
Pa (pascal)
1 kg / m•s2
MINES
pc (parsec)
3.08567818585 x 1016 m
pdl (poundal)
.138254954376 kg•m / s2
YOU MADE IT!!
ph (phot)
10000 cd•sr / m2
YOU BLEW UP!!
pk (peck)
.0088097675 m3
psi (pounds per square inch)
6894.75729317 kg•m / s2
Invalid Mpar
pt (pint)
.000473176473 m3
Single Equation
qt (quart)
.000946352946 m3
EQ Invalid for MINIT
r (radian)
1r
Too Many Unknowns
R (roentgen)
.000258 A•s / kg
All Variables Known
° R (degrees Rankine)
0.555555555556 K
Illegal During MROOT
rad (rad)
.01 m2 / s2
NEAR
SCORE:
Multiple-Equation Solver Messages
E401
E402
E403
E404
E405
E406
E407
Value in SI Units
lbmol (pound-mole)
µ (micron)
1 radian
Minehunt Game Prompts
E305
E306
E307
E308
E309
E30A
Unit (Full Name)
m (meter)
Equation Library Messages
E301
E302
E303
E304
Units (continued)
Message
Rydberg
Solving for
A-50 Error and Status Messages
Tables of Units and Constants B-3
B
Messages Listed Numerically (continued)
# (hex)
1010F
10110
10111
10112
10113
10114
10115
10116
10117
10118
31401
70000
Message
Forbidden
Bad Expression
Jump too Long
B. Tables of Units and Constants
Val betw 1-8 expected
Units
Insuffisant Memory
Unit (Full Name)
Matrix Error
Value in SI Units
Define Error
a (are)
100 m2
[ or ] expected
A (ampere)
1A
ARM register expected
acre (acre)
4046.87260987 m2
ARM invalid imediate
arcmin (minute of arc)
2.90888208666 x 10-4 r
arcs (second of arc)
4.8481368111 x 10-6 r
No Message here
(user-defined message created with DOERR)
atm (atmosphere)
101325 kg / m•s2
au (astronomical unit)
1.495979 x 1011 m
Å (Angstrom)
1 x 10-10 m
b (barn)
1 x 10-28 m2
bar (bar)
100000 kg / m•s2
bbl (barrel)
.158987294928 m3
Bq (becquerel)
11/s
Btu (international table Btu)
1055.05585262 kg•m2 / s2
bu (bushel)
.03523907 m3
oC
(degree Celsius)
299792458 m / s
C (coulomb)
1 A•s
cal (calorie)
4.1868 kg•m2 / s2
cd (candela)
1 cd
chain (chain)
20.1168402337 m
Ci (curie)
3.7 x 1010 1 / s
ct (carat)
.0002 kg
cu (US cup)
2.365882365 x 10-4 m3
(degree)
1.74532925199 x 10-2 r
o
d (day)
A-52 Error and Status Messages
1K or 274.15 K
c (speed of light)
86400 s
dB (decibel)
1 (dimensionless value)
dyn (dyne)
.00001 kg / m•s2
erg (erg)
.0000001 kg•m2 / s2
eV (electron volt)
1.60217733 x 10-19 kg•m2/s2
F (farad)
1 A2•s4 / kg•m2
Tables of Units and Constants B-1
Reserved Variable
What It Contains
Used By
PPAR
Plotting parameters.
DRAW
PRTPAR
Printing parameters.
PRINT commands
PTPAR
Periodic Table parameters.
PERTBL
STARTED
Program run on EDIT.
EDIT
STARTEQW
CST commands list for EQW. Equation Writer
STARTERR
Program run on error.
Error processing
STARTOFF
Program run at turnoff.
OFF
STARTRECV
Program run at RECV.
Filer, RECV
STARTSEND
Program run at SEND.
Filer, SEND
STARTUP
Program run at reset.
Reset
s1, s2,…
Arbitrary signs.
ISOL, QUAD
TOFF
Time in ticks until OFF.
Turnoff delay
TPAR
Table parameters.
Table of values
VPAR
Viewing parameters.
DRAW
ZPAR
Plot zoom factors.
DRAW
ΣDAT
Statistical data.
Statistics application, DRAW
ΣPAR
Statistical parameters.
Statistics application, DRAW
Contents of the System Reserved Variables
αENTER
This is the vectored ENTER pre-processor. It is active when flags –62 and –63 are set. When ENTER is pressed,
the command line is placed on the stack as a string and αENTER is executed.
ALRMDAT
ALRMDAT does not reside in a particular directory. You cannot access the variable itself, but you can access its
data from any directory using the RCLALARM and STOALARM commands, or through the Alarm Catalog.
ALRMDAT contains a list of these alarm parameters:
D-2 Reserved Variables
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
* 81
* 82
* 83
* 84
* 85
* 86
* 87
* 88
* 89
* 90
* 91
* 92
* 93
94
95
* 96
* 97
* 98
* 99
*100
*101
*102
*103
[CONVERT] UNITS NXT POWR (CONVERT 1 10 or UNITS 10: "POWER")
[CONVERT] UNITS NXT PRESS (CONVERT 1 11 or UNITS 11: "PRESSURE")
[CONVERT] UNITS NXT TEMP (CONVERT 1 12 or UNITS 12: "TEMPERATURE")
[CONVERT] UNITS NXT NXT ELEC (CONVERT 1 13 or UNITS 13: "ELECTRIC CURRENT")
[CONVERT] UNITS NXT NXT ANGL (CONVERT 1 14 or UNITS 14: "ANGLE")
[CONVERT] UNITS NXT NXT LIGHT (CONVERT 1 15 or UNITS 15: "LIGHT")
[CONVERT] UNITS NXT NXT RAD (CONVERT 1 16 or UNITS 16: "RADIATION")
[CONVERT] UNITS NXT NXT VISC (CONVERT 1 17 or UNITS 17: "VISCOSITY")
[CONVERT] UNITS TOOLS (CONVERT 1 1 or UNITS 1: "TOOLS")
PRG NXT NXT ERROR IFERR (PRG 14 6: "IF ERROR")
PRG NXT NXT ERROR (PRG 14: "ERROR")
PRG NXT CHARS (PRG 9: "CHAR")
PRG NXT MODES (LS&MODE or PRG 10: "MODES")
PRG NXT MODES FMT (LS&MODE 1: "FORMAT")
PRG NXT MODES ANGLE (LS&MODE 2: "ANGLE")
PRG NXT MODES FLAG (LS&MODE 3: "FLAG")
PRG NXT MODES KEYS (LS&MODE 4: "KEYS")
PRG NXT MODES MENU (LS&MODE 5: "MENU")
PRG NXT MODES MISC (LS&MODE 6: "MISC")
PRG MEM (PRG 2: "MEMORY")
PRG MEM DIR (PRG 2 5: "DIRECTORY")
PRG MEM ARITH (PRG 2 6: "ARITH")
PRG/TOOL STACK (PRG 1 1: "STACK")
RS&NUM.SLV (similar to RS-NUM.SLV; no name)
RS&NUM.SLV ROOT (74 MENU ROOT: "ROOT")
RS&NUM.SLV DIFFEQ (74 MENU DIFFEQ: "DIF EQ")
RS&NUM.SLV POLY (74 MENU POLY: "POLY")
RS&NUM.SLV SYS (74 MENU SYS: "SYS")
RS&NUM.SLV TVM (74 MENU TVM: "TVM")
RS&NUM.SLV TVM SOLVR (FINANCE is the input-form version)
old soft-menu PLOT (no choose-box version available)
old soft-menu PLOT PTYPE (no choose-box version available)
old soft-menu PLOT PPAR (no choose-box version available)
old soft-menu PLOT 3D (81.02 MENU 3D: "3-D")
old soft-menu PLOT 3D PTYPE (no choose-box version available)
old soft-menu PLOT 3D VPAR (no choose-box version available)
old soft-menu PLOT STAT (81.02 MENU STAT: "PLOT STAT")
old soft-menu PLOT STAT PTYPE (no choose-box version available)
old soft-menu PLOT STAT ΣPAR (no choose-box version available)
old soft-menu PLOT STAT ΣPAR MODL (no choose-box version available)
old soft-menu PLOT STAT DATA (87 MENU DATA: "PLOT ΣDAT")
old soft-menu PLOT FLAG (no choose-box version available)
old SYMBOLIC menu (93 DUP MENU MENU LS&PREV: "SYMBOLIC")
PRG NXT NXT TIME (RS&TIME or PRG 13: "TIME")
PRG NXT NXT TIME ALRM (RS&TIME 6 or TIME 4 6 or PRG 13 6 or APPS 5 4 6: "ALARM")
old soft-menu STAT (97 MENU STAT: "STATISTIC")
old soft-menu STAT DATA (96 MENU DATA: "STAT DATA")
old soft-menu STAT ΣPAR (no choose-box version available)
old soft-menu STAT ΣPAR MODL (no choose-box version available)
old soft-menu STAT 1VAR (96 MENU 1VAR: "STAT 1VAR")
old soft-menu STAT PLOT (96 MENU PLOT: "STAT PLOT")
old soft-menu STAT FIT (96 MENU FIT: "STAT FIT")
old soft-menu STAT SUMS (96 MENU SUMS: "STAT SUM")
The Menu-Number Table H-3
H
You can specify menu labels and key actions independently by replacing a single object within the custom-menu list
with a list of the form {“label-object” action-object }.
To provide different shifted actions for custom menu keys, action-object can be a list containing three action objects in
this order:
The unshifted action (required if you want to specify the shifted actions).
The left-shifted action.
The right-shifted action.
EQ
EQ contains the current equation or the name of the variable containing the current equation,
EQ supplies the equation for ROOT, as well as for the plotting command DRAW. (ΣDAT supplies the information
when the plot type is HISTOGRAM, BAR, or SCATTER.)
The object in EQ can be an algebraic object, a number, a name, or a program. How DRAW interprets EQ depends
on the plot type.
For graphics use, EQ can also be a list of equations or other objects. If EQ contains a list, then DRAW treats each
object in turn as the current equation, and plots them successively. However, ROOT in the HP Solve application
cannot solve an EQ containing al list.
To alter the contents of EQ, use the command STEQ.
EXITED
EXITED can be stored in any directory. If there is an EXITED program that exists in the path, it will be called
upon exiting the command line. This can be used in conjunction with STARTED, for instance, to set a header size
of 0 when entering the command line and restore it to 2 when exiting (in order to increase the editor window size).
Note, this is only valid when entering the command line through a EDIT function.
EXPR
EXPR contains the current algebraic expression (or the name of the variable containing the current expression)
used by the SYMBOLIC application and its associated commands. The object in EQ must be an algebraic or a
name.
IOPAR
IOPAR is a variable in the HOME directory that contains a list of the I/O parameters needed for a communications
link with a computer. It is created the first time you transfer data or open the serial port (OPENIO), and is
automatically updated whenever you change the I/O settings. All IOPAR parameters are integers.
H. The Menu-Number Table
Menu Numbers
“*” in the first column means the menu is not one of the keyboard menus and is therefore only available through
the MENU command.
Menus are identified by keyboard path (used when flag –117 is clear) followed by choose-box path (used when flag
–117 is set) followed by its displayed name.
RS-9 means “press right-shift, let go, then press 9”.
RS&9 means “press right-shift, hold it down, and press 9”.
“Abandoned” means that the menu was used in a former ROM version but has been made obsolete by subsequent
improvements to the operating system.
Syntax Example:
16 [MTH] BASE NXT LOGIC (MTH 6 7 or BASE 7: "LOGIC")
This means that menu 16 can be reached in eight different ways:
In algebraic mode:
(1)
MENU(16)
(2)
TMENU(16)
In RPL mode:
(3)
16 MENU
(4)
16 TMENU
In either algebraic or RPL mode:
With flag –117 set (soft-menu mode):
(5)
Press MTH BASE NXT LOGIC
(6)
Press BASE NXT LOGIC
With flag –117 clear (choose-box mode):
(7)
Press MTH 6 ENTER 7 ENTER
(8)
Press BASE 7 ENTER
... and the name shown at the top of the choose box is “LOGIC MENU”.
Note: When a choose-box path is “1”, just press ENTER since the first choice is automatically highlighted in menu
choose boxes.
D-4 Reserved Variables
The Menu-Number Table H-1
MASD.INI
MASD.INI must contain valid MASD source code. This source code will be parsed/compiled before the source on
the stack. It is useful to always include a basic set of commands or definitions in all compiled source.
Keycode
Keystroke
Definition
93.61
[email protected]& 2
¡ (upside down exclamation point)
94.61
[email protected]& 3
¿ (upside down question mark)
MHpar
104.31
@ & í (@& †)
; or . (depends on flag –51)
MHpar stores the status of an interrupted Minehunt game. MHpar is created when you exit Minehunt by pressing
K. If MHpar still exists when you restart Minehunt, the interrupted game resumes and MHpar is purged.
104.61
[email protected]&í(@&†)
; or . (depends on flag –51)
105.31
@ & ï(@& `)
Toggles exact/approximate mode (flag –105)
Mpar
Mpar is created when you use the Equation Library’s Multiple-Equation Solver, and it stores the set of equations
you’re using.
When the Equation Library starts the Multiple-Equation Solver, it first stores a list of the equation set in EQ, and
stores the equation set, a list of variables, and additional information in Mpar. Mpar is then used to set up the Solver
menu for the current equation set.
Mpar is structured as library data dedicated to the Multiple Equation Solver application. This means that although
you can view and edit Mpar directly, you can edit it only indirectly by executing commands that modify it.
You can also use the MINIT command to create Mpar from a set of equations on the stack.
n1, n2, 7
The ISOL and QUAD commands return general solutions (as opposed to principal solutions) or operations. A general
solution contains variables for arbitrary integers or arbitrary signs, or both.
The variable n1 represents an arbitrary integer 0, ±1, ±2, etc. Additional arbitrary integers are represented by n2, n3,
etc.
If flag –1 is set, then ISOL and QUAD return principal solutions, in which case the arbitrary integer is always zero.
Nmines
Nmines is a variable you create in the current directory to control the number of mines used in the Minehunt game.
Nmines contains an integer in the range 1 to 64; if Nmines is negative, the mines are visible during the game.
PPAR
PPAR is a variable in the current directory. It contains a list of plotting parameters used by the DRAW command
for all mathematical and statistical plots, by AUTO for autoscaling, and by the interactive
(nonprogrammable) graphics operations.
Shifted softkeys
This section describes the effect of using the shift keys and menu labels displayed above the A through F keys.
@%VARNAME% = 'varname' !©.
Applies to the VAR menu, CUSTOM menus obtained by pressing !£, or via the programmable MENU or
TMENU commands, and any menu containing a variable (e.g. pressing @%EQ% in the ROOT menu [menu
number 75] yields 'EQ' !©even in program mode.)
! %VARNAME% = 'varname' ‰.
Applies to the VAR menu, CUSTOM menus obtained by pressing !£, (the left shift of the Hkey)or via the
programmable MENU or TMENU commands, and any menu containing a variable (e.g. pressing ! %EQ% in the
ROOT menu [menu number 75] yields 'EQ' ‰ even in program mode.)
The function !î(the left shift of the `key) is really the LASTARG key in RPL mode. It performs the
LASTARG command EXCEPT when pressed immediately after pressing a ‰ or %PURGE% key, including a
!varname ‰. If !îis pressed immediately after a ‰, then the PREVIOUS contents of the variable
are returned (if any). If !îis pressed immediately after a %PURGE% key is pressed, then the purged variable
AND ITS CONTENTS are both returned to the stack. This does not apply if the variable is a directory object. The
purpose of these exceptions is to prevent disaster: If you accidentally PURGE a variable, or wipe out a variable’s
contents by accidentally STOing something else into it, you can recover simply by pressing !î.
Pressing %EDIT% by itself is the same as pressing ˜: it performs an EDITB. ! %EDIT% performs an EDIT.
In the ROOT SOLVR ( @& Ï, %ROOT%, %SOLVR% ), pressing %VARNAME% performs 'varname' K.
@%VARNAME% performs 'varname' ! ©. ! %VARNAME% solves for varname in the current equation.
Pressing ANY key (other than $) while the solver is working causes it to display the current solution interval
until a solution is found. Watching the progress of the solver this way lets you avoid waiting for solutions when the
process is not converging.
Menus that contain mode-toggling keys (e.g. the MISC menu ( !°L%MODES% L%MISC% ) handle the shift
keys in a special way. Pressing ! %MODE% sets the corresponding system flag (unrelated to the previous or
subsequent presence or absence of the “bullet” in the menu key), and in program mode types nn SF where nn is the
flag number. @%MODE% performs the opposite: nn CF. Modes that do not behave this way (e.g. STK and CMD)
are not programmable modes.
D-6 Reserved Variables
Keyboard Shortcuts G-3
G
The $RESET$ operation („&ôL %RESET% ) resets the PPAR parameters (except ptype) to their default values,
and erases PICT. (Note: the & means to press and hold the „key while pressing ô).
Note that res behaves differently for the statistical plot types BAR, HISTOGRAM, and SCATTER than for other
plot types. For BAR, res specifies bar width; for HISTOGRAM, res specifies bin width; res does not affect
SCATTER.
G. Keyboard Shortcuts
PRTPAR
Each key on the calculator performs so many different functions that only the most fundamental ones are actually
shown on the keyboard (on the keys themselves or on the space around the keys). The following is the complete list
of the “hidden” functions of the calculator’s keyboard.
PRTPAR is a variable in the HOME directory that contains a list of printing parameters. It is created automatically
the first time you use a printing command.
Parameter (Command)
delay time (DELAY)
Default
Value
Description
A real number, in the range 0 to 6.9, specifying the
number of seconds the calculator waits between
sending lines. This should be at least as long as the
time required to print the longest line. If the delay is
too short for the printer, you will lose data. The delay
setting also affects serial printing if transmit-pacing
(in IOPAR) is not being used.
0
Notation: In this appendix, there are two ways of showing key presses:
@` means: press Right Shift, release it, then press `.
@&` means: while holding Right Shift, press `.
On-key combinations
The table lists functions that include the $ key. These are not programmable.
Keystroke
ƒ& $
remap (OLDPRT stores the
character-remapping string
for the HP 82240A Infrared
Printer)
A string defining the current remapping of the
Empty
extended character set for printing. The string can
string.
contain as many characters as you want to remap, with
the first character being the new character 128, the
second being the new character 129, etc. (Any
character number that exceeds the string length will
not be remapped.) See the example below.
line length
A real number specifying the number of characters in
a line for serial printing. This does not affect infrared
printing.
80
A string specifying the line-termination method for
serial printing. This does not affect infrared printing.
Note that control character 13 is the carriage return
and 10 is the line feed.
Control
characters
13 and 10.
Definition
Holding these two keys during the entire turn-on routine prevents all added
libraries from being attached AND prevents 'STARTUP' from being
executed. This is useful if the calculator seems to hang up during turn-on.
$& C
Warmstart. Clears the stack, PICT, LASTARG, and other temporary things
like those, and turns off USER Mode. Doesn’t clear any variables. Useful
when the calculator is taking too long to finish a complicated function and
pressing $ doesn’t seem to interrupt it. Also useful if you lock out the
keyboard with a bad USER mode set of key assignments.
$& D
Displays the current ROM’s version and build numbers, then enters Factory
Test Mode. Press $& C to exit
$& F
Like $& D but a friendlier and more complete set of tests, designed for
the end-user. Follow the instructions on the screen. Do NOT format the SD
card unless you wish to lose all of its contents!
$& A& F
Clears the calculator’s RAM, returning everything to the factory state.
Anything in port 2 (flash ROM) will remain untouched.
$& —
Print Screen. Send the current display to the current printer
$& +
Adjusts the display contrast up.
Example: If the remapping string were “ABCDEFGH” and the character to be printed had value 131, then the
character actually printed would be “D”, since 131–128=3 and “A” has the value zero. A character code of 136 or
greater would not be remapped since 136–128=8, which exceeds the length of the string.
$& -
Adjusts the display contrast down.
$& R
Begins a “remote control” mode, where the calculator transmits the screen
bitmap through the USB port and accepts keypresses through the same way.
PTPAR
$& S
Terminates the remote control mode.
line termination
Parameters without modified commands can be modified with a program by storing new values in the list contained
in PRTPAR (use the PUT command).
PTPAR is created when you use the Periodic Table, and it stores the current pointer position information.
STARTED
If it exists, the STARTED variable is evaluated when the command-line editor is evaluated.
D-8 Reserved Variables
$& Ó
($&9)
Forces the very next system interrupt to be ignored. This is intended to allow
the user to shutdown rapidly repeating alarms, but it must be noted that
keystrokes also cause a system interrupt, so be sure NOT to press any key
between pressing $& Ó and the next repeating alarm, or the alarm
will come due and continue repeating.
Keyboard Shortcuts G-1
TPAR
TPAR is a variable in the current directory. It contains a list of parameters used by the table of values plotting
operation.
Parameter
(Command)
starting-value
step
table-format
zoom-factor
font-size
filename
Description
Real number that specifies the first value to show in the
table.
Real number that specifies the amount to increment
from starting-value for each row in the table.
0 for “Automatic”, for generating the table based on
automatically-created values, or 1 for “Build Your
Own”, for generating the table based on values stored in
a vector stored in filename and saving any user-entered
values.
Real number that specifies the zoom factor for the table.
0 for the small font or 1 for the large font.
The name of a variable containing a vector with values
to use for input into the table.
Default Value
0
.1
0
Group 7: Two -argument, one result commands
Two-argument commands can operate in parallel in any of three different ways:
{list } {list }
{list } object
object {list }
In the first form, parallel elements are combined by the command:
{ 1 2 3 } { 4 5 6 } returns { .04 .1 .18 }.
In the second form, the level 1 object is combined with each element in the level 2 list in succession:
{ 1 2 3 } 30 %CH returns { 2900 1400 900 }.
In the third form, the level 2 object is combined with each element of the level 1 list in succession:
50 { 1 2 3 } %T returns { 2 4 6 }.
4
0
TAB
Group 8: Multiple-argument, one-result commands
Commands that take multiple (3, 4, or 5) arguments can perform parallel processing only if all arguments are lists.
For example, { 'SIN(X)' 'COS(X)' 'TAN(X)' } { X X X } { 0 0 0 } ROOT returns { 0
90 0 }. Notice that lists must be used even though the level 1 and level 2 lists each contain multiples of the same
element.
VPAR
Group 9: Multiple-result commands
VPAR is a variable in the current directory. It contains a list of parameters used by the 3D plot types. The main data
structure stored in VPAR describes the “view volume,” the abstract three-dimensional region in which the function
is plotted.
Any command that allows parallel processing, but produces multiple results from its input data, will return its results
as a single list. For example, { 1 2 3 } { 4 5 6 } R→C C→R produces { 1 4 2 5 3 6 } rather
than the more expected { 1 2 3 } { 4 5 6 }.
Parameter
(Command)
Description
Default Value
(xleft, xright) (XVOL)
Real numbers that specify the width of the view volume.
(–1, 1)
(yfar, ynear) (YVOL)
Real numbers that specify the depth of the view volume.
(–1, 1)
(zlow, zhigh) (ZVOL)
Real numbers that specify the height of the view volume. (–1, 1)
(xeye, yeye, zeye) (EYEPT)
Real numbers that specify the point in space from which
the plot is viewed.
(xstep, ystep)
(NUMX, NUMY)
Real numbers that specify the increments between of x- (10, 8)
coordinates and y-coordinates plotted. The increments
are equal to the range for the axes divided by the number
of steps. Used instead of (or in combination with) res.
(0, –3, 0)
(xxleft, xxright) (XXRNG)
Real numbers that specify the width of the input plane
(domain). Used by GRIDMAP and PARSURFACE.
(–1, 1)
(yyfar, yynear) (YYRNG)
Real numbers that specify the depth of the input plane
(domain). Used by GRIDMAP and PARSURFACE.
(–1, 1)
The following UNMIX program will unmix the data given the number of expected result lists:
« OVER SIZE → l n s
« 1 n
FOR j j s
FOR i l i GET n
STEP s n / →LIST
NEXT
»
»
Taking { 1 4 2 5 3 6 } from above as the result of C→R (a command which should return two results),
2 UNMIX gives { 1 2 3 } { 4 5 6 }.
Group 10: Quirky commands
A few commands behave uniquely with respect to parallel processing:
Parameters without commands can be modified programmatically by storing new values in the list contained in
VPAR (use the PUT command).
D-10 Reserved Variables
DELALARM. This command can take a list of arguments. Note, however, that deletions from early in the alarm
list will change the alarm indices of the later alarm entries. Thus, if there are only three alarms,
{ 1 3 } DELALARM will cause an error, whereas { 3 1 } DELALARM will not.
DOERR. This command forces an error state that causes all running programs and commands to halt. Thus,
even though providing the command with a list argument will cause the command to perform parallel processing,
the first error state will cause the command to abort and none of the rest of the list arguments will be used.
FREE, MERGE. These commands are for the HP 48SX and do not apply to these calculators.
RESTORE. This command performs a system warmstart after installing the backup object into memory. All
functions are terminated at that time. Thus, only the first backup object in a list will be restored.
Parallel Processing with Lists F-3
F
ΣPAR
ΣPAR is a variable in the current directory that contains either the current statistical parameter list or the name of
the variable containing this list.
Parameter (Command)
columnindep (XCOL)
Description
Default
Value
A real number specifying the independent-variable’s
column number.
1
columndep (YCOL)
A real number specifying the dependent-variable’s
column number.
2
intercept (LR)
A real number specifying the coefficient of intercept as
determined by the current regression.
0
slope (LR)
A real number specifying the coefficient of slope as
determined by the current regression.
0
model (LINFIT, etc.)
A command specifying the regression model (LINFIT,
EXPFIT, PWRFIT, or LOGFIT).
F. Parallel Processing with Lists
Parallel processing is the idea that, generally, if a command can be applied to one or more individual arguments,
then it can also be extended to be applied to one or more sets of arguments. (Note: some examples assume
approximate mode.)
Some examples:
5 INV returns .2, so { 4 5 8 } INV returns { .25 .2 .125 }.
4 5 * returns 20, so { 4 5 6 } { 5 6 7 } * returns { 20 30 42 }, and { 4 5 6 } 5
* returns { 20 25 30 }.
LINFIT
General rules for parallel processing
As a rule-of-thumb, a given command can use parallel list processing if all the following are true:
The command checks for valid argument types. Commands that apply to all object types, such as DUP, SWAP,
ROT, and so forth, do not use parallel list processing.
The command takes exactly one, two, three, four, or five arguments, none of which may itself be a list.
Commands that use an indefinite number of arguments (such as →LIST) do not use parallel list processing.
The command isn’t a programming branch command (IF, FOR, CASE, NEXT, and so forth).
The remainder of this appendix describes how the many and various commands available on the calculator are
grouped with respect to parallel processing.
Group 1: Commands that cannot parallel process
A command must take arguments before it can parallel process, since a zero-argument command (such as RAND,
VARS, or REC) has no arguments with which to form a group.
Group 2: Commands that must use DOLIST to parallel process
This group of commands cannot use parallel processing directly, but can be “coerced” into it using the DOLIST
command (see Using D later in this appendix). This group consists of several subgroups:
D-12 Reserved Variables
Stack manipulation commands. A stack manipulation command cannot parallel process because the stack is
manipulated as a whole and list objects are treated the same as any other object. Stack commands (such as
DROP) that take level 1 arguments will not accept level 1 list arguments.
Commands that operate on a list as a whole. Certain commands accept lists as arguments but treat them
no differently than any other data object. They perform their function on the object as a whole without respect to
its elements. For example, →STR converts the entire list object to a string rather than converting each individual
element, and the == command tests the level 1 object against the level 2 object regardless of the objects’ types.
List manipulation commands. List manipulation commands will not parallel process since they operate on
list arguments as lists rather than as sets of parallel data. However, a list manipulation command can be forced to
parallel process lists of lists by using the DOLIST command. For example, { { 1 2 3 } { 4 5 6 } }
« œLIST » DOLIST returns { 6 120 }.
Other commands that have list arguments. Because a list can hold any number of objects of any type, it is
commonly used to hold a variable number of parameters of various types. Some commands accept such lists, and
because of this are insensitive to parallel processing, except by using DOLIST.
Index-oriented commands. Many array commands either establish the size of an array in rows and columns
or manipulate individual elements by their row and column indices. These commands expect these row and
column indices to be real number pairs collected in lists. For example, { 3 4 } RANM will generate a random
Parallel Processing with Lists F-1
MODULO
The variable MODULO contains a real prime number for use with the modular operations. The default value is 13.
It is used by ADDTMOD, DIV2MOD, DIVMOD, EXPANDMOD, FACTORMOD, GCDMOD, INVMOD,
MODSTO, MULTMOD, POWMOD, RREFMOD, and SUBTMOD.
Precedence of Operations
Evaluation of an algebraic object is carried according to the order of precedence of the operators — those with
higher precedence are executed first.
Operations with the same order of precedence are executed from left to right.
PERIOD
From highest precedence to lowest, the order of precedence is:
Contains the period for CAS periodic operations. The default value is 2π.
Order
PRIMIT
Contains a primitive (subexpression) used temporarily for anti-derivitive expression during CAS operations.
REALASSUME
The variable REALASSUME contains a list of variables which the CAS assumes are real values.
VX
The variable VX contains the name of the default variable to use for CAS commands which operate on a default
variable. It is used by DERVX, INTVX, SIGMAVX, and SOLVEVX.
D-14 Reserved Variables
Operation
1.
1.1
1.2
1.3
Unit attachment:
Parenthesized expressions from innermost to outermost
Power (^) from bottom to top (i.e. 1_m^2^3^4 = 1_m^24)
Multiplication (*) and Division (/)
2.
Parenthesized expression from innermost to outermost
3.
Functions that require arguments (i.e. SIN, LOG)
4.
Factorial (!)
5.
Power (^) from top to bottom (i.e. 2^2^3^4 = 2^(2^(3^4))) and Root (√, XROOT)
6.
Negation (-), Multiplication (*), Division (/) and Modulus (MOD)
7.
Addition (+) and Subtraction (–)
8.
Relational operators (==, ≠, <, >, ≤, ≥)
9.
Logical operators AND and NOT
10.
Logical operators OR and XOR
11.
Left argument of “Where” (|)
12.
Equal (=)
Technical Reference E-5
Symbolic Integration (continued)
Object Size, continued
Object Type
Size (bytes)
Unit object
real magnitude
each prefix
each unit name
each ×, ^, or /
each exponent
Unquoted global or
local name
Vector
XLIB name
7.5 +
2.5 or 10.5
6
5 + number of characters
2.5
2.5 or 10.5
3.5 + number of characters
12.5 + 8 × number of elements
5.5
Symbolic Integration Patterns
1/(SIN(φ)×TAN(φ))
Pattern
Antiderivative
–INV(SIN(φ))
1/(SIN(φ)2)
–INV(TAN(φ))
SINH(φ)
1/(SINH(φ)×COSH(φ))
COSH(φ)
LN(TANH(φ))
1/(SINH(φ)×TANH(φ))
–INV(SINH(φ))
SQ(φ)
φ 3/3
TAN(φ)2
TAN(φ)–φ
TAN(φ)
–LN(COS(φ))
INV(COS(φ))
LN(SIN(φ))
–INV(SIN(φ))
LN(COSH(φ))
INV(COSH(φ))
LN(SINH(φ))
–INV(SINH(φ))
TAN(φ)/COS(φ)
1/TAN(φ)
1/TAN(φ)×SIN(φ))
This table lists the symbolic integration patterns used by the calculator. These are the integrands that the calculator
can integrate symbolically.
φ is a linear function of the variable of integration. The antiderivatives should be divided by the first–order
coefficient in φ to reduce the expression to its simplest form. Also, patterns beginning with 1 / match INV: for
example, 1 /φ is the same as INV(φ).
Symbolic Integration
TANH(φ)
TANH(φ)/COSH(φ)
1/TANH(φ)
1/TANH(φ)×SINH(φ))
2×φ 1.5/3
φ
1/ φ
1/(2× (φ))
2× φ
2× (φ)×.5
φ×ACOS(φ)– (1–φ 2)
φ z(z symbolic)
IFTE(z = = –1,LN(φ),φ (z+1)/(z+1))
ALOG(φ)
ASIN(φ)
.434294481904×ALOG(φ)
φ×ASIN(φ)+ (1–φ 2)
φ
φ0
φ
ATAN(φ)
φ×ATAN(φ)–LN(1+φ 2)/2
φ –1
LN(φ)
COS(φ)
1/(COS(φ)×SIN(φ))
COSH(φ)
1/(COSH(φ)×SINH(φ))
1/(COSH(φ)2)
SIN(φ)
LN(TAN(φ))
SINH(φ)
LN(TANH(φ))
TANH(φ)
1/φ
LN(φ)
1/(1–φ 2)
ATANH(φ)
1/(1+φ 2)
ATAN(φ)
1/(φ 2+1)
ATAN(φ)
EXP(φ)
EXPM(φ)
LN(φ)
EXP(φ)
EXP(φ)
φ×LN(φ)–φ
1/( (φ–1)× (φ+1))
ACOSH(φ)
1/ (1–φ 2)
ASIN(φ)
1/ (1+φ 2)
ASINH(φ)
LOG(φ)
.434294481904×φ×LN(φ)–φ
1/ (φ 2+1)
ASINH(φ)
SIGN(φ)
SIN(φ)
ABS(φ)
–COS(φ)
LN(TAN(φ))
–INV(SIN(φ))
Pattern
ACOS(φ)
1/(SIN(φ)×COS(φ))
1/(SIN(φ)×TAN(φ))
E-2 Technical Reference
Antiderivative
z(z
real, ≠ 0,–1)
φ (z+1)/(z+1)
Technical Reference E-3
Command
Type Library
VANDERMONDE
C 788-83
Size Keys
5.5 MATRICES CREAT NXT NXT
MTH MATRX MAKE NXT NXT
«MATR» NXT NXT
2.5 100.02 MENU
2.5 PRG MEM DIR NXT
5.5 140 DUP MENUXY
5.5 CAT
5.5 key LS-downarrow
5.5 CAT
5.5 CAT
2.5 PRG TYPE NXT NXT
2.5 MTH VECTR
2.5 PRG NXT IN
2.5 PRG BRCH [WHILE]
VAR
VARS
VER
VERSION
VISIT
VISITB
VPOTENTIAL
VTYPE
V→
WAIT
WHILE
C
C
F
C
C
C
C
C
C
C
C
2-301
2-36
788-140
171-15
221-8
221-10
222-57
2-167
2-180
2-55
1792-5
WIREFRAME
C
171-8
5.5 85 MENU
WSLOG
XCOL
C
C
2-19
2-306
2.5 CAT
2.5 89/98 MENU
XGET
XLIB~
XMIT
XNUM
C
C
C
C
171-112
256-33
2-360
788-103
5.5
5.5
2.5
5.5
XOR
F
2-232
XPON
XPUT
XQ
F
C
C
2-105
171-113
788-104
XRECV
C
171-80
XRNG
XROOT
C
A
2.5 83 MENU
2.5 key 52.3: x-root-of-y
XSEND
C
2-218
2-74
2-75
171-79
XSERV
XVOL
C
C
171-110
171-0
5.5 CAT
5.5 86 MENU
XXRNG
C
171-3
5.5 86 MENU
YCOL
C
2-307
2.5 89/98 MENU
YRNG
C
2-219
2.5 83 MENU
CAT
256.06 MENU
109 MENU
«REWRITE»
142.02 MENU
2.5 PRG TEST NXT
[MTH/CONVERT] BASE NXT LOGIC
2.5 MTH REAL NXT
5.5 CAT
5.5 «REWRITE»
142.02 MENU
5.5 104.02 MENU
5.5 104.02 MENU
Menu
6.03
137.03
146.03
100.02
71.02
?
H
First
1.05
28C
28S
H 1.05
2219.03
48GX
2269.02
1.05
2269.02
1.05
H 1.20
33.03
48SX
4
48SX
39
28C
31
28C
145.02
85
48GX
2219.02
48SX
89
48SX
98
2219.19
1.16
256.06
1.16
109
48SX
142.02 H 1.05
16
32.02
169
14.02
2219.19
142.02 H
28C
28C
1.16
1.05
104.02
2219.14
83
48GX
104.02
2219.14
2219.19
86
2219
86
2219
89
98
83
48GX
48SX
48SX
1.16
48GX
48GX
48SX
48SX
The Command Menu-Path Table I-29
Command
!
Type Library
F 2-99
%
F
2-124
%CH
%T
'
F
F
F
*
*H
*W
+
A
C
C
A
/
A
A
2-126
2-125
1792-20
1792-21
2-71
2-189
2-190
2-68
2-69
2-70
2-72
;
C
2-388
<
F
2-235
=
==
A
F
2-59
2-233
>
F
2-236
?
ABCUV
ABS
F
C
F
788-137
788-48
2-61
ACK
C
2-21
ACKALL
C
2-20
ACOS
ACOS2S
A
C
2-88
788-37
ACOSH
A
2-91
Size Keys
2.5 key ALPHA-RS-2
MTH NXT PROB
2.5 key ALPHA-LS-1
MTH REAL
2.5 MTH REAL
2.5 MTH REAL
2.5 key 43.1
2.5
2.5
2.5
2.5
?
First
28C
28C
14
14
key 75.1
alias for SCALEH
alias for SCALEW
key 95.1
2.5 key 85.1
2.5 key 65.1
RS&NUM.SLV SYS
2.5 key RS&SPC
key ALPHA-LS-2
2.5 key 63.3
PRG TEST
«TESTS»
2.5 key 62.3
2.5 PRG TEST
«TESTS» NXT
2.5 key 64.3
PRG TEST
«TESTS»
5.5 key ALPHA-RS-3
5.5 ARITH POLY
2.5 key 65.2
CMPLX
MATRICES OPER
MTH VECTR
MTH REAL NXT
MTH MATRX NORM
MTH NXT CMPLX
«CMPLX»
2.5 RS&TIME ALRM
PRG NXT NXT TIME ALRM
2.5 RS&TIME ALRM
PRG NXT NXT TIME ALRM
2.5 key 54.2
5.5 TRIG
CONVERT TRIG
«TRIGO»
2.5 MTH HYP
TRIG HYP
«HYPERBOLIC»
I-2 The Command Menu-Path Table
Menu
13
141
14
Command
TESTS
TEVAL
TEXPAND
Type
C
C
C
Library
222-46
788-101
788-19
TEXT
THEN
C
C
2-217
1792-26
1792-1
1792-24
TICKS
C
2-18
28C
28C
28C
-
28C
28C
28C
28C
28C
28C
78
1.05
Size
5.5
5.5
5.5
Keys
«MATHS» NXT
101 DUP MENUXY
EXP&LN
SYMB ALG
SYMB TRIG
ALG NXT
TRIG NXT
SYMB NXT EXPLN
«EXP&LN»
«TRIGO» NXT
«ALGB» NXT
2.5 PRG NXT OUT
2.5 PRG BRCH IF/CASE
PRG NXT NXT ERROR IFERR
2.5 RS&TIME
PRG NXT NXT TIME
APPS 5 4
2.5 RS&TIME
PRG NXT NXT TIME
APPS 5 4
5.5 APPS 12 UTILS NXT
117.02 MENU
5.5 SYMB TRIG
TRIG NXT
CONVERT TRIG NXT
«TRIGO» NXT
2.5 PRG NXT PICT
2.5 LS&MODE MENU
PRG NXT MODES MENU
2.5 100 MENU
5.5 MATRICES OPER NXT NXT
MTH MATRX NORM NXT
32
28C
TIME
C
2-16
32
28C
28C
TINC
F
171-101
32
28C
TLIN
C
788-25
TLINE
TMENU
C
C
2-207
2-348
TOT
TRACE
C
C
2-300
171-39
TRAN
C
788-69
5.5 MATRICES OPER NXT NXT
MTH MATRX NORM NXT
«MATR»
TRANSIO
TRIG
C
C
2-373
788-27
TRIGCOS
C
788-28
TRIGO
C
788-130
2.5 106 MENU
5.5 SYMB TRIG
TRIG NXT NXT
CONVERT TRIG NXT
«TRIGO» NXT NXT
5.5 TRIG NXT NXT
CONVERT TRIG NXT
«TRIGO» NXT NXT
5.5 «MAIN»
126
4
7
14.02
20
130
147
156
H
H
1.05
1.05
28C
95
48SX
95
48SX
122
140
12
161
H
28C
1.05
28C
Menu
121
122.02
124.02
139
151
155
?
H
H
H
40
24
25
60
145
94
167
First
1.20
1.05
1.05
48SX
28C
48SX
94
167
48SX
117.02
48GX
2219.17
122.02 H 1.05
139
140.02
38
68
48SX
48SX
100
28C
7.02
48GX
147.02
156.03
2219.07
7.02
H 1.05
137.03
147.02
156.03
106
48SX
122.03 H 1.05
139
140.02
122.03
140.02
H
1.05
H
1.05
The Command Menu-Path Table I-27
Command
ATAN2S
Type Library
C 788-34
Size Keys
5.5 TRIG
CONVERT TRIG
«TRIGO»
2.5 MTH HYP
TRIG HYP
«HYPERBOLIC»
5.5 83.02 MENU
ATANH
A
2-92
ATICK
C
171-16
ATTACH
AUGMENT
AUTO
AXES
AXL
C
C
C
C
C
2-358
222-19
2-192
2-186
788-74
2.5
5.5
2.5
2.5
5.5
AXM
C
788-73
5.5
AXQ
C
788-76
5.5
110 MENU
MATRICES CREAT
81.02 MENU
83.02 MENU
CONVERT MATRX
MATRICES OPER
«MATR»
MATRICES OPER
«MATR»
CONVERT MATRIX
MATRICES QUADF
«MATR» NXT
256 MENU
256 MENU
88 MENU
101 MENU
MATRICES NXT VECT
106 MENU
PRG NXT OUT NXT
90/99 MENU
A→
A→H
BAR
BARPLOT
BASIS
BAUD
BEEP
BESTFIT
C
C
C
C
C
C
C
C
256-3
256-4
2-227
2-316
222-17
2-371
2-52
2-323
5.5
5.5
2.5
2.5
5.5
2.5
2.5
2.5
BIN
C
2-144
2.5 [MTH/CONVERT] BASE
BINS
BLANK
BOX
BUFLEN
BYTES
BetaTesting
B→R
C
C
C
C
C
C
C
2-315
2-209
2-208
2-375
2-38
256-25
2-10
2.5
2.5
2.5
2.5
2.5
5.5
2.5
100 MENU
PRG NXT GROB
PRG NXT PICT
109 MENU
PRG MEM
256.05 MENU
[MTH/CONVERT] BASE
C2P
CASCFG
CASCMD
CASE
C
C
C
C
222-30
788-126
222-51
1792-25
5.5
5.5
5.5
2.5
ARITH PERM
«MAIN»
TOOL NXT
PRG BRCH CASE
CD→
CEIL
CENTR
C
F
C
256-7
2-104
2-187
5.5 256.02 MENU
2.5 MTH REAL NXT NXT
2.5 83.02 MENU
I-4 The Command Menu-Path Table
Menu
122
140
? First
H 1.05
256
256
88
101
160
106
40.02
90
99
15
168
100
37
38
109
70
256.05
15
168
174
25
145.03
256.02
14.03
83.02
Type Library
C 2-8
Size Keys
2.5 [MTH/CONVERT] BASE NXT BYTE
28C
SRECV
SREPL
C
C
2-361
221-16
48GX
SREV
START
C
C
256-15
1792-9
48SX
1.20
48SX
28C
H 1.05
STD
C
2-141
STEP
C
1792-12
2.5 LS&MODE FMT
PRG NXT MODES FMT
2.5 PRG BRCH START/FOR
STEQ
C
2-250
2.5 RS&NUM.SLV ROOT LS-EQ
H
1.05
H
1.05
STIME
STO
C
C
2-376
2-341
STO*
STO+
STOSTO/
STOALARM
C
C
C
C
C
2-330
2-327
2-328
2-329
2-25
STOF
C
2-151
STOKEYS
C
2-381
STORE
STOVX
STOΣ
F
C
C
222-36
222-64
2-283
2.5 109 MENU
2.5 key 32.1
PRG MEM DIR
2.5 PRG MEM ARITH
2.5 PRG MEM ARITH
2.5 PRG MEM ARITH
2.5 PRG MEM ARITH
2.5 RS&TIME ALRM
PRG NXT NXT TIME ALRM
2.5 LS&MODE FLAG NXT
PRG NXT MODES FLAG NXT
2.5 LS&MODE KEYS
PRG NXT MODES KEYS
5.5 «ALGB» NXT
5.5 CAT
2.5 91/97 MENU LS-ΣDAT
STREAM
C
171-88
5.5 PRG LIST PROC
STR→
STRM
STURM
STURMAB
STWS
C
C
C
C
C
2-163
255-0
222-22
222-23
2-148
2.5
5.5
5.5
5.5
2.5
SUB
C
2-156
SUBST
F
788-2
2.5 RS&CHARS
PRG LIST
PRG NXT GROB
PRG NXT CHARS
MATRICES CREAT NXT NXT
MTH MATRX MAKE NXT
5.5 ALG NXT
SYMB ALG
«ALGB» NXT
12
161
83.02
2219.03
110
146
81.02
83.02
135
156
173
135
156
157
173
Command
SRB
H
1.05
1.05
48SX
48SX
H 1.20
48SX
28C
48SX
28C
48SX
48SX
48SX
48SX
48SX
1.05
28C
H
H
1.20
1.05
1.20
48SX
1.05
28C
28C
2.5 109 MENU
5.5 RS&CHARS NXT
PRG NXT CHARS NXT
5.5 256.03 MENU
2.5 PRG BRCH [START]
CAT
APPS 14
ARITH POLY PREV
ARITH POLY PREV
[MTH/CONVERT] BASE NXT
Menu
18
171
109
62.02
2269.03
?
First
28C
48SX
1.05
1.05
28C
26
145
64
28C
26
27
145.02
75 +
[LS]-EQ
109
71
28C
48SX
28C
72
72
72
72
95
28C
28C
28C
28C
48SX
66.02
28C
67
48SX
28C
H
H
91
97
36
2219.15
1.20
1.20
28C
48GX
126.04
126.04
15.02
168.02
6.02
34
37
62
146.03
H
H
124.02
151
H
28C
2.15
1.20
1.20
28C
28C
1.05
The Command Menu-Path Table I-25
Command
COND
Type Library
C 171-38
CONIC
CONJ
C
F
2-221
2-62
CONLIB
C
171-24
CONST
C
171-25
CONSTANTS
CONT
CONVERT
C
C
C
222-42
2-58
2-11
CORR
COS
COSH
C
A
A
2-289
2-82
2-85
COV
CR
CRC
CRDIR
CRLIB
CROSS
C
C
C
C
C
C
2-290
2-243
256-27
2-32
256-26
2-122
CSWP
C
171-65
Size Keys
5.5 MATRICES OPER
MTH MATRX NORM
2.5 82 MENU
2.5 CMPLX
MTH NXT CMPLX NXT
«CMPLX»
5.5 APPS 3
APPS 12 COLIB
115 MENU
5.5 APPS 12 COLIB
115 MENU
5.5 «MATHS»
2.5 key 101.02
2.5 [CONVERT] UNITS TOOLS
2.5 102 MENU
2.5 key 54.1
2.5 MTH HYP
TRIG HYP
«HYPERBOLIC»
2.5 102 MENU
2.5 107 MENU
5.5 256.05 MENU
2.5 PRG MEM DIR
5.5 256.05 MENU
2.5 MTH VECTR
MATRICES NXT VECT
5.5 MTH MATRX COL
MATRICES CREAT COL
CURL
C
788-87
5.5 CALC DERIV
CYCLOTOMIC
CYLIN
F
C
222-21
171-18
C→PX
C→R
C
C
2-199
2-159
DARCY
F
171-97
DATE
C
2-17
5.5 ARITH POLY
5.5 LS&MODE ANGLE
MTH VECTR NXT
PRG NXT MODES ANGLE
2.5 PRG NXT PICT NXT
2.5 PRG TYPE NXT
MTH NXT CMPLX
5.5 APPS 12 UTILS
117 MENU
2.5 RS&TIME
PRG NXT NXT TIME
APPS 5 4
I-6 The Command Menu-Path Table
Menu
7
147
156
2219.07
82
20.02
130
?
First
48GX
48SX
28C
115
2219.05
48GX
115
2219.05
48GX
H
59
118
102
12
161
1.20
48SX
28C
28C
28C
28C
102
28C
107
28C
256.05
1.16
71
28S
256.05
1.05
4
28C
137
160
9
48GX
149
165
2219.11
136
H 1.05
162
126
H 1.20
4.02
48GX
65
2219.04
38.02
48SX
20
28C
33.02
117
48GX
2219.17
94
48SX
167
Command
R→I
SAME
SBRK
SB~B
SCALE
SCALEH
SCALEW
SCATRPLOT
SCATTER
SCHUR
Type
F
C
C
C
C
C
C
C
C
C
Library
2-389
2-228
2-377
256-20
2-194
2-189
2-190
2-318
2-225
171-51
SCI
C
2-139
SCLΣ
SCONJ
SCROLL
C
C
C
2-313
2-326
788-125
SDEV
SEND
SEQ
C
C
C
2-299
2-364
171-83
SERIAL
SERIES
C
C
256-29
788-7
SERVER
SEVAL
SF
C
F
C
2-369
788-100
2-131
SHOW
SIDENS
C
F
2-338
171-99
SIGMA
SIGMAVX
SIGN
F
F
F
222-2
222-1
2-78
SIGNTAB
C
788-95
SIMP2
SIMPLIFY
C
F
788-51
222-34
Size
2.5
2.5
2.5
5.5
2.5
2.5
2.5
2.5
2.5
5.5
Keys
CONVERT REWRITE NXT NXT
PRG TEST NXT
109 MENU
256.04 MENU
83.02 MENU
83.02 MENU
83.02 MENU
101 MENU
88 MENU
MATRICES FACT
MTH MATRX FACTR
2.5 LS&MODE FMT
PRG NXT MODES FMT
2.5 CAT
2.5 PRG MEM ARITH NXT
5.5 TOOL VIEW is the same as SCROLL DROP
125 DUP MENUXY
2.5 100 MENU
2.5 104 MENU
5.5 PRG LIST PROC NXT
5.5 256.05 MENU
5.5 SYMB CALC
CALC LIMIT
«DIFF» NXT
2.5 105 MENU
5.5 100 DUP MENUXY
2.5 LS&MODE FLAG
PRG TEST NXT NXT
PRG NXT MODES FLAG
2.5 93 MENU
5.5 APPS 12 UTILS
117 MENU
5.5 CALC DERIV NXT
5.5 CALC DERIV NXT NXT
2.5 CMPLX NXT
MTH REAL NXT
MTH NXT CMPLX NXT
«CMPLX» NXT
5.5 SYMB GRAPH
CALC GRAPH
5.5 ARITH NXT
5.5 in EQW
CONVERT REWRITE NXT
«REWRITE»
«EQW»
Menu
172.03
32.02
109
256.04
83.02
83.02
83.02
101
88
8
148
2219.09
64
?
First
1.05
28C
48SX
1.05
48SX
1.05
1.05
48SX
48SX
48GX
28C
72.02
H
28C
28C
1.05
100
28C
104
48SX
36.02
48GX
2219.14
256.05
1.16
136.03 H 1.05
152
163
105
48SX
H 1.05
32.03
28C
66
93
28C
117
48GX
2219.17
162.02 H 1.16
162.03 H 1.16
14.02
28C
20.02
130.02
142
153
177
125.02
172.02
H
1.05
H
H
1.05
1.20
The Command Menu-Path Table I-23
Command
DIR
DISP
DISPXY
DISTRIB
Type
C
C
C
F
Library
1792-27
2-50
221-22
222-25
Size
2.5
2.5
5.5
5.5
DIV
C
788-86
Keys
CAT
PRG NXT OUT
CAT
CONVERT REWRITE
«REWRITE»
5.5 CALC DERIV
DIV2
DIV2MOD
C
C
788-38
788-114
5.5 ARITH POLY
5.5 ARITH MODUL
DIVIS
C
788-68
DIVMOD
F
788-113
DIVPC
F
788-98
DO
C
1792-7
5.5 ARITH
SYMB ARITH
«INTEGER»
5.5 ARITH MODUL
«MODULAR»
5.5 CALC LIMIT
«DIFF»
2.5 PRG BRCH [DO]
DOERR
DOLIST
C
C
2-42
171-91
2.5 PRG NXT NXT ERROR
5.5 PRG LIST PROC
DOMAIN
DOSUBS
C
C
222-33
171-84
5.5 CAT
5.5 PRG LIST PROC
DOT
C
2-121
2.5 MTH VECTR
MATRICES NXT VECT
DRAW
DRAW3DMATRIX
DRAX
DROITE
DROP
C
C
C
F
C
2-191
171-107
2-193
222-35
2-272
2.5
5.5
2.5
5.5
2.5
DROP2
DROPN
DTAG
DUP
C
C
C
C
2-273
2-277
2-385
2-269
2.5
2.5
2.5
2.5
DUP2
DUPDUP
DUPN
D→R
EDIT
C
C
C
F
C
2-270
2-398
2-278
2-112
221-7
2.5
2.5
2.5
2.5
5.5
EDITB
C
221-9
5.5
I-8 The Command Menu-Path Table
81 MENU
CAT
81 MENU
«CMPLX»
PRG/TOOL STACK
backspace key when not editing
PRG/TOOL STACK NXT NXT
PRG/TOOL STACK NXT NXT
PRG TYPE NXT
PRG/TOOL STACK
ENTER key when not editing
PRG/TOOL STACK NXT NXT
PRG/TOOL STACK NXT NXT
PRG/TOOL STACK NXT NXT
MTH REAL NXT NXT
key LS-downarrow
TOOL LS-EDIT
key downarrow
TOOL
Menu
First
48SX
40
28C
2269.04
1.20
172
H 1.20
136
162
126
128
138
125
134
?
H
1.05
H
H
1.05
1.05
H
1.05
128
H 1.05
138
136
H 1.05
163
29
28C
145.02
61
48SX
36
48GX
2219.16
H 1.20
36
48GX
2219.15
4
28C
137
160
81
28C
2219.18 H 1.05
81
28C
H 1.20
73
28C
73.03
73.03
33.02
73
28C
28C
48SX
28C
73.03
73.03
73.03
14.03
2269.02
28C
1.05
28C
28C
1.05
2269.02
1.05
Command
RCLΣ
Type Library
C 2-286
Size Keys
2.5 91/97 MENU RS-ΣDAT
RCWS
C
2-149
2.5 [MTH/CONVERT] BASE NXT
RDM
C
2-172
RDZ
RE
C
F
2-128
2-154
RECN
RECT
C
C
2-366
171-17
RECV
REF
C
C
2-367
788-72
REMAINDER
F
788-42
RENAME
REORDER
REPEAT
C
F
C
221-19
788-105
1792-6
2.5 MTH MATRX MAKE
MATRICES CREAT NXT NXT
2.5 MTH NXT PROB
2.5 CMPLX NXT
MTH NXT CMPLX
«CMPLX» NXT
2.5 104.02 MENU
5.5 LS&MODE ANGLE
MTH VECTR NXT
PRG NXT MODES ANGLE
2.5 104 MENU
5.5 MATRICES LIN-S
«MATR»
5.5 ARITH POLY PREV
«POLYNOMIAL» NXT
5.5 CAT
5.5 105 DUP MENUXY
2.5 PRG BRCH WHILE
REPL
C
2-157
RES
RESTORE
RESULTANT
REVLIST
C
C
F
C
2-188
2-354
222-5
171-93
REWRITE
RISCH
C
F
222-40
788-13
RKF
C
171-32
5.5 «MAIN» NXT
5.5 CALC DERIV NXT
«DIFF» NXT
5.5 RS&NUM.SLV DIFFEQ
RKFERR
C
171-34
5.5 RS&NUM.SLV DIFFEQ
RKFSTEP
C
171-33
5.5 RS&NUM.SLV DIFFEQ
RL
C
2-1
2.5 [MTH/CONVERT] BASE NXT BIT
RLB
C
2-2
2.5 [MTH/CONVERT] BASE NXT BYTE
RND
F
2-108
2.5 MTH REAL NXT NXT
2.5 RS&CHARS
PRG LIST
PRG NXT GROB
PRG NXT CHARS
MTH MATRX MAKE NXT
MATRICES CREAT NXT NXT
2.5 83 MENU
2.5 PRG MEM NXT
5.5 ARITH POLY PREV
5.5 MTH LIST
PRG LIST PROC
Menu
? First
91
28C
97
15.02
28C
168.02
6
28C
146.03
13
28C
20
28C
130.02
141.02
104.02
48SX
4.02
48GX
65
2219.03
104
48SX
137.03 H 1.05
158
126.04 H 1.05
2269.04
H
31
145.02
6.02
34
37
62
146.03
1.05
1.05
28C
48SX
83
48GX
70.02
48SX
126.04 H 1.16
11
48GX
36
2219.16
H 1.20
136.03 H 1.05
162.02
76
48GX
2219.06
76
48GX
2219.06
76
48GX
2219.06
17
28C
170
18
28C
171
14.03
28C
The Command Menu-Path Table I-21
Command
EXPAN
Type Library
C 2-334
EXPAND
C
788-0
EXPANDMOD
F
788-118
EXPFIT
C
2-321
EXPLN
C
788-23
Size Keys
2.5 93/142 MENU
5.5 ALG
SYMB ALG
«ALGB»
5.5 ARITH MODUL
«MODULAR»
2.5 90/99 MENU
5.5 EXP&LN
CONVERT REWRITE
SYMB NXT EXPLN
«EXP&LN»
«REWRITE»
2.5 EXP&LN
MTH HYP NXT
EXPM
A
2-98
EYEPT
C
171-5
5.5 86.02 MENU
F0λ
F
171-98
FACT
FACTOR
F
C
2-100
788-1
5.5 APPS 12 UTILS
117 MENU
2.5 CAT
5.5 ALG
SYMB ALG
ARITH POLY
«ALGB»
«INTEGER»
«POLYNOMIAL»
in EQW
5.5 ARITH MODUL
«MODULAR»
5.5 ARITH
5.5 APPS 12 UTILS
117 MENU
2.5 CAT
2.5 LS&MODE FLAG
PRG TEST NXT NXT
PRG NXT MODES FLAG
2.5 LS&MODE FLAG
PRG TEST NXT NXT
PRG NXT MODES FLAG
5.5 ARITH POLY NXT
«SOLVER»
5.5 CONVERT REWRITE
«REWRITE»
5.5 MTH NXT FFT
FACTORMOD
F
788-119
FACTORS
FANNING
C
F
788-67
171-96
FAST3D
FC?
C
C
2-400
2-134
FC?C
C
2-143
FCOEF
C
788-65
FDISTRIB
F
222-24
FFT
C
171-26
FILER
C
221-12
5.5 key 21.2
CAT
I-10 The Command Menu-Path Table
Menu
93
142
124
142
151
128
138
90
99
121
135
155
172
?
First
28C
H
1.05
H
1.05
POTENTIAL
POWEXPAND
C
F
222-56
222-27
48SX
POWMOD
F
788-115
1.05
PR1
C
2-240
28C
PREDV
PREDX
PREDY
PREVAL
C
C
C
F
2-303
2-305
2-304
788-12
2.5
2.5
2.5
5.5
PREVPRIME
F
788-62
5.5
PRLCD
PROMPT
PROMPTSTO
PROOT
C
C
C
C
2-246
1792-28
788-139
171-68
2.5
2.5
5.5
5.5
PROPFRAC
C
788-53
PRST
PRSTC
PRVAR
PSDEV
C
C
C
C
2-242
2-241
2-244
171-29
5.5 SYMB ARITH
ARITH NXT
«POLYNOMIAL» NXT
2.5 107 MENU
2.5 107 MENU
2.5 107 MENU
5.5 100.02 MENU
PSI
PTAYL
F
F
222-4
788-54
PTPROP
PURGE
F
C
229-1
2-344
PUSH
PUT
C
C
222-52
2-176
PUTI
C
2-177
PVAR
C
171-30
5.5 MTH NXT SPECIAL
5.5 ARITH POLY NXT NXT
«POLYNOMIAL» NXT
5.5 APPS 13
2.5 TOOL
PRG MEM
PRG MEM DIR
5.5 CAT
2.5 PRG LIST ELEM
MATRICES CREAT NXT
MTH MATRX MAKE NXT
2.5 PRG LIST ELEM
MATRICES CREAT NXT
MTH MATRX MAKE NXT
5.5 100.02 MENU
PVARS
C
2-351
2.5 110 MENU
H
12.02
121
141
86.02
2219
117
2219.17
124
126
142
151
48GX
48GX
H
48GX
1.05
128
H 1.05
138
125
H 1.05
117
48GX
2219.17
1.05
32.03
28C
66
32.03
66
Type Library
C 222-53
C 2-161
28C
126.02
H
1.05
172
H
1.20
19
2219.05
2269.03
Command
POP
POS
48GX
1.05
Size Keys
5.5 CAT
2.5 RS&CHARS
PRG LIST ELEM
PRG NXT CHARS
5.5 CAT
5.5 CONVERT REWRITE NXT
«REWRITE»
5.5 ARITH MODUL NXT
«MODULAR» NXT
2.5 104/107 MENU
CAT
102 MENU
102 MENU
CALC DERIV NXT
«DIFF» NXT
ARITH INTEG NXT
«INTEGER» NXT
107 MENU (hotkey: ON+uparrow)
PRG NXT IN NXT
139 DUP MENUXY
RS&NUM.SLV POLY
ARITH POLY NXT NXT
Menu
?
H
First
1.20
28C
H
H
1.20
1.20
H
1.05
35
62
172.02
128.02
138.02
104
107.02
102
102
136.03
162.02
127.02
107
39.02
28C
28C
48SX
48SX
H 1.05
H
1.05
28C
48SX
H 1.05
48GX
77
126.03
2219.12
125.02 H
134
1.05
107
28C
107
28C
107
28C
100.02
48GX
2219.05
176
H 1.16
126.03 H 1.05
2.15
28C
70
71
H
6.02
35
146.02
6.02
35
146.02
100.02
2219.06
110
1.20
28C
28C
48GX
48SX
The Command Menu-Path Table I-19
Command
GRAPH
GREDUCE
GREY
GRIDMAP
Type
C
C
C
C
Library
2-200
222-59
1792-29
171-10
Size
2.5
5.5
2.5
5.5
GROB
GROBADD
C
C
1792-29
788-124
GXOR
HADAMARD
C
C
2-212
788-70
HALFTAN
C
788-32
HALT
HEAD
C
C
1792-14
171-81
HEADER→
HELP
HERMITE
C
C
F
221-5
222-50
788-92
HESS
C
788-89
2.5 CAT
5.5 SYMB GRAPH
CALC GRAPH
2.5 PRG NXT GROB
5.5 MATRICES OPER NXT
«MATR»
5.5 TRIG
SYMB TRIG
CONVERT TRIG
«TRIGO»
2.5 PRG NXT NXT RUN
5.5 RS&CHARS NXT
PRG LIST ELEM NXT
PRG NXT CHARS NXT
5.5 CAT
5.5 TOOL NXT
5.5 ARITH POLY NXT
«POLYNOMIAL»
5.5 CALC DERIV
HEX
C
2-146
2.5 [MTH/CONVERT] BASE
HILBERT
C
788-84
5.5 MATRICES CREAT NXT
MTH MATRX MAKE NXT NXT
HISTOGRAM
HISTPLOT
HMS+
C
C
C
2-226
2-317
2-116
HMS-
C
2-117
HMS→
C
2-115
HOME
HORNER
HYPERBOLIC
H→
H→A
H→S
IABCUV
C
C
C
C
C
C
C
2-34
788-55
222-43
256-1
256-5
256-9
788-49
2.5 88 MENU
2.5 101 MENU
2.5 RS&TIME NXT
PRG NXT NXT TIME NXT
APPS 5 4 NXT
2.5 RS&TIME NXT
PRG NXT NXT TIME NXT
APPS 5 4 NXT
2.5 RS&TIME NXT
PRG NXT NXT TIME NXT
APPS 5 4 NXT
2.5 key LS&UPDIR
5.5 ARITH POLY NXT
5.5 «MATHS»
5.5 256 MENU
5.5 256 MENU
5.5 256.02 MENU
5.5 ARITH INTEG
I-12 The Command Menu-Path Table
Keys
alias for PICTURE
CAT
must be typed in
85 MENU
Menu
? First
- 48SX
H 1.20
- 1.20
48GX
Command
MULTMOD
Type Library
F 788-112
Size Keys
5.5 ARITH MODUL NXT
«MODULAR» NXT
5.5 APPS 12 MES
116 MENU
5.5 MTH NXT PROB NXT
2.5 PRG/TOOL STACK PREV
2.5 key 62.1: +/CMPLX
MTH NXT CMPLX NXT
«CMPLX» NXT
2.5 PRG MEM
2.5 PRG BRCH START/FOR
MUSER
C
171-117
NDIST
NDUPN
NEG
C
C
A
171-28
2-399
2-60
NEWOB
NEXT
C
C
2-39
1792-11
NEXTPRIME
F
788-61
NIP
NOT
C
F
2-396
2-231
NOVAL
NSUB
C
F
2-391
171-86
NUM
C
2-164
NUMX
C
171-6
2.5 RS&CHARS
PRG TYPE NXT
PRG NXT CHARS
5.5 86.02 MENU
NUMY
C
171-7
5.5 86.02 MENU
48SX
48SX
28C
NΣ
OBJ→
C
C
2-288
2-169
94.02
167.02
28C
OCT
C
2-147
2.5 103 MENU
2.5 PRG TYPE
PRG LIST
RS&CHARS NXT
PRG NXT CHARS NXT
2.5 [MTH/CONVERT] BASE
94.02
167.02
28C
OFF
OLDPRT
OPENIO
OR
C
C
C
F
2-41
2-239
2-362
2-230
2.5
2.5
2.5
2.5
ORDER
OVER
P2C
PA2B2
PARAMETRIC
PARITY
C
C
C
F
C
C
2-346
2-275
222-31
788-57
241-3
2-372
2.5
2.5
5.5
5.5
2.5
2.5
85
2219.02
153
177
37
137
156.02
122
139
140
48SX
H 1.05
H
48SX
1.05
H
1.05
41
35.02
62.02
2219.14
2269
28C
48GX
126.02
H
1.05
1.20
1.05
136.02
162
15
168
6.03
137.02
146.02
88
101
94.02
167.02
H
1.05
126.02
256
256
256.02
127
28C
H
H
H
H
1.05
28S
1.05
1.20
1.05
1.05
1.05
1.05
5.5 ARITH INTEG NXT
«INTEGER» NXT
2.5 PRG/TOOL STACK NXT NXT
2.5 PRG TEST NXT
[MTH/CONVERT] BASE NXT LOGIC
«TESTS» NXT
2.5 PRG NXT IN
5.5 PRG LIST PROC
PRG NXT NXT RUN NXT
108 MENU
109 MENU
PRG TEST NXT
[MTH/CONVERT] BASE NXT LOGIC
«TESTS» NXT
PRG MEM DIR NXT
PRG/TOOL STACK
ARITH PERM
ARITH INTEG NXT
82 MENU
106 MENU
Menu
? First
128.02 H 1.05
138.02
116
48GX
2219.2
2219.05
48GX
73.04
1.05
20.02
28C
130
70
26
27
145.02
127.02
73.03
16
32.02
169
39
36
2219.15
33.02
62
48SX
28C
H
1.05
1.05
28C
48GX
48GX
28C
86.02
2219.02
86.02
2219.02
103
33
34
62.02
48GX
15
168
41.02
108
109
16
32.02
169
71.02
73
174
127.02
82
106
28C
48GX
28C
48SX
48SX
48SX
48SX
28C
28C
28C
H 1.20
H 1.05
48SX
48SX
The Command Menu-Path Table I-17
Command
IREMAINDER
Type Library
F 788-43
ISOL
C
2-336
ISOM
ISPRIME?
C
F
222-13
788-60
I→R
JORDAN
F
C
2-390
788-80
KER
KERRM
KEY
KEYEVAL
KEYTIME→
KGET
KILL
LABEL
LAGRANGE
C
C
C
C
C
C
C
C
C
222-15
2-374
2-57
788-123
171-109
2-365
2-40
2-201
788-93
LANGUAGE→
LAP
C
F
221-1
788-16
LAPL
C
788-88
LAST
LASTARG
C
C
2-54
2-54
LCD→
LCM
C
F
2-213
788-45
LCXM
C
788-85
LC~C
LDEC
C
C
256-23
788-18
LEGENDRE
F
788-90
LGCD
LIBEVAL
LIBS
LIMIT
C
C
C
F
788-50
171-22
2-357
788-5
Size Keys
5.5 SYMB ARITH
ARITH INTEG NXT
«INTEGER» NXT
2.5 S.SLV
«SOLVER»
5.5 MATRICES LINAP
5.5 SYMB ARITH
ARITH INTEG NXT
«INTEGER» NXT
2.5 CONVERT REWRITE
5.5 MATRICES NXT EIGEN
«MATR» NXT
5.5 MATRICES LINAP
2.5 104.02 MENU
2.5 PRG NXT IN
5.5 123 DUP MENUXY
5.5 CAT
2.5 105 MENU
2.5 PRG NXT NXT RUN
2.5 81.02 MENU
5.5 ARITH POLY NXT
5.5 CAT
5.5 CALC DIFF
«DIFF» NXT NXT
5.5 CALC DERIV NXT
2.5 alias for LASTARG
2.5 key 105.2 in RPL mode
PRG NXT NXT ERROR
2.5 PRG NXT GROB NXT
5.5 ARITH POLY NXT NXT
«POLYNOMIAL»
«INTEGER» NXT
5.5 137.02 MENU
85 DUP MENUXY
5.5 256.04 MENU
5.5 S.SLV
SYMB SOLVE
CALC DIFF
«SOLVER»
5.5 ARITH POLY NXT NXT
«POLYNOMIAL»
5.5 ARITH NXT
5.5 CAT
2.5 110 MENU
5.5 alias for lim
I-14 The Command Menu-Path Table
Menu
127.02
134
93
120
175
127.02
134
172
137.02
159
175
104.02
39
?
H
First
1.05
Type Library
C 788-20
28C
H
H
1.20
1.05
H
1.05
1.05
1.20
48SX
28C
H 1.05
2219.19
1.05
105
48SX
41
28C
81.02
48SX
126.02 H 1.05
142
2269
1.05
136.02 H 1.05
164
136.02 H 1.05
164
- 28C
61
48SX
H
37.02
126.03
H
28S
1.05
137.02
H
1.05
H
1.05
1.05
H
1.05
256.04
120
136.03
154
164
126.03
Command
LIN
125.02 H 1.05
2219.04
48GX
110
48SX
- 1.05
Size Keys
5.5 ALG
EXP&LN
SYMB ALG
CONVERT REWRITE
SYMB NXT EXPLN
«EXP&LN»
«REWRITE»
2.5 PRG NXT PICT
2.5 90/99 MENU
Menu
121
124
135
151
155
172
LINE
LINFIT
C
C
2-206
2-319
LININ
F
171-21
5.5 PRG TEST PREV
LINSOLVE
C
788-82
LIST→
LN
C
A
2-158
2-94
LNAME
LNCOLLECT
C
C
788-109
788-22
LNP1
A
2-97
5.5 S.SLV
SYMB SOLVE
MATRICES LIN-S
«SOLVER»
«MATR» NXT NXT
2.5 CAT
2.5 key 51.3
141 MENU
5.5 109 DUP MENUXY
5.5 ALG
EXP&LN
SYMB NXT EXPLN
CONVERT REWRITE NXT
«EXP&LN»
«REWRITE»
2.5 EXP&LN
MTH HYP NXT
LOCAL
LOG
C
A
222-60
2-95
LOGFIT
C
2-320
LQ
C
171-50
5.5 MATRICES FACT
MTH MATRX FACTR
LR
LR~R
LSQ
C
C
C
2-302
256-21
171-43
2.5 102 MENU
5.5 256.04 MENU
5.5 MTH MATRX
RS&NUM.SLV SYS
MATRICES OPER NXT
LU
C
171-48
5.5 MATRICES FACT
MTH MATRX FACTR
LVAR
C
788-106
5.5 106 DUP MENUXY
5.5 CAT
2.5 key 61.3
141.02 MENU
2.5 90/99 MENU
?
H
First
1.05
38
48SX
90
48SX
99
32.04
48GX
2219.04
120
H 1.05
137.02
154
158
28C
28C
141
121
124
155
172.02
H
H
12.02
121
141
1.05
1.05
28C
H
141.02
90
99
8
148
2219.09
102
256.04
5
78
156.02
2219.08
8
137.02
148
2219.09
1.20
28C
48SX
48GX
28C
1.05
48GX
48GX
H
1.05
The Command Menu-Path Table I-15
Command
→HMS
Type Library
C 2-114
→KEYTIME
→LANGUAGE
→LCD
→LIST
C
C
C
C
171-108
221-0
2-214
2-154
→LST
→MINIFONT
→NDISP
→NUM
C
C
C
C
256-10
221-17
221-6
2-53
→PRG
→Q
C
C
256-12
2-263
Size Keys
2.5 RS&TIME NXT
PRG NXT NXT TIME NXT
APPS 5 4 NXT
5.5 CAT
5.5 CAT
2.5 PRG NXT GROB NXT
2.5 PRG TYPE
PRG LIST
5.5 256.02 MENU
5.5 CAT
5.5 CAT
2.5 key 105.3
CONVERT REWRITE NXT
5.5 256.03 MENU
2.5 CONVERT REWRITE NXT
→Qп
C
2-264
2.5 CONVERT REWRITE NXT
→RAM
→ROW
C
C
256-14
171-54
5.5 256.03 MENU
5.5 MTH MATRX ROW
MATRICES CREAT ROW
→S2
→STR
C
C
256-32
2-162
→TAG
→TIME
C
C
2-384
2-23
→UNIT
C
2-13
5.5 256.06 MENU
2.5 PRG TYPE
RS&CHARS NXT
PRG NXT CHARS NXT
2.5 PRG TYPE
2.5 RS&TIME
PRG NXT NXT TIME
APPS 5 4
2.5 PRG TYPE
[CONVERT] UNITS TOOLS
→V2
→V3
↓MATCH
↑MATCH
∆LIST
C
C
C
C
C
2-181
2-182
2-266
2-265
171-85
2.5
2.5
2.5
2.5
5.5
ΠLIST
C
171-90
5.5 MTH LIST
∞
F
788-138
«
»
C
C
1792-18
1792-17
1792-19
5.5 key 102.2
«CONSTANTS»
2.5 key 95.3
2.5 key 95.3
I-32 The Command Menu-Path Table
MTH VECTR
MTH VECTR
93.02 MENU
93.02 MENU
MTH LIST
Menu
94.02
167.02
?
First
28C
2219.19
2269
37.02
33
34
256.02
2269.04
2269.02
172.02
1.05
1.05
28S
28C
256.03
93.02
172.02
93.02
172.02
256.03
10
150
166
2219.1
256.06
33
62.02
1.05
48SX
1.05
1.05
1.05
28C
48SX
1.05
48GX
1.16
28C
33
94
167
48SX
48SX
33
59
118
4
4
93.02
93.02
11
2219.15
11
2219.16
48SX
48SX
48SX
48SX
48SX
48GX
48GX
H
1.05
28C
28C
The following table shows the relation between character codes (results of NUM, arguments to CHR) and
characters (results of CHR, arguments to NUM), as well as the translation codes to be used to transmit characters
between the calculator and a remote device, for the upper half of the character set.
Character Codes 128-255 With ASCII Character Translations
Code
128
129
130
131
132
133
134
135
136
137
138
Trans.
€ \<)
 \x‚ \.V
ƒ \v/
„ \.S
Σ \GS
► \|>
π \pi
ˆ \.d
‰ \<=
Š \>=
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
‹ \=/
Π\Ga
→ \->
← \<↓ \|v
↑ \|^
‘ \Gg
’ \Gd
“ \Ge
” \Gn
• \Gh
– \Gl
— \Gr
˜ \Gs
™ \Gt
š \Gw
› \GD
œ \PI
Ž \GW
ā \[]
Ÿ \oo
€ \160
¡ \161
162
163
164
165
166
167
168
169
¢ \162
£ \163
¤ \164
¥ \165
¦ \166
§ \167
¨ \168
© \169
Description
angle
x bar
gradient
square root
integration
Sigma
store
pi
derivation
less than or equal
greater than or
equal
not equal
alpha
right arrow
left arrow
down arrow
up arrow
gamma
delta
epsilon
eta
theta
lambda
rho
sigma
tau
omega
Delta
Pi
Omega
box
infinity
euro
upside-down
exclamation
cents
pounds
general currency
yen
broken pipe
section
dieresis/umlaut
copyright
Code
170
171
172
173
174
Trans.
ª \170
« \<<
¬ \172
− \173
® \174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
¯ \175
° \^o
± \177
² \178
³ \179
´ \180
µ \Gm
¶ \182
· \183
¸ \184
¹ \185
º \186
» \>>
¼ \188
½ \189
¾ \190
¿ \191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
À \192
Á \193
 \194
à \195
Ä \196
Å \197
Æ \198
Ç \199
È \200
É \201
Ê \202
Ë \203
Ì \204
Í \205
Î \206
Ï \207
Ð \208
Ñ \209
Ò \210
Ó \211
J-2 ASCII Character Codes and Translations
Description
feminine ordinal
begin program
logical negation
negative
registered
trademark
macron
degree
plus/minus
superscript 2
superscript 3
acute accent
mu
paragraph
dot
cedilla
superscript 1
masculine ordinal
end program
vulgar 1/4
vulgar 1/2
vulgar 3/4
upside-down
question
A grave
A acute
A circumflex
A tilde
A dieresis/umlaut
A ring
A-E ligature
C cedilla
E grave
E acute
E circumflex
E dieresis/umlaut
I grave
I acute
I circumflex
I dieresis
Eth
N tilde
O grave
O acute
Code
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
Trans.
Ô \212
Õ \213
Ö \214
× \.x
Ø \O/
Ù \217
Ú \218
Û \219
Ü \220
Ý \221
Þ \222
ß \Gb
à \224
á \225
â \226
ã \227
ä \228
å \229
æ \230
ç \231
è \232
é \233
ê \234
ë \235
ì \236
í \237
î \238
ï \239
ð \240
ñ \241
ò \242
ó \243
ô \244
õ \245
ö \246
÷ \:ø \248
ù \249
ú \250
û \251
ü \252
ý \253
þ \254
ÿ \255
Description
O circumflex
O tilde
O dieresis/umlaut
multiplication
O slash
U grave
U acute
U circumflex
U dieresis/umlaut
Y acute
Thorn
beta
a grave
a acute
a circumflex
a tilde
a dieresis/umlaut
a ring
a-e ligature
c cedilla
e grave
e acute
e circumflex
e umlaut
i grave
i acute
i circumflex
i dieresis
eth
n tilde
o grave
o acute
o circumflex
o tilde
o dieresis/umlaut
division
o slash
u grave
u acute
u circumflex
u dieresis/umlaut
y acute
thorn
y dieresis
alpha keyboard
automatically locking..................................................1-42
ALRMDAT.......................................................................D-2
alternant..........................................................................3-269
AMORT ...........................................................................3-11
AND .................................................................................3-11
angular motion.................................................................5-36
ANIMATE.......................................................................3-12
animation................................................................2-31, 2-39
annunciators
user flags.......................................................................1-27
ANS...................................................................................3-12
APEEK .............................................................................. 6-2
APLY ................................................................................2-20
applications ......................................................................1-53
APPLY..............................................................................3-13
ARC...................................................................................3-13
ARCHIVE .......................................................................3-14
ARG ..................................................................................3-14
arguments
verifying........................................................................2-24
ARIT .................................................................................3-15
ARM→ ..................................................................... 6-3, 6-41
arrays
applying a program to ................................................2-20
manipulating ......................................................2-12, 2-34
maximum and minimum elements...........................2-16
sorting elements ..........................................................2-16
ARRY→ ...........................................................................3-15
ASIN .................................................................................3-15
ASIN2C............................................................................3-17
ASIN2T ............................................................................3-17
ASINH..............................................................................3-17
ASM .................................................................................... 6-3
asm (internal) ...................................................................6-42
ASM→...................................................................... 6-3, 6-41
ASM2 ................................................................................6-42
ASN...................................................................................3-18
ASR ...................................................................................3-19
Assembler.........................................................................6-11
Assembler syntax ............................................................6-11
ASSUME..........................................................................3-19
ATAN...............................................................................3-20
ATAN2S...........................................................................3-21
ATANH ...........................................................................3-22
ATICK..............................................................................3-22
ATTACH .........................................................................3-23
AUGMENT ....................................................................3-23
AUTO...............................................................................3-24
AXES ................................................................................3-24
AXL...................................................................................3-25
AXM .................................................................................3-25
AXQ..................................................................................3-26
Index - 2
B
B→R................................................................................. 3-30
BAR .................................................................................. 3-26
BARPLOT....................................................................... 3-27
BASIS ............................................................................... 3-27
BAUD .............................................................................. 3-27
BDISP .................................................................................2-7
BEEP................................................................................ 3-28
beeper
in programs ................................................................. 1-48
BER .................................................................................. 2-29
Bernoulli equation .......................................................... 5-19
Bessel functions .............................................................. 2-29
BESTFIT ......................................................................... 3-28
BetaTesting.........................................................................6-3
BIN ................................................................................... 3-28
binary integers
comparing.................................................................... 1-12
custom display................................................................2-5
representing flags.............................................. 1-28, 1-29
wordsize ....................................................................... 1-12
binary operations
and ................................................................................ 3-11
convert to real ............................................................. 3-30
converting to binary................................................. 3-214
exclusive OR ............................................................. 3-277
not............................................................................... 3-157
regular or.................................................................... 3-161
rotate...................................................3-204, 3-205, 3-209
set wordsize............................................................... 3-242
shift....................................................... 3-19, 3-227, 3-232
BINS................................................................................. 3-29
bipolar transistors ........................................................... 5-54
black body........................................................................ 3-82
black body radiation....................................................... 5-31
BLANK............................................................................ 3-29
BOX ................................................................................. 3-29
branching structures
conditional structures ...................................... 1-13, 1-35
loop structures ............................................................ 1-17
program element............................................................1-2
BRCH menu.......................................................... 1-13, 1-17
Brewster angle................................................................. 5-38
buckling...............................................................................5-4
BUFLEN ......................................................................... 3-30
business
amortization ................................................................ 3-11
time value of money................................................. 3-261
BYTES ............................................................................. 3-30
C
C$ ...................................................................................... 3-31
C→PX.............................................................................. 3-49
C→R................................................................................. 3-49
C2P ................................................................................... 3-31
CROSS..............................................................................3-47
CST.....................................................................................D-3
CSWP................................................................................3-47
CURL................................................................................3-48
current.............................................................5-9, 5-31, 5-50
cursor (command line) ...................................................1-42
custom menus
in programs..................................................................1-52
menu-based applications............................................1-53
customization
keyboard .......................................................................3-18
cycle.......................................................................3-31, 3-163
CYCLOTOMIC..............................................................3-48
CYLIN..............................................................................3-48
cylinder..............................................................................5-48
D
D→R.................................................................................3-71
DARCY ............................................................................3-49
DATE ...............................................................................3-49
DATE+............................................................................3-50
DBUG ..............................................................................3-50
DDAYS ............................................................................3-51
debugging ...............................................................1-31, 1-32
DEC ..................................................................................3-51
DECR ...............................................................................3-51
DEDICACE....................................................................3-52
DEF ..................................................................................3-52
DEFINE ..........................................................................3-52
defining procedures
compiled local variables in ........................................1-10
local variable structures................................................ 1-7
local variables i .............................................................. 1-9
definite loops .............................2-1, 2-18, 2-32, 2-34, 2-39
with counters ....................................................... 2-8, 2-12
DEG .................................................................................3-53
DEGREE.........................................................................3-53
degree-minute-seconds.................................................3-107
DELALARM...................................................................3-53
DELAY ............................................................................3-54
DELKEYS.......................................................................3-54
DEPND ...........................................................................3-55
DEPTH ............................................................................3-55
DERIV .............................................................................3-56
Derivative .......................................................................3-291
DERVX............................................................................3-56
DESOLVE ......................................................................3-56
DET ..................................................................................3-57
DETACH.........................................................................3-57
DIAG→ ...........................................................................3-58
DIAGMAP ......................................................................3-58
DIFF .................................................................................3-59
DIFFEQ...........................................................................3-59
diodes................................................................................5-52
DIR....................................................................................3-60
Index - 4
Directives......................................................................... 6-17
Disassembler ................................................................... 6-41
DISP ................................................................................. 3-60
display
area numbers ............................................................... 1-39
clearing ......................................................................... 1-49
freezing......................................................................... 1-39
DISPXY........................................................................... 3-61
DISTRIB.......................................................................... 3-61
DIV................................................................................... 3-62
DIV2................................................................................. 3-62
DIV2MOD...................................................................... 3-62
Divide ............................................................................. 3-300
DIVIS............................................................................... 3-63
DIVMOD........................................................................ 3-63
DIVPC ............................................................................. 3-63
dn ...................................................................................... 3-64
DO.................................................................................... 3-64
do looping.................................................... 1-22, 2-14, 2-29
DOERR ........................................................................... 3-65
DOLIST........................................................................... 3-65
DOMAIN........................................................................ 3-66
DOSUBS ......................................................................... 3-66
DOT ................................................................................. 3-67
drag force......................................................................... 5-24
DRAW ............................................................................. 3-68
DRAW3DMATRIX ...................................................... 3-68
DRAX .............................................................................. 3-68
DROITE.......................................................................... 3-69
DROP .................................................................. 3-69, 3-304
DROP2 ............................................................................ 3-69
DROPN........................................................................... 3-70
DTAG .............................................................................. 3-70
DUP.................................................................................. 3-70
DUP2................................................................................ 3-70
DUPDUP ........................................................................ 3-71
DUPN .............................................................................. 3-71
E
e ........................................................................................ 3-71
EDIT ................................................................................ 3-72
EDITB ............................................................................. 3-72
editing
programs .........................................................................1-6
EGCD .............................................................................. 3-72
EGV ................................................................................. 3-73
EGVL............................................................................... 3-73
EIZ ................................................................................... 1-54
elastic buckling...................................................................5-4
elastic collisions............................................................... 5-24
electricity .....................................................................5-3, 5-9
ellipse ................................................................................ 5-44
ELSE ................................................................................ 3-73
END................................................................................. 3-73
ENDSUB......................................................................... 3-74
Fibonacci numbers ........................................................... 2-1
FIBT.................................................................................... 2-4
Filename conventions ....................................................6-17
FILER...............................................................................3-87
FINDALARM.................................................................3-87
FINISH ............................................................................3-87
FIX ....................................................................................3-87
flags
annunciators.................................................................1-27
binary integer form .....................................................1-29
clearing..........................................................................1-27
control behavior..........................................................1-27
controlling logic with........................................2-16, 2-18
default states ................................................................. C-1
preserving and restoring status ......................... 2-6, 2-34
program control ..........................................................1-27
recalling states....................................................1-28, 1-29
restoring states.............................................................1-28
setting......................................1-27, 2-8, 2-16, 2-18, 2-37
storing states ................................................................1-28
system .................................................................1-27, 1-28
testing........................................................1-27, 2-16, 2-18
types ..............................................................................1-27
user ................................................................................1-27
FLASHEVAL..................................................................3-88
FLOOR ............................................................................3-88
fluids..................................................................................5-18
focal length.......................................................................5-37
FONT→ ..........................................................................3-89
FONT6.............................................................................3-88
FONT7.............................................................................3-89
FONT8.............................................................................3-89
FOR...................................................................................3-90
for looping....1-20, 1-21, 2-8, 2-12, 2-18, 2-32, 2-33, 2-39
electrostatic force ............................................................5-10
force ..............................................................5-21, 5-22, 5-32
FOURIER........................................................................3-91
Fourier transform............................................................3-86
Fourier transform, inverse...........................................3-113
FP ......................................................................................3-91
fractions
converting ......................................................3-187, 3-278
FREE ................................................................................3-91
free fall motion................................................................5-35
FREEZE ..........................................................................3-91
frequency
resonant ........................................................................5-16
friction losses ...................................................................5-21
FROOTS..........................................................................3-92
FS? .....................................................................................3-92
FS?C ..................................................................................3-93
FUNCTION....................................................................3-93
FXND...............................................................................3-94
Index - 6
G
GAMMA.......................................................................... 3-95
Gamma function........................................................... 3-291
garbage collection ......................................................... 3-146
gas compressibility........................................................ 3-285
gas-compressibility factor.............................................. 5-27
gases.................................................................................. 5-25
GAUSS............................................................................. 3-95
GBASIS............................................................................ 3-95
GCD ................................................................................. 3-96
GCDMOD ...................................................................... 3-96
geometry................................................................. 5-43, 5-47
GET.................................................................................. 3-97
GETADR ........................................................................ 6-42
GETI ................................................................................ 3-97
GETNAME .................................................................... 6-42
GETNAMES.................................................................. 6-42
global variables
action in programs.........................................................1-1
disadvantages in programs...........................................1-7
GOR ................................................................................. 3-98
GRAD.............................................................................. 3-98
GRAMSCHMIDT ......................................................... 3-99
GRAPH ........................................................................... 3-99
graphics
animation ..................................................................... 3-12
appending .................................................................. 3-101
blank ............................................................................. 3-29
box drawing................................................................. 3-29
clearing PICT .............................................................. 3-75
custom.......................................................................... 2-39
display text......................................................... 3-60, 3-61
displaying ................................................................... 3-128
drawing arc .................................................................. 3-13
exclusive OR ............................................................. 3-101
freeze display............................................................... 3-91
line drawing ............................................................... 3-254
pixel check ................................................................. 3-170
pixel off...................................................................... 3-171
pixel on....................................................................... 3-171
screenshot.................................................................. 3-128
subset.......................................................................... 3-242
graphics commands
parallel processing with ............................................... F-2
graphics objects
manipulating............................................ 2-32, 2-34, 2-39
gravitation .................................................... 5-24, 5-35, 5-36
Greater than .................................................................. 3-295
Greater than or Equal.................................................. 3-295
GREDUCE..................................................................... 3-99
GRIDMAP.................................................................... 3-100
GROB ............................................................................ 3-101
GROBADD .................................................................. 3-101
GXOR............................................................................ 3-101
L
LABEL ...........................................................................3-126
Labels ................................................................................6-13
LAGRANGE ................................................................3-126
LANGUAGE→ ...........................................................3-126
LAP .................................................................................3-127
LAPL...............................................................................3-127
LAST...............................................................................3-127
last argument
recalling........................................................................... 2-8
LASTARG .....................................................................3-128
LC~C .................................................................................. 6-5
LCD→............................................................................3-128
LCM ................................................................................3-129
LCXM.............................................................................3-129
LDEC .............................................................................3-129
LEGENDRE ................................................................3-130
length factor....................................................................... 5-4
Less than.........................................................................3-293
Less than or Equal ........................................................3-294
LGCD.............................................................................3-130
LIBEVAL.......................................................................3-130
LIBS ................................................................................3-131
light....................................................................................5-37
lim....................................................................................3-131
LIMIT .............................................................................3-131
LIN..................................................................................3-131
LINE...............................................................................3-132
linear motion....................................................................5-35
linear structure.................................................................1-13
LINFIT...........................................................................3-133
LININ.............................................................................3-133
Links..................................................................................6-13
LINSOLVE ...................................................................3-133
list concatenation ..............................................................F-2
list processing programming example .........................2-20
LIST→............................................................................3-133
lists
action in programs ........................................................ 1-1
adding ............................................................................. 3-9
concatenation...............................................................3-23
parallel processing.........................................................F-1
reversing .....................................................................3-202
sorting ...............................................................2-11, 3-230
LN ...................................................................................3-135
LNAME .........................................................................3-136
LNCOLLECT...............................................................3-137
LNP1...............................................................................3-137
LOCAL...........................................................................3-137
Local Names, Evaluating................................................. 1-9
local variable structures
advantages ...................................................................... 1-8
as user-defined functions...........................................1-10
calculations with............................................................ 1-2
create local variables ..................................................... 1-7
Index - 8
defining procedure ................................................1-7, 1-9
entering ...........................................................................1-7
operation.................................................................1-2, 1-7
program element............................................................1-2
syntax.......................................................................1-2, 1-7
local variables .....................................................................2-6
action in programs.........................................................1-1
compiled ...................................................................... 1-10
creating............................................................................1-7
evaluating ..................................................................... 2-14
exist temporarily ............................................1-7, 1-8, 1-9
naming.............................................................................1-7
nested ................................................................. 2-29, 2-34
passing between programs........................................ 2-33
storing objects in .............................................. 2-14, 2-26
LOG ............................................................................... 3-138
LOGFIT ........................................................................ 3-138
logic
controlling.................................................................... 2-18
controlling with flags ....................................... 2-16, 2-19
functions ........................................ 2-16, 2-18, 2-25, 2-26
Logical Equality ............................................................ 3-302
logical functions.................................................... 1-11, 1-12
longitudinal waves .......................................................... 5-59
loop structures
counters................................ 1-18, 1-19, 1-20, 1-21, 1-25
definite.......................... 1-17, 2-2, 2-18, 2-32, 2-34, 2-39
do looping.................................................................... 1-22
for looping......................................................... 1-20, 1-21
indefinite ................................ 1-17, 1-22, 2-5, 2-14, 2-16
keystroke input............................................................ 1-49
negative steps .................................................... 1-19, 1-21
program element....................................................1-1, 1-2
start looping ................................................................ 1-19
start looping ................................................................ 1-18
summation alternative ............................................... 1-26
test commands in ............................................. 1-22, 1-24
while looping............................................................... 1-24
lowercase letters
in names ..........................................................................1-7
LQ................................................................................... 3-139
LR.................................................................................... 3-139
LR~R...................................................................................6-5
LSQ................................................................................. 3-139
LST ................................................................................... 1-53
LU ................................................................................... 3-140
LVAR ............................................................................. 3-140
M
Mach number .................................................................. 5-26
Macros.................................................................... 6-16, 6-22
MAD............................................................................... 3-141
magnetic field ........................................................ 5-31, 5-33
magnetism........................................................................ 5-31
magnification................................................................... 5-37
UNTIL............................................................................3-265
UPDIR............................................................................3-265
UPs ..........................................................................6-21, 6-30
user input
reading key .................................................................3-123
waiting.........................................................................3-272
user-defined errors..........................................................1-33
user-defined functions
internal structure ...............................................1-10, 1-11
utility programs................................................................2-26
UTPC..............................................................................3-265
UTPF ..............................................................................3-266
UTPN .............................................................................3-266
UTPT ..............................................................................3-267
UVAL .............................................................................3-267
V
V→..................................................................................3-267
VANDERMONDE.....................................................3-269
VAR ................................................................................3-269
variables
action in programs ........................................................ 1-1
decrementing ...............................................................1-25
incrementing ................................................................1-25
VARS ..............................................................................3-270
vectored enter..................................................................2-37
VER.................................................................................3-270
VERSION......................................................................3-270
VFY...................................................................................2-26
waves.................................................................................5-59
VISIT ..............................................................................3-271
VISITB ...........................................................................3-271
VOL .................................................................................... 1-4
voltage....................................................................... 5-9, 5-51
VPOTENTIAL.............................................................3-271
VSPH ................................................................................1-41
VTYPE...........................................................................3-272
VX ....................................................................................D-14
W
WAIT..............................................................................3-272
waiting
displaying output.........................................................1-51
for keystrokes ....................................................1-48, 1-49
WALK ..............................................................................2-39
WGT .................................................................................1-53
Where..............................................................................3-286
WHILE...........................................................................3-273
while looping ........................................................... 1-24, 2-5
WIREFRAME...............................................................3-273
WSLOG..........................................................................3-274
X
XCOL............................................................................. 3-276
XGET ............................................................................ 3-276
XLIB~.................................................................................6-9
XMIT.............................................................................. 3-276
XNUM ........................................................................... 3-277
XOR ............................................................................... 3-277
XPON ............................................................................ 3-278
XPUT ............................................................................. 3-278
XQ .................................................................................. 3-278
XRECV.......................................................................... 3-279
XRNG............................................................................ 3-279
XROOT......................................................................... 3-279
XSEND.......................................................................... 3-280
XSERV........................................................................... 3-280
XVOL............................................................................. 3-281
XXRNG......................................................................... 3-281
Y
YCOL............................................................................. 3-282
YRNG ............................................................................ 3-283
YSLICE.......................................................................... 3-283
YVOL............................................................................. 3-284
YYRNG ......................................................................... 3-284
Z
ZEROS .......................................................................... 3-284
ZFACTOR .................................................................... 3-285
ZVOL............................................................................. 3-285
Α
αENTER................................................................. 2-37, D-2
Π
ΠLIST ............................................................................ 3-134
Σ
Σ- (Sigma Minus).......................................................... 3-290
Σ (Summation).............................................................. 3-289
Σ+ (Sigma Plus)............................................................ 3-289
ΣLINE ........................................................................... 3-132
ΣLIST............................................................................. 3-134
ΣX................................................................................... 3-275
ΣX*Y.............................................................................. 3-281
ΣX^2 .............................................................................. 3-276
ΣX2................................................................................. 3-275
ΣXY................................................................................ 3-281
ΣY ................................................................................... 3-282
ΣY^2............................................................................... 3-282
ΣY2................................................................................. 3-282
Index - 17
N
P
SSEC .................................................................................1-44
names
action in programs ........................................................ 1-1
NAMES............................................................................2-25
nBASE ..............................................................................2-22
NDIST............................................................................3-154
NDUPN .........................................................................3-155
NEG ...............................................................................3-155
nested structures....................................................2-28, 2-29
New MASD instructions ...............................................6-26
newlines .................................................................... 1-3, 1-40
NEWOB.........................................................................3-155
NEXT.............................................................................3-156
NEXTPRIME ...............................................................3-156
NIP..................................................................................3-156
Nmines ..............................................................................D-6
NMOS transistors...........................................................5-53
nop.....................................................................................6-42
NOT................................................................................3-157
Not equal........................................................................3-296
NOVAL..........................................................................3-157
NPN bipolar transistors.................................................5-54
NSUB..............................................................................3-158
nullspace .........................................................................3-123
NUM...............................................................................3-158
number bases
converting between ....................................................2-22
numbers
action in programs ........................................................ 1-1
NUMX............................................................................3-159
NUMY............................................................................3-159
NΣ ...................................................................................3-157
P2C ................................................................................. 3-163
PA2B2 ............................................................................ 3-163
PAD.....................................................................................2-5
parallel addition................................................................. F-2
parallel processing ............................................................ F-1
DOLIST................................................................. F-1, F-4
multiple-result commands........................................... F-3
parallelepiped................................................................... 5-48
PARAMETRIC ............................................................ 3-163
PARITY......................................................................... 3-164
PARSURFACE............................................................. 3-164
PARTFRAC .................................................................. 3-165
PATH................................................................... 3-165, 6-17
PCAR.............................................................................. 3-166
PCOEF .......................................................................... 3-166
PCONTOUR................................................................ 3-166
PCOV............................................................................. 3-167
PDIM ............................................................................. 3-168
PEEK ..................................................................................6-6
PEEKARM ........................................................................6-6
pendulum ............................................................... 5-41, 5-42
Percent............................................................................ 3-292
PERINFO ..................................................................... 3-168
PERIOD......................................................................... D-14
periodic table................................................................. 3-168
properties................................................................... 3-183
PERM............................................................................. 3-168
permutation ............................................... 3-31, 3-36, 3-163
PERTBL ........................................................................ 3-168
PEVAL........................................................................... 3-169
PGDIR........................................................................... 3-169
phaes delay....................................................................... 5-14
PHONES......................................................................... 1-46
Pi (constant) .................................................................. 3-290
PICK............................................................................... 3-169
PICK3 ............................................................................ 3-169
PICT ............................................................................... 3-170
PICTURE...................................................................... 3-170
PIE.................................................................................... 2-34
pie charts.......................................................................... 2-34
PINIT............................................................................. 3-170
PIX?................................................................................ 3-170
PIXOFF......................................................................... 3-171
PIXON........................................................................... 3-171
PKT ................................................................................ 3-171
plane geometry................................................................ 5-43
PLOT ............................................................................. 3-172
PLOTADD ................................................................... 3-172
plotting
axes ............................................................................... 3-68
axis tick-mark .............................................................. 3-22
bar plots ....................................................................... 3-26
conic ............................................................................. 3-43
contour....................................................................... 3-166
ß
O
OBJ→.............................................................................3-159
object type numbers .......................................................1-13
objects
action in programs ........................................................ 1-1
entering in programs .................................................... 1-3
testing types .................................................................1-13
type numbers ...............................................................1-13
OCT ................................................................................3-160
OFF.................................................................................3-160
Ohm’s law ........................................................................5-10
OLDPRT........................................................................3-160
OPENIO........................................................................3-161
optics.................................................................................5-37
OR ...................................................................................3-161
ORDER..........................................................................3-162
oscillations........................................................................5-40
output
labeling............................................................................ 2-4
OVER.............................................................................3-162
Index - 10
ßENTER .................................................................2-37, D-3
S
SST ..................................................................................3-233
SST↓................................................................................3-233
stack
calculations on............................................................... 1-2
stack operations
depth .............................................................................3-55
drop...................................................................3-69, 3-304
drop n ...........................................................................3-70
drop two.......................................................................3-69
duplicate .......................................................................3-70
duplicate n....................................................................3-71
duplicate n, return n .................................................3-155
duplicate twice.............................................................3-71
duplicate two................................................................3-70
nip................................................................................3-156
over .............................................................................3-162
pick..............................................................................3-169
pick three....................................................................3-169
roll down ....................................................................3-206
roll up..........................................................................3-206
rotate ...........................................................................3-207
swap ............................................................................3-244
un-pick........................................................................3-264
un-rotate .....................................................................3-265
stack syntax
in local variable structures ........................................... 1-2
test commands ............................................................1-11
START............................................................................3-234
start looping ...................................................1-18, 1-19, 2-2
STARTED ........................................................................D-8
STARTEQW ....................................................................D-9
STARTERR......................................................................D-9
STARTOFF......................................................................D-9
STARTRECV...................................................................D-9
STARTSEND ..................................................................D-9
STARTUP.........................................................................D-9
state change............................................................5-26, 5-27
statistics
add to matrix..............................................................3-289
best fit .........................................................................3-132
frequency bins .............................................................3-29
linear fit.......................................................................3-133
purge matrix.................................................................3-38
remove from matrix .................................................3-290
standard deviation.....................................................3-181
sum..................................................... 3-275, 3-281, 3-282
STD.................................................................................3-234
STEP...............................................................................3-235
step junction...........................................................5-52, 5-54
STEQ ............................................................................. 3-235
STIME............................................................................ 3-235
STO ................................................................................ 3-236
STO-............................................................................... 3-239
STO* .............................................................................. 3-239
STO/ .............................................................................. 3-239
STO+ ............................................................................. 3-238
STOALARM................................................................. 3-236
STOF.............................................................................. 3-237
STOKEYS..................................................................... 3-237
Store................................................................................ 3-303
STORE........................................................................... 3-238
storing
programs .........................................................................1-3
STOVX .......................................................................... 3-238
STOΣ.............................................................................. 3-240
STR→............................................................................. 3-240
strain ................................................................................. 5-56
STREAM ....................................................................... 3-241
stress ..........................................................................5-3, 5-56
STRING .......................................................................... 6-21
string operations
concatenating ............................................................ 3-298
converting.................................................................. 3-240
first character ............................................................ 3-103
length.......................................................................... 3-226
parsing........................................................................ 3-240
position ...................................................................... 3-174
replace ........................................................................ 3-233
substring..................................................................... 3-242
tail................................................................................ 3-247
strings
action in programs.........................................................1-1
as program output ...................................................... 1-49
input converted to...................................................... 1-40
manipulating...................................................................2-5
STROBJ ........................................................................... 6-21
STURM .......................................................................... 3-241
STURMAB .................................................................... 3-242
STWS.............................................................................. 3-242
SUB................................................................................. 3-242
subroutines .............................................2-4, 2-8, 2-15, 2-26
debugging..................................................................... 1-32
in programs ................................................................. 1-29
operation...................................................................... 1-29
single-step execution.................................................. 1-31
SUBST............................................................................ 3-243
SUBTMOD ................................................................... 3-244
Subtract .......................................................................... 3-299
Summation..................................................................... 3-289
SVD ................................................................................ 3-244
SVL ................................................................................. 3-244
SWAP ............................................................................. 3-244
SYLVESTER ................................................................ 3-245
SYSEVAL...................................................................... 3-245
Index - 15
using arrays...................................................................2-12
using calculator clock ................................................... 2-4
using flags.....................................................................2-20
using other programs ....................... 2-4, 2-8, 2-15, 2-26
using statistics commands .........................................2-34
utility programs ...........................................................2-26
vectored enter..............................................................2-37
while loops ..................................................................... 2-5
programs
newlines in...................................................................... 1-3
programs
action for object types.................................................. 1-1
applying to elements of a matrix ..............................2-20
are sequence of objects ................................................ 1-1
beeping .........................................................................1-48
calculation styles............................................................ 1-2
causing errors...............................................................1-33
checksums ...................................................................... 2-1
comments in .................................................................. 1-7
conditional structures.......................................1-13, 1-35
creating on computer ................................................... 1-7
cursor position during input .....................................1-42
debugging .....................................................................1-31
default input.................................................................1-40
displaying input forms ................................................1-45
displaying menus.................1-48, 1-52, 2-17, 2-18, 2-34
displaying output.....................................1-49, 1-50, 1-51
displaying string output..............................................1-50
editing ............................................................................. 1-6
elapsed time ................................................................... 2-4
entering........................................................................... 1-3
entry modes ................................................................... 1-6
entry modes during input ..........................................1-42
error actions.................................................................1-33
executing......................................................................... 1-3
finding roots in............................................................2-38
flags in...........................................................................1-27
getting input.........................1-37, 1-39, 1-40, 1-48, 1-49
HALT annunciator .....................................................1-31
halting ...........................................................................1-32
in local variable structure..................................... 1-2, 1-7
input as strings.............................................................1-40
introduction ................................................................... 1-1
killing...................................................................1-31, 1-32
labeling output.............................................................1-50
local variable structures................................................ 1-7
loop structures.............................................................1-17
naming ............................................................................ 1-3
not evaluating local variables ...................................... 1-9
objects in ........................................................................ 1-1
on the stack.................................................................... 1-2
pausing for output ......................................................1-51
prompting.......................................1-37, 1-38, 1-39, 1-40
resuming.....................1-31, 1-32, 1-37, 1-39, 1-53, 1-55
scope of local variables in............................................ 1-9
Index - 12
single-step execution........................................ 1-31, 1-32
size ...................................................................................2-1
stopping ..........................................................................1-4
storing..............................................................................1-3
structures in....................................................................1-2
subroutines .................................................................. 1-29
test commands............................................................ 1-11
trapping errors .................................................. 1-35, 1-36
turning off calculator ................................................. 1-55
user-defined functions............................................... 1-10
using as arguments ................................... 2-8, 2-14, 2-38
using as subroutines ..........................2-4, 2-8, 2-15, 2-26
utility............................................................................. 2-26
verifying ..........................................................................2-1
verifying input................................................... 1-42, 2-24
viewing ............................................................................1-6
waiting for keystrokes................................................ 1-48
projectile motion............................................................. 5-35
PROMPT....................................................................... 3-179
prompting .................................................... 1-37, 1-39, 1-40
PROMPTSTO .............................................................. 3-179
PROOT.......................................................................... 3-179
PROPFRAC.................................................................. 3-180
PRST............................................................................... 3-180
PRSTC............................................................................ 3-181
PRTPAR ........................................................................... D-8
PRVAR........................................................................... 3-181
PSDEV........................................................................... 3-181
pseudoprime.................................................................. 3-122
Psi.................................................................................... 3-182
PSI................................................................................... 3-182
PTAYL........................................................................... 3-182
PTPAR .............................................................................. D-8
PTPROP ........................................................................ 3-183
PURGE.......................................................................... 3-183
PUSH.............................................................................. 3-184
PUT ................................................................................ 3-184
PUTI............................................................................... 3-185
PVAR ............................................................................. 3-185
PVARS ........................................................................... 3-186
PVIEW........................................................................... 3-186
PWRFIT......................................................................... 3-187
PX→C............................................................................ 3-187
Q
QR................................................................................... 3-188
qr ... ................................................................................. 3-188
QUAD............................................................................ 3-189
QUOT............................................................................ 3-189
QUOTE......................................................................... 3-189
QXA ............................................................................... 3-190
R
R~SB ...................................................................................6-7
R→B............................................................................... 3-214
R→C ...............................................................................3-215
R→D...............................................................................3-215
R→I ................................................................................3-215
RAD ................................................................................3-190
RAND ............................................................................3-190
random number.............................................................3-190
range................................................................................3-115
RANK.............................................................................3-191
RANM ............................................................................3-191
RATIO............................................................................3-191
RCEQ .............................................................................3-192
RCI ..................................................................................3-192
RCIJ.................................................................................3-192
RCL .................................................................................3-193
RCLALARM..................................................................3-193
RCLF...............................................................................3-194
RCLKEYS......................................................................3-194
RCLMENU....................................................................3-194
RCLVX...........................................................................3-195
RCLΣ ..............................................................................3-195
RCWS .............................................................................3-195
RDM ...............................................................................3-195
RDZ ................................................................................3-196
RE....................................................................................3-196
reactance...........................................................................5-14
real gases...........................................................................5-25
real numbers
manipulating ................................................................2-22
REALASSUME .............................................................D-14
recalling
flag states......................................................................1-28
menu numbers.............................................................1-52
RECN .............................................................................3-197
RECT..............................................................................3-197
rectangle............................................................................5-45
recursion................................................................... 2-2, 2-28
RECV..............................................................................3-197
REF .................................................................................3-198
reflection...........................................................................5-39
refraction ..........................................................................5-37
REMAINDER ..............................................................3-198
RENAME ......................................................................3-198
REORDER....................................................................3-199
REPEAT ........................................................................3-199
REPL ..............................................................................3-199
RES .................................................................................3-200
resistance
wire................................................................................5-11
resonant frequency..........................................................5-16
RESTORE .....................................................................3-201
RESULTANT ...............................................................3-201
REVLIST .......................................................................3-202
REWRITE .....................................................................3-202
ring.....................................................................................5-46
RISCH ............................................................................3-202
RKF ................................................................................ 3-203
RKFERR ....................................................................... 3-203
RKFSTEP...................................................................... 3-204
RL.................................................................................... 3-204
RLB................................................................................. 3-205
RND ............................................................................... 3-205
RNRM............................................................................ 3-206
ROLL ............................................................................. 3-206
ROLLD.......................................................................... 3-206
ROM version................................................................. 3-270
ROMUPLOAD ............................................................ 3-206
ROOT ............................................................................ 3-207
root-finder
in programs ................................................................. 2-38
ROOTR ........................................................................... 2-38
roots
in programs ................................................................. 2-38
ROT................................................................................ 3-207
rounding......................................................................... 3-205
ROW- ............................................................................. 3-207
ROW+ ........................................................................... 3-208
ROW→.......................................................................... 3-208
RPL mode........................................................................ 6-35
RPL>.............................................................................. 3-209
RPN syntax
converting to ............................................................... 2-27
RR ................................................................................... 3-209
RRB ................................................................................ 3-209
rref................................................................................... 3-210
RREF.............................................................................. 3-210
RREFMOD................................................................... 3-211
RRK................................................................................ 3-211
RRKSTEP ..................................................................... 3-212
RSBERR ........................................................................ 3-213
RSD ................................................................................ 3-213
RSWP ............................................................................. 3-214
RULES ........................................................................... 3-214
RUN menu ...................................................................... 1-33
S
S~N .....................................................................................6-8
S→H....................................................................................6-8
SAME............................................................................. 3-215
Saturn instruction set ..................................................... 6-23
SB~B ...................................................................................6-7
SBRK.............................................................................. 3-216
SCALE ........................................................................... 3-216
SCALEH........................................................................ 3-216
SCALEW ....................................................................... 3-216
SCATRPLOT................................................................ 3-217
SCATTER ..................................................................... 3-217
SCHUR .......................................................................... 3-218
SCI .................................................................................. 3-218
SCLΣ .............................................................................. 3-218
SCONJ ........................................................................... 3-219
Index - 13
Was this manual useful for you? yes no
Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Download PDF

advertisement