Common Lisp Package: CL-NUM-UTILS.MATRIX

README:

FUNCTION

Public

DIAGONAL-MATRIX-ELEMENTS (INSTANCE)

@arg[extid]{A @class{extid}} @return[sytemid]{puri:uri or nil} Returns the System ID part of this External ID.

HERMITIAN-MATRIX (ELEMENTS)

Create a lower-triangular-matrix.

LOWER-TRIANGULAR-MATRIX (ELEMENTS)

Create a lower-triangular-matrix.

UPPER-TRIANGULAR-MATRIX (ELEMENTS)

Create a lower-triangular-matrix.

WRAPPED-MATRIX-ELEMENTS (INSTANCE)

@arg[extid]{A @class{extid}} @return[sytemid]{puri:uri or nil} Returns the System ID part of this External ID.

Undocumented

DIAGONAL-MATRIX (ELEMENTS)

SETFDIAGONAL-MATRIX-ELEMENTS (NEW-VALUE INSTANCE)

Private

ABOVE-DIAGONAL? (ROW COL)

Test if element with indexes row and col is (strictly) above the diagonal.

BELOW-DIAGONAL? (ROW COL)

Test if element with indexes row and col is (strictly) below the diagonal.

ENSURE-VALID-ELEMENTS (ARRAY RANK &REST PREDICATES)

Convert OBJECT to an array, check that it 1. has the required rank, 2. has a valid sparse element type, and 3. that it satisfies PREDICATES. Return the array.

HERMITIAN-MATRIX-ELEMENTS (INSTANCE)

@arg[extid]{A @class{extid}} @return[sytemid]{puri:uri or nil} Returns the System ID part of this External ID.

LOWER-TRIANGULAR-MATRIX-ELEMENTS (INSTANCE)

@arg[extid]{A @class{extid}} @return[sytemid]{puri:uri or nil} Returns the System ID part of this External ID.

UPPER-TRIANGULAR-MATRIX-ELEMENTS (INSTANCE)

@arg[extid]{A @class{extid}} @return[sytemid]{puri:uri or nil} Returns the System ID part of this External ID.

VALID-SPARSE-TYPE? (TYPE)

Check if TYPE is a valid type for sparse matrices. Only supertypes and subtypes of NUMBER are allowed.

ZERO-LIKE (ARRAY)

Return 0 coerced to the element type of ARRAY. It is assumed that the latter satisfies VALID-SPARSE-TYPE?.

Undocumented

COPY-DIAGONAL-MATRIX (INSTANCE)

COPY-HERMITIAN-MATRIX (INSTANCE)

COPY-LOWER-TRIANGULAR-MATRIX (INSTANCE)

COPY-UPPER-TRIANGULAR-MATRIX (INSTANCE)

COPY-WRAPPED-MATRIX (INSTANCE)

DIAGONAL-MATRIX-P (OBJECT)

HERMITIAN-MATRIX-P (OBJECT)

LOWER-TRIANGULAR-MATRIX-P (OBJECT)

MAKE-DIAGONAL-MATRIX (&KEY ((ELEMENTS DUM229) NIL))

MAKE-HERMITIAN-MATRIX (&KEY ((ELEMENTS DUM714) NIL))

MAKE-LOWER-TRIANGULAR-MATRIX (&KEY ((ELEMENTS DUM496) NIL))

MAKE-UPPER-TRIANGULAR-MATRIX (&KEY ((ELEMENTS DUM612) NIL))

MAKE-WRAPPED-MATRIX (&KEY ((ELEMENTS DUM419) NIL))

UPPER-TRIANGULAR-MATRIX-P (OBJECT)

WRAPPED-MATRIX-P (OBJECT)

MACRO

Private

&DIAGONAL-MATRIX (&WHOLE WHOLE272 ELEMENTS)

LET+ form for slots of the structure DIAGONAL-MATRIX.

&DIAGONAL-MATRIX-R/O (&WHOLE WHOLE312 ELEMENTS)

LET+ form for slots of the structure DIAGONAL-MATRIX. Read-only.

DEFINE-ELEMENTWISE-AS-ARRAY (TYPE &KEY (FUNCTIONS '(E2+ E2- E2*)))

Define binary elementwise operations for FUNCTION, implemented by converting them to arrays.

DEFINE-ELEMENTWISE-SAME-CLASS (TYPE &KEY (FUNCTIONS '(E2+ E2- E2*)) (ELEMENTS-ACCESSOR (SYMBOLICATE TYPE '-ELEMENTS)))

Define binary elementwise operations for FUNCTION for two arguments of the same class.

DEFINE-ELEMENTWISE-UNIVARIATE (TYPE &KEY (FUNCTIONS '(E1- E1/ EEXP E1LOG ESQRT)) (ELEMENTS-ACCESSOR (SYMBOLICATE TYPE '-ELEMENTS)))

Define unary elementwise operations for FUNCTION for all subclasses of wrapped-elements.

DEFINE-ELEMENTWISE-WITH-CONSTANT (TYPE &KEY (FUNCTIONS '(E2* E2/)) (ELEMENTS-ACCESSOR (SYMBOLICATE TYPE '-ELEMENTS)))

Define binary elementwise operations for FUNCTION for all subclasses of wrapped-elements.

Undocumented

DEFINE-WRAPPED-MATRIX (TYPE ELEMENTS STRUCT-DOCSTRING (MASKED-TEST MASKED-STRING) CHECK-AND-CONVERT-ELEMENTS REGULARIZE-ELEMENTS)

GENERIC-FUNCTION

Public

DIAGONAL-VECTOR (MATRIX)

Return the diagonal elements of MATRIX as a vector.

SETFDIAGONAL-VECTOR (VECTOR MATRIX)

Set the diagonal elements of MATRIX using VECTOR.

TRANSPOSE (ARRAY)

Transpose.

Private

Undocumented

E1LOG (A)

CLASS

Public

DIAGONAL-MATRIX (ELEMENTS)

Diagonal matrix. The elements in the diagonal are stored in a vector.

HERMITIAN-MATRIX (ELEMENTS)

Hermitian/symmetric matrix, with elements stored in the _lower_ triangle. Implements _both_ real symmetric and complex Hermitian matrices --- as technically, real symmetric matrices are also Hermitian. Complex symmetric matrices are _not_ implemented as a special matrix type, as they don't have any special properties (eg real eigenvalues, etc).

LOWER-TRIANGULAR-MATRIX (ELEMENTS)

Lower triangular matrix. ELEMENTS in the upper triangle are treated as zero.

UPPER-TRIANGULAR-MATRIX (ELEMENTS)

Upper triangular matrix. ELEMENTS in the lower triangle are treated as zero.

WRAPPED-MATRIX

A matrix that has some special structure (eg triangular, symmetric/hermitian). ELEMENTS is always a matrix. Not used directly, not exported.