package owl

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Owl_sparse_matrix_zSource

Sourcetype elt = Complex.t
Create sparse matrices
Sourceval zeros : int -> int -> mat
Sourceval ones : int -> int -> mat
Sourceval eye : int -> mat
Sourceval binary : int -> int -> mat
Sourceval uniform : ?scale:float -> int -> int -> mat
Sourceval uniform_int : ?a:int -> ?b:int -> int -> int -> mat
Sourceval sequential : int -> int -> mat
Obtain the basic properties of a matrix
Sourceval shape : mat -> int * int
Sourceval row_num : mat -> int
Sourceval col_num : mat -> int
Sourceval row_num_nz : mat -> int
Sourceval col_num_nz : mat -> int
Sourceval numel : mat -> int
Sourceval nnz : mat -> int
Sourceval nnz_rows : mat -> int array
Sourceval nnz_cols : mat -> int array
Sourceval density : mat -> float
Manipulate a matrix
Sourceval insert : mat -> int -> int -> elt -> unit
Sourceval set : mat -> int -> int -> elt -> unit
Sourceval get : mat -> int -> int -> elt
Sourceval reset : mat -> unit
Sourceval fill : mat -> elt -> unit
Sourceval copy : mat -> mat
Sourceval transpose : mat -> mat
Sourceval diag : mat -> mat
Sourceval row : mat -> int -> mat
Sourceval col : mat -> int -> mat
Sourceval rows : mat -> int array -> mat
Sourceval cols : mat -> int array -> mat
Sourceval prune : mat -> elt -> float -> unit
Iterate elements, columns, and rows
Sourceval iteri : (int -> int -> elt -> unit) -> mat -> unit
Sourceval iter : (elt -> unit) -> mat -> unit
Sourceval mapi : (int -> int -> elt -> elt) -> mat -> mat
Sourceval map : (elt -> elt) -> mat -> mat
Sourceval foldi : (int -> int -> 'a -> elt -> 'a) -> 'a -> mat -> 'a
Sourceval fold : ('a -> elt -> 'a) -> 'a -> mat -> 'a
Sourceval filteri : (int -> int -> elt -> bool) -> mat -> (int * int) array
Sourceval filter : (elt -> bool) -> mat -> (int * int) array
Sourceval iteri_rows : (int -> mat -> unit) -> mat -> unit
Sourceval iter_rows : (mat -> unit) -> mat -> unit
Sourceval iteri_cols : (int -> mat -> unit) -> mat -> unit
Sourceval iter_cols : (mat -> unit) -> mat -> unit
Sourceval mapi_rows : (int -> mat -> 'a) -> mat -> 'a array
Sourceval map_rows : (mat -> 'a) -> mat -> 'a array
Sourceval mapi_cols : (int -> mat -> 'a) -> mat -> 'a array
Sourceval map_cols : (mat -> 'a) -> mat -> 'a array
Sourceval fold_rows : ('a -> mat -> 'a) -> 'a -> mat -> 'a
Sourceval fold_cols : ('a -> mat -> 'a) -> 'a -> mat -> 'a
Sourceval iteri_nz : (int -> int -> elt -> unit) -> mat -> unit
Sourceval iter_nz : (elt -> unit) -> mat -> unit
Sourceval mapi_nz : (int -> int -> elt -> elt) -> mat -> mat
Sourceval map_nz : (elt -> elt) -> mat -> mat
Sourceval foldi_nz : (int -> int -> 'a -> elt -> 'a) -> 'a -> mat -> 'a
Sourceval fold_nz : ('a -> elt -> 'a) -> 'a -> mat -> 'a
Sourceval filteri_nz : (int -> int -> elt -> bool) -> mat -> (int * int) array
Sourceval filter_nz : (elt -> bool) -> mat -> (int * int) array
Sourceval iteri_rows_nz : (int -> mat -> unit) -> mat -> unit
Sourceval iter_rows_nz : (mat -> unit) -> mat -> unit
Sourceval iteri_cols_nz : (int -> mat -> unit) -> mat -> unit
Sourceval iter_cols_nz : (mat -> unit) -> mat -> unit
Sourceval mapi_rows_nz : (int -> mat -> 'a) -> mat -> 'a array
Sourceval map_rows_nz : (mat -> 'a) -> mat -> 'a array
Sourceval mapi_cols_nz : (int -> mat -> 'a) -> mat -> 'a array
Sourceval map_cols_nz : (mat -> 'a) -> mat -> 'a array
Sourceval fold_rows_nz : ('a -> mat -> 'a) -> 'a -> mat -> 'a
Sourceval fold_cols_nz : ('a -> mat -> 'a) -> 'a -> mat -> 'a
Examine elements and compare two matrices
Sourceval exists : (elt -> bool) -> mat -> bool
Sourceval not_exists : (elt -> bool) -> mat -> bool
Sourceval for_all : (elt -> bool) -> mat -> bool
Sourceval exists_nz : (elt -> bool) -> mat -> bool
Sourceval not_exists_nz : (elt -> bool) -> mat -> bool
Sourceval for_all_nz : (elt -> bool) -> mat -> bool
Sourceval is_zero : mat -> bool
Sourceval is_positive : mat -> bool
Sourceval is_negative : mat -> bool
Sourceval is_nonnegative : mat -> bool
Sourceval equal : mat -> mat -> bool
Sourceval not_equal : mat -> mat -> bool
Sourceval greater : mat -> mat -> bool
Sourceval less : mat -> mat -> bool
Sourceval greater_equal : mat -> mat -> bool
Sourceval less_equal : mat -> mat -> bool
Randomisation functions
Sourceval permutation_matrix : int -> mat
Sourceval draw_rows : ?replacement:bool -> mat -> int -> mat * int array
Sourceval draw_cols : ?replacement:bool -> mat -> int -> mat * int array
Sourceval shuffle_rows : mat -> mat
Sourceval shuffle_cols : mat -> mat
Sourceval shuffle : mat -> mat
Input/Output and helper functions
Sourceval to_array : mat -> (int array * elt) array
Sourceval of_array : int -> int -> (int array * elt) array -> mat
Sourceval print : mat -> unit
Sourceval save : mat -> string -> unit
Sourceval load : string -> mat
Unary mathematical operations
Sourceval trace : mat -> elt
Sourceval sum : mat -> elt
Sourceval mean : mat -> elt
Sourceval sum_rows : mat -> mat
Sourceval sum_cols : mat -> mat
Sourceval mean_rows : mat -> mat
Sourceval mean_cols : mat -> mat
Sourceval neg : mat -> mat
Binary mathematical operations
Sourceval add : mat -> mat -> mat
Sourceval sub : mat -> mat -> mat
Sourceval mul : mat -> mat -> mat
Sourceval div : mat -> mat -> mat
Sourceval dot : mat -> mat -> mat
Sourceval add_scalar : mat -> elt -> mat
Sourceval sub_scalar : mat -> elt -> mat
Sourceval mul_scalar : mat -> elt -> mat
Sourceval div_scalar : mat -> elt -> mat
Sourceval scalar_add : elt -> mat -> mat
Sourceval scalar_sub : elt -> mat -> mat
Sourceval scalar_mul : elt -> mat -> mat
Sourceval scalar_div : elt -> mat -> mat
Sourceval power_scalar : mat -> elt -> mat
Sourceval mpow : mat -> float -> mat
OCaml

Innovation. Community. Security.