Function: math[mat] - simple definition of a matrix (the MATLAB way)
Calling Sequence:
mat(str);
Parameters:
str - a string
Description:
This function provides an easy way to define a (m,n)-matrix without having to use multiple lists and commas to separate rows and components of the matrix, resp.
Each component must be seperated by one or more blanks, each row by one of the following characters: ; or , or # or | (pipe).
The return of this function is an array.
A note to users of Release 5: math/mat accepts strings `put into` either double or backquotes.
This function is part of the math package, and so can be used only after performing the command with(math) or with(math, mat).
Examples:
> with(math, mat):
> A := mat(`1 2 3 4;5 6 7 8 ; 9.5 10 11 12 |13 14 15 16`);
> B := mat(`1 2 3 4`);
See Also:
linalg/matrix , array .
Version History:
Version 1.0.0 - September 27, 1997
Version 1.0.1 - January 01, 1999