math-exercises 2.2.27 → 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/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.js +1 -1
- 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 +12 -0
- package/lib/exercises/math/geometry/cartesian/readAbscissOnLine.d.ts.map +1 -1
- package/lib/exercises/math/geometry/cartesian/readAbscissOnLine.js +151 -91
- 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.js +2 -2
- 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/integer/integer.js +1 -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 -31
- 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/package.json +1 -1
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.placeAbscissOnLine = void 0;
|
|
4
|
+
const toolBarConstructor_1 = require("../../../../exercises/utils/geogebra/toolBarConstructor");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const geogebraConstructor_1 = require("../../../../geogebra/geogebraConstructor");
|
|
7
|
+
const ggbPointToCoords_1 = require("../../../../geogebra/parsers/ggbPointToCoords");
|
|
8
|
+
const parseGGBPoints_1 = require("../../../../geogebra/parsers/parseGGBPoints");
|
|
9
|
+
const point_1 = require("../../../../math/geometry/point");
|
|
10
|
+
const nombre_1 = require("../../../../math/numbers/nombre");
|
|
11
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
12
|
+
const randint_1 = require("../../../../math/utils/random/randint");
|
|
13
|
+
const round_1 = require("../../../../math/utils/round");
|
|
14
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
15
|
+
const multiplyNode_1 = require("../../../../tree/nodes/operators/multiplyNode");
|
|
16
|
+
const random_1 = require("../../../../utils/alea/random");
|
|
17
|
+
const getInstruction = ({ abscissTex }) => {
|
|
18
|
+
return `Placer le point d'abscisse $${abscissTex}$ sur la droite graduée ci-dessous :`;
|
|
19
|
+
};
|
|
20
|
+
// const getHint: GetHint<Identifiers> = (identifiers) => {};
|
|
21
|
+
// const getCorrection: GetCorrection<Identifiers> = (identifiers) => {};
|
|
22
|
+
const getGGBAnswer = ({ absciss, coeff }) => {
|
|
23
|
+
return [`(${coeff},0)`];
|
|
24
|
+
};
|
|
25
|
+
const getStudentGGBOptions = ({ coeff, oneUnitTex, abscissType, }) => {
|
|
26
|
+
const O = new point_1.Point("O", (0).toTree(), (0).toTree());
|
|
27
|
+
const I = new point_1.Point("I", (1).toTree(), (0).toTree());
|
|
28
|
+
const A = new point_1.Point("A", coeff.toTree(), (0).toTree());
|
|
29
|
+
const commands = [
|
|
30
|
+
...O.toGGBCommand(),
|
|
31
|
+
`Text("\\small 0", (0, -0.5), false, true, 0, 0)`,
|
|
32
|
+
...I.toGGBCommand(),
|
|
33
|
+
`Text("\\small ${oneUnitTex}", (1, ${abscissType === nombre_1.NumberType.Rational ? -1 : -0.5}), false, true, 0, 0)`,
|
|
34
|
+
];
|
|
35
|
+
const ggb = new geogebraConstructor_1.GeogebraConstructor({
|
|
36
|
+
commands,
|
|
37
|
+
customToolBar: (0, toolBarConstructor_1.toolBarConstructor)({
|
|
38
|
+
point: true,
|
|
39
|
+
}),
|
|
40
|
+
hideGrid: true,
|
|
41
|
+
xAxis: {
|
|
42
|
+
hideNumbers: true,
|
|
43
|
+
steps: 1,
|
|
44
|
+
},
|
|
45
|
+
yAxis: {
|
|
46
|
+
hidden: true,
|
|
47
|
+
},
|
|
48
|
+
forbidShiftDragZoom: true,
|
|
49
|
+
});
|
|
50
|
+
return ggb.getOptions({
|
|
51
|
+
coords: [-7, 7, -2, 2],
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
const isGGBAnswerValid = (ans, { ggbAnswer, absciss, abscissTex, abscissType, axisUnit, coeff, oneUnitTex }) => {
|
|
55
|
+
const points = (0, parseGGBPoints_1.parseGGBPoints)(ans).map((p) => (0, ggbPointToCoords_1.ggbPointToCoords)(p));
|
|
56
|
+
return points.some((point) => point.y === 0 && Math.abs(point.x - coeff) < 0.1);
|
|
57
|
+
return false;
|
|
58
|
+
};
|
|
59
|
+
const getPlaceAbscissOnLineQuestion = () => {
|
|
60
|
+
const abscissType = (0, random_1.random)([
|
|
61
|
+
nombre_1.NumberType.Integer,
|
|
62
|
+
nombre_1.NumberType.Rational,
|
|
63
|
+
nombre_1.NumberType.Decimal,
|
|
64
|
+
]);
|
|
65
|
+
let absciss, axisUnit, oneUnitTex, abscissTex, coeff;
|
|
66
|
+
switch (abscissType) {
|
|
67
|
+
case nombre_1.NumberType.Integer:
|
|
68
|
+
axisUnit = (0, randint_1.randint)(1, 10);
|
|
69
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
70
|
+
absciss = axisUnit * coeff;
|
|
71
|
+
oneUnitTex = axisUnit.frenchify();
|
|
72
|
+
abscissTex = absciss.frenchify();
|
|
73
|
+
break;
|
|
74
|
+
case nombre_1.NumberType.Rational:
|
|
75
|
+
const randomFrac = (0, random_1.random)([
|
|
76
|
+
[1, 2],
|
|
77
|
+
[1, 3],
|
|
78
|
+
[2, 3],
|
|
79
|
+
[1, 4],
|
|
80
|
+
[3, 4],
|
|
81
|
+
[1, 5],
|
|
82
|
+
[2, 5],
|
|
83
|
+
[3, 5],
|
|
84
|
+
[4, 5],
|
|
85
|
+
]);
|
|
86
|
+
axisUnit = randomFrac[0] / randomFrac[1];
|
|
87
|
+
const oneUnit = new fractionNode_1.FractionNode(randomFrac[0].toTree(), randomFrac[1].toTree());
|
|
88
|
+
oneUnitTex = oneUnit.toTex();
|
|
89
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
90
|
+
absciss = axisUnit * coeff;
|
|
91
|
+
abscissTex = new multiplyNode_1.MultiplyNode(oneUnit, coeff.toTree()).simplify().toTex();
|
|
92
|
+
break;
|
|
93
|
+
case nombre_1.NumberType.Decimal:
|
|
94
|
+
default:
|
|
95
|
+
axisUnit = (0, randfloat_1.randfloat)(0, 5, 1);
|
|
96
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
97
|
+
absciss = (0, round_1.round)(axisUnit * coeff, 2);
|
|
98
|
+
oneUnitTex = axisUnit.frenchify();
|
|
99
|
+
abscissTex = absciss.frenchify();
|
|
100
|
+
break;
|
|
101
|
+
}
|
|
102
|
+
const identifiers = {
|
|
103
|
+
absciss,
|
|
104
|
+
abscissTex,
|
|
105
|
+
abscissType,
|
|
106
|
+
axisUnit,
|
|
107
|
+
coeff,
|
|
108
|
+
oneUnitTex,
|
|
109
|
+
};
|
|
110
|
+
const question = {
|
|
111
|
+
ggbAnswer: getGGBAnswer(identifiers),
|
|
112
|
+
instruction: getInstruction(identifiers),
|
|
113
|
+
studentGgbOptions: getStudentGGBOptions(identifiers),
|
|
114
|
+
identifiers,
|
|
115
|
+
// hint: getHint(identifiers),
|
|
116
|
+
// correction: getCorrection(identifiers),
|
|
117
|
+
};
|
|
118
|
+
return question;
|
|
119
|
+
};
|
|
120
|
+
exports.placeAbscissOnLine = {
|
|
121
|
+
id: "placeAbscissOnLine",
|
|
122
|
+
label: "Placer un point d'abscisse donnée sur une droite graduée",
|
|
123
|
+
isSingleStep: true,
|
|
124
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getPlaceAbscissOnLineQuestion, nb),
|
|
125
|
+
ggbTimer: 60,
|
|
126
|
+
isGGBAnswerValid,
|
|
127
|
+
subject: "Mathématiques",
|
|
128
|
+
// getHint,
|
|
129
|
+
// getCorrection,
|
|
130
|
+
getGGBAnswer,
|
|
131
|
+
getStudentGGBOptions,
|
|
132
|
+
answerType: "GGB",
|
|
133
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise";
|
|
2
|
+
import { NumberType } from "../../../../math/numbers/nombre";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
abscissType: NumberType;
|
|
5
|
+
axisUnit: number;
|
|
6
|
+
oneUnitTex: string;
|
|
7
|
+
absciss: number;
|
|
8
|
+
abscissTex: string;
|
|
9
|
+
coeff: number;
|
|
10
|
+
};
|
|
11
|
+
export declare const placeAbscissOnSemiLine: Exercise<Identifiers>;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=placeAbscissOnSemiLine.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"placeAbscissOnSemiLine.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/cartesian/placeAbscissOnSemiLine.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAST,MAAM,0BAA0B,CAAC;AAOlC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAQvD,KAAK,WAAW,GAAG;IACjB,WAAW,EAAE,UAAU,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAoIF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,WAAW,CAcxD,CAAC"}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.placeAbscissOnSemiLine = void 0;
|
|
4
|
+
const toolBarConstructor_1 = require("../../../../exercises/utils/geogebra/toolBarConstructor");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const geogebraConstructor_1 = require("../../../../geogebra/geogebraConstructor");
|
|
7
|
+
const ggbPointToCoords_1 = require("../../../../geogebra/parsers/ggbPointToCoords");
|
|
8
|
+
const parseGGBPoints_1 = require("../../../../geogebra/parsers/parseGGBPoints");
|
|
9
|
+
const point_1 = require("../../../../math/geometry/point");
|
|
10
|
+
const nombre_1 = require("../../../../math/numbers/nombre");
|
|
11
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
12
|
+
const randint_1 = require("../../../../math/utils/random/randint");
|
|
13
|
+
const round_1 = require("../../../../math/utils/round");
|
|
14
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
15
|
+
const multiplyNode_1 = require("../../../../tree/nodes/operators/multiplyNode");
|
|
16
|
+
const random_1 = require("../../../../utils/alea/random");
|
|
17
|
+
const getInstruction = ({ abscissTex }) => {
|
|
18
|
+
return `Placer le point d'abscisse $${abscissTex}$ sur la droite graduée ci-dessous :`;
|
|
19
|
+
};
|
|
20
|
+
// const getHint: GetHint<Identifiers> = (identifiers) => {};
|
|
21
|
+
// const getCorrection: GetCorrection<Identifiers> = (identifiers) => {};
|
|
22
|
+
const getGGBAnswer = ({ absciss, coeff }) => {
|
|
23
|
+
return [`(${coeff},0)`];
|
|
24
|
+
};
|
|
25
|
+
const getStudentGGBOptions = ({ coeff, oneUnitTex, abscissType, }) => {
|
|
26
|
+
const O = new point_1.Point("O", (0).toTree(), (0).toTree());
|
|
27
|
+
const I = new point_1.Point("I", (1).toTree(), (0).toTree());
|
|
28
|
+
const commands = [
|
|
29
|
+
...O.toGGBCommand(),
|
|
30
|
+
`Text("\\small 0", (0, -0.5), false, true, 0, 0)`,
|
|
31
|
+
...I.toGGBCommand(),
|
|
32
|
+
`Text("\\small ${oneUnitTex}", (1, ${abscissType === nombre_1.NumberType.Rational ? -1 : -0.5}), false, true, 0, 0)`,
|
|
33
|
+
];
|
|
34
|
+
const ggb = new geogebraConstructor_1.GeogebraConstructor({
|
|
35
|
+
commands,
|
|
36
|
+
customToolBar: (0, toolBarConstructor_1.toolBarConstructor)({
|
|
37
|
+
point: true,
|
|
38
|
+
}),
|
|
39
|
+
hideGrid: true,
|
|
40
|
+
xAxis: {
|
|
41
|
+
hideNumbers: true,
|
|
42
|
+
steps: 1,
|
|
43
|
+
showPositive: true,
|
|
44
|
+
},
|
|
45
|
+
yAxis: {
|
|
46
|
+
hidden: true,
|
|
47
|
+
},
|
|
48
|
+
forbidShiftDragZoom: true,
|
|
49
|
+
});
|
|
50
|
+
return ggb.getOptions({
|
|
51
|
+
coords: [-1, 10, -2, 2],
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
const isGGBAnswerValid = (ans, { ggbAnswer, absciss, abscissTex, abscissType, axisUnit, coeff, oneUnitTex }) => {
|
|
55
|
+
const points = (0, parseGGBPoints_1.parseGGBPoints)(ans).map((p) => (0, ggbPointToCoords_1.ggbPointToCoords)(p));
|
|
56
|
+
return points.some((point) => point.y === 0 && Math.abs(point.x - coeff) < 0.1);
|
|
57
|
+
};
|
|
58
|
+
const getPlaceAbscissOnSemiLineQuestion = () => {
|
|
59
|
+
const abscissType = (0, random_1.random)([
|
|
60
|
+
nombre_1.NumberType.Integer,
|
|
61
|
+
nombre_1.NumberType.Rational,
|
|
62
|
+
nombre_1.NumberType.Decimal,
|
|
63
|
+
]);
|
|
64
|
+
let absciss, axisUnit, oneUnitTex, abscissTex, coeff;
|
|
65
|
+
switch (abscissType) {
|
|
66
|
+
case nombre_1.NumberType.Integer:
|
|
67
|
+
axisUnit = (0, randint_1.randint)(1, 10);
|
|
68
|
+
coeff = (0, randint_1.randint)(2, 10);
|
|
69
|
+
absciss = axisUnit * coeff;
|
|
70
|
+
oneUnitTex = axisUnit.frenchify();
|
|
71
|
+
abscissTex = absciss.frenchify();
|
|
72
|
+
break;
|
|
73
|
+
case nombre_1.NumberType.Rational:
|
|
74
|
+
const randomFrac = (0, random_1.random)([
|
|
75
|
+
[1, 2],
|
|
76
|
+
[1, 3],
|
|
77
|
+
[2, 3],
|
|
78
|
+
[1, 4],
|
|
79
|
+
[3, 4],
|
|
80
|
+
[1, 5],
|
|
81
|
+
[2, 5],
|
|
82
|
+
[3, 5],
|
|
83
|
+
[4, 5],
|
|
84
|
+
]);
|
|
85
|
+
axisUnit = randomFrac[0] / randomFrac[1];
|
|
86
|
+
const oneUnit = new fractionNode_1.FractionNode(randomFrac[0].toTree(), randomFrac[1].toTree());
|
|
87
|
+
oneUnitTex = oneUnit.toTex();
|
|
88
|
+
coeff = (0, randint_1.randint)(2, 10);
|
|
89
|
+
absciss = axisUnit * coeff;
|
|
90
|
+
abscissTex = new multiplyNode_1.MultiplyNode(oneUnit, coeff.toTree()).simplify().toTex();
|
|
91
|
+
break;
|
|
92
|
+
case nombre_1.NumberType.Decimal:
|
|
93
|
+
default:
|
|
94
|
+
axisUnit = (0, randfloat_1.randfloat)(0, 5, 1);
|
|
95
|
+
coeff = (0, randint_1.randint)(2, 10);
|
|
96
|
+
absciss = (0, round_1.round)(axisUnit * coeff, 2);
|
|
97
|
+
oneUnitTex = axisUnit.frenchify();
|
|
98
|
+
abscissTex = absciss.frenchify();
|
|
99
|
+
break;
|
|
100
|
+
}
|
|
101
|
+
const identifiers = {
|
|
102
|
+
absciss,
|
|
103
|
+
abscissTex,
|
|
104
|
+
abscissType,
|
|
105
|
+
axisUnit,
|
|
106
|
+
coeff,
|
|
107
|
+
oneUnitTex,
|
|
108
|
+
};
|
|
109
|
+
const question = {
|
|
110
|
+
ggbAnswer: getGGBAnswer(identifiers),
|
|
111
|
+
instruction: getInstruction(identifiers),
|
|
112
|
+
studentGgbOptions: getStudentGGBOptions(identifiers),
|
|
113
|
+
identifiers,
|
|
114
|
+
// hint: getHint(identifiers),
|
|
115
|
+
// correction: getCorrection(identifiers),
|
|
116
|
+
};
|
|
117
|
+
return question;
|
|
118
|
+
};
|
|
119
|
+
exports.placeAbscissOnSemiLine = {
|
|
120
|
+
id: "placeAbscissOnSemiLine",
|
|
121
|
+
label: "Placer un point d'abscisse donnée sur une demi-droite graduée",
|
|
122
|
+
isSingleStep: true,
|
|
123
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getPlaceAbscissOnSemiLineQuestion, nb),
|
|
124
|
+
ggbTimer: 60,
|
|
125
|
+
isGGBAnswerValid,
|
|
126
|
+
subject: "Mathématiques",
|
|
127
|
+
// getHint,
|
|
128
|
+
// getCorrection,
|
|
129
|
+
getGGBAnswer,
|
|
130
|
+
getStudentGGBOptions,
|
|
131
|
+
answerType: "GGB",
|
|
132
|
+
};
|
|
@@ -6,7 +6,7 @@ const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQ
|
|
|
6
6
|
const geogebraConstructor_1 = require("../../../../geogebra/geogebraConstructor");
|
|
7
7
|
const point_1 = require("../../../../math/geometry/point");
|
|
8
8
|
const randint_1 = require("../../../../math/utils/random/randint");
|
|
9
|
-
const random_1 = require("../../../../utils/random");
|
|
9
|
+
const random_1 = require("../../../../utils/alea/random");
|
|
10
10
|
const getPointCoordinatesNoAxisNumbersQuestion = () => {
|
|
11
11
|
const x = (0, randint_1.randint)(-10, 10);
|
|
12
12
|
const y = (0, randint_1.randint)(-10, 10);
|
|
@@ -1 +1,13 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise";
|
|
2
|
+
import { NumberType } from "../../../../math/numbers/nombre";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
abscissType: NumberType;
|
|
5
|
+
axisUnit: number;
|
|
6
|
+
oneUnitTex: string;
|
|
7
|
+
absciss: number;
|
|
8
|
+
abscissTex: string;
|
|
9
|
+
coeff: number;
|
|
10
|
+
};
|
|
11
|
+
export declare const readAbscissOnLine: Exercise<Identifiers>;
|
|
12
|
+
export {};
|
|
1
13
|
//# sourceMappingURL=readAbscissOnLine.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"readAbscissOnLine.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/cartesian/readAbscissOnLine.ts"],"names":[],"mappings":""}
|
|
1
|
+
{"version":3,"file":"readAbscissOnLine.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/cartesian/readAbscissOnLine.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAIlC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAUvD,KAAK,WAAW,GAAG;IACjB,WAAW,EAAE,UAAU,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AA2JF,eAAO,MAAM,iBAAiB,EAAE,QAAQ,CAAC,WAAW,CAgBnD,CAAC"}
|
|
@@ -1,92 +1,152 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.readAbscissOnLine = void 0;
|
|
4
|
+
const exercise_1 = require("../../../../exercises/exercise");
|
|
5
|
+
const getDistinctQuestions_1 = require("../../../../exercises/utils/getDistinctQuestions");
|
|
6
|
+
const geogebraConstructor_1 = require("../../../../geogebra/geogebraConstructor");
|
|
7
|
+
const point_1 = require("../../../../math/geometry/point");
|
|
8
|
+
const nombre_1 = require("../../../../math/numbers/nombre");
|
|
9
|
+
const randfloat_1 = require("../../../../math/utils/random/randfloat");
|
|
10
|
+
const randint_1 = require("../../../../math/utils/random/randint");
|
|
11
|
+
const round_1 = require("../../../../math/utils/round");
|
|
12
|
+
const fractionNode_1 = require("../../../../tree/nodes/operators/fractionNode");
|
|
13
|
+
const multiplyNode_1 = require("../../../../tree/nodes/operators/multiplyNode");
|
|
14
|
+
const latexParser_1 = require("../../../../tree/parsers/latexParser");
|
|
15
|
+
const random_1 = require("../../../../utils/alea/random");
|
|
16
|
+
const getPropositions = (n, { answer, absciss, abscissTex, abscissType, axisUnit, oneUnitTex }) => {
|
|
17
|
+
const propositions = [];
|
|
18
|
+
(0, exercise_1.addValidProp)(propositions, answer);
|
|
19
|
+
const unitNode = (0, latexParser_1.parseLatex)(oneUnitTex);
|
|
20
|
+
while (propositions.length < n) {
|
|
21
|
+
const coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
22
|
+
(0, exercise_1.tryToAddWrongProp)(propositions, new multiplyNode_1.MultiplyNode(unitNode, coeff.toTree()).simplify().toTex());
|
|
23
|
+
}
|
|
24
|
+
return (0, exercise_1.shuffleProps)(propositions, n);
|
|
25
|
+
};
|
|
26
|
+
const getAnswer = ({ absciss, abscissType, axisUnit, abscissTex, oneUnitTex, }) => {
|
|
27
|
+
return abscissTex;
|
|
28
|
+
};
|
|
29
|
+
const getInstruction = (identifiers) => {
|
|
30
|
+
return `Quelle est l'abscisse du point $A$ sur la droite graduée ci-dessous ?`;
|
|
31
|
+
};
|
|
32
|
+
const getGGBOptions = ({ absciss, abscissType, axisUnit, oneUnitTex, coeff, }) => {
|
|
33
|
+
const O = new point_1.Point("O", (0).toTree(), (0).toTree());
|
|
34
|
+
const I = new point_1.Point("I", (1).toTree(), (0).toTree());
|
|
35
|
+
const A = new point_1.Point("A", coeff.toTree(), (0).toTree());
|
|
36
|
+
const commands = [
|
|
37
|
+
...O.toGGBCommand(),
|
|
38
|
+
`Text("\\small 0", (0, -0.5), false, true, 0, 0)`,
|
|
39
|
+
...I.toGGBCommand(),
|
|
40
|
+
`Text("\\small ${oneUnitTex}", (1, ${abscissType === nombre_1.NumberType.Rational ? -1 : -0.5}), false, true, 0, 0)`,
|
|
41
|
+
...A.toGGBCommand(),
|
|
42
|
+
];
|
|
43
|
+
const ggb = new geogebraConstructor_1.GeogebraConstructor({
|
|
44
|
+
hideGrid: true,
|
|
45
|
+
forbidShiftDragZoom: true,
|
|
46
|
+
commands,
|
|
47
|
+
yAxis: {
|
|
48
|
+
hidden: true,
|
|
49
|
+
},
|
|
50
|
+
xAxis: {
|
|
51
|
+
hideNumbers: true,
|
|
52
|
+
steps: 1,
|
|
53
|
+
},
|
|
54
|
+
});
|
|
55
|
+
return ggb.getOptions({
|
|
56
|
+
coords: [-7, 7, -2, 2],
|
|
57
|
+
});
|
|
58
|
+
};
|
|
59
|
+
const getKeys = (identifiers) => {
|
|
60
|
+
return [];
|
|
61
|
+
};
|
|
62
|
+
const isAnswerValid = (ans, { answer, abscissTex }) => {
|
|
63
|
+
try {
|
|
64
|
+
const node = (0, latexParser_1.parseLatex)(abscissTex);
|
|
65
|
+
return node
|
|
66
|
+
.toAllValidTexs({
|
|
67
|
+
allowFractionToDecimal: true,
|
|
68
|
+
allowMinusAnywhereInFraction: true,
|
|
69
|
+
})
|
|
70
|
+
.includes(ans);
|
|
71
|
+
}
|
|
72
|
+
catch (err) {
|
|
73
|
+
return false;
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
const getReadAbscissOnLineQuestion = () => {
|
|
77
|
+
const abscissType = (0, random_1.random)([
|
|
78
|
+
nombre_1.NumberType.Integer,
|
|
79
|
+
nombre_1.NumberType.Rational,
|
|
80
|
+
nombre_1.NumberType.Decimal,
|
|
81
|
+
]);
|
|
82
|
+
let absciss, axisUnit, oneUnitTex, abscissTex, coeff;
|
|
83
|
+
switch (abscissType) {
|
|
84
|
+
case nombre_1.NumberType.Integer:
|
|
85
|
+
axisUnit = (0, randint_1.randint)(1, 10);
|
|
86
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
87
|
+
absciss = axisUnit * coeff;
|
|
88
|
+
oneUnitTex = axisUnit.frenchify();
|
|
89
|
+
abscissTex = absciss.frenchify();
|
|
90
|
+
break;
|
|
91
|
+
case nombre_1.NumberType.Rational:
|
|
92
|
+
const randomFrac = (0, random_1.random)([
|
|
93
|
+
[1, 2],
|
|
94
|
+
[1, 3],
|
|
95
|
+
[2, 3],
|
|
96
|
+
[1, 4],
|
|
97
|
+
[3, 4],
|
|
98
|
+
[1, 5],
|
|
99
|
+
[2, 5],
|
|
100
|
+
[3, 5],
|
|
101
|
+
[4, 5],
|
|
102
|
+
]);
|
|
103
|
+
axisUnit = randomFrac[0] / randomFrac[1];
|
|
104
|
+
const oneUnit = new fractionNode_1.FractionNode(randomFrac[0].toTree(), randomFrac[1].toTree());
|
|
105
|
+
oneUnitTex = oneUnit.toTex();
|
|
106
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
107
|
+
absciss = axisUnit * coeff;
|
|
108
|
+
abscissTex = new multiplyNode_1.MultiplyNode(oneUnit, coeff.toTree()).simplify().toTex();
|
|
109
|
+
break;
|
|
110
|
+
case nombre_1.NumberType.Decimal:
|
|
111
|
+
default:
|
|
112
|
+
axisUnit = (0, randfloat_1.randfloat)(0, 5, 1);
|
|
113
|
+
coeff = (0, randint_1.randint)(-6, 7, [0, 1]);
|
|
114
|
+
absciss = (0, round_1.round)(axisUnit * coeff, 2);
|
|
115
|
+
oneUnitTex = axisUnit.frenchify();
|
|
116
|
+
abscissTex = absciss.frenchify();
|
|
117
|
+
break;
|
|
118
|
+
}
|
|
119
|
+
const identifiers = {
|
|
120
|
+
absciss,
|
|
121
|
+
axisUnit,
|
|
122
|
+
oneUnitTex,
|
|
123
|
+
abscissType,
|
|
124
|
+
abscissTex,
|
|
125
|
+
coeff,
|
|
126
|
+
};
|
|
127
|
+
const question = {
|
|
128
|
+
answer: getAnswer(identifiers),
|
|
129
|
+
instruction: getInstruction(identifiers),
|
|
130
|
+
keys: getKeys(identifiers),
|
|
131
|
+
answerFormat: "tex",
|
|
132
|
+
identifiers,
|
|
133
|
+
ggbOptions: getGGBOptions(identifiers),
|
|
134
|
+
};
|
|
135
|
+
return question;
|
|
136
|
+
};
|
|
137
|
+
exports.readAbscissOnLine = {
|
|
138
|
+
id: "readAbscissOnLine",
|
|
139
|
+
connector: "=",
|
|
140
|
+
label: "Lire une abscisse sur une droite graduée",
|
|
141
|
+
isSingleStep: true,
|
|
142
|
+
generator: (nb) => (0, getDistinctQuestions_1.getDistinctQuestions)(getReadAbscissOnLineQuestion, nb),
|
|
143
|
+
qcmTimer: 60,
|
|
144
|
+
freeTimer: 60,
|
|
145
|
+
ggbTimer: 60,
|
|
146
|
+
getPropositions,
|
|
147
|
+
isAnswerValid,
|
|
148
|
+
subject: "Mathématiques",
|
|
149
|
+
getAnswer,
|
|
150
|
+
getGGBOptions,
|
|
151
|
+
hasGeogebra: true,
|
|
152
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { Exercise } from "../../../../exercises/exercise";
|
|
2
|
+
import { NumberType } from "../../../../math/numbers/nombre";
|
|
3
|
+
type Identifiers = {
|
|
4
|
+
abscissType: NumberType;
|
|
5
|
+
axisUnit: number;
|
|
6
|
+
oneUnitTex: string;
|
|
7
|
+
absciss: number;
|
|
8
|
+
abscissTex: string;
|
|
9
|
+
coeff: number;
|
|
10
|
+
};
|
|
11
|
+
export declare const readAbscissOnSemiLine: Exercise<Identifiers>;
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=readAbscissOnSemiLine.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"readAbscissOnSemiLine.d.ts","sourceRoot":"","sources":["../../../../../src/exercises/math/geometry/cartesian/readAbscissOnSemiLine.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAkBT,MAAM,0BAA0B,CAAC;AAIlC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAUvD,KAAK,WAAW,GAAG;IACjB,WAAW,EAAE,UAAU,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AA4JF,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,WAAW,CAgBvD,CAAC"}
|