Type:
Class
Constants:
SELECTORS : {all: true, diagonal: true, off_diagonal: true, lower: true, strict_lower: true, strict_upper: true, upper: true}.freeze

The Matrix class represents a mathematical matrix. It provides methods for creating matrices, operating on them arithmetically and algebraically, and determining their mathematical properties (trace, rank, inverse, determinant).

Method Catalogue

To create a matrix:

To access Matrix elements/columns/rows/submatrices/properties:

Properties of a matrix:

Matrix arithmetic:

Matrix functions:

Matrix decompositions:

Complex arithmetic:

  • conj

  • conjugate

  • imag

  • imaginary

  • real

  • rect

  • rectangular

Conversion to other data types:

String representations:

column_vector

column_vector(column) Class Public methods Creates a single-column matrix where

2015-04-18 05:08:11
to_a

to_a() Instance Public methods Returns an array of arrays that describe the

2015-04-18 10:27:55
real?

real?() Instance Public methods Returns true if all entries of

2015-04-18 09:30:22
rank_e

rank_e() Instance Public methods deprecated; use

2015-04-18 09:18:33
elements_to_r

elements_to_r() Instance Public methods

2015-04-18 07:38:17
row

row(i) Instance Public methods Returns row vector number i of the

2015-04-18 09:50:31
hash

hash() Instance Public methods Returns a hash-code for the matrix.

2015-04-18 08:00:55
**

**(other) Instance Public methods

2015-04-18 05:56:48
diagonal

diagonal(*values) Class Public methods Creates a matrix where the diagonal elements

2015-04-18 05:20:56
rectangular

rectangular() Instance Public methods Alias for:

2015-04-18 09:40:14