@cortex-js/compute-engine 0.23.1 → 0.24.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/README.md +2 -2
  2. package/dist/compute-engine.esm.js +13003 -12756
  3. package/dist/compute-engine.js +12985 -12738
  4. package/dist/compute-engine.min.esm.js +10 -10
  5. package/dist/compute-engine.min.js +10 -10
  6. package/dist/math-json.esm.js +2 -2
  7. package/dist/math-json.js +2 -2
  8. package/dist/math-json.min.esm.js +2 -2
  9. package/dist/math-json.min.js +2 -2
  10. package/dist/types/common/ansi-codes.d.ts +1 -1
  11. package/dist/types/common/grapheme-splitter.d.ts +1 -1
  12. package/dist/types/common/signals.d.ts +12 -1
  13. package/dist/types/common/utils.d.ts +1 -1
  14. package/dist/types/compute-engine/assume.d.ts +1 -1
  15. package/dist/types/compute-engine/boxed-expression/abstract-boxed-expression.d.ts +4 -4
  16. package/dist/types/compute-engine/boxed-expression/box.d.ts +2 -2
  17. package/dist/types/compute-engine/boxed-expression/boxed-dictionary.d.ts +8 -4
  18. package/dist/types/compute-engine/boxed-expression/boxed-domain.d.ts +6 -3
  19. package/dist/types/compute-engine/boxed-expression/boxed-function-definition.d.ts +1 -1
  20. package/dist/types/compute-engine/boxed-expression/boxed-function.d.ts +8 -4
  21. package/dist/types/compute-engine/boxed-expression/boxed-number.d.ts +5 -3
  22. package/dist/types/compute-engine/boxed-expression/boxed-patterns.d.ts +17 -22
  23. package/dist/types/compute-engine/boxed-expression/boxed-string.d.ts +7 -3
  24. package/dist/types/compute-engine/boxed-expression/boxed-symbol-definition.d.ts +2 -2
  25. package/dist/types/compute-engine/boxed-expression/boxed-symbol.d.ts +7 -4
  26. package/dist/types/compute-engine/boxed-expression/boxed-tensor.d.ts +7 -3
  27. package/dist/types/compute-engine/boxed-expression/canonical.d.ts +1 -1
  28. package/dist/types/compute-engine/boxed-expression/expression-map.d.ts +1 -1
  29. package/dist/types/compute-engine/boxed-expression/order.d.ts +1 -1
  30. package/dist/types/compute-engine/boxed-expression/serialize.d.ts +1 -1
  31. package/dist/types/compute-engine/boxed-expression/utils.d.ts +2 -9
  32. package/dist/types/compute-engine/boxed-expression/validate.d.ts +1 -1
  33. package/dist/types/compute-engine/collection-utils.d.ts +1 -1
  34. package/dist/types/compute-engine/compile.d.ts +1 -1
  35. package/dist/types/compute-engine/compute-engine.d.ts +39 -23
  36. package/dist/types/compute-engine/cost-function.d.ts +1 -1
  37. package/dist/types/compute-engine/domain-utils.d.ts +1 -1
  38. package/dist/types/compute-engine/function-utils.d.ts +4 -4
  39. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-algebra.d.ts +1 -1
  40. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-arithmetic.d.ts +1 -1
  41. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-calculus.d.ts +1 -1
  42. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-complex.d.ts +1 -1
  43. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-core.d.ts +1 -1
  44. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-linear-algebra.d.ts +1 -1
  45. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-logic.d.ts +1 -1
  46. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-other.d.ts +1 -1
  47. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-relational-operators.d.ts +1 -1
  48. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-sets.d.ts +1 -1
  49. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-statistics.d.ts +1 -1
  50. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-symbols.d.ts +1 -1
  51. package/dist/types/compute-engine/latex-syntax/dictionary/definitions-trigonometry.d.ts +1 -1
  52. package/dist/types/compute-engine/latex-syntax/dictionary/definitions.d.ts +1 -1
  53. package/dist/types/compute-engine/latex-syntax/latex-syntax.d.ts +1 -1
  54. package/dist/types/compute-engine/latex-syntax/parse-identifier.d.ts +1 -1
  55. package/dist/types/compute-engine/latex-syntax/parse.d.ts +5 -3
  56. package/dist/types/compute-engine/latex-syntax/public.d.ts +154 -18
  57. package/dist/types/compute-engine/latex-syntax/serialize-number.d.ts +1 -1
  58. package/dist/types/compute-engine/latex-syntax/serializer-style.d.ts +2 -2
  59. package/dist/types/compute-engine/latex-syntax/serializer.d.ts +1 -1
  60. package/dist/types/compute-engine/latex-syntax/tokenizer.d.ts +1 -1
  61. package/dist/types/compute-engine/library/arithmetic-add.d.ts +1 -1
  62. package/dist/types/compute-engine/library/arithmetic-divide.d.ts +1 -1
  63. package/dist/types/compute-engine/library/arithmetic-multiply.d.ts +1 -1
  64. package/dist/types/compute-engine/library/arithmetic-power.d.ts +1 -1
  65. package/dist/types/compute-engine/library/arithmetic.d.ts +1 -1
  66. package/dist/types/compute-engine/library/calculus.d.ts +1 -1
  67. package/dist/types/compute-engine/library/collections.d.ts +1 -1
  68. package/dist/types/compute-engine/library/complex.d.ts +1 -1
  69. package/dist/types/compute-engine/library/control-structures.d.ts +1 -1
  70. package/dist/types/compute-engine/library/core.d.ts +1 -1
  71. package/dist/types/compute-engine/library/domains.d.ts +1 -1
  72. package/dist/types/compute-engine/library/library.d.ts +1 -1
  73. package/dist/types/compute-engine/library/linear-algebra.d.ts +1 -1
  74. package/dist/types/compute-engine/library/logic.d.ts +1 -1
  75. package/dist/types/compute-engine/library/polynomials.d.ts +1 -1
  76. package/dist/types/compute-engine/library/random-expression.d.ts +1 -1
  77. package/dist/types/compute-engine/library/relational-operator.d.ts +2 -1
  78. package/dist/types/compute-engine/library/sets.d.ts +1 -1
  79. package/dist/types/compute-engine/library/statistics.d.ts +1 -1
  80. package/dist/types/compute-engine/library/trigonometry.d.ts +1 -1
  81. package/dist/types/compute-engine/library/utils.d.ts +1 -1
  82. package/dist/types/compute-engine/numerics/factor.d.ts +1 -1
  83. package/dist/types/compute-engine/numerics/numeric-bigint.d.ts +2 -2
  84. package/dist/types/compute-engine/numerics/numeric-bignum.d.ts +1 -1
  85. package/dist/types/compute-engine/numerics/numeric-complex.d.ts +1 -1
  86. package/dist/types/compute-engine/numerics/numeric.d.ts +1 -1
  87. package/dist/types/compute-engine/numerics/primes.d.ts +1 -1
  88. package/dist/types/compute-engine/numerics/rationals.d.ts +1 -1
  89. package/dist/types/compute-engine/numerics/richardson.d.ts +1 -1
  90. package/dist/types/compute-engine/numerics/terms.d.ts +1 -1
  91. package/dist/types/compute-engine/public.d.ts +156 -54
  92. package/dist/types/compute-engine/rules.d.ts +2 -2
  93. package/dist/types/compute-engine/simplify-rules.d.ts +1 -1
  94. package/dist/types/compute-engine/solve.d.ts +1 -1
  95. package/dist/types/compute-engine/symbolic/derivative.d.ts +1 -1
  96. package/dist/types/compute-engine/symbolic/expand.d.ts +1 -1
  97. package/dist/types/compute-engine/symbolic/flatten.d.ts +1 -1
  98. package/dist/types/compute-engine/symbolic/negate.d.ts +1 -1
  99. package/dist/types/compute-engine/symbolic/polynomials.d.ts +1 -1
  100. package/dist/types/compute-engine/symbolic/product.d.ts +1 -1
  101. package/dist/types/compute-engine/symbolic/tensor-fields.d.ts +1 -1
  102. package/dist/types/compute-engine/symbolic/tensors.d.ts +4 -1
  103. package/dist/types/compute-engine/symbolic/utils.d.ts +1 -1
  104. package/dist/types/compute-engine.d.ts +2 -2
  105. package/dist/types/math-json/math-json-format.d.ts +10 -1
  106. package/dist/types/math-json/utils.d.ts +1 -1
  107. package/dist/types/math-json.d.ts +2 -2
  108. package/package.json +8 -3
@@ -1,4 +1,4 @@
1
- /** CortexJS Compute Engine 0.23.1 */
1
+ /** Compute Engine 0.24.0 */
2
2
 
3
3
  // src/math-json/utils.ts
4
4
  function isSymbolObject(expr) {
@@ -240,7 +240,7 @@ function mapArgs(expr, fn) {
240
240
  }
241
241
 
242
242
  // src/math-json.ts
243
- var version = "0.23.1";
243
+ var version = "0.24.0";
244
244
  export {
245
245
  applyRecursively,
246
246
  dictionary as getDictionary,
package/dist/math-json.js CHANGED
@@ -1,4 +1,4 @@
1
- /** CortexJS MathJSON 0.23.1 */
1
+ /** MathJSON 0.24.0 */
2
2
  (function(global,factory){typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : typeof define === 'function' && define.amd ? define(['exports'],factory):(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.MathJson = {}));})(this, (function (exports) { 'use strict';
3
3
  var MathJson = (() => {
4
4
  var __defProp = Object.defineProperty;
@@ -278,7 +278,7 @@ var MathJson = (() => {
278
278
  }
279
279
 
280
280
  // src/math-json.ts
281
- var version = "0.23.1";
281
+ var version = "0.24.0";
282
282
  return __toCommonJS(math_json_exports);
283
283
  })();
284
284
  Object.assign(exports, MathJson); Object.defineProperty(exports, '__esModule', { value: true });}));
@@ -1,4 +1,4 @@
1
- /** CortexJS Compute Engine 0.23.1 */
1
+ /** Compute Engine 0.24.0 */
2
2
 
3
3
  // src/math-json/utils.ts
4
4
  function isSymbolObject(expr) {
@@ -240,7 +240,7 @@ function mapArgs(expr, fn) {
240
240
  }
241
241
 
242
242
  // src/math-json.ts
243
- var version = "0.23.1";
243
+ var version = "0.24.0";
244
244
  export {
245
245
  applyRecursively,
246
246
  dictionary as getDictionary,
@@ -1,4 +1,4 @@
1
- /** CortexJS MathJSON 0.23.1 */
1
+ /** MathJSON 0.24.0 */
2
2
  (function(global,factory){typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) : typeof define === 'function' && define.amd ? define(['exports'],factory):(global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.MathJson = {}));})(this, (function (exports) { 'use strict';
3
- var MathJson=(()=>{var f=Object.defineProperty;var T=Object.getOwnPropertyDescriptor;var v=Object.getOwnPropertyNames;var k=Object.prototype.hasOwnProperty;var D=(n,t)=>{for(var e in t)f(n,e,{get:t[e],enumerable:!0})},R=(n,t,e,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of v(t))!k.call(n,r)&&r!==e&&f(n,r,{get:()=>t[r],enumerable:!(i=T(t,r))||i.enumerable});return n};var _=n=>R(f({},"__esModule",{value:!0}),n);var z={};D(z,{applyRecursively:()=>J,getDictionary:()=>y,getStringValue:()=>m,head:()=>o,headName:()=>I,isDictionaryObject:()=>M,isFunctionObject:()=>u,isStringObject:()=>S,isSymbolObject:()=>d,mapArgs:()=>$,nops:()=>E,op:()=>s,symbol:()=>A,version:()=>X});function d(n){return n!==null&&typeof n=="object"&&"sym"in n}function S(n){return n!==null&&typeof n=="object"&&"str"in n}function u(n){return n!==null&&typeof n=="object"&&"fn"in n}function M(n){return n!==null&&typeof n=="object"&&"dict"in n}var c;function N(n){if(!c){let e=`^[${["Zyyy","Zinh","Arab","Armn","Beng","Bopo","Cyrl","Deva","Ethi","Geor","Grek","Gujr","Guru","Hang","Hani","Hebr","Hira","Kana","Knda","Khmr","Laoo","Latn","Mlym","Mymr","Orya","Sinh","Taml","Telu","Thaa","Thai","Tibt"].map(i=>`\\p{Script=${i}}`).join("")}]*$`;c=new RegExp(e,"u")}return c.test(n)}function a(n){return/^[a-zA-Z_][a-zA-Z0-9_]*$/.test(n)||O.test(n)?!0:N(n)?/^[\p{XIDS}_]\p{XIDC}*$/u.test(n):!1}var F="\\u{FE0F}",V="\\u{20E3}",L="\\u{200D}",P="\\p{RI}\\p{RI}",w="(?:[\\u{E0020}-\\u{E007E}]+\\u{E007F})",b=`(?:\\p{EMod}|${F}${V}?|${w})`,C="(?:(?=\\P{XIDC})\\p{Emoji})",h=`(?:${C}${b}*|\\p{Emoji}${b}+|${P})`,j=`(?:${h})(${L}${h})*`,G=new RegExp(`(?:${j})+`,"u"),O=new RegExp(`^(?:${j})+$`,"u");function q(n){return typeof n!="string"?"not-a-string":n===""?"empty-string":n.normalize()!==n?"expected-nfc":/[\u200E\u200F\u2066-\u2069\u202A-\u202E]/.test(n)?"unexpected-bidi-marker":O.test(n)?"valid":/\p{XIDC}/u.test(n)&&G.test(n)?"unexpected-mixed-emoji":N(n)?a(n)?"valid":a(n[0])?"invalid-char":"invalid-first-char":"unexpected-script"}function m(n){return n==null?null:typeof n=="object"&&"str"in n?n.str:typeof n!="string"||n.length<2||n[0]!=="'"||n[n.length-1]!=="'"?null:n.substring(1,n.length-1)}function o(n){return Array.isArray(n)?typeof n[0]=="string"&&!a(n[0])?(console.error(`Invalid identifier "${n[0]}": ${q(n[0])}`),null):n[0]:n==null?null:u(n)?n.fn[0]:null}function I(n){let t=o(n);return typeof t=="string"?t:""}function H(n){return Array.isArray(n)?n.slice(1):n==null?null:u(n)?n.fn.slice(1):null}function s(n,t){return Array.isArray(n)?n[t]??null:n==null?null:u(n)?n.fn[t]??null:null}function K(n){return s(n,1)}function Z(n){return s(n,2)}function E(n){return n==null?0:Array.isArray(n)?Math.max(0,n.length-1):u(n)?Math.max(0,n.fn.length-1):0}function A(n){if(typeof n=="string")return/^[+-]?[0-9\.]/.test(n)||n.length>=2&&n[0]==="'"&&n[n.length-1]==="'"?null:n;if(n==null)return null;let t=d(n)?n.sym:n;return typeof t!="string"?null:t}function p(n){let t=o(n);if(t==="KeyValuePair"||t==="Tuple"||t==="Pair"){let e=m(K(n));return e?[e,Z(n)??"Nothing"]:null}return null}function y(n){if(n===null)return null;if(typeof n=="object"&&"dict"in n)return n.dict;let t=p(n);if(t)return{[t[0]]:t[1]};if(o(n)==="Dictionary"){let i={};for(let r=1;r<E(n);r++){let l=p(s(n,r));l&&(i[l[0]]=l[1])}return i}return null}function J(n,t){let e=o(n);if(e!==null)return[t(e),...(H(n)??[]).map(t)];let i=y(n);if(i!==null){let r=Object.keys(i),l={};for(let g of r)l[g]=t(i[g]);return{dict:l}}return t(n)}function $(n,t){let e=null;if(Array.isArray(n)&&(e=n),u(n)&&(e=n.fn),e===null)return[];let i=1,r=[];for(;i<e.length;)r.push(t(e[i])),i+=1;return r}var X="0.23.1";return _(z);})();
3
+ var MathJson=(()=>{var f=Object.defineProperty;var T=Object.getOwnPropertyDescriptor;var v=Object.getOwnPropertyNames;var k=Object.prototype.hasOwnProperty;var D=(n,t)=>{for(var e in t)f(n,e,{get:t[e],enumerable:!0})},R=(n,t,e,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of v(t))!k.call(n,r)&&r!==e&&f(n,r,{get:()=>t[r],enumerable:!(i=T(t,r))||i.enumerable});return n};var _=n=>R(f({},"__esModule",{value:!0}),n);var z={};D(z,{applyRecursively:()=>J,getDictionary:()=>y,getStringValue:()=>m,head:()=>o,headName:()=>I,isDictionaryObject:()=>M,isFunctionObject:()=>u,isStringObject:()=>S,isSymbolObject:()=>d,mapArgs:()=>$,nops:()=>E,op:()=>s,symbol:()=>A,version:()=>X});function d(n){return n!==null&&typeof n=="object"&&"sym"in n}function S(n){return n!==null&&typeof n=="object"&&"str"in n}function u(n){return n!==null&&typeof n=="object"&&"fn"in n}function M(n){return n!==null&&typeof n=="object"&&"dict"in n}var c;function N(n){if(!c){let e=`^[${["Zyyy","Zinh","Arab","Armn","Beng","Bopo","Cyrl","Deva","Ethi","Geor","Grek","Gujr","Guru","Hang","Hani","Hebr","Hira","Kana","Knda","Khmr","Laoo","Latn","Mlym","Mymr","Orya","Sinh","Taml","Telu","Thaa","Thai","Tibt"].map(i=>`\\p{Script=${i}}`).join("")}]*$`;c=new RegExp(e,"u")}return c.test(n)}function a(n){return/^[a-zA-Z_][a-zA-Z0-9_]*$/.test(n)||O.test(n)?!0:N(n)?/^[\p{XIDS}_]\p{XIDC}*$/u.test(n):!1}var F="\\u{FE0F}",V="\\u{20E3}",L="\\u{200D}",P="\\p{RI}\\p{RI}",w="(?:[\\u{E0020}-\\u{E007E}]+\\u{E007F})",b=`(?:\\p{EMod}|${F}${V}?|${w})`,C="(?:(?=\\P{XIDC})\\p{Emoji})",h=`(?:${C}${b}*|\\p{Emoji}${b}+|${P})`,j=`(?:${h})(${L}${h})*`,G=new RegExp(`(?:${j})+`,"u"),O=new RegExp(`^(?:${j})+$`,"u");function q(n){return typeof n!="string"?"not-a-string":n===""?"empty-string":n.normalize()!==n?"expected-nfc":/[\u200E\u200F\u2066-\u2069\u202A-\u202E]/.test(n)?"unexpected-bidi-marker":O.test(n)?"valid":/\p{XIDC}/u.test(n)&&G.test(n)?"unexpected-mixed-emoji":N(n)?a(n)?"valid":a(n[0])?"invalid-char":"invalid-first-char":"unexpected-script"}function m(n){return n==null?null:typeof n=="object"&&"str"in n?n.str:typeof n!="string"||n.length<2||n[0]!=="'"||n[n.length-1]!=="'"?null:n.substring(1,n.length-1)}function o(n){return Array.isArray(n)?typeof n[0]=="string"&&!a(n[0])?(console.error(`Invalid identifier "${n[0]}": ${q(n[0])}`),null):n[0]:n==null?null:u(n)?n.fn[0]:null}function I(n){let t=o(n);return typeof t=="string"?t:""}function H(n){return Array.isArray(n)?n.slice(1):n==null?null:u(n)?n.fn.slice(1):null}function s(n,t){return Array.isArray(n)?n[t]??null:n==null?null:u(n)?n.fn[t]??null:null}function K(n){return s(n,1)}function Z(n){return s(n,2)}function E(n){return n==null?0:Array.isArray(n)?Math.max(0,n.length-1):u(n)?Math.max(0,n.fn.length-1):0}function A(n){if(typeof n=="string")return/^[+-]?[0-9\.]/.test(n)||n.length>=2&&n[0]==="'"&&n[n.length-1]==="'"?null:n;if(n==null)return null;let t=d(n)?n.sym:n;return typeof t!="string"?null:t}function p(n){let t=o(n);if(t==="KeyValuePair"||t==="Tuple"||t==="Pair"){let e=m(K(n));return e?[e,Z(n)??"Nothing"]:null}return null}function y(n){if(n===null)return null;if(typeof n=="object"&&"dict"in n)return n.dict;let t=p(n);if(t)return{[t[0]]:t[1]};if(o(n)==="Dictionary"){let i={};for(let r=1;r<E(n);r++){let l=p(s(n,r));l&&(i[l[0]]=l[1])}return i}return null}function J(n,t){let e=o(n);if(e!==null)return[t(e),...(H(n)??[]).map(t)];let i=y(n);if(i!==null){let r=Object.keys(i),l={};for(let g of r)l[g]=t(i[g]);return{dict:l}}return t(n)}function $(n,t){let e=null;if(Array.isArray(n)&&(e=n),u(n)&&(e=n.fn),e===null)return[];let i=1,r=[];for(;i<e.length;)r.push(t(e[i])),i+=1;return r}var X="0.24.0";return _(z);})();
4
4
  Object.assign(exports, MathJson); Object.defineProperty(exports, '__esModule', { value: true });}));
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export declare const BLACK = "\u001B[30;1m${s}";
3
3
  export declare const GREY = "\u001B[30;1m${s}";
4
4
  export declare const GREEN = "\u001B[32;1m";
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  /**
3
3
  * Return a string or an array of graphemes.
4
4
  *
@@ -1,6 +1,11 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
+ /** @category Error Handling */
3
+ export type RuntimeSignalCode = 'timeout' | 'out-of-memory' | 'recursion-depth-exceeded' | 'iteration-limit-exceeded';
4
+ /** @category Error Handling */
2
5
  export type SignalCode = RuntimeSignalCode | ('invalid-name' | 'expected-predicate' | 'expected-symbol' | 'operator-requires-one-operand' | 'postfix-operator-requires-one-operand' | 'prefix-operator-requires-one-operand' | 'unbalanced-symbols' | 'expected-argument' | 'unexpected-command' | 'cyclic-definition' | 'invalid-supersets' | 'expected-supersets' | 'unknown-domain' | 'duplicate-wikidata' | 'invalid-dictionary-entry' | 'syntax-error');
6
+ /** @category Error Handling */
3
7
  export type SignalMessage = SignalCode | [SignalCode, ...any[]];
8
+ /** @category Error Handling */
4
9
  export type SignalOrigin = {
5
10
  url?: string;
6
11
  source?: string;
@@ -9,6 +14,7 @@ export type SignalOrigin = {
9
14
  column?: number;
10
15
  around?: string;
11
16
  };
17
+ /** @category Error Handling */
12
18
  export type Signal = {
13
19
  severity?: 'warning' | 'error';
14
20
  /** An error/warning code or, a code with one or more arguments specific to
@@ -22,12 +28,15 @@ export type Signal = {
22
28
  /** Location where the signal was raised. */
23
29
  origin?: SignalOrigin;
24
30
  };
31
+ /** @category Error Handling */
25
32
  export type ErrorSignal = Signal & {
26
33
  severity: 'error';
27
34
  };
35
+ /** @category Error Handling */
28
36
  export type WarningSignal = Signal & {
29
37
  severity: 'warning';
30
38
  };
39
+ /** @category Error Handling */
31
40
  export type WarningSignalHandler = (warnings: WarningSignal[]) => void;
32
41
  /**
33
42
  * The error codes can be used in an `ErrorCode` expression:
@@ -82,5 +91,7 @@ export type WarningSignalHandler = (warnings: WarningSignal[]) => void;
82
91
  *
83
92
  * * `base-out-of-range`: The base is expected to be between 2 and 36.
84
93
  *
94
+ * @category Error Handling
95
+ *
85
96
  */
86
97
  export type ErrorCode = 'expected-argument' | 'unexpected-argument' | 'expected-operator' | 'expected-operand' | 'invalid-name' | 'invalid-dictionary-entry' | 'unknown-symbol' | 'unknown-operator' | 'unknown-function' | 'unknown-command' | 'unexpected-command' | 'unbalanced-symbols' | 'unexpected-superscript' | 'unexpected-subscript' | 'unexpected-sequence' | 'non-associative-operator' | 'function-has-too-many-arguments' | 'function-has-too-few-arguments' | 'operator-requires-one-operand' | 'infix-operator-requires-two-operands' | 'prefix-operator-requires-one-operand' | 'postfix-operator-requires-one-operand' | 'associative-function-has-too-few-arguments' | 'commutative-function-has-too-few-arguments' | 'threadable-function-has-too-few-arguments' | 'hold-first-function-has-too-few-arguments' | 'hold-rest-function-has-too-few-arguments' | 'base-out-of-range' | 'syntax-error';
@@ -1 +1 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  /**
3
3
  * Add an assumption, in the form of a predicate, for example:
4
4
  *
@@ -1,7 +1,7 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Decimal } from 'decimal.js';
3
3
  import { Expression } from '../../math-json/math-json-format';
4
- import { BoxedExpression, BoxedFunctionDefinition, BoxedRuleSet, BoxedSymbolDefinition, BoxedDomain, EvaluateOptions, IComputeEngine, LatexString, Metadata, NOptions, PatternMatchOptions, SimplifyOptions, Substitution, RuntimeScope, DomainCompatibility, DomainLiteral, BoxedBaseDefinition, Rational, BoxedSubstitution } from '../public';
4
+ import { BoxedExpression, BoxedFunctionDefinition, BoxedRuleSet, BoxedSymbolDefinition, BoxedDomain, EvaluateOptions, IComputeEngine, LatexString, Metadata, NOptions, PatternMatchOptions, SimplifyOptions, Substitution, RuntimeScope, DomainCompatibility, DomainLiteral, BoxedBaseDefinition, Rational, BoxedSubstitution, Rule, SemiBoxedExpression } from '../public';
5
5
  /**
6
6
  * _BoxedExpression
7
7
  */
@@ -13,7 +13,7 @@ export declare abstract class _BoxedExpression implements BoxedExpression {
13
13
  abstract set isCanonical(_val: boolean);
14
14
  abstract isSame(rhs: BoxedExpression): boolean;
15
15
  abstract isEqual(rhs: BoxedExpression): boolean;
16
- abstract match(rhs: BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
16
+ abstract match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
17
17
  readonly engine: IComputeEngine;
18
18
  /** Verbatim LaTeX, obtained from a source, i.e. from parsing,
19
19
  * not generated synthetically
@@ -78,7 +78,7 @@ export declare abstract class _BoxedExpression implements BoxedExpression {
78
78
  canonical: boolean;
79
79
  }): BoxedExpression;
80
80
  solve(_vars: Iterable<string>): null | BoxedExpression[];
81
- replace(_rules: BoxedRuleSet): null | BoxedExpression;
81
+ replace(_rules: BoxedRuleSet | Rule | Rule[]): null | BoxedExpression;
82
82
  has(_v: string | string[]): boolean;
83
83
  isLess(_rhs: BoxedExpression): boolean | undefined;
84
84
  isLessEqual(_rhs: BoxedExpression): boolean | undefined;
@@ -1,9 +1,9 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Decimal } from 'decimal.js';
3
3
  import { IComputeEngine, SemiBoxedExpression, BoxedExpression, Metadata, Rational, CanonicalForm } from '../public';
4
4
  import { MathJsonNumber } from '../../math-json/math-json-format';
5
5
  /**
6
- * ## THEORY OF OPERATIONS
6
+ * ### THEORY OF OPERATIONS
7
7
  *
8
8
  * 1/ Boxing does not depend on the numeric mode. The numeric mode could be
9
9
  * changed later, but the previously boxed numbers could not be retroactively
@@ -1,8 +1,12 @@
1
- /* 0.23.1 */
2
- import { BoxedExpression, IComputeEngine, EvaluateOptions, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, ReplaceOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, BoxedSubstitution } from '../public';
1
+ /* 0.24.0 */
2
+ import Decimal from 'decimal.js';
3
+ import { Expression } from '../../math-json/math-json-format';
4
+ import { BoxedExpression, IComputeEngine, EvaluateOptions, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, ReplaceOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, BoxedSubstitution, Rule } from '../public';
3
5
  import { _BoxedExpression } from './abstract-boxed-expression';
4
6
  /**
5
7
  * BoxedDictionary
8
+ *
9
+ * @noInheritDoc
6
10
  */
7
11
  export declare class BoxedDictionary extends _BoxedExpression {
8
12
  private _value;
@@ -28,7 +32,7 @@ export declare class BoxedDictionary extends _BoxedExpression {
28
32
  get json(): Expression;
29
33
  /** Structural equality */
30
34
  isSame(rhs: BoxedExpression): boolean;
31
- match(rhs: BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
35
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
32
36
  /** Mathematical equality */
33
37
  isEqual(rhs: BoxedExpression): boolean;
34
38
  evaluate(_options?: EvaluateOptions): BoxedExpression;
@@ -37,7 +41,7 @@ export declare class BoxedDictionary extends _BoxedExpression {
37
41
  get canonical(): BoxedExpression;
38
42
  simplify(_options?: SimplifyOptions): BoxedExpression;
39
43
  N(_options?: NOptions): BoxedExpression;
40
- replace(rules: BoxedRuleSet, options?: ReplaceOptions): null | BoxedExpression;
44
+ replace(rules: BoxedRuleSet | Rule | Rule[], options?: ReplaceOptions): null | BoxedExpression;
41
45
  subs(sub: Substitution, options?: {
42
46
  canonical: boolean;
43
47
  }): BoxedExpression;
@@ -1,5 +1,7 @@
1
- /* 0.23.1 */
2
- import { BoxedDomain, BoxedExpression, BoxedSubstitution, DomainCompatibility, DomainConstructor, DomainExpression, DomainLiteral, IComputeEngine, Metadata, PatternMatchOptions } from '../public';
1
+ /* 0.24.0 */
2
+ import Decimal from 'decimal.js';
3
+ import { Expression } from '../../math-json/math-json-format';
4
+ import { BoxedDomain, BoxedExpression, BoxedSubstitution, DomainCompatibility, DomainConstructor, DomainExpression, DomainLiteral, IComputeEngine, Metadata, PatternMatchOptions, SemiBoxedExpression } from '../public';
3
5
  import { _BoxedExpression } from './abstract-boxed-expression';
4
6
  /**
5
7
  * A `_BoxedDomain` is a wrapper around a boxed, canonical, domain
@@ -7,6 +9,7 @@ import { _BoxedExpression } from './abstract-boxed-expression';
7
9
  *
8
10
  * It could be an invalid domain, in which case `isValid` is `false`.
9
11
  *
12
+ * @noInheritDoc
10
13
  */
11
14
  export declare class _BoxedDomain extends _BoxedExpression implements BoxedDomain {
12
15
  private _hash;
@@ -23,7 +26,7 @@ export declare class _BoxedDomain extends _BoxedExpression implements BoxedDomai
23
26
  isCompatible(dom: BoxedDomain | DomainLiteral, compatibility?: DomainCompatibility): boolean;
24
27
  isEqual(rhs: BoxedExpression): boolean;
25
28
  isSame(rhs: BoxedExpression): boolean;
26
- match(rhs: BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
29
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
27
30
  get head(): string;
28
31
  get domain(): BoxedDomain;
29
32
  get isFunction(): boolean;
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export declare class _BoxedFunctionDefinition implements BoxedFunctionDefinition {
3
3
  engine: IComputeEngine;
4
4
  scope: RuntimeScope;
@@ -1,6 +1,8 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
+ import { Decimal } from 'decimal.js';
3
+ import { _BoxedExpression } from './abstract-boxed-expression';
2
4
  import { Expression } from '../../math-json/math-json-format';
3
- import { BoxedExpression, BoxedFunctionDefinition, IComputeEngine, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, Substitution, ReplaceOptions, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedSubstitution, EvaluateOptions, BoxedBaseDefinition, Hold } from '../public';
5
+ import { BoxedExpression, BoxedFunctionDefinition, IComputeEngine, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, Substitution, ReplaceOptions, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedSubstitution, EvaluateOptions, BoxedBaseDefinition, Hold, Rule } from '../public';
4
6
  /**
5
7
  * A boxed function represent an expression that can be
6
8
  * represented by a function call.
@@ -12,6 +14,8 @@ import { BoxedExpression, BoxedFunctionDefinition, IComputeEngine, NOptions, Box
12
14
  * on the head. The definition contains the signature of the function,
13
15
  * and the implementation of the function.
14
16
  *
17
+ * @noInheritDoc
18
+ *
15
19
  */
16
20
  export declare class BoxedFunction extends _BoxedExpression {
17
21
  private readonly _head;
@@ -49,11 +53,11 @@ export declare class BoxedFunction extends _BoxedExpression {
49
53
  subs(sub: Substitution, options?: {
50
54
  canonical?: boolean;
51
55
  }): BoxedExpression;
52
- replace(rules: BoxedRuleSet, options?: ReplaceOptions): BoxedExpression | null;
56
+ replace(rules: BoxedRuleSet | Rule | Rule[], options?: ReplaceOptions): BoxedExpression | null;
53
57
  has(x: string | string[]): boolean;
54
58
  /** `isSame` is structural/symbolic equality */
55
59
  isSame(rhs: BoxedExpression): boolean;
56
- match(rhs: BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
60
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
57
61
  get complexity(): number | undefined;
58
62
  get baseDefinition(): BoxedBaseDefinition | undefined;
59
63
  get functionDefinition(): BoxedFunctionDefinition | undefined;
@@ -1,10 +1,12 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Decimal } from 'decimal.js';
3
3
  import { Expression } from '../../math-json/math-json-format';
4
- import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, NOptions, PatternMatchOptions, Rational, SimplifyOptions, BoxedSubstitution, EvaluateOptions } from '../public';
4
+ import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, NOptions, PatternMatchOptions, Rational, SimplifyOptions, BoxedSubstitution, EvaluateOptions, SemiBoxedExpression } from '../public';
5
5
  import { _BoxedExpression } from './abstract-boxed-expression';
6
6
  /**
7
7
  * BoxedNumber
8
+ *
9
+ * @noInheritDoc
8
10
  */
9
11
  export declare class BoxedNumber extends _BoxedExpression {
10
12
  protected readonly _value: number | Decimal | Complex | Rational;
@@ -40,7 +42,7 @@ export declare class BoxedNumber extends _BoxedExpression {
40
42
  get sgn(): -1 | 0 | 1 | undefined | null;
41
43
  isSame(rhs: BoxedExpression): boolean;
42
44
  isEqual(rhs: BoxedExpression): boolean;
43
- match(rhs: BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
45
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
44
46
  /** Compare this with another BoxedNumber.
45
47
  * `rhs` must be a BoxedNumber. Use `isEqualWithTolerance(rhs.N())`
46
48
  * if necessary.
@@ -1,22 +1,17 @@
1
- /* 0.23.1 */
2
- import { _BoxedExpression } from './abstract-boxed-expression';
3
- import { BoxedExpression, BoxedSubstitution, BoxedDomain, IComputeEngine, LatexString, Metadata, Pattern, PatternMatchOptions, SemiBoxedExpression, Substitution } from '../public';
4
- export declare class BoxedPattern extends _BoxedExpression implements Pattern {
5
- _pattern: BoxedExpression;
6
- constructor(ce: IComputeEngine, pattern: LatexString | SemiBoxedExpression, metadata?: Metadata);
7
- get hash(): number;
8
- reset(): void;
9
- get json(): Expression;
10
- get head(): string | BoxedExpression;
11
- get domain(): BoxedDomain;
12
- get isCanonical(): boolean;
13
- set isCanonical(_val: boolean);
14
- isSame(rhs: BoxedExpression): boolean;
15
- isEqual(rhs: BoxedExpression): boolean;
16
- match(expr: BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
17
- test(expr: BoxedExpression, options?: PatternMatchOptions): boolean;
18
- count(exprs: Iterable<BoxedExpression>, options?: PatternMatchOptions): number;
19
- subs(sub: Substitution, options?: {
20
- canonical: boolean;
21
- }): BoxedExpression;
22
- }
1
+ /* 0.24.0 */
2
+ import { BoxedSymbol } from './boxed-symbol';
3
+ import Complex from 'complex.js';
4
+ import Decimal from 'decimal.js';
5
+ export declare function isWildcard(expr: BoxedExpression): expr is BoxedSymbol;
6
+ export declare function wildcardName(expr: BoxedExpression): string | null;
7
+ /**
8
+ * The function attempts to match a subject expression to a
9
+ * [pattern](/compute-engine/guides/patterns-and-rules/).
10
+ *
11
+ * If the match is successful, it returns a `Substitution` indicating how to
12
+ * transform the pattern to become the subject.
13
+ *
14
+ * If the expression does not match the pattern, it returns `null`.
15
+ *
16
+ */
17
+ export declare function match(subject: BoxedExpression, pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
@@ -1,8 +1,12 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { _BoxedExpression } from './abstract-boxed-expression';
3
- import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, PatternMatchOptions, BoxedSubstitution } from '../public';
3
+ import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, PatternMatchOptions, BoxedSubstitution, SemiBoxedExpression } from '../public';
4
+ import Complex from 'complex.js';
5
+ import Decimal from 'decimal.js';
4
6
  /**
5
7
  * BoxedString
8
+ *
9
+ * @noInheritDoc
6
10
  */
7
11
  export declare class BoxedString extends _BoxedExpression {
8
12
  private readonly _string;
@@ -18,5 +22,5 @@ export declare class BoxedString extends _BoxedExpression {
18
22
  get string(): string;
19
23
  isEqual(rhs: BoxedExpression): boolean;
20
24
  isSame(rhs: BoxedExpression): boolean;
21
- match(rhs: BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
25
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
22
26
  }
@@ -1,6 +1,6 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  /**
3
- * ## THEORY OF OPERATIONS
3
+ * ### THEORY OF OPERATIONS
4
4
  *
5
5
  * - The value or domain of a constant cannot be changed.
6
6
  * - If set explicitly, the value is the source of truth: it overrides any
@@ -1,8 +1,8 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Decimal } from 'decimal.js';
3
3
  import { Expression } from '../../math-json/math-json-format';
4
4
  import { _BoxedExpression } from './abstract-boxed-expression';
5
- import { BoxedExpression, BoxedRuleSet, BoxedSymbolDefinition, IComputeEngine, EvaluateOptions, NOptions, ReplaceOptions, SimplifyOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedFunctionDefinition, BoxedBaseDefinition, DomainExpression, BoxedSubstitution } from '../public';
5
+ import { BoxedExpression, BoxedRuleSet, BoxedSymbolDefinition, IComputeEngine, EvaluateOptions, NOptions, ReplaceOptions, SimplifyOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedFunctionDefinition, BoxedBaseDefinition, DomainExpression, BoxedSubstitution, Rule, SemiBoxedExpression } from '../public';
6
6
  /**
7
7
  * BoxedSymbol
8
8
  *
@@ -15,6 +15,9 @@ import { BoxedExpression, BoxedRuleSet, BoxedSymbolDefinition, IComputeEngine, E
15
15
  * If a `BoxedFunctionDefinition`, it it a reference to a function name,
16
16
  * not a function expression, i.e. `Sin`, not `["Sin", "Pi"]`. This is used
17
17
  * for example in `["InverseFunction", "Sin"]`
18
+ *
19
+ * @noInheritDoc
20
+ *
18
21
  */
19
22
  export declare class BoxedSymbol extends _BoxedExpression {
20
23
  private _scope;
@@ -67,7 +70,7 @@ export declare class BoxedSymbol extends _BoxedExpression {
67
70
  get sgn(): -1 | 0 | 1 | undefined | null;
68
71
  has(x: string | string[]): boolean;
69
72
  isSame(rhs: BoxedExpression): boolean;
70
- match(rhs: BoxedExpression, _options?: PatternMatchOptions): BoxedSubstitution | null;
73
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
71
74
  isEqual(rhs: BoxedExpression): boolean;
72
75
  isLess(rhs: BoxedExpression): boolean | undefined;
73
76
  isLessEqual(rhs: BoxedExpression): boolean | undefined;
@@ -99,7 +102,7 @@ export declare class BoxedSymbol extends _BoxedExpression {
99
102
  simplify(options?: SimplifyOptions): BoxedExpression;
100
103
  evaluate(options?: EvaluateOptions): BoxedExpression;
101
104
  N(options?: NOptions): BoxedExpression;
102
- replace(rules: BoxedRuleSet, options?: ReplaceOptions): BoxedExpression | null;
105
+ replace(rules: BoxedRuleSet | Rule | Rule[], options?: ReplaceOptions): BoxedExpression | null;
103
106
  subs(sub: Substitution, options?: {
104
107
  canonical: boolean;
105
108
  }): BoxedExpression;
@@ -1,5 +1,7 @@
1
- /* 0.23.1 */
2
- import { BoxedExpression, IComputeEngine, EvaluateOptions, NOptions, SimplifyOptions, Metadata, BoxedDomain, BoxedSubstitution, PatternMatchOptions, BoxedBaseDefinition, BoxedFunctionDefinition } from '../public';
1
+ /* 0.24.0 */
2
+ import Decimal from 'decimal.js';
3
+ import { Expression } from '../../math-json/math-json-format';
4
+ import { BoxedExpression, IComputeEngine, EvaluateOptions, NOptions, SimplifyOptions, Metadata, BoxedDomain, BoxedSubstitution, PatternMatchOptions, BoxedBaseDefinition, BoxedFunctionDefinition, SemiBoxedExpression } from '../public';
3
5
  import { DataTypeMap, TensorDataType } from '../symbolic/tensor-fields';
4
6
  import { AbstractTensor, TensorData } from '../symbolic/tensors';
5
7
  import { _BoxedExpression } from './abstract-boxed-expression';
@@ -14,6 +16,8 @@ import { _BoxedExpression } from './abstract-boxed-expression';
14
16
  * The counterpart (expression if input is tensor, or tensor
15
17
  * if input is expression) is created lazily.
16
18
  *
19
+ * @noInheritDoc
20
+ *
17
21
  */
18
22
  export declare class BoxedTensor extends _BoxedExpression {
19
23
  private _tensor;
@@ -56,7 +60,7 @@ export declare class BoxedTensor extends _BoxedExpression {
56
60
  isSame(rhs: BoxedExpression): boolean;
57
61
  /** Mathematical equality */
58
62
  isEqual(rhs: BoxedExpression): boolean;
59
- match(rhs: BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
63
+ match(pattern: Decimal | Complex | [num: number, denom: number] | SemiBoxedExpression | BoxedExpression, options?: PatternMatchOptions): BoxedSubstitution | null;
60
64
  evaluate(options?: EvaluateOptions): BoxedExpression;
61
65
  simplify(options?: SimplifyOptions): BoxedExpression;
62
66
  N(options?: NOptions): BoxedExpression;
@@ -1,2 +1,2 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export declare function canonicalForm(expr: BoxedExpression, forms: boolean | CanonicalForm | CanonicalForm[]): BoxedExpression;
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export declare class ExpressionMap<U> implements ExpressionMapInterface<U> {
3
3
  readonly _items: Map<BoxedExpression, U>;
4
4
  constructor(source?: ExpressionMapInterface<U> | readonly (readonly [BoxedExpression, U])[]);
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export type Order = 'lex' | 'dexlex' | 'grevlex' | 'elim';
3
3
  export declare const DEFAULT_COMPLEXITY = 100000;
4
4
  /**
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Decimal } from 'decimal.js';
3
3
  import { Expression } from '../../math-json/math-json-format';
4
4
  import { BoxedExpression, IComputeEngine, Metadata, Rational } from '../public';
@@ -1,6 +1,7 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { Expression } from '../../math-json/math-json-format';
3
3
  import { BoxedExpression, IComputeEngine } from '../public';
4
+ export declare function isBoxedExpression(x: unknown): x is BoxedExpression;
4
5
  /**
5
6
  * For any numeric result, if `bignumPreferred()` is true, calculate using
6
7
  * bignums. If `bignumPreferred()` is false, calculate using machine numbers
@@ -33,11 +34,3 @@ export declare function asBigint(expr: BoxedExpression): bigint | null;
33
34
  * hoisted.
34
35
  *
35
36
  */
36
- /**
37
- * Assert that `expr` is in fact canonical.
38
- *
39
- * Called for example from within a `canonical` handler.
40
- *
41
- * To make an expression whose canonical status is unknown, canonical, call
42
- * `expr.canonical`.
43
- */
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  /**
3
3
  * Check that the number of arguments is as expected.
4
4
  *
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  export declare function isCollection(col: BoxedExpression): boolean;
3
3
  export declare function isFiniteCollection(col: BoxedExpression): boolean;
4
4
  export declare function isIndexableCollection(col: BoxedExpression): boolean;
@@ -1,4 +1,4 @@
1
- /* 0.23.1 */
1
+ /* 0.24.0 */
2
2
  import { BoxedExpression } from './public';
3
3
  export type CompiledType = boolean | number | string | object;
4
4
  type JSSource = string;