UNPKG

7.88 kBJavaScriptView Raw
1/**
2 * THIS FILE IS AUTO-GENERATED
3 * DON'T MAKE CHANGES HERE
4 */
5import { config } from './configReadonly'
6import {
7 createChainClass,
8 createChain,
9 createNode,
10 createArrayNode,
11 createConditionalNode,
12 createFunctionAssignmentNode,
13 createObjectNode,
14 createParenthesisNode,
15 createRelationalNode,
16 createReviver,
17 createAccessorNode,
18 createBlockNode,
19 createOperatorNode,
20 createSymbolNode,
21 createConstantNode,
22 createRangeNode,
23 createFunctionNode,
24 createAssignmentNode,
25 createIndexNode,
26 createParse,
27 createEvaluate,
28 createHelpClass,
29 createSimplify,
30 createRationalize,
31 createCompile,
32 createHelp,
33 createParserClass,
34 createDerivative,
35 createParser,
36 createFilterTransform,
37 createMapTransform,
38 createMinTransform,
39 createApplyTransform,
40 createMaxTransform,
41 createStdTransform,
42 createVarianceTransform,
43 createMeanTransform,
44 createSumTransform,
45 createForEachTransform,
46 createSubsetTransform,
47 createRangeTransform
48} from '../factoriesNumber'
49import {
50 typed,
51 Range,
52 nthRoot,
53 e,
54 _false,
55 LN10,
56 LOG10E,
57 _NaN,
58 phi,
59 SQRT1_2, // eslint-disable-line camelcase
60 tau,
61 version,
62 string,
63 filter,
64 map,
65 pickRandom,
66 randomInt,
67 compare,
68 compareText,
69 smaller,
70 larger,
71 erf,
72 max,
73 format,
74 clone,
75 typeOf,
76 unaryPlus,
77 addScalar,
78 ceil,
79 exp,
80 fix,
81 gcd,
82 log10,
83 mod,
84 multiply,
85 sqrt,
86 subtract,
87 divideScalar,
88 log,
89 add,
90 divide,
91 bitNot,
92 bitXor,
93 rightArithShift,
94 and,
95 or,
96 Index,
97 subset,
98 gamma,
99 acosh,
100 acoth,
101 acsch,
102 asech,
103 asinh,
104 atan2,
105 cos,
106 cot,
107 csc,
108 sec,
109 sin,
110 tan,
111 isInteger,
112 isPositive,
113 isNaN,
114 ResultSet,
115 round,
116 LN2,
117 _null,
118 SQRT2,
119 number,
120 apply,
121 factorial,
122 permutations,
123 equalScalar,
124 equal,
125 smallerEq,
126 deepEqual,
127 prod,
128 sum,
129 variance,
130 std,
131 isPrime,
132 unaryMinus,
133 cbrt,
134 expm1,
135 lcm,
136 multiplyScalar,
137 square,
138 pow,
139 norm,
140 bitOr,
141 rightLogShift,
142 xor,
143 combinations,
144 acot,
145 asec,
146 atan,
147 cosh,
148 csch,
149 sinh,
150 isNegative,
151 stirlingS2,
152 catalan,
153 _Infinity,
154 pi,
155 _true,
156 forEach,
157 multinomial,
158 compareNatural,
159 largerEq,
160 min,
161 print,
162 numeric,
163 cube,
164 log2,
165 xgcd,
166 bitAnd,
167 not,
168 acos,
169 asin,
170 coth,
171 tanh,
172 bellNumbers,
173 LOG2E,
174 boolean,
175 random,
176 unequal,
177 mean,
178 isNumeric,
179 abs,
180 sign,
181 leftShift,
182 acsc,
183 sech,
184 hypot,
185 partitionSelect,
186 mode,
187 quantileSeq,
188 hasNumericValue,
189 log1p,
190 atanh,
191 composition,
192 median,
193 floor,
194 isZero,
195 equalText,
196 matrix,
197 range,
198 mad,
199 size
200} from './pureFunctionsNumber.generated'
201
202const math = {} // NOT pure!
203const mathWithTransform = {} // NOT pure!
204const classes = {} // NOT pure!
205
206export const Chain = createChainClass({ math })
207export const chain = createChain({ Chain, typed })
208export const Node = createNode({ mathWithTransform })
209export const ArrayNode = createArrayNode({ Node })
210export const ConditionalNode = createConditionalNode({ Node })
211export const FunctionAssignmentNode = createFunctionAssignmentNode({ Node, typed })
212export const ObjectNode = createObjectNode({ Node })
213export const ParenthesisNode = createParenthesisNode({ Node })
214export const RelationalNode = createRelationalNode({ Node })
215export const reviver = createReviver({ classes })
216export const AccessorNode = createAccessorNode({ Node, subset })
217export const BlockNode = createBlockNode({ Node, ResultSet })
218export const OperatorNode = createOperatorNode({ Node })
219export const SymbolNode = createSymbolNode({ Node, math })
220export const ConstantNode = createConstantNode({ Node })
221export const RangeNode = createRangeNode({ Node })
222export const FunctionNode = createFunctionNode({ Node, SymbolNode, math })
223export const AssignmentNode = createAssignmentNode({ matrix, Node, subset })
224export const IndexNode = createIndexNode({ Index, Node, Range, size })
225export const parse = createParse({ AccessorNode, ArrayNode, AssignmentNode, BlockNode, ConditionalNode, ConstantNode, FunctionAssignmentNode, FunctionNode, IndexNode, ObjectNode, OperatorNode, ParenthesisNode, RangeNode, RelationalNode, SymbolNode, config, numeric, typed })
226export const evaluate = createEvaluate({ parse, typed })
227export const Help = createHelpClass({ parse })
228export const simplify = createSimplify({ ConstantNode, FunctionNode, OperatorNode, ParenthesisNode, SymbolNode, add, config, divide, equal, isZero, mathWithTransform, multiply, parse, pow, subtract, typed })
229export const rationalize = createRationalize({ ConstantNode, FunctionNode, OperatorNode, ParenthesisNode, SymbolNode, add, config, divide, equal, isZero, mathWithTransform, multiply, parse, pow, simplify, subtract, typed })
230export const compile = createCompile({ parse, typed })
231export const help = createHelp({ Help, mathWithTransform, typed })
232export const Parser = createParserClass({ parse })
233export const derivative = createDerivative({ ConstantNode, FunctionNode, OperatorNode, ParenthesisNode, SymbolNode, config, equal, isZero, numeric, parse, simplify, typed })
234export const parser = createParser({ Parser, typed })
235
236Object.assign(math, {
237 typed,
238 chain,
239 nthRoot,
240 e,
241 false: _false,
242 LN10,
243 LOG10E,
244 NaN: _NaN,
245 phi,
246 SQRT1_2,
247 tau,
248 version,
249 string,
250 filter,
251 map,
252 pickRandom,
253 randomInt,
254 compare,
255 compareText,
256 smaller,
257 larger,
258 erf,
259 max,
260 format,
261 clone,
262 typeOf,
263 reviver,
264 unaryPlus,
265 addScalar,
266 ceil,
267 exp,
268 fix,
269 gcd,
270 log10,
271 mod,
272 multiply,
273 sqrt,
274 subtract,
275 divideScalar,
276 log,
277 add,
278 divide,
279 bitNot,
280 bitXor,
281 rightArithShift,
282 and,
283 or,
284 subset,
285 gamma,
286 acosh,
287 acoth,
288 acsch,
289 asech,
290 asinh,
291 atan2,
292 cos,
293 cot,
294 csc,
295 sec,
296 sin,
297 tan,
298 isInteger,
299 isPositive,
300 isNaN,
301 round,
302 'E': e,
303 LN2,
304 null: _null,
305 SQRT2,
306 number,
307 apply,
308 factorial,
309 permutations,
310 equalScalar,
311 equal,
312 smallerEq,
313 deepEqual,
314 prod,
315 sum,
316 variance,
317 std,
318 isPrime,
319 unaryMinus,
320 cbrt,
321 expm1,
322 lcm,
323 multiplyScalar,
324 square,
325 pow,
326 norm,
327 bitOr,
328 rightLogShift,
329 xor,
330 combinations,
331 acot,
332 asec,
333 atan,
334 cosh,
335 csch,
336 sinh,
337 isNegative,
338 stirlingS2,
339 catalan,
340 Infinity: _Infinity,
341 pi,
342 true: _true,
343 forEach,
344 multinomial,
345 compareNatural,
346 largerEq,
347 min,
348 print,
349 numeric,
350 cube,
351 log2,
352 xgcd,
353 bitAnd,
354 not,
355 acos,
356 asin,
357 coth,
358 tanh,
359 bellNumbers,
360 LOG2E,
361 boolean,
362 random,
363 unequal,
364 mean,
365 isNumeric,
366 abs,
367 sign,
368 leftShift,
369 acsc,
370 sech,
371 hypot,
372 'PI': pi,
373 partitionSelect,
374 mode,
375 quantileSeq,
376 hasNumericValue,
377 log1p,
378 atanh,
379 composition,
380 median,
381 floor,
382 isZero,
383 equalText,
384 matrix,
385 range,
386 mad,
387 size,
388 parse,
389 evaluate,
390 simplify,
391 rationalize,
392 compile,
393 help,
394 derivative,
395 parser,
396 config
397})
398
399Object.assign(mathWithTransform, math, {
400 filter: createFilterTransform({ typed }),
401 map: createMapTransform({ typed }),
402 min: createMinTransform({ smaller, typed }),
403 apply: createApplyTransform({ isInteger, typed }),
404 max: createMaxTransform({ larger, typed }),
405 std: createStdTransform({ sqrt, typed, variance }),
406 variance: createVarianceTransform({ add, apply, divide, isNaN, multiply, subtract, typed }),
407 mean: createMeanTransform({ add, divide, typed }),
408 sum: createSumTransform({ add, config, typed }),
409 forEach: createForEachTransform({ typed }),
410 subset: createSubsetTransform({ matrix, typed }),
411 range: createRangeTransform({ matrix, config, larger, largerEq, smaller, smallerEq, typed })
412})
413
414Object.assign(classes, {
415 Range,
416 Chain,
417 Node,
418 ArrayNode,
419 ConditionalNode,
420 FunctionAssignmentNode,
421 ObjectNode,
422 ParenthesisNode,
423 RelationalNode,
424 Index,
425 ResultSet,
426 AccessorNode,
427 BlockNode,
428 OperatorNode,
429 SymbolNode,
430 ConstantNode,
431 RangeNode,
432 FunctionNode,
433 AssignmentNode,
434 IndexNode,
435 Help,
436 Parser
437})
438
439Chain.createProxy(math)
440
441export { embeddedDocs as docs } from '../expression/embeddedDocs/embeddedDocs'