@cortex-js/compute-engine 0.9.0 → 0.11.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.
- package/dist/compute-engine.esm.js +3016 -3218
- package/dist/compute-engine.min.esm.js +2 -2
- package/dist/compute-engine.min.js +2 -2
- package/dist/math-json.esm.js +2 -2
- package/dist/math-json.min.esm.js +2 -2
- package/dist/math-json.min.js +2 -2
- package/dist/types/common/grapheme-splitter.d.ts +1 -1
- package/dist/types/common/signals.d.ts +9 -9
- package/dist/types/common/utils.d.ts +1 -1
- package/dist/types/compute-engine/assume.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/abstract-boxed-expression.d.ts +1 -2
- package/dist/types/compute-engine/boxed-expression/box.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/boxed-dictionary.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/boxed-domain.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/boxed-function-definition.d.ts +2 -2
- package/dist/types/compute-engine/boxed-expression/boxed-function.d.ts +1 -2
- package/dist/types/compute-engine/boxed-expression/boxed-number.d.ts +1 -2
- package/dist/types/compute-engine/boxed-expression/boxed-patterns.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/boxed-string.d.ts +1 -2
- package/dist/types/compute-engine/boxed-expression/boxed-symbol-definition.d.ts +33 -40
- package/dist/types/compute-engine/boxed-expression/boxed-symbol.d.ts +3 -3
- package/dist/types/compute-engine/boxed-expression/expression-map.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/order.d.ts +2 -2
- package/dist/types/compute-engine/boxed-expression/serialize.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/utils.d.ts +1 -1
- package/dist/types/compute-engine/boxed-expression/validate.d.ts +1 -1
- package/dist/types/compute-engine/compute-engine.d.ts +18 -20
- package/dist/types/compute-engine/cost-function.d.ts +1 -1
- package/dist/types/compute-engine/domain-utils.d.ts +2 -2
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-algebra.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-arithmetic.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-calculus.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-core.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-inequalities.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-logic.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-other.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-sets.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-symbols.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions-trigonometry.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/dictionary/definitions.d.ts +11 -11
- package/dist/types/compute-engine/latex-syntax/latex-syntax.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/parse.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/public.d.ts +30 -30
- package/dist/types/compute-engine/latex-syntax/serialize-number.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/serializer-style.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/serializer.d.ts +1 -1
- package/dist/types/compute-engine/latex-syntax/tokenizer.d.ts +2 -2
- package/dist/types/compute-engine/library/arithmetic-add.d.ts +1 -1
- package/dist/types/compute-engine/library/arithmetic-divide.d.ts +1 -1
- package/dist/types/compute-engine/library/arithmetic-multiply.d.ts +1 -1
- package/dist/types/compute-engine/library/arithmetic-power.d.ts +1 -1
- package/dist/types/compute-engine/library/arithmetic.d.ts +2 -2
- package/dist/types/compute-engine/library/calculus.d.ts +2 -2
- package/dist/types/compute-engine/library/collections.d.ts +2 -2
- package/dist/types/compute-engine/library/core.d.ts +2 -2
- package/dist/types/compute-engine/library/domains.d.ts +1 -1
- package/dist/types/compute-engine/library/library.d.ts +5 -5
- package/dist/types/compute-engine/library/logic.d.ts +2 -2
- package/dist/types/compute-engine/library/polynomials.d.ts +2 -2
- package/dist/types/compute-engine/library/relational-operator.d.ts +2 -2
- package/dist/types/compute-engine/library/sets.d.ts +2 -2
- package/dist/types/compute-engine/library/trigonometry.d.ts +2 -2
- package/dist/types/compute-engine/library/utils.d.ts +3 -0
- package/dist/types/compute-engine/numerics/numeric-bignum.d.ts +1 -1
- package/dist/types/compute-engine/numerics/numeric-complex.d.ts +1 -1
- package/dist/types/compute-engine/numerics/numeric.d.ts +1 -1
- package/dist/types/compute-engine/numerics/primes.d.ts +1 -1
- package/dist/types/compute-engine/numerics/rationals.d.ts +1 -1
- package/dist/types/compute-engine/public.d.ts +101 -92
- package/dist/types/compute-engine/rules.d.ts +1 -1
- package/dist/types/compute-engine/simplify-rules.d.ts +1 -1
- package/dist/types/compute-engine/solve.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/expand.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/flatten.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/negate.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/polynomials.d.ts +3 -3
- package/dist/types/compute-engine/symbolic/product.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/sum.d.ts +1 -1
- package/dist/types/compute-engine/symbolic/utils.d.ts +1 -1
- package/dist/types/compute-engine.d.ts +2 -2
- package/dist/types/math-json/math-json-format.d.ts +7 -7
- package/dist/types/math-json/utils.d.ts +1 -1
- package/dist/types/math-json.d.ts +2 -2
- package/package.json +1 -1
package/dist/math-json.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** MathJSON 0.
|
|
1
|
+
/** MathJSON 0.11.0 */
|
|
2
2
|
function isSymbolObject(expr) {
|
|
3
3
|
return expr !== null && typeof expr === 'object' && 'sym' in expr;
|
|
4
4
|
}
|
|
@@ -182,6 +182,6 @@ function mapArgs(expr, fn) {
|
|
|
182
182
|
}
|
|
183
183
|
|
|
184
184
|
// This is the root of the `math-json` package (i.e. `math-json.js` and
|
|
185
|
-
const version = '0.
|
|
185
|
+
const version = '0.11.0';
|
|
186
186
|
|
|
187
187
|
export { applyRecursively, dictionary as getDictionary, stringValue as getStringValue, head, headName, isDictionaryObject, isFunctionObject, isStringObject, isSymbolObject, mapArgs, nops, op, symbol, version };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/** MathJSON 0.
|
|
2
|
-
function n(n){return null!==n&&"object"==typeof n&&"sym"in n}function t(n){return null!==n&&"object"==typeof n&&"str"in n}function r(n){return null!==n&&"object"==typeof n&&"fn"in n}function u(n){return null!==n&&"object"==typeof n&&"dict"in n}function l(n){return null==n?null:"object"==typeof n&&"str"in n?n.str:"string"!=typeof n||n.length<2||"'"!==n[0]||"'"!==n[n.length-1]?null:n.substring(1,n.length-1)}function e(n){return null==n?null:Array.isArray(n)?n[0]:r(n)?n.fn[0]:null}function i(n){const t=e(n);return"string"==typeof t?t:""}function o(n){return null==n?null:Array.isArray(n)?n.slice(1):r(n)?n.fn.slice(1):null}function f(n,t){return null==n?null:Array.isArray(n)?n[t]??null:r(n)?n.fn[t]??null:null}function c(n){return f(n,2)}function s(n){return null==n?0:Array.isArray(n)?Math.max(0,n.length-1):r(n)?Math.max(0,n.fn.length-1):0}function y(t){if(null==t)return null;if("string"==typeof t){if(/^[+\-\.0-9]/.test(t))return null;if(t.length>=2&&"'"===t[0]&&"'"===t[t.length-1])return null}const r=n(t)?t.sym:t;return"string"!=typeof r?null:r}function a(n){const t=e(n);if("KeyValuePair"===t||"Tuple"===t||"Pair"===t){const t=l(function(n){return f(n,1)}(n));return t?[t,c(n)??"Nothing"]:null}return null}function g(n){if(null===n)return null;if("object"==typeof n&&"dict"in n)return n.dict;const t=a(n);if(t)return{[t[0]]:t[1]};if("Dictionary"===e(n)){const t={};for(let r=1;r<s(n);r++){const u=a(f(n,r));u&&(t[u[0]]=u[1])}return t}return null}function p(n,t){const r=e(n);if(null!==r)return[t(r),...(o(n)??[]).map(t)];const u=g(n);if(null!==u){const n=Object.keys(u),r={};for(const l of n)r[l]=t(u[l]);return{dict:r}}return t(n)}function h(n,t){let u=null;if(Array.isArray(n)&&(u=n),r(n)&&(u=n.fn),null===u)return[];let l=1;const e=[];for(;l<u.length;)e.push(t(u[l])),l+=1;return e}const A="0.
|
|
1
|
+
/** MathJSON 0.11.0 */
|
|
2
|
+
function n(n){return null!==n&&"object"==typeof n&&"sym"in n}function t(n){return null!==n&&"object"==typeof n&&"str"in n}function r(n){return null!==n&&"object"==typeof n&&"fn"in n}function u(n){return null!==n&&"object"==typeof n&&"dict"in n}function l(n){return null==n?null:"object"==typeof n&&"str"in n?n.str:"string"!=typeof n||n.length<2||"'"!==n[0]||"'"!==n[n.length-1]?null:n.substring(1,n.length-1)}function e(n){return null==n?null:Array.isArray(n)?n[0]:r(n)?n.fn[0]:null}function i(n){const t=e(n);return"string"==typeof t?t:""}function o(n){return null==n?null:Array.isArray(n)?n.slice(1):r(n)?n.fn.slice(1):null}function f(n,t){return null==n?null:Array.isArray(n)?n[t]??null:r(n)?n.fn[t]??null:null}function c(n){return f(n,2)}function s(n){return null==n?0:Array.isArray(n)?Math.max(0,n.length-1):r(n)?Math.max(0,n.fn.length-1):0}function y(t){if(null==t)return null;if("string"==typeof t){if(/^[+\-\.0-9]/.test(t))return null;if(t.length>=2&&"'"===t[0]&&"'"===t[t.length-1])return null}const r=n(t)?t.sym:t;return"string"!=typeof r?null:r}function a(n){const t=e(n);if("KeyValuePair"===t||"Tuple"===t||"Pair"===t){const t=l(function(n){return f(n,1)}(n));return t?[t,c(n)??"Nothing"]:null}return null}function g(n){if(null===n)return null;if("object"==typeof n&&"dict"in n)return n.dict;const t=a(n);if(t)return{[t[0]]:t[1]};if("Dictionary"===e(n)){const t={};for(let r=1;r<s(n);r++){const u=a(f(n,r));u&&(t[u[0]]=u[1])}return t}return null}function p(n,t){const r=e(n);if(null!==r)return[t(r),...(o(n)??[]).map(t)];const u=g(n);if(null!==u){const n=Object.keys(u),r={};for(const l of n)r[l]=t(u[l]);return{dict:r}}return t(n)}function h(n,t){let u=null;if(Array.isArray(n)&&(u=n),r(n)&&(u=n.fn),null===u)return[];let l=1;const e=[];for(;l<u.length;)e.push(t(u[l])),l+=1;return e}const A="0.11.0";export{p as applyRecursively,g as getDictionary,l as getStringValue,e as head,i as headName,u as isDictionaryObject,r as isFunctionObject,t as isStringObject,n as isSymbolObject,h as mapArgs,s as nops,f as op,y as symbol,A as version};
|
package/dist/math-json.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/** MathJSON 0.
|
|
2
|
-
var global,factory;global=this,factory=function(n){function t(n){return null!==n&&"object"==typeof n&&"sym"in n}function r(n){return null!==n&&"object"==typeof n&&"fn"in n}function l(n){return null==n?null:"object"==typeof n&&"str"in n?n.str:"string"!=typeof n||n.length<2||"'"!==n[0]||"'"!==n[n.length-1]?null:n.substring(1,n.length-1)}function e(n){return null==n?null:Array.isArray(n)?n[0]:r(n)?n.fn[0]:null}function u(n){return null==n?null:Array.isArray(n)?n.slice(1):r(n)?n.fn.slice(1):null}function o(n,t){var l,e;return null==n?null:Array.isArray(n)?null!==(l=n[t])&&void 0!==l?l:null:r(n)&&null!==(e=n.fn[t])&&void 0!==e?e:null}function i(n){return o(n,2)}function f(n){return null==n?0:Array.isArray(n)?Math.max(0,n.length-1):r(n)?Math.max(0,n.fn.length-1):0}function c(n){var t;const r=e(n);if("KeyValuePair"===r||"Tuple"===r||"Pair"===r){const r=l(function(n){return o(n,1)}(n));return r?[r,null!==(t=i(n))&&void 0!==t?t:"Nothing"]:null}return null}function s(n){if(null===n)return null;if("object"==typeof n&&"dict"in n)return n.dict;const t=c(n);if(t)return{[t[0]]:t[1]};if("Dictionary"===e(n)){const t={};for(let r=1;r<f(n);r++){const l=c(o(n,r));l&&(t[l[0]]=l[1])}return t}return null}n.applyRecursively=function(n,t){var r;const l=e(n);if(null!==l)return[t(l),...(null!==(r=u(n))&&void 0!==r?r:[]).map(t)];const o=s(n);if(null!==o){const n=Object.keys(o),r={};for(const l of n)r[l]=t(o[l]);return{dict:r}}return t(n)},n.getDictionary=s,n.getStringValue=l,n.head=e,n.headName=function(n){const t=e(n);return"string"==typeof t?t:""},n.isDictionaryObject=function(n){return null!==n&&"object"==typeof n&&"dict"in n},n.isFunctionObject=r,n.isStringObject=function(n){return null!==n&&"object"==typeof n&&"str"in n},n.isSymbolObject=t,n.mapArgs=function(n,t){let l=null;if(Array.isArray(n)&&(l=n),r(n)&&(l=n.fn),null===l)return[];let e=1;const u=[];for(;e<l.length;)u.push(t(l[e])),e+=1;return u},n.nops=f,n.op=o,n.symbol=function(n){if(null==n)return null;if("string"==typeof n){if(/^[+\-\.0-9]/.test(n))return null;if(n.length>=2&&"'"===n[0]&&"'"===n[n.length-1])return null}const r=t(n)?n.sym:n;return"string"!=typeof r?null:r},n.version="0.
|
|
1
|
+
/** MathJSON 0.11.0 */
|
|
2
|
+
var global,factory;global=this,factory=function(n){function t(n){return null!==n&&"object"==typeof n&&"sym"in n}function r(n){return null!==n&&"object"==typeof n&&"fn"in n}function l(n){return null==n?null:"object"==typeof n&&"str"in n?n.str:"string"!=typeof n||n.length<2||"'"!==n[0]||"'"!==n[n.length-1]?null:n.substring(1,n.length-1)}function e(n){return null==n?null:Array.isArray(n)?n[0]:r(n)?n.fn[0]:null}function u(n){return null==n?null:Array.isArray(n)?n.slice(1):r(n)?n.fn.slice(1):null}function o(n,t){var l,e;return null==n?null:Array.isArray(n)?null!==(l=n[t])&&void 0!==l?l:null:r(n)&&null!==(e=n.fn[t])&&void 0!==e?e:null}function i(n){return o(n,2)}function f(n){return null==n?0:Array.isArray(n)?Math.max(0,n.length-1):r(n)?Math.max(0,n.fn.length-1):0}function c(n){var t;const r=e(n);if("KeyValuePair"===r||"Tuple"===r||"Pair"===r){const r=l(function(n){return o(n,1)}(n));return r?[r,null!==(t=i(n))&&void 0!==t?t:"Nothing"]:null}return null}function s(n){if(null===n)return null;if("object"==typeof n&&"dict"in n)return n.dict;const t=c(n);if(t)return{[t[0]]:t[1]};if("Dictionary"===e(n)){const t={};for(let r=1;r<f(n);r++){const l=c(o(n,r));l&&(t[l[0]]=l[1])}return t}return null}n.applyRecursively=function(n,t){var r;const l=e(n);if(null!==l)return[t(l),...(null!==(r=u(n))&&void 0!==r?r:[]).map(t)];const o=s(n);if(null!==o){const n=Object.keys(o),r={};for(const l of n)r[l]=t(o[l]);return{dict:r}}return t(n)},n.getDictionary=s,n.getStringValue=l,n.head=e,n.headName=function(n){const t=e(n);return"string"==typeof t?t:""},n.isDictionaryObject=function(n){return null!==n&&"object"==typeof n&&"dict"in n},n.isFunctionObject=r,n.isStringObject=function(n){return null!==n&&"object"==typeof n&&"str"in n},n.isSymbolObject=t,n.mapArgs=function(n,t){let l=null;if(Array.isArray(n)&&(l=n),r(n)&&(l=n.fn),null===l)return[];let e=1;const u=[];for(;e<l.length;)u.push(t(l[e])),e+=1;return u},n.nops=f,n.op=o,n.symbol=function(n){if(null==n)return null;if("string"==typeof n){if(/^[+\-\.0-9]/.test(n))return null;if(n.length>=2&&"'"===n[0]&&"'"===n[n.length-1])return null}const r=t(n)?n.sym:n;return"string"!=typeof r?null:r},n.version="0.11.0",Object.defineProperty(n,"__esModule",{value:!0})},"object"==typeof exports&&"undefined"!=typeof module?factory(exports):"function"==typeof define&&define.amd?define(["exports"],factory):factory((global="undefined"!=typeof globalThis?globalThis:global||self).MathJson={});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/* 0.
|
|
2
|
-
export
|
|
3
|
-
export
|
|
4
|
-
export
|
|
1
|
+
/* 0.11.0 */
|
|
2
|
+
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');
|
|
3
|
+
export type SignalMessage = SignalCode | [SignalCode, ...any[]];
|
|
4
|
+
export type SignalOrigin = {
|
|
5
5
|
url?: string;
|
|
6
6
|
source?: string;
|
|
7
7
|
offset?: number;
|
|
@@ -9,7 +9,7 @@ export declare type SignalOrigin = {
|
|
|
9
9
|
column?: number;
|
|
10
10
|
around?: string;
|
|
11
11
|
};
|
|
12
|
-
export
|
|
12
|
+
export type Signal = {
|
|
13
13
|
severity?: 'warning' | 'error';
|
|
14
14
|
/** An error/warning code or, a code with one or more arguments specific to
|
|
15
15
|
* the signal code.
|
|
@@ -22,13 +22,13 @@ export declare type Signal = {
|
|
|
22
22
|
/** Location where the signal was raised. */
|
|
23
23
|
origin?: SignalOrigin;
|
|
24
24
|
};
|
|
25
|
-
export
|
|
25
|
+
export type ErrorSignal = Signal & {
|
|
26
26
|
severity: 'error';
|
|
27
27
|
};
|
|
28
|
-
export
|
|
28
|
+
export type WarningSignal = Signal & {
|
|
29
29
|
severity: 'warning';
|
|
30
30
|
};
|
|
31
|
-
export
|
|
31
|
+
export type WarningSignalHandler = (warnings: WarningSignal[]) => void;
|
|
32
32
|
/**
|
|
33
33
|
* The error codes can be used in an `ErrorCode` expression:
|
|
34
34
|
*
|
|
@@ -83,4 +83,4 @@ export declare type WarningSignalHandler = (warnings: WarningSignal[]) => void;
|
|
|
83
83
|
* * `base-out-of-range`: The base is expected to be between 2 and 36.
|
|
84
84
|
*
|
|
85
85
|
*/
|
|
86
|
-
export
|
|
86
|
+
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.
|
|
1
|
+
/* 0.11.0 */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { Complex } from 'complex.js';
|
|
3
3
|
import { Expression } from '../../math-json/math-json-format';
|
|
4
4
|
import { BoxedExpression, BoxedFunctionDefinition, BoxedRuleSet, BoxedSymbolDefinition, BoxedDomain, EvaluateOptions, IComputeEngine, LatexString, Metadata, NOptions, PatternMatchOptions, SemiBoxedExpression, SimplifyOptions, Substitution, RuntimeScope, DomainCompatibility, DomainLiteral, BoxedBaseDefinition, Rational, BoxedSubstitution } from '../public';
|
|
@@ -86,7 +86,6 @@ export declare abstract class AbstractBoxedExpression implements BoxedExpression
|
|
|
86
86
|
isCompatible(_dom: BoxedDomain | DomainLiteral, _kind?: DomainCompatibility): boolean;
|
|
87
87
|
get description(): string[] | undefined;
|
|
88
88
|
get url(): string | undefined;
|
|
89
|
-
get isLiteral(): boolean;
|
|
90
89
|
get wikidata(): string | undefined;
|
|
91
90
|
set wikidata(val: string | undefined);
|
|
92
91
|
get complexity(): number | undefined;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { BoxedExpression, IComputeEngine, EvaluateOptions, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, ReplaceOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, BoxedSubstitution } from '../public';
|
|
3
3
|
import { AbstractBoxedExpression } from './abstract-boxed-expression';
|
|
4
4
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { BoxedDomain, BoxedExpression, BoxedSubstitution, DomainCompatibility, DomainConstructor, DomainExpression, DomainLiteral, IComputeEngine, Metadata, PatternMatchOptions } from '../public';
|
|
3
3
|
import { AbstractBoxedExpression } from './abstract-boxed-expression';
|
|
4
4
|
/**
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
2
|
-
export declare function makeFunctionDefinition(engine: IComputeEngine, def: FunctionDefinition): BoxedFunctionDefinition;
|
|
1
|
+
/* 0.11.0 */
|
|
2
|
+
export declare function makeFunctionDefinition(engine: IComputeEngine, name: string, def: FunctionDefinition | BoxedFunctionDefinition): BoxedFunctionDefinition;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { Expression } from '../../math-json/math-json-format';
|
|
3
3
|
import { BoxedExpression, BoxedFunctionDefinition, IComputeEngine, EvaluateOptions, NOptions, BoxedRuleSet, SemiBoxedExpression, SimplifyOptions, Substitution, ReplaceOptions, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedSubstitution } from '../public';
|
|
4
4
|
/**
|
|
@@ -27,7 +27,6 @@ export declare class BoxedFunction extends AbstractBoxedExpression {
|
|
|
27
27
|
get hash(): number;
|
|
28
28
|
get isCanonical(): boolean;
|
|
29
29
|
set isCanonical(val: boolean);
|
|
30
|
-
get isLiteral(): boolean;
|
|
31
30
|
get isPure(): boolean;
|
|
32
31
|
get json(): Expression;
|
|
33
32
|
get scope(): RuntimeScope | null;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { Complex } from 'complex.js';
|
|
3
3
|
import { Expression } from '../../math-json/math-json-format';
|
|
4
4
|
import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, NOptions, PatternMatchOptions, Rational, SimplifyOptions, BoxedSubstitution } from '../public';
|
|
@@ -30,7 +30,6 @@ export declare class BoxedNumber extends AbstractBoxedExpression {
|
|
|
30
30
|
get hash(): number;
|
|
31
31
|
get head(): string;
|
|
32
32
|
get isPure(): boolean;
|
|
33
|
-
get isLiteral(): boolean;
|
|
34
33
|
get isExact(): boolean;
|
|
35
34
|
get isCanonical(): boolean;
|
|
36
35
|
set isCanonical(val: boolean);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { AbstractBoxedExpression } from './abstract-boxed-expression';
|
|
3
3
|
import { BoxedExpression, BoxedSubstitution, BoxedDomain, IComputeEngine, LatexString, Metadata, Pattern, PatternMatchOptions, SemiBoxedExpression, Substitution } from '../public';
|
|
4
4
|
export declare class BoxedPattern extends AbstractBoxedExpression implements Pattern {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { AbstractBoxedExpression } from './abstract-boxed-expression';
|
|
3
3
|
import { BoxedExpression, BoxedDomain, IComputeEngine, Metadata, PatternMatchOptions, BoxedSubstitution } from '../public';
|
|
4
4
|
/**
|
|
@@ -11,7 +11,6 @@ export declare class BoxedString extends AbstractBoxedExpression {
|
|
|
11
11
|
get json(): Expression;
|
|
12
12
|
get head(): string;
|
|
13
13
|
get isPure(): boolean;
|
|
14
|
-
get isLiteral(): boolean;
|
|
15
14
|
get isCanonical(): boolean;
|
|
16
15
|
set isCanonical(_va: boolean);
|
|
17
16
|
get domain(): BoxedDomain;
|
|
@@ -1,55 +1,46 @@
|
|
|
1
|
-
/* 0.
|
|
2
|
-
|
|
1
|
+
/* 0.11.0 */
|
|
2
|
+
/**
|
|
3
|
+
* THEORY OF OPERATIONS
|
|
4
|
+
*
|
|
5
|
+
* - The value or domain of a constant cannot be changed.
|
|
6
|
+
* - If set explicitly, the value is the source of truth: it overrides any
|
|
7
|
+
* flags.
|
|
8
|
+
* - Once the domain has been set, it can only be changed from a numeric domain
|
|
9
|
+
* to another numeric domain (some expressions may have been validated with
|
|
10
|
+
* assumptions that the domain was numeric).
|
|
11
|
+
* - When the domain is changed, the value is preserved if it is compatible
|
|
12
|
+
* with the new domain, otherwise it is reset to no value. Flags are adjusted
|
|
13
|
+
* to match the domain (discarded if not a numeric domain).
|
|
14
|
+
* - When the value is changed, the domain is unaffected. If the value is not
|
|
15
|
+
* compatible with the domain (setting a def with a numeric domain to a value
|
|
16
|
+
* of `True` for example), the value is discarded.
|
|
17
|
+
* - When getting a flag, if a value is available, it is the source of truth.
|
|
18
|
+
* Otherwise, the stored flags are (the stored flags are also set when the domain is changed)
|
|
19
|
+
*
|
|
20
|
+
*/
|
|
3
21
|
export declare class BoxedSymbolDefinitionImpl implements BoxedSymbolDefinition {
|
|
4
22
|
readonly name: string;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
private _inferedDomain;
|
|
23
|
+
readonly wikidata?: string;
|
|
24
|
+
readonly description?: string | string[];
|
|
25
|
+
readonly url?: string;
|
|
9
26
|
private _engine;
|
|
10
27
|
readonly scope: RuntimeScope | undefined;
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
private
|
|
14
|
-
private
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
private _real;
|
|
18
|
-
private _extendedReal;
|
|
19
|
-
private _complex;
|
|
20
|
-
private _extendedComplex;
|
|
21
|
-
private _imaginary;
|
|
22
|
-
private _positive;
|
|
23
|
-
private _nonPositive;
|
|
24
|
-
private _negative;
|
|
25
|
-
private _nonNegative;
|
|
26
|
-
private _zero;
|
|
27
|
-
private _notZero;
|
|
28
|
-
private _one;
|
|
29
|
-
private _negativeOne;
|
|
30
|
-
private _infinity;
|
|
31
|
-
private _NaN;
|
|
32
|
-
private _finite;
|
|
33
|
-
private _even;
|
|
34
|
-
private _odd;
|
|
35
|
-
private _prime;
|
|
36
|
-
private _composite;
|
|
28
|
+
private _defValue?;
|
|
29
|
+
private _value;
|
|
30
|
+
private _domain;
|
|
31
|
+
private _flags;
|
|
32
|
+
readonly constant: boolean;
|
|
33
|
+
readonly holdUntil: 'never' | 'simplify' | 'evaluate' | 'N';
|
|
37
34
|
private _at;
|
|
38
35
|
at?: (index: string | number) => undefined | BoxedExpression;
|
|
39
|
-
readonly constant: boolean;
|
|
40
|
-
readonly hold: boolean;
|
|
41
36
|
prototype?: BoxedFunctionDefinition;
|
|
42
37
|
self?: unknown;
|
|
43
|
-
constructor(ce: IComputeEngine, def: SymbolDefinition);
|
|
38
|
+
constructor(ce: IComputeEngine, name: string, def: SymbolDefinition);
|
|
44
39
|
reset(): void;
|
|
45
|
-
unbind(): void;
|
|
46
|
-
bind(): void;
|
|
47
40
|
get value(): BoxedExpression | undefined;
|
|
48
|
-
set value(val:
|
|
41
|
+
set value(val: SemiBoxedExpression | number | undefined);
|
|
49
42
|
get domain(): BoxedDomain | undefined;
|
|
50
43
|
set domain(domain: BoxedDomain | DomainExpression | undefined);
|
|
51
|
-
updateFlags(flags: Partial<SymbolFlags>): void;
|
|
52
|
-
setProps(props: Omit<Partial<BoxedSymbolDefinition>, 'domain' | 'value'>): void;
|
|
53
44
|
get number(): boolean | undefined;
|
|
54
45
|
set number(val: boolean | undefined);
|
|
55
46
|
get integer(): boolean | undefined;
|
|
@@ -98,4 +89,6 @@ export declare class BoxedSymbolDefinitionImpl implements BoxedSymbolDefinition
|
|
|
98
89
|
set prime(val: boolean | undefined);
|
|
99
90
|
get composite(): boolean | undefined;
|
|
100
91
|
set composite(val: boolean | undefined);
|
|
92
|
+
updateFlags(flags: Partial<SymbolFlags>): void;
|
|
101
93
|
}
|
|
94
|
+
export declare function domainToFlags(dom: BoxedDomain | undefined | null): Partial<SymbolFlags>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { AbstractBoxedExpression } from './abstract-boxed-expression';
|
|
3
3
|
import { BoxedExpression, BoxedRuleSet, BoxedSymbolDefinition, IComputeEngine, EvaluateOptions, NOptions, ReplaceOptions, SimplifyOptions, Substitution, Metadata, PatternMatchOptions, BoxedDomain, RuntimeScope, BoxedFunctionDefinition, BoxedBaseDefinition, DomainExpression, BoxedSubstitution } from '../public';
|
|
4
4
|
/**
|
|
@@ -22,6 +22,7 @@ export declare class BoxedSymbol extends AbstractBoxedExpression {
|
|
|
22
22
|
constructor(ce: IComputeEngine, name: string, options?: {
|
|
23
23
|
metadata?: Metadata;
|
|
24
24
|
canonical?: boolean;
|
|
25
|
+
def?: BoxedSymbolDefinition | BoxedFunctionDefinition;
|
|
25
26
|
});
|
|
26
27
|
get hash(): number;
|
|
27
28
|
unbind(): void;
|
|
@@ -41,7 +42,6 @@ export declare class BoxedSymbol extends AbstractBoxedExpression {
|
|
|
41
42
|
get head(): string;
|
|
42
43
|
get symbol(): string;
|
|
43
44
|
get isNothing(): boolean;
|
|
44
|
-
get isLiteral(): boolean;
|
|
45
45
|
get baseDefinition(): BoxedBaseDefinition | undefined;
|
|
46
46
|
get symbolDefinition(): BoxedSymbolDefinition | undefined;
|
|
47
47
|
get functionDefinition(): BoxedFunctionDefinition | undefined;
|
|
@@ -84,7 +84,7 @@ export declare class BoxedSymbol extends AbstractBoxedExpression {
|
|
|
84
84
|
get isComplex(): boolean | undefined;
|
|
85
85
|
get isImaginary(): boolean | undefined;
|
|
86
86
|
simplify(options?: SimplifyOptions): BoxedExpression;
|
|
87
|
-
evaluate(
|
|
87
|
+
evaluate(options?: EvaluateOptions): BoxedExpression;
|
|
88
88
|
N(options?: NOptions): BoxedExpression;
|
|
89
89
|
replace(rules: BoxedRuleSet, options?: ReplaceOptions): BoxedExpression | null;
|
|
90
90
|
subs(sub: Substitution, options?: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/* 0.
|
|
2
|
-
export
|
|
1
|
+
/* 0.11.0 */
|
|
2
|
+
export type Order = 'lex' | 'dexlex' | 'grevlex' | 'elim';
|
|
3
3
|
export declare const DEFAULT_COMPLEXITY = 100000;
|
|
4
4
|
/**
|
|
5
5
|
* Sort by higher total degree (sum of degree), if tied, sort by max degree,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { Complex } from 'complex.js';
|
|
3
3
|
import { Expression, MathJsonNumber } from '../math-json/math-json-format';
|
|
4
4
|
import { SignalMessage, WarningSignal } from '../common/signals';
|
|
5
5
|
import type { LibraryCategory, LatexDictionary, LatexDictionaryEntry, LatexString, NumberFormattingOptions, ParseLatexOptions, SerializeLatexOptions } from './latex-syntax/public';
|
|
6
|
-
import { AssumeResult, BoxedExpression, BoxedFunctionDefinition, BoxedSymbolDefinition, IComputeEngine,
|
|
6
|
+
import { AssumeResult, BoxedExpression, BoxedFunctionDefinition, BoxedSymbolDefinition, IComputeEngine, IDTable, ExpressionMapInterface, NumericMode as NumericMode, Pattern, RuntimeScope, Scope, SemiBoxedExpression, SymbolDefinition, BoxedRuleSet, Rule, JsonSerializationOptions, ComputeEngineStats, Metadata, BoxedDomain, DomainExpression, FunctionDefinition, Rational, BoxedSubstitution } from './public';
|
|
7
7
|
/**
|
|
8
8
|
*
|
|
9
9
|
* To use the CortexJS Compute Engine, create a `ComputeEngine` instance.
|
|
@@ -108,25 +108,28 @@ export declare class ComputeEngine implements IComputeEngine {
|
|
|
108
108
|
*
|
|
109
109
|
*/
|
|
110
110
|
context: RuntimeScope | null;
|
|
111
|
+
strict: boolean;
|
|
111
112
|
/** Absolute time beyond which evaluation should not proceed.
|
|
112
113
|
* @internal
|
|
113
114
|
*/
|
|
114
115
|
deadline?: number;
|
|
115
116
|
/**
|
|
116
|
-
* Return
|
|
117
|
+
* Return identifier tables suitable for the specified categories, or `"all"`
|
|
117
118
|
* for all categories (`"arithmetic"`, `"algebra"`, etc...).
|
|
118
119
|
*
|
|
119
|
-
*
|
|
120
|
-
* expression should be interpreted, i.e. how to evaluate and
|
|
120
|
+
* An identifier table defines how the symbols and function names in a
|
|
121
|
+
* MathJSON expression should be interpreted, i.e. how to evaluate and
|
|
122
|
+
* manipulate them.
|
|
121
123
|
*
|
|
122
124
|
*/
|
|
123
|
-
static
|
|
125
|
+
static getStandardLibrary(categories?: LibraryCategory[] | LibraryCategory | 'all'): Readonly<IDTable>[];
|
|
124
126
|
/**
|
|
125
127
|
* Construct a new `ComputeEngine` instance.
|
|
126
128
|
*
|
|
127
|
-
*
|
|
128
|
-
* the
|
|
129
|
-
*
|
|
129
|
+
* Identifier tables define functions and symbols (in `options.ids`).
|
|
130
|
+
* If no table is provided the standard library is used (`ComputeEngine.getStandardLibrary()`)
|
|
131
|
+
*
|
|
132
|
+
* The LaTeX syntax dictionary is defined in `options.latexDictionary`.
|
|
130
133
|
*
|
|
131
134
|
* The order of the dictionaries matter: the definitions from the later ones
|
|
132
135
|
* override the definitions from earlier ones. The first dictionary should
|
|
@@ -148,12 +151,11 @@ export declare class ComputeEngine implements IComputeEngine {
|
|
|
148
151
|
* be a variable in this domain. **Default** `ExtendedRealNumber`
|
|
149
152
|
*/
|
|
150
153
|
constructor(options?: {
|
|
151
|
-
symbolTables?: Readonly<SymbolTable>[];
|
|
152
|
-
latexDictionary?: readonly LatexDictionaryEntry[];
|
|
153
154
|
numericMode?: NumericMode;
|
|
154
155
|
numericPrecision?: number;
|
|
156
|
+
ids?: Readonly<IDTable>[];
|
|
157
|
+
latexDictionary?: readonly LatexDictionaryEntry[];
|
|
155
158
|
tolerance?: number;
|
|
156
|
-
assumptions?: (LatexString | Expression)[];
|
|
157
159
|
defaultDomain?: string;
|
|
158
160
|
});
|
|
159
161
|
/** After the configuration of the engine has changed, clear the caches
|
|
@@ -243,8 +245,8 @@ export declare class ComputeEngine implements IComputeEngine {
|
|
|
243
245
|
/**
|
|
244
246
|
* Add (or replace) a definition for a symbol in the current scope.
|
|
245
247
|
*/
|
|
246
|
-
defineSymbol(def: SymbolDefinition): BoxedSymbolDefinition;
|
|
247
|
-
defineFunction(def: FunctionDefinition): BoxedFunctionDefinition;
|
|
248
|
+
defineSymbol(name: string, def: SymbolDefinition): BoxedSymbolDefinition;
|
|
249
|
+
defineFunction(name: string, def: FunctionDefinition): BoxedFunctionDefinition;
|
|
248
250
|
/**
|
|
249
251
|
*
|
|
250
252
|
* Create a new scope and add it to the top of the scope stack
|
|
@@ -253,16 +255,12 @@ export declare class ComputeEngine implements IComputeEngine {
|
|
|
253
255
|
* etc... for this scope
|
|
254
256
|
*
|
|
255
257
|
*/
|
|
256
|
-
pushScope(
|
|
257
|
-
symbolTable?: Readonly<SymbolTable> | Readonly<SymbolTable>[];
|
|
258
|
-
assumptions?: (LatexString | Expression)[];
|
|
259
|
-
scope?: Partial<Scope>;
|
|
260
|
-
}): void;
|
|
258
|
+
pushScope(ids?: Readonly<IDTable> | Readonly<IDTable>[], scope?: Partial<Scope>): void;
|
|
261
259
|
/** Remove the topmost scope from the scope stack.
|
|
262
260
|
*/
|
|
263
261
|
popScope(): void;
|
|
264
262
|
set(identifiers: {
|
|
265
|
-
[identifier: string]: SemiBoxedExpression;
|
|
263
|
+
[identifier: string]: SemiBoxedExpression | null;
|
|
266
264
|
}): void;
|
|
267
265
|
let(identifiers: {
|
|
268
266
|
[identifier: string]: SymbolDefinition | FunctionDefinition;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { Decimal } from 'decimal.js';
|
|
3
3
|
import { BoxedExpression } from './public';
|
|
4
4
|
/** Quickly determine the numeric domain of a number or constant
|
|
@@ -10,7 +10,7 @@ export declare function inferNumericDomain(value: number | Decimal | Complex | [
|
|
|
10
10
|
* Simple description of a numeric domain as a base domain, a min and
|
|
11
11
|
* max value, possibly open ends, and some excluded values.
|
|
12
12
|
*/
|
|
13
|
-
export
|
|
13
|
+
export type NumericDomainInfo = {
|
|
14
14
|
domain?: string;
|
|
15
15
|
min?: number;
|
|
16
16
|
max?: number;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_ALGEBRA: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_ARITHMETIC: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_CALCULUS: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_CORE: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_INEQUALITIES: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_LOGIC: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_OTHERS: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_SETS: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_SYMBOLS: LatexDictionary;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
export declare const DEFINITIONS_TRIGONOMETRY: LatexDictionary;
|
|
@@ -1,46 +1,46 @@
|
|
|
1
|
-
/* 0.
|
|
1
|
+
/* 0.11.0 */
|
|
2
2
|
import { WarningSignal } from '../../../common/signals';
|
|
3
|
-
export
|
|
3
|
+
export type CommonEntry = {
|
|
4
4
|
name?: string;
|
|
5
5
|
serialize: SerializeHandler | LatexString;
|
|
6
6
|
};
|
|
7
|
-
export
|
|
7
|
+
export type SymbolEntry = CommonEntry & {
|
|
8
8
|
kind: 'symbol';
|
|
9
9
|
precedence: number;
|
|
10
10
|
parse: SymbolParseHandler;
|
|
11
11
|
};
|
|
12
|
-
export
|
|
12
|
+
export type FunctionEntry = CommonEntry & {
|
|
13
13
|
kind: 'function';
|
|
14
14
|
parse: FunctionParseHandler;
|
|
15
15
|
};
|
|
16
|
-
export
|
|
16
|
+
export type MatchfixEntry = CommonEntry & {
|
|
17
17
|
kind: 'matchfix';
|
|
18
18
|
openDelimiter: Delimiter | LatexToken[];
|
|
19
19
|
closeDelimiter: Delimiter | LatexToken[];
|
|
20
20
|
parse: MatchfixParseHandler;
|
|
21
21
|
};
|
|
22
|
-
export
|
|
22
|
+
export type InfixEntry = CommonEntry & {
|
|
23
23
|
kind: 'infix';
|
|
24
24
|
associativity: 'right' | 'left' | 'non' | 'both';
|
|
25
25
|
precedence: number;
|
|
26
26
|
parse: InfixParseHandler;
|
|
27
27
|
};
|
|
28
|
-
export
|
|
28
|
+
export type PrefixEntry = CommonEntry & {
|
|
29
29
|
kind: 'prefix';
|
|
30
30
|
precedence: number;
|
|
31
31
|
parse: PrefixParseHandler;
|
|
32
32
|
};
|
|
33
|
-
export
|
|
33
|
+
export type PostfixEntry = CommonEntry & {
|
|
34
34
|
kind: 'postfix';
|
|
35
35
|
precedence: number;
|
|
36
36
|
parse: PostfixParseHandler;
|
|
37
37
|
};
|
|
38
|
-
export
|
|
38
|
+
export type EnvironmentEntry = CommonEntry & {
|
|
39
39
|
kind: 'environment';
|
|
40
40
|
parse: EnvironmentParseHandler;
|
|
41
41
|
};
|
|
42
|
-
export
|
|
43
|
-
export
|
|
42
|
+
export type IndexedLatexDictionaryEntry = FunctionEntry | SymbolEntry | MatchfixEntry | InfixEntry | PrefixEntry | PostfixEntry | EnvironmentEntry;
|
|
43
|
+
export type IndexedLatexDictionary = {
|
|
44
44
|
lookahead: number;
|
|
45
45
|
name: Map<string, IndexedLatexDictionaryEntry>;
|
|
46
46
|
function: Map<string, FunctionEntry[]>;
|