linalg(deprecated)/randmatrix - Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : linalg(deprecated)/randmatrix

linalg(deprecated)

  

randmatrix

  

random matrix generator

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

randmatrix(m, n, options)

Parameters

m, n

-

positive integers

options

-

(optional) names or equations

Description

• 

Important: The linalg package has been deprecated. Use the superseding command LinearAlgebra[RandomMatrix], instead.

  

- For information on migrating linalg code to the new packages, see examples/LinearAlgebraMigration.

• 

The randmatrix function generates a random matrix of dimension m by n.  It is intended to be used for generating examples for debugging, testing, and demonstration purposes.  Several options are available.  The options determine the form of the matrix and the entries in the matrix.

• 

The first two arguments specify the row dimension and column dimension. The remaining arguments are interpreted as options and are input as equations or names in any order. The names sparse, dense (default), symmetric, antisymmetric, and unimodular specify the structure of the matrix.  The equation entries = f specifies that the nullary function f is to be used to generate the matrix entries.  The default is rand(-99..99).  Thus the matrix entries are random two digit integers.

• 

The command with(linalg,randmatrix) allows the use of the abbreviated form of this command.

Examples

Important: The linalg package has been deprecated. Use the superseding command LinearAlgebra[RandomMatrix], instead.

withlinalg:

randmatrix3,3

7225594875606297

(1)

randmatrix3,3,unimodular

17340183001

(2)

poly := proc() Randpoly(3, x) mod 3 end proc;

polyprocRandpoly3,xmod3end proc

(3)

randmatrix2,2,entries=poly

x3+x2+2x+12x3+2x2+12x3+x+12x3+x2+x

(4)

See Also

linalg(deprecated)[matrix]

LinearAlgebra

LinearAlgebra[RandomMatrix]

Matrix