UNPKG

mathjs

Version:

Math.js is an extensive math library for JavaScript and Node.js. It features a flexible expression parser with support for symbolic computation, comes with a large set of built-in functions and constants, and offers an integrated solution to work with dif

11 lines (10 loc) 291 B
'use strict'; /** * Test whether a value is a Matrix * @param {*} x * @returns {boolean} returns true with input is a Matrix * (like a DenseMatrix or SparseMatrix) */ module.exports = function isMatrix(x) { return x && x.constructor.prototype.isMatrix || false; };