176 Section 12: Calculating with Matrices

Using Matrix Operations in a Program

If the calculator is in User mode during program entry when you enter a O or l{A through E, %} instruction to store or recall a matrix element, a u replaces the dash usually displayed after the line number. When this line is executed in a running program, it operates as though the calculator were in User mode. That is, the row and column numbers in R0 and R1 are automatically incremented according to the dimensions of the specified matrix. This allows you to access elements sequentially. (The USER annunciator has no effect during program execution.)

In addition, when the last element is accessed by the ―User‖ Oor l instruction – when R0 and R1 are returned to 1 – program execution skips the next line. This is useful for programming a loop that stores or recalls each matrix element, then continues executing the program. For example, the following sequence squares all elements of matrix D: