UNPKG

@odoo/o-spreadsheet

Version:
25 lines (24 loc) 980 B
import { Matrix } from "../types/misc"; export declare function getUnitMatrix(n: number): Matrix<number>; /** * Invert a matrix and compute its determinant using Gaussian Elimination. * * The Matrix should be a square matrix, and should be indexed [col][row] instead of the * standard mathematical indexing [row][col]. */ export declare function invertMatrix(M: Matrix<number>): { inverted?: Matrix<number>; determinant: number; }; /** * Matrix multiplication of 2 matrices. * ex: matrix1 : n x l, matrix2 : m x n => result : m x l * * Note: we use indexing [col][row] instead of the standard mathematical notation [row][col] */ export declare function multiplyMatrices(matrix1: Matrix<number>, matrix2: Matrix<number>): Matrix<number>; /** * Return the input if it's a scalar or the first element of the input if it's a matrix. */ export declare function toScalar<T>(arg: Matrix<T> | T): T; export declare function isMultipleElementMatrix(arg: any): boolean;