@mojir/lits 2.1.10 → 2.1.12

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.
@@ -3,7 +3,7 @@ export declare const api: {
3
3
  readonly collection: readonly ["filter", "map", "reduce", "reduce-right", "reductions", "count", "get", "get-in", "contains?", "assoc", "assoc-in", "++", "not-empty", "every?", "not-every?", "any?", "not-any?", "update", "update-in"];
4
4
  readonly array: readonly ["range", "repeat", "flatten", "mapcat"];
5
5
  readonly sequence: readonly ["nth", "push", "pop", "unshift", "shift", "slice", "splice", "position", "index-of", "last-index-of", "some", "reverse", "first", "second", "last", "rest", "next", "take", "take-last", "take-while", "drop", "drop-last", "drop-while", "sort", "sort-by", "distinct", "remove", "remove-at", "split-at", "split-with", "frequencies", "group-by", "partition", "partition-all", "partition-by", "starts-with?", "ends-with?", "interleave", "interpose"];
6
- readonly math: readonly ["+", "-", "*", "/", "~", "mod", "rem", "quot", "inc", "dec", "sqrt", "cbrt", "^", "round", "trunc", "floor", "ceil", "min", "max", "abs", "sign", "ln", "log2", "log10", "sin", "cos", "tan", "asin", "acos", "atan", "sinh", "cosh", "tanh", "asinh", "acosh", "atanh"];
6
+ readonly math: readonly ["+", "-", "*", "/", "mod", "rem", "quot", "inc", "dec", "sqrt", "cbrt", "^", "round", "trunc", "floor", "ceil", "min", "max", "abs", "sign", "ln", "log2", "log10", "sin", "cos", "tan", "asin", "acos", "atan", "sinh", "cosh", "tanh", "asinh", "acosh", "atanh", "to-rad", "to-deg"];
7
7
  readonly functional: readonly ["|>", "apply", "identity", "comp", "constantly", "juxt", "complement", "every-pred", "some-pred", "fnull"];
8
8
  readonly misc: readonly ["≠", "=", "<", ">", "≤", "≥", "!", "write!", "iso-date->epoch", "epoch->iso-date", "boolean", "compare", "identical?", "json-parse", "json-stringify"];
9
9
  readonly object: readonly ["dissoc", "keys", "vals", "entries", "find", "merge", "merge-with", "zipmap", "select-keys"];
@@ -15,7 +15,7 @@ export declare const api: {
15
15
  readonly grid: readonly ["grid:every?", "grid:some?", "grid:every-row?", "grid:some-row?", "grid:every-col?", "grid:some-col?", "grid:row", "grid:col", "grid:shape", "grid:fill", "grid:generate", "grid:reshape", "grid:transpose", "grid:flip-h", "grid:flip-v", "grid:rotate", "grid:reverse-rows", "grid:reverse-cols", "grid:slice", "grid:slice-rows", "grid:slice-cols", "grid:splice-rows", "grid:splice-cols", "grid:concat-rows", "grid:concat-cols", "grid:map", "grid:mapi", "grid:reduce", "grid:reducei", "grid:push-rows", "grid:unshift-rows", "grid:pop-row", "grid:shift-row", "grid:push-cols", "grid:unshift-cols", "grid:pop-col", "grid:shift-col", "grid:from-array"];
16
16
  readonly matrix: readonly ["mat:mul", "mat:det", "mat:inv", "mat:adj", "mat:cofactor", "mat:minor", "mat:trace", "mat:symmetric?", "mat:triangular?", "mat:upper-triangular?", "mat:lower-triangular?", "mat:diagonal?", "mat:square?", "mat:orthogonal?", "mat:identity?", "mat:invertible?", "mat:hilbert", "mat:vandermonde", "mat:band", "mat:banded?", "mat:rank", "mat:frobenius-norm", "mat:1-norm", "mat:inf-norm", "mat:max-norm"];
17
17
  readonly vector: readonly ["vec:monotonic?", "vec:strictly-monotonic?", "vec:increasing?", "vec:decreasing?", "vec:strictly-increasing?", "vec:strictly-decreasing?", "vec:median", "vec:mode", "vec:min-index", "vec:max-index", "vec:sort-indices", "vec:count-values", "vec:linspace", "vec:ones", "vec:zeros", "vec:fill", "vec:generate", "vec:cumsum", "vec:cumprod", "vec:quartiles", "vec:percentile", "vec:quantile", "vec:histogram", "vec:ecdf", "vec:outliers?", "vec:outliers", "vec:bincount", "vec:winsorize", "vec:mse", "vec:mae", "vec:rmse", "vec:smape", "vec:mean", "vec:moving-mean", "vec:centered-moving-mean", "vec:running-mean", "vec:median", "vec:moving-median", "vec:centered-moving-median", "vec:running-median", "vec:variance", "vec:moving-variance", "vec:centered-moving-variance", "vec:running-variance", "vec:sample-variance", "vec:moving-sample-variance", "vec:centered-moving-sample-variance", "vec:running-sample-variance", "vec:sum", "vec:moving-sum", "vec:centered-moving-sum", "vec:running-sum", "vec:prod", "vec:moving-prod", "vec:centered-moving-prod", "vec:running-prod", "vec:min", "vec:moving-min", "vec:centered-moving-min", "vec:running-min", "vec:max", "vec:moving-max", "vec:centered-moving-max", "vec:running-max", "vec:stdev", "vec:moving-stdev", "vec:centered-moving-stdev", "vec:running-stdev", "vec:sample-stdev", "vec:moving-sample-stdev", "vec:centered-moving-sample-stdev", "vec:running-sample-stdev", "vec:iqr", "vec:moving-iqr", "vec:centered-moving-iqr", "vec:running-iqr", "vec:span", "vec:moving-span", "vec:centered-moving-span", "vec:running-span", "vec:geometric-mean", "vec:moving-geometric-mean", "vec:centered-moving-geometric-mean", "vec:running-geometric-mean", "vec:harmonic-mean", "vec:moving-harmonic-mean", "vec:centered-moving-harmonic-mean", "vec:running-harmonic-mean", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness", "vec:sample-skewness", "vec:moving-sample-skewness", "vec:centered-moving-sample-skewness", "vec:running-sample-skewness", "vec:kurtosis", "vec:moving-kurtosis", "vec:centered-moving-kurtosis", "vec:running-kurtosis", "vec:sample-kurtosis", "vec:moving-sample-kurtosis", "vec:centered-moving-sample-kurtosis", "vec:running-sample-kurtosis", "vec:excess-kurtosis", "vec:moving-excess-kurtosis", "vec:centered-moving-excess-kurtosis", "vec:running-excess-kurtosis", "vec:sample-excess-kurtosis", "vec:moving-sample-excess-kurtosis", "vec:centered-moving-sample-excess-kurtosis", "vec:running-sample-excess-kurtosis", "vec:rms", "vec:moving-rms", "vec:centered-moving-rms", "vec:running-rms", "vec:mad", "vec:moving-mad", "vec:centered-moving-mad", "vec:running-mad", "vec:medad", "vec:moving-medad", "vec:centered-moving-medad", "vec:running-medad", "vec:gini-coefficient", "vec:moving-gini-coefficient", "vec:centered-moving-gini-coefficient", "vec:running-gini-coefficient", "vec:entropy", "vec:moving-entropy", "vec:centered-moving-entropy", "vec:running-entropy", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness"];
18
- readonly linAlg: readonly ["lin:reflect", "lin:refract", "lin:lerp", "lin:rotate2d", "lin:rotate3d", "lin:dot", "lin:cross", "lin:normalize-minmax", "lin:normalize-zscore", "lin:normalize-robust", "lin:normalize-l1", "lin:normalize-l2", "lin:normalize-log", "lin:angle", "lin:projection", "lin:orthogonal?", "lin:parallel?", "lin:collinear?", "lin:cosine-similarity", "lin:euclidean-distance", "lin:euclidean-norm", "lin:manhattan-distance", "lin:manhattan-norm", "lin:hamming-distance", "lin:hamming-norm", "lin:chebyshev-distance", "lin:chebyshev-norm", "lin:minkowski-distance", "lin:minkowski-norm", "lin:cov", "lin:corr", "lin:spearman-corr", "lin:pearson-corr", "lin:kendall-tau", "lin:autocorrelation", "lin:cross-correlation", "lin:rref", "lin:solve"];
18
+ readonly linAlg: readonly ["lin:reflect", "lin:refract", "lin:lerp", "lin:rotate2d", "lin:rotate3d", "lin:dot", "lin:cross", "lin:normalize-minmax", "lin:normalize-zscore", "lin:normalize-robust", "lin:normalize-l1", "lin:normalize-l2", "lin:normalize-log", "lin:angle", "lin:projection", "lin:orthogonal?", "lin:parallel?", "lin:collinear?", "lin:cosine-similarity", "lin:euclidean-distance", "lin:euclidean-norm", "lin:manhattan-distance", "lin:manhattan-norm", "lin:hamming-distance", "lin:hamming-norm", "lin:chebyshev-distance", "lin:chebyshev-norm", "lin:minkowski-distance", "lin:minkowski-norm", "lin:cov", "lin:corr", "lin:spearman-corr", "lin:pearson-corr", "lin:kendall-tau", "lin:autocorrelation", "lin:cross-correlation", "lin:rref", "lin:solve", "lin:to-polar", "lin:from-polar"];
19
19
  readonly numberTheory: readonly ["nth:abundant-seq", "nth:abundant-nth", "nth:abundant-take-while", "nth:abundant?", "nth:bell-seq", "nth:bell-nth", "nth:bell-take-while", "nth:bell?", "nth:catalan-seq", "nth:catalan-nth", "nth:catalan-take-while", "nth:catalan?", "nth:composite-seq", "nth:composite-nth", "nth:composite-take-while", "nth:composite?", "nth:factorial-seq", "nth:factorial-nth", "nth:factorial-take-while", "nth:factorial?", "nth:fibonacci-seq", "nth:fibonacci-nth", "nth:fibonacci-take-while", "nth:fibonacci?", "nth:geometric-seq", "nth:geometric-nth", "nth:geometric-take-while", "nth:geometric?", "nth:golomb-seq", "nth:golomb-nth", "nth:golomb-take-while", "nth:golomb?", "nth:happy-seq", "nth:happy-nth", "nth:happy-take-while", "nth:happy?", "nth:look-and-say-seq", "nth:look-and-say-nth", "nth:look-and-say-take-while", "nth:look-and-say?", "nth:lucas-seq", "nth:lucas-nth", "nth:lucas-take-while", "nth:lucas?", "nth:lucky-seq", "nth:lucky-nth", "nth:lucky-take-while", "nth:lucky?", "nth:mersenne-seq", "nth:mersenne-nth", "nth:mersenne-take-while", "nth:mersenne?", "nth:padovan-seq", "nth:padovan-nth", "nth:padovan-take-while", "nth:padovan?", "nth:partition-seq", "nth:partition-nth", "nth:partition-take-while", "nth:partition?", "nth:pell-seq", "nth:pell-nth", "nth:pell-take-while", "nth:pell?", "nth:perfect-seq", "nth:perfect-nth", "nth:perfect-take-while", "nth:perfect?", "nth:perfect-cube-seq", "nth:perfect-cube-nth", "nth:perfect-cube-take-while", "nth:perfect-cube?", "nth:perfect-power-seq", "nth:perfect-power-nth", "nth:perfect-power-take-while", "nth:perfect-power?", "nth:perfect-square-seq", "nth:perfect-square-nth", "nth:perfect-square-take-while", "nth:perfect-square?", "nth:polygonal-seq", "nth:polygonal-nth", "nth:polygonal-take-while", "nth:polygonal?", "nth:prime-seq", "nth:prime-nth", "nth:prime-take-while", "nth:prime?", "nth:recaman-seq", "nth:recaman-nth", "nth:recaman-take-while", "nth:recaman?", "nth:sylvester-seq", "nth:sylvester-nth", "nth:sylvester-take-while", "nth:sylvester?", "nth:thue-morse-seq", "nth:thue-morse-nth", "nth:thue-morse-take-while", "nth:thue-morse?", "nth:tribonacci-seq", "nth:tribonacci-nth", "nth:tribonacci-take-while", "nth:tribonacci?", "nth:collatz-seq", "nth:juggler-seq", "nth:bernoulli-seq", "nth:bernoulli-take-while", "nth:bernoulli-nth", "nth:combinations", "nth:count-combinations", "nth:derangements", "nth:count-derangements", "nth:divisors", "nth:count-divisors", "nth:proper-divisors", "nth:count-proper-divisors", "nth:prime-factors", "nth:count-prime-factors", "nth:distinct-prime-factors", "nth:count-distinct-prime-factors", "nth:factorial", "nth:partitions", "nth:count-partitions", "nth:permutations", "nth:count-permutations", "nth:power-set", "nth:count-power-set", "nth:coprime?", "nth:divisible-by?", "nth:gcd", "nth:lcm", "nth:multinomial", "nth:amicable?", "nth:euler-totient", "nth:mobius", "nth:mertens", "nth:sigma", "nth:carmichael-lambda", "nth:cartesian-product", "nth:perfect-power", "nth:mod-exp", "nth:mod-inv", "nth:extended-gcd", "nth:chinese-remainder", "nth:stirling-first", "nth:stirling-second"];
20
20
  readonly random: readonly ["!:random", "!:random-int", "!:random-int-inclusive", "!:random-float", "!:random-boolean", "!:random-item", "!:random-sample", "!:random-sample-unique", "!:shuffle", "!:random-normal", "!:random-exponential", "!:random-binomial", "!:random-poisson", "!:random-gamma", "!:random-pareto", "!:uuid", "!:random-char", "!:random-string", "!:random-id", "!:random-color"];
21
21
  readonly shorthand: ["-short-regexp", "-short-fn"];
@@ -44,7 +44,7 @@ export type NormalExpressionName = CollectionApiName | ArrayApiName | SequenceAp
44
44
  export type FunctionName = NormalExpressionName | SpecialExpressionsApiName;
45
45
  export type ShorthandName = typeof api.shorthand[number];
46
46
  export type DatatypeName = typeof api.datatype[number];
47
- declare const apiNames: readonly ["filter", "map", "reduce", "reduce-right", "reductions", "count", "get", "get-in", "contains?", "assoc", "assoc-in", "++", "not-empty", "every?", "not-every?", "any?", "not-any?", "update", "update-in", "range", "repeat", "flatten", "mapcat", "nth", "push", "pop", "unshift", "shift", "slice", "splice", "position", "index-of", "last-index-of", "some", "reverse", "first", "second", "last", "rest", "next", "take", "take-last", "take-while", "drop", "drop-last", "drop-while", "sort", "sort-by", "distinct", "remove", "remove-at", "split-at", "split-with", "frequencies", "group-by", "partition", "partition-all", "partition-by", "starts-with?", "ends-with?", "interleave", "interpose", "+", "-", "*", "/", "~", "mod", "rem", "quot", "inc", "dec", "sqrt", "cbrt", "^", "round", "trunc", "floor", "ceil", "min", "max", "abs", "sign", "ln", "log2", "log10", "sin", "cos", "tan", "asin", "acos", "atan", "sinh", "cosh", "tanh", "asinh", "acosh", "atanh", "|>", "apply", "identity", "comp", "constantly", "juxt", "complement", "every-pred", "some-pred", "fnull", "≠", "=", "<", ">", "≤", "≥", "!", "write!", "iso-date->epoch", "epoch->iso-date", "boolean", "compare", "identical?", "json-parse", "json-stringify", "dissoc", "keys", "vals", "entries", "find", "merge", "merge-with", "zipmap", "select-keys", "boolean?", "null?", "number?", "string?", "function?", "integer?", "array?", "object?", "coll?", "seq?", "regexp?", "zero?", "pos?", "neg?", "even?", "odd?", "finite?", "nan?", "negative-infinity?", "positive-infinity?", "false?", "true?", "empty?", "not-empty?", "vector?", "grid?", "matrix?", "regexp", "match", "replace", "replace-all", "string-repeat", "str", "number", "lower-case", "upper-case", "trim", "trim-left", "trim-right", "pad-left", "pad-right", "split", "split-lines", "template", "to-char-code", "from-char-code", "encode-base64", "decode-base64", "encode-uri-component", "decode-uri-component", "join", "capitalize", "blank?", "<<", ">>", ">>>", "bit-not", "&", "bit-and-not", "|", "xor", "bit-flip", "bit-clear", "bit-set", "bit-test", "assert", "assert=", "assert!=", "assert-gt", "assert-lt", "assert-gte", "assert-lte", "assert-true", "assert-false", "assert-truthy", "assert-falsy", "assert-null", "assert-throws", "assert-throws-error", "assert-not-throws", "mat:mul", "mat:det", "mat:inv", "mat:adj", "mat:cofactor", "mat:minor", "mat:trace", "mat:symmetric?", "mat:triangular?", "mat:upper-triangular?", "mat:lower-triangular?", "mat:diagonal?", "mat:square?", "mat:orthogonal?", "mat:identity?", "mat:invertible?", "mat:hilbert", "mat:vandermonde", "mat:band", "mat:banded?", "mat:rank", "mat:frobenius-norm", "mat:1-norm", "mat:inf-norm", "mat:max-norm", "vec:monotonic?", "vec:strictly-monotonic?", "vec:increasing?", "vec:decreasing?", "vec:strictly-increasing?", "vec:strictly-decreasing?", "vec:median", "vec:mode", "vec:min-index", "vec:max-index", "vec:sort-indices", "vec:count-values", "vec:linspace", "vec:ones", "vec:zeros", "vec:fill", "vec:generate", "vec:cumsum", "vec:cumprod", "vec:quartiles", "vec:percentile", "vec:quantile", "vec:histogram", "vec:ecdf", "vec:outliers?", "vec:outliers", "vec:bincount", "vec:winsorize", "vec:mse", "vec:mae", "vec:rmse", "vec:smape", "vec:mean", "vec:moving-mean", "vec:centered-moving-mean", "vec:running-mean", "vec:median", "vec:moving-median", "vec:centered-moving-median", "vec:running-median", "vec:variance", "vec:moving-variance", "vec:centered-moving-variance", "vec:running-variance", "vec:sample-variance", "vec:moving-sample-variance", "vec:centered-moving-sample-variance", "vec:running-sample-variance", "vec:sum", "vec:moving-sum", "vec:centered-moving-sum", "vec:running-sum", "vec:prod", "vec:moving-prod", "vec:centered-moving-prod", "vec:running-prod", "vec:min", "vec:moving-min", "vec:centered-moving-min", "vec:running-min", "vec:max", "vec:moving-max", "vec:centered-moving-max", "vec:running-max", "vec:stdev", "vec:moving-stdev", "vec:centered-moving-stdev", "vec:running-stdev", "vec:sample-stdev", "vec:moving-sample-stdev", "vec:centered-moving-sample-stdev", "vec:running-sample-stdev", "vec:iqr", "vec:moving-iqr", "vec:centered-moving-iqr", "vec:running-iqr", "vec:span", "vec:moving-span", "vec:centered-moving-span", "vec:running-span", "vec:geometric-mean", "vec:moving-geometric-mean", "vec:centered-moving-geometric-mean", "vec:running-geometric-mean", "vec:harmonic-mean", "vec:moving-harmonic-mean", "vec:centered-moving-harmonic-mean", "vec:running-harmonic-mean", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness", "vec:sample-skewness", "vec:moving-sample-skewness", "vec:centered-moving-sample-skewness", "vec:running-sample-skewness", "vec:kurtosis", "vec:moving-kurtosis", "vec:centered-moving-kurtosis", "vec:running-kurtosis", "vec:sample-kurtosis", "vec:moving-sample-kurtosis", "vec:centered-moving-sample-kurtosis", "vec:running-sample-kurtosis", "vec:excess-kurtosis", "vec:moving-excess-kurtosis", "vec:centered-moving-excess-kurtosis", "vec:running-excess-kurtosis", "vec:sample-excess-kurtosis", "vec:moving-sample-excess-kurtosis", "vec:centered-moving-sample-excess-kurtosis", "vec:running-sample-excess-kurtosis", "vec:rms", "vec:moving-rms", "vec:centered-moving-rms", "vec:running-rms", "vec:mad", "vec:moving-mad", "vec:centered-moving-mad", "vec:running-mad", "vec:medad", "vec:moving-medad", "vec:centered-moving-medad", "vec:running-medad", "vec:gini-coefficient", "vec:moving-gini-coefficient", "vec:centered-moving-gini-coefficient", "vec:running-gini-coefficient", "vec:entropy", "vec:moving-entropy", "vec:centered-moving-entropy", "vec:running-entropy", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness", "lin:reflect", "lin:refract", "lin:lerp", "lin:rotate2d", "lin:rotate3d", "lin:dot", "lin:cross", "lin:normalize-minmax", "lin:normalize-zscore", "lin:normalize-robust", "lin:normalize-l1", "lin:normalize-l2", "lin:normalize-log", "lin:angle", "lin:projection", "lin:orthogonal?", "lin:parallel?", "lin:collinear?", "lin:cosine-similarity", "lin:euclidean-distance", "lin:euclidean-norm", "lin:manhattan-distance", "lin:manhattan-norm", "lin:hamming-distance", "lin:hamming-norm", "lin:chebyshev-distance", "lin:chebyshev-norm", "lin:minkowski-distance", "lin:minkowski-norm", "lin:cov", "lin:corr", "lin:spearman-corr", "lin:pearson-corr", "lin:kendall-tau", "lin:autocorrelation", "lin:cross-correlation", "lin:rref", "lin:solve", "grid:every?", "grid:some?", "grid:every-row?", "grid:some-row?", "grid:every-col?", "grid:some-col?", "grid:row", "grid:col", "grid:shape", "grid:fill", "grid:generate", "grid:reshape", "grid:transpose", "grid:flip-h", "grid:flip-v", "grid:rotate", "grid:reverse-rows", "grid:reverse-cols", "grid:slice", "grid:slice-rows", "grid:slice-cols", "grid:splice-rows", "grid:splice-cols", "grid:concat-rows", "grid:concat-cols", "grid:map", "grid:mapi", "grid:reduce", "grid:reducei", "grid:push-rows", "grid:unshift-rows", "grid:pop-row", "grid:shift-row", "grid:push-cols", "grid:unshift-cols", "grid:pop-col", "grid:shift-col", "grid:from-array", "nth:abundant-seq", "nth:abundant-nth", "nth:abundant-take-while", "nth:abundant?", "nth:bell-seq", "nth:bell-nth", "nth:bell-take-while", "nth:bell?", "nth:catalan-seq", "nth:catalan-nth", "nth:catalan-take-while", "nth:catalan?", "nth:composite-seq", "nth:composite-nth", "nth:composite-take-while", "nth:composite?", "nth:factorial-seq", "nth:factorial-nth", "nth:factorial-take-while", "nth:factorial?", "nth:fibonacci-seq", "nth:fibonacci-nth", "nth:fibonacci-take-while", "nth:fibonacci?", "nth:geometric-seq", "nth:geometric-nth", "nth:geometric-take-while", "nth:geometric?", "nth:golomb-seq", "nth:golomb-nth", "nth:golomb-take-while", "nth:golomb?", "nth:happy-seq", "nth:happy-nth", "nth:happy-take-while", "nth:happy?", "nth:look-and-say-seq", "nth:look-and-say-nth", "nth:look-and-say-take-while", "nth:look-and-say?", "nth:lucas-seq", "nth:lucas-nth", "nth:lucas-take-while", "nth:lucas?", "nth:lucky-seq", "nth:lucky-nth", "nth:lucky-take-while", "nth:lucky?", "nth:mersenne-seq", "nth:mersenne-nth", "nth:mersenne-take-while", "nth:mersenne?", "nth:padovan-seq", "nth:padovan-nth", "nth:padovan-take-while", "nth:padovan?", "nth:partition-seq", "nth:partition-nth", "nth:partition-take-while", "nth:partition?", "nth:pell-seq", "nth:pell-nth", "nth:pell-take-while", "nth:pell?", "nth:perfect-seq", "nth:perfect-nth", "nth:perfect-take-while", "nth:perfect?", "nth:perfect-cube-seq", "nth:perfect-cube-nth", "nth:perfect-cube-take-while", "nth:perfect-cube?", "nth:perfect-power-seq", "nth:perfect-power-nth", "nth:perfect-power-take-while", "nth:perfect-power?", "nth:perfect-square-seq", "nth:perfect-square-nth", "nth:perfect-square-take-while", "nth:perfect-square?", "nth:polygonal-seq", "nth:polygonal-nth", "nth:polygonal-take-while", "nth:polygonal?", "nth:prime-seq", "nth:prime-nth", "nth:prime-take-while", "nth:prime?", "nth:recaman-seq", "nth:recaman-nth", "nth:recaman-take-while", "nth:recaman?", "nth:sylvester-seq", "nth:sylvester-nth", "nth:sylvester-take-while", "nth:sylvester?", "nth:thue-morse-seq", "nth:thue-morse-nth", "nth:thue-morse-take-while", "nth:thue-morse?", "nth:tribonacci-seq", "nth:tribonacci-nth", "nth:tribonacci-take-while", "nth:tribonacci?", "nth:collatz-seq", "nth:juggler-seq", "nth:bernoulli-seq", "nth:bernoulli-take-while", "nth:bernoulli-nth", "nth:combinations", "nth:count-combinations", "nth:derangements", "nth:count-derangements", "nth:divisors", "nth:count-divisors", "nth:proper-divisors", "nth:count-proper-divisors", "nth:prime-factors", "nth:count-prime-factors", "nth:distinct-prime-factors", "nth:count-distinct-prime-factors", "nth:factorial", "nth:partitions", "nth:count-partitions", "nth:permutations", "nth:count-permutations", "nth:power-set", "nth:count-power-set", "nth:coprime?", "nth:divisible-by?", "nth:gcd", "nth:lcm", "nth:multinomial", "nth:amicable?", "nth:euler-totient", "nth:mobius", "nth:mertens", "nth:sigma", "nth:carmichael-lambda", "nth:cartesian-product", "nth:perfect-power", "nth:mod-exp", "nth:mod-inv", "nth:extended-gcd", "nth:chinese-remainder", "nth:stirling-first", "nth:stirling-second", "!:random", "!:random-int", "!:random-int-inclusive", "!:random-float", "!:random-boolean", "!:random-item", "!:random-sample", "!:random-sample-unique", "!:shuffle", "!:random-normal", "!:random-exponential", "!:random-binomial", "!:random-poisson", "!:random-gamma", "!:random-pareto", "!:uuid", "!:random-char", "!:random-string", "!:random-id", "!:random-color", "-short-regexp", "-short-fn", "-type-number", "-type-string", "-type-object", "-type-array", "-type-vector", "-type-matrix", "-type-grid", "-type-boolean", "-type-function", "-type-integer", "-type-any", "-type-null", "-type-collection", "-type-sequence", "-type-regexp", "-type-never"];
47
+ declare const apiNames: readonly ["filter", "map", "reduce", "reduce-right", "reductions", "count", "get", "get-in", "contains?", "assoc", "assoc-in", "++", "not-empty", "every?", "not-every?", "any?", "not-any?", "update", "update-in", "range", "repeat", "flatten", "mapcat", "nth", "push", "pop", "unshift", "shift", "slice", "splice", "position", "index-of", "last-index-of", "some", "reverse", "first", "second", "last", "rest", "next", "take", "take-last", "take-while", "drop", "drop-last", "drop-while", "sort", "sort-by", "distinct", "remove", "remove-at", "split-at", "split-with", "frequencies", "group-by", "partition", "partition-all", "partition-by", "starts-with?", "ends-with?", "interleave", "interpose", "+", "-", "*", "/", "mod", "rem", "quot", "inc", "dec", "sqrt", "cbrt", "^", "round", "trunc", "floor", "ceil", "min", "max", "abs", "sign", "ln", "log2", "log10", "sin", "cos", "tan", "asin", "acos", "atan", "sinh", "cosh", "tanh", "asinh", "acosh", "atanh", "to-rad", "to-deg", "|>", "apply", "identity", "comp", "constantly", "juxt", "complement", "every-pred", "some-pred", "fnull", "≠", "=", "<", ">", "≤", "≥", "!", "write!", "iso-date->epoch", "epoch->iso-date", "boolean", "compare", "identical?", "json-parse", "json-stringify", "dissoc", "keys", "vals", "entries", "find", "merge", "merge-with", "zipmap", "select-keys", "boolean?", "null?", "number?", "string?", "function?", "integer?", "array?", "object?", "coll?", "seq?", "regexp?", "zero?", "pos?", "neg?", "even?", "odd?", "finite?", "nan?", "negative-infinity?", "positive-infinity?", "false?", "true?", "empty?", "not-empty?", "vector?", "grid?", "matrix?", "regexp", "match", "replace", "replace-all", "string-repeat", "str", "number", "lower-case", "upper-case", "trim", "trim-left", "trim-right", "pad-left", "pad-right", "split", "split-lines", "template", "to-char-code", "from-char-code", "encode-base64", "decode-base64", "encode-uri-component", "decode-uri-component", "join", "capitalize", "blank?", "<<", ">>", ">>>", "bit-not", "&", "bit-and-not", "|", "xor", "bit-flip", "bit-clear", "bit-set", "bit-test", "assert", "assert=", "assert!=", "assert-gt", "assert-lt", "assert-gte", "assert-lte", "assert-true", "assert-false", "assert-truthy", "assert-falsy", "assert-null", "assert-throws", "assert-throws-error", "assert-not-throws", "mat:mul", "mat:det", "mat:inv", "mat:adj", "mat:cofactor", "mat:minor", "mat:trace", "mat:symmetric?", "mat:triangular?", "mat:upper-triangular?", "mat:lower-triangular?", "mat:diagonal?", "mat:square?", "mat:orthogonal?", "mat:identity?", "mat:invertible?", "mat:hilbert", "mat:vandermonde", "mat:band", "mat:banded?", "mat:rank", "mat:frobenius-norm", "mat:1-norm", "mat:inf-norm", "mat:max-norm", "vec:monotonic?", "vec:strictly-monotonic?", "vec:increasing?", "vec:decreasing?", "vec:strictly-increasing?", "vec:strictly-decreasing?", "vec:median", "vec:mode", "vec:min-index", "vec:max-index", "vec:sort-indices", "vec:count-values", "vec:linspace", "vec:ones", "vec:zeros", "vec:fill", "vec:generate", "vec:cumsum", "vec:cumprod", "vec:quartiles", "vec:percentile", "vec:quantile", "vec:histogram", "vec:ecdf", "vec:outliers?", "vec:outliers", "vec:bincount", "vec:winsorize", "vec:mse", "vec:mae", "vec:rmse", "vec:smape", "vec:mean", "vec:moving-mean", "vec:centered-moving-mean", "vec:running-mean", "vec:median", "vec:moving-median", "vec:centered-moving-median", "vec:running-median", "vec:variance", "vec:moving-variance", "vec:centered-moving-variance", "vec:running-variance", "vec:sample-variance", "vec:moving-sample-variance", "vec:centered-moving-sample-variance", "vec:running-sample-variance", "vec:sum", "vec:moving-sum", "vec:centered-moving-sum", "vec:running-sum", "vec:prod", "vec:moving-prod", "vec:centered-moving-prod", "vec:running-prod", "vec:min", "vec:moving-min", "vec:centered-moving-min", "vec:running-min", "vec:max", "vec:moving-max", "vec:centered-moving-max", "vec:running-max", "vec:stdev", "vec:moving-stdev", "vec:centered-moving-stdev", "vec:running-stdev", "vec:sample-stdev", "vec:moving-sample-stdev", "vec:centered-moving-sample-stdev", "vec:running-sample-stdev", "vec:iqr", "vec:moving-iqr", "vec:centered-moving-iqr", "vec:running-iqr", "vec:span", "vec:moving-span", "vec:centered-moving-span", "vec:running-span", "vec:geometric-mean", "vec:moving-geometric-mean", "vec:centered-moving-geometric-mean", "vec:running-geometric-mean", "vec:harmonic-mean", "vec:moving-harmonic-mean", "vec:centered-moving-harmonic-mean", "vec:running-harmonic-mean", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness", "vec:sample-skewness", "vec:moving-sample-skewness", "vec:centered-moving-sample-skewness", "vec:running-sample-skewness", "vec:kurtosis", "vec:moving-kurtosis", "vec:centered-moving-kurtosis", "vec:running-kurtosis", "vec:sample-kurtosis", "vec:moving-sample-kurtosis", "vec:centered-moving-sample-kurtosis", "vec:running-sample-kurtosis", "vec:excess-kurtosis", "vec:moving-excess-kurtosis", "vec:centered-moving-excess-kurtosis", "vec:running-excess-kurtosis", "vec:sample-excess-kurtosis", "vec:moving-sample-excess-kurtosis", "vec:centered-moving-sample-excess-kurtosis", "vec:running-sample-excess-kurtosis", "vec:rms", "vec:moving-rms", "vec:centered-moving-rms", "vec:running-rms", "vec:mad", "vec:moving-mad", "vec:centered-moving-mad", "vec:running-mad", "vec:medad", "vec:moving-medad", "vec:centered-moving-medad", "vec:running-medad", "vec:gini-coefficient", "vec:moving-gini-coefficient", "vec:centered-moving-gini-coefficient", "vec:running-gini-coefficient", "vec:entropy", "vec:moving-entropy", "vec:centered-moving-entropy", "vec:running-entropy", "vec:skewness", "vec:moving-skewness", "vec:centered-moving-skewness", "vec:running-skewness", "lin:reflect", "lin:refract", "lin:lerp", "lin:rotate2d", "lin:rotate3d", "lin:dot", "lin:cross", "lin:normalize-minmax", "lin:normalize-zscore", "lin:normalize-robust", "lin:normalize-l1", "lin:normalize-l2", "lin:normalize-log", "lin:angle", "lin:projection", "lin:orthogonal?", "lin:parallel?", "lin:collinear?", "lin:cosine-similarity", "lin:euclidean-distance", "lin:euclidean-norm", "lin:manhattan-distance", "lin:manhattan-norm", "lin:hamming-distance", "lin:hamming-norm", "lin:chebyshev-distance", "lin:chebyshev-norm", "lin:minkowski-distance", "lin:minkowski-norm", "lin:cov", "lin:corr", "lin:spearman-corr", "lin:pearson-corr", "lin:kendall-tau", "lin:autocorrelation", "lin:cross-correlation", "lin:rref", "lin:solve", "lin:to-polar", "lin:from-polar", "grid:every?", "grid:some?", "grid:every-row?", "grid:some-row?", "grid:every-col?", "grid:some-col?", "grid:row", "grid:col", "grid:shape", "grid:fill", "grid:generate", "grid:reshape", "grid:transpose", "grid:flip-h", "grid:flip-v", "grid:rotate", "grid:reverse-rows", "grid:reverse-cols", "grid:slice", "grid:slice-rows", "grid:slice-cols", "grid:splice-rows", "grid:splice-cols", "grid:concat-rows", "grid:concat-cols", "grid:map", "grid:mapi", "grid:reduce", "grid:reducei", "grid:push-rows", "grid:unshift-rows", "grid:pop-row", "grid:shift-row", "grid:push-cols", "grid:unshift-cols", "grid:pop-col", "grid:shift-col", "grid:from-array", "nth:abundant-seq", "nth:abundant-nth", "nth:abundant-take-while", "nth:abundant?", "nth:bell-seq", "nth:bell-nth", "nth:bell-take-while", "nth:bell?", "nth:catalan-seq", "nth:catalan-nth", "nth:catalan-take-while", "nth:catalan?", "nth:composite-seq", "nth:composite-nth", "nth:composite-take-while", "nth:composite?", "nth:factorial-seq", "nth:factorial-nth", "nth:factorial-take-while", "nth:factorial?", "nth:fibonacci-seq", "nth:fibonacci-nth", "nth:fibonacci-take-while", "nth:fibonacci?", "nth:geometric-seq", "nth:geometric-nth", "nth:geometric-take-while", "nth:geometric?", "nth:golomb-seq", "nth:golomb-nth", "nth:golomb-take-while", "nth:golomb?", "nth:happy-seq", "nth:happy-nth", "nth:happy-take-while", "nth:happy?", "nth:look-and-say-seq", "nth:look-and-say-nth", "nth:look-and-say-take-while", "nth:look-and-say?", "nth:lucas-seq", "nth:lucas-nth", "nth:lucas-take-while", "nth:lucas?", "nth:lucky-seq", "nth:lucky-nth", "nth:lucky-take-while", "nth:lucky?", "nth:mersenne-seq", "nth:mersenne-nth", "nth:mersenne-take-while", "nth:mersenne?", "nth:padovan-seq", "nth:padovan-nth", "nth:padovan-take-while", "nth:padovan?", "nth:partition-seq", "nth:partition-nth", "nth:partition-take-while", "nth:partition?", "nth:pell-seq", "nth:pell-nth", "nth:pell-take-while", "nth:pell?", "nth:perfect-seq", "nth:perfect-nth", "nth:perfect-take-while", "nth:perfect?", "nth:perfect-cube-seq", "nth:perfect-cube-nth", "nth:perfect-cube-take-while", "nth:perfect-cube?", "nth:perfect-power-seq", "nth:perfect-power-nth", "nth:perfect-power-take-while", "nth:perfect-power?", "nth:perfect-square-seq", "nth:perfect-square-nth", "nth:perfect-square-take-while", "nth:perfect-square?", "nth:polygonal-seq", "nth:polygonal-nth", "nth:polygonal-take-while", "nth:polygonal?", "nth:prime-seq", "nth:prime-nth", "nth:prime-take-while", "nth:prime?", "nth:recaman-seq", "nth:recaman-nth", "nth:recaman-take-while", "nth:recaman?", "nth:sylvester-seq", "nth:sylvester-nth", "nth:sylvester-take-while", "nth:sylvester?", "nth:thue-morse-seq", "nth:thue-morse-nth", "nth:thue-morse-take-while", "nth:thue-morse?", "nth:tribonacci-seq", "nth:tribonacci-nth", "nth:tribonacci-take-while", "nth:tribonacci?", "nth:collatz-seq", "nth:juggler-seq", "nth:bernoulli-seq", "nth:bernoulli-take-while", "nth:bernoulli-nth", "nth:combinations", "nth:count-combinations", "nth:derangements", "nth:count-derangements", "nth:divisors", "nth:count-divisors", "nth:proper-divisors", "nth:count-proper-divisors", "nth:prime-factors", "nth:count-prime-factors", "nth:distinct-prime-factors", "nth:count-distinct-prime-factors", "nth:factorial", "nth:partitions", "nth:count-partitions", "nth:permutations", "nth:count-permutations", "nth:power-set", "nth:count-power-set", "nth:coprime?", "nth:divisible-by?", "nth:gcd", "nth:lcm", "nth:multinomial", "nth:amicable?", "nth:euler-totient", "nth:mobius", "nth:mertens", "nth:sigma", "nth:carmichael-lambda", "nth:cartesian-product", "nth:perfect-power", "nth:mod-exp", "nth:mod-inv", "nth:extended-gcd", "nth:chinese-remainder", "nth:stirling-first", "nth:stirling-second", "!:random", "!:random-int", "!:random-int-inclusive", "!:random-float", "!:random-boolean", "!:random-item", "!:random-sample", "!:random-sample-unique", "!:shuffle", "!:random-normal", "!:random-exponential", "!:random-binomial", "!:random-poisson", "!:random-gamma", "!:random-pareto", "!:uuid", "!:random-char", "!:random-string", "!:random-id", "!:random-color", "-short-regexp", "-short-fn", "-type-number", "-type-string", "-type-object", "-type-array", "-type-vector", "-type-matrix", "-type-grid", "-type-boolean", "-type-function", "-type-integer", "-type-any", "-type-null", "-type-collection", "-type-sequence", "-type-regexp", "-type-never"];
48
48
  export type ApiName = typeof apiNames[number];
49
49
  export declare function isApiName(arg: string): arg is ApiName;
50
50
  export declare const categoryRecord: {
@@ -140,7 +140,6 @@ export declare const functionReference: {
140
140
  "*": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
141
141
  "/": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
142
142
  "-": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
143
- "~": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
144
143
  quot: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
145
144
  mod: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
146
145
  rem: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
@@ -168,6 +167,8 @@ export declare const functionReference: {
168
167
  atan: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
169
168
  tanh: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
170
169
  atanh: FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
170
+ "to-rad": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
171
+ "to-deg": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
171
172
  "=": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
172
173
  "\u2260": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
173
174
  "identical?": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
@@ -391,6 +392,8 @@ export declare const functionReference: {
391
392
  "lin:cross-correlation": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
392
393
  "lin:rref": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
393
394
  "lin:solve": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
395
+ "lin:to-polar": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
396
+ "lin:from-polar": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
394
397
  "mat:mul": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
395
398
  "mat:det": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
396
399
  "mat:inv": FunctionReference<"String" | "Array" | "Special expression" | "Predicate" | "Sequence" | "Collection" | "Object" | "Math" | "Functional" | "Regular expression" | "Bitwise" | "Misc" | "Assert" | "Vector" | "Linear Algebra" | "Matrix" | "Grid" | "Number Theory" | "Random" | "Shorthand" | "Datatype">;
@@ -0,0 +1 @@
1
+ export declare function length(vector: number[]): number;
@@ -1 +1 @@
1
- export declare function scale(vector: number[], scalar: number): number[];
1
+ export declare function scale<T extends number[]>(vector: T, scalar: number): T;
@@ -1 +1 @@
1
- export declare function subtract(vector1: number[], vector2: number[]): number[];
1
+ export declare function subtract<T extends number[]>(vector1: T, vector2: T): T;
@@ -1,5 +1,5 @@
1
- declare const binaryOperators: readonly ["^", "*", "/", "%", "+", "-", "<<", ">>", ">>>", "++", "<", "<=", "≤", ">", ">=", "≥", "=", "!=", "≠", "~", "≈", "&", "xor", "|", "&&", "||", "??", "|>"];
2
- declare const symbolicOperators: readonly ["^", "*", "/", "%", "+", "-", "<<", ">>", ">>>", "++", "<", "<=", "≤", ">", ">=", "≥", "=", "!=", "≠", "~", "", "&", "xor", "|", "&&", "||", "??", "|>", "->", "...", ".", ",", ":=", ";"];
1
+ declare const binaryOperators: readonly ["^", "*", "/", "%", "+", "-", "<<", ">>", ">>>", "++", "<", "<=", "≤", ">", ">=", "≥", "=", "!=", "≠", "&", "xor", "|", "&&", "||", "??", "|>"];
2
+ declare const symbolicOperators: readonly ["^", "*", "/", "%", "+", "-", "<<", ">>", ">>>", "++", "<", "<=", "≤", ">", ">=", "≥", "=", "!=", "≠", "&", "xor", "|", "&&", "||", "??", "|>", "?", ":", "->", "...", ".", ",", ":=", ";"];
3
3
  export declare function isFunctionOperator(operator: string): boolean;
4
4
  export type SymbolicBinaryOperator = typeof binaryOperators[number];
5
5
  export type SymbolicOperator = typeof symbolicOperators[number];
@@ -10,5 +10,6 @@ export declare function cloneColl<T extends Coll>(value: T): T;
10
10
  export declare function createNativeJsFunction(fn: (...args: any[]) => unknown, name?: string): NativeJsFunction;
11
11
  export declare function joinSets<T>(...results: Set<T>[]): Set<T>;
12
12
  export declare function addToSet<T>(target: Set<T>, source: Set<T>): void;
13
+ export declare const EPSILON = 1e-10;
13
14
  export declare function approxEqual(a: number, b: number, epsilon?: number): boolean;
14
- export declare function approxZero(value: number, epsilon?: number): boolean;
15
+ export declare function approxZero(value: number): boolean;
@@ -802,7 +802,7 @@ function deepEqual(a, b, sourceCodeInfo) {
802
802
  if (a === b)
803
803
  return true;
804
804
  if (typeof a === 'number' && typeof b === 'number')
805
- return Math.abs(a - b) < 1e-10;
805
+ return approxEqual(a, b);
806
806
  if (Array.isArray(a) && Array.isArray(b)) {
807
807
  if (a.length !== b.length)
808
808
  return false;
@@ -891,9 +891,8 @@ function approxEqual(a, b, epsilon) {
891
891
  // Use relative error for larger values
892
892
  return diff / (absA + absB) < epsilon;
893
893
  }
894
- function approxZero(value, epsilon) {
895
- if (epsilon === void 0) { epsilon = EPSILON; }
896
- return Math.abs(value) < epsilon;
894
+ function approxZero(value) {
895
+ return Math.abs(value) < EPSILON;
897
896
  }
898
897
 
899
898
  // isArray not needed, use Array.isArary
@@ -2654,30 +2653,6 @@ var mathNormalExpression = {
2654
2653
  },
2655
2654
  paramCount: {},
2656
2655
  },
2657
- '~': {
2658
- evaluate: function (params, sourceCodeInfo) {
2659
- var _a;
2660
- var _b = __read(getNumberVectorOrMatrixOperation([params[0], params[1]], sourceCodeInfo), 2), operation = _b[0], operands = _b[1];
2661
- var eplsilon = (_a = params[2]) !== null && _a !== void 0 ? _a : 1e-10;
2662
- assertNumber(eplsilon, sourceCodeInfo, { positive: true, finite: true });
2663
- if (operation === 'number') {
2664
- var _c = __read(operands, 2), first = _c[0], second = _c[1];
2665
- return approxEqual(first, second, eplsilon);
2666
- }
2667
- else if (operation === 'vector') {
2668
- var firstVector = operands[0];
2669
- var secondVector_1 = operands[1];
2670
- return firstVector.every(function (val, i) { return approxEqual(val, secondVector_1[i], eplsilon); });
2671
- }
2672
- else {
2673
- var firstMatrix = operands[0];
2674
- var secondMatrix_1 = operands[1];
2675
- return firstMatrix.every(function (row, i) { return row.every(function (val, j) { return approxEqual(val, secondMatrix_1[i][j], eplsilon); }); });
2676
- }
2677
- },
2678
- paramCount: { min: 2, max: 3 },
2679
- aliases: ['≈'],
2680
- },
2681
2656
  'quot': {
2682
2657
  evaluate: function (params, sourceCodeInfo) {
2683
2658
  var _a = __read(getNumberVectorOrMatrixOperation(params, sourceCodeInfo), 2), operation = _a[0], operands = _a[1];
@@ -2686,13 +2661,13 @@ var mathNormalExpression = {
2686
2661
  }
2687
2662
  else if (operation === 'vector') {
2688
2663
  var firstVector = operands[0];
2689
- var secondVector_2 = operands[1];
2690
- return firstVector.map(function (val, i) { return Math.trunc(val / secondVector_2[i]); });
2664
+ var secondVector_1 = operands[1];
2665
+ return firstVector.map(function (val, i) { return Math.trunc(val / secondVector_1[i]); });
2691
2666
  }
2692
2667
  else {
2693
2668
  var firstMatrix = operands[0];
2694
- var secondMatrix_2 = operands[1];
2695
- return firstMatrix.map(function (row, i) { return row.map(function (val, j) { return Math.trunc(val / secondMatrix_2[i][j]); }); });
2669
+ var secondMatrix_1 = operands[1];
2670
+ return firstMatrix.map(function (row, i) { return row.map(function (val, j) { return Math.trunc(val / secondMatrix_1[i][j]); }); });
2696
2671
  }
2697
2672
  },
2698
2673
  paramCount: 2,
@@ -2706,19 +2681,19 @@ var mathNormalExpression = {
2706
2681
  }
2707
2682
  else if (operation === 'vector') {
2708
2683
  var firstVector = operands[0];
2709
- var secondVector_3 = operands[1];
2684
+ var secondVector_2 = operands[1];
2710
2685
  return firstVector.map(function (dividend, i) {
2711
- var divisor = secondVector_3[i];
2686
+ var divisor = secondVector_2[i];
2712
2687
  var quotient = Math.floor(dividend / divisor);
2713
2688
  return dividend - divisor * quotient;
2714
2689
  });
2715
2690
  }
2716
2691
  else {
2717
2692
  var firstMatrix = operands[0];
2718
- var secondMatrix_3 = operands[1];
2693
+ var secondMatrix_2 = operands[1];
2719
2694
  return firstMatrix.map(function (row, i) { return row.map(function (val, j) {
2720
- var quotient = Math.floor(val / secondMatrix_3[i][j]);
2721
- return val - secondMatrix_3[i][j] * quotient;
2695
+ var quotient = Math.floor(val / secondMatrix_2[i][j]);
2696
+ return val - secondMatrix_2[i][j] * quotient;
2722
2697
  }); });
2723
2698
  }
2724
2699
  },
@@ -2732,13 +2707,13 @@ var mathNormalExpression = {
2732
2707
  }
2733
2708
  else if (operation === 'vector') {
2734
2709
  var firstVector = operands[0];
2735
- var secondVector_4 = operands[1];
2736
- return firstVector.map(function (dividend, i) { return dividend % secondVector_4[i]; });
2710
+ var secondVector_3 = operands[1];
2711
+ return firstVector.map(function (dividend, i) { return dividend % secondVector_3[i]; });
2737
2712
  }
2738
2713
  else {
2739
2714
  var firstMatrix = operands[0];
2740
- var secondMatrix_4 = operands[1];
2741
- return firstMatrix.map(function (row, i) { return row.map(function (dividend, j) { return dividend % secondMatrix_4[i][j]; }); });
2715
+ var secondMatrix_3 = operands[1];
2716
+ return firstMatrix.map(function (row, i) { return row.map(function (dividend, j) { return dividend % secondMatrix_3[i][j]; }); });
2742
2717
  }
2743
2718
  },
2744
2719
  paramCount: 2,
@@ -2788,13 +2763,13 @@ var mathNormalExpression = {
2788
2763
  }
2789
2764
  else if (operation === 'vector') {
2790
2765
  var firstVector = operands[0];
2791
- var secondVector_5 = operands[1];
2792
- return firstVector.map(function (base, i) { return Math.pow(base, secondVector_5[i]); });
2766
+ var secondVector_4 = operands[1];
2767
+ return firstVector.map(function (base, i) { return Math.pow(base, secondVector_4[i]); });
2793
2768
  }
2794
2769
  else {
2795
2770
  var firstMatrix = operands[0];
2796
- var secondMatrix_5 = operands[1];
2797
- return firstMatrix.map(function (row, i) { return row.map(function (base, j) { return Math.pow(base, secondMatrix_5[i][j]); }); });
2771
+ var secondMatrix_4 = operands[1];
2772
+ return firstMatrix.map(function (row, i) { return row.map(function (base, j) { return Math.pow(base, secondMatrix_4[i][j]); }); });
2798
2773
  }
2799
2774
  },
2800
2775
  paramCount: 2,
@@ -3206,6 +3181,40 @@ var mathNormalExpression = {
3206
3181
  },
3207
3182
  paramCount: 1,
3208
3183
  },
3184
+ 'to-rad': {
3185
+ evaluate: function (params, sourceCodeInfo) {
3186
+ var _a = __read(getNumberVectorOrMatrixOperation(params, sourceCodeInfo), 2), operation = _a[0], operands = _a[1];
3187
+ if (operation === 'number') {
3188
+ return (operands[0] * Math.PI) / 180;
3189
+ }
3190
+ else if (operation === 'vector') {
3191
+ var vector = operands[0];
3192
+ return vector.map(function (val) { return (val * Math.PI) / 180; });
3193
+ }
3194
+ else {
3195
+ var matrix = operands[0];
3196
+ return matrix.map(function (row) { return row.map(function (val) { return (val * Math.PI) / 180; }); });
3197
+ }
3198
+ },
3199
+ paramCount: 1,
3200
+ },
3201
+ 'to-deg': {
3202
+ evaluate: function (params, sourceCodeInfo) {
3203
+ var _a = __read(getNumberVectorOrMatrixOperation(params, sourceCodeInfo), 2), operation = _a[0], operands = _a[1];
3204
+ if (operation === 'number') {
3205
+ return (operands[0] * 180) / Math.PI;
3206
+ }
3207
+ else if (operation === 'vector') {
3208
+ var vector = operands[0];
3209
+ return vector.map(function (val) { return (val * 180) / Math.PI; });
3210
+ }
3211
+ else {
3212
+ var matrix = operands[0];
3213
+ return matrix.map(function (row) { return row.map(function (val) { return (val * 180) / Math.PI; }); });
3214
+ }
3215
+ },
3216
+ paramCount: 1,
3217
+ },
3209
3218
  };
3210
3219
 
3211
3220
  function isEqual(_a, sourceCodeInfo) {
@@ -3825,9 +3834,9 @@ var predicatesNormalExpression = {
3825
3834
  },
3826
3835
  'zero?': {
3827
3836
  evaluate: function (_a, sourceCodeInfo) {
3828
- var _b = __read(_a, 1), first = _b[0];
3829
- assertNumber(first, sourceCodeInfo, { finite: true });
3830
- return first === 0;
3837
+ var _b = __read(_a, 1), value = _b[0];
3838
+ assertNumber(value, sourceCodeInfo, { finite: true });
3839
+ return Math.abs(value) < EPSILON;
3831
3840
  },
3832
3841
  paramCount: 1,
3833
3842
  },
@@ -6673,6 +6682,10 @@ function scale(vector, scalar) {
6673
6682
  return vector.map(function (item) { return item * scalar; });
6674
6683
  }
6675
6684
 
6685
+ function length(vector) {
6686
+ return Math.sqrt(vector.reduce(function (acc, item) { return acc + Math.pow(item, 2); }, 0));
6687
+ }
6688
+
6676
6689
  var linearAlgebraNormalExpression = {
6677
6690
  'lin:rotate2d': {
6678
6691
  evaluate: function (_a, sourceCodeInfo) {
@@ -6997,7 +7010,7 @@ var linearAlgebraNormalExpression = {
6997
7010
  evaluate: function (_a, sourceCodeInfo) {
6998
7011
  var _b = __read(_a, 1), vector = _b[0];
6999
7012
  assertNonEmptyVector(vector, sourceCodeInfo);
7000
- return Math.sqrt(vector.reduce(function (acc, val) { return acc + val * val; }, 0));
7013
+ return length(vector);
7001
7014
  },
7002
7015
  paramCount: 1,
7003
7016
  aliases: ['lin:l2-norm', 'lin:length'],
@@ -7303,6 +7316,31 @@ var linearAlgebraNormalExpression = {
7303
7316
  },
7304
7317
  paramCount: 2,
7305
7318
  },
7319
+ 'lin:to-polar': {
7320
+ evaluate: function (_a, sourceCodeInfo) {
7321
+ var _b = __read(_a, 1), vector = _b[0];
7322
+ assert2dVector(vector, sourceCodeInfo);
7323
+ if (isZeroVector(vector)) {
7324
+ return [0, 0];
7325
+ }
7326
+ var r = Math.sqrt(Math.pow(vector[0], 2) + Math.pow(vector[1], 2));
7327
+ var theta = Math.atan2(vector[1], vector[0]);
7328
+ return [r, theta];
7329
+ },
7330
+ paramCount: 1,
7331
+ },
7332
+ 'lin:from-polar': {
7333
+ evaluate: function (_a, sourceCodeInfo) {
7334
+ var _b = __read(_a, 1), polar = _b[0];
7335
+ assert2dVector(polar, sourceCodeInfo);
7336
+ var _c = __read(polar, 2), r = _c[0], theta = _c[1];
7337
+ if (r === 0) {
7338
+ return [0, 0];
7339
+ }
7340
+ return [r * Math.cos(theta), r * Math.sin(theta)];
7341
+ },
7342
+ paramCount: 1,
7343
+ },
7306
7344
  };
7307
7345
 
7308
7346
  /**
@@ -12830,8 +12868,6 @@ var binaryOperators = [
12830
12868
  '=', // equal
12831
12869
  '!=', // not equal
12832
12870
  '≠', // not equal
12833
- '~', // approximate
12834
- '≈', // approximate
12835
12871
  '&', // bitwise AND
12836
12872
  'xor', // bitwise XOR
12837
12873
  '|', // bitwise OR
@@ -12841,6 +12877,8 @@ var binaryOperators = [
12841
12877
  '|>', // pipe
12842
12878
  ];
12843
12879
  var otherOperators = [
12880
+ '?', // conditional operator
12881
+ ':', // conditional operator
12844
12882
  '->', // lambda
12845
12883
  '...', // rest
12846
12884
  '.', // property accessor
@@ -12850,17 +12888,12 @@ var otherOperators = [
12850
12888
  ];
12851
12889
  var symbolicOperators = __spreadArray(__spreadArray([], __read(binaryOperators), false), __read(otherOperators), false);
12852
12890
  var nonFunctionOperators = [
12853
- '??',
12854
- '&&',
12855
- '||',
12856
12891
  'comment',
12857
12892
  'cond',
12858
12893
  'def',
12859
12894
  'defined?',
12860
- // 'defn',
12861
12895
  'do',
12862
12896
  'doseq',
12863
- // 'fn',
12864
12897
  'if',
12865
12898
  'let',
12866
12899
  'loop',
@@ -13438,8 +13471,9 @@ function untokenize(tokenStream) {
13438
13471
  }, '');
13439
13472
  }
13440
13473
 
13441
- var exponentiationPrecedence = 11;
13442
- var binaryFunctionalOperatorPrecedence = 2;
13474
+ var exponentiationPrecedence = 12;
13475
+ var binaryFunctionalOperatorPrecedence = 3;
13476
+ var conditionalOperatorPrecedence = 1;
13443
13477
  var placeholderRegexp = /^\$([1-9]\d?)?$/;
13444
13478
  function withSourceCodeInfo(node, sourceCodeInfo) {
13445
13479
  if (sourceCodeInfo) {
@@ -13454,40 +13488,39 @@ function getPrecedence(operatorSign, sourceCodeInfo) {
13454
13488
  case '*': // multiplication
13455
13489
  case '/': // division
13456
13490
  case '%': // remainder
13457
- return 10;
13491
+ return 11;
13458
13492
  case '+': // addition
13459
13493
  case '-': // subtraction
13460
- return 9;
13494
+ return 10;
13461
13495
  case '<<': // left shift
13462
13496
  case '>>': // signed right shift
13463
13497
  case '>>>': // unsigned right shift
13464
- return 8;
13498
+ return 9;
13465
13499
  case '++': // string concatenation
13466
- return 7;
13500
+ return 8;
13467
13501
  case '<': // less than
13468
13502
  case '<=': // less than or equal
13469
13503
  case '≤': // less than or equal
13470
13504
  case '>': // greater than
13471
13505
  case '>=': // greater than or equal
13472
13506
  case '≥': // greater than or equal
13473
- return 6;
13507
+ return 7;
13474
13508
  case '=': // equal
13475
13509
  case '!=': // not equal
13476
13510
  case '≠': // not equal
13477
- case '~': // approximate
13478
- case '≈': // approximate
13479
- return 5;
13511
+ return 6;
13480
13512
  case '&': // bitwise AND
13481
13513
  case 'xor': // bitwise XOR
13482
13514
  case '|': // bitwise OR
13483
- return 4;
13515
+ return 5;
13484
13516
  case '&&': // logical AND
13485
13517
  case '||': // logical OR
13486
13518
  case '??': // nullish coalescing
13487
- return 3;
13519
+ return 4;
13520
+ // leave room for binaryFunctionalOperatorPrecedence = 3
13488
13521
  case '|>': // pipe
13489
- return 1;
13490
- // leave room for binaryFunctionalOperatorPrecedence = 2
13522
+ return 2;
13523
+ // leave room for conditionalOperatorPrecedence = 1
13491
13524
  /* v8 ignore next 2 */
13492
13525
  default:
13493
13526
  throw new LitsError("Unknown binary operator: ".concat(operatorSign), sourceCodeInfo);
@@ -13529,21 +13562,21 @@ function fromBinaryOperatorToNode(operator, symbolNode, left, right, sourceCodeI
13529
13562
  case '&':
13530
13563
  case 'xor':
13531
13564
  case '|':
13532
- case '~':
13533
- case '≈':
13534
13565
  case '|>':
13535
13566
  return createNamedNormalExpressionNode(symbolNode, [left, right], sourceCodeInfo);
13536
13567
  case '&&':
13537
13568
  case '||':
13538
13569
  case '??':
13539
13570
  return withSourceCodeInfo([NodeTypes.SpecialExpression, [specialExpressionTypes[operatorName], [left, right]]], sourceCodeInfo);
13540
- /* v8 ignore next 10 */
13571
+ /* v8 ignore next 11 */
13541
13572
  case '.':
13542
13573
  case ';':
13543
13574
  case ':=':
13544
13575
  case ',':
13545
13576
  case '->':
13546
13577
  case '...':
13578
+ case '?':
13579
+ case ':':
13547
13580
  throw new LitsError("Unknown binary operator: ".concat(operatorName), sourceCodeInfo);
13548
13581
  default:
13549
13582
  throw new LitsError("Unknown binary operator: ".concat(operatorName), sourceCodeInfo);
@@ -13659,6 +13692,19 @@ var Parser = /** @class */ (function () {
13659
13692
  }
13660
13693
  left = createNamedNormalExpressionNode(operatorSymbol, [left, right], operator[2]);
13661
13694
  }
13695
+ else if ((operator === null || operator === void 0 ? void 0 : operator[1]) === '?') {
13696
+ if (conditionalOperatorPrecedence <= precedence) {
13697
+ break;
13698
+ }
13699
+ this.advance();
13700
+ var trueNode = this.parseExpression();
13701
+ if (!isOperatorToken(this.peek(), ':')) {
13702
+ throw new LitsError('Expected :', this.peekSourceCodeInfo());
13703
+ }
13704
+ this.advance();
13705
+ var falseNode = this.parseExpression();
13706
+ left = withSourceCodeInfo([NodeTypes.SpecialExpression, [specialExpressionTypes.if, [left, trueNode, falseNode]]], left[2]);
13707
+ }
13662
13708
  else {
13663
13709
  break;
13664
13710
  }