New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mathjs

Package Overview
Dependencies
Maintainers
1
Versions
286
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mathjs - npm Package Versions

1
29

0.17.1

Diff

Changelog

Source

2013-12-19, version 0.17.1

  • Fixed a bug with negative temperatures.
  • Fixed a bug with prefixes of units squared meter m2 and cubic meter m3.
josdejong
published 0.17.0 •

Changelog

Source

2013-12-12, version 0.17.0

  • Renamed and flattened configuration settings:
    • number.defaultType is now number.
    • number.precision is now decimals.
    • matrix.defaultType is now matrix.
  • Function multiply now consistently outputs a complex number on complex input.
  • Fixed mod and in not working as function (only as operator).
  • Fixed support for old browsers (IE8 and older), compatible when using es5-shim.
  • Fixed support for Java's ScriptEngine.
josdejong
published 0.16.0 •

Changelog

Source

2013-11-28, version 0.16.0

  • Implemented BigNumber support for arbitrary precision calculations. Added settings number.defaultType and number.precision to configure big numbers.
  • Documentation is extended.
  • Removed utility functions isScalar, toScalar, isVector, toVector from Matrix and Range. Use math.squeeze and math.size instead.
  • Implemented functions get and set on Matrix, for easier and faster retrieval/replacement of elements in a matrix.
  • Implemented function resize, handling matrices, scalars, and strings.
  • Functions ones and zeros now return an empty matrix instead of a number 1 or 0 when no arguments are provided.
  • Implemented functions min and max for Range and Index.
  • Resizing matrices now leaves new elements undefined by default instead of filling them with zeros. Function resize now has an extra optional parameter defaultValue.
  • Range operator : in expression parser has been given a higher precedence.
  • Functions don't allow arguments of unknown type anymore.
  • Options be set when constructing a math.js instance or using the new function config(options. Options are no longer accessible via math.options.
  • Renamed scientific notation to exponential in function format.
  • Function format outputs exponential notation with positive exponents now always with + sign, so outputs 2.1e+3 instead of 2.1e3.
  • Fixed function squeeze not being able squeeze into a scalar.
  • Some fixes and performance improvements in the resize and subset functions.
  • Function size now adheres to the option matrix.defaultType for scalar input.
  • Minor bug fixes.
josdejong
published 0.15.0 •

Changelog

Source

2013-10-26, version 0.15.0

  • Math.js must be instantiated now, static calls are no longer supported. Usage:
    • node.js: var math = require('mathjs')();
    • browser: var math = mathjs();
  • Implemented support for multiplying vectors with matrices.
  • Improved number formatting:
    • Function format now support various options: precision, different notations (fixed, scientific, auto), and more.
    • Numbers are no longer rounded to 5 digits by default when formatted.
    • Implemented a function format for Matrix, Complex, Unit, Range, and Selector to format using options.
    • Function format does only stringify values now, and has a new parameter precision to round to a specific number of digits.
    • Removed option math.options.precision, use math.format(value [, precision]) instead.
    • Fixed formatting numbers as scientific notation in some cases returning a zero digit left from the decimal point. (like "0.33333e8" rather than "3.3333e7"). Thanks @husayt.
  • Implemented a function print to interpolate values in a template string, this functionality was moved from the function format.
  • Implemented statistics function mean. Thanks Guillermo Indalecio Fernandez (@guillermobox).
  • Extended and changed max and min for multi dimensional matrices: they now return the maximum and minimum of the flattened array. An optional second argument dim allows to calculate the max or min for specified dimension.
  • Renamed option math.options.matrix.default to math.options.matrix.defaultType.
  • Removed support for comparing complex numbers in functions smaller, smallereq, larger, largereq. Complex numbers cannot be ordered.
josdejong
published 0.14.0 •

Changelog

Source

2013-10-08, version 0.14.0

  • Introduced an option math.options.matrix.default which can have values matrix (default) or array. This option is used by the functions eye, ones, range, and zeros, to determine the type of matrix output.
  • Getting a subset of a matrix will automatically squeeze the resulting subset, setting a subset of a matrix will automatically unsqueeze the given subset.
  • Removed concatenation of nested arrays in the expression parser. You can now input nested arrays like in JavaScript. Matrices can be concatenated using the function concat.
  • The matrix syntax [...] in the expression parser now creates 1 dimensional matrices by default. math.eval('[1,2,3,4]') returns a matrix with size [4], math.eval('[1,2;3,4]') returns a matrix with size [2,2].
  • Documentation is restructured and extended.
  • Fixed non working operator mod (modulus operator).
josdejong
published 0.13.0 •

Changelog

Source

2013-09-03, version 0.13.0

  • Implemented support for booleans in all relevant functions.
  • Implemented functions map and forEach. Thanks Sebastien Piquemal (@sebpic).
  • All construction functions can be used to convert the type of variables, also element-wise for all elements in an Array or Matrix.
  • Changed matrix indexes of the expression parser to one-based with the upper-bound included, similar to most math applications. Note that on a JavaScript level, math.js uses zero-based indexes with excluded upper-bound.
  • Removed support for scalars in the function subset, it now only supports Array, Matrix, and String.
  • Removed the functions get and set from a selector, they are a duplicate of the function subset.
  • Replaced functions get and set of Matrix with a single function subset.
  • Some moving around with code and namespaces:
    • Renamed namespace math.expr to math.expression (contains Scope, Parser, node objects).
    • Renamed namespace math.docs to math.expression.docs.
    • Moved math.expr.Selector to math.chaining.Selector.
  • Fixed some edge cases in functions lcm and xgcd.
josdejong
published 0.12.1 •

Changelog

Source

2013-08-22, version 0.12.1

  • Fixed outdated version of README.md.
  • Fixed a broken unit test.
josdejong
published 0.12.0 •

Changelog

Source

2013-08-22, version 0.12.0

  • Implemented functions random([min, max]), randomInt([min, max]), pickRandom(array). Thanks Sebastien Piquemal (@sebpic).
  • Implemented function distribution(name), generating a distribution object with functions random, randomInt, pickRandom for different distributions. Currently supporting uniform and normal.
  • Changed the behavior of range to exclude the upper bound, so range(1, 4) now returns [1, 2, 3] instead of [1, 2, 3, 4].
  • Changed the syntax of range, which is now range(start, end [, step]) instead of range(start, [step, ] end).
  • Changed the behavior of ones and zeros to geometric dimensions, for example ones(3) returns a vector with length 3, filled with ones, and ones(3,3) returns a 2D array with size [3, 3].
  • Changed the return type of ones and zeros: they now return an Array when arguments are Numbers or an Array, and returns a Matrix when the argument is a Matrix.
  • Change matrix index notation in parser from round brackets to square brackets, for example A[0, 0:3].
  • Removed the feature introduced in v0.10.0 to automatically convert a complex value with an imaginary part equal to zero to a number.
  • Fixed zeros being formatted as null. Thanks @TimKraft.
josdejong
published 0.11.1 •

Changelog

Source

2013-07-23, version 0.11.1

  • Fixed missing development dependency
josdejong
published 0.11.0 •

Changelog

Source

2013-07-23, version 0.11.0

  • Changed math.js from one-based to zero-based indexes.
    • Getting and setting matrix subset is now zero-based.
    • The dimension argument in function concat is now zero-based.
  • Improvements in the string output of function help.
  • Added constants true and false.
  • Added constructor function boolean.
  • Fixed function select not accepting 0 as input. Thanks Elijah Manor (@elijahmanor).
  • Parser now supports multiple unary minus operators after each other.
  • Fixed not accepting empty matrices like [[], []].
  • Some fixes in the end user documentation.
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc