Linear algebra runtime

Matrices that flow through JavaScript.

Build, transform, and factorize dense matrices in Node.js and the browser. Typed, dependency-light, and ready for SVD, EVD, LU, QR, Cholesky, and least squares.

npm install matrixflow-js

Native linear algebra, one import.

A dense-matrix core with views, structured types, and production decompositions.

Dense Matrix

Create, slice, and combine matrices. Element-wise math, products, norms, and in-place operators.

Zero-copy views

Transpose, submatrix, row/column, and flip views wrap existing data instead of allocating copies.

Decompositions

SVD, EVD, LU, QR, Cholesky, and NIPALS, plus inverse, pseudo-inverse, and least-squares solvers.

Structured types

SymmetricMatrix and DistanceMatrix keep packed storage while exposing the same Matrix API.

Statistics

Mean, variance, covariance, correlation, centering, and scaling along rows or columns.

Everywhere JS runs

ESM, CommonJS, TypeScript types, and a minified UMD build for CDN and browser use.

Playground

Run real matrixflow-js code in the browser. The snippet must return a value.

Output
Loading library…

API surface

Import what you need from matrixflow-js. Full signatures live in matrix.d.ts and the README.

Core

Matrix, AbstractMatrix, SymmetricMatrix, DistanceMatrix, wrap

Solvers

inverse, pseudoInverse, solve, determinant, linearDependencies

Factorizations

SVD, EVD, LU, QR, CHO, NIPALS

Stats

covariance, correlation, plus mean, variance, center, and scale on Matrix