math-exercises 2.2.26 → 2.2.28
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/exercise.d.ts +2 -1
- package/lib/exercises/exercise.d.ts.map +1 -1
- package/lib/exercises/exercise.js +1 -1
- package/lib/exercises/math/calcul/addAndSub.js +1 -1
- package/lib/exercises/math/calcul/addAndSubWithoutRelatives.js +1 -1
- package/lib/exercises/math/calcul/arithmetics/commonDivisorsList.js +1 -1
- package/lib/exercises/math/calcul/arithmetics/divisibiltyCriteria.js +1 -1
- package/lib/exercises/math/calcul/arithmetics/divisorsList.js +1 -1
- package/lib/exercises/math/calcul/arithmetics/paritySumsAndProducts.js +1 -1
- package/lib/exercises/math/calcul/decimals/multiplyDecimalByTens.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionAndIntegerDivision.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionAndIntegerProduct.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionAndIntegerSum.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionToPercentToDecimal.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionsDivision.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionsProduct.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionsSum.js +1 -1
- package/lib/exercises/math/calcul/fractions/fractionsSumsMultiplesDenominators.js +1 -1
- package/lib/exercises/math/calcul/fractions/simplifyFraction.js +1 -1
- package/lib/exercises/math/calcul/index.js +1 -0
- package/lib/exercises/math/calcul/mentalCaluls/mentalAddAndSub.js +2 -2
- package/lib/exercises/math/calcul/mentalCaluls/mentalDivisions.js +2 -2
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplications.js +2 -2
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplicationsNoRelative.js +2 -2
- package/lib/exercises/math/calcul/mentalCaluls/mentalPercentage.js +2 -2
- package/lib/exercises/math/calcul/operations/expressionNature.js +1 -1
- package/lib/exercises/math/calcul/operations/operationsPriorities.js +2 -2
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesis.js +1 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesisNoRelatives.js +1 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesWithoutRelative.js +2 -2
- package/lib/exercises/math/calcul/ordering/decimalOrdering.js +1 -1
- package/lib/exercises/math/calcul/ordering/decimalOrderingNoRelatives.js +1 -1
- package/lib/exercises/math/calcul/ordering/framing.js +2 -2
- package/lib/exercises/math/calcul/ordering/integerOrdering.js +2 -2
- package/lib/exercises/math/calcul/proportionality/proportionalityTable.js +1 -1
- package/lib/exercises/math/calcul/proportionality/proportionalityTableCoefficient.js +1 -1
- package/lib/exercises/math/calcul/proportionality/scaleCalculation.js +1 -1
- package/lib/exercises/math/calcul/proportionality/scaleUsage.js +1 -1
- package/lib/exercises/math/calcul/rounding/rounding.d.ts.map +1 -1
- package/lib/exercises/math/calcul/rounding/rounding.js +5 -6
- package/lib/exercises/math/calcul/writing/index.d.ts +2 -0
- package/lib/exercises/math/calcul/writing/index.d.ts.map +1 -0
- package/lib/exercises/math/calcul/writing/index.js +17 -0
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.d.ts +7 -0
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.d.ts.map +1 -0
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.js +67 -0
- package/lib/exercises/math/calculLitteral/distributivity/allIdentities.js +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/doubleDistributivity.js +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/firstIdentity.js +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/secondIdentity.js +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/simpleDistributivity.js +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/thirdIdentity.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/binomialsTrinomialsProposedSolutions.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/equationFromSentenceExercise.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/equationSimpleSquare.js +3 -3
- package/lib/exercises/math/calculLitteral/equation/equationType1Exercise.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/equationType2Exercise.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/equationType3Exercise.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/equationType4Exercise.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/firstDegreeEquation.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/fractionEquation.js +1 -1
- package/lib/exercises/math/calculLitteral/equation/multiplicationEquation.js +1 -1
- package/lib/exercises/math/calculLitteral/factorisation/factoIdRmq1.js +1 -1
- package/lib/exercises/math/calculLitteral/factorisation/factoIdRmq2.js +1 -1
- package/lib/exercises/math/calculLitteral/factorisation/factoType1Exercise.js +2 -2
- package/lib/exercises/math/calculLitteral/factorisation/factoType2.js +1 -1
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType0.js +2 -2
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType1.js +2 -2
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType2.js +2 -2
- package/lib/exercises/math/calculLitteral/inequations/firstDegreeInequationsType3.js +2 -2
- package/lib/exercises/math/calculLitteral/inequations/squareFunctionInequation.js +1 -1
- package/lib/exercises/math/calculLitteral/simplifying/distributeAndSimplify.js +1 -1
- package/lib/exercises/math/calculLitteral/simplifying/evaluateExpression.js +2 -2
- package/lib/exercises/math/calculLitteral/simplifying/reduceExpression.js +1 -1
- package/lib/exercises/math/calculLitteral/systems/basicNiceValuesSystemResolution.js +1 -1
- package/lib/exercises/math/calculLitteral/systems/basicSystemResolution.js +1 -1
- package/lib/exercises/math/calculLitteral/systems/verifySystemSolution.js +1 -1
- package/lib/exercises/math/combinatory/anagrams.js +1 -1
- package/lib/exercises/math/complex/addComplex.js +1 -1
- package/lib/exercises/math/complex/argumentFromAlgebraicComplex.js +1 -1
- package/lib/exercises/math/complex/conjugateComplex.ts.js +1 -1
- package/lib/exercises/math/complex/conjugateDivideComplex.js +1 -1
- package/lib/exercises/math/complex/conjugateMultiplyComplex.js +1 -1
- package/lib/exercises/math/complex/divideComplex.js +1 -1
- package/lib/exercises/math/complex/inverseComplex.js +1 -1
- package/lib/exercises/math/complex/linearCombinaisonComplex.js +1 -1
- package/lib/exercises/math/complex/mutiplyComplex.js +1 -1
- package/lib/exercises/math/complex/reAndIm.js +2 -2
- package/lib/exercises/math/conversion/aeraConversion.js +1 -1
- package/lib/exercises/math/conversion/capacityConversion.js +1 -1
- package/lib/exercises/math/conversion/hoursToDecimal.js +1 -1
- package/lib/exercises/math/conversion/lengthConversion.js +1 -1
- package/lib/exercises/math/conversion/massConversion.js +1 -1
- package/lib/exercises/math/conversion/volumeCapacityConversion.js +2 -2
- package/lib/exercises/math/conversion/volumeConversion.js +1 -1
- package/lib/exercises/math/derivation/derivative/convexityQuadrinomials.js +1 -1
- package/lib/exercises/math/derivation/derivative/lnDerivativeTwo.js +1 -1
- package/lib/exercises/math/derivation/derivative/rootFunctionDerivative.js +1 -1
- package/lib/exercises/math/derivation/derivative/secondDegreeDerivative.js +1 -1
- package/lib/exercises/math/derivation/derivative/thirdDegreeFunctionVariation.js +2 -2
- package/lib/exercises/math/derivation/tangent/derivativeNumberReading.js +1 -1
- package/lib/exercises/math/derivation/tangent/derivativeTangentEquationReading.js +1 -1
- package/lib/exercises/math/equaDiff/equaDiffCheckSolutionFirstOrder.js +2 -2
- package/lib/exercises/math/equaDiff/equaDiffGeneralForme.js +1 -1
- package/lib/exercises/math/equaDiff/equaDiffGeneralFormeWithIC.js +1 -1
- package/lib/exercises/math/functions/absolute/absoluteValueEquations.js +2 -2
- package/lib/exercises/math/functions/absolute/absoluteValueInequations.js +1 -1
- package/lib/exercises/math/functions/affines/affineExpressionFromTwoImages.js +1 -1
- package/lib/exercises/math/functions/affines/leadingCoeffAndOriginOrdinate.js +1 -1
- package/lib/exercises/math/functions/affines/leadingCoefficient.js +1 -1
- package/lib/exercises/math/functions/affines/leadingCoefficientCalculV1.js +1 -1
- package/lib/exercises/math/functions/affines/leadingCoefficientCalculV2.js +1 -1
- package/lib/exercises/math/functions/affines/signFunction.js +2 -2
- package/lib/exercises/math/functions/basics/graphicEquation.js +1 -1
- package/lib/exercises/math/functions/basics/graphicInequation.js +1 -1
- package/lib/exercises/math/functions/basics/imageFunction.js +2 -2
- package/lib/exercises/math/functions/basics/imageFunctionGeogebra.js +2 -2
- package/lib/exercises/math/functions/basics/inverseImageFunction.js +1 -1
- package/lib/exercises/math/functions/basics/inverseImageFunctionGeogebra.js +2 -2
- package/lib/exercises/math/functions/basics/inverseImageFunctionTable.js +3 -3
- package/lib/exercises/math/functions/basics/twoFunctionsEquation.js +2 -2
- package/lib/exercises/math/functions/basics/twoFunctionsInequation.js +2 -2
- package/lib/exercises/math/functions/cube/cubicEquation.js +1 -1
- package/lib/exercises/math/functions/exponential/expEquation.js +1 -1
- package/lib/exercises/math/functions/exponential/expSimplifiying.js +1 -1
- package/lib/exercises/math/functions/integral/integralExpU.js +1 -1
- package/lib/exercises/math/functions/integral/integralFractions.js +1 -1
- package/lib/exercises/math/functions/logarithm/log10Simplifying.js +1 -1
- package/lib/exercises/math/functions/logarithm/logEquation.js +1 -1
- package/lib/exercises/math/functions/logarithm/logSimplifiying.js +2 -2
- package/lib/exercises/math/functions/parity/parityFromAlgebra.js +3 -3
- package/lib/exercises/math/functions/parity/parityFromGraph.js +3 -3
- package/lib/exercises/math/functions/rationalFraction/rationalFractionForbiddenValue.js +1 -1
- package/lib/exercises/math/functions/trinoms/alphaBetaFromDevForm.js +2 -2
- package/lib/exercises/math/functions/trinoms/alphaBetaInCanonicalForm.js +2 -2
- package/lib/exercises/math/functions/trinoms/canonicalFromDevForm.js +1 -1
- package/lib/exercises/math/functions/trinoms/deltaTrinom.js +1 -1
- package/lib/exercises/math/functions/trinoms/extremumFromCanonicalForm.js +1 -1
- package/lib/exercises/math/functions/trinoms/extremumTypeFromAlgebricForm.js +2 -2
- package/lib/exercises/math/functions/trinoms/factorizedFormFromRoots.js +1 -1
- package/lib/exercises/math/functions/trinoms/niceRootsFromDevForm.js +1 -1
- package/lib/exercises/math/functions/trinoms/rootsFromDevForm.js +1 -1
- package/lib/exercises/math/functions/trinoms/rootsFromFactorizedForm.js +1 -1
- package/lib/exercises/math/functions/trinoms/solveSecondDegreeEquationByFactorisation.js +1 -1
- package/lib/exercises/math/functions/trinoms/variationsFromAlgebricForm.js +2 -2
- package/lib/exercises/math/geometry/areas/circleArea.js +2 -2
- package/lib/exercises/math/geometry/areas/rectangleArea.js +1 -1
- package/lib/exercises/math/geometry/areas/rightTriangleArea.js +1 -1
- package/lib/exercises/math/geometry/areas/squareArea.js +1 -1
- package/lib/exercises/math/geometry/areas/triangleArea.js +1 -1
- package/lib/exercises/math/geometry/areas/triangleAreaV2.js +1 -1
- package/lib/exercises/math/geometry/cartesian/drawAlineInGGB.js +1 -1
- package/lib/exercises/math/geometry/cartesian/index.d.ts +4 -0
- package/lib/exercises/math/geometry/cartesian/index.d.ts.map +1 -1
- package/lib/exercises/math/geometry/cartesian/index.js +4 -0
- package/lib/exercises/math/geometry/cartesian/midpoint.js +1 -1
- package/lib/exercises/math/geometry/cartesian/placeAPoint.js +1 -1
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnLine.d.ts +13 -0
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnLine.d.ts.map +1 -0
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnLine.js +133 -0
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnSemiLine.d.ts +13 -0
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnSemiLine.d.ts.map +1 -0
- package/lib/exercises/math/geometry/cartesian/placeAbscissOnSemiLine.js +132 -0
- package/lib/exercises/math/geometry/cartesian/pointCoordinatesNoOrthonorm.js +1 -1
- package/lib/exercises/math/geometry/cartesian/readAbscissOnLine.d.ts +13 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnLine.d.ts.map +1 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnLine.js +152 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnSemiLine.d.ts +13 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnSemiLine.d.ts.map +1 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnSemiLine.js +153 -0
- package/lib/exercises/math/geometry/convexity/convexityQuadrinomialsGeo.js +1 -1
- package/lib/exercises/math/geometry/convexity/convexityTrinomialsGeo.js +1 -1
- package/lib/exercises/math/geometry/perimeters/circleCircumference.js +2 -2
- package/lib/exercises/math/geometry/perimeters/rectanglePerimeter.js +1 -1
- package/lib/exercises/math/geometry/perimeters/squarePerimeter.js +1 -1
- package/lib/exercises/math/geometry/perimeters/trianglePerimeter.js +1 -1
- package/lib/exercises/math/geometry/pythagore/pythagoreCalcul.js +2 -2
- package/lib/exercises/math/geometry/thales/thales.js +1 -1
- package/lib/exercises/math/geometry/thales/thalesCalcul.js +2 -2
- package/lib/exercises/math/geometry/vectors/alignementViaColinearity.js +2 -2
- package/lib/exercises/math/geometry/vectors/chasles.js +2 -2
- package/lib/exercises/math/geometry/vectors/colinearity.js +2 -2
- package/lib/exercises/math/geometry/vectors/determinant.js +1 -1
- package/lib/exercises/math/geometry/vectors/equalCaracteristicFromGraph.js +2 -2
- package/lib/exercises/math/geometry/vectors/fourthParallelogramPoint.js +1 -1
- package/lib/exercises/math/geometry/vectors/paralellismViaColinearity.js +2 -2
- package/lib/exercises/math/geometry/vectors/parallelogramViaEqualVectors.js +2 -2
- package/lib/exercises/math/geometry/vectors/scalarProduct/scalarProductOrthoInSquare.js +1 -1
- package/lib/exercises/math/geometry/vectors/scalarProduct/scalarProductViaCoords.js +1 -1
- package/lib/exercises/math/geometry/vectors/scalarProduct/scalarProductViaCos.js +1 -1
- package/lib/exercises/math/geometry/volumes/volumeOfPyramidWithSquareOrRectBase.js +1 -1
- package/lib/exercises/math/geometry/volumes/volumeOfPyramidWithTriangleBase.js +1 -1
- package/lib/exercises/math/geometry/volumes/volumeOfPyramidWithTriangleRectBase.js +1 -1
- package/lib/exercises/math/limits/limitReading.js +1 -1
- package/lib/exercises/math/limits/polynomLimit.js +2 -2
- package/lib/exercises/math/limits/polynomLimitNoFI.js +2 -2
- package/lib/exercises/math/limits/rationalFracForbiddenValueLimit.js +1 -1
- package/lib/exercises/math/limits/rationalFracLimit.js +2 -2
- package/lib/exercises/math/limits/sequencePolynomLimit.js +1 -1
- package/lib/exercises/math/limits/sequencePolynomNoFILimit.js +1 -1
- package/lib/exercises/math/limits/sequencePolynomProductLimit.js +1 -1
- package/lib/exercises/math/limits/sequenceRationalFracLimit.js +1 -1
- package/lib/exercises/math/percent/applyPercent.js +2 -2
- package/lib/exercises/math/percent/averageEvolutionRate.js +1 -1
- package/lib/exercises/math/percent/cmToEvolution.js +1 -1
- package/lib/exercises/math/percent/evolutionRateFromValues.d.ts +8 -0
- package/lib/exercises/math/percent/evolutionRateFromValues.d.ts.map +1 -0
- package/lib/exercises/math/percent/evolutionRateFromValues.js +71 -0
- package/lib/exercises/math/percent/findStartValueAfterEvolution.d.ts +8 -0
- package/lib/exercises/math/percent/findStartValueAfterEvolution.d.ts.map +1 -0
- package/lib/exercises/math/percent/findStartValueAfterEvolution.js +65 -0
- package/lib/exercises/math/percent/findTVA.js +2 -2
- package/lib/exercises/math/percent/globalPercent.js +1 -1
- package/lib/exercises/math/percent/htToTTC.js +2 -2
- package/lib/exercises/math/percent/index.d.ts +4 -0
- package/lib/exercises/math/percent/index.d.ts.map +1 -1
- package/lib/exercises/math/percent/index.js +4 -0
- package/lib/exercises/math/percent/isTableProportional.js +1 -1
- package/lib/exercises/math/percent/percentToDecimal.d.ts.map +1 -1
- package/lib/exercises/math/percent/percentToDecimal.js +70 -27
- package/lib/exercises/math/percent/populationEffectifFromSubPopulation.d.ts +9 -0
- package/lib/exercises/math/percent/populationEffectifFromSubPopulation.d.ts.map +1 -0
- package/lib/exercises/math/percent/populationEffectifFromSubPopulation.js +93 -0
- package/lib/exercises/math/percent/reciprocalPercentage.js +2 -2
- package/lib/exercises/math/percent/subPopulationEffectifFromPercent.d.ts +9 -0
- package/lib/exercises/math/percent/subPopulationEffectifFromPercent.d.ts.map +1 -0
- package/lib/exercises/math/percent/subPopulationEffectifFromPercent.js +85 -0
- package/lib/exercises/math/percent/ttcToHT.js +2 -2
- package/lib/exercises/math/powers/decimalToScientific.js +1 -1
- package/lib/exercises/math/powers/powersDivision.js +1 -1
- package/lib/exercises/math/powers/powersOfTenToDecimal.js +1 -1
- package/lib/exercises/math/powers/powersProduct.js +1 -1
- package/lib/exercises/math/primitive/constantPrimitive.js +1 -1
- package/lib/exercises/math/primitive/logarithmePrimitive.js +1 -1
- package/lib/exercises/math/primitive/polynomialPrimitive.js +1 -1
- package/lib/exercises/math/primitive/sinCosPrimitive.js +2 -2
- package/lib/exercises/math/primitive/sinUCosUPrimitive.js +2 -2
- package/lib/exercises/math/probaStat/cardBasicProbas.js +2 -2
- package/lib/exercises/math/probaStat/conditionalProbability.js +1 -1
- package/lib/exercises/math/probaStat/diceBasicProbas.js +2 -2
- package/lib/exercises/math/probaStat/independancy.js +2 -2
- package/lib/exercises/math/probaStat/issuesCountingForCards.js +3 -3
- package/lib/exercises/math/probaStat/probaFromTableNoContext.js +1 -1
- package/lib/exercises/math/probaStat/probaFromTableWithContext.js +1 -1
- package/lib/exercises/math/probaStat/probabilityTree.js +1 -1
- package/lib/exercises/math/probaStat/stats1var/averageWithTable.js +1 -1
- package/lib/exercises/math/probaStat/stats1var/marginalAndConditionalFrequency.d.ts.map +1 -1
- package/lib/exercises/math/probaStat/stats1var/marginalAndConditionalFrequency.js +2 -1
- package/lib/exercises/math/probaStat/stats1var/median.js +1 -1
- package/lib/exercises/math/probaStat/stats1var/quartiles.js +1 -1
- package/lib/exercises/math/probaStat/stats2var/fineAdjustementExercise.js +1 -1
- package/lib/exercises/math/python/pyForLoop1Exercise.js +2 -2
- package/lib/exercises/math/python/pyNestedForLoopExercise.js +1 -1
- package/lib/exercises/math/python/pyWhileLoop1Exercise.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticExplicitFormulaUsage.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplicitFormula.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplictFormulaFirstTermRandom.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReason.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReasonRandomRange.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindTerm.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFirstTermsSum.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticReasonUsage.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticRecurrenceFormulaUsage.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticThresholdFind.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/firstIntegersSum.js +1 -1
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromFirstTerms.js +2 -2
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromGraph.js +2 -2
- package/lib/exercises/math/sequences/geometric/geometricExplicitFormulaUsage.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormula.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormulaFirstTermRandom.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindReason.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindTerm.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFirstTermsGeneralSum.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFirstTermsSum.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricReasonUsage.js +1 -1
- package/lib/exercises/math/sequences/geometric/geometricRecurrenceFormulaUsage.js +1 -1
- package/lib/exercises/math/sequences/sequencePlot.js +1 -1
- package/lib/exercises/math/sets/intervals/inequalityToInterval.js +1 -1
- package/lib/exercises/math/sets/intervals/intervalToInequality.js +1 -1
- package/lib/exercises/math/sets/intervals/intervalsIntersection.js +1 -1
- package/lib/exercises/math/sets/intervals/intervalsUnion.js +1 -1
- package/lib/exercises/math/sets/setBelonging.js +2 -2
- package/lib/exercises/math/squareRoots/simpifySquareRoot.js +1 -1
- package/lib/exercises/math/squareRoots/squareRootEquation.js +1 -1
- package/lib/exercises/math/squareRoots/squareRootIdentities.js +2 -2
- package/lib/exercises/math/squareRoots/squareRootsSum.js +1 -1
- package/lib/exercises/math/trigonometry/arcLength.d.ts +10 -0
- package/lib/exercises/math/trigonometry/arcLength.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/arcLength.js +92 -0
- package/lib/exercises/math/trigonometry/associatePoint.js +1 -1
- package/lib/exercises/math/trigonometry/basicEquationCos.d.ts +7 -0
- package/lib/exercises/math/trigonometry/basicEquationCos.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/basicEquationCos.js +94 -0
- package/lib/exercises/math/trigonometry/basicEquationSin.d.ts +7 -0
- package/lib/exercises/math/trigonometry/basicEquationSin.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/basicEquationSin.js +106 -0
- package/lib/exercises/math/trigonometry/basicTrigoSystemEquation.d.ts +7 -0
- package/lib/exercises/math/trigonometry/basicTrigoSystemEquation.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/basicTrigoSystemEquation.js +85 -0
- package/lib/exercises/math/trigonometry/calculateCosSinAndTan.js +1 -1
- package/lib/exercises/math/trigonometry/degreeToRadians.d.ts +9 -0
- package/lib/exercises/math/trigonometry/degreeToRadians.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/degreeToRadians.js +125 -0
- package/lib/exercises/math/trigonometry/index.d.ts +6 -0
- package/lib/exercises/math/trigonometry/index.d.ts.map +1 -1
- package/lib/exercises/math/trigonometry/index.js +6 -0
- package/lib/exercises/math/trigonometry/mainAngleMeasure.d.ts +9 -0
- package/lib/exercises/math/trigonometry/mainAngleMeasure.d.ts.map +1 -0
- package/lib/exercises/math/trigonometry/mainAngleMeasure.js +91 -0
- package/lib/exercises/math/trigonometry/mainRemarkableValues.js +2 -2
- package/lib/exercises/math/trigonometry/remarkableValues.js +3 -3
- package/lib/exercises/math/trigonometry/trigonometry.js +1 -1
- package/lib/exercises/math/trigonometry/trigonometryAngleCalcul.js +1 -1
- package/lib/exercises/math/trigonometry/trigonometrySideCalcul.js +1 -1
- package/lib/exercises/pc/calibrationCurveOfSolution.js +2 -2
- package/lib/exercises/pc/chemicalElements/atomicStructureOfNucleus.js +1 -1
- package/lib/exercises/pc/chemicalElements/calculateProtonsNumberFromMass.js +2 -2
- package/lib/exercises/pc/chemicalElements/findAtomEntitiesNumberFromMass.js +1 -1
- package/lib/exercises/pc/chemicalElements/findAtomicStructureElement.js +1 -1
- package/lib/exercises/pc/chemicalElements/findValenceElectronsNumberFromElectronicConfiguration.js +1 -1
- package/lib/exercises/pc/chemicalElements/findValenceElectronsNumberFromTable.js +1 -1
- package/lib/exercises/pc/chemicalElements/identifyRightElectronicConfiguration.js +1 -1
- package/lib/exercises/pc/chemicalElements/massOrVolumeProportion.js +2 -2
- package/lib/exercises/pc/chemicalEquations.js +1 -1
- package/lib/exercises/pc/chemicalReactions/calculateCombustionEnergy.js +1 -1
- package/lib/exercises/pc/chemicalReactions/identifyStoichiometricMixture.js +1 -1
- package/lib/exercises/pc/chemicalReactions/stoichiometricReaction.js +1 -1
- package/lib/exercises/pc/chemicalReactions/titrationEquivalenceRelation.js +1 -1
- package/lib/exercises/pc/chemicalReactionsProduct.js +1 -1
- package/lib/exercises/pc/delution.js +1 -1
- package/lib/exercises/pc/dosage/beerLambertRandomValue.js +1 -1
- package/lib/exercises/pc/electricity/calculateIntensityInSerieOrParallel.js +1 -1
- package/lib/exercises/pc/electricity/calculateVoltage.js +1 -1
- package/lib/exercises/pc/electricity/electricEnergyFromPower.js +1 -1
- package/lib/exercises/pc/electricity/electricPowerOrEnergyCalculation.js +2 -2
- package/lib/exercises/pc/electricity/kirchhoffVoltageLaw.js +1 -1
- package/lib/exercises/pc/electricity/ohmicConductorOrGenerator.js +1 -1
- package/lib/exercises/pc/energy/kineticEnergyOrMassOrSpeed.js +2 -2
- package/lib/exercises/pc/fluids/mariotte.js +1 -1
- package/lib/exercises/pc/forces/calculateNormalOrFrictionForce.js +1 -1
- package/lib/exercises/pc/forces/forceWork.js +1 -1
- package/lib/exercises/pc/forces/massWeight.js +1 -1
- package/lib/exercises/pc/forces/pressingForce.js +1 -1
- package/lib/exercises/pc/formulaFromComposition.js +1 -1
- package/lib/exercises/pc/identifyAtomicMassOrAtomicNb.js +2 -2
- package/lib/exercises/pc/kineticEnergy.js +1 -1
- package/lib/exercises/pc/math/isolateVariables.js +1 -1
- package/lib/exercises/pc/math/proportionnalityCoeffFromLine.js +1 -1
- package/lib/exercises/pc/molarQuantity.js +1 -1
- package/lib/exercises/pc/mole/molarMass.js +1 -1
- package/lib/exercises/pc/mole/moleculeCountFromMassAndAvogadro.js +1 -1
- package/lib/exercises/pc/moleculeFormula.js +1 -1
- package/lib/exercises/pc/moleculeNomenclature.js +1 -1
- package/lib/exercises/pc/motion/averageSpeed.d.ts.map +1 -1
- package/lib/exercises/pc/motion/characteristicsOfVelocityVector.js +1 -1
- package/lib/exercises/pc/motion/motionReference.js +1 -1
- package/lib/exercises/pc/motion/typeOfAcceleration.js +1 -1
- package/lib/exercises/pc/motion/typeOfMovement.js +1 -1
- package/lib/exercises/pc/pH.js +1 -1
- package/lib/exercises/pc/perceivedFrequency.js +1 -1
- package/lib/exercises/pc/potentialEnergy.js +1 -1
- package/lib/exercises/pc/recognizeRefractionOrReflectionAngles.js +1 -1
- package/lib/exercises/pc/snellDescartes.js +1 -1
- package/lib/exercises/pc/sound/findPeriodFromGraph.js +1 -1
- package/lib/exercises/pc/sound/findPeriodOrFrequencyFromGraph.js +1 -1
- package/lib/exercises/pc/sound/frequencyComparison.js +1 -1
- package/lib/exercises/pc/waves/lightDistanceConversion.js +1 -1
- package/lib/exercises/pc/waves/periodicWaveCelerity.js +1 -1
- package/lib/exercises/pc/weight/weightOnTheMoon.js +1 -1
- package/lib/exercises/utils/getDistinctQuestions.d.ts +1 -1
- package/lib/exercises/utils/getDistinctQuestions.d.ts.map +1 -1
- package/lib/exercises/utils/getDistinctQuestions.js +11 -5
- package/lib/geogebra/colors.js +1 -1
- package/lib/geogebra/geogebraConstructor.js +1 -1
- package/lib/geogebra/parsers/ggbPointToCoords.d.ts +5 -0
- package/lib/geogebra/parsers/ggbPointToCoords.d.ts.map +1 -0
- package/lib/geogebra/parsers/ggbPointToCoords.js +12 -0
- package/lib/geogebra/parsers/parseGGBPoints.d.ts +2 -0
- package/lib/geogebra/parsers/parseGGBPoints.d.ts.map +1 -0
- package/lib/geogebra/parsers/parseGGBPoints.js +10 -0
- package/lib/index.d.ts +61 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/math/geometry/line.d.ts.map +1 -1
- package/lib/math/geometry/line.js +0 -1
- package/lib/math/inequations/inequation.js +1 -1
- package/lib/math/numbers/decimals/decimal.d.ts +1 -0
- package/lib/math/numbers/decimals/decimal.d.ts.map +1 -1
- package/lib/math/numbers/decimals/decimal.js +10 -0
- package/lib/math/numbers/integer/integer.d.ts +2 -0
- package/lib/math/numbers/integer/integer.d.ts.map +1 -1
- package/lib/math/numbers/integer/integer.js +10 -1
- package/lib/math/numbers/nombre.js +1 -1
- package/lib/math/numbers/rationals/rational.js +3 -3
- package/lib/math/numbers/reals/real.js +2 -2
- package/lib/math/polynomials/polynomial.js +1 -1
- package/lib/math/polynomials/trinom.js +1 -1
- package/lib/math/sequences/geometricSequence.d.ts +2 -2
- package/lib/math/sequences/geometricSequence.d.ts.map +1 -1
- package/lib/math/sequences/geometricSequence.js +13 -11
- package/lib/math/sets/discreteSet.d.ts +2 -2
- package/lib/math/sets/discreteSet.d.ts.map +1 -1
- package/lib/math/sets/discreteSet.js +4 -4
- package/lib/math/sets/intervals/intervals.js +1 -1
- package/lib/math/trigonometry/remarkableValue.js +1 -1
- package/lib/math/trigonometry/remarkableValues.d.ts +3 -0
- package/lib/math/trigonometry/remarkableValues.d.ts.map +1 -1
- package/lib/math/trigonometry/remarkableValues.js +72 -1
- package/lib/math/utils/random/randTupleInt.js +1 -1
- package/lib/playground.d.ts.map +1 -1
- package/lib/playground.js +1 -10
- package/lib/tree/nodes/equations/multiEqualNode.js +2 -2
- package/lib/tree/nodes/geometry/degree.d.ts.map +1 -1
- package/lib/tree/nodes/geometry/degree.js +3 -2
- package/lib/tree/nodes/geometry/pointNode.js +1 -1
- package/lib/tree/nodes/inequations/inequationNode.js +1 -1
- package/lib/tree/nodes/operators/addNode.js +3 -3
- package/lib/tree/nodes/operators/divideNode.js +1 -1
- package/lib/tree/nodes/operators/multiplyNode.js +3 -3
- package/lib/tree/nodes/operators/substractNode.js +1 -1
- package/lib/tree/nodes/sets/discreteSetNode.d.ts +1 -0
- package/lib/tree/nodes/sets/discreteSetNode.d.ts.map +1 -1
- package/lib/tree/nodes/sets/discreteSetNode.js +8 -2
- package/lib/tree/nodes/sets/intervalNode.js +1 -1
- package/lib/tree/nodes/sets/unionIntervalNode.js +2 -2
- package/lib/tree/parsers/euroParser.d.ts +2 -0
- package/lib/tree/parsers/euroParser.d.ts.map +1 -0
- package/lib/tree/parsers/euroParser.js +12 -0
- package/lib/tree/parsers/percentParser.d.ts +1 -0
- package/lib/tree/parsers/percentParser.d.ts.map +1 -1
- package/lib/tree/parsers/percentParser.js +11 -0
- package/lib/utils/alea/coinFlip.d.ts +2 -0
- package/lib/utils/alea/coinFlip.d.ts.map +1 -0
- package/lib/utils/alea/coinFlip.js +7 -0
- package/lib/utils/alea/diceFlip.d.ts +2 -0
- package/lib/utils/alea/diceFlip.d.ts.map +1 -0
- package/lib/utils/alea/diceFlip.js +8 -0
- package/lib/utils/alea/probaFlip.d.ts +7 -0
- package/lib/utils/alea/probaFlip.d.ts.map +1 -0
- package/lib/utils/alea/probaFlip.js +12 -0
- package/lib/utils/alea/probaLawFlip.d.ts +7 -0
- package/lib/utils/alea/probaLawFlip.d.ts.map +1 -0
- package/lib/utils/alea/probaLawFlip.js +24 -0
- package/lib/utils/alea/random.d.ts +2 -0
- package/lib/utils/alea/random.d.ts.map +1 -0
- package/lib/utils/alea/random.js +7 -0
- package/lib/utils/alea/randomEnumValue.d.ts +2 -0
- package/lib/utils/alea/randomEnumValue.d.ts.map +1 -0
- package/lib/utils/alea/randomEnumValue.js +9 -0
- package/lib/utils/alea/shuffle.d.ts +2 -0
- package/lib/utils/alea/shuffle.d.ts.map +1 -0
- package/lib/utils/alea/shuffle.js +15 -0
- package/lib/utils/arrays/arrayEqual.d.ts +2 -0
- package/lib/utils/arrays/arrayEqual.d.ts.map +1 -0
- package/lib/utils/arrays/arrayEqual.js +13 -0
- package/lib/utils/arrays/arrayHasSameElement.d.ts +2 -0
- package/lib/utils/arrays/arrayHasSameElement.d.ts.map +1 -0
- package/lib/utils/arrays/arrayHasSameElement.js +8 -0
- package/lib/utils/arrays/cartesianProducts.d.ts +13 -0
- package/lib/utils/arrays/cartesianProducts.d.ts.map +1 -0
- package/lib/utils/arrays/cartesianProducts.js +64 -0
- package/lib/utils/arrays/enumToArray.d.ts +8 -0
- package/lib/utils/arrays/enumToArray.d.ts.map +1 -0
- package/lib/utils/arrays/enumToArray.js +16 -0
- package/lib/utils/arrays/permutations.d.ts +2 -0
- package/lib/utils/arrays/permutations.d.ts.map +1 -0
- package/lib/utils/arrays/permutations.js +21 -0
- package/lib/utils/latex/alignTex.d.ts +1 -1
- package/lib/utils/latex/alignTex.d.ts.map +1 -1
- package/lib/utils/latex/alignTex.js +3 -3
- package/lib/utils/strings/frenchNumbers.d.ts +6 -0
- package/lib/utils/strings/frenchNumbers.d.ts.map +1 -0
- package/lib/utils/strings/frenchNumbers.js +50 -0
- package/lib/utils/strings/numberToFrenchWord.d.ts +2 -0
- package/lib/utils/strings/numberToFrenchWord.d.ts.map +1 -0
- package/lib/utils/strings/numberToFrenchWord.js +81 -0
- package/package.json +1 -1
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.arcLength = 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 degree_1 = require("../../../tree/nodes/geometry/degree");
|
|
8
|
+
const nodeConstructor_1 = require("../../../tree/nodes/nodeConstructor");
|
|
9
|
+
const piNode_1 = require("../../../tree/nodes/numbers/piNode");
|
|
10
|
+
const fractionNode_1 = require("../../../tree/nodes/operators/fractionNode");
|
|
11
|
+
const multiplyNode_1 = require("../../../tree/nodes/operators/multiplyNode");
|
|
12
|
+
const coinFlip_1 = require("../../../utils/alea/coinFlip");
|
|
13
|
+
const getPropositions = (n, { answer, isThetaInDegree, radius }) => {
|
|
14
|
+
const propositions = [];
|
|
15
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
16
|
+
while (propositions.length < n) {
|
|
17
|
+
const thetaInDegree = isThetaInDegree ? (0, randint_1.randint)(1, 360) : undefined;
|
|
18
|
+
const thetaInRadNodeIds = isThetaInDegree
|
|
19
|
+
? undefined
|
|
20
|
+
: new fractionNode_1.FractionNode(new multiplyNode_1.MultiplyNode((2).toTree(), piNode_1.PiNode), (0, randint_1.randint)(2, 20).toTree())
|
|
21
|
+
.simplify()
|
|
22
|
+
.toIdentifiers();
|
|
23
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ isThetaInDegree, radius, thetaInDegree, thetaInRadNodeIds }));
|
|
24
|
+
}
|
|
25
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
26
|
+
};
|
|
27
|
+
const getAnswerNode = (identifiers) => {
|
|
28
|
+
if (identifiers.isThetaInDegree) {
|
|
29
|
+
return new fractionNode_1.FractionNode(new multiplyNode_1.MultiplyNode((identifiers.radius * identifiers.thetaInDegree).toTree(), piNode_1.PiNode), (180).toTree()).simplify();
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
const node = nodeConstructor_1.NodeConstructor.fromIdentifiers(identifiers.thetaInRadNodeIds);
|
|
33
|
+
return new multiplyNode_1.MultiplyNode(identifiers.radius.toTree(), node).simplify();
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
const getAnswer = (identifiers) => {
|
|
37
|
+
return getAnswerNode(identifiers).toTex();
|
|
38
|
+
};
|
|
39
|
+
const getInstruction = (identifiers) => {
|
|
40
|
+
return `Soit $\\mathcal C$ un cercle de centre $O$ et de rayon $${identifiers.radius}$. Soient $A$ et $B$ deux points sur ce cercle. L'angle au centre $\\widehat{BAO}$ vaut $${identifiers.isThetaInDegree
|
|
41
|
+
? new degree_1.DegreeNode(identifiers.thetaInDegree).toTex()
|
|
42
|
+
: nodeConstructor_1.NodeConstructor.fromIdentifiers(identifiers.thetaInRadNodeIds).toTex() +
|
|
43
|
+
"\\ \\text{rad}"}$. Quelle est la longueur de l'arc de cercle $\\overset{\\Large \\frown}{AB}$ ?`;
|
|
44
|
+
};
|
|
45
|
+
const getKeys = (identifiers) => {
|
|
46
|
+
return ["pi"];
|
|
47
|
+
};
|
|
48
|
+
const isAnswerValid = (ans, { answer, isThetaInDegree, radius, thetaInDegree, thetaInRadNodeIds }) => {
|
|
49
|
+
const node = getAnswerNode({
|
|
50
|
+
isThetaInDegree,
|
|
51
|
+
radius,
|
|
52
|
+
thetaInDegree,
|
|
53
|
+
thetaInRadNodeIds,
|
|
54
|
+
});
|
|
55
|
+
return node.toAllValidTexs().includes(ans);
|
|
56
|
+
};
|
|
57
|
+
const getArcLengthQuestion = () => {
|
|
58
|
+
const radius = (0, randint_1.randint)(1, 6);
|
|
59
|
+
const isThetaInDegree = (0, coinFlip_1.coinFlip)();
|
|
60
|
+
const thetaInDegree = isThetaInDegree ? (0, randint_1.randint)(1, 360) : undefined;
|
|
61
|
+
const thetaInRadNode = isThetaInDegree
|
|
62
|
+
? undefined
|
|
63
|
+
: new fractionNode_1.FractionNode(new multiplyNode_1.MultiplyNode((2).toTree(), piNode_1.PiNode), (0, randint_1.randint)(2, 20).toTree()).simplify();
|
|
64
|
+
const identifiers = {
|
|
65
|
+
isThetaInDegree,
|
|
66
|
+
radius,
|
|
67
|
+
thetaInDegree,
|
|
68
|
+
thetaInRadNodeIds: thetaInRadNode?.toIdentifiers(),
|
|
69
|
+
};
|
|
70
|
+
const question = {
|
|
71
|
+
answer: getAnswer(identifiers),
|
|
72
|
+
instruction: getInstruction(identifiers),
|
|
73
|
+
keys: getKeys(identifiers),
|
|
74
|
+
answerFormat: "tex",
|
|
75
|
+
identifiers,
|
|
76
|
+
};
|
|
77
|
+
return question;
|
|
78
|
+
};
|
|
79
|
+
exports.arcLength = {
|
|
80
|
+
id: "arcLength",
|
|
81
|
+
connector: "=",
|
|
82
|
+
label: "Calculer la longueur d'un arc de cercle à partir de l'angle au centre",
|
|
83
|
+
isSingleStep: true,
|
|
84
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getArcLengthQuestion, nb),
|
|
85
|
+
qcmTimer: 60,
|
|
86
|
+
freeTimer: 60,
|
|
87
|
+
ggbTimer: 60,
|
|
88
|
+
getPropositions,
|
|
89
|
+
isAnswerValid,
|
|
90
|
+
subject: "Mathématiques",
|
|
91
|
+
getAnswer,
|
|
92
|
+
};
|
|
@@ -4,7 +4,7 @@ exports.associatePoint = void 0;
|
|
|
4
4
|
const exercise_1 = require("../../../exercises/exercise");
|
|
5
5
|
const getDistinctQuestions_1 = require("../../../exercises/utils/getDistinctQuestions");
|
|
6
6
|
const remarkableValue_1 = require("../../../math/trigonometry/remarkableValue");
|
|
7
|
-
const random_1 = require("../../../utils/random");
|
|
7
|
+
const random_1 = require("../../../utils/alea/random");
|
|
8
8
|
const points = [
|
|
9
9
|
"I",
|
|
10
10
|
"A",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"basicEquationCos.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/basicEquationCos.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAgBlC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AA6EF,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAC,WAAW,CAiBlD,CAAC"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.basicEquationCos = void 0;
|
|
4
|
+
const exercise_1 = require("../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const remarkableValues_1 = require("../../../math/trigonometry/remarkableValues");
|
|
7
|
+
const equationSolutionNode_1 = require("../../../tree/nodes/equations/equationSolutionNode");
|
|
8
|
+
const cosNode_1 = require("../../../tree/nodes/functions/cosNode");
|
|
9
|
+
const oppositeNode_1 = require("../../../tree/nodes/functions/oppositeNode");
|
|
10
|
+
const discreteSetNode_1 = require("../../../tree/nodes/sets/discreteSetNode");
|
|
11
|
+
const random_1 = require("../../../utils/alea/random");
|
|
12
|
+
const getPropositions = (n, { answer, degree }) => {
|
|
13
|
+
const propositions = [];
|
|
14
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
15
|
+
//distracteur avec une solution manquante
|
|
16
|
+
if (degree !== 0 && degree !== 180) {
|
|
17
|
+
const answerNode = getAnswerNode({ degree });
|
|
18
|
+
const newSet = answerNode.solutionsSet.toDeleteRandomElement();
|
|
19
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new equationSolutionNode_1.EquationSolutionNode(newSet).toTex());
|
|
20
|
+
}
|
|
21
|
+
while (propositions.length < n) {
|
|
22
|
+
const value = (0, random_1.random)(remarkableValues_1.mainPositiveTrigovalues);
|
|
23
|
+
const randDegree = value.degree;
|
|
24
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ degree: randDegree }));
|
|
25
|
+
}
|
|
26
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
27
|
+
};
|
|
28
|
+
const getAnswerNode = (identifiers) => {
|
|
29
|
+
const value = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree);
|
|
30
|
+
if (value.degree === 0 || value.degree === 180)
|
|
31
|
+
return new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([value.angle]));
|
|
32
|
+
const ans2 = value.angle;
|
|
33
|
+
const ans1 = new oppositeNode_1.OppositeNode(value.angle);
|
|
34
|
+
return new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([ans1, ans2]));
|
|
35
|
+
};
|
|
36
|
+
const getAnswer = (identifiers) => {
|
|
37
|
+
return getAnswerNode(identifiers).toTex();
|
|
38
|
+
};
|
|
39
|
+
const getInstruction = (identifiers) => {
|
|
40
|
+
const cos = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree).cos;
|
|
41
|
+
return `Résoudre :
|
|
42
|
+
|
|
43
|
+
$$
|
|
44
|
+
${new cosNode_1.CosNode("x".toTree()).toTex()}=${cos.toTex()}
|
|
45
|
+
$$
|
|
46
|
+
|
|
47
|
+
Donner les solutions dans l'intervalle $\\left]-\\pi,\\pi\\right]$.
|
|
48
|
+
`;
|
|
49
|
+
};
|
|
50
|
+
// const getHint: GetHint<Identifiers> = (identifiers) => {
|
|
51
|
+
// return "";
|
|
52
|
+
// };
|
|
53
|
+
// const getCorrection: GetCorrection<Identifiers> = (identifiers) => {
|
|
54
|
+
// return "";
|
|
55
|
+
// };
|
|
56
|
+
const getKeys = (identifiers) => {
|
|
57
|
+
return ["x", "S", "equal", "lbrace", "semicolon", "rbrace", "pi"];
|
|
58
|
+
};
|
|
59
|
+
const isAnswerValid = (ans, { answer, degree }) => {
|
|
60
|
+
const answerNode = getAnswerNode({ degree });
|
|
61
|
+
return answerNode.toAllValidTexs().includes(ans);
|
|
62
|
+
};
|
|
63
|
+
const getBasicEquationCosQuestion = () => {
|
|
64
|
+
const value = (0, random_1.random)(remarkableValues_1.mainPositiveTrigovalues);
|
|
65
|
+
const degree = value.degree;
|
|
66
|
+
const identifiers = { degree };
|
|
67
|
+
const question = {
|
|
68
|
+
answer: getAnswer(identifiers),
|
|
69
|
+
instruction: getInstruction(identifiers),
|
|
70
|
+
keys: getKeys(identifiers),
|
|
71
|
+
answerFormat: "tex",
|
|
72
|
+
identifiers,
|
|
73
|
+
// hint: getHint(identifiers),
|
|
74
|
+
// correction: getCorrection(identifiers),
|
|
75
|
+
};
|
|
76
|
+
return question;
|
|
77
|
+
};
|
|
78
|
+
exports.basicEquationCos = {
|
|
79
|
+
id: "basicEquationCos",
|
|
80
|
+
connector: "\\iff",
|
|
81
|
+
label: "Résoudre une équation du type $\\cos\\left(x\\right)=k$",
|
|
82
|
+
isSingleStep: true,
|
|
83
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getBasicEquationCosQuestion, nb, 9),
|
|
84
|
+
qcmTimer: 60,
|
|
85
|
+
freeTimer: 60,
|
|
86
|
+
ggbTimer: 60,
|
|
87
|
+
getPropositions,
|
|
88
|
+
isAnswerValid,
|
|
89
|
+
subject: "Mathématiques",
|
|
90
|
+
// getHint,
|
|
91
|
+
// getCorrection,
|
|
92
|
+
getAnswer,
|
|
93
|
+
maxAllowedQuestions: 9,
|
|
94
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"basicEquationSin.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/basicEquationSin.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAclC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAyFF,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAC,WAAW,CAiBlD,CAAC"}
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.basicEquationSin = void 0;
|
|
4
|
+
const exercise_1 = require("../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const remarkableValues_1 = require("../../../math/trigonometry/remarkableValues");
|
|
7
|
+
const equationSolutionNode_1 = require("../../../tree/nodes/equations/equationSolutionNode");
|
|
8
|
+
const sinNode_1 = require("../../../tree/nodes/functions/sinNode");
|
|
9
|
+
const discreteSetNode_1 = require("../../../tree/nodes/sets/discreteSetNode");
|
|
10
|
+
const random_1 = require("../../../utils/alea/random");
|
|
11
|
+
const getPropositions = (n, { answer, degree }) => {
|
|
12
|
+
const propositions = [];
|
|
13
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
14
|
+
//distracteur avec une solution manquante
|
|
15
|
+
if (degree !== 90 && degree !== 270) {
|
|
16
|
+
const answerNode = getAnswerNode({ degree });
|
|
17
|
+
const newSet = answerNode.solutionsSet.toDeleteRandomElement();
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new equationSolutionNode_1.EquationSolutionNode(newSet).toTex());
|
|
19
|
+
}
|
|
20
|
+
const mainSinusValues = remarkableValues_1.mainTrigoValues.slice(3, 12);
|
|
21
|
+
while (propositions.length < n) {
|
|
22
|
+
const value = (0, random_1.random)(mainSinusValues);
|
|
23
|
+
const randDegree = value.degree;
|
|
24
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, getAnswer({ degree: randDegree }));
|
|
25
|
+
}
|
|
26
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
27
|
+
};
|
|
28
|
+
const getAnswerNode = (identifiers) => {
|
|
29
|
+
const value = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree);
|
|
30
|
+
if (value.degree === 90 || value.degree === 270)
|
|
31
|
+
return new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([value.angle]));
|
|
32
|
+
const isNegative = value.degree > 270;
|
|
33
|
+
let ans1;
|
|
34
|
+
let ans2;
|
|
35
|
+
if (isNegative) {
|
|
36
|
+
ans2 = value.angle;
|
|
37
|
+
const oppositeDegree = 270 - (value.degree - 270);
|
|
38
|
+
ans1 = remarkableValues_1.mainTrigoValues.find((v) => v.degree === oppositeDegree).angle;
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
ans1 = value.angle;
|
|
42
|
+
const oppositeDegree = 90 + (90 - value.degree);
|
|
43
|
+
ans2 = remarkableValues_1.mainTrigoValues.find((v) => v.degree === oppositeDegree).angle;
|
|
44
|
+
}
|
|
45
|
+
return new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([ans1, ans2]));
|
|
46
|
+
};
|
|
47
|
+
const getAnswer = (identifiers) => {
|
|
48
|
+
return getAnswerNode(identifiers).toTex();
|
|
49
|
+
};
|
|
50
|
+
const getInstruction = (identifiers) => {
|
|
51
|
+
const sin = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree).sin;
|
|
52
|
+
return `Résoudre :
|
|
53
|
+
|
|
54
|
+
$$
|
|
55
|
+
${new sinNode_1.SinNode("x".toTree()).toTex()}=${sin.toTex()}
|
|
56
|
+
$$
|
|
57
|
+
|
|
58
|
+
Donner les solutions dans l'intervalle $\\left]-\\pi,\\pi\\right]$.
|
|
59
|
+
`;
|
|
60
|
+
};
|
|
61
|
+
// const getHint: GetHint<Identifiers> = (identifiers) => {
|
|
62
|
+
// return "";
|
|
63
|
+
// };
|
|
64
|
+
// const getCorrection: GetCorrection<Identifiers> = (identifiers) => {
|
|
65
|
+
// return "";
|
|
66
|
+
// };
|
|
67
|
+
const getKeys = (identifiers) => {
|
|
68
|
+
return ["x", "S", "equal", "lbrace", "semicolon", "rbrace", "pi"];
|
|
69
|
+
};
|
|
70
|
+
const isAnswerValid = (ans, { answer, degree }) => {
|
|
71
|
+
const answerNode = getAnswerNode({ degree });
|
|
72
|
+
return answerNode.toAllValidTexs().includes(ans);
|
|
73
|
+
};
|
|
74
|
+
const getBasicEquationSinQuestion = () => {
|
|
75
|
+
const mainSinusValues = remarkableValues_1.mainTrigoValues.slice(3, 12);
|
|
76
|
+
const value = (0, random_1.random)(mainSinusValues);
|
|
77
|
+
const degree = value.degree;
|
|
78
|
+
const identifiers = { degree };
|
|
79
|
+
const question = {
|
|
80
|
+
answer: getAnswer(identifiers),
|
|
81
|
+
instruction: getInstruction(identifiers),
|
|
82
|
+
keys: getKeys(identifiers),
|
|
83
|
+
answerFormat: "tex",
|
|
84
|
+
identifiers,
|
|
85
|
+
// hint: getHint(identifiers),
|
|
86
|
+
// correction: getCorrection(identifiers),
|
|
87
|
+
};
|
|
88
|
+
return question;
|
|
89
|
+
};
|
|
90
|
+
exports.basicEquationSin = {
|
|
91
|
+
id: "basicEquationSin",
|
|
92
|
+
connector: "\\iff",
|
|
93
|
+
label: "Résoudre une équation du type $\\sin\\left(x\\right)=k$",
|
|
94
|
+
isSingleStep: true,
|
|
95
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getBasicEquationSinQuestion, nb, 9),
|
|
96
|
+
qcmTimer: 60,
|
|
97
|
+
freeTimer: 60,
|
|
98
|
+
ggbTimer: 60,
|
|
99
|
+
getPropositions,
|
|
100
|
+
isAnswerValid,
|
|
101
|
+
subject: "Mathématiques",
|
|
102
|
+
// getHint,
|
|
103
|
+
// getCorrection,
|
|
104
|
+
getAnswer,
|
|
105
|
+
maxAllowedQuestions: 9,
|
|
106
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"basicTrigoSystemEquation.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/basicTrigoSystemEquation.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAUlC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AA0EF,eAAO,MAAM,wBAAwB,EAAE,QAAQ,CAAC,WAAW,CAkB1D,CAAC"}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.basicTrigoSystemEquation = void 0;
|
|
4
|
+
const exercise_1 = require("../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const remarkableValues_1 = require("../../../math/trigonometry/remarkableValues");
|
|
7
|
+
const equationSolutionNode_1 = require("../../../tree/nodes/equations/equationSolutionNode");
|
|
8
|
+
const cosNode_1 = require("../../../tree/nodes/functions/cosNode");
|
|
9
|
+
const sinNode_1 = require("../../../tree/nodes/functions/sinNode");
|
|
10
|
+
const discreteSetNode_1 = require("../../../tree/nodes/sets/discreteSetNode");
|
|
11
|
+
const alignTex_1 = require("../../../utils/latex/alignTex");
|
|
12
|
+
const random_1 = require("../../../utils/alea/random");
|
|
13
|
+
const getPropositions = (n, { answer }) => {
|
|
14
|
+
const propositions = [];
|
|
15
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
16
|
+
while (propositions.length < n) {
|
|
17
|
+
const value = (0, random_1.random)(remarkableValues_1.mainTrigoValues);
|
|
18
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([value.angle])).toTex());
|
|
19
|
+
}
|
|
20
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
21
|
+
};
|
|
22
|
+
const getAnswerNode = (identifiers) => {
|
|
23
|
+
const value = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree);
|
|
24
|
+
return new equationSolutionNode_1.EquationSolutionNode(new discreteSetNode_1.DiscreteSetNode([value.angle]));
|
|
25
|
+
};
|
|
26
|
+
const getAnswer = (identifiers) => {
|
|
27
|
+
return getAnswerNode(identifiers).toTex();
|
|
28
|
+
};
|
|
29
|
+
const getInstruction = (identifiers) => {
|
|
30
|
+
const value = remarkableValues_1.mainTrigoValues.find((v) => v.degree === identifiers.degree);
|
|
31
|
+
return `Résoudre :
|
|
32
|
+
|
|
33
|
+
$$
|
|
34
|
+
\\left\\{${(0, alignTex_1.alignTex)([
|
|
35
|
+
[`${new cosNode_1.CosNode("x".toTree()).toTex()}=${value.cos.toTex()}`],
|
|
36
|
+
[`${new sinNode_1.SinNode("x".toTree()).toTex()}=${value.sin.toTex()}`],
|
|
37
|
+
], true)}\\right.
|
|
38
|
+
$$
|
|
39
|
+
|
|
40
|
+
Donner les solutions dans l'intervalle $\\left]-\\pi,\\pi\\right]$.
|
|
41
|
+
`;
|
|
42
|
+
};
|
|
43
|
+
// const getHint: GetHint<Identifiers> = (identifiers) => {};
|
|
44
|
+
// const getCorrection: GetCorrection<Identifiers> = (identifiers) => {};
|
|
45
|
+
const getKeys = (identifiers) => {
|
|
46
|
+
return ["x", "S", "equal", "lbrace", "semicolon", "rbrace", "pi"];
|
|
47
|
+
};
|
|
48
|
+
const isAnswerValid = (ans, { answer, degree }) => {
|
|
49
|
+
const node = getAnswerNode({ degree });
|
|
50
|
+
return node.toAllValidTexs().includes(ans);
|
|
51
|
+
};
|
|
52
|
+
const getBasicTrigoSystemEquationQuestion = () => {
|
|
53
|
+
const value = (0, random_1.random)(remarkableValues_1.mainTrigoValues);
|
|
54
|
+
const degree = value.degree;
|
|
55
|
+
const identifiers = {
|
|
56
|
+
degree,
|
|
57
|
+
};
|
|
58
|
+
const question = {
|
|
59
|
+
answer: getAnswer(identifiers),
|
|
60
|
+
instruction: getInstruction(identifiers),
|
|
61
|
+
keys: getKeys(identifiers),
|
|
62
|
+
answerFormat: "tex",
|
|
63
|
+
identifiers,
|
|
64
|
+
// hint: getHint(identifiers),
|
|
65
|
+
// correction: getCorrection(identifiers),
|
|
66
|
+
};
|
|
67
|
+
return question;
|
|
68
|
+
};
|
|
69
|
+
exports.basicTrigoSystemEquation = {
|
|
70
|
+
id: "basicTrigoSystemEquation",
|
|
71
|
+
connector: "\\iff",
|
|
72
|
+
label: "Résoudre un système du type $\\left\\{\\begin{matrix}\\cos(x)=a\\\\ \\sin(x)=b\\end{matrix}\\right.$",
|
|
73
|
+
isSingleStep: true,
|
|
74
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getBasicTrigoSystemEquationQuestion, nb, 15),
|
|
75
|
+
qcmTimer: 60,
|
|
76
|
+
freeTimer: 60,
|
|
77
|
+
ggbTimer: 60,
|
|
78
|
+
getPropositions,
|
|
79
|
+
isAnswerValid,
|
|
80
|
+
subject: "Mathématiques",
|
|
81
|
+
// getHint,
|
|
82
|
+
// getCorrection,
|
|
83
|
+
getAnswer,
|
|
84
|
+
maxAllowedQuestions: 15,
|
|
85
|
+
};
|
|
@@ -9,7 +9,7 @@ const cosNode_1 = require("../../../tree/nodes/functions/cosNode");
|
|
|
9
9
|
const sinNode_1 = require("../../../tree/nodes/functions/sinNode");
|
|
10
10
|
const tanNode_1 = require("../../../tree/nodes/functions/tanNode");
|
|
11
11
|
const degree_1 = require("../../../tree/nodes/geometry/degree");
|
|
12
|
-
const random_1 = require("../../../utils/random");
|
|
12
|
+
const random_1 = require("../../../utils/alea/random");
|
|
13
13
|
const trigo = ["sin", "tan", "cos"];
|
|
14
14
|
const getCalculateCosSinAndTanQuestion = () => {
|
|
15
15
|
const trigoFunct = (0, random_1.random)(trigo);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Exercise } from "../../../exercises/exercise";
|
|
2
|
+
type Identifiers = {
|
|
3
|
+
degree: number;
|
|
4
|
+
radianNodeIds: any;
|
|
5
|
+
isDegreeToRadian: boolean;
|
|
6
|
+
};
|
|
7
|
+
export declare const degreeToRadians: Exercise<Identifiers>;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=degreeToRadians.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"degreeToRadians.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/degreeToRadians.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAclC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,GAAG,CAAC;IACnB,gBAAgB,EAAE,OAAO,CAAC;CAC3B,CAAC;AAgIF,eAAO,MAAM,eAAe,EAAE,QAAQ,CAAC,WAAW,CAgBjD,CAAC"}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.degreeToRadians = void 0;
|
|
4
|
+
const exercise_1 = require("../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const remarkableValues_1 = require("../../../math/trigonometry/remarkableValues");
|
|
7
|
+
const randint_1 = require("../../../math/utils/random/randint");
|
|
8
|
+
const degree_1 = require("../../../tree/nodes/geometry/degree");
|
|
9
|
+
const nodeConstructor_1 = require("../../../tree/nodes/nodeConstructor");
|
|
10
|
+
const piNode_1 = require("../../../tree/nodes/numbers/piNode");
|
|
11
|
+
const fractionNode_1 = require("../../../tree/nodes/operators/fractionNode");
|
|
12
|
+
const multiplyNode_1 = require("../../../tree/nodes/operators/multiplyNode");
|
|
13
|
+
const coinFlip_1 = require("../../../utils/alea/coinFlip");
|
|
14
|
+
const random_1 = require("../../../utils/alea/random");
|
|
15
|
+
const getPropositions = (n, { answer, isDegreeToRadian }) => {
|
|
16
|
+
const propositions = [];
|
|
17
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
18
|
+
while (propositions.length < n) {
|
|
19
|
+
if (isDegreeToRadian) {
|
|
20
|
+
const degree = (0, randint_1.randint)(1, 360);
|
|
21
|
+
const radianNode = new fractionNode_1.FractionNode(new multiplyNode_1.MultiplyNode(degree.toTree(), piNode_1.PiNode), (180).toTree()).simplify();
|
|
22
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, radianNode.toTex());
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new degree_1.DegreeNode((0, randint_1.randint)(1, 360)).toTex());
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
29
|
+
};
|
|
30
|
+
const getAnswer = ({ degree, isDegreeToRadian, radianNodeIds, }) => {
|
|
31
|
+
if (isDegreeToRadian) {
|
|
32
|
+
return nodeConstructor_1.NodeConstructor.fromIdentifiers(radianNodeIds).toTex();
|
|
33
|
+
}
|
|
34
|
+
else {
|
|
35
|
+
return new degree_1.DegreeNode(degree).toTex();
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
const getInstruction = ({ degree, isDegreeToRadian, radianNodeIds, }) => {
|
|
39
|
+
return isDegreeToRadian
|
|
40
|
+
? `Convertir en radians :
|
|
41
|
+
|
|
42
|
+
$$
|
|
43
|
+
${new degree_1.DegreeNode(degree).toTex()}
|
|
44
|
+
$$
|
|
45
|
+
`
|
|
46
|
+
: `Convertir en degrés :
|
|
47
|
+
|
|
48
|
+
$$
|
|
49
|
+
${nodeConstructor_1.NodeConstructor.fromIdentifiers(radianNodeIds).toTex()}
|
|
50
|
+
$$
|
|
51
|
+
`;
|
|
52
|
+
};
|
|
53
|
+
// const getHint : GetHint<Identifiers> = (identifiers)=>{
|
|
54
|
+
// }
|
|
55
|
+
// const getCorrection : GetCorrection<Identifiers> = (identifiers)=>{
|
|
56
|
+
// }
|
|
57
|
+
const getKeys = (identifiers) => {
|
|
58
|
+
return ["pi", "degree"];
|
|
59
|
+
};
|
|
60
|
+
const isAnswerValid = (ans, { answer, degree, isDegreeToRadian, radianNodeIds }) => {
|
|
61
|
+
if (isDegreeToRadian) {
|
|
62
|
+
return nodeConstructor_1.NodeConstructor.fromIdentifiers(radianNodeIds)
|
|
63
|
+
.toAllValidTexs()
|
|
64
|
+
.includes(ans);
|
|
65
|
+
}
|
|
66
|
+
else {
|
|
67
|
+
return new degree_1.DegreeNode(degree).toAllValidTexs().includes(ans);
|
|
68
|
+
}
|
|
69
|
+
};
|
|
70
|
+
const getIdentifiers = (prevIds) => {
|
|
71
|
+
const isRemakableValue = (0, coinFlip_1.coinFlip)();
|
|
72
|
+
const isDegreeToRadian = (0, coinFlip_1.coinFlip)();
|
|
73
|
+
let degree;
|
|
74
|
+
let radianNode;
|
|
75
|
+
if (isRemakableValue) {
|
|
76
|
+
const value = (0, random_1.random)(remarkableValues_1.remarkableTrigoValues);
|
|
77
|
+
degree = value.degree;
|
|
78
|
+
radianNode = value.angle;
|
|
79
|
+
}
|
|
80
|
+
else {
|
|
81
|
+
// if(isDegreeToRadian){
|
|
82
|
+
degree = (0, randint_1.randint)(1, 360, [
|
|
83
|
+
0, 30, 45, 60, 90, 120, 135, 150, 180, 210, 240, 255, 270, 300, 315,
|
|
84
|
+
330, 360,
|
|
85
|
+
]);
|
|
86
|
+
radianNode = new fractionNode_1.FractionNode(new multiplyNode_1.MultiplyNode(degree.toTree(), piNode_1.PiNode), (180).toTree()).simplify();
|
|
87
|
+
// }else {
|
|
88
|
+
// radianNode =
|
|
89
|
+
// }
|
|
90
|
+
}
|
|
91
|
+
return {
|
|
92
|
+
degree,
|
|
93
|
+
radianNodeIds: radianNode.toIdentifiers(),
|
|
94
|
+
isDegreeToRadian,
|
|
95
|
+
};
|
|
96
|
+
};
|
|
97
|
+
const getDegreeToRadiansQuestion = () => {
|
|
98
|
+
const identifiers = getIdentifiers();
|
|
99
|
+
const question = {
|
|
100
|
+
answer: getAnswer(identifiers),
|
|
101
|
+
instruction: getInstruction(identifiers),
|
|
102
|
+
keys: getKeys(identifiers),
|
|
103
|
+
answerFormat: "tex",
|
|
104
|
+
identifiers,
|
|
105
|
+
// hint: getHint(identifiers),
|
|
106
|
+
// correction: getCorrection(identifiers)
|
|
107
|
+
};
|
|
108
|
+
return question;
|
|
109
|
+
};
|
|
110
|
+
exports.degreeToRadians = {
|
|
111
|
+
id: "degreeToRadians",
|
|
112
|
+
connector: "=",
|
|
113
|
+
label: "Convertir des degrés en radians et vice-versa",
|
|
114
|
+
isSingleStep: true,
|
|
115
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getDegreeToRadiansQuestion, nb),
|
|
116
|
+
qcmTimer: 60,
|
|
117
|
+
freeTimer: 60,
|
|
118
|
+
ggbTimer: 60,
|
|
119
|
+
getPropositions,
|
|
120
|
+
isAnswerValid,
|
|
121
|
+
subject: "Mathématiques",
|
|
122
|
+
// getHint,
|
|
123
|
+
// getCorrection,
|
|
124
|
+
getAnswer,
|
|
125
|
+
};
|
|
@@ -6,4 +6,10 @@ export * from "./trigonometrySideCalcul";
|
|
|
6
6
|
export * from "./associatePoint";
|
|
7
7
|
export * from "./arcValue";
|
|
8
8
|
export * from "./calculateCosSinAndTan";
|
|
9
|
+
export * from "./basicEquationCos";
|
|
10
|
+
export * from "./basicEquationSin";
|
|
11
|
+
export * from "./basicTrigoSystemEquation";
|
|
12
|
+
export * from "./mainAngleMeasure";
|
|
13
|
+
export * from "./degreeToRadians";
|
|
14
|
+
export * from "./arcLength";
|
|
9
15
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -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"}
|
|
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"}
|
|
@@ -22,3 +22,9 @@ __exportStar(require("./trigonometrySideCalcul"), exports);
|
|
|
22
22
|
__exportStar(require("./associatePoint"), exports);
|
|
23
23
|
__exportStar(require("./arcValue"), exports);
|
|
24
24
|
__exportStar(require("./calculateCosSinAndTan"), exports);
|
|
25
|
+
__exportStar(require("./basicEquationCos"), exports);
|
|
26
|
+
__exportStar(require("./basicEquationSin"), exports);
|
|
27
|
+
__exportStar(require("./basicTrigoSystemEquation"), exports);
|
|
28
|
+
__exportStar(require("./mainAngleMeasure"), exports);
|
|
29
|
+
__exportStar(require("./degreeToRadians"), exports);
|
|
30
|
+
__exportStar(require("./arcLength"), exports);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Exercise } from "../../../exercises/exercise";
|
|
2
|
+
type Identifiers = {
|
|
3
|
+
degree: number;
|
|
4
|
+
multipleOf2PiToAdd: number;
|
|
5
|
+
nodeIds: any;
|
|
6
|
+
};
|
|
7
|
+
export declare const mainAngleMeasure: Exercise<Identifiers>;
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=mainAngleMeasure.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mainAngleMeasure.d.ts","sourceRoot":"","sources":["../../../../src/exercises/math/trigonometry/mainAngleMeasure.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAclC,KAAK,WAAW,GAAG;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,kBAAkB,EAAE,MAAM,CAAC;IAC3B,OAAO,EAAE,GAAG,CAAC;CACd,CAAC;AAmFF,eAAO,MAAM,gBAAgB,EAAE,QAAQ,CAAC,WAAW,CAgBlD,CAAC"}
|