Forked from mateogianolio/vectorious, added sparse matrix/vector support (by using SPBLAS, nodejs only) and boost of AX=B solve (by using LAPACK).
todo: documment new featues
Also see nblas-plus
First please read and apply Preinstall section of nblas-plus
Windows is not tested.
$ npm install vectorious-plus
var v = require('vectorious'), Matrix = v.Matrix, Vector = v.Vector, SpVector = v.SpVector, SpMatrix = v.Matrix, BLAS = v.BLAS; // access BLAS routines (and also SPBLAS, LAPACK)
Download a release and use it like this:
<script> var A = new Matrix([, , ]), B = new Matrix([[1, 3, 5]]), C = A.multiply(B); console.log('C:', C.toArray()); /* C: [ [1, 3, 5], [2, 6, 10], [3, 9, 15] ] */ </script>
The documentation is located in the wiki section of this repository.
Internal benchmarks are located in the wiki section of this repository.
Compared to other libraries
The following benchmarks compare Vectorious 4.1.0 with three popular matrix/vector libraries:
The graphs show operations per second on the vertical (y) axis.
Below is a graph comparing the vector operations
The operations were performed on vectors generated with
Below is a graph comparing the matrix operations
The operations were performed on matrices generated with