math-exercises 2.2.37 → 2.2.38
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/conversion/aeraConversion.d.ts.map +1 -1
- package/lib/exercises/math/conversion/aeraConversion.js +1 -2
- package/lib/exercises/math/functions/basics/imageAntecedentFromSentence.d.ts +9 -0
- package/lib/exercises/math/functions/basics/imageAntecedentFromSentence.d.ts.map +1 -0
- package/lib/exercises/math/functions/basics/imageAntecedentFromSentence.js +76 -0
- package/lib/exercises/math/functions/basics/index.d.ts +1 -0
- package/lib/exercises/math/functions/basics/index.d.ts.map +1 -1
- package/lib/exercises/math/functions/basics/index.js +1 -0
- package/lib/exercises/math/geometry/areas/circleRadiusFromArea.d.ts +7 -0
- package/lib/exercises/math/geometry/areas/circleRadiusFromArea.d.ts.map +1 -0
- package/lib/exercises/math/geometry/areas/circleRadiusFromArea.js +108 -0
- package/lib/exercises/math/geometry/areas/index.d.ts +3 -0
- package/lib/exercises/math/geometry/areas/index.d.ts.map +1 -1
- package/lib/exercises/math/geometry/areas/index.js +3 -0
- package/lib/exercises/math/geometry/areas/rectangleSideFromArea.d.ts +8 -0
- package/lib/exercises/math/geometry/areas/rectangleSideFromArea.d.ts.map +1 -0
- package/lib/exercises/math/geometry/areas/rectangleSideFromArea.js +95 -0
- package/lib/exercises/math/geometry/areas/squareSideFromArea.d.ts +8 -0
- package/lib/exercises/math/geometry/areas/squareSideFromArea.d.ts.map +1 -0
- package/lib/exercises/math/geometry/areas/squareSideFromArea.js +77 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnSemiLine.js +1 -1
- package/lib/exercises/math/geometry/perimeters/circleRadiusFromPerimeter.d.ts +7 -0
- package/lib/exercises/math/geometry/perimeters/circleRadiusFromPerimeter.d.ts.map +1 -0
- package/lib/exercises/math/geometry/perimeters/circleRadiusFromPerimeter.js +102 -0
- package/lib/exercises/math/geometry/perimeters/index.d.ts +3 -0
- package/lib/exercises/math/geometry/perimeters/index.d.ts.map +1 -1
- package/lib/exercises/math/geometry/perimeters/index.js +3 -0
- package/lib/exercises/math/geometry/perimeters/rectangleSideFromPerimeter.d.ts +8 -0
- package/lib/exercises/math/geometry/perimeters/rectangleSideFromPerimeter.d.ts.map +1 -0
- package/lib/exercises/math/geometry/perimeters/rectangleSideFromPerimeter.js +114 -0
- package/lib/exercises/math/geometry/perimeters/squareSideFromPerimeter.d.ts +7 -0
- package/lib/exercises/math/geometry/perimeters/squareSideFromPerimeter.d.ts.map +1 -0
- package/lib/exercises/math/geometry/perimeters/squareSideFromPerimeter.js +74 -0
- package/lib/exercises/math/trigonometry/equationCosOnRandomInterval.d.ts.map +1 -1
- package/lib/exercises/math/trigonometry/equationCosOnRandomInterval.js +14 -5
- package/lib/exercises/math/trigonometry/equationSinOnRandomInterval.js +1 -1
- package/lib/exercises/math/trigonometry/index.d.ts +1 -0
- package/lib/exercises/math/trigonometry/index.d.ts.map +1 -1
- package/lib/exercises/math/trigonometry/index.js +1 -1
- package/lib/exercises/pc/calibrationCurveOfSolution.js +4 -4
- package/lib/index.d.ts +22 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/math/numbers/reals/real.d.ts +2 -0
- package/lib/math/numbers/reals/real.d.ts.map +1 -1
- package/lib/math/numbers/reals/real.js +7 -0
- package/lib/tree/nodes/operators/fractionNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/fractionNode.js +2 -1
- package/lib/types/keyIds.d.ts +1 -1
- package/lib/types/keyIds.d.ts.map +1 -1
- package/package.json +2 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"aeraConversion.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/conversion/aeraConversion.ts"],"names":[],"mappings":"AAMA,OAAO,EACL,QAAQ,EAQT,MAAM,gBAAgB,CAAC;AAExB,KAAK,WAAW,GAAG;IACjB,eAAe,EAAE,MAAM,CAAC;IACxB,0BAA0B,EAAE,MAAM,CAAC;IACnC,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;
|
|
1
|
+
{"version":3,"file":"aeraConversion.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/conversion/aeraConversion.ts"],"names":[],"mappings":"AAMA,OAAO,EACL,QAAQ,EAQT,MAAM,gBAAgB,CAAC;AAExB,KAAK,WAAW,GAAG;IACjB,eAAe,EAAE,MAAM,CAAC;IACxB,0BAA0B,EAAE,MAAM,CAAC;IACnC,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AA2DF,eAAO,MAAM,cAAc,EAAE,QAAQ,CAAC,WAAW,CAahD,CAAC"}
|
|
@@ -36,8 +36,7 @@ const getPropositions = (n, { answer, randomAera, randomUnitIndex, randomUnitIns
|
|
|
36
36
|
while (propositions.length < n) {
|
|
37
37
|
const wrongAnswer = aeraDecimal
|
|
38
38
|
.multiplyByPowerOfTen(2 * (0, randint_1.randint)(-2, 4, [randomUnitIndex - randomUnitInstructionIndex]))
|
|
39
|
-
.value.
|
|
40
|
-
.replace(".", ",");
|
|
39
|
+
.value.frenchify();
|
|
41
40
|
(0, exercise_1.tryToAddWrongProp)(propositions, wrongAnswer);
|
|
42
41
|
}
|
|
43
42
|
return (0, shuffle_1.shuffle)(propositions);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise";
|
|
2
|
+
type Identifiers = {
|
|
3
|
+
isImage: boolean;
|
|
4
|
+
x: number;
|
|
5
|
+
y: number;
|
|
6
|
+
};
|
|
7
|
+
export declare const imageAntecedentFromSentence: Exercise<Identifiers>;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=imageAntecedentFromSentence.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"imageAntecedentFromSentence.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/functions/basics/imageAntecedentFromSentence.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAMlC,KAAK,WAAW,GAAG;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACX,CAAC;AAsEF,eAAO,MAAM,2BAA2B,EAAE,QAAQ,CAAC,WAAW,CAgB7D,CAAC"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.imageAntecedentFromSentence = 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 coinFlip_1 = require("../../../../utils/alea/coinFlip");
|
|
8
|
+
const getPropositions = (n, { answer, isImage, x, y }) => {
|
|
9
|
+
const propositions = [];
|
|
10
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
11
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ isImage, x: y, y: x }));
|
|
12
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, `${x}=${y}`);
|
|
13
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ isImage, x: y, y: y }));
|
|
14
|
+
// tryToAddWrongProp(propositions, getAnswer({ isImage, x: x, y: x }));
|
|
15
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
16
|
+
};
|
|
17
|
+
const getAnswer = (identifiers) => {
|
|
18
|
+
return `f\\left(${identifiers.x}\\right)=${identifiers.y}`;
|
|
19
|
+
};
|
|
20
|
+
const getInstruction = (identifiers) => {
|
|
21
|
+
let instruction = "Traduire par une égalité la phrase suivante : \n \n";
|
|
22
|
+
instruction += identifiers.isImage
|
|
23
|
+
? `
|
|
24
|
+
"L'image de $${identifiers.x}$ par $f$ est $${identifiers.y}$"
|
|
25
|
+
`
|
|
26
|
+
: `"Un antécédent de $${identifiers.y}$ par $f$ est $${identifiers.x}$"`;
|
|
27
|
+
return instruction;
|
|
28
|
+
};
|
|
29
|
+
const getHint = (identifiers) => {
|
|
30
|
+
return `Si $f(x) = y$, alors $x$ est un antécédent de $y$ par $f$, et $y$ est l'image de $x$ par $f$.`;
|
|
31
|
+
};
|
|
32
|
+
const getCorrection = (identifiers) => {
|
|
33
|
+
return `Si $f(x) = y$, alors $x$ est un antécédent de $y$ par $f$, et $y$ est l'image de $x$ par $f$. Ici, on a donc $${getAnswer(identifiers)}$`;
|
|
34
|
+
};
|
|
35
|
+
const getKeys = (identifiers) => {
|
|
36
|
+
return ["fParenthesis", "equal"];
|
|
37
|
+
};
|
|
38
|
+
const isAnswerValid = (ans, { answer, x, y }) => {
|
|
39
|
+
const reversed = answer.split("=").reverse().join("=");
|
|
40
|
+
return [answer, reversed].includes(ans);
|
|
41
|
+
};
|
|
42
|
+
const getImageAntecedentFromSentenceQuestion = () => {
|
|
43
|
+
const x = (0, randint_1.randint)(-10, 10);
|
|
44
|
+
const y = (0, randint_1.randint)(-10, 10, [x]);
|
|
45
|
+
const identifiers = {
|
|
46
|
+
isImage: (0, coinFlip_1.coinFlip)(),
|
|
47
|
+
x,
|
|
48
|
+
y,
|
|
49
|
+
};
|
|
50
|
+
const question = {
|
|
51
|
+
answer: getAnswer(identifiers),
|
|
52
|
+
instruction: getInstruction(identifiers),
|
|
53
|
+
keys: getKeys(identifiers),
|
|
54
|
+
answerFormat: "tex",
|
|
55
|
+
identifiers,
|
|
56
|
+
hint: getHint(identifiers),
|
|
57
|
+
correction: getCorrection(identifiers),
|
|
58
|
+
};
|
|
59
|
+
return question;
|
|
60
|
+
};
|
|
61
|
+
exports.imageAntecedentFromSentence = {
|
|
62
|
+
id: "imageAntecedentFromSentence",
|
|
63
|
+
connector: "\\iff",
|
|
64
|
+
label: "Traduire une phrase contenant image ou antécédent en une égalité",
|
|
65
|
+
isSingleStep: true,
|
|
66
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getImageAntecedentFromSentenceQuestion, nb),
|
|
67
|
+
qcmTimer: 60,
|
|
68
|
+
freeTimer: 60,
|
|
69
|
+
getPropositions,
|
|
70
|
+
isAnswerValid,
|
|
71
|
+
subject: "Mathématiques",
|
|
72
|
+
getHint,
|
|
73
|
+
getCorrection,
|
|
74
|
+
getAnswer,
|
|
75
|
+
hasHintAndCorrection: true,
|
|
76
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/functions/basics/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/functions/basics/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC;AAChC,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC;AACvC,cAAc,gCAAgC,CAAC;AAC/C,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,6BAA6B,CAAC;AAC5C,cAAc,+BAA+B,CAAC"}
|
|
@@ -23,3 +23,4 @@ __exportStar(require("./graphicInequation"), exports);
|
|
|
23
23
|
__exportStar(require("./twoFunctionsEquation"), exports);
|
|
24
24
|
__exportStar(require("./twoFunctionsInequation"), exports);
|
|
25
25
|
__exportStar(require("./inverseImageFunctionTable"), exports);
|
|
26
|
+
__exportStar(require("./imageAntecedentFromSentence"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"circleRadiusFromArea.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/areas/circleRadiusFromArea.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAclC,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAyFF,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,WAAW,CAgBtD,CAAC"}
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.circleRadiusFromArea = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
7
|
+
const round_1 = require("../../../../math/utils/round");
|
|
8
|
+
const sqrtNode_1 = require("../../../../tree/nodes/functions/sqrtNode");
|
|
9
|
+
const piNode_1 = require("../../../../tree/nodes/numbers/piNode");
|
|
10
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
11
|
+
const numberParser_1 = require("../../../../tree/parsers/numberParser");
|
|
12
|
+
const alignTex_1 = require("../../../../utils/latex/alignTex");
|
|
13
|
+
const getPropositions = (n, { answer, area }) => {
|
|
14
|
+
const propositions = [];
|
|
15
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
16
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(Math.sqrt(area), 2).frenchify());
|
|
17
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area / Math.PI, 2).frenchify());
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area / (2 * Math.PI), 2).frenchify());
|
|
19
|
+
while (propositions.length < n) {
|
|
20
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
21
|
+
}
|
|
22
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
23
|
+
};
|
|
24
|
+
const getAnswer = (identifiers) => {
|
|
25
|
+
return (0, round_1.round)(Math.sqrt(identifiers.area / Math.PI), 2).frenchify();
|
|
26
|
+
};
|
|
27
|
+
const getInstruction = (identifiers) => {
|
|
28
|
+
return `Calculer le rayon d'un cercle d'aire $${identifiers.area.frenchify()}$. Arrondir au centième.`;
|
|
29
|
+
};
|
|
30
|
+
const getHint = (identifiers) => {
|
|
31
|
+
return `L'aire d'un cercle est égale à :
|
|
32
|
+
|
|
33
|
+
$$
|
|
34
|
+
\\pi\\times r^2
|
|
35
|
+
$$
|
|
36
|
+
|
|
37
|
+
où $r$ est le rayon.`;
|
|
38
|
+
};
|
|
39
|
+
const getCorrection = (identifiers) => {
|
|
40
|
+
const r2 = identifiers.area / Math.PI;
|
|
41
|
+
return `L'aire d'un cercle est égale à :
|
|
42
|
+
|
|
43
|
+
$$
|
|
44
|
+
\\pi\\times r^2
|
|
45
|
+
$$
|
|
46
|
+
|
|
47
|
+
où $r$ est le rayon.
|
|
48
|
+
|
|
49
|
+
Ici, on a donc :
|
|
50
|
+
|
|
51
|
+
$$
|
|
52
|
+
${identifiers.area.frenchify()} = \\pi\\times r^2
|
|
53
|
+
$$
|
|
54
|
+
|
|
55
|
+
On isole $r^2$ dans cette équation :
|
|
56
|
+
|
|
57
|
+
${(0, alignTex_1.alignTex)([
|
|
58
|
+
["r^2", "=", new fractionNode_1.FractionNode(identifiers.area.toTree(), piNode_1.PiNode).toTex()],
|
|
59
|
+
["", "\\approx", (0, round_1.round)(r2, 2).frenchify()],
|
|
60
|
+
])}
|
|
61
|
+
|
|
62
|
+
Enfin, on obtient $r$ en prenant la racine carrée du résultat précédent :
|
|
63
|
+
|
|
64
|
+
${(0, alignTex_1.alignTex)([
|
|
65
|
+
["r", "=", new sqrtNode_1.SqrtNode((0, round_1.round)(r2, 2).toTree()).toTex()],
|
|
66
|
+
["", "\\approx", getAnswer(identifiers)],
|
|
67
|
+
])}
|
|
68
|
+
`;
|
|
69
|
+
};
|
|
70
|
+
const getKeys = (identifiers) => {
|
|
71
|
+
return [];
|
|
72
|
+
};
|
|
73
|
+
const isAnswerValid = (ans, { answer, area }) => {
|
|
74
|
+
const parsed = (0, numberParser_1.numberParser)(ans);
|
|
75
|
+
if (!parsed)
|
|
76
|
+
return false;
|
|
77
|
+
return parsed === answer;
|
|
78
|
+
};
|
|
79
|
+
const getCircleRadiusFromAreaQuestion = () => {
|
|
80
|
+
const area = (0, randfloat_1.randfloat)(1, 100, 2);
|
|
81
|
+
const identifiers = { area };
|
|
82
|
+
const question = {
|
|
83
|
+
answer: getAnswer(identifiers),
|
|
84
|
+
instruction: getInstruction(identifiers),
|
|
85
|
+
keys: getKeys(identifiers),
|
|
86
|
+
answerFormat: "tex",
|
|
87
|
+
identifiers,
|
|
88
|
+
hint: getHint(identifiers),
|
|
89
|
+
correction: getCorrection(identifiers),
|
|
90
|
+
};
|
|
91
|
+
return question;
|
|
92
|
+
};
|
|
93
|
+
exports.circleRadiusFromArea = {
|
|
94
|
+
id: "circleRadiusFromArea",
|
|
95
|
+
connector: "=",
|
|
96
|
+
label: "Calculer le rayon d'un cercle en connaissant son aire",
|
|
97
|
+
isSingleStep: true,
|
|
98
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getCircleRadiusFromAreaQuestion, nb),
|
|
99
|
+
qcmTimer: 60,
|
|
100
|
+
freeTimer: 60,
|
|
101
|
+
getPropositions,
|
|
102
|
+
isAnswerValid,
|
|
103
|
+
subject: "Mathématiques",
|
|
104
|
+
getHint,
|
|
105
|
+
getCorrection,
|
|
106
|
+
getAnswer,
|
|
107
|
+
hasHintAndCorrection: true,
|
|
108
|
+
};
|
|
@@ -4,4 +4,7 @@ export * from "./rightTriangleArea";
|
|
|
4
4
|
export * from "./squareArea";
|
|
5
5
|
export * from "./triangleArea";
|
|
6
6
|
export * from "./triangleAreaV2";
|
|
7
|
+
export * from "./squareSideFromArea";
|
|
8
|
+
export * from "./rectangleSideFromArea";
|
|
9
|
+
export * from "./circleRadiusFromArea";
|
|
7
10
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/areas/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,qBAAqB,CAAC;AACpC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/areas/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,iBAAiB,CAAC;AAChC,cAAc,qBAAqB,CAAC;AACpC,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sBAAsB,CAAC;AACrC,cAAc,yBAAyB,CAAC;AACxC,cAAc,wBAAwB,CAAC"}
|
|
@@ -20,3 +20,6 @@ __exportStar(require("./rightTriangleArea"), exports);
|
|
|
20
20
|
__exportStar(require("./squareArea"), exports);
|
|
21
21
|
__exportStar(require("./triangleArea"), exports);
|
|
22
22
|
__exportStar(require("./triangleAreaV2"), exports);
|
|
23
|
+
__exportStar(require("./squareSideFromArea"), exports);
|
|
24
|
+
__exportStar(require("./rectangleSideFromArea"), exports);
|
|
25
|
+
__exportStar(require("./circleRadiusFromArea"), exports);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rectangleSideFromArea.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/areas/rectangleSideFromArea.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAUlC,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAoFF,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,WAAW,CAiBvD,CAAC"}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.rectangleSideFromArea = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
7
|
+
const round_1 = require("../../../../math/utils/round");
|
|
8
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
9
|
+
const numberParser_1 = require("../../../../tree/parsers/numberParser");
|
|
10
|
+
const alignTex_1 = require("../../../../utils/latex/alignTex");
|
|
11
|
+
const getPropositions = (n, { answer, area, width }) => {
|
|
12
|
+
const propositions = [];
|
|
13
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
14
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area / 4, 3).frenchify());
|
|
15
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area - width, 3).frenchify());
|
|
16
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)((area - 2 * width) / 2, 3).frenchify());
|
|
17
|
+
while (propositions.length < n) {
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
19
|
+
}
|
|
20
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
21
|
+
};
|
|
22
|
+
const getAnswer = (identifiers) => {
|
|
23
|
+
return (0, round_1.round)(identifiers.area / identifiers.width, 2).frenchify();
|
|
24
|
+
};
|
|
25
|
+
const getInstruction = (identifiers) => {
|
|
26
|
+
return `Calculer la longueur d'un rectangle d'aire $${identifiers.area.frenchify()}$ et de largeur $${identifiers.width.frenchify()}$.`;
|
|
27
|
+
};
|
|
28
|
+
const getHint = (identifiers) => {
|
|
29
|
+
return `L'aire d'un rectangle est le produit de la largeur et de la longueur.`;
|
|
30
|
+
};
|
|
31
|
+
const getCorrection = (identifiers) => {
|
|
32
|
+
return `L'aire d'un rectangle est le produit de la largeur et de la longueur.
|
|
33
|
+
|
|
34
|
+
Ici, on a donc :
|
|
35
|
+
|
|
36
|
+
$$
|
|
37
|
+
${identifiers.area.frenchify()} = ${identifiers.width.frenchify()}\\times L
|
|
38
|
+
$$
|
|
39
|
+
|
|
40
|
+
Pour retrouver la longueur, on isole $L$ dans cette équation. On obtient :
|
|
41
|
+
|
|
42
|
+
${(0, alignTex_1.alignTex)([
|
|
43
|
+
[
|
|
44
|
+
"L",
|
|
45
|
+
"=",
|
|
46
|
+
`${new fractionNode_1.FractionNode(identifiers.area.toTree(), identifiers.width.toTree()).toTex()}`,
|
|
47
|
+
],
|
|
48
|
+
["", "=", getAnswer(identifiers)],
|
|
49
|
+
])}
|
|
50
|
+
`;
|
|
51
|
+
};
|
|
52
|
+
const getKeys = (identifiers) => {
|
|
53
|
+
return [];
|
|
54
|
+
};
|
|
55
|
+
const isAnswerValid = (ans, { answer, area, width }) => {
|
|
56
|
+
const parsed = (0, numberParser_1.numberParser)(ans);
|
|
57
|
+
if (!parsed)
|
|
58
|
+
return false;
|
|
59
|
+
return parsed === answer;
|
|
60
|
+
};
|
|
61
|
+
const getRectangleSideFromAreaQuestion = () => {
|
|
62
|
+
const width = (0, randfloat_1.randfloat)(1, 50, 1);
|
|
63
|
+
const length = (0, randfloat_1.randfloat)(width + 1, width + 30, 1);
|
|
64
|
+
const area = (0, round_1.round)(width * length, 5);
|
|
65
|
+
const identifiers = {
|
|
66
|
+
area,
|
|
67
|
+
width,
|
|
68
|
+
};
|
|
69
|
+
const question = {
|
|
70
|
+
answer: getAnswer(identifiers),
|
|
71
|
+
instruction: getInstruction(identifiers),
|
|
72
|
+
keys: getKeys(identifiers),
|
|
73
|
+
answerFormat: "tex",
|
|
74
|
+
identifiers,
|
|
75
|
+
hint: getHint(identifiers),
|
|
76
|
+
correction: getCorrection(identifiers),
|
|
77
|
+
};
|
|
78
|
+
return question;
|
|
79
|
+
};
|
|
80
|
+
exports.rectangleSideFromArea = {
|
|
81
|
+
id: "rectangleSideFromArea",
|
|
82
|
+
connector: "=",
|
|
83
|
+
label: "Calculer la longueur d'un rectangle en connaissant son aire et sa largeur",
|
|
84
|
+
isSingleStep: true,
|
|
85
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getRectangleSideFromAreaQuestion, nb),
|
|
86
|
+
qcmTimer: 60,
|
|
87
|
+
freeTimer: 60,
|
|
88
|
+
getPropositions,
|
|
89
|
+
isAnswerValid,
|
|
90
|
+
subject: "Mathématiques",
|
|
91
|
+
getHint,
|
|
92
|
+
getCorrection,
|
|
93
|
+
getAnswer,
|
|
94
|
+
hasHintAndCorrection: true,
|
|
95
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"squareSideFromArea.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/areas/squareSideFromArea.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAUlC,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,eAAe,EAAE,OAAO,CAAC;CAC1B,CAAC;AA+DF,eAAO,MAAM,kBAAkB,EAAE,QAAQ,CAAC,WAAW,CAgBpD,CAAC"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.squareSideFromArea = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
7
|
+
const randint_1 = require("../../../../math/utils/random/randint");
|
|
8
|
+
const round_1 = require("../../../../math/utils/round");
|
|
9
|
+
const sqrtNode_1 = require("../../../../tree/nodes/functions/sqrtNode");
|
|
10
|
+
const coinFlip_1 = require("../../../../utils/alea/coinFlip");
|
|
11
|
+
const getPropositions = (n, { answer, area }) => {
|
|
12
|
+
const propositions = [];
|
|
13
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
14
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (area * area).frenchify());
|
|
15
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area / 2, 2).frenchify());
|
|
16
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(area / 4, 2).frenchify());
|
|
17
|
+
while (propositions.length < n) {
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
19
|
+
}
|
|
20
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
21
|
+
};
|
|
22
|
+
const getAnswer = (identifiers) => {
|
|
23
|
+
return (0, round_1.round)(Math.sqrt(identifiers.area), 2).frenchify();
|
|
24
|
+
};
|
|
25
|
+
const getInstruction = (identifiers) => {
|
|
26
|
+
return `Calculer le côté d'un carré d'aire $${identifiers.area.frenchify()}$. Arrondir au centième.`;
|
|
27
|
+
};
|
|
28
|
+
const getHint = (identifiers) => {
|
|
29
|
+
return `L'aire d'un carré est égale au carré du côté.`;
|
|
30
|
+
};
|
|
31
|
+
const getCorrection = (identifiers) => {
|
|
32
|
+
return `L'aire d'un carré est égale au carré du côté. Pour retrouver le côté à partir de l'aire, il faut donc calculer la racine carrée de l'aire. Le côté du carré est donc égal à :
|
|
33
|
+
|
|
34
|
+
$$
|
|
35
|
+
${new sqrtNode_1.SqrtNode(identifiers.area.toTree()).toTex()}${identifiers.isPerfectSquare ? "=" : "\\approx"}${getAnswer(identifiers)}
|
|
36
|
+
$$
|
|
37
|
+
`;
|
|
38
|
+
};
|
|
39
|
+
const getKeys = (identifiers) => {
|
|
40
|
+
return [];
|
|
41
|
+
};
|
|
42
|
+
const isAnswerValid = (ans, { answer, area }) => {
|
|
43
|
+
const node = new sqrtNode_1.SqrtNode(area.toTree());
|
|
44
|
+
const approximation = (0, round_1.round)(Math.sqrt(area), 2).frenchify();
|
|
45
|
+
return [...node.toAllValidTexs(), approximation].includes(ans);
|
|
46
|
+
};
|
|
47
|
+
const getSquareSideFromAreaQuestion = () => {
|
|
48
|
+
const isPerfectSquare = (0, coinFlip_1.coinFlip)();
|
|
49
|
+
const area = isPerfectSquare ? (0, randint_1.randint)(1, 11) ** 2 : (0, randfloat_1.randfloat)(1, 100, 1);
|
|
50
|
+
const identifiers = { area, isPerfectSquare };
|
|
51
|
+
const question = {
|
|
52
|
+
answer: getAnswer(identifiers),
|
|
53
|
+
instruction: getInstruction(identifiers),
|
|
54
|
+
keys: getKeys(identifiers),
|
|
55
|
+
answerFormat: "tex",
|
|
56
|
+
identifiers,
|
|
57
|
+
hint: getHint(identifiers),
|
|
58
|
+
correction: getCorrection(identifiers),
|
|
59
|
+
};
|
|
60
|
+
return question;
|
|
61
|
+
};
|
|
62
|
+
exports.squareSideFromArea = {
|
|
63
|
+
id: "squareSideFromArea",
|
|
64
|
+
connector: "=",
|
|
65
|
+
label: "Calculer le côté d'un carré en connaissant son aire",
|
|
66
|
+
isSingleStep: true,
|
|
67
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getSquareSideFromAreaQuestion, nb),
|
|
68
|
+
qcmTimer: 60,
|
|
69
|
+
freeTimer: 60,
|
|
70
|
+
getPropositions,
|
|
71
|
+
isAnswerValid,
|
|
72
|
+
subject: "Mathématiques",
|
|
73
|
+
getHint,
|
|
74
|
+
getCorrection,
|
|
75
|
+
getAnswer,
|
|
76
|
+
hasHintAndCorrection: true,
|
|
77
|
+
};
|
|
@@ -106,7 +106,7 @@ const getReadAbscissOnSemiLineQuestion = () => {
|
|
|
106
106
|
break;
|
|
107
107
|
case nombre_1.NumberType.Decimal:
|
|
108
108
|
default:
|
|
109
|
-
axisUnit = (0, randfloat_1.randfloat)(0, 5, 1);
|
|
109
|
+
axisUnit = (0, randfloat_1.randfloat)(0.1, 5, 1);
|
|
110
110
|
coeff = (0, randint_1.randint)(2, 10);
|
|
111
111
|
absciss = (0, round_1.round)(axisUnit * coeff, 2);
|
|
112
112
|
oneUnitTex = axisUnit.frenchify();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"circleRadiusFromPerimeter.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/perimeters/circleRadiusFromPerimeter.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAclC,KAAK,WAAW,GAAG;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AA2FF,eAAO,MAAM,yBAAyB,EAAE,QAAQ,CAAC,WAAW,CAgB3D,CAAC"}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.circleRadiusFromPerimeter = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
7
|
+
const round_1 = require("../../../../math/utils/round");
|
|
8
|
+
const piNode_1 = require("../../../../tree/nodes/numbers/piNode");
|
|
9
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
10
|
+
const multiplyNode_1 = require("../../../../tree/nodes/operators/multiplyNode");
|
|
11
|
+
const numberParser_1 = require("../../../../tree/parsers/numberParser");
|
|
12
|
+
const alignTex_1 = require("../../../../utils/latex/alignTex");
|
|
13
|
+
const getPropositions = (n, { answer, perimeter }) => {
|
|
14
|
+
const propositions = [];
|
|
15
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
16
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(Math.sqrt(perimeter), 2).frenchify());
|
|
17
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter / Math.PI, 2).frenchify());
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter / 4, 2).frenchify());
|
|
19
|
+
while (propositions.length < n) {
|
|
20
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
21
|
+
}
|
|
22
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
23
|
+
};
|
|
24
|
+
const getAnswer = (identifiers) => {
|
|
25
|
+
return (0, round_1.round)(identifiers.perimeter / (2 * Math.PI), 2).frenchify();
|
|
26
|
+
};
|
|
27
|
+
const getInstruction = (identifiers) => {
|
|
28
|
+
return `Calculer le rayon d'un cercle de périmètre $${identifiers.perimeter.frenchify()}$. Arrondir au centième.`;
|
|
29
|
+
};
|
|
30
|
+
const getHint = (identifiers) => {
|
|
31
|
+
return `Le périmètre d'un cercle est égale à :
|
|
32
|
+
|
|
33
|
+
$$
|
|
34
|
+
2\\times \\pi\\times r
|
|
35
|
+
$$
|
|
36
|
+
|
|
37
|
+
où $r$ est le rayon.`;
|
|
38
|
+
};
|
|
39
|
+
const getCorrection = (identifiers) => {
|
|
40
|
+
return `Le périmètre d'un cercle est égal à :
|
|
41
|
+
|
|
42
|
+
$$
|
|
43
|
+
2\\times \\pi\\times r
|
|
44
|
+
$$
|
|
45
|
+
|
|
46
|
+
où $r$ est le rayon.
|
|
47
|
+
|
|
48
|
+
Ici, on a donc :
|
|
49
|
+
|
|
50
|
+
$${identifiers.perimeter.frenchify()} = 2\\times \\pi\\times r$
|
|
51
|
+
|
|
52
|
+
On isole $r$ dans cette équation :
|
|
53
|
+
|
|
54
|
+
${(0, alignTex_1.alignTex)([
|
|
55
|
+
[
|
|
56
|
+
"r",
|
|
57
|
+
"=",
|
|
58
|
+
new fractionNode_1.FractionNode(identifiers.perimeter.toTree(), new multiplyNode_1.MultiplyNode((2).toTree(), piNode_1.PiNode)).toTex(),
|
|
59
|
+
],
|
|
60
|
+
["", "\\aprox", getAnswer(identifiers)],
|
|
61
|
+
])}
|
|
62
|
+
`;
|
|
63
|
+
};
|
|
64
|
+
const getKeys = (identifiers) => {
|
|
65
|
+
return [];
|
|
66
|
+
};
|
|
67
|
+
const isAnswerValid = (ans, { answer, perimeter }) => {
|
|
68
|
+
const parsed = (0, numberParser_1.numberParser)(ans);
|
|
69
|
+
if (!parsed)
|
|
70
|
+
return false;
|
|
71
|
+
return parsed === answer;
|
|
72
|
+
};
|
|
73
|
+
const getCircleRadiusFromPerimeterQuestion = () => {
|
|
74
|
+
const perimeter = (0, randfloat_1.randfloat)(1, 100, 2);
|
|
75
|
+
const identifiers = { perimeter };
|
|
76
|
+
const question = {
|
|
77
|
+
answer: getAnswer(identifiers),
|
|
78
|
+
instruction: getInstruction(identifiers),
|
|
79
|
+
keys: getKeys(identifiers),
|
|
80
|
+
answerFormat: "tex",
|
|
81
|
+
identifiers,
|
|
82
|
+
hint: getHint(identifiers),
|
|
83
|
+
correction: getCorrection(identifiers),
|
|
84
|
+
};
|
|
85
|
+
return question;
|
|
86
|
+
};
|
|
87
|
+
exports.circleRadiusFromPerimeter = {
|
|
88
|
+
id: "circleRadiusFromPerimeter",
|
|
89
|
+
connector: "=",
|
|
90
|
+
label: "Calculer le rayon d'un cercle en connaissant son périmètre",
|
|
91
|
+
isSingleStep: true,
|
|
92
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getCircleRadiusFromPerimeterQuestion, nb),
|
|
93
|
+
qcmTimer: 60,
|
|
94
|
+
freeTimer: 60,
|
|
95
|
+
getPropositions,
|
|
96
|
+
isAnswerValid,
|
|
97
|
+
subject: "Mathématiques",
|
|
98
|
+
getHint,
|
|
99
|
+
getCorrection,
|
|
100
|
+
getAnswer,
|
|
101
|
+
hasHintAndCorrection: true,
|
|
102
|
+
};
|
|
@@ -2,4 +2,7 @@ export * from "./circleCircumference";
|
|
|
2
2
|
export * from "./rectanglePerimeter";
|
|
3
3
|
export * from "./squarePerimeter";
|
|
4
4
|
export * from "./trianglePerimeter";
|
|
5
|
+
export * from "./squareSideFromPerimeter";
|
|
6
|
+
export * from "./rectangleSideFromPerimeter";
|
|
7
|
+
export * from "./circleRadiusFromPerimeter";
|
|
5
8
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/perimeters/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/perimeters/index.ts"],"names":[],"mappings":"AAAA,cAAc,uBAAuB,CAAC;AACtC,cAAc,sBAAsB,CAAC;AACrC,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,6BAA6B,CAAC"}
|
|
@@ -18,3 +18,6 @@ __exportStar(require("./circleCircumference"), exports);
|
|
|
18
18
|
__exportStar(require("./rectanglePerimeter"), exports);
|
|
19
19
|
__exportStar(require("./squarePerimeter"), exports);
|
|
20
20
|
__exportStar(require("./trianglePerimeter"), exports);
|
|
21
|
+
__exportStar(require("./squareSideFromPerimeter"), exports);
|
|
22
|
+
__exportStar(require("./rectangleSideFromPerimeter"), exports);
|
|
23
|
+
__exportStar(require("./circleRadiusFromPerimeter"), exports);
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise";
|
|
2
|
+
type Identifiers = {
|
|
3
|
+
perimeter: number;
|
|
4
|
+
width: number;
|
|
5
|
+
};
|
|
6
|
+
export declare const rectangleSideFromPerimeter: Exercise<Identifiers>;
|
|
7
|
+
export {};
|
|
8
|
+
//# sourceMappingURL=rectangleSideFromPerimeter.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rectangleSideFromPerimeter.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/perimeters/rectangleSideFromPerimeter.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAOlC,KAAK,WAAW,GAAG;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AA4GF,eAAO,MAAM,0BAA0B,EAAE,QAAQ,CAAC,WAAW,CAiB5D,CAAC"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.rectangleSideFromPerimeter = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
7
|
+
const round_1 = require("../../../../math/utils/round");
|
|
8
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
9
|
+
const alignTex_1 = require("../../../../utils/latex/alignTex");
|
|
10
|
+
const getPropositions = (n, { answer, perimeter, width }) => {
|
|
11
|
+
const propositions = [];
|
|
12
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
13
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter / 4, 2).frenchify());
|
|
14
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter - width, 2).frenchify());
|
|
15
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter - 2 * width, 2).frenchify());
|
|
16
|
+
while (propositions.length < n) {
|
|
17
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
18
|
+
}
|
|
19
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
20
|
+
};
|
|
21
|
+
const getAnswer = (identifiers) => {
|
|
22
|
+
return (0, round_1.round)((identifiers.perimeter - 2 * identifiers.width) / 2, 2).frenchify();
|
|
23
|
+
};
|
|
24
|
+
const getInstruction = (identifiers) => {
|
|
25
|
+
return `Calculer la longueur d'un rectangle de périmètre $${identifiers.perimeter.frenchify()}$ et de largeur $${identifiers.width.frenchify()}$.`;
|
|
26
|
+
};
|
|
27
|
+
const getHint = (identifiers) => {
|
|
28
|
+
return `Le périmètre d'un rectangle est égal à :
|
|
29
|
+
|
|
30
|
+
$$
|
|
31
|
+
P = 2\\times l + 2\\times L
|
|
32
|
+
$$
|
|
33
|
+
|
|
34
|
+
où $l$ et la largeur et $L$ et la longueur.`;
|
|
35
|
+
};
|
|
36
|
+
const getCorrection = (identifiers) => {
|
|
37
|
+
const lengthDouble = (0, round_1.round)(identifiers.perimeter - 2 * identifiers.width, 3);
|
|
38
|
+
return `Le périmètre d'un rectangle est égal à :
|
|
39
|
+
|
|
40
|
+
$$
|
|
41
|
+
P = 2\\times l + 2\\times L
|
|
42
|
+
$$
|
|
43
|
+
|
|
44
|
+
Ici, on a donc :
|
|
45
|
+
|
|
46
|
+
$$
|
|
47
|
+
${identifiers.perimeter.frenchify()} = 2\\times ${identifiers.width.frenchify()} + 2\\times L
|
|
48
|
+
$$
|
|
49
|
+
|
|
50
|
+
Pour retrouver la longueur, on isole $L$ dans cette équation. On obtient :
|
|
51
|
+
|
|
52
|
+
${(0, alignTex_1.alignTex)([
|
|
53
|
+
[
|
|
54
|
+
"2\\times L",
|
|
55
|
+
"=",
|
|
56
|
+
`${identifiers.perimeter.frenchify()}- 2\\times ${identifiers.width.frenchify()}`,
|
|
57
|
+
],
|
|
58
|
+
["", "=", `${lengthDouble.frenchify()}`],
|
|
59
|
+
])}
|
|
60
|
+
|
|
61
|
+
Ainsi, la longueur du rectangle vaut :
|
|
62
|
+
|
|
63
|
+
${(0, alignTex_1.alignTex)([
|
|
64
|
+
[
|
|
65
|
+
"L",
|
|
66
|
+
"=",
|
|
67
|
+
`${new fractionNode_1.FractionNode(lengthDouble.toTree(), (2).toTree()).toTex()}`,
|
|
68
|
+
],
|
|
69
|
+
["", "=", getAnswer(identifiers)],
|
|
70
|
+
])}
|
|
71
|
+
`;
|
|
72
|
+
};
|
|
73
|
+
const getKeys = (identifiers) => {
|
|
74
|
+
return [];
|
|
75
|
+
};
|
|
76
|
+
const isAnswerValid = (ans, { answer, perimeter, width }) => {
|
|
77
|
+
const node = new fractionNode_1.FractionNode((perimeter - 2 * width).toTree(), (2).toTree());
|
|
78
|
+
return node.toAllValidTexs({ allowFractionToDecimal: true }).includes(ans);
|
|
79
|
+
};
|
|
80
|
+
const getRectangleSideFromPerimeterQuestion = () => {
|
|
81
|
+
const width = (0, randfloat_1.randfloat)(1, 50, 1);
|
|
82
|
+
const perimeter = (0, randfloat_1.randfloat)(2 * width + 2, 2 * width + 50, 1);
|
|
83
|
+
const length = (0, round_1.round)((perimeter - 2 * width) / 2, 2);
|
|
84
|
+
const identifiers = {
|
|
85
|
+
perimeter,
|
|
86
|
+
width: Math.min(width, length),
|
|
87
|
+
};
|
|
88
|
+
const question = {
|
|
89
|
+
answer: getAnswer(identifiers),
|
|
90
|
+
instruction: getInstruction(identifiers),
|
|
91
|
+
keys: getKeys(identifiers),
|
|
92
|
+
answerFormat: "tex",
|
|
93
|
+
identifiers,
|
|
94
|
+
hint: getHint(identifiers),
|
|
95
|
+
correction: getCorrection(identifiers),
|
|
96
|
+
};
|
|
97
|
+
return question;
|
|
98
|
+
};
|
|
99
|
+
exports.rectangleSideFromPerimeter = {
|
|
100
|
+
id: "rectangleSideFromPerimeter",
|
|
101
|
+
connector: "=",
|
|
102
|
+
label: "Calculer la longueur d'un rectangle en connaissant son périmètre et sa largeur",
|
|
103
|
+
isSingleStep: true,
|
|
104
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getRectangleSideFromPerimeterQuestion, nb),
|
|
105
|
+
qcmTimer: 60,
|
|
106
|
+
freeTimer: 60,
|
|
107
|
+
getPropositions,
|
|
108
|
+
isAnswerValid,
|
|
109
|
+
subject: "Mathématiques",
|
|
110
|
+
getHint,
|
|
111
|
+
getCorrection,
|
|
112
|
+
getAnswer,
|
|
113
|
+
hasHintAndCorrection: true,
|
|
114
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"squareSideFromPerimeter.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/perimeters/squareSideFromPerimeter.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAQlC,KAAK,WAAW,GAAG;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAmEF,eAAO,MAAM,uBAAuB,EAAE,QAAQ,CAAC,WAAW,CAgBzD,CAAC"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.squareSideFromPerimeter = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const real_1 = require("../../../../math/numbers/reals/real");
|
|
7
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
8
|
+
const round_1 = require("../../../../math/utils/round");
|
|
9
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
10
|
+
const getPropositions = (n, { answer, perimeter }) => {
|
|
11
|
+
const propositions = [];
|
|
12
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
13
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (4 * perimeter).frenchify());
|
|
14
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, round_1.round)(perimeter / 2, 3).frenchify());
|
|
15
|
+
const sqrt = new real_1.SquareRoot(perimeter).basicSimplify().toTree().toTex();
|
|
16
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, sqrt);
|
|
17
|
+
while (propositions.length < n) {
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, (0, randfloat_1.randfloat)(1, 100, 2).frenchify());
|
|
19
|
+
}
|
|
20
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
21
|
+
};
|
|
22
|
+
const getAnswer = (identifiers) => {
|
|
23
|
+
return (0, round_1.round)(identifiers.perimeter / 4, 3).frenchify();
|
|
24
|
+
};
|
|
25
|
+
const getInstruction = (identifiers) => {
|
|
26
|
+
return `Calculer le côté d'un carré de périmètre $${identifiers.perimeter.frenchify()}$.`;
|
|
27
|
+
};
|
|
28
|
+
const getHint = (identifiers) => {
|
|
29
|
+
return `Le périmètre d'un carré est égal à $4$ fois la longueur du côté.`;
|
|
30
|
+
};
|
|
31
|
+
const getCorrection = (identifiers) => {
|
|
32
|
+
return `Le périmètre d'un carré est égal à $4$ fois la longueur du côté. Pour retrouver le côté à partir du périmètre, il faut donc diviser le périmètre par $4$. Le côté du carré est donc égal à :
|
|
33
|
+
|
|
34
|
+
$$
|
|
35
|
+
${new fractionNode_1.FractionNode(identifiers.perimeter.toTree(), (4).toTree()).toTex()}=${getAnswer(identifiers)}
|
|
36
|
+
$$
|
|
37
|
+
`;
|
|
38
|
+
};
|
|
39
|
+
const getKeys = (identifiers) => {
|
|
40
|
+
return [];
|
|
41
|
+
};
|
|
42
|
+
const isAnswerValid = (ans, { answer, perimeter }) => {
|
|
43
|
+
const node = new fractionNode_1.FractionNode(perimeter.toTree(), (4).toTree());
|
|
44
|
+
return node.toAllValidTexs({ allowFractionToDecimal: true }).includes(ans);
|
|
45
|
+
};
|
|
46
|
+
const getSquareSideFromPerimeterQuestion = () => {
|
|
47
|
+
const identifiers = { perimeter: (0, randfloat_1.randfloat)(1, 100, 1) };
|
|
48
|
+
const question = {
|
|
49
|
+
answer: getAnswer(identifiers),
|
|
50
|
+
instruction: getInstruction(identifiers),
|
|
51
|
+
keys: getKeys(identifiers),
|
|
52
|
+
answerFormat: "tex",
|
|
53
|
+
identifiers,
|
|
54
|
+
hint: getHint(identifiers),
|
|
55
|
+
correction: getCorrection(identifiers),
|
|
56
|
+
};
|
|
57
|
+
return question;
|
|
58
|
+
};
|
|
59
|
+
exports.squareSideFromPerimeter = {
|
|
60
|
+
id: "squareSideFromPerimeter",
|
|
61
|
+
connector: "=",
|
|
62
|
+
label: "Calculer le côté d'un carré en connaissant son périmètre",
|
|
63
|
+
isSingleStep: true,
|
|
64
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getSquareSideFromPerimeterQuestion, nb),
|
|
65
|
+
qcmTimer: 60,
|
|
66
|
+
freeTimer: 60,
|
|
67
|
+
getPropositions,
|
|
68
|
+
isAnswerValid,
|
|
69
|
+
subject: "Mathématiques",
|
|
70
|
+
getHint,
|
|
71
|
+
getCorrection,
|
|
72
|
+
getAnswer,
|
|
73
|
+
hasHintAndCorrection: true,
|
|
74
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"equationCosOnRandomInterval.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/equationCosOnRandomInterval.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"equationCosOnRandomInterval.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/equationCosOnRandomInterval.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,0BAA0B,CAAC;AAqBlC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,mBAAmB,EAAE,MAAM,CAAC;CAC7B,CAAC;AA6HF,eAAO,MAAM,2BAA2B,EAAE,QAAQ,CAAC,WAAW,CAgB7D,CAAC"}
|
|
@@ -14,11 +14,19 @@ const closure_1 = require("../../../tree/nodes/sets/closure");
|
|
|
14
14
|
const discreteSetNode_1 = require("../../../tree/nodes/sets/discreteSetNode");
|
|
15
15
|
const intervalNode_1 = require("../../../tree/nodes/sets/intervalNode");
|
|
16
16
|
const random_1 = require("../../../utils/alea/random");
|
|
17
|
-
const getPropositions = (n, { answer }) => {
|
|
17
|
+
const getPropositions = (n, { answer, degree, leftBoundPiMultiple }) => {
|
|
18
18
|
const propositions = [];
|
|
19
19
|
(0, exercise_1.addValidProp)(propositions, answer);
|
|
20
|
+
//distracteur avec une solution manquante
|
|
21
|
+
if (degree !== 0 && degree !== 180) {
|
|
22
|
+
const answerNode = getAnswerNode({ degree, leftBoundPiMultiple });
|
|
23
|
+
const newSet = answerNode.solutionsSet.toDeleteRandomElement();
|
|
24
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new equationSolutionNode_1.EquationSolutionNode(newSet).toTex());
|
|
25
|
+
}
|
|
20
26
|
while (propositions.length < n) {
|
|
21
|
-
|
|
27
|
+
const value = (0, random_1.random)(remarkableValues_1.mainPositiveTrigovalues);
|
|
28
|
+
const randDegree = value.degree;
|
|
29
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ degree: randDegree, leftBoundPiMultiple }));
|
|
22
30
|
}
|
|
23
31
|
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
24
32
|
};
|
|
@@ -66,10 +74,11 @@ const getCorrection = (identifiers) => {
|
|
|
66
74
|
return "";
|
|
67
75
|
};
|
|
68
76
|
const getKeys = (identifiers) => {
|
|
69
|
-
return ["pi"];
|
|
77
|
+
return ["x", "S", "equal", "lbrace", "semicolon", "rbrace", "pi"];
|
|
70
78
|
};
|
|
71
|
-
const isAnswerValid = (ans, { answer }) => {
|
|
72
|
-
|
|
79
|
+
const isAnswerValid = (ans, { answer, degree, leftBoundPiMultiple }) => {
|
|
80
|
+
const answerNode = getAnswerNode({ degree, leftBoundPiMultiple });
|
|
81
|
+
return answerNode.toAllValidTexs().includes(ans);
|
|
73
82
|
};
|
|
74
83
|
const getEquationCosOnRandomIntervalQuestion = () => {
|
|
75
84
|
const value = (0, random_1.random)(remarkableValues_1.mainPositiveTrigovalues);
|
|
@@ -90,7 +90,7 @@ const getEquationSinOnRandomIntervalQuestion = () => {
|
|
|
90
90
|
exports.equationSinOnRandomInterval = {
|
|
91
91
|
id: "equationSinOnRandomInterval",
|
|
92
92
|
connector: "\\iff",
|
|
93
|
-
label: "Résoudre une équation du type $\\
|
|
93
|
+
label: "Résoudre une équation du type $\\sin\\left(x\\right)=k$ sur un intervalle donné",
|
|
94
94
|
isSingleStep: true,
|
|
95
95
|
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getEquationSinOnRandomIntervalQuestion, nb),
|
|
96
96
|
qcmTimer: 60,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/index.ts"],"names":[],"mappings":"AAAA,cAAc,wBAAwB,CAAC;AACvC,cAAc,oBAAoB,CAAC;AACnC,cAAc,gBAAgB,CAAC;AAC/B,cAAc,2BAA2B,CAAC;AAC1C,cAAc,0BAA0B,CAAC;AACzC,cAAc,kBAAkB,CAAC;AACjC,cAAc,YAAY,CAAC;AAC3B,cAAc,yBAAyB,CAAC;AACxC,cAAc,oBAAoB,CAAC;AACnC,cAAc,oBAAoB,CAAC;AACnC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,oBAAoB,CAAC;AACnC,cAAc,mBAAmB,CAAC;AAClC,cAAc,aAAa,CAAC;AAC5B,cAAc,+BAA+B,CAAC"}
|
|
@@ -28,4 +28,4 @@ __exportStar(require("./basicTrigoSystemEquation"), exports);
|
|
|
28
28
|
__exportStar(require("./mainAngleMeasure"), exports);
|
|
29
29
|
__exportStar(require("./degreeToRadians"), exports);
|
|
30
30
|
__exportStar(require("./arcLength"), exports);
|
|
31
|
-
|
|
31
|
+
__exportStar(require("./equationCosOnRandomInterval"), exports);
|
|
@@ -58,7 +58,7 @@ const generateExercise = () => {
|
|
|
58
58
|
const epsilon = (0, randint_1.randint)(1, 3);
|
|
59
59
|
const l = (0, randint_1.randint)(1, 3);
|
|
60
60
|
const instruction = `Dans un laboratoire, vous avez effectué l'étalonnage d'une solution ${(0, requiresApostropheBefore_1.requiresApostropheBefore)(molecule.name) ? "d'" : "de "}${molecule.name}. \n
|
|
61
|
-
Vous disposez du coefficient d'extinction molaire
|
|
61
|
+
Vous disposez du coefficient d'extinction molaire $\\varepsilon$ de $${epsilon}$ $\\text{L}\\cdot\\text{mol}^{-1}\\cdot\\text{cm}^{-1}$ et de la longueur de la cuve $l$ de $${l}$ $\\text{cm}$. \n
|
|
62
62
|
Tracer la courbe d'étalonnage de cette solution.`;
|
|
63
63
|
return {
|
|
64
64
|
instruction,
|
|
@@ -70,13 +70,13 @@ const generateExercise = () => {
|
|
|
70
70
|
};
|
|
71
71
|
const getCorrection = () => {
|
|
72
72
|
return `1 - Choisir deux coordonnées $x_1$ et $x_2$. \n \\
|
|
73
|
-
2 - Calculer $A_1 = x_1\\cdot l \\cdot
|
|
73
|
+
2 - Calculer $A_1 = x_1\\cdot l \\cdot \\varepsilon$ et $A_2 = x_2\\cdot l \\cdot \\varepsilon$. \n \\
|
|
74
74
|
3 - Tracer la droite qui passe par les deux points $(x_1,A_1)$ et $(x_2,A_2)$.`;
|
|
75
75
|
};
|
|
76
76
|
const getHint = () => {
|
|
77
|
-
return `Utiliser la formule $A=C\\cdot \\ell\\cdot
|
|
77
|
+
return `Utiliser la formule $A=C\\cdot \\ell\\cdot \\varepsilon$, où :\n
|
|
78
78
|
- $A$ est l'absorbance (une grandeur sans unité)\n
|
|
79
|
-
-
|
|
79
|
+
- $\\varepsilon$ est le coefficient d'extinction molaire (ou coefficient d'absorption molaire) en $\\text{L}\\cdot\\text{mol}^{-1}\\cdot\\text{cm}^{-1}$\n
|
|
80
80
|
- $C$ est la concentration de la solution en $\\text{mol}\\cdot\\text{L}^{-1}$\n
|
|
81
81
|
- $\\ell$ est la longueur du chemin optique en centimètres $(\\text{cm})$`;
|
|
82
82
|
};
|
package/lib/index.d.ts
CHANGED
|
@@ -638,6 +638,10 @@ declare const mathExercises: (import("./exercises/exercise").Exercise<{
|
|
|
638
638
|
imageValues: number[];
|
|
639
639
|
isAskingImage: boolean;
|
|
640
640
|
value: number;
|
|
641
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
642
|
+
isImage: boolean;
|
|
643
|
+
x: number;
|
|
644
|
+
y: number;
|
|
641
645
|
}> | import("./exercises/exercise").Exercise<{
|
|
642
646
|
k: number;
|
|
643
647
|
}> | import("./exercises/exercise").Exercise<{
|
|
@@ -813,6 +817,14 @@ declare const mathExercises: (import("./exercises/exercise").Exercise<{
|
|
|
813
817
|
side: number;
|
|
814
818
|
}> | import("./exercises/exercise").Exercise<{}> | import("./exercises/exercise").Exercise<{
|
|
815
819
|
randomSide: number;
|
|
820
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
821
|
+
area: number;
|
|
822
|
+
isPerfectSquare: boolean;
|
|
823
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
824
|
+
area: number;
|
|
825
|
+
width: number;
|
|
826
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
827
|
+
area: number;
|
|
816
828
|
}> | import("./exercises/exercise").Exercise<{
|
|
817
829
|
coords1: number[];
|
|
818
830
|
coords2: number[];
|
|
@@ -881,6 +893,13 @@ declare const mathExercises: (import("./exercises/exercise").Exercise<{
|
|
|
881
893
|
side: number;
|
|
882
894
|
}> | import("./exercises/exercise").Exercise<{
|
|
883
895
|
sides: number[];
|
|
896
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
897
|
+
perimeter: number;
|
|
898
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
899
|
+
perimeter: number;
|
|
900
|
+
width: number;
|
|
901
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
902
|
+
perimeter: number;
|
|
884
903
|
}> | import("./exercises/exercise").Exercise<{
|
|
885
904
|
sideA: string;
|
|
886
905
|
sideB: string;
|
|
@@ -1483,6 +1502,9 @@ declare const mathExercises: (import("./exercises/exercise").Exercise<{
|
|
|
1483
1502
|
thetaInDegree: number | undefined;
|
|
1484
1503
|
thetaInRadNodeIds: any;
|
|
1485
1504
|
isThetaInDegree: boolean;
|
|
1505
|
+
}> | import("./exercises/exercise").Exercise<{
|
|
1506
|
+
degree: number;
|
|
1507
|
+
leftBoundPiMultiple: number;
|
|
1486
1508
|
}> | import("./exercises/exercise").Exercise<{
|
|
1487
1509
|
exercise: {
|
|
1488
1510
|
a: number;
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA,OAAO,yBAAyB,CAAC;AAEjC,QAAA,MAAM,aAAa
|
|
1
|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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAA6B,CAAC;AAE/C,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,CAAC"}
|
|
@@ -27,6 +27,8 @@ export declare class SquareRoot extends Real {
|
|
|
27
27
|
constructor(operand: number);
|
|
28
28
|
isSimplifiable(): boolean;
|
|
29
29
|
getSimplifiedCoeffs(): [number, number];
|
|
30
|
+
/**simplifier les carrés parfaits mais pas le reste */
|
|
31
|
+
basicSimplify(): Nombre;
|
|
30
32
|
simplify(): Nombre;
|
|
31
33
|
toTex(): string;
|
|
32
34
|
toTree(): SqrtNode;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"real.d.ts","sourceRoot":"","sources":["../../../../src/math/numbers/reals/real.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAS/D,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC/C,8BAAsB,eAAe;IACnC,MAAM,CAAC,MAAM;CAUd;AACD,qBAAa,IAAK,YAAW,MAAM;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,UAAU,CAAC;gBACL,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM;IAKtC,MAAM,CAAC,CAAC,EAAE,MAAM;IAGhB,MAAM,IAAI,aAAa;CAIxB;AAED,8BAAsB,qBAAqB;IACzC;;OAEG;IACH,MAAM,CAAC,kBAAkB,CAAC,EACxB,kBAA0B,EAC1B,SAAc,GACf;;;KAAA,GAAG,UAAU;IASd,MAAM,CAAC,kBAAkB,CAAC,GAAG,GAAE,MAAW,GAAG,UAAU;CAIxD;AAED,qBAAa,UAAW,SAAQ,IAAI;IAClC,OAAO,EAAE,MAAM,CAAC;gBACJ,OAAO,EAAE,MAAM;IAK3B,cAAc;IAMd,mBAAmB,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"real.d.ts","sourceRoot":"","sources":["../../../../src/math/numbers/reals/real.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAS/D,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAC/C,8BAAsB,eAAe;IACnC,MAAM,CAAC,MAAM;CAUd;AACD,qBAAa,IAAK,YAAW,MAAM;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,UAAU,CAAC;gBACL,KAAK,EAAE,MAAM,EAAE,GAAG,EAAE,MAAM;IAKtC,MAAM,CAAC,CAAC,EAAE,MAAM;IAGhB,MAAM,IAAI,aAAa;CAIxB;AAED,8BAAsB,qBAAqB;IACzC;;OAEG;IACH,MAAM,CAAC,kBAAkB,CAAC,EACxB,kBAA0B,EAC1B,SAAc,GACf;;;KAAA,GAAG,UAAU;IASd,MAAM,CAAC,kBAAkB,CAAC,GAAG,GAAE,MAAW,GAAG,UAAU;CAIxD;AAED,qBAAa,UAAW,SAAQ,IAAI;IAClC,OAAO,EAAE,MAAM,CAAC;gBACJ,OAAO,EAAE,MAAM;IAK3B,cAAc;IAMd,mBAAmB,IAAI,CAAC,MAAM,EAAE,MAAM,CAAC;IAkBvC,sDAAsD;IACtD,aAAa,IAAI,MAAM;IAMvB,QAAQ,IAAI,MAAM;IAyBlB,KAAK,IAAI,MAAM;IAIf,MAAM;CAGP"}
|
|
@@ -89,6 +89,13 @@ class SquareRoot extends Real {
|
|
|
89
89
|
const insideSqrt = factors.length === 0 ? 1 : factors.reduce((x, y) => x * y);
|
|
90
90
|
return [outsideSqrt, insideSqrt];
|
|
91
91
|
}
|
|
92
|
+
/**simplifier les carrés parfaits mais pas le reste */
|
|
93
|
+
basicSimplify() {
|
|
94
|
+
if (Math.sqrt(this.operand) === this.operand) {
|
|
95
|
+
return new integer_1.Integer(this.operand);
|
|
96
|
+
}
|
|
97
|
+
return this;
|
|
98
|
+
}
|
|
92
99
|
simplify() {
|
|
93
100
|
if (this.operand === 0)
|
|
94
101
|
return new integer_1.Integer(0);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fractionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/operators/fractionNode.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,WAAW,EAAE,YAAY,EAAkB,MAAM,gBAAgB,CAAC;AAK3E,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAKlE,wBAAgB,cAAc,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,IAAI,YAAY,CAEzD;AACD,qBAAa,YAAa,YAAW,YAAY;IAC/C,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB;;;OAGG;IACH,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,YAAY,IAAI,MAAM;IAItB,aAAa;;;;;;;;;IAQb,UAAU;IAGV,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;
|
|
1
|
+
{"version":3,"file":"fractionNode.d.ts","sourceRoot":"","sources":["../../../../src/tree/nodes/operators/fractionNode.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAC/D,OAAO,EAAE,WAAW,EAAE,YAAY,EAAkB,MAAM,gBAAgB,CAAC;AAK3E,OAAO,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AAKlE,wBAAgB,cAAc,CAAC,CAAC,EAAE,IAAI,GAAG,CAAC,IAAI,YAAY,CAEzD;AACD,qBAAa,YAAa,YAAW,YAAY;IAC/C,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB;;;OAGG;IACH,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,YAAY,IAAI,MAAM;IAItB,aAAa;;;;;;;;;IAQb,UAAU;IAGV,iBAAiB,CAAC,IAAI,CAAC,EAAE,WAAW;IA+BpC,cAAc,CAAC,IAAI,CAAC,EAAE,WAAW,GAAG,MAAM,EAAE;IAI5C,KAAK,IAAI,MAAM;IAaf,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC;IAMrC,QAAQ,CAAC,IAAI,CAAC,EAAE,eAAe,GAAG,aAAa;IAgJ/C,MAAM,CAAC,IAAI,EAAE,aAAa,GAAG,OAAO;CAOrC"}
|
|
@@ -51,7 +51,8 @@ class FractionNode {
|
|
|
51
51
|
const [num, denum] = [leftNode.value, rightNode.value];
|
|
52
52
|
const decimal = (0, round_1.round)(num / denum, 12);
|
|
53
53
|
//on ne push pas les non décimaux (limite arbitraire : partie décimale de 12 => non décimal)
|
|
54
|
-
if ((decimal
|
|
54
|
+
if (Math.floor(decimal) !== decimal &&
|
|
55
|
+
(decimal + "").split(".")[1].length > 11)
|
|
55
56
|
return;
|
|
56
57
|
res.push(new numberNode_1.NumberNode(decimal));
|
|
57
58
|
}
|
package/lib/types/keyIds.d.ts
CHANGED
|
@@ -14,7 +14,7 @@ export type KeyId =
|
|
|
14
14
|
/**sets */
|
|
15
15
|
| "belongs" | "notin" | "cap" | "cup" | "lbrace" | "rbrace" | "lbracket" | "rbracket" | "varnothing" | "naturals" | "integers" | "rationals" | "decimals" | "reals" | "complex" | "ast" | "del" | "right" | "left" | "rightarrow" | "overrightarrow" | "infty"
|
|
16
16
|
/**fcts */
|
|
17
|
-
| "log" | "ln" | "exp" | "epower" | "sin" | "cos" | "tan" | "arccos" | "arcsin" | "arctan" | "abs" | "fx"
|
|
17
|
+
| "log" | "ln" | "exp" | "epower" | "sin" | "cos" | "tan" | "arccos" | "arcsin" | "arctan" | "abs" | "fx" | "fParenthesis"
|
|
18
18
|
/**sequences */
|
|
19
19
|
| "un" | "unplus1"
|
|
20
20
|
/**probas */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"keyIds.d.ts","sourceRoot":"","sources":["../../src/types/keyIds.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK;AACf,gBAAgB;AACd,YAAY,GACZ,aAAa,GACb,mBAAmB,GACnB,oBAAoB;AACtB,WAAW;GACT,IAAI,GACJ,KAAK,GACL,SAAS,GACT,IAAI,GACJ,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,SAAS,GACT,OAAO,GACP,eAAe;AAEjB,aAAa;GACX,QAAQ,GACR,OAAO,GACP,MAAM,GACN,YAAY,GACZ,KAAK,GACL,OAAO,GACP,QAAQ,GACR,KAAK;AAEP,WAAW;GACT,IAAI,GACJ,IAAI,GACJ,OAAO;AAET,cAAc;GACZ,gBAAgB,GAChB,QAAQ,GACR,SAAS;AAEX,gBAAgB;GACd,MAAM,GACN,OAAO,GACP,OAAO,GACP,MAAM,GACN,QAAQ,GACR,MAAM,GACN,SAAS,GACT,QAAQ,GACR,MAAM,GACN,OAAO,GACP,SAAS,GACT,iBAAiB,GACjB,uBAAuB,GACvB,kBAAkB,GAClB,yBAAyB,GACzB,OAAO,GACP,OAAO,GACP,WAAW,GACX,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,KAAK,GACL,QAAQ,GACR,SAAS,GACT,OAAO;AAET,UAAU;GACR,SAAS,GACT,OAAO,GACP,KAAK,GACL,KAAK,GACL,QAAQ,GACR,QAAQ,GACR,UAAU,GACV,UAAU,GACV,YAAY,GACZ,UAAU,GACV,UAAU,GACV,WAAW,GACX,UAAU,GACV,OAAO,GACP,SAAS,GACT,KAAK,GACL,KAAK,GACL,OAAO,GACP,MAAM,GACN,YAAY,GACZ,gBAAgB,GAChB,OAAO;AAET,UAAU;GACR,KAAK,GACL,IAAI,GACJ,KAAK,GACL,QAAQ,GACR,KAAK,GACL,KAAK,GACL,KAAK,GACL,QAAQ,GACR,QAAQ,GACR,QAAQ,GACR,KAAK,GACL,IAAI;
|
|
1
|
+
{"version":3,"file":"keyIds.d.ts","sourceRoot":"","sources":["../../src/types/keyIds.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,KAAK;AACf,gBAAgB;AACd,YAAY,GACZ,aAAa,GACb,mBAAmB,GACnB,oBAAoB;AACtB,WAAW;GACT,IAAI,GACJ,KAAK,GACL,SAAS,GACT,IAAI,GACJ,KAAK,GACL,IAAI,GACJ,IAAI,GACJ,SAAS,GACT,OAAO,GACP,eAAe;AAEjB,aAAa;GACX,QAAQ,GACR,OAAO,GACP,MAAM,GACN,YAAY,GACZ,KAAK,GACL,OAAO,GACP,QAAQ,GACR,KAAK;AAEP,WAAW;GACT,IAAI,GACJ,IAAI,GACJ,OAAO;AAET,cAAc;GACZ,gBAAgB,GAChB,QAAQ,GACR,SAAS;AAEX,gBAAgB;GACd,MAAM,GACN,OAAO,GACP,OAAO,GACP,MAAM,GACN,QAAQ,GACR,MAAM,GACN,SAAS,GACT,QAAQ,GACR,MAAM,GACN,OAAO,GACP,SAAS,GACT,iBAAiB,GACjB,uBAAuB,GACvB,kBAAkB,GAClB,yBAAyB,GACzB,OAAO,GACP,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AAS,GACT,WAAW,GACX,UAAU,GACV,WAAW,GACX,QAAQ,GACR,UAAU,GACV,SAAS,GACT,cAAc,GACd,OAAO,GACP,YAAY,GACZ,WAAW,GACX,QAAQ,GACR,YAAY,GACZ,QAAQ,GACR,aAAa,GACb,UAAU,GACV,QAAQ,GACR,YAAY,GACZ,WAAW,GACX,SAAS,GACT,WAAW,GACX,WAAW,GACX,SAAS,GACT,SAAS,GACT,UAAU,GACV,SAAS,GACT,WAAW,GACX,WAAW,GACX,WAAW,GACX,UAAU,GACV,QAAQ,GACR,QAAQ,GACR,WAAW,GACX,UAAU,GACV,UAAU,GACV,UAAU,GACV,WAAW,GACX,UAAU,GACV,SAAS,GACT,SAAS,GACT,WAAW,GACX,YAAY,GACZ,UAAU,GACV,aAAa,GACb,WAAW,GACX,QAAQ,GACR,WAAW,GACX,WAAW,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "math-exercises",
|
|
3
|
-
"version": "2.2.
|
|
3
|
+
"version": "2.2.38",
|
|
4
4
|
"description": "Math exercises generator for middle school and high school",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"files": [
|
|
@@ -36,6 +36,7 @@
|
|
|
36
36
|
"dotenv": "^16.0.3",
|
|
37
37
|
"express": "^4.18.2",
|
|
38
38
|
"jest": "^29.7.0",
|
|
39
|
+
"node-latex": "^3.1.0",
|
|
39
40
|
"nodemon": "^2.0.22",
|
|
40
41
|
"prettier": "^2.8.4",
|
|
41
42
|
"ts-jest": "^29.1.1",
|