mathjs 11.7.0 → 11.8.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (88) hide show
  1. package/HISTORY.md +26 -0
  2. package/README.md +0 -26
  3. package/lib/browser/math.js +1 -1
  4. package/lib/browser/math.js.LICENSE.txt +2 -2
  5. package/lib/browser/math.js.map +1 -1
  6. package/lib/cjs/core/function/typed.js +1 -1
  7. package/lib/cjs/entry/dependenciesAny/dependenciesDistance.generated.js +2 -2
  8. package/lib/cjs/entry/pureFunctionsAny.generated.js +2 -2
  9. package/lib/cjs/expression/Parser.js +1 -1
  10. package/lib/cjs/expression/function/parser.js +1 -1
  11. package/lib/cjs/expression/node/FunctionAssignmentNode.js +1 -1
  12. package/lib/cjs/expression/node/OperatorNode.js +1 -3
  13. package/lib/cjs/expression/operators.js +19 -4
  14. package/lib/cjs/expression/transform/filter.transform.js +4 -13
  15. package/lib/cjs/expression/transform/forEach.transform.js +3 -12
  16. package/lib/cjs/expression/transform/map.transform.js +4 -13
  17. package/lib/cjs/factoriesNumber.js +18 -0
  18. package/lib/cjs/function/algebra/derivative.js +2 -2
  19. package/lib/cjs/function/algebra/leafCount.js +1 -1
  20. package/lib/cjs/function/algebra/polynomialRoot.js +1 -1
  21. package/lib/cjs/function/algebra/rationalize.js +5 -7
  22. package/lib/cjs/function/algebra/resolve.js +1 -1
  23. package/lib/cjs/function/algebra/simplify.js +7 -7
  24. package/lib/cjs/function/algebra/simplifyConstant.js +3 -3
  25. package/lib/cjs/function/algebra/simplifyCore.js +2 -2
  26. package/lib/cjs/function/algebra/sparse/csAmd.js +1 -3
  27. package/lib/cjs/function/algebra/sparse/csLeaf.js +1 -3
  28. package/lib/cjs/function/algebra/symbolicEqual.js +8 -8
  29. package/lib/cjs/function/geometry/distance.js +31 -29
  30. package/lib/cjs/function/matrix/eigs/complexEigs.js +3 -3
  31. package/lib/cjs/function/matrix/filter.js +2 -11
  32. package/lib/cjs/function/matrix/forEach.js +3 -12
  33. package/lib/cjs/function/matrix/map.js +6 -38
  34. package/lib/cjs/function/matrix/matrixFromColumns.js +1 -1
  35. package/lib/cjs/function/matrix/matrixFromRows.js +1 -1
  36. package/lib/cjs/function/matrix/sqrtm.js +1 -1
  37. package/lib/cjs/header.js +2 -2
  38. package/lib/cjs/type/bignumber/function/bignumber.js +7 -0
  39. package/lib/cjs/type/fraction/function/fraction.js +8 -1
  40. package/lib/cjs/type/matrix/DenseMatrix.js +41 -45
  41. package/lib/cjs/type/matrix/SparseMatrix.js +39 -41
  42. package/lib/cjs/type/number.js +7 -3
  43. package/lib/cjs/type/unit/Unit.js +2 -0
  44. package/lib/cjs/type/unit/function/splitUnit.js +1 -1
  45. package/lib/cjs/utils/applyCallback.js +73 -0
  46. package/lib/cjs/utils/bignumber/formatter.js +4 -3
  47. package/lib/cjs/utils/lruQueue.js +2 -6
  48. package/lib/cjs/utils/map.js +1 -1
  49. package/lib/cjs/utils/snapshot.js +7 -1
  50. package/lib/cjs/version.js +1 -1
  51. package/lib/esm/core/function/typed.js +1 -1
  52. package/lib/esm/entry/dependenciesAny/dependenciesDistance.generated.js +2 -2
  53. package/lib/esm/entry/pureFunctionsAny.generated.js +2 -2
  54. package/lib/esm/expression/Parser.js +1 -1
  55. package/lib/esm/expression/function/parser.js +1 -1
  56. package/lib/esm/expression/node/OperatorNode.js +1 -3
  57. package/lib/esm/expression/operators.js +1 -3
  58. package/lib/esm/expression/transform/filter.transform.js +4 -13
  59. package/lib/esm/expression/transform/forEach.transform.js +3 -12
  60. package/lib/esm/expression/transform/map.transform.js +4 -13
  61. package/lib/esm/function/algebra/derivative.js +2 -2
  62. package/lib/esm/function/algebra/leafCount.js +1 -1
  63. package/lib/esm/function/algebra/polynomialRoot.js +1 -1
  64. package/lib/esm/function/algebra/rationalize.js +5 -7
  65. package/lib/esm/function/algebra/resolve.js +1 -1
  66. package/lib/esm/function/algebra/simplify.js +7 -7
  67. package/lib/esm/function/algebra/simplifyConstant.js +2 -2
  68. package/lib/esm/function/algebra/simplifyCore.js +2 -2
  69. package/lib/esm/function/algebra/sparse/csAmd.js +1 -3
  70. package/lib/esm/function/algebra/sparse/csLeaf.js +1 -3
  71. package/lib/esm/function/algebra/symbolicEqual.js +8 -8
  72. package/lib/esm/function/geometry/distance.js +31 -29
  73. package/lib/esm/function/matrix/eigs/complexEigs.js +2 -2
  74. package/lib/esm/function/matrix/filter.js +2 -11
  75. package/lib/esm/function/matrix/forEach.js +3 -12
  76. package/lib/esm/function/matrix/map.js +6 -38
  77. package/lib/esm/function/matrix/sqrtm.js +1 -1
  78. package/lib/esm/type/bignumber/function/bignumber.js +5 -0
  79. package/lib/esm/type/fraction/function/fraction.js +6 -1
  80. package/lib/esm/type/number.js +5 -3
  81. package/lib/esm/type/unit/Unit.js +2 -0
  82. package/lib/esm/type/unit/function/splitUnit.js +1 -1
  83. package/lib/esm/utils/applyCallback.js +67 -0
  84. package/lib/esm/utils/bignumber/formatter.js +4 -3
  85. package/lib/esm/utils/lruQueue.js +2 -6
  86. package/lib/esm/version.js +1 -1
  87. package/package.json +21 -21
  88. package/types/index.d.ts +16 -16
package/HISTORY.md CHANGED
@@ -1,5 +1,31 @@
1
1
  # History
2
2
 
3
+ # 2023-06-13, 11.8.1
4
+
5
+ - Fix #2964: issue in function ` distance` when calculate the distance from
6
+ a point to a line (#2965). Thanks @Kiku-CN.
7
+ - Fix `math.format` not working correctly for `engineering` notation when using
8
+ BigNumbers and for `fixed` notation with `precision: 0` configured (#2956).
9
+ Thanks @mgreminger.
10
+ - Fix #2880: not possible to map cube root `cbrt`.
11
+ - Fix #2938: make the syntax description of all functions consistent in the
12
+ docs (#2941). Thanks @dvd101x.
13
+ - Fix #2954: improve the TypeScript definitions the return type of functions
14
+ `min` and `max` (#2955). Thanks @Maxim-Mazurok.
15
+ - Fix #2959: typo in an example in the docs. Thanks @kunalagrwl.
16
+ - Drop official support for Node.js 14, has reached end of life.
17
+
18
+
19
+ # 2023-04-03, 11.8.0
20
+
21
+ - Extended functions `fraction`, `bignumber`, and `number` with support for
22
+ units, see #2918 (#2926).
23
+ - Implemented aliases `amp` and `amps` for unit `ampere` (#2917).
24
+ Thanks @veggiesaurus.
25
+ - Improve TypeScript definitions of function `gcd` (#2922). Thanks @brunoSnoww.
26
+ - Fix #2923: improve docs of the function `distance` (#2924). Thanks @tmtron.
27
+
28
+
3
29
  # 2023-03-15, 11.7.0
4
30
 
5
31
  - Implement #2567: accept array as parameter for function `gcd` (#2878).
package/README.md CHANGED
@@ -11,34 +11,8 @@ Math.js is an extensive math library for JavaScript and Node.js. It features a f
11
11
  [![License](https://img.shields.io/github/license/josdejong/mathjs.svg)](https://github.com/josdejong/mathjs/blob/master/LICENSE)
12
12
  [![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2Fjosdejong%2Fmathjs.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2Fjosdejong%2Fmathjs?ref=badge_shield)
13
13
  [![Codecov](https://codecov.io/gh/josdejong/mathjs/branch/develop/graph/badge.svg)](https://codecov.io/gh/josdejong/mathjs)
14
- [![Foresight](https://api-public.service.runforesight.com/api/v1/badge/test?repoId=13cb22bf-6cd5-4c4b-a9de-46081ac63ffb)](https://mathjs.app.runforesight.com/)
15
14
  [![Github Sponsor](https://camo.githubusercontent.com/7d9333b097b2f54a8957d126ab82937811489c9b75c3850f609985cf94cd29fe/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f2532302d53706f6e736f722532306d652532306f6e2532304769744875622d6f72616e6765)](https://github.com/sponsors/josdejong)
16
15
 
17
- ## Sponsors
18
-
19
- <table width="100%">
20
- <tr>
21
- <td>
22
- <img width="1000" height="0">
23
- <a href="https://www.runforesight.com/?utm_source=mathjs&utm_medium=sponsorship">
24
- <img src="https://www.thundra.io/hubfs/RunForesight/GitHub%20Sponsorship%20banners/power-up-github.png"
25
- alt="Foresight" width="260" align="right">
26
- </a>
27
-
28
- <h3>Foresight: Increase CI/CD Health & Test Performance</h3>
29
-
30
- <p>
31
- Foresight provides full visibility and deep insights into the health
32
- and performance of your tests and CI pipelines. Assess the risk of
33
- changes, resolve bottlenecks, reduce build times, and deliver
34
- high-quality software at speed with Foresight.
35
- </p>
36
-
37
- [Sign up now!](https://runforesight.com/?utm_source=mathjs&utm_medium=sponsorship)
38
- </td>
39
- </tr>
40
- </table>
41
-
42
16
  ## Features
43
17
 
44
18
  - Supports numbers, big numbers, complex numbers, fractions, units, strings, arrays, and matrices.