math-exercises 1.4.15 → 1.4.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/lib/exercises/calcul/arithmetics/paritySumsAndProducts.d.ts +4 -0
  2. package/lib/exercises/calcul/arithmetics/paritySumsAndProducts.d.ts.map +1 -0
  3. package/lib/exercises/calcul/arithmetics/paritySumsAndProducts.js +113 -0
  4. package/lib/exercises/combinatory/anagrams.d.ts +4 -0
  5. package/lib/exercises/combinatory/anagrams.d.ts.map +1 -0
  6. package/lib/exercises/combinatory/anagrams.js +128 -0
  7. package/lib/exercises/combinatory/ballsCounting.d.ts +4 -0
  8. package/lib/exercises/combinatory/ballsCounting.d.ts.map +1 -0
  9. package/lib/exercises/combinatory/ballsCounting.js +124 -0
  10. package/lib/exercises/combinatory/diceCounting.d.ts +4 -0
  11. package/lib/exercises/combinatory/diceCounting.d.ts.map +1 -0
  12. package/lib/exercises/combinatory/diceCounting.js +134 -0
  13. package/lib/exercises/derivation/derivative/productDerivative.d.ts +4 -0
  14. package/lib/exercises/derivation/derivative/productDerivative.d.ts.map +1 -0
  15. package/lib/exercises/derivation/derivative/productDerivative.js +62 -0
  16. package/lib/exercises/derivation/derivative/quotientDerivative.d.ts +4 -0
  17. package/lib/exercises/derivation/derivative/quotientDerivative.d.ts.map +1 -0
  18. package/lib/exercises/derivation/derivative/quotientDerivative.js +65 -0
  19. package/lib/exercises/exercise.d.ts +1 -1
  20. package/lib/exercises/exercise.d.ts.map +1 -1
  21. package/lib/exercises/exercises.d.ts.map +1 -1
  22. package/lib/exercises/exercises.js +58 -26
  23. package/lib/exercises/functions/absolute/absoluteValueEquations.d.ts +4 -0
  24. package/lib/exercises/functions/absolute/absoluteValueEquations.d.ts.map +1 -0
  25. package/lib/exercises/functions/absolute/absoluteValueEquations.js +75 -0
  26. package/lib/exercises/functions/absolute/absoluteValueInequations.d.ts +4 -0
  27. package/lib/exercises/functions/absolute/absoluteValueInequations.d.ts.map +1 -0
  28. package/lib/exercises/functions/absolute/absoluteValueInequations.js +67 -0
  29. package/lib/exercises/geometry/vectors/coordinatesReading.d.ts +4 -0
  30. package/lib/exercises/geometry/vectors/coordinatesReading.d.ts.map +1 -0
  31. package/lib/exercises/geometry/vectors/coordinatesReading.js +81 -0
  32. package/lib/exercises/geometry/vectors/vectorCoordinatesFromTwoPoints.d.ts +4 -0
  33. package/lib/exercises/geometry/vectors/vectorCoordinatesFromTwoPoints.d.ts.map +1 -0
  34. package/lib/exercises/geometry/vectors/vectorCoordinatesFromTwoPoints.js +68 -0
  35. package/lib/exercises/percent/evolutionToCM.d.ts +4 -0
  36. package/lib/exercises/percent/evolutionToCM.d.ts.map +1 -0
  37. package/lib/exercises/percent/evolutionToCM.js +74 -0
  38. package/lib/exercises/sequences/explicitFormulaUsage.d.ts +22 -0
  39. package/lib/exercises/sequences/explicitFormulaUsage.d.ts.map +1 -0
  40. package/lib/exercises/sequences/explicitFormulaUsage.js +82 -0
  41. package/lib/exercises/sequences/genericSequenceVariations.d.ts +4 -0
  42. package/lib/exercises/sequences/genericSequenceVariations.d.ts.map +1 -0
  43. package/lib/exercises/sequences/genericSequenceVariations.js +55 -0
  44. package/lib/exercises/sequences/recurrenceFormulaUsage.d.ts +4 -0
  45. package/lib/exercises/sequences/recurrenceFormulaUsage.d.ts.map +1 -0
  46. package/lib/exercises/sequences/recurrenceFormulaUsage.js +69 -0
  47. package/lib/exercises/utils/geogebra/getAdaptedCoords.d.ts +1 -0
  48. package/lib/exercises/utils/geogebra/getAdaptedCoords.d.ts.map +1 -0
  49. package/lib/exercises/utils/geogebra/getAdaptedCoords.js +1 -0
  50. package/lib/math/geometry/point.d.ts +2 -0
  51. package/lib/math/geometry/point.d.ts.map +1 -1
  52. package/lib/math/geometry/point.js +8 -0
  53. package/lib/math/polynomials/polynomial.d.ts +7 -0
  54. package/lib/math/polynomials/polynomial.d.ts.map +1 -1
  55. package/lib/math/polynomials/polynomial.js +7 -0
  56. package/lib/math/sequences/sequence.d.ts +3 -1
  57. package/lib/math/sequences/sequence.d.ts.map +1 -1
  58. package/lib/math/sequences/sequence.js +2 -1
  59. package/lib/types/keyIds.d.ts +6 -4
  60. package/lib/types/keyIds.d.ts.map +1 -1
  61. package/lib/utils/randomLetter.d.ts +2 -0
  62. package/lib/utils/randomLetter.d.ts.map +1 -0
  63. package/lib/utils/randomLetter.js +9 -0
  64. package/package.json +1 -2
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getEvolutionToCmQuestion = exports.evolutionToCM = void 0;
4
+ const exercise_1 = require("../../exercises/exercise");
5
+ const getDistinctQuestions_1 = require("../../exercises/utils/getDistinctQuestions");
6
+ const randint_1 = require("../../math/utils/random/randint");
7
+ const round_1 = require("../../math/utils/round");
8
+ const coinFlip_1 = require("../../utils/coinFlip");
9
+ const uuid_1 = require("uuid");
10
+ exports.evolutionToCM = {
11
+ id: 'evolutionToCM',
12
+ connector: '=',
13
+ instruction: '',
14
+ label: "Passer d'évolution en pourcentage au coefficient multiplicateur",
15
+ levels: ['2ndPro', '2nde', '1rePro', '1reTech', '1reESM'],
16
+ isSingleStep: true,
17
+ sections: ['Pourcentages'],
18
+ generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getEvolutionToCmQuestion, nb),
19
+ qcmTimer: 60,
20
+ freeTimer: 60,
21
+ };
22
+ function getEvolutionToCmQuestion() {
23
+ const isFromEvolutionToCM = (0, coinFlip_1.coinFlip)();
24
+ const evolution = (0, randint_1.randint)(-99, 101, [0]);
25
+ const isHausse = evolution > 0;
26
+ const CM = ((0, round_1.round)(1 + evolution / 100, 2) + '').replaceAll('.', ',');
27
+ const answer = isFromEvolutionToCM ? CM : (isHausse ? '+' : '') + evolution + '\\%';
28
+ const getPropositions = (n) => {
29
+ const res = [];
30
+ res.push({
31
+ id: (0, uuid_1.v4)(),
32
+ statement: answer,
33
+ isRightAnswer: true,
34
+ format: 'tex',
35
+ });
36
+ if (isFromEvolutionToCM) {
37
+ (0, exercise_1.tryToAddWrongProp)(res, ((0, round_1.round)(evolution / 100, 2) + '').replaceAll('.', ','));
38
+ (0, exercise_1.tryToAddWrongProp)(res, evolution + '');
39
+ }
40
+ else {
41
+ (0, exercise_1.tryToAddWrongProp)(res, '+' + ((0, round_1.round)(1 + evolution / 100, 2) * 100 + '\\%').replaceAll('.', ','));
42
+ }
43
+ const missing = n - res.length;
44
+ for (let i = 0; i < missing; i++) {
45
+ let isDuplicate;
46
+ let proposition;
47
+ do {
48
+ const wrongAnswer = isFromEvolutionToCM
49
+ ? ((0, round_1.round)((0, randint_1.randint)(1, 200) / 100, 2) + '').replaceAll('.', ',')
50
+ : ((0, coinFlip_1.coinFlip)() ? '+' : '-') + (0, randint_1.randint)(1, 100) + '\\%';
51
+ proposition = {
52
+ id: (0, uuid_1.v4)() + ``,
53
+ statement: wrongAnswer,
54
+ isRightAnswer: false,
55
+ format: 'tex',
56
+ };
57
+ isDuplicate = res.some((p) => p.statement === proposition.statement);
58
+ } while (isDuplicate);
59
+ res.push(proposition);
60
+ }
61
+ return (0, exercise_1.shuffleProps)(res, n);
62
+ };
63
+ const question = {
64
+ answer: answer,
65
+ instruction: isFromEvolutionToCM
66
+ ? `Quel est le coefficient multiplicateur associé à une ${isHausse ? 'hausse' : 'baisse'} de $${isHausse ? evolution : evolution.toString().slice(1)}\\%$ ?`
67
+ : `Quelle est l'évolution en pourcentage associée à un coefficient multiplicateur de $${CM}$ ?`,
68
+ keys: ['percent'],
69
+ getPropositions,
70
+ answerFormat: 'tex',
71
+ };
72
+ return question;
73
+ }
74
+ exports.getEvolutionToCmQuestion = getEvolutionToCmQuestion;
@@ -0,0 +1,22 @@
1
+ import { MathExercise, Question } from '../../exercises/exercise';
2
+ export declare const explicitFormulaUsage: MathExercise;
3
+ /**
4
+ *
5
+ * expres alg possibles :
6
+ * poly: deg1, deg2
7
+ * trigo
8
+ * inverse
9
+ * frac ratio
10
+ * sqrt
11
+ * exp ln
12
+ * powers
13
+ */
14
+ /**
15
+ *
16
+ * soit un = ...
17
+ * calculer u3
18
+ * donc il faut le tex de la suite + la valeur en 3
19
+ * deg2, frac rac
20
+ */
21
+ export declare function getExplicitFormulaUsageQuestion(): Question;
22
+ //# sourceMappingURL=explicitFormulaUsage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"explicitFormulaUsage.d.ts","sourceRoot":"","sources":["../../../src/exercises/sequences/explicitFormulaUsage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,YAAY,EAAe,QAAQ,EAAqB,MAAM,0BAA0B,CAAC;AAOhH,eAAO,MAAM,oBAAoB,EAAE,YAWlC,CAAC;AAEF;;;;;;;;;;GAUG;AACH;;;;;;GAMG;AACH,wBAAgB,+BAA+B,IAAI,QAAQ,CAiD1D"}
@@ -0,0 +1,82 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getExplicitFormulaUsageQuestion = exports.explicitFormulaUsage = void 0;
4
+ const exercise_1 = require("../../exercises/exercise");
5
+ const getDistinctQuestions_1 = require("../../exercises/utils/getDistinctQuestions");
6
+ const polynomial_1 = require("../../math/polynomials/polynomial");
7
+ const randint_1 = require("../../math/utils/random/randint");
8
+ const uuid_1 = require("uuid");
9
+ exports.explicitFormulaUsage = {
10
+ id: 'explicitFormulaUsage',
11
+ connector: '=',
12
+ instruction: '',
13
+ label: "Utiliser la formule explicite d'une suite",
14
+ levels: ['1reESM', '1reSpé', '1reTech'],
15
+ isSingleStep: true,
16
+ sections: ['Suites'],
17
+ generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getExplicitFormulaUsageQuestion, nb),
18
+ qcmTimer: 60,
19
+ freeTimer: 60,
20
+ };
21
+ /**
22
+ *
23
+ * expres alg possibles :
24
+ * poly: deg1, deg2
25
+ * trigo
26
+ * inverse
27
+ * frac ratio
28
+ * sqrt
29
+ * exp ln
30
+ * powers
31
+ */
32
+ /**
33
+ *
34
+ * soit un = ...
35
+ * calculer u3
36
+ * donc il faut le tex de la suite + la valeur en 3
37
+ * deg2, frac rac
38
+ */
39
+ function getExplicitFormulaUsageQuestion() {
40
+ const u = polynomial_1.PolynomialConstructor.randomWithOrder(2, 'n');
41
+ const rank = (0, randint_1.randint)(0, 4);
42
+ const answer = u.calculate(rank);
43
+ const getPropositions = (n) => {
44
+ const res = [];
45
+ res.push({
46
+ id: (0, uuid_1.v4)(),
47
+ statement: answer + '',
48
+ isRightAnswer: true,
49
+ format: 'tex',
50
+ });
51
+ (0, exercise_1.tryToAddWrongProp)(res, u.calculate(rank - 1) + '');
52
+ (0, exercise_1.tryToAddWrongProp)(res, u.calculate(rank + 1) + '');
53
+ const missing = n - res.length;
54
+ for (let i = 0; i < missing; i++) {
55
+ let isDuplicate;
56
+ let proposition;
57
+ do {
58
+ const wrongAnswer = (0, randint_1.randint)(-100, 100) + '';
59
+ proposition = {
60
+ id: (0, uuid_1.v4)() + ``,
61
+ statement: wrongAnswer,
62
+ isRightAnswer: false,
63
+ format: 'tex',
64
+ };
65
+ isDuplicate = res.some((p) => p.statement === proposition.statement);
66
+ } while (isDuplicate);
67
+ res.push(proposition);
68
+ }
69
+ return (0, exercise_1.shuffleProps)(res, n);
70
+ };
71
+ const question = {
72
+ answer: answer + '',
73
+ instruction: `Soit $u$ la suite définie pour tout $n\\geq 0$ par $u_n = ${u
74
+ .toTree()
75
+ .toTex()}$. Calculer $u_${rank}$.`,
76
+ keys: [],
77
+ getPropositions,
78
+ answerFormat: 'tex',
79
+ };
80
+ return question;
81
+ }
82
+ exports.getExplicitFormulaUsageQuestion = getExplicitFormulaUsageQuestion;
@@ -0,0 +1,4 @@
1
+ import { MathExercise, Question } from '../../exercises/exercise';
2
+ export declare const genericSequenceVariations: MathExercise;
3
+ export declare function getGenericSequenceVariationsQuestion(): Question;
4
+ //# sourceMappingURL=genericSequenceVariations.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"genericSequenceVariations.d.ts","sourceRoot":"","sources":["../../../src/exercises/sequences/genericSequenceVariations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,YAAY,EAAe,QAAQ,EAAqB,MAAM,0BAA0B,CAAC;AAOhH,eAAO,MAAM,yBAAyB,EAAE,YAYvC,CAAC;AAEF,wBAAgB,oCAAoC,IAAI,QAAQ,CAsC/D"}
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getGenericSequenceVariationsQuestion = exports.genericSequenceVariations = void 0;
4
+ const exercise_1 = require("../../exercises/exercise");
5
+ const getDistinctQuestions_1 = require("../../exercises/utils/getDistinctQuestions");
6
+ const polynomial_1 = require("../../math/polynomials/polynomial");
7
+ const randint_1 = require("../../math/utils/random/randint");
8
+ const uuid_1 = require("uuid");
9
+ exports.genericSequenceVariations = {
10
+ id: 'genericSequenceVariations',
11
+ connector: '=',
12
+ instruction: '',
13
+ label: "Déterminer le sens de variations d'une suite en étudiant la différence de deux termes",
14
+ levels: ['1reESM', '1rePro', '1reTech'],
15
+ isSingleStep: true,
16
+ sections: ['Suites'],
17
+ generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getGenericSequenceVariationsQuestion, nb),
18
+ qcmTimer: 60,
19
+ freeTimer: 60,
20
+ answerType: 'QCM',
21
+ };
22
+ function getGenericSequenceVariationsQuestion() {
23
+ const u = polynomial_1.PolynomialConstructor.randomWithOrder(2, 'n');
24
+ const [b, a] = u.coefficients.slice(1);
25
+ const root = Math.ceil((-a - b) / (2 * a));
26
+ const answer = root <= 0
27
+ ? a > 0
28
+ ? 'Croissante'
29
+ : 'Décroissante'
30
+ : `${a > 0 ? 'Croissante' : 'Décroissante'} à partir du rang ${root}`;
31
+ const getPropositions = (n) => {
32
+ const res = [];
33
+ res.push({
34
+ id: (0, uuid_1.v4)(),
35
+ statement: answer,
36
+ isRightAnswer: true,
37
+ format: 'raw',
38
+ });
39
+ (0, exercise_1.tryToAddWrongProp)(res, 'Croissante', 'raw');
40
+ (0, exercise_1.tryToAddWrongProp)(res, 'Décroissante', 'raw');
41
+ let fakeRoot = root <= 0 ? (0, randint_1.randint)(1, 10) : root;
42
+ (0, exercise_1.tryToAddWrongProp)(res, `Croissante à partir du rang ${fakeRoot}`, 'raw');
43
+ (0, exercise_1.tryToAddWrongProp)(res, `Décroissante à partir du rang ${fakeRoot}`, 'raw');
44
+ return (0, exercise_1.shuffleProps)(res, n);
45
+ };
46
+ const question = {
47
+ answer,
48
+ instruction: `Soit $u$ la suite définie par $u_n = ${u.toTree().toTex()}$. Quel est le sens de variations de $u$ ?`,
49
+ keys: [],
50
+ getPropositions,
51
+ answerFormat: 'raw',
52
+ };
53
+ return question;
54
+ }
55
+ exports.getGenericSequenceVariationsQuestion = getGenericSequenceVariationsQuestion;
@@ -0,0 +1,4 @@
1
+ import { MathExercise, Question } from '../../exercises/exercise';
2
+ export declare const recurrenceFormulaUsage: MathExercise;
3
+ export declare function getRecurrenceFormulaUsageQuestion(): Question;
4
+ //# sourceMappingURL=recurrenceFormulaUsage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"recurrenceFormulaUsage.d.ts","sourceRoot":"","sources":["../../../src/exercises/sequences/recurrenceFormulaUsage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAgB,YAAY,EAAe,QAAQ,EAAqB,MAAM,0BAA0B,CAAC;AAMhH,eAAO,MAAM,sBAAsB,EAAE,YAWpC,CAAC;AAEF,wBAAgB,iCAAiC,IAAI,QAAQ,CAsD5D"}
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getRecurrenceFormulaUsageQuestion = exports.recurrenceFormulaUsage = void 0;
4
+ const exercise_1 = require("../../exercises/exercise");
5
+ const getDistinctQuestions_1 = require("../../exercises/utils/getDistinctQuestions");
6
+ const polynomial_1 = require("../../math/polynomials/polynomial");
7
+ const randint_1 = require("../../math/utils/random/randint");
8
+ const uuid_1 = require("uuid");
9
+ exports.recurrenceFormulaUsage = {
10
+ id: 'recurrenceFormulaUsage',
11
+ connector: '=',
12
+ instruction: '',
13
+ label: "Utiliser la formule de récurrence d'une suite",
14
+ levels: ['1reESM', '1reSpé', '1reTech'],
15
+ isSingleStep: true,
16
+ sections: ['Suites'],
17
+ generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getRecurrenceFormulaUsageQuestion, nb),
18
+ qcmTimer: 60,
19
+ freeTimer: 60,
20
+ };
21
+ function getRecurrenceFormulaUsageQuestion() {
22
+ const coeffs = [(0, randint_1.randint)(-5, 6), (0, randint_1.randint)(-5, 6), (0, randint_1.randint)(-3, 4, [0])];
23
+ const u = new polynomial_1.Polynomial(coeffs, 'u_n');
24
+ const u0 = (0, randint_1.randint)(-2, 3, [0]);
25
+ const rank = (0, randint_1.randint)(1, 4);
26
+ let currentValue = u0;
27
+ for (let i = 0; i < rank; i++) {
28
+ currentValue = u.calculate(currentValue);
29
+ }
30
+ const answer = currentValue + '';
31
+ const getPropositions = (n) => {
32
+ const res = [];
33
+ res.push({
34
+ id: (0, uuid_1.v4)(),
35
+ statement: answer + '',
36
+ isRightAnswer: true,
37
+ format: 'tex',
38
+ });
39
+ (0, exercise_1.tryToAddWrongProp)(res, u.calculate(rank) + '');
40
+ const missing = n - res.length;
41
+ for (let i = 0; i < missing; i++) {
42
+ let isDuplicate;
43
+ let proposition;
44
+ do {
45
+ const wrongAnswer = (0, randint_1.randint)(-100, 100) + '';
46
+ proposition = {
47
+ id: (0, uuid_1.v4)() + ``,
48
+ statement: wrongAnswer,
49
+ isRightAnswer: false,
50
+ format: 'tex',
51
+ };
52
+ isDuplicate = res.some((p) => p.statement === proposition.statement);
53
+ } while (isDuplicate);
54
+ res.push(proposition);
55
+ }
56
+ return (0, exercise_1.shuffleProps)(res, n);
57
+ };
58
+ const question = {
59
+ answer: answer + '',
60
+ instruction: `Soit $u$ la suite définie par $u_0 = ${u0}$ et pour tout $n\\geq 1$, $u_{n+1} = ${u
61
+ .toTree()
62
+ .toTex()}$. Calculer $u_${rank}$.`,
63
+ keys: [],
64
+ getPropositions,
65
+ answerFormat: 'tex',
66
+ };
67
+ return question;
68
+ }
69
+ exports.getRecurrenceFormulaUsageQuestion = getRecurrenceFormulaUsageQuestion;
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=getAdaptedCoords.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"getAdaptedCoords.d.ts","sourceRoot":"","sources":["../../../../src/exercises/utils/geogebra/getAdaptedCoords.ts"],"names":[],"mappings":""}
@@ -0,0 +1 @@
1
+ "use strict";
@@ -1,5 +1,7 @@
1
1
  import { Node } from '../../tree/nodes/node';
2
+ import { MathSet } from '../sets/mathSet';
2
3
  export declare abstract class PointConstructor {
4
+ static random(domainX?: MathSet, domainY?: MathSet): Point;
3
5
  }
4
6
  export declare class Point {
5
7
  name: string;
@@ -1 +1 @@
1
- {"version":3,"file":"point.d.ts","sourceRoot":"","sources":["../../../src/math/geometry/point.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAS7C,8BAAsB,gBAAgB;CAMrC;AAED,qBAAa,KAAK;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,CAAC,EAAE,IAAI,CAAC;IACR,CAAC,EAAE,IAAI,CAAC;gBACI,IAAI,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI;IAM1C,KAAK,IAAI,MAAM;IAIf,eAAe,IAAI,MAAM;IAIzB,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,cAAc,CAAC,CAAC,EAAE,KAAK,GAAG,IAAI;IAO9B,OAAO,CAAC,CAAC,EAAE,KAAK,GAAG,OAAO;CAG3B;AAED;;;;;;;;;;;;GAYG"}
1
+ {"version":3,"file":"point.d.ts","sourceRoot":"","sources":["../../../src/math/geometry/point.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAQ7C,OAAO,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAG1C,8BAAsB,gBAAgB;IACpC,MAAM,CAAC,MAAM,CAAC,OAAO,GAAE,OAAqC,EAAE,OAAO,GAAE,OAAqC,GAAG,KAAK;CAOrH;AAED,qBAAa,KAAK;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,CAAC,EAAE,IAAI,CAAC;IACR,CAAC,EAAE,IAAI,CAAC;gBACI,IAAI,EAAE,MAAM,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI;IAM1C,KAAK,IAAI,MAAM;IAIf,eAAe,IAAI,MAAM;IAIzB,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,cAAc,CAAC,CAAC,EAAE,KAAK,GAAG,IAAI;IAO9B,OAAO,CAAC,CAAC,EAAE,KAAK,GAAG,OAAO;CAG3B;AAED;;;;;;;;;;;;GAYG"}
@@ -9,7 +9,15 @@ const powerNode_1 = require("../../tree/nodes/operators/powerNode");
9
9
  const substractNode_1 = require("../../tree/nodes/operators/substractNode");
10
10
  const simplify_1 = require("../../tree/parsers/simplify");
11
11
  const mathjs_1 = require("mathjs");
12
+ const intervals_1 = require("../sets/intervals/intervals");
12
13
  class PointConstructor {
14
+ static random(domainX = new intervals_1.Interval('[[-10; 10]]'), domainY = new intervals_1.Interval('[[-10; 10]]')) {
15
+ const x = domainX.getRandomElement();
16
+ const y = domainY.getRandomElement();
17
+ if (x === null || y === null)
18
+ throw Error("can't build point with thoses sets");
19
+ return new Point('A', new numberNode_1.NumberNode(x.value), new numberNode_1.NumberNode(y.value));
20
+ }
13
21
  }
14
22
  exports.PointConstructor = PointConstructor;
15
23
  class Point {
@@ -2,6 +2,13 @@ import { Node } from '../../tree/nodes/node';
2
2
  export declare abstract class PolynomialConstructor {
3
3
  static randomWithOrder(order: number, variable?: string): Polynomial;
4
4
  static random(maxOrder: number, variable?: string): Polynomial;
5
+ /**
6
+ *
7
+ * @param maxOrder included
8
+ * @param length
9
+ * @param variable
10
+ * @returns
11
+ */
5
12
  static randomWithLength(maxOrder: number, length: number, variable?: string): Polynomial;
6
13
  static randomWithLengthAndSameSigns(maxOrder: number, length: number, variable?: string): Polynomial;
7
14
  static randomNoFI(maxOrder: number, to: '+\\infty' | '-\\infty', length?: number, variable?: string): Polynomial;
@@ -1 +1 @@
1
- {"version":3,"file":"polynomial.d.ts","sourceRoot":"","sources":["../../../src/math/polynomials/polynomial.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAW7C,8BAAsB,qBAAqB;IACzC,MAAM,CAAC,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;IAa5D,MAAM,CAAC,MAAM,CAAC,QAAQ,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;IActD,MAAM,CAAC,gBAAgB,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;IAmBhF,MAAM,CAAC,4BAA4B,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;IAmB5F,MAAM,CAAC,UAAU,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,UAAU,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;CAyBzG;AAED,qBAAa,UAAU;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE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AAE,EAAE,UAAU,GAAG,UAAU,EAAE,MAAM,CAAC,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAY;CAyBzG;AAED,qBAAa,UAAU;IACrB,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,YAAY,EAAE,MAAM,EAAE,CAAC;IAEvB;;;;OAIG;gBACS,YAAY,EAAE,MAAM,EAAE,EAAE,QAAQ,GAAE,MAAY;IAS1D,MAAM,CAAC,CAAC,EAAE,UAAU,GAAG,OAAO;IAG9B,QAAQ,IAAI,MAAM,EAAE;IAkCpB,GAAG,CAAC,CAAC,EAAE,UAAU,GAAG,UAAU;IAkB9B,KAAK,CAAC,EAAE,EAAE,MAAM,GAAG,UAAU;IAO7B,QAAQ,CAAC,CAAC,EAAE,UAAU,GAAG,UAAU;IAsBnC,QAAQ,IAAI,UAAU;IAOtB,QAAQ,IAAI,UAAU;IAQtB,SAAS,IAAI,UAAU;IAMvB,SAAS,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM;IAM5B,QAAQ,CAAC,EAAE,EAAE,UAAU,GAAG,UAAU,GAAG,MAAM;IAiB7C,MAAM,IAAI,IAAI;IAmCd,KAAK,IAAI,MAAM;IAkBf,QAAQ,IAAI,MAAM;CAGnB"}
@@ -33,6 +33,13 @@ class PolynomialConstructor {
33
33
  coefficients.push((0, randint_1.randint)(-9, 10, [0]));
34
34
  return new Polynomial(coefficients, variable);
35
35
  }
36
+ /**
37
+ *
38
+ * @param maxOrder included
39
+ * @param length
40
+ * @param variable
41
+ * @returns
42
+ */
36
43
  static randomWithLength(maxOrder, length, variable = 'x') {
37
44
  if (maxOrder < 0) {
38
45
  throw Error('Order must be a non-negative integer');
@@ -11,12 +11,14 @@ export declare class Sequence {
11
11
  firstTerm: Node;
12
12
  recurrenceFormula?: string;
13
13
  explicitFormula?: string;
14
- constructor({ type, recurrenceFormula, explicitFormula, firstRank, firstTerm, }: {
14
+ recurrenceEvaluator?: (x: number) => number;
15
+ constructor({ type, recurrenceFormula, explicitFormula, firstRank, firstTerm, recurrenceEvaluator, }: {
15
16
  type: SequenceType;
16
17
  recurrenceFormula?: string;
17
18
  explicitFormula?: string;
18
19
  firstRank: Integer;
19
20
  firstTerm: Node;
21
+ recurrenceEvaluator: (x: number) => number;
20
22
  });
21
23
  }
22
24
  export {};
@@ -1 +1 @@
1
- {"version":3,"file":"sequence.d.ts","sourceRoot":"","sources":["../../../src/math/sequences/sequence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AAErD,aAAK,YAAY;IACf,UAAU,IAAA;IACV,SAAS,IAAA;IACT,KAAK,IAAA;CACN;AAED,qBAAa,QAAQ;IACnB,IAAI,EAAE,YAAY,CAAC;IACnB,SAAS,EAAE,OAAO,CAAkB;IACpC,SAAS,EAAE,IAAI,CAAC;IAChB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;gBAEb,EACV,IAAI,EACJ,iBAAiB,EACjB,eAAe,EACf,SAAS,EACT,SAAS,GACV,EAAE;QACD,IAAI,EAAE,YAAY,CAAC;QACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;QAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB,SAAS,EAAE,OAAO,CAAC;QACnB,SAAS,EAAE,IAAI,CAAC;KACjB;CAOF"}
1
+ {"version":3,"file":"sequence.d.ts","sourceRoot":"","sources":["../../../src/math/sequences/sequence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAC;AAErD,aAAK,YAAY;IACf,UAAU,IAAA;IACV,SAAS,IAAA;IACT,KAAK,IAAA;CACN;AAED,qBAAa,QAAQ;IACnB,IAAI,EAAE,YAAY,CAAC;IACnB,SAAS,EAAE,OAAO,CAAkB;IACpC,SAAS,EAAE,IAAI,CAAC;IAChB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,mBAAmB,CAAC,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;gBAChC,EACV,IAAI,EACJ,iBAAiB,EACjB,eAAe,EACf,SAAS,EACT,SAAS,EACT,mBAAmB,GACpB,EAAE;QACD,IAAI,EAAE,YAAY,CAAC;QACnB,iBAAiB,CAAC,EAAE,MAAM,CAAC;QAC3B,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB,SAAS,EAAE,OAAO,CAAC;QACnB,SAAS,EAAE,IAAI,CAAC;QAChB,mBAAmB,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAC;KAC5C;CAQF"}
@@ -9,13 +9,14 @@ var SequenceType;
9
9
  SequenceType[SequenceType["other"] = 2] = "other";
10
10
  })(SequenceType || (SequenceType = {}));
11
11
  class Sequence {
12
- constructor({ type, recurrenceFormula, explicitFormula, firstRank, firstTerm, }) {
12
+ constructor({ type, recurrenceFormula, explicitFormula, firstRank, firstTerm, recurrenceEvaluator, }) {
13
13
  this.firstRank = new integer_1.Integer(0);
14
14
  this.type = type;
15
15
  this.firstTerm = firstTerm;
16
16
  this.recurrenceFormula = recurrenceFormula;
17
17
  this.explicitFormula = explicitFormula;
18
18
  this.firstRank = firstRank;
19
+ this.recurrenceEvaluator = recurrenceEvaluator;
19
20
  }
20
21
  }
21
22
  exports.Sequence = Sequence;
@@ -1,12 +1,14 @@
1
1
  export type KeyId =
2
2
  /**units */
3
- 'cm' | 'cm2' | 'degree' | 'Hz' | 'mol' | 'kJ' | 'mL'
3
+ 'cm' | 'cm2' | 'celsius' | 'Hz' | 'mol' | 'kJ' | 'mL'
4
4
  /**utility */
5
- | 'custom' | 'right' | 'left' | 'rightarrow' | 'overrightarrow' | 'del' | 'close' | 'switch' | 'ou' | 'et' | 'maj'
5
+ | 'custom' | 'right' | 'left' | 'rightarrow' | 'del' | 'close' | 'switch' | 'ou' | 'et' | 'maj'
6
+ /**geometry */
7
+ | 'overrightarrow' | 'degree'
6
8
  /**operations */
7
- | 'plus' | 'minus' | 'times' | 'frac' | 'obelus' | 'sqrt' | 'sqrtCub' | 'square' | 'cube' | 'power' | 'percent' | 'leftParenthesis' | 'rightParenthesis' | 'equal' | 'comma' | 'semicolon' | 'dot' | 'sup' | 'inf' | 'geq' | 'leq' | 'approx'
9
+ | 'plus' | 'minus' | 'times' | 'frac' | 'obelus' | 'sqrt' | 'sqrtCub' | 'square' | 'cube' | 'power' | 'percent' | 'leftParenthesis' | 'rightParenthesis' | 'equal' | 'comma' | 'semicolon' | 'dot' | 'sup' | 'inf' | 'geq' | 'leq' | 'approx' | 'xsquare' | 'xcube'
8
10
  /**sets */
9
- | 'belongs' | 'notin' | 'cap' | 'cup' | 'lbrace' | 'rbrace' | 'lbracket' | 'rbracket' | 'emptyset' | 'naturals' | 'integers' | 'rationals' | 'decimals' | 'reals' | 'complex' | 'ast' | 'degree' | 'del' | 'right' | 'left' | 'rightarrow' | 'overrightarrow' | 'infty'
11
+ | 'belongs' | 'notin' | 'cap' | 'cup' | 'lbrace' | 'rbrace' | 'lbracket' | 'rbracket' | 'emptyset' | 'naturals' | 'integers' | 'rationals' | 'decimals' | 'reals' | 'complex' | 'ast' | 'del' | 'right' | 'left' | 'rightarrow' | 'overrightarrow' | 'infty'
10
12
  /**fcts */
11
13
  | 'log' | 'ln' | 'exp' | 'epower' | 'sin' | 'cos' | 'tan' | 'arccos' | 'arcsin' | 'arctan' | 'abs'
12
14
  /**sequences */
@@ -1 +1 @@
1
- {"version":3,"file":"keyIds.d.ts","sourceRoot":"","sources":["../../src/types/keyIds.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK;AACf,WAAW;AACT,IAAI,GACJ,KAAK,GACL,QAAQ,GACR,IAAI,GACJ,KAAK,GACL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X,oBAAoB,GACpB,KAAK,GACL,mBAAmB,GACnB,QAAQ,GACR,UAAU,GACV,SAAS,GACT,SAAS,GACT,iBAAiB,GACjB,QAAQ,GACR,SAAS,GACT,aAAa,GACb,kBAAkB,GAClB,oBAAoB,GACpB,mBAAmB,GACnB,QAAQ,GACR,SAAS,GACT,eAAe,GACf,UAAU,GACV,gBAAgB,GAChB,SAAS,GACT,qBAAqB,GACrB,qBAAqB,GACrB,kBAAkB,GAClB,mBAAmB,GACnB,mBAAmB,GACnB,sBAAsB,GACtB,oBAAoB,GACpB,mBAAmB,GACnB,yBAAyB,GACzB,mBAAmB,GACnB,MAAM,GACN,kBAAkB,GAClB,wBAAwB,GACxB,sBAAsB,GACtB,sBAAsB,GACtB,uBAAuB,GACvB,qBAAqB,GACrB,qBAAqB,GACrB,uBAAuB,GACvB,mBAAmB,GACnB,QAAQ,GACR,mBAAmB,GACnB,mBAAmB,GACnB,QAAQ,GACR,uBAAuB,GACvB,QAAQ,GACR,sBAAsB,GACtB,QAAQ,GACR,sBAAsB,GACtB,OAAO,GACP,sBAAsB,GACtB,sBAAsB,GACtB,kBAAkB,GAClB,wBAAwB,GACxB,qBAAqB,GACrB,UAAU,GACV,mBAAmB,GACnB,yBAAyB,GACzB,iBAAiB,GACjB,uBAAuB,GACvB,iBAAiB,GACjB,oBAAoB,GACpB,iBAAiB,GACjB,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,sBAAsB,GACtB,oBAAoB,GACpB,eAAe,GACf,aAAa,GACb,aAAa,GACb,eAAe,GACf,eAAe,GACf,eAAe,GACf,uBAAuB,GACvB,gBAAgB,GAChB,mBAAmB,GACnB,sBAAsB,GACtB,qBAAqB,GACrB,kBAAkB,GAClB,wBAAwB,GACxB,uBAAuB,CAAC"}
1
+ {"version":3,"file":"keyIds.d.ts","sourceRoot":"","sources":["../../src/types/keyIds.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK;AACf,WAAW;AACT,IAAI,GACJ,K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U,GACV,SAAS,GACT,aAAa,GACb,oBAAoB,GACpB,SAAS,GACT,gBAAgB,GAChB,WAAW,GACX,oBAAoB,GACpB,KAAK,GACL,mBAAmB,GACnB,QAAQ,GACR,UAAU,GACV,SAAS,GACT,SAAS,GACT,iBAAiB,GACjB,QAAQ,GACR,SAAS,GACT,aAAa,GACb,kBAAkB,GAClB,oBAAoB,GACpB,mBAAmB,GACnB,QAAQ,GACR,SAAS,GACT,eAAe,GACf,UAAU,GACV,gBAAgB,GAChB,SAAS,GACT,qBAAqB,GACrB,qBAAqB,GACrB,kBAAkB,GAClB,mBAAmB,GACnB,mBAAmB,GACnB,sBAAsB,GACtB,oBAAoB,GACpB,mBAAmB,GACnB,yBAAyB,GACzB,mBAAmB,GACnB,MAAM,GACN,kBAAkB,GAClB,wBAAwB,GACxB,sBAAsB,GACtB,sBAAsB,GACtB,uBAAuB,GACvB,qBAAqB,GACrB,qBAAqB,GACrB,uBAAuB,GACvB,mBAAmB,GACnB,QAAQ,GACR,mBAAmB,GACnB,mBAAmB,GACnB,QAAQ,GACR,uBAAuB,GACvB,QAAQ,GACR,sBAAsB,GACtB,QAAQ,GACR,sBAAsB,GACtB,OAAO,GACP,sBAAsB,GACtB,sBAAsB,GACtB,kBAAkB,GAClB,wBAAwB,GACxB,qBAAqB,GACrB,UAAU,GACV,mBAAmB,GACnB,yBAAyB,GACzB,iBAAiB,GACjB,uBAAuB,GACvB,iBAAiB,GACjB,oBAAoB,GACpB,iBAAiB,GACjB,kBAAkB,GAClB,qBAAqB,GACrB,mBAAmB,GACnB,sBAAsB,GACtB,oBAAoB,GACpB,eAAe,GACf,aAAa,GACb,aAAa,GACb,eAAe,GACf,eAAe,GACf,eAAe,GACf,uBAAuB,GACvB,gBAAgB,GAChB,mBAAmB,GACnB,sBAAsB,GACtB,qBAAqB,GACrB,kBAAkB,GAClB,wBAAwB,GACxB,uBAAuB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const randomLetter: (isMaj?: boolean) => string;
2
+ //# sourceMappingURL=randomLetter.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"randomLetter.d.ts","sourceRoot":"","sources":["../../src/utils/randomLetter.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,YAAY,WAAW,OAAO,WAI1C,CAAC"}
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.randomLetter = void 0;
4
+ const randomLetter = (isMaj = false) => {
5
+ if (isMaj)
6
+ return String.fromCharCode(65 + Math.floor(Math.random() * 26));
7
+ return String.fromCharCode(97 + Math.floor(Math.random() * 26));
8
+ };
9
+ exports.randomLetter = randomLetter;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "math-exercises",
3
- "version": "1.4.15",
3
+ "version": "1.4.17",
4
4
  "description": "Math exercises generator for middle school and high school",
5
5
  "main": "lib/index.js",
6
6
  "files": [
@@ -31,7 +31,6 @@
31
31
  "jest": "^29.7.0",
32
32
  "nodemon": "^2.0.20",
33
33
  "prettier": "^2.8.4",
34
- "react-math-keyboard": "^1.3.1",
35
34
  "ts-jest": "^29.1.1",
36
35
  "ts-node": "^10.9.1",
37
36
  "ts-node-dev": "^2.0.0",