math-exercises 3.0.190 → 3.0.191
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/dataRepresentations/scatterPlot/index.d.ts +6 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/index.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/index.js +5 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotBuildScatterPlotFromDataTable.d.ts +12 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotBuildScatterPlotFromDataTable.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotBuildScatterPlotFromDataTable.js +206 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotCommenting.d.ts +9 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotCommenting.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotCommenting.js +210 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableFromScatterPlotData.d.ts +10 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableFromScatterPlotData.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableFromScatterPlotData.js +252 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableWithDataClassesFromScatterPlotData.d.ts +12 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableWithDataClassesFromScatterPlotData.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotFillDataTableWithDataClassesFromScatterPlotData.js +352 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotInterpreting.d.ts +11 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotInterpreting.d.ts.map +1 -0
- package/lib/exercises/math/dataRepresentations/scatterPlot/scatterPlotInterpreting.js +403 -0
- package/lib/exercises/math/derivation/tangent/tangentEquationFromFunctionExpression.js +1 -1
- package/lib/exercises/math/derivation/variations/signVarTableFromFunctionExpression.d.ts.map +1 -1
- package/lib/exercises/math/derivation/variations/signVarTableFromFunctionExpression.js +4 -1
- package/lib/exercises/math/functions/affines/affineCompareTwoImagesFromVariations.d.ts +13 -0
- package/lib/exercises/math/functions/affines/affineCompareTwoImagesFromVariations.d.ts.map +1 -0
- package/lib/exercises/math/functions/affines/affineCompareTwoImagesFromVariations.js +205 -0
- package/lib/exercises/math/functions/affines/affineVarTableOnBoundedInterval.d.ts +9 -0
- package/lib/exercises/math/functions/affines/affineVarTableOnBoundedInterval.d.ts.map +1 -0
- package/lib/exercises/math/functions/affines/affineVarTableOnBoundedInterval.js +157 -0
- package/lib/exercises/math/functions/affines/affineVariations.d.ts +12 -0
- package/lib/exercises/math/functions/affines/affineVariations.d.ts.map +1 -0
- package/lib/exercises/math/functions/affines/affineVariations.js +176 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromGraph.d.ts +8 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromGraph.d.ts.map +1 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromGraph.js +203 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromTwoImages.d.ts +12 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromTwoImages.d.ts.map +1 -0
- package/lib/exercises/math/functions/affines/affineVariationsFromTwoImages.js +259 -0
- package/lib/exercises/math/functions/exponentials/exponentialFunctionImage.d.ts +9 -0
- package/lib/exercises/math/functions/exponentials/exponentialFunctionImage.d.ts.map +1 -0
- package/lib/exercises/math/functions/exponentials/exponentialFunctionImage.js +99 -0
- package/lib/exercises/math/functions/exponentials/index.d.ts +5 -0
- package/lib/exercises/math/functions/exponentials/index.d.ts.map +1 -1
- package/lib/exercises/math/functions/exponentials/index.js +5 -0
- package/lib/exercises/math/functions/exponentials/realPowersFraction.d.ts +10 -0
- package/lib/exercises/math/functions/exponentials/realPowersFraction.d.ts.map +1 -0
- package/lib/exercises/math/functions/exponentials/realPowersFraction.js +125 -0
- package/lib/exercises/math/functions/exponentials/realPowersMixOperations.d.ts +12 -0
- package/lib/exercises/math/functions/exponentials/realPowersMixOperations.d.ts.map +1 -0
- package/lib/exercises/math/functions/exponentials/realPowersMixOperations.js +148 -0
- package/lib/exercises/math/functions/exponentials/realPowersPower.d.ts +10 -0
- package/lib/exercises/math/functions/exponentials/realPowersPower.d.ts.map +1 -0
- package/lib/exercises/math/functions/exponentials/realPowersPower.js +128 -0
- package/lib/exercises/math/functions/exponentials/realPowersProduct.d.ts +10 -0
- package/lib/exercises/math/functions/exponentials/realPowersProduct.d.ts.map +1 -0
- package/lib/exercises/math/functions/exponentials/realPowersProduct.js +128 -0
- package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.d.ts +12 -0
- package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.d.ts.map +1 -0
- package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.js +217 -0
- package/lib/exercises/math/sequences/geometric/geometricFindRecurrenceFormula.d.ts +10 -0
- package/lib/exercises/math/sequences/geometric/geometricFindRecurrenceFormula.d.ts.map +1 -0
- package/lib/exercises/math/sequences/geometric/geometricFindRecurrenceFormula.js +186 -0
- package/lib/exercises/math/sequences/geometric/graph/geometricPlaceFirstPoints.d.ts +14 -0
- package/lib/exercises/math/sequences/geometric/graph/geometricPlaceFirstPoints.d.ts.map +1 -0
- package/lib/exercises/math/sequences/geometric/graph/geometricPlaceFirstPoints.js +189 -0
- package/lib/exercises/math/sequences/geometric/graph/index.d.ts +2 -0
- package/lib/exercises/math/sequences/geometric/graph/index.d.ts.map +1 -0
- package/lib/exercises/math/sequences/geometric/graph/index.js +1 -0
- package/lib/index.d.ts +21 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/tree/nodes/algebraicNode.d.ts +3 -0
- package/lib/tree/nodes/algebraicNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/fractionNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/fractionNode.js +5 -3
- package/lib/tree/nodes/operators/multiplyNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/multiplyNode.js +5 -3
- package/lib/tree/nodes/operators/powerNode.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
import { addValidProp, shuffleProps, propWhile, tryToAddWrongProp, } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { getDistinctQuestions } from "../../../../exercises/utils/getDistinctQuestions.js";
|
|
3
|
+
import { randfloat } from "../../../../math/utils/random/randfloat.js";
|
|
4
|
+
import { reifyAlgebraic, } from "../../../../tree/nodes/nodeConstructor.js";
|
|
5
|
+
import { frac } from "../../../../tree/nodes/operators/fractionNode.js";
|
|
6
|
+
import { multiply } from "../../../../tree/nodes/operators/multiplyNode.js";
|
|
7
|
+
import { power } from "../../../../tree/nodes/operators/powerNode.js";
|
|
8
|
+
import { parseAlgebraic } from "../../../../tree/parsers/latexParser.js";
|
|
9
|
+
import { shuffle } from "../../../../utils/alea/shuffle.js";
|
|
10
|
+
import { doWhile } from "../../../../utils/doWhile.js";
|
|
11
|
+
import { handleVEAError } from "../../../../utils/errors/handleVEAError.js";
|
|
12
|
+
import { isInt } from "../../../../utils/isInt.js";
|
|
13
|
+
import { alignTex } from "../../../../utils/latex/alignTex.js";
|
|
14
|
+
const getPropositions = (n, { answer, aIds }) => {
|
|
15
|
+
const propositions = [];
|
|
16
|
+
addValidProp(propositions, answer);
|
|
17
|
+
const a = reifyAlgebraic(aIds);
|
|
18
|
+
propWhile(propositions, n, () => {
|
|
19
|
+
tryToAddWrongProp(propositions, power(a, randfloat(0.1, 5, 1)).simplify().toTex());
|
|
20
|
+
});
|
|
21
|
+
return shuffleProps(propositions, n);
|
|
22
|
+
};
|
|
23
|
+
const getAnswer = (identifiers) => {
|
|
24
|
+
const statement = getStatement(identifiers);
|
|
25
|
+
return statement.simplify().toTex();
|
|
26
|
+
};
|
|
27
|
+
const getStatement = (identifiers) => {
|
|
28
|
+
const { aIds, tIds, xIds, yIds, zIds } = identifiers;
|
|
29
|
+
const a = reifyAlgebraic(aIds);
|
|
30
|
+
const x = reifyAlgebraic(xIds);
|
|
31
|
+
const y = reifyAlgebraic(yIds);
|
|
32
|
+
const z = reifyAlgebraic(zIds);
|
|
33
|
+
const t = reifyAlgebraic(tIds);
|
|
34
|
+
return frac(multiply(power(power(a, x), y), power(a, z)), power(a, t));
|
|
35
|
+
};
|
|
36
|
+
const getInstruction = (identifiers) => {
|
|
37
|
+
return `Écrire sous la forme d'une seule puissance :
|
|
38
|
+
|
|
39
|
+
$$
|
|
40
|
+
${getStatement(identifiers).toTex()}
|
|
41
|
+
$$`;
|
|
42
|
+
};
|
|
43
|
+
const getHint = () => {
|
|
44
|
+
return `Utilise les propriétés suivantes : pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
45
|
+
|
|
46
|
+
- $a^x\\times a^y = a^{x+y}$
|
|
47
|
+
- $\\frac{a^x}{a^y}= a^{x-y}$
|
|
48
|
+
- $\\left(a^x\\right)^y = a^{x\\times y}$`;
|
|
49
|
+
};
|
|
50
|
+
const getCorrection = (identifiers) => {
|
|
51
|
+
//(a^x)^y*a^z / a^t
|
|
52
|
+
const statement = getStatement(identifiers);
|
|
53
|
+
return `Pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
54
|
+
|
|
55
|
+
- $a^x\\times a^y = a^{x+y}$
|
|
56
|
+
- $\\frac{a^x}{a^y}= a^{x-y}$
|
|
57
|
+
- $\\left(a^x\\right)^y = a^{x\\times y}$
|
|
58
|
+
|
|
59
|
+
Ici, on a donc :
|
|
60
|
+
|
|
61
|
+
${alignTex([
|
|
62
|
+
[
|
|
63
|
+
statement.toTex(),
|
|
64
|
+
"=",
|
|
65
|
+
statement
|
|
66
|
+
.simplify({
|
|
67
|
+
forbidPowerDivision: true,
|
|
68
|
+
forbidPowerMultiply: true,
|
|
69
|
+
})
|
|
70
|
+
.toTex(),
|
|
71
|
+
],
|
|
72
|
+
[
|
|
73
|
+
"",
|
|
74
|
+
"=",
|
|
75
|
+
statement
|
|
76
|
+
.simplify({
|
|
77
|
+
forbidPowerDivision: true,
|
|
78
|
+
})
|
|
79
|
+
.toTex(),
|
|
80
|
+
],
|
|
81
|
+
["", "=", getAnswer(identifiers)],
|
|
82
|
+
])}`;
|
|
83
|
+
};
|
|
84
|
+
const getKeys = () => {
|
|
85
|
+
return [];
|
|
86
|
+
};
|
|
87
|
+
const isAnswerValid = (ans, { answer }) => {
|
|
88
|
+
try {
|
|
89
|
+
const parsed = parseAlgebraic(ans);
|
|
90
|
+
if (!parsed)
|
|
91
|
+
return false;
|
|
92
|
+
return (parsed
|
|
93
|
+
.simplify({
|
|
94
|
+
forbidPowerDivision: true,
|
|
95
|
+
forbidPowerMultiply: true,
|
|
96
|
+
forbidPowerPower: true,
|
|
97
|
+
})
|
|
98
|
+
.toTex() === answer);
|
|
99
|
+
}
|
|
100
|
+
catch (err) {
|
|
101
|
+
return handleVEAError(err);
|
|
102
|
+
}
|
|
103
|
+
};
|
|
104
|
+
const getRealPowersMixOperationsQuestion = () => {
|
|
105
|
+
const a = randfloat(0.1, 5, 1, [1]);
|
|
106
|
+
let x = doWhile(() => randfloat(0.1, 5, 1), (v) => isInt(v));
|
|
107
|
+
let y = randfloat(0.1, 5, 1);
|
|
108
|
+
let z = randfloat(0.1, 5, 1);
|
|
109
|
+
let t = randfloat(0.1, 5, 1);
|
|
110
|
+
[x, y, z, t] = shuffle([x, y, z, t]);
|
|
111
|
+
const identifiers = {
|
|
112
|
+
aIds: a.toTree().toIdentifiers(),
|
|
113
|
+
xIds: x.toTree().toIdentifiers(),
|
|
114
|
+
yIds: y.toTree().toIdentifiers(),
|
|
115
|
+
tIds: t.toTree().toIdentifiers(),
|
|
116
|
+
zIds: z.toTree().toIdentifiers(),
|
|
117
|
+
};
|
|
118
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
119
|
+
};
|
|
120
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
121
|
+
return {
|
|
122
|
+
answer: getAnswer(identifiers),
|
|
123
|
+
instruction: getInstruction(identifiers),
|
|
124
|
+
keys: getKeys(identifiers),
|
|
125
|
+
answerFormat: "tex",
|
|
126
|
+
identifiers,
|
|
127
|
+
hint: getHint(identifiers),
|
|
128
|
+
correction: getCorrection(identifiers),
|
|
129
|
+
};
|
|
130
|
+
};
|
|
131
|
+
export const realPowersMixOperations = {
|
|
132
|
+
id: "realPowersMixOperations",
|
|
133
|
+
connector: "=",
|
|
134
|
+
label: "Simplifier un mélange de calculs avec des puissances réelles",
|
|
135
|
+
isSingleStep: true,
|
|
136
|
+
generator: (nb, opts) => getDistinctQuestions(() => getRealPowersMixOperationsQuestion(opts), nb),
|
|
137
|
+
qcmTimer: 60,
|
|
138
|
+
freeTimer: 60,
|
|
139
|
+
getPropositions,
|
|
140
|
+
isAnswerValid,
|
|
141
|
+
subject: "Mathématiques",
|
|
142
|
+
getInstruction,
|
|
143
|
+
getHint,
|
|
144
|
+
getCorrection,
|
|
145
|
+
getAnswer,
|
|
146
|
+
getQuestionFromIdentifiers,
|
|
147
|
+
hasHintAndCorrection: true,
|
|
148
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { NodeIdentifiers } from "../../../../tree/nodes/nodeConstructor.js";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
aIds: NodeIdentifiers;
|
|
5
|
+
xIds: NodeIdentifiers;
|
|
6
|
+
yIds: NodeIdentifiers;
|
|
7
|
+
};
|
|
8
|
+
export declare const realPowersPower: Exercise<Identifiers>;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=realPowersPower.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"realPowersPower.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/functions/exponentials/realPowersPower.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAeT,MAAM,6BAA6B,CAAC;AAGrC,OAAO,EACL,eAAe,EAEhB,MAAM,qCAAqC,CAAC;AAY7C,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,EAAE,eAAe,CAAC;CACvB,CAAC;AA0HF,eAAO,MAAM,eAAe,EAAE,QAAQ,CAAC,WAAW,CAkBjD,CAAC"}
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
import { addValidProp, shuffleProps, tryToAddWrongProp, propWhile, } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { getDistinctQuestions } from "../../../../exercises/utils/getDistinctQuestions.js";
|
|
3
|
+
import { randfloat } from "../../../../math/utils/random/randfloat.js";
|
|
4
|
+
import { reifyAlgebraic, } from "../../../../tree/nodes/nodeConstructor.js";
|
|
5
|
+
import { add } from "../../../../tree/nodes/operators/addNode.js";
|
|
6
|
+
import { multiply } from "../../../../tree/nodes/operators/multiplyNode.js";
|
|
7
|
+
import { power } from "../../../../tree/nodes/operators/powerNode.js";
|
|
8
|
+
import { substract } from "../../../../tree/nodes/operators/substractNode.js";
|
|
9
|
+
import { parseAlgebraic } from "../../../../tree/parsers/latexParser.js";
|
|
10
|
+
import { coinFlip } from "../../../../utils/alea/coinFlip.js";
|
|
11
|
+
import { doWhile } from "../../../../utils/doWhile.js";
|
|
12
|
+
import { handleVEAError } from "../../../../utils/errors/handleVEAError.js";
|
|
13
|
+
import { isInt } from "../../../../utils/isInt.js";
|
|
14
|
+
const getPropositions = (n, { answer, aIds, xIds, yIds }) => {
|
|
15
|
+
const propositions = [];
|
|
16
|
+
addValidProp(propositions, answer);
|
|
17
|
+
const a = reifyAlgebraic(aIds);
|
|
18
|
+
const x = reifyAlgebraic(xIds);
|
|
19
|
+
const y = reifyAlgebraic(yIds);
|
|
20
|
+
tryToAddWrongProp(propositions, power(a, substract(x, y)).simplify().toTex());
|
|
21
|
+
tryToAddWrongProp(propositions, power(a, add(x, y)).simplify().toTex());
|
|
22
|
+
propWhile(propositions, n, () => {
|
|
23
|
+
tryToAddWrongProp(propositions, power(a, randfloat(0.1, 5, 1)).simplify().toTex());
|
|
24
|
+
});
|
|
25
|
+
return shuffleProps(propositions, n);
|
|
26
|
+
};
|
|
27
|
+
const getAnswer = (identifiers) => {
|
|
28
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
29
|
+
const a = reifyAlgebraic(aIds);
|
|
30
|
+
const x = reifyAlgebraic(xIds);
|
|
31
|
+
const y = reifyAlgebraic(yIds);
|
|
32
|
+
return power(a, multiply(x, y)).simplify().toTex();
|
|
33
|
+
};
|
|
34
|
+
const getInstruction = (identifiers) => {
|
|
35
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
36
|
+
const a = reifyAlgebraic(aIds);
|
|
37
|
+
const x = reifyAlgebraic(xIds);
|
|
38
|
+
const y = reifyAlgebraic(yIds);
|
|
39
|
+
return `Écrire sous la forme d'une seule puissance :
|
|
40
|
+
|
|
41
|
+
$$
|
|
42
|
+
${power(power(a, x), y).toTex()}
|
|
43
|
+
$$`;
|
|
44
|
+
};
|
|
45
|
+
const getHint = () => {
|
|
46
|
+
return `Utilise la propriété suivante : pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
47
|
+
|
|
48
|
+
$$
|
|
49
|
+
\\left(a^x\\right)^y = a^{x\\times y}
|
|
50
|
+
$$`;
|
|
51
|
+
};
|
|
52
|
+
const getCorrection = (identifiers) => {
|
|
53
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
54
|
+
const a = reifyAlgebraic(aIds);
|
|
55
|
+
const x = reifyAlgebraic(xIds);
|
|
56
|
+
const y = reifyAlgebraic(yIds);
|
|
57
|
+
return `Pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
58
|
+
|
|
59
|
+
$$
|
|
60
|
+
\\left(a^x\\right)^y = a^{x\\times y}
|
|
61
|
+
$$
|
|
62
|
+
|
|
63
|
+
Ici, on a donc :
|
|
64
|
+
|
|
65
|
+
$$
|
|
66
|
+
${power(power(a, x), y).toTex()} = ${power(a, multiply(x, y)).toTex()} = ${getAnswer(identifiers)}
|
|
67
|
+
$$`;
|
|
68
|
+
};
|
|
69
|
+
const getKeys = () => {
|
|
70
|
+
return [];
|
|
71
|
+
};
|
|
72
|
+
const isAnswerValid = (ans, { answer }) => {
|
|
73
|
+
try {
|
|
74
|
+
const parsed = parseAlgebraic(ans);
|
|
75
|
+
if (!parsed)
|
|
76
|
+
return false;
|
|
77
|
+
return (parsed
|
|
78
|
+
.simplify({
|
|
79
|
+
forbidPowerPower: true,
|
|
80
|
+
})
|
|
81
|
+
.toTex() === answer);
|
|
82
|
+
}
|
|
83
|
+
catch (err) {
|
|
84
|
+
return handleVEAError(err);
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
const getRealPowersFractionQuestion = () => {
|
|
88
|
+
const a = randfloat(0.1, 5, 1, [1]);
|
|
89
|
+
let x = doWhile(() => randfloat(0.1, 5, 1), (v) => isInt(v));
|
|
90
|
+
let y = randfloat(0.1, 5, 1);
|
|
91
|
+
if (coinFlip())
|
|
92
|
+
[x, y] = [y, x]; //comme ca l'éventuel entier est n'importe ou
|
|
93
|
+
const identifiers = {
|
|
94
|
+
aIds: a.toTree().toIdentifiers(),
|
|
95
|
+
xIds: x.toTree().toIdentifiers(),
|
|
96
|
+
yIds: y.toTree().toIdentifiers(),
|
|
97
|
+
};
|
|
98
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
99
|
+
};
|
|
100
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
101
|
+
return {
|
|
102
|
+
answer: getAnswer(identifiers),
|
|
103
|
+
instruction: getInstruction(identifiers),
|
|
104
|
+
keys: getKeys(identifiers),
|
|
105
|
+
answerFormat: "tex",
|
|
106
|
+
identifiers,
|
|
107
|
+
hint: getHint(identifiers),
|
|
108
|
+
correction: getCorrection(identifiers),
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
export const realPowersPower = {
|
|
112
|
+
id: "realPowersPower",
|
|
113
|
+
connector: "=",
|
|
114
|
+
label: "Simplifier une puissance de puissances réelles",
|
|
115
|
+
isSingleStep: true,
|
|
116
|
+
generator: (nb, opts) => getDistinctQuestions(() => getRealPowersFractionQuestion(opts), nb),
|
|
117
|
+
qcmTimer: 60,
|
|
118
|
+
freeTimer: 60,
|
|
119
|
+
getPropositions,
|
|
120
|
+
isAnswerValid,
|
|
121
|
+
subject: "Mathématiques",
|
|
122
|
+
getInstruction,
|
|
123
|
+
getHint,
|
|
124
|
+
getCorrection,
|
|
125
|
+
getAnswer,
|
|
126
|
+
getQuestionFromIdentifiers,
|
|
127
|
+
hasHintAndCorrection: true,
|
|
128
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { NodeIdentifiers } from "../../../../tree/nodes/nodeConstructor.js";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
aIds: NodeIdentifiers;
|
|
5
|
+
xIds: NodeIdentifiers;
|
|
6
|
+
yIds: NodeIdentifiers;
|
|
7
|
+
};
|
|
8
|
+
export declare const realPowersProduct: Exercise<Identifiers>;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=realPowersProduct.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"realPowersProduct.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/functions/exponentials/realPowersProduct.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAeT,MAAM,6BAA6B,CAAC;AAGrC,OAAO,EACL,eAAe,EAEhB,MAAM,qCAAqC,CAAC;AAY7C,KAAK,WAAW,GAAG;IACjB,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,EAAE,eAAe,CAAC;IACtB,IAAI,EAAE,eAAe,CAAC;CACvB,CAAC;AAuHF,eAAO,MAAM,iBAAiB,EAAE,QAAQ,CAAC,WAAW,CAkBnD,CAAC"}
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
import { addValidProp, shuffleProps, propWhile, tryToAddWrongProp, } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { getDistinctQuestions } from "../../../../exercises/utils/getDistinctQuestions.js";
|
|
3
|
+
import { randfloat } from "../../../../math/utils/random/randfloat.js";
|
|
4
|
+
import { reifyAlgebraic, } from "../../../../tree/nodes/nodeConstructor.js";
|
|
5
|
+
import { add } from "../../../../tree/nodes/operators/addNode.js";
|
|
6
|
+
import { multiply } from "../../../../tree/nodes/operators/multiplyNode.js";
|
|
7
|
+
import { power } from "../../../../tree/nodes/operators/powerNode.js";
|
|
8
|
+
import { substract } from "../../../../tree/nodes/operators/substractNode.js";
|
|
9
|
+
import { parseAlgebraic } from "../../../../tree/parsers/latexParser.js";
|
|
10
|
+
import { coinFlip } from "../../../../utils/alea/coinFlip.js";
|
|
11
|
+
import { doWhile } from "../../../../utils/doWhile.js";
|
|
12
|
+
import { handleVEAError } from "../../../../utils/errors/handleVEAError.js";
|
|
13
|
+
import { isInt } from "../../../../utils/isInt.js";
|
|
14
|
+
const getPropositions = (n, { answer, aIds, xIds, yIds }) => {
|
|
15
|
+
const propositions = [];
|
|
16
|
+
addValidProp(propositions, answer);
|
|
17
|
+
const a = reifyAlgebraic(aIds);
|
|
18
|
+
const x = reifyAlgebraic(xIds);
|
|
19
|
+
const y = reifyAlgebraic(yIds);
|
|
20
|
+
tryToAddWrongProp(propositions, power(a, substract(x, y).simplify()).toTex());
|
|
21
|
+
tryToAddWrongProp(propositions, power(a, multiply(x, y).simplify()).toTex());
|
|
22
|
+
propWhile(propositions, n, () => {
|
|
23
|
+
tryToAddWrongProp(propositions, power(a, randfloat(0.1, 5, 1)).toTex());
|
|
24
|
+
});
|
|
25
|
+
return shuffleProps(propositions, n);
|
|
26
|
+
};
|
|
27
|
+
const getAnswer = (identifiers) => {
|
|
28
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
29
|
+
const a = reifyAlgebraic(aIds);
|
|
30
|
+
const x = reifyAlgebraic(xIds);
|
|
31
|
+
const y = reifyAlgebraic(yIds);
|
|
32
|
+
return power(a, add(x, y)).simplify().toTex();
|
|
33
|
+
};
|
|
34
|
+
const getInstruction = (identifiers) => {
|
|
35
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
36
|
+
const a = reifyAlgebraic(aIds);
|
|
37
|
+
const x = reifyAlgebraic(xIds);
|
|
38
|
+
const y = reifyAlgebraic(yIds);
|
|
39
|
+
return `Écrire sous la forme d'une seule puissance :
|
|
40
|
+
|
|
41
|
+
$$
|
|
42
|
+
${multiply(power(a, x), power(a, y)).toTex()}
|
|
43
|
+
$$`;
|
|
44
|
+
};
|
|
45
|
+
const getHint = () => {
|
|
46
|
+
return `Utilise la propriété suivante : pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
47
|
+
|
|
48
|
+
$$
|
|
49
|
+
a^x\\times a^y = a^{x+y}
|
|
50
|
+
$$`;
|
|
51
|
+
};
|
|
52
|
+
const getCorrection = (identifiers) => {
|
|
53
|
+
const { aIds, xIds, yIds } = identifiers;
|
|
54
|
+
const a = reifyAlgebraic(aIds);
|
|
55
|
+
const x = reifyAlgebraic(xIds);
|
|
56
|
+
const y = reifyAlgebraic(yIds);
|
|
57
|
+
return `Pour tous nombres réels positifs $x$ et $y$ et pour tout nombre réel $a>0$, on a :
|
|
58
|
+
|
|
59
|
+
$$
|
|
60
|
+
a^x\\times a^y = a^{x+y}
|
|
61
|
+
$$
|
|
62
|
+
|
|
63
|
+
Ici, on a donc :
|
|
64
|
+
|
|
65
|
+
$$
|
|
66
|
+
${multiply(power(a, x), power(a, y)).toTex()} = ${power(a, add(x, y)).toTex()} = ${getAnswer(identifiers)}
|
|
67
|
+
$$`;
|
|
68
|
+
};
|
|
69
|
+
const getKeys = () => {
|
|
70
|
+
return [];
|
|
71
|
+
};
|
|
72
|
+
const isAnswerValid = (ans, { answer }) => {
|
|
73
|
+
try {
|
|
74
|
+
const parsed = parseAlgebraic(ans);
|
|
75
|
+
if (!parsed)
|
|
76
|
+
return false;
|
|
77
|
+
return (parsed
|
|
78
|
+
.simplify({
|
|
79
|
+
forbidPowerMultiply: true,
|
|
80
|
+
})
|
|
81
|
+
.toTex() === answer);
|
|
82
|
+
}
|
|
83
|
+
catch (err) {
|
|
84
|
+
return handleVEAError(err);
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
const getRealPowersProductQuestion = () => {
|
|
88
|
+
const a = randfloat(0.1, 5, 1, [1]);
|
|
89
|
+
let x = doWhile(() => randfloat(0.1, 5, 1), (v) => isInt(v));
|
|
90
|
+
let y = randfloat(0.1, 5, 1);
|
|
91
|
+
if (coinFlip())
|
|
92
|
+
[x, y] = [y, x]; //comme ca l'éventuel entier est n'importe ou
|
|
93
|
+
const identifiers = {
|
|
94
|
+
aIds: a.toTree().toIdentifiers(),
|
|
95
|
+
xIds: x.toTree().toIdentifiers(),
|
|
96
|
+
yIds: y.toTree().toIdentifiers(),
|
|
97
|
+
};
|
|
98
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
99
|
+
};
|
|
100
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
101
|
+
return {
|
|
102
|
+
answer: getAnswer(identifiers),
|
|
103
|
+
instruction: getInstruction(identifiers),
|
|
104
|
+
keys: getKeys(identifiers),
|
|
105
|
+
answerFormat: "tex",
|
|
106
|
+
identifiers,
|
|
107
|
+
hint: getHint(identifiers),
|
|
108
|
+
correction: getCorrection(identifiers),
|
|
109
|
+
};
|
|
110
|
+
};
|
|
111
|
+
export const realPowersProduct = {
|
|
112
|
+
id: "realPowersProduct",
|
|
113
|
+
connector: "=",
|
|
114
|
+
label: "Simplifier un produit de puissances réelles",
|
|
115
|
+
isSingleStep: true,
|
|
116
|
+
generator: (nb, opts) => getDistinctQuestions(() => getRealPowersProductQuestion(opts), nb),
|
|
117
|
+
qcmTimer: 60,
|
|
118
|
+
freeTimer: 60,
|
|
119
|
+
getPropositions,
|
|
120
|
+
isAnswerValid,
|
|
121
|
+
subject: "Mathématiques",
|
|
122
|
+
getInstruction,
|
|
123
|
+
getHint,
|
|
124
|
+
getCorrection,
|
|
125
|
+
getAnswer,
|
|
126
|
+
getQuestionFromIdentifiers,
|
|
127
|
+
hasHintAndCorrection: true,
|
|
128
|
+
};
|
package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise.js";
|
|
2
|
+
type Identifiers = {
|
|
3
|
+
rank1: number;
|
|
4
|
+
value1: number;
|
|
5
|
+
rank2: number;
|
|
6
|
+
value2: number;
|
|
7
|
+
precisionInitial: number;
|
|
8
|
+
precisionReason: number;
|
|
9
|
+
};
|
|
10
|
+
export declare const geometricFindNextTermFromTwoConsecutiveTerms: Exercise<Identifiers>;
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=geometricFindNextTermFromTwoConsecutiveTerms.d.ts.map
|
package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geometricFindNextTermFromTwoConsecutiveTerms.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,6BAA6B,CAAC;AAcrC,KAAK,WAAW,GAAG;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,gBAAgB,EAAE,MAAM,CAAC;IACzB,eAAe,EAAE,MAAM,CAAC;CACzB,CAAC;AA2OF,eAAO,MAAM,4CAA4C,EAAE,QAAQ,CAAC,WAAW,CAmB5E,CAAC"}
|
package/lib/exercises/math/sequences/geometric/geometricFindNextTermFromTwoConsecutiveTerms.js
ADDED
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
import { addValidProp, tryToAddWrongProp, propWhile, } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { getDistinctQuestions } from "../../../../exercises/utils/getDistinctQuestions.js";
|
|
3
|
+
import { numberVEA } from "../../../../exercises/vea/numberVEA.js";
|
|
4
|
+
import { randfloat } from "../../../../math/utils/random/randfloat.js";
|
|
5
|
+
import { randint } from "../../../../math/utils/random/randint.js";
|
|
6
|
+
import { round } from "../../../../math/utils/round.js";
|
|
7
|
+
import { frac } from "../../../../tree/nodes/operators/fractionNode.js";
|
|
8
|
+
import { multiply } from "../../../../tree/nodes/operators/multiplyNode.js";
|
|
9
|
+
import { coinFlip } from "../../../../utils/alea/coinFlip.js";
|
|
10
|
+
import { random } from "../../../../utils/alea/random.js";
|
|
11
|
+
import { shuffle } from "../../../../utils/alea/shuffle.js";
|
|
12
|
+
import { handleVEAError } from "../../../../utils/errors/handleVEAError.js";
|
|
13
|
+
import { alignTex } from "../../../../utils/latex/alignTex.js";
|
|
14
|
+
const getInstruction = (identifiers) => {
|
|
15
|
+
const { rank1, value1, rank2, value2 } = identifiers;
|
|
16
|
+
const rankAsked = round(rank2 + 1, 0);
|
|
17
|
+
return `Soit $u$ une suite géométrique telle que $u_{${rank1.frenchify()}} = ${value1.frenchify()}$ et $u_{${rank2.frenchify()}} = ${value2.frenchify()}$.
|
|
18
|
+
|
|
19
|
+
Que vaut $u_{${rankAsked.frenchify()}}$ ?`;
|
|
20
|
+
};
|
|
21
|
+
const getAnswerStuff = (identifiers) => {
|
|
22
|
+
const { value1, value2 } = identifiers;
|
|
23
|
+
const nodeReason = frac(value2, value1).simplify({ towardsDistribute: true });
|
|
24
|
+
const nodeAnswer = multiply(value2, nodeReason);
|
|
25
|
+
return {
|
|
26
|
+
nodeReason,
|
|
27
|
+
nodeAnswer,
|
|
28
|
+
};
|
|
29
|
+
};
|
|
30
|
+
const getAnswer = (identifiers) => {
|
|
31
|
+
return getAnswerStuff(identifiers)
|
|
32
|
+
.nodeAnswer.simplify({ towardsDistribute: true })
|
|
33
|
+
.toTex();
|
|
34
|
+
};
|
|
35
|
+
const getHint = (identifiers, _optsIn) => {
|
|
36
|
+
const { rank2 } = identifiers;
|
|
37
|
+
const rankAsked = round(rank2 + 1, 0);
|
|
38
|
+
return `Commence par déterminer la raison $q$ de la suite $u$.
|
|
39
|
+
|
|
40
|
+
Puis, utilise cette raison et un des termes connus de la suite pour déterminer $u_{${rankAsked.frenchify()}}$.`;
|
|
41
|
+
};
|
|
42
|
+
const getCorrection = (identifiers) => {
|
|
43
|
+
const { rank1, value1, rank2, value2 } = identifiers;
|
|
44
|
+
const rankAsked = round(rank2 + 1, 0);
|
|
45
|
+
const { nodeReason, nodeAnswer } = getAnswerStuff(identifiers);
|
|
46
|
+
return `On commence par déterminer la raison $q$ de la suite $u$.
|
|
47
|
+
|
|
48
|
+
On a :
|
|
49
|
+
|
|
50
|
+
${alignTex([
|
|
51
|
+
["q", "=", `\\frac{u_{${rank2}}}{u_{${rank1}}}`],
|
|
52
|
+
["", "=", `\\frac{${value2.frenchify()}}{${value1.frenchify()}}`],
|
|
53
|
+
["", "=", `${nodeReason.toTex()}`],
|
|
54
|
+
])}
|
|
55
|
+
|
|
56
|
+
On peut alors déterminer $u_{${rankAsked.frenchify()}}$ en utilisant $u_{${rank2.frenchify()}}$ et $q$. En effet, on a :
|
|
57
|
+
|
|
58
|
+
${alignTex([
|
|
59
|
+
[
|
|
60
|
+
`u_{${rankAsked.frenchify()}}`,
|
|
61
|
+
"=",
|
|
62
|
+
`u_{${rank2.frenchify()}} \\ \\times \\ q`,
|
|
63
|
+
],
|
|
64
|
+
["", "=", nodeAnswer.toTex()],
|
|
65
|
+
["", "=", nodeAnswer.simplify({ towardsDistribute: true }).toTex()],
|
|
66
|
+
])}
|
|
67
|
+
|
|
68
|
+
`;
|
|
69
|
+
};
|
|
70
|
+
const getPropositions = (n, { answer, ..._identifiers }) => {
|
|
71
|
+
const propositions = [];
|
|
72
|
+
addValidProp(propositions, answer);
|
|
73
|
+
propWhile(propositions, n, () => {
|
|
74
|
+
const identifiersWrong = createRandomIdentifiersCurated();
|
|
75
|
+
const texWrong = getAnswer(identifiersWrong);
|
|
76
|
+
tryToAddWrongProp(propositions, texWrong);
|
|
77
|
+
});
|
|
78
|
+
return shuffle(propositions);
|
|
79
|
+
};
|
|
80
|
+
const isAnswerValid = (ans, { answer }) => {
|
|
81
|
+
try {
|
|
82
|
+
return numberVEA(ans, answer);
|
|
83
|
+
}
|
|
84
|
+
catch (err) {
|
|
85
|
+
return handleVEAError(err);
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
const createRandomIdentifiersRaw = () => {
|
|
89
|
+
const isDivergent = coinFlip();
|
|
90
|
+
const isReasonNegative = coinFlip();
|
|
91
|
+
const signReason = isReasonNegative ? -1 : +1;
|
|
92
|
+
function createGeometricDivergent() {
|
|
93
|
+
const precisionInitial = 1;
|
|
94
|
+
const initial = randfloat(1, 10, precisionInitial, [1]);
|
|
95
|
+
const precisionReason = 0;
|
|
96
|
+
const reason = signReason * randint(2, 10);
|
|
97
|
+
return [initial, precisionInitial, reason, precisionReason];
|
|
98
|
+
}
|
|
99
|
+
function createGeometricConvergent() {
|
|
100
|
+
const poolReasonStuff = [
|
|
101
|
+
{
|
|
102
|
+
q: 0.5,
|
|
103
|
+
precision: 1,
|
|
104
|
+
invQ: 2,
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
q: 0.25,
|
|
108
|
+
precision: 2,
|
|
109
|
+
invQ: 4,
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
q: 0.2,
|
|
113
|
+
precision: 1,
|
|
114
|
+
invQ: 5,
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
q: 0.1,
|
|
118
|
+
precision: 1,
|
|
119
|
+
invQ: 10,
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
q: 0.05,
|
|
123
|
+
precision: 2,
|
|
124
|
+
invQ: 20,
|
|
125
|
+
},
|
|
126
|
+
];
|
|
127
|
+
const { q, invQ, precision: precisionReason } = random(poolReasonStuff);
|
|
128
|
+
const reason = signReason * q;
|
|
129
|
+
const precisionInitial = 0;
|
|
130
|
+
const initial = round(randint(10, 20) * Math.pow(invQ, 8), precisionInitial);
|
|
131
|
+
return [initial, precisionInitial, reason, precisionReason];
|
|
132
|
+
}
|
|
133
|
+
const [initial, precisionInitial, reason, precisionReason] = (() => {
|
|
134
|
+
if (isDivergent) {
|
|
135
|
+
return createGeometricDivergent();
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
return createGeometricConvergent();
|
|
139
|
+
}
|
|
140
|
+
})();
|
|
141
|
+
const rank1 = randint(1, 5);
|
|
142
|
+
const rank2 = rank1 + 1;
|
|
143
|
+
const rankAsked = rank2 + 1;
|
|
144
|
+
function valueForRank(initial, reason, rank) {
|
|
145
|
+
return initial * Math.pow(reason, rank);
|
|
146
|
+
}
|
|
147
|
+
const [value1, value2] = [rank1, rank2].map((rank) => round(valueForRank(initial, reason, rank), 4));
|
|
148
|
+
const identifiers = {
|
|
149
|
+
rank1,
|
|
150
|
+
value1,
|
|
151
|
+
rank2,
|
|
152
|
+
value2,
|
|
153
|
+
precisionInitial,
|
|
154
|
+
precisionReason,
|
|
155
|
+
rankAsked,
|
|
156
|
+
};
|
|
157
|
+
return identifiers;
|
|
158
|
+
};
|
|
159
|
+
const createRandomIdentifiersCurated = () => {
|
|
160
|
+
let identifiers;
|
|
161
|
+
let isValid = false;
|
|
162
|
+
let counter = -1;
|
|
163
|
+
while (!isValid && counter < 100) {
|
|
164
|
+
counter++;
|
|
165
|
+
const identifiersCandidate = createRandomIdentifiersRaw();
|
|
166
|
+
getAnswerStuff(identifiersCandidate);
|
|
167
|
+
const answer = getAnswer(identifiersCandidate);
|
|
168
|
+
isValid = !answer.includes("NaN");
|
|
169
|
+
if (isValid) {
|
|
170
|
+
identifiers = identifiersCandidate;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
if (!isValid) {
|
|
174
|
+
//2.5 * 2^n
|
|
175
|
+
const identifiersDefault = {
|
|
176
|
+
rank1: 2,
|
|
177
|
+
value1: 10,
|
|
178
|
+
rank2: 5,
|
|
179
|
+
value2: 40,
|
|
180
|
+
precisionInitial: 1,
|
|
181
|
+
precisionReason: 0,
|
|
182
|
+
};
|
|
183
|
+
identifiers = identifiersDefault;
|
|
184
|
+
}
|
|
185
|
+
return identifiers;
|
|
186
|
+
};
|
|
187
|
+
const getGeometricFindNextTermFromTwoConsecutiveTermsQuestion = () => {
|
|
188
|
+
const identifiers = createRandomIdentifiersCurated();
|
|
189
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
190
|
+
};
|
|
191
|
+
const getQuestionFromIdentifiers = (identifiers, opts) => {
|
|
192
|
+
const question = {
|
|
193
|
+
answer: getAnswer(identifiers, opts),
|
|
194
|
+
instruction: getInstruction(identifiers, opts),
|
|
195
|
+
keys: [],
|
|
196
|
+
answerFormat: "tex",
|
|
197
|
+
identifiers,
|
|
198
|
+
hint: getHint(identifiers, opts),
|
|
199
|
+
correction: getCorrection(identifiers, opts),
|
|
200
|
+
options: opts,
|
|
201
|
+
};
|
|
202
|
+
return question;
|
|
203
|
+
};
|
|
204
|
+
export const geometricFindNextTermFromTwoConsecutiveTerms = {
|
|
205
|
+
id: "geometricFindNextTermFromTwoConsecutiveTerms",
|
|
206
|
+
connector: "=",
|
|
207
|
+
label: "Connaissant deux termes consécutifs d'une suite géométrique, calculer le terme suivant",
|
|
208
|
+
isSingleStep: true,
|
|
209
|
+
generator: (nb, opts) => getDistinctQuestions(() => getGeometricFindNextTermFromTwoConsecutiveTermsQuestion(opts), nb),
|
|
210
|
+
qcmTimer: 60,
|
|
211
|
+
freeTimer: 60,
|
|
212
|
+
getPropositions,
|
|
213
|
+
isAnswerValid,
|
|
214
|
+
subject: "Mathématiques",
|
|
215
|
+
getQuestionFromIdentifiers,
|
|
216
|
+
hasHintAndCorrection: true,
|
|
217
|
+
};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise.js";
|
|
2
|
+
import { OptionFirstTermRankOne } from "../../../../exercises/options/optionFirstTermRankOne.js";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
reason: number;
|
|
5
|
+
firstValue: number;
|
|
6
|
+
};
|
|
7
|
+
type Options = OptionFirstTermRankOne;
|
|
8
|
+
export declare const geometricFindRecurrenceFormula: Exercise<Identifiers, Options>;
|
|
9
|
+
export {};
|
|
10
|
+
//# sourceMappingURL=geometricFindRecurrenceFormula.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"geometricFindRecurrenceFormula.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/sequences/geometric/geometricFindRecurrenceFormula.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAeT,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAEL,sBAAsB,EACvB,MAAM,mDAAmD,CAAC;AAgB3D,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAuNF,KAAK,OAAO,GAAG,sBAAsB,CAAC;AAMtC,eAAO,MAAM,8BAA8B,EAAE,QAAQ,CAAC,WAAW,EAAE,OAAO,CAmBzE,CAAC"}
|