<random-unit-matrix> ( m n max -- matrix )
Extra matrix operations

Prev:<random-integer-matrix> ( m n max -- matrix )
Next:invertible-matrix? ( matrix -- ? )


Vocabulary
math.matrices.extras

Inputs
man integer
nan integer
maxa number


Outputs
matrixa matrix


Word description
Creates a m x n matrix full of random, possibly signed floats as a fraction of max.

Notes
The signedness of the numbers in the resulting matrix will be randomized. Use mabs with this word to generate a matrix of random positive numbers.
This word is the real variant of <random-integer-matrix>.
This word is implemented by generating sub-integral floats through random-units and multiplying by random integers less than or equal to max.


Examples
USING: math.matrices.extras prettyprint ; 4 2 15 <random-unit-matrix> .
{ { -3.713295909201797 3.815787135075961 } { -2.460506890603817 1.535222788710546 } { 3.692213981267878 -1.462963244399762 } { 13.8967592095433 -6.688509969360172 } }


Definition