background image

HP-15C

Matrix Operations

Memory

A total of 64 matrix elements can be used in a total of 5 matrices 
named A-E. Different matrices can have different size; sometimes 
the result of a matrix operation can overwrite the input matrix.
The registers for the matrix elements are allocated from the 
uncommitted registers space, see MEM.
See further down for 

complex matrices

.

MATRIX 0

Redimensions all matrices to 0x0 thus freeing up all memory 
occupied by matrices

Matrix descriptors

The stack registers, Last-X and index register I as well as ordinary 
storage registers can contain "

matrix descriptors

" which refer to one 

of the matrices A-E. Ie. if there are two matrix descriptors in X and 
Y then pressing "+" will add them and put the result in the 

result 

matrix.

 Matrix descriptors can be moved around in the stack and 

to/from storage registers like ordinary numbers

DIM A-E

Dimensions one of the matrices A-E. It will have as many rows as 
specified in Y and as many columns as specified in X.
Whan an existing matrix is redimensioned values are lost or zeros 
inserted. Refer to pg. 142 of the Owner's Handbook

DIM (i)

If I contains a matrix descriptor then the DIM operation will be 
performed on the matrix specified in I. 
This indirect method applies to other matrix operations, see below.

RCL DIM A-E, (i)

Places the matrix' dimensions in X and Y. A non-exisiting matrix has 
dimensions 0x0

RCL MATRIX A-E

Put a matrix descriptor in the X register. This displays the matrix' 
name and its dimensions

STO 0-9, .0-.9, I
RCL 0-9, .0-.9, I

Matrix descriptors can be stored in and recalled from ordinary 
storage registers

MATRIX 1

Stores 1 in R0 and R1 which are used to index matrix elements. 
Useful in preparation of matrix element input

STO A-E, (i)
RCL A-E, (i)

Store X in the matrix element of matrix A-E which is addressed by 
registers R0 and R1. R0 is the row and R1 the column number, 
starting from 1. RCL recalls the matrix element. 
While the A-E key is held down, the matrix name, row and column 
are displayed. R1 & R0 are automatically incremented in USER 
mode, see below

USER

When user mode is active, a STO A-E, (i) or RCL A-E, (i) operation 
will automatically increment the column index in R1 until it wraps 
back to 1 in which case the row index R0 is increment until it wraps 
back to 1 as well.
So in user mode 

all

 matrix elements can quickly be entered and 

recalled

STO +–x

÷

 A-E, (i)

RCL +–x

÷

 A-E, (i)

Matrix element arithmentic. Does not increment R1/R0 in USER 
mode

7

Summary of Contents for 15C

Page 1: ...umber of uncommitted registers Use DIM to commit them to storage registers Uncommitted registers are automatically converted to program space when needed pp Number of registers containing program instructions One register consists of 7 bytes and can hold 7 program steps except for a few instructions that occupy two bytes n Number of bytes left before next uncommitted register is converted to progr...

Page 2: ...L 0 9 0 9 Recall number from storage register to X register RCL 0 9 0 9 RCL 0 9 0 9 RCL x 0 9 0 9 RCL 0 9 0 9 Register recall arithmetic X OP Register X X 0 9 0 9 Exchange X with one of the storage registers STO I Store X in index register STO x I Register store arithmetic with index reister RCL I Recall value from index register RCL x I Register recall arithmetic with index reister X I Exchange X...

Page 3: ...of X INT Returns the integer part of X yx Y to the power of X Works also for negative Y in case X is integer Calculates X percent of Y Does not pop the stack Percential difference from Y to X Does not pop the stack Trigonometric Functions DEG Set trig mode degrees 360 RAD Set trig mode radians 2π indicated in display GRD Set trig mode grad 400 indicated in display SIN COS TAN Trigonometric functio...

Page 4: ...previous program step but do not execute any program code PRGM Step backwards thru program scolls when held down Inserting steps Program entry starts with line number 1 Line 000 indicates the start of the program space Commands are inserted after the currently displayed line Program code values indicate the row column of a command with the exception that numbers are displayed as such Prefix keys h...

Page 5: ...0 X 0 1 X 0 2 X 0 3 X 0 4 X 0 5 X Y 6 X Y 7 X Y 8 X Y 9 X Y If camparisn is false Skip the next program step If camparisn is true Execute the next program step ISG 0 9 0 9 I Increment and skip if greater This loop command uses the specified register which must contain a value in the form nnnnn xxxyy where nnnnn Current initial loop counter value xxx Comparisn value for loop counter yy Loop counter...

Page 6: ...al part of the number Store STO 1 Re Im STO 2 Re Im Recall RCL 2 RCL 1 f I or RCL 2 Re Im RCL 1 this does not disturb the stack x y Replace both real and imaginary part of X and Y register R R Shift both the real and imaginary part Sqrt x Ln Log 1 x ex hyp sin cos tan hyp 1 sin cos tan All these unary functions work in complex mode as well NOTE To calculate sqrt 1 the complex mode must be already ...

Page 7: ...contains a matrix descriptor then the DIM operation will be performed on the matrix specified in I This indirect method applies to other matrix operations see below RCL DIM A E i Places the matrix dimensions in X and Y A non exisiting matrix has dimensions 0x0 RCL MATRIX A E Put a matrix descriptor in the X register This displays the matrix name and its dimensions STO 0 9 0 9 I RCL 0 9 0 9 I Matri...

Page 8: ...A This is the matrix that will hold the result of a matrix operation Not all operations require a result matrix The result matrix will automatically be dimensioned so that it can properly hold the result For some matrix operations the result matrix can be identical to one of the input matrices STO RESULT When a matrix descriptor is already present in X then this matrix will be used as the result m...

Page 9: ...he Y X order X must be square and have dimensions compatible with Y MATRIX 5 Calculate YT X RESULT where RESULT may neither be X nor Y X Y must have compatible dimension MATRIX 6 Calulatest the residual RESULT Y X RESULT The descriptor of RESULT is placed in X RESULT may neither be X nor Y X Y must have compatible dimension Matrix in LU form Its descriptor is displayed with two dashes after the ma...

Page 10: ...xecuted If X is a scalar it remains unchanged and the next program line is skipped This can be used to test whether X contains a matrix or a scalar Root Finding Solver Memory The solver needs 5 registers These are allocated from the uncommitted registers space see MEM The solver and the numerical integrator see below share their registers SOLVE 0 9 0 9 A E Finds real root of a function This is a v...

Page 11: ...program at the label must calculate the function f X and return the result in X before it executes the RTN When x y ends the stack wil contain these values X The integral of f x Y The uncertainty of the result x y f x X Y Z Upper integration limit T Lower integration limit Note that x y eats up two of the seven possible GSB levels One for x y and one for the calls to the user function The program ...

Reviews: