BBS: Inland Empire Archive Date: 04-30-92 (21:21) Number: 194 From: PAUL LEONARD Refer#: 147 To: MARGARET ROMAO Recvd: NO Subj: Matrix Conf: (2) Quik_Bas

On or about <Apr 29 11:26>, Margaret Romao (1:3603/150) scribbled: MR> What did the MAT function do? The following is from the Basic-Plus2 help listings... BP2 MAT_INPUT MATINPUTarray(s) 50 MATINPUTA The MATINPUTstatement assigns data you input to the elements of a specified array. Elements are stored in row order as they are typed. MATINPUT# MATINPUT#num-exp%, array name 100 MATINPUT#2%, ARN The MATINPUT# statement reads values from a terminal format file and assigns them to a specified array. The elements are stored in the destination array in row order. MAT_LINPUT MAT LINPUT string array name 300 MAT LINPUT VECTOR.NAME$ The MAT LINPUT statement assigns data you input to elements of a string array. MAT LINPUT # MAT LINPUT #num-exp% string array name 90 MAT LINPUT #1%,A$ The MAT LINPUT statement reads string data from a terminal format file and assigns it to elements of a string array. MAT LINPUT # does not include the string's line terminator as part of the array element. MAT_PRINT MATREADarray(s) 50 MATREADB,C The MATREADstatement reads data statement values into elements of a 1- or 2-dimensional array. MATRIX_ASSIGNMENT MAT array name = array name 15 MAT A = B In matrix assignment, the MAT statement sets each entry of Array A equal to the corresponding entry of Array B. A is redimensioned to the size of B. IDN Sets up an identity matrix: all elements are zero except for those on the (I,I) diagonal, which are set to one. INV Generates a matrix that is the inverse of another. For example, MAT N = INV(M) makes Matrix N the inverse of Matrix M. Matrix M must be a square matrix. ...All of these functions are just specialized array functions and can be implemented with FOR...NEXT loops. For example, the IDN(mat) can be coded with...DIMmat%(10,10)FORi%=1 to 10FORj%=1 to 10IFi%=j% then mat%(i%,j%)=1 else mat%(i%,j%)=0NEXTj%NEXTi% ptl --- msged 2.07 * Origin: PTL Pointwork (1:105/48.111)

Echo Basic Postings

**Books at Amazon:**

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET