math-exercises 2.2.81 → 2.2.83
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/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType2.d.ts +4 -1
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType2.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType2.js +79 -30
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType3.d.ts +4 -1
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType3.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType3.js +89 -39
- package/lib/exercises/math/calculLitteral/inequations/squareFunctionInequation.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/inequations/squareFunctionInequation.js +37 -17
- package/lib/exercises/math/calculLitteral/simplifying/evaluateExpression.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/simplifying/evaluateExpression.js +55 -15
- package/lib/exercises/math/derivation/derivative/convexityQuadrinomials.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/convexityQuadrinomials.js +9 -18
- package/lib/exercises/math/derivation/derivative/thirdDegreeFunctionVariation.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/thirdDegreeFunctionVariation.js +11 -11
- package/lib/exercises/math/functions/absolute/absolueValueInequationsSup.d.ts.map +1 -1
- package/lib/exercises/math/functions/absolute/absolueValueInequationsSup.js +10 -2
- package/lib/exercises/math/functions/absolute/absoluteValueInequations.d.ts.map +1 -1
- package/lib/exercises/math/functions/absolute/absoluteValueInequations.js +11 -4
- package/lib/exercises/math/functions/basics/graphicEquation.d.ts.map +1 -1
- package/lib/exercises/math/functions/basics/graphicEquation.js +46 -28
- package/lib/exercises/math/functions/basics/graphicInequation.d.ts.map +1 -1
- package/lib/exercises/math/functions/basics/graphicInequation.js +0 -1
- package/lib/exercises/math/functions/basics/graphicInequationAffine.d.ts.map +1 -1
- package/lib/exercises/math/functions/basics/graphicInequationAffine.js +10 -3
- package/lib/exercises/math/functions/basics/twoFunctionsInequation.d.ts.map +1 -1
- package/lib/exercises/math/functions/basics/twoFunctionsInequation.js +74 -58
- package/lib/exercises/math/functions/logarithm/log10Simplifying.d.ts.map +1 -1
- package/lib/exercises/math/functions/logarithm/log10Simplifying.js +1 -0
- package/lib/exercises/math/functions/square/squareImageInterval.d.ts.map +1 -1
- package/lib/exercises/math/functions/square/squareImageInterval.js +13 -4
- package/lib/exercises/math/functions/trinoms/secondDegreeInequation.d.ts.map +1 -1
- package/lib/exercises/math/functions/trinoms/secondDegreeInequation.js +10 -6
- package/lib/exercises/math/functions/trinoms/trinomSignFromRoots.d.ts.map +1 -1
- package/lib/exercises/math/functions/trinoms/trinomSignFromRoots.js +12 -6
- package/lib/exercises/math/geometry/convexity/convexityQuadrinomialsGeo.d.ts.map +1 -1
- package/lib/exercises/math/geometry/convexity/convexityQuadrinomialsGeo.js +9 -14
- package/lib/exercises/math/matrices/matrixInversibilityDomain.d.ts.map +1 -1
- package/lib/exercises/math/matrices/matrixInversibilityDomain.js +15 -2
- package/lib/exercises/math/probaStat/binomial/binomialInequation.d.ts.map +1 -1
- package/lib/exercises/math/python/pyForLoop1Exercise.d.ts.map +1 -1
- package/lib/exercises/math/sequences/genericSequenceVariations.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/inequalityToInterval.d.ts +2 -4
- package/lib/exercises/math/sets/intervals/inequalityToInterval.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/inequalityToInterval.js +30 -25
- package/lib/exercises/math/sets/intervals/intervalToInequality.d.ts +2 -4
- package/lib/exercises/math/sets/intervals/intervalToInequality.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/intervalToInequality.js +42 -78
- package/lib/exercises/math/sets/intervals/intervalsIntersection.d.ts +3 -7
- package/lib/exercises/math/sets/intervals/intervalsIntersection.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/intervalsIntersection.js +101 -31
- package/lib/exercises/math/sets/intervals/intervalsUnion.d.ts +3 -7
- package/lib/exercises/math/sets/intervals/intervalsUnion.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/intervalsUnion.js +68 -19
- package/lib/exercises/pc/index.d.ts +4 -0
- package/lib/exercises/pc/index.d.ts.map +1 -1
- package/lib/exercises/pc/index.js +4 -6
- package/lib/exercises/vea/equationVEA.js +2 -2
- package/lib/geogebra/lagrange.d.ts.map +1 -1
- package/lib/geogebra/spline.d.ts.map +1 -1
- package/lib/index.d.ts +38 -20
- package/lib/index.d.ts.map +1 -1
- package/lib/math/geometry/point.d.ts.map +1 -1
- package/lib/math/inequations/inequation.d.ts +1 -1
- package/lib/math/inequations/inequation.d.ts.map +1 -1
- package/lib/math/numbers/integer/integer.d.ts.map +1 -1
- package/lib/math/numbers/rationals/rational.d.ts +2 -3
- package/lib/math/numbers/rationals/rational.d.ts.map +1 -1
- package/lib/math/polynomials/trinom.d.ts +2 -4
- package/lib/math/polynomials/trinom.d.ts.map +1 -1
- package/lib/playground.d.ts.map +1 -1
- package/lib/playground.js +4 -4
- package/lib/tree/nodes/equations/equationSolutionNode.d.ts +0 -1
- package/lib/tree/nodes/equations/equationSolutionNode.d.ts.map +1 -1
- package/lib/tree/nodes/equations/equationSolutionNode.js +0 -3
- package/lib/tree/nodes/inequations/inequationNode.d.ts +2 -1
- package/lib/tree/nodes/inequations/inequationNode.d.ts.map +1 -1
- package/lib/tree/nodes/inequations/inequationNode.js +4 -3
- package/lib/tree/nodes/inequations/inequationSolutionNode.d.ts +0 -1
- package/lib/tree/nodes/inequations/inequationSolutionNode.d.ts.map +1 -1
- package/lib/tree/nodes/inequations/inequationSolutionNode.js +0 -3
- package/lib/tree/nodes/numbers/numberNode.d.ts +1 -1
- package/lib/tree/nodes/operators/multiplyNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/multiplyNode.js +6 -1
- package/lib/tree/nodes/sets/closure.d.ts +5 -0
- package/lib/tree/nodes/sets/closure.d.ts.map +1 -1
- package/lib/tree/nodes/sets/closure.js +32 -0
- package/lib/tree/nodes/sets/discreteSetNode.d.ts +4 -4
- package/lib/tree/nodes/sets/discreteSetNode.d.ts.map +1 -1
- package/lib/tree/nodes/sets/discreteSetNode.js +3 -4
- package/lib/tree/nodes/sets/intervalNode.d.ts +13 -1
- package/lib/tree/nodes/sets/intervalNode.d.ts.map +1 -1
- package/lib/tree/nodes/sets/intervalNode.js +154 -3
- package/lib/tree/parsers/discreteSetParser.d.ts +2 -2
- package/lib/tree/parsers/discreteSetParser.d.ts.map +1 -1
- package/lib/tree/parsers/discreteSetParser.js +2 -1
- package/lib/tree/parsers/equationSolutionParser.js +1 -1
- package/lib/tree/parsers/powerParser.d.ts +1 -1
- package/lib/tree/parsers/rationalParser.d.ts +1 -1
- package/lib/tree/parsers/unionIntervalParser.d.ts.map +1 -1
- package/lib/tree/parsers/unionIntervalParser.js +3 -1
- package/package.json +1 -1
|
@@ -3,42 +3,90 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.intervalsUnion = void 0;
|
|
4
4
|
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
5
|
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
-
const
|
|
6
|
+
const infiniteNode_1 = require("../../../../tree/nodes/numbers/infiniteNode");
|
|
7
|
+
const intervalNode_1 = require("../../../../tree/nodes/sets/intervalNode");
|
|
8
|
+
const unionIntervalParser_1 = require("../../../../tree/parsers/unionIntervalParser");
|
|
7
9
|
const shuffle_1 = require("../../../../utils/alea/shuffle");
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
+
const rebuildIdentifiers = (oldIds) => {
|
|
11
|
+
if (!!oldIds.int1Identifiers)
|
|
12
|
+
return oldIds;
|
|
13
|
+
const a1 = oldIds.int1Min === "-infty" || oldIds.int2Min === -Infinity
|
|
14
|
+
? infiniteNode_1.MinusInfinityNode
|
|
15
|
+
: oldIds.int1Min.toTree();
|
|
16
|
+
const b1 = oldIds.int1Max === "infty" || oldIds.int1Max === Infinity
|
|
17
|
+
? infiniteNode_1.PlusInfinityNode
|
|
18
|
+
: oldIds.int1Max.toTree();
|
|
19
|
+
const closure1 = oldIds.int1Closure;
|
|
20
|
+
const interval1 = new intervalNode_1.IntervalNode(a1, b1, closure1);
|
|
21
|
+
const a2 = oldIds.int2Min === "-infty" || oldIds.int2Min === -Infinity
|
|
22
|
+
? infiniteNode_1.MinusInfinityNode
|
|
23
|
+
: oldIds.int2Min.toTree();
|
|
24
|
+
const b2 = oldIds.int2Max === "infty" || oldIds.int2Max === Infinity
|
|
25
|
+
? infiniteNode_1.PlusInfinityNode
|
|
26
|
+
: oldIds.int2Max.toTree();
|
|
27
|
+
const closure2 = oldIds.int2Closure;
|
|
28
|
+
const interval2 = new intervalNode_1.IntervalNode(a2, b2, closure2);
|
|
29
|
+
return {
|
|
30
|
+
int1Identifiers: interval1.toIdentifiers(),
|
|
31
|
+
int2Identifiers: interval2.toIdentifiers(),
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
const getInstruction = (identifiers) => {
|
|
35
|
+
const [int1, int2] = [
|
|
36
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(identifiers.int1Identifiers),
|
|
37
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(identifiers.int2Identifiers),
|
|
38
|
+
];
|
|
39
|
+
return `Soit $I = ${int1.toTex()}$ et $J = ${int2.toTex()}$.
|
|
40
|
+
|
|
41
|
+
Déterminer $I\\cup J$.`;
|
|
42
|
+
};
|
|
43
|
+
const getAnswer = (identifiers) => {
|
|
44
|
+
const [int1, int2] = [
|
|
45
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(identifiers.int1Identifiers),
|
|
46
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(identifiers.int2Identifiers),
|
|
47
|
+
];
|
|
10
48
|
const set = int1.union(int2);
|
|
11
|
-
|
|
49
|
+
return set.toTex();
|
|
50
|
+
};
|
|
51
|
+
const getIntervalsUnionQuestion = () => {
|
|
52
|
+
const [int1, int2] = intervalNode_1.IntervalNodeConstructor.differentRandoms(2);
|
|
53
|
+
const identifiers = {
|
|
54
|
+
int1Identifiers: int1.toIdentifiers(),
|
|
55
|
+
int2Identifiers: int2.toIdentifiers(),
|
|
56
|
+
};
|
|
12
57
|
const question = {
|
|
13
|
-
answer,
|
|
14
|
-
instruction:
|
|
58
|
+
answer: getAnswer(identifiers),
|
|
59
|
+
instruction: getInstruction(identifiers),
|
|
15
60
|
keys: ["infty", "lbracket", "rbracket", "semicolon", "cup", "cap"],
|
|
16
61
|
answerFormat: "tex",
|
|
17
|
-
identifiers
|
|
18
|
-
int1Closure: int1.closure,
|
|
19
|
-
int1Max: int1.max,
|
|
20
|
-
int1Min: int1.min,
|
|
21
|
-
int2Closure: int2.closure,
|
|
22
|
-
int2Max: int2.max,
|
|
23
|
-
int2Min: int2.min,
|
|
24
|
-
},
|
|
62
|
+
identifiers,
|
|
25
63
|
};
|
|
26
64
|
return question;
|
|
27
65
|
};
|
|
28
|
-
const getPropositions = (n, { answer,
|
|
66
|
+
const getPropositions = (n, { answer, int1Identifiers, int2Identifiers }) => {
|
|
29
67
|
const propositions = [];
|
|
30
68
|
(0, exercise_1.addValidProp)(propositions, answer);
|
|
31
|
-
const int1 =
|
|
32
|
-
|
|
69
|
+
const [int1, int2] = [
|
|
70
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(int1Identifiers),
|
|
71
|
+
intervalNode_1.IntervalNodeConstructor.fromIdentifiers(int2Identifiers),
|
|
72
|
+
];
|
|
33
73
|
(0, exercise_1.tryToAddWrongProp)(propositions, int1.intersection(int2).toTex());
|
|
34
74
|
while (propositions.length < n) {
|
|
35
|
-
const wrongAnswer =
|
|
75
|
+
const wrongAnswer = intervalNode_1.IntervalNodeConstructor.random().toTex();
|
|
36
76
|
(0, exercise_1.tryToAddWrongProp)(propositions, wrongAnswer);
|
|
37
77
|
}
|
|
38
78
|
return (0, shuffle_1.shuffle)(propositions);
|
|
39
79
|
};
|
|
40
80
|
const isAnswerValid = (ans, { answer }) => {
|
|
41
|
-
|
|
81
|
+
try {
|
|
82
|
+
const parsed = (0, unionIntervalParser_1.unionIntervalParser)(ans.replaceAll("S", "").replaceAll("=", ""));
|
|
83
|
+
if (!parsed)
|
|
84
|
+
return false;
|
|
85
|
+
return parsed.simplify().toTex() === answer;
|
|
86
|
+
}
|
|
87
|
+
catch (err) {
|
|
88
|
+
return false;
|
|
89
|
+
}
|
|
42
90
|
};
|
|
43
91
|
exports.intervalsUnion = {
|
|
44
92
|
id: "intervalsUnion",
|
|
@@ -53,4 +101,5 @@ exports.intervalsUnion = {
|
|
|
53
101
|
getPropositions,
|
|
54
102
|
isAnswerValid,
|
|
55
103
|
subject: "Mathématiques",
|
|
104
|
+
rebuildIdentifiers,
|
|
56
105
|
};
|
|
@@ -47,6 +47,8 @@ export * from "../math/geometry/vectors/scalarProduct/scalarProductViaCoords";
|
|
|
47
47
|
export * from "../math/geometry/vectors/scalarProduct/scalarProductViaCos";
|
|
48
48
|
export * from "../math/geometry/vectors/coordinatesReading";
|
|
49
49
|
export * from "../math/functions/affines/affineExpressionReading";
|
|
50
|
+
export * from "../math/geometry/thales/thales";
|
|
51
|
+
export * from "../math/geometry/thales/thalesCalcul";
|
|
50
52
|
export * from "../math/equaDiff/equaDiffCheckSolutionFirstOrder";
|
|
51
53
|
export * from "../math/equaDiff/equaDiffGeneralForme";
|
|
52
54
|
export * from "../math/equaDiff/equaDiffGeneralFormeWithIC";
|
|
@@ -55,4 +57,6 @@ export * from "../math/derivation/derivative/usualderivative";
|
|
|
55
57
|
export { thirdDegreeDerivative } from "../math/derivation/derivative/thirdDegreeDerivative";
|
|
56
58
|
export { firstDegreeDerivative } from "../math/derivation/derivative/firstDegreeDerivative";
|
|
57
59
|
export { secondDegreeDerivative } from "../math/derivation/derivative/secondDegreeDerivative";
|
|
60
|
+
export * from "../math/trigonometry/trigonometrySideCalcul";
|
|
61
|
+
export * from "../math/trigonometry/trigonometryAngleCalcul";
|
|
58
62
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/exercises/pc/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,YAAY,CAAC;AAC3B,cAAc,0BAA0B,CAAC;AACzC,cAAc,iBAAiB,CAAC;AAChC,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,wBAAwB,CAAC;AACvC,cAAc,MAAM,CAAC;AACrB,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,kBAAkB,CAAC;AACjC,cAAc,SAAS,CAAC;AACxB,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,SAAS,CAAC;AACxB,cAAc,oBAAoB,CAAC;AACnC,cAAc,qBAAqB,CAAC;AACpC,cAAc,QAAQ,CAAC;AACvB,cAAc,kBAAkB,CAAC;AACjC,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,UAAU,CAAC;AACzB,cAAc,UAAU,CAAC;AACzB,cAAc,8BAA8B,CAAC;AAC7C,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,gCAAgC,CAAC;AAC/C,cAAc,yCAAyC,CAAC;AACxD,cAAc,oBAAoB,CAAC;AACnC,cAAc,SAAS,CAAC;AAExB,yBAAyB;AACzB,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qDAAqD,CAAC;AACpE,OAAO,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACpE,cAAc,oCAAoC,CAAC;AACnD,cAAc,6CAA6C,CAAC;AAC5D,OAAO,EAA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B,CAAC;AACnC,cAAc,SAAS,CAAC;AAExB,yBAAyB;AACzB,cAAc,gCAAgC,CAAC;AAC/C,cAAc,qDAAqD,CAAC;AACpE,OAAO,EAAE,mBAAmB,EAAE,MAAM,+BAA+B,CAAC;AACpE,cAAc,oCAAoC,CAAC;AACnD,cAAc,6CAA6C,CAAC;AAC5D,OAAO,EAAE,qBAAqB,EAAE,MAAM,mDAAmD,CAAC;AAC1F,OAAO,EAAE,mBAAmB,EAAE,MAAM,8CAA8C,CAAC;AACnF,OAAO,EAAE,kBAAkB,EAAE,MAAM,8CAA8C,CAAC;AAClF,cAAc,uDAAuD,CAAC;AACtE,cAAc,uDAAuD,CAAC;AACtE,cAAc,uDAAuD,CAAC;AACtE,cAAc,uDAAuD,CAAC;AACtE,cAAc,+DAA+D,CAAC;AAC9E,cAAc,4DAA4D,CAAC;AAC3E,cAAc,6CAA6C,CAAC;AAC5D,cAAc,mDAAmD,CAAC;AAClE,cAAc,gCAAgC,CAAC;AAC/C,cAAc,sCAAsC,CAAC;AACrD,cAAc,kDAAkD,CAAC;AACjE,cAAc,uCAAuC,CAAC;AACtD,cAAc,6CAA6C,CAAC;AAC5D,cAAc,oDAAoD,CAAC;AACnE,cAAc,+CAA+C,CAAC;AAC9D,OAAO,EAAE,qBAAqB,EAAE,MAAM,qDAAqD,CAAC;AAC5F,OAAO,EAAE,qBAAqB,EAAE,MAAM,qDAAqD,CAAC;AAC5F,OAAO,EAAE,sBAAsB,EAAE,MAAM,sDAAsD,CAAC;AAC9F,cAAc,6CAA6C,CAAC;AAC5D,cAAc,8CAA8C,CAAC"}
|
|
@@ -68,9 +68,8 @@ __exportStar(require("../math/geometry/vectors/scalarProduct/scalarProductViaCoo
|
|
|
68
68
|
__exportStar(require("../math/geometry/vectors/scalarProduct/scalarProductViaCos"), exports);
|
|
69
69
|
__exportStar(require("../math/geometry/vectors/coordinatesReading"), exports);
|
|
70
70
|
__exportStar(require("../math/functions/affines/affineExpressionReading"), exports);
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
// export * from "../math/geometry/thales/thalesCalcul";
|
|
71
|
+
__exportStar(require("../math/geometry/thales/thales"), exports);
|
|
72
|
+
__exportStar(require("../math/geometry/thales/thalesCalcul"), exports);
|
|
74
73
|
__exportStar(require("../math/equaDiff/equaDiffCheckSolutionFirstOrder"), exports);
|
|
75
74
|
__exportStar(require("../math/equaDiff/equaDiffGeneralForme"), exports);
|
|
76
75
|
__exportStar(require("../math/equaDiff/equaDiffGeneralFormeWithIC"), exports);
|
|
@@ -82,6 +81,5 @@ var firstDegreeDerivative_1 = require("../math/derivation/derivative/firstDegree
|
|
|
82
81
|
Object.defineProperty(exports, "firstDegreeDerivative", { enumerable: true, get: function () { return firstDegreeDerivative_1.firstDegreeDerivative; } });
|
|
83
82
|
var secondDegreeDerivative_1 = require("../math/derivation/derivative/secondDegreeDerivative");
|
|
84
83
|
Object.defineProperty(exports, "secondDegreeDerivative", { enumerable: true, get: function () { return secondDegreeDerivative_1.secondDegreeDerivative; } });
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
//!FIX TRIANGLE
|
|
84
|
+
__exportStar(require("../math/trigonometry/trigonometrySideCalcul"), exports);
|
|
85
|
+
__exportStar(require("../math/trigonometry/trigonometryAngleCalcul"), exports);
|
|
@@ -12,9 +12,9 @@ const equationVEA = (ans, solutionTex) => {
|
|
|
12
12
|
}
|
|
13
13
|
else {
|
|
14
14
|
const setParsed = (0, discreteSetParser_1.discreteSetParser)(ans);
|
|
15
|
-
if (!setParsed || setParsed.length !== 1)
|
|
15
|
+
if (!setParsed || setParsed.elements.length !== 1)
|
|
16
16
|
return false;
|
|
17
|
-
return (0, rationalVEA_1.rationalVEA)(setParsed[0].toTex(), solutionTex);
|
|
17
|
+
return (0, rationalVEA_1.rationalVEA)(setParsed.elements[0].toTex(), solutionTex);
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
catch (err) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lagrange.d.ts","sourceRoot":"","sources":["../../src/geogebra/lagrange.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"lagrange.d.ts","sourceRoot":"","sources":["../../src/geogebra/lagrange.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAIlD,OAAO,EAAE,YAAY,EAAE,MAAM,oCAAoC,CAAC;AAelE,qBAAa,QAAQ;IACnB,MAAM,EAAE,MAAM,EAAE,EAAE,CAAC;gBAEP,QAAQ,EAAE,YAAY,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE;IAuDpD,WAAW;CAUZ"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spline.d.ts","sourceRoot":"","sources":["../../src/geogebra/spline.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"spline.d.ts","sourceRoot":"","sources":["../../src/geogebra/spline.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAIlD,OAAO,EAAE,YAAY,EAAE,MAAM,oCAAoC,CAAC;AAKlE,8BAAsB,iBAAiB;IACrC,MAAM;CAQP;AACD,qBAAa,MAAM;IACjB,MAAM,EAAE,MAAM,EAAE,EAAE,CAAC;gBAEP,QAAQ,EAAE,YAAY,EAAE,MAAM,CAAC,EAAE,KAAK,EAAE;IAuDpD,WAAW;CAUZ"}
|
package/lib/index.d.ts
CHANGED
|
@@ -354,14 +354,18 @@ declare const mathExercises: (Exercise<{
|
|
|
354
354
|
a: number;
|
|
355
355
|
b: number;
|
|
356
356
|
c: number;
|
|
357
|
-
}, {
|
|
357
|
+
}, {
|
|
358
|
+
inequationSolutionFormat: string;
|
|
359
|
+
}> | Exercise<{
|
|
358
360
|
coeff: number;
|
|
359
361
|
ineqType: import("./math/inequations/inequation").InegalitySymbols;
|
|
360
362
|
a: number;
|
|
361
363
|
b: number;
|
|
362
364
|
c: number;
|
|
363
365
|
d: number;
|
|
364
|
-
}, {
|
|
366
|
+
}, {
|
|
367
|
+
inequationSolutionFormat: string;
|
|
368
|
+
}> | Exercise<{
|
|
365
369
|
k: number;
|
|
366
370
|
inequationSymbol: import("./math/inequations/inequation").InegalitySymbols;
|
|
367
371
|
}, {}> | Exercise<{
|
|
@@ -1635,27 +1639,15 @@ declare const mathExercises: (Exercise<{
|
|
|
1635
1639
|
points: number[][];
|
|
1636
1640
|
isArithmetic: boolean;
|
|
1637
1641
|
}, {}> | Exercise<{
|
|
1638
|
-
|
|
1639
|
-
intervalMax: string | number;
|
|
1640
|
-
intervalClosure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1642
|
+
intervalIdentifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1641
1643
|
}, {}> | Exercise<{
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
int1Closure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1645
|
-
int2Min: number;
|
|
1646
|
-
int2Max: number;
|
|
1647
|
-
int2Closure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1644
|
+
int1Identifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1645
|
+
int2Identifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1648
1646
|
}, {}> | Exercise<{
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
int1Closure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1652
|
-
int2Min: number;
|
|
1653
|
-
int2Max: number;
|
|
1654
|
-
int2Closure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1647
|
+
int1Identifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1648
|
+
int2Identifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1655
1649
|
}, {}> | Exercise<{
|
|
1656
|
-
|
|
1657
|
-
intervalMax: string | number;
|
|
1658
|
-
intervalClosure: import("./tree/nodes/sets/closure").ClosureType;
|
|
1650
|
+
intervalIdentifiers: import("./tree/nodes/sets/intervalNode").IntervalNodeIdentifiers;
|
|
1659
1651
|
}, {}> | Exercise<{
|
|
1660
1652
|
type: number;
|
|
1661
1653
|
nb: string;
|
|
@@ -1886,6 +1878,23 @@ declare const pcExercises: (Exercise<{
|
|
|
1886
1878
|
isLog10: boolean;
|
|
1887
1879
|
}, {
|
|
1888
1880
|
isLog10: boolean;
|
|
1881
|
+
}> | Exercise<{
|
|
1882
|
+
vertices: string[];
|
|
1883
|
+
xA: number;
|
|
1884
|
+
yA: number;
|
|
1885
|
+
xB: number;
|
|
1886
|
+
yB: number;
|
|
1887
|
+
xC: number;
|
|
1888
|
+
yC: number;
|
|
1889
|
+
factor: number;
|
|
1890
|
+
}, {}> | Exercise<{
|
|
1891
|
+
ratio: number;
|
|
1892
|
+
triangleIdentifiers: import("./math/geometry/triangle").TriangleIdentifiers;
|
|
1893
|
+
insidePointsNames: string[];
|
|
1894
|
+
segmentAskedName: string;
|
|
1895
|
+
isPapillon: boolean;
|
|
1896
|
+
}, {
|
|
1897
|
+
configurationType: string;
|
|
1889
1898
|
}> | Exercise<{
|
|
1890
1899
|
xA: number;
|
|
1891
1900
|
xB: number;
|
|
@@ -1907,6 +1916,15 @@ declare const pcExercises: (Exercise<{
|
|
|
1907
1916
|
a: number;
|
|
1908
1917
|
b: number;
|
|
1909
1918
|
c: number;
|
|
1919
|
+
}, {}> | Exercise<{
|
|
1920
|
+
randAngle: number;
|
|
1921
|
+
hiddenSide: number;
|
|
1922
|
+
triangleIdentifiers: import("./math/geometry/triangle").TriangleIdentifiers;
|
|
1923
|
+
}, {}> | Exercise<{
|
|
1924
|
+
sideAsked: number;
|
|
1925
|
+
givenSide: number;
|
|
1926
|
+
givenAngle: number;
|
|
1927
|
+
triangleIdentifiers: import("./math/geometry/triangle").TriangleIdentifiers;
|
|
1910
1928
|
}, {}> | Exercise<{
|
|
1911
1929
|
reactionArray: import("./pc/constants/molecularChemistry/reaction").ReactionSpecies[];
|
|
1912
1930
|
}, {}> | Exercise<{
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAG1D,OAAO,yBAAyB,CAAC;AAEjC,QAAA,MAAM,aAAa
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAG1D,OAAO,yBAAyB,CAAC;AAEjC,QAAA,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;SAA+B,CAAC;AACnD,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;SAA6B,CAAC;AAE/C,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,QAAQ,EAAE,QAAQ,EAAE,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"point.d.ts","sourceRoot":"","sources":["../../../src/math/geometry/point.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"point.d.ts","sourceRoot":"","sources":["../../../src/math/geometry/point.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAG/D,OAAO,EAAE,kBAAkB,EAAE,MAAM,mDAAmD,CAAC;AACvF,OAA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AG,MAAM,EACzB,CAAC,EAAE,aAAa,GAAG,MAAM;IAO3B,KAAK,IAAI,MAAM;IAGf,aAAa,IAAI,gBAAgB;IAQjC,eAAe,IAAI,MAAM;IAGzB,QAAQ,IAAI,MAAM;IAIlB,UAAU,IAAI,MAAM;IAIpB,UAAU,IAAI,MAAM;IAIpB,QAAQ,CAAC,CAAC,EAAE,KAAK,EAAE,IAAI,SAAM,GAAG,KAAK;IAQrC,UAAU,CAAC,CAAC,EAAE,KAAK,GAAG,MAAM;IAM5B,MAAM,CAAC,CAAC,EAAE,KAAK,GAAG,OAAO;IAGzB,SAAS,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK;IAK5B,YAAY;IAGZ,YAAY,CAAC,EACX,OAAc,EACd,SAAgB,EAChB,KAAK,EACL,IAAI,EACJ,KAAK,GACN,GAAE,kBAAuB;IAiB1B,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK;IAiBnC,eAAe,CAAC,MAAM,EAAE,KAAK,EAAE,IAAI,SAAkB;IAIrD,OAAO,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,SAAkB;IAI1C,aAAa,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,SAAkB;CAIjD"}
|
|
@@ -11,6 +11,6 @@ export declare class InequationSymbol {
|
|
|
11
11
|
reversed: () => InegalitySymbols;
|
|
12
12
|
toReversed: () => InequationSymbol;
|
|
13
13
|
toStrictnessToggled: () => InequationSymbol;
|
|
14
|
-
strictnessToggled: () =>
|
|
14
|
+
strictnessToggled: () => InegalitySymbols;
|
|
15
15
|
}
|
|
16
16
|
//# sourceMappingURL=inequation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inequation.d.ts","sourceRoot":"","sources":["../../../src/math/inequations/inequation.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,gBAAgB,GAAG,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,MAAM,CAAC;AAE3D,8BAAsB,2BAA2B;IAC/C,MAAM,CAAC,MAAM;IAGb,MAAM,CAAC,YAAY;CAGpB;AACD,qBAAa,gBAAgB;IAC3B,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,gBAAgB,CAAC;gBACb,MAAM,EAAE,gBAAgB;IAKpC,QAAQ,QAAO,gBAAgB,CAW7B;IACF,UAAU,yBAER;IACF,mBAAmB,yBAEjB;IACF,iBAAiB,
|
|
1
|
+
{"version":3,"file":"inequation.d.ts","sourceRoot":"","sources":["../../../src/math/inequations/inequation.ts"],"names":[],"mappings":"AACA,MAAM,MAAM,gBAAgB,GAAG,GAAG,GAAG,GAAG,GAAG,MAAM,GAAG,MAAM,CAAC;AAE3D,8BAAsB,2BAA2B;IAC/C,MAAM,CAAC,MAAM;IAGb,MAAM,CAAC,YAAY;CAGpB;AACD,qBAAa,gBAAgB;IAC3B,QAAQ,EAAE,OAAO,CAAC;IAClB,KAAK,EAAE,OAAO,CAAC;IACf,MAAM,EAAE,gBAAgB,CAAC;gBACb,MAAM,EAAE,gBAAgB;IAKpC,QAAQ,QAAO,gBAAgB,CAW7B;IACF,UAAU,yBAER;IACF,mBAAmB,yBAEjB;IACF,iBAAiB,QAAO,gBAAgB,CAWtC;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"integer.d.ts","sourceRoot":"","sources":["../../../../src/math/numbers/integer/integer.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AAEjE,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,eAAO,MAAM,iBAAiB,UAK7B,CAAC;AACF,8BAAsB,kBAAkB;IACtC,MAAM,CAAC,MAAM,CAAC,UAA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;gBAEL,KAAK,EAAE,MAAM,EAAE,GAAG,CAAC,EAAE,MAAM;IAMvC,MAAM,CAAC,CAAC,EAAE,MAAM;IAGhB,MAAM,IAAI,UAAU;IAIpB,KAAK,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM;IAMxB,KAAK,CAAC,SAAS,EAAE,MAAM;IAkCvB,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM;IAc1B,QAAQ,CAAC,EAAE,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO;IAYxC,QAAQ;IAGR,GAAG,CAAC,EAAE,EAAE,MAAM;CAYf"}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AlgebraicNode } from "../../../tree/nodes/algebraicNode";
|
|
2
2
|
import { NodeOptions } from "../../../tree/nodes/node";
|
|
3
|
-
import { FractionNode } from "../../../tree/nodes/operators/fractionNode";
|
|
4
3
|
import { Integer } from "../integer/integer";
|
|
5
4
|
import { Nombre, NumberType } from "../nombre";
|
|
6
5
|
export declare abstract class RationalConstructor {
|
|
@@ -30,7 +29,7 @@ export declare class Rational implements Nombre {
|
|
|
30
29
|
reverse(shouldSimplify: boolean): Nombre;
|
|
31
30
|
divide(nb: Nombre): Nombre;
|
|
32
31
|
opposite(): Rational;
|
|
33
|
-
toTree(opts?: NodeOptions):
|
|
32
|
+
toTree(opts?: NodeOptions): AlgebraicNode;
|
|
34
33
|
isIrreductible(): boolean;
|
|
35
34
|
simplify(): Integer | Rational;
|
|
36
35
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rational.d.ts","sourceRoot":"","sources":["../../../../src/math/numbers/rationals/rational.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"rational.d.ts","sourceRoot":"","sources":["../../../../src/math/numbers/rationals/rational.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAE/D,OAAO,EAAQ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umberNode } from "../../tree/nodes/numbers/numberNode";
|
|
2
2
|
import { AddNode } from "../../tree/nodes/operators/addNode";
|
|
3
|
-
import { FractionNode } from "../../tree/nodes/operators/fractionNode";
|
|
4
3
|
import { MultiplyNode } from "../../tree/nodes/operators/multiplyNode";
|
|
5
4
|
import { Point } from "../geometry/point";
|
|
6
5
|
import { Polynomial } from "./polynomial";
|
|
7
|
-
import { OppositeNode } from "../../tree/nodes/functions/oppositeNode";
|
|
8
6
|
import { AlgebraicNode } from "../../tree/nodes/algebraicNode";
|
|
9
7
|
export declare abstract class TrinomConstructor {
|
|
10
8
|
static random(aOpts?: {
|
|
@@ -65,9 +63,9 @@ export declare class Trinom extends Polynomial {
|
|
|
65
63
|
getRootsNode(): AlgebraicNode[];
|
|
66
64
|
getRootsEquationSolutionTex(): string;
|
|
67
65
|
getAlpha(): number;
|
|
68
|
-
getAlphaNode():
|
|
66
|
+
getAlphaNode(): AlgebraicNode | NumberNode;
|
|
69
67
|
getBeta(): number;
|
|
70
|
-
getBetaNode():
|
|
68
|
+
getBetaNode(): AlgebraicNode | NumberNode;
|
|
71
69
|
getFactorizedForm(): AlgebraicNode | MultiplyNode;
|
|
72
70
|
getCanonicalForm(): AddNode | MultiplyNode;
|
|
73
71
|
getSommet(): Point;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"trinom.d.ts","sourceRoot":"","sources":["../../../src/math/polynomials/trinom.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;
|
|
1
|
+
{"version":3,"file":"trinom.d.ts","sourceRoot":"","sources":["../../../src/math/polynomials/trinom.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,qCAAqC,CAAC;AACjE,OAAO,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAE7D,OAAO,EAAE,YAAY,EAAE,MAAM,yCAAy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playground.d.ts","sourceRoot":"","sources":["../src/playground.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"playground.d.ts","sourceRoot":"","sources":["../src/playground.ts"],"names":[],"mappings":"AAsDA,eAAO,MAAM,UAAU,YAGtB,CAAC"}
|
package/lib/playground.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.playground = void 0;
|
|
4
|
+
const sqrtNode_1 = require("./tree/nodes/functions/sqrtNode");
|
|
4
5
|
const nodeConstructor_1 = require("./tree/nodes/nodeConstructor");
|
|
6
|
+
const multiplyNode_1 = require("./tree/nodes/operators/multiplyNode");
|
|
5
7
|
const playground = () => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
// const a = "-3x^2";
|
|
9
|
-
// console.log(isMonom(parsed));
|
|
8
|
+
const a = (0, multiplyNode_1.multiply)(3, (0, sqrtNode_1.sqrt)(2));
|
|
9
|
+
console.log(a.simplify().toTex());
|
|
10
10
|
};
|
|
11
11
|
exports.playground = playground;
|
|
12
12
|
const logIdentifiers = () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"equationSolutionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/equations/equationSolutionNode.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,KAAK,2BAA2B,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAC7E,qBAAa,oBAAqB,YAAW,IAAI;IAC/C,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,eAAe,CAAC;IAC9B,IAAI,CAAC,EAAE,WAAW,CAAC;gBAEjB,YAAY,EAAE,eAAe,EAC7B,MAAM,CAAC,EAAE,2BAA2B;IActC,aAAa;;;;;;;;;IAMb,cAAc;IAId,SAAS;IAkBT,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;IAQpC,YAAY;
|
|
1
|
+
{"version":3,"file":"equationSolutionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/equations/equationSolutionNode.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAE1D,KAAK,2BAA2B,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAC7E,qBAAa,oBAAqB,YAAW,IAAI;IAC/C,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,eAAe,CAAC;IAC9B,IAAI,CAAC,EAAE,WAAW,CAAC;gBAEjB,YAAY,EAAE,eAAe,EAC7B,MAAM,CAAC,EAAE,2BAA2B;IActC,aAAa;;;;;;;;;IAMb,cAAc;IAId,SAAS;IAkBT,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;IAQpC,YAAY;IAIZ,KAAK;IAGL,QAAQ;CAGT"}
|
|
@@ -18,12 +18,13 @@ export declare class InequationNode implements Node {
|
|
|
18
18
|
symbols: InegalitySymbols[];
|
|
19
19
|
};
|
|
20
20
|
toInterval(): IntervalNode;
|
|
21
|
+
/**turns x<3 into 3>x */
|
|
21
22
|
toReversed(): InequationNode;
|
|
22
23
|
toSwitched(): InequationNode;
|
|
24
|
+
toSwicthedStrictness(): InequationNode;
|
|
23
25
|
toAllValidTexs(): string[];
|
|
24
26
|
toEquivalentNodes(opts?: NodeOptions | undefined): InequationNode[];
|
|
25
27
|
toMathString(): string;
|
|
26
|
-
toMathjs(): string;
|
|
27
28
|
toAllTexs(): string[];
|
|
28
29
|
toTex(): string;
|
|
29
30
|
simplify(opts?: SimplifyOptions): InequationNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inequationNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/inequations/inequationNode.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAEjB,MAAM,mCAAmC,CAAC;AAK3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAG/D,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAClE,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAMvD,qBAAa,cAAe,YAAW,IAAI;IACzC,IAAI,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC;IAC/B,IAAI,EAAE,QAAQ,CAAC;IACf,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,OAAO,EAAE,gBAAgB,EAAE,CAAC;gBAE1B,QAAQ,EAAE,aAAa,EAAE,EACzB,OAAO,EAAE,gBAAgB,EAAE,GAAG,gBAAgB;IAuBhD,aAAa;;;;;;;IAOb,UAAU;
|
|
1
|
+
{"version":3,"file":"inequationNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/inequations/inequationNode.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,gBAAgB,EAEjB,MAAM,mCAAmC,CAAC;AAK3C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAG/D,OAAO,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAClE,OAAO,EAAE,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAMvD,qBAAa,cAAe,YAAW,IAAI;IACzC,IAAI,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC;IAC/B,IAAI,EAAE,QAAQ,CAAC;IACf,GAAG,EAAE,MAAM,CAAC;IACZ,QAAQ,EAAE,aAAa,EAAE,CAAC;IAC1B,OAAO,EAAE,gBAAgB,EAAE,CAAC;gBAE1B,QAAQ,EAAE,aAAa,EAAE,EACzB,OAAO,EAAE,gBAAgB,EAAE,GAAG,gBAAgB;IAuBhD,aAAa;;;;;;;IAOb,UAAU;IA8CV,wBAAwB;IACxB,UAAU;IAQV,UAAU;IAMV,oBAAoB;IAMpB,cAAc;IAGd,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW,GAAG,SAAS;IAYhD,YAAY;IAGZ,SAAS;IAGT,KAAK;IAGL,QAAQ,CAAC,IAAI,CAAC,EAAE,eAAe,GAAG,cAAc;CAcjD;AAED,eAAO,MAAM,kCAAkC,WACrC,MAAM,SACP,gBAAgB,SAChB,aAAa,WAuBrB,CAAC"}
|
|
@@ -79,6 +79,7 @@ class InequationNode {
|
|
|
79
79
|
return new intervalNode_1.IntervalNode(leftIsInf ? infiniteNode_1.MinusInfinityNode : this.children[1], rightIsInf ? infiniteNode_1.PlusInfinityNode : this.children[1], closure);
|
|
80
80
|
}
|
|
81
81
|
}
|
|
82
|
+
/**turns x<3 into 3>x */
|
|
82
83
|
toReversed() {
|
|
83
84
|
const newChildren = [...this.children].reverse();
|
|
84
85
|
const newSymbols = this.symbols.map((el) => new inequation_1.InequationSymbol(el).reversed());
|
|
@@ -87,6 +88,9 @@ class InequationNode {
|
|
|
87
88
|
toSwitched() {
|
|
88
89
|
return new InequationNode(this.children, this.symbols.map((el) => new inequation_1.InequationSymbol(el).reversed()));
|
|
89
90
|
}
|
|
91
|
+
toSwicthedStrictness() {
|
|
92
|
+
return new InequationNode(this.children, this.symbols.map((el) => new inequation_1.InequationSymbol(el).strictnessToggled()));
|
|
93
|
+
}
|
|
90
94
|
toAllValidTexs() {
|
|
91
95
|
return this.toEquivalentNodes().map((node) => node.toTex());
|
|
92
96
|
}
|
|
@@ -105,9 +109,6 @@ class InequationNode {
|
|
|
105
109
|
toMathString() {
|
|
106
110
|
return this.tex;
|
|
107
111
|
}
|
|
108
|
-
toMathjs() {
|
|
109
|
-
return this.tex;
|
|
110
|
-
}
|
|
111
112
|
toAllTexs() {
|
|
112
113
|
return [this.toTex()];
|
|
113
114
|
}
|
|
@@ -24,7 +24,6 @@ export declare class InequationSolutionNode implements Node {
|
|
|
24
24
|
toAllValidTexs(): string[];
|
|
25
25
|
toEquivalentNodes(opts?: NodeOptions): (import("./inequationNode").InequationNode | InequationSolutionNode)[];
|
|
26
26
|
toMathString(): string;
|
|
27
|
-
toMathjs(): string;
|
|
28
27
|
toTex(): string;
|
|
29
28
|
simplify(): this;
|
|
30
29
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inequationSolutionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/inequations/inequationSolutionNode.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAkB,MAAM,sBAAsB,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAE9D,KAAK,6BAA6B,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAC/E,qBAAa,sBAAuB,YAAW,IAAI;IACjD,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,gBAAgB,EAAE,YAAY,GAAG,iBAAiB,CAAC;IACnD,IAAI,CAAC,EAAE,WAAW,CAAC;gBAEjB,gBAAgB,EAAE,YAAY,GAAG,iBAAiB,EAClD,MAAM,CAAC,EAAE,6BAA6B;IAaxC,aAAa;;;;;;;;;IAMb,SAAS;IAUT,cAAc;IAId,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;IAepC,YAAY;
|
|
1
|
+
{"version":3,"file":"inequationSolutionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/inequations/inequationSolutionNode.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAkB,MAAM,sBAAsB,CAAC;AACpE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAE9D,KAAK,6BAA6B,GAAG;IAAE,QAAQ,CAAC,EAAE,MAAM,CAAC;IAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAAE,CAAC;AAC/E,qBAAa,sBAAuB,YAAW,IAAI;IACjD,IAAI,EAAE,QAAQ,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,gBAAgB,EAAE,YAAY,GAAG,iBAAiB,CAAC;IACnD,IAAI,CAAC,EAAE,WAAW,CAAC;gBAEjB,gBAAgB,EAAE,YAAY,GAAG,iBAAiB,EAClD,MAAM,CAAC,EAAE,6BAA6B;IAaxC,aAAa;;;;;;;;;IAMb,SAAS;IAUT,cAAc;IAId,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;IAepC,YAAY;IAIZ,KAAK;IAGL,QAAQ;CAGT"}
|
|
@@ -24,7 +24,7 @@ export declare class NumberNode implements AlgebraicNode {
|
|
|
24
24
|
toAllValidTexs(): string[];
|
|
25
25
|
toEquivalentNodes(): this[];
|
|
26
26
|
evaluate(vars?: Record<string, number>): number;
|
|
27
|
-
simplify(opts?: SimplifyOptions):
|
|
27
|
+
simplify(opts?: SimplifyOptions): AlgebraicNode | NumberNode;
|
|
28
28
|
equals(node: AlgebraicNode): boolean;
|
|
29
29
|
toDetailedEvaluation(vars: Record<string, AlgebraicNode>): this;
|
|
30
30
|
derivative(varName?: string | undefined): AlgebraicNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"multiplyNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/operators/multiplyNode.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC7E,OAAO,EACL,uBAAuB,EACvB,WAAW,EAEZ,MAAM,gBAAgB,CAAC;AAYxB,OAAO,EACL,aAAa,EACb,eAAe,EAEhB,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"multiplyNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/operators/multiplyNode.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC7E,OAAO,EACL,uBAAuB,EACvB,WAAW,EAEZ,MAAM,gBAAgB,CAAC;AAYxB,OAAO,EACL,aAAa,EACb,eAAe,EAEhB,MAAM,kBAAkB,CAAC;AAU1B,wBAAgB,cAAc,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,IAAI,YAAY,CAEzD;AAED,eAAO,MAAM,QAAQ,MAChB,aAAa,GAAG,MAAM,GAAG,MAAM,KAC/B,aAAa,GAAG,MAAM,GAAG,MAAM,SAC3B,WAAW,iBAOnB,CAAC;AACF,eAAO,MAAM,iBAAiB,QAAS,aAAa,EAAE,SAWrD,CAAC;AACF,qBAAa,YAAa,YAAW,uBAAuB;IAC1D,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,EAAE,EAAE,WAAW,CAAC;IAChB,SAAS,EAAE,aAAa,CAAC;IACzB,UAAU,EAAE,aAAa,CAAC;IAC1B,IAAI,EAAE,QAAQ,CAAC;IACf,SAAS,EAAE,OAAO,CAAC;gBAEjB,SAAS,EAAE,aAAa,EACxB,UAAU,EAAE,aAAa,EACzB,IAAI,CAAC,EAAE,WAAW;IAUpB,OAAO,aAGL;IAEF,YAAY,IAAI,MAAM;IAItB,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY,GAAG,MAAM;IAgFrC,SAAS;IAkDT,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW,GAAG,YAAY,EAAE;IAyFrD,cAAc,CAAC,IAAI,CAAC,EAAE,WAAW,GAAG,MAAM,EAAE;IAG5C,aAAa;;;;;;;;;IAYb,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAItC,IAAI;IAGJ,cAAc;IACd,QAAQ,CAAC,IAAI,CAAC,EAAE,eAAe,GAAG,aAAa;IAiK/C,MAAM,CAAC,IAAI,EAAE,aAAa;IAU1B,oBAAoB,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC;IAQxD,UAAU,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,aAAa;CAMxD"}
|
|
@@ -20,6 +20,7 @@ const addNode_1 = require("./addNode");
|
|
|
20
20
|
const round_1 = require("../../../math/utils/round");
|
|
21
21
|
const colorize_1 = require("../../../utils/latex/colorize");
|
|
22
22
|
const substractNode_1 = require("./substractNode");
|
|
23
|
+
const constantNode_1 = require("../numbers/constantNode");
|
|
23
24
|
function isMultiplyNode(a) {
|
|
24
25
|
return (0, operatorNode_1.isOperatorNode)(a) && a.id === operatorNode_1.OperatorIds.multiply;
|
|
25
26
|
}
|
|
@@ -91,10 +92,14 @@ class MultiplyNode {
|
|
|
91
92
|
return (0, colorize_1.colorize)("-" + rightTex, color);
|
|
92
93
|
// }
|
|
93
94
|
}
|
|
95
|
+
//!this is atrocious
|
|
94
96
|
let showTimesSign = !opts?.forceDotSign &&
|
|
95
97
|
(opts?.forceTimesSign ||
|
|
96
98
|
!isNaN(+rightTex[0]) ||
|
|
97
|
-
(this.rightChild.isNumeric &&
|
|
99
|
+
(this.rightChild.isNumeric &&
|
|
100
|
+
this.leftChild.isNumeric &&
|
|
101
|
+
!(0, constantNode_1.isConstantNode)(this.rightChild) &&
|
|
102
|
+
!(0, sqrtNode_1.isSqrtNode)(this.rightChild)) ||
|
|
98
103
|
(0, numberNode_1.isNumberNode)(this.rightChild) ||
|
|
99
104
|
((0, variableNode_1.isVariableNode)(this.leftChild) &&
|
|
100
105
|
(0, variableNode_1.isVariableNode)(this.rightChild) &&
|
|
@@ -11,7 +11,12 @@ export declare abstract class Closure {
|
|
|
11
11
|
static rightReverse(closure: ClosureType): ClosureType;
|
|
12
12
|
static switch(closure: ClosureType): ClosureType;
|
|
13
13
|
static fromBrackets(left: "[" | "]", right: "]" | "["): ClosureType;
|
|
14
|
+
static toBrackets(closure: ClosureType): string[];
|
|
14
15
|
static isLeftOpen(closure: ClosureType): boolean;
|
|
15
16
|
static isRightOpen(closure: ClosureType): boolean;
|
|
17
|
+
static getLessLeftStrict: (a: "[" | "]", b: "[" | "]") => "[" | "]";
|
|
18
|
+
static getLessRightStrict: (a: "[" | "]", b: "[" | "]") => "[" | "]";
|
|
19
|
+
static getMostLeftStrict: (a: "[" | "]", b: "[" | "]") => "[" | "]";
|
|
20
|
+
static getMostRightStrict: (a: "[" | "]", b: "[" | "]") => "[" | "]";
|
|
16
21
|
}
|
|
17
22
|
//# sourceMappingURL=closure.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"closure.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/sets/closure.ts"],"names":[],"mappings":"AAEA,oBAAY,WAAW;IACrB,EAAE,IAAA;IACF,EAAE,IAAA;IACF,EAAE,IAAA;IACF,EAAE,IAAA;CACH;AAED,8BAAsB,OAAO;IAC3B,MAAM,CAAC,MAAM;IAcb,MAAM,CAAC,OAAO,CAAC,OAAO,EAAE,WAAW;IAYnC,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE,WAAW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