package owl-base

  1. Overview
  2. Docs
On This Page
  1. Type definition
Legend:
Library
Module
Module type
Parameter
Class
Class type

Matrix module: including creation, manipulation, and various vectorised mathematical operations.

About the comparison of two complex numbers ``x`` and ``y``, Owl uses the following conventions: 1) ``x`` and ``y`` are equal iff both real and imaginary parts are equal; 2) ``x`` is less than ``y`` if the magnitude of ``x`` is less than the magnitude of ``x``; in case both ``x`` and ``y`` have the same magnitudes, ``x`` is less than ``x`` if the phase of ``x`` is less than the phase of ``y``; 3) less or equal, greater, greater or equal relation can be further defined atop of the aforementioned conventions.

Type definition
type ('a, 'b) t = ('a, 'b, Stdlib.Bigarray.c_layout) Stdlib.Bigarray.Genarray.t

N-dimensional array type, i.e. Bigarray Genarray type.

val eye : ('a, 'b) Stdlib.Bigarray.kind -> int -> ('a, 'b) t

``eye m`` creates an ``m`` by ``m`` identity matrix.

val diagm : ?k:int -> ('a, 'b) t -> ('a, 'b) t

Refer to :doc:`owl_dense_matrix_generic`

val tril : ?k:int -> ('a, 'b) t -> ('a, 'b) t

Refer to :doc:`owl_dense_matrix_generic`

val triu : ?k:int -> ('a, 'b) t -> ('a, 'b) t

Refer to :doc:`owl_dense_matrix_generic`

OCaml

Innovation. Community. Security.