math-exercises 3.0.69 → 3.0.70
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 +9 -1
- package/lib/exercises/exercise.d.ts.map +1 -1
- package/lib/exercises/math/calcul/addAndSub.d.ts.map +1 -1
- package/lib/exercises/math/calcul/addAndSub.js +4 -0
- package/lib/exercises/math/calcul/addAndSubWithoutRelatives.d.ts +3 -0
- package/lib/exercises/math/calcul/addAndSubWithoutRelatives.d.ts.map +1 -1
- package/lib/exercises/math/calcul/addAndSubWithoutRelatives.js +33 -20
- package/lib/exercises/math/calcul/digitDecimalRank.d.ts.map +1 -1
- package/lib/exercises/math/calcul/digitDecimalRank.js +36 -13
- package/lib/exercises/math/calcul/digitDecimalRankNumber.d.ts.map +1 -1
- package/lib/exercises/math/calcul/digitDecimalRankNumber.js +27 -12
- package/lib/exercises/math/calcul/digitRank.d.ts.map +1 -1
- package/lib/exercises/math/calcul/digitRank.js +37 -13
- package/lib/exercises/math/calcul/digitRankNumber.d.ts.map +1 -1
- package/lib/exercises/math/calcul/digitRankNumber.js +21 -12
- package/lib/exercises/math/calcul/mentalCaluls/mentalAddAndSub.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalAddAndSub.js +33 -17
- package/lib/exercises/math/calcul/mentalCaluls/mentalAddAndSubNoRelative.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalAddAndSubNoRelative.js +36 -18
- package/lib/exercises/math/calcul/mentalCaluls/mentalDivisions.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalDivisions.js +38 -30
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplications.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplications.js +35 -21
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplicationsNoRelative.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalMultiplicationsNoRelative.js +4 -0
- package/lib/exercises/math/calcul/mentalCaluls/mentalPercentage.d.ts.map +1 -1
- package/lib/exercises/math/calcul/mentalCaluls/mentalPercentage.js +22 -9
- package/lib/exercises/math/calcul/operations/expressionNature.d.ts +2 -1
- package/lib/exercises/math/calcul/operations/expressionNature.d.ts.map +1 -1
- package/lib/exercises/math/calcul/operations/expressionNature.js +36 -15
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesis.d.ts +2 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesis.d.ts.map +1 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesis.js +26 -15
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesisNoRelatives.d.ts +2 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesisNoRelatives.d.ts.map +1 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesParenthesisNoRelatives.js +26 -17
- package/lib/exercises/math/calcul/operations/operationsPrioritiesWithoutRelative.d.ts +1 -0
- package/lib/exercises/math/calcul/operations/operationsPrioritiesWithoutRelative.d.ts.map +1 -1
- package/lib/exercises/math/calcul/operations/operationsPrioritiesWithoutRelative.js +89 -60
- package/lib/exercises/math/calcul/ordering/decimalOrdering.d.ts.map +1 -1
- package/lib/exercises/math/calcul/ordering/decimalOrdering.js +30 -13
- package/lib/exercises/math/calcul/ordering/decimalOrderingNoRelatives.d.ts.map +1 -1
- package/lib/exercises/math/calcul/ordering/decimalOrderingNoRelatives.js +26 -13
- package/lib/exercises/math/calcul/ordering/framing.d.ts.map +1 -1
- package/lib/exercises/math/calcul/ordering/framing.js +70 -59
- package/lib/exercises/math/calcul/ordering/integerOrdering.d.ts.map +1 -1
- package/lib/exercises/math/calcul/ordering/integerOrdering.js +30 -11
- package/lib/exercises/math/calcul/proportionality/findCoeffInProportionalTableNonIntegers.d.ts.map +1 -1
- package/lib/exercises/math/calcul/proportionality/findCoeffInProportionalTableNonIntegers.js +4 -0
- package/lib/exercises/math/calcul/proportionality/isTableProportional.d.ts.map +1 -1
- package/lib/exercises/math/calcul/proportionality/isTableProportional.js +42 -24
- package/lib/exercises/math/calcul/proportionality/isTableProportionalNonInteger.d.ts.map +1 -1
- package/lib/exercises/math/calcul/proportionality/isTableProportionalNonInteger.js +4 -0
- package/lib/exercises/math/calcul/proportionality/scaleUsage.d.ts +1 -0
- package/lib/exercises/math/calcul/proportionality/scaleUsage.d.ts.map +1 -1
- package/lib/exercises/math/calcul/proportionality/scaleUsage.js +75 -39
- package/lib/exercises/math/calcul/writing/index.d.ts +1 -1
- package/lib/exercises/math/calcul/writing/index.d.ts.map +1 -1
- package/lib/exercises/math/calcul/writing/index.js +3 -1
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.d.ts +0 -5
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.d.ts.map +1 -1
- package/lib/exercises/math/calcul/writing/numberToFrenchWriting.js +87 -64
- package/lib/exercises/math/calculLitteral/distributivity/allIdentities.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/allIdentities.js +29 -5
- package/lib/exercises/math/calculLitteral/distributivity/idRmq1.d.ts +2 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq1.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq1.js +3 -3
- package/lib/exercises/math/calculLitteral/distributivity/idRmq2.d.ts +2 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq2.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq2.js +3 -3
- package/lib/exercises/math/calculLitteral/distributivity/idRmq3.d.ts +2 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq3.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/distributivity/idRmq3.js +3 -3
- package/lib/exercises/math/calculLitteral/factorisation/facto1.d.ts.map +1 -1
- package/lib/exercises/math/calculLitteral/factorisation/facto1.js +3 -1
- package/lib/exercises/math/complex/addComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/addComplex.js +31 -18
- package/lib/exercises/math/complex/argumentFromAlgebraicComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/argumentFromAlgebraicComplex.js +24 -11
- package/lib/exercises/math/complex/conjugateComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/conjugateComplex.js +20 -7
- package/lib/exercises/math/complex/conjugateDivideComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/conjugateDivideComplex.js +29 -16
- package/lib/exercises/math/complex/conjugateMultiplyComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/conjugateMultiplyComplex.js +26 -13
- package/lib/exercises/math/complex/divideComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/divideComplex.js +29 -16
- package/lib/exercises/math/complex/inverseComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/inverseComplex.js +18 -7
- package/lib/exercises/math/complex/linearCombinaisonComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/linearCombinaisonComplex.js +30 -13
- package/lib/exercises/math/complex/moduloFromAlgebraicComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/moduloFromAlgebraicComplex.js +20 -8
- package/lib/exercises/math/complex/mutiplyComplex.d.ts.map +1 -1
- package/lib/exercises/math/complex/mutiplyComplex.js +26 -13
- package/lib/exercises/math/complex/reAndIm.d.ts.map +1 -1
- package/lib/exercises/math/complex/reAndIm.js +22 -9
- package/lib/exercises/math/conversion/volumeCapacityConversion.d.ts.map +1 -1
- package/lib/exercises/math/conversion/volumeCapacityConversion.js +1 -0
- package/lib/exercises/math/dataRepresentations/testGen.d.ts.map +1 -1
- package/lib/exercises/math/dataRepresentations/testGen.js +5 -1
- package/lib/exercises/math/dataRepresentations/testGenGGB.d.ts.map +1 -1
- package/lib/exercises/math/dataRepresentations/testGenGGB.js +5 -1
- package/lib/exercises/math/dataRepresentations/testGenStudentGGB.d.ts.map +1 -1
- package/lib/exercises/math/dataRepresentations/testGenStudentGGB.js +5 -1
- package/lib/exercises/math/derivation/convexity/convexityQuadrinomials.d.ts.map +1 -1
- package/lib/exercises/math/derivation/convexity/convexityQuadrinomials.js +4 -0
- package/lib/exercises/math/derivation/convexity/convexityTrinomials.d.ts.map +1 -1
- package/lib/exercises/math/derivation/convexity/convexityTrinomials.js +4 -0
- package/lib/exercises/math/derivation/convexity/inflexionPointQuadrinomials.d.ts.map +1 -1
- package/lib/exercises/math/derivation/convexity/inflexionPointQuadrinomials.js +4 -2
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeFour.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeFour.js +4 -2
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeOne.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeOne.js +4 -0
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeTwo.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/exp/expDerivativeTwo.js +4 -0
- package/lib/exercises/math/derivation/derivative/exp/secondDerivativeOfExpoFunction.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/exp/secondDerivativeOfExpoFunction.js +4 -2
- package/lib/exercises/math/derivation/derivative/inverseFunctionDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/inverseFunctionDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/ln/lnDerivativeTwo.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/ln/lnDerivativeTwo.js +4 -0
- package/lib/exercises/math/derivation/derivative/polynomial/constanteDerivative.d.ts +2 -1
- package/lib/exercises/math/derivation/derivative/polynomial/constanteDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/constanteDerivative.js +6 -4
- package/lib/exercises/math/derivation/derivative/polynomial/firstDegreeDerivative.d.ts +2 -1
- package/lib/exercises/math/derivation/derivative/polynomial/firstDegreeDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/firstDegreeDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/polynomial/secondDegreeDerivative.d.ts +2 -1
- package/lib/exercises/math/derivation/derivative/polynomial/secondDegreeDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/secondDegreeDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/polynomial/secondDerivativeOfThirdDegreeFunction.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/secondDerivativeOfThirdDegreeFunction.js +4 -0
- package/lib/exercises/math/derivation/derivative/polynomial/secondDerivativeOfTrinom.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/secondDerivativeOfTrinom.js +4 -0
- package/lib/exercises/math/derivation/derivative/polynomial/thirdDegreeDerivative.d.ts +2 -1
- package/lib/exercises/math/derivation/derivative/polynomial/thirdDegreeDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/thirdDegreeDerivative.js +4 -10
- package/lib/exercises/math/derivation/derivative/polynomial/usualderivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/polynomial/usualderivative.js +32 -4
- package/lib/exercises/math/derivation/derivative/power/powerCompositionDerivation.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/power/powerCompositionDerivation.js +4 -2
- package/lib/exercises/math/derivation/derivative/power/powerFunctionDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/power/powerFunctionDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/productDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/productDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/quotientDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/quotientDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/sqrt/rootFunctionDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/sqrt/rootFunctionDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/sqrt/sqrtCompositionDerivation.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/sqrt/sqrtCompositionDerivation.js +4 -0
- package/lib/exercises/math/derivation/derivative/trigo/cosCompositionDerivation.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/trigo/cosCompositionDerivation.js +4 -0
- package/lib/exercises/math/derivation/derivative/trigo/cosSecondDegreeDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/trigo/cosSecondDegreeDerivative.js +4 -0
- package/lib/exercises/math/derivation/derivative/trigo/sinCompositionDerivation.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/trigo/sinCompositionDerivation.js +4 -0
- package/lib/exercises/math/derivation/derivative/trigo/sinSecondDegreeDerivative.d.ts.map +1 -1
- package/lib/exercises/math/derivation/derivative/trigo/sinSecondDegreeDerivative.js +4 -0
- package/lib/exercises/math/equaDiff/equaDiffCheckSolutionFirstOrder.d.ts +4 -3
- package/lib/exercises/math/equaDiff/equaDiffCheckSolutionFirstOrder.d.ts.map +1 -1
- package/lib/exercises/math/equaDiff/equaDiffCheckSolutionFirstOrder.js +32 -16
- package/lib/exercises/math/functions/exponential/expFactorization.d.ts.map +1 -1
- package/lib/exercises/math/functions/exponential/expFactorization.js +1 -0
- package/lib/exercises/math/functions/trinoms/equation/secondDegreeInequation.d.ts.map +1 -1
- package/lib/exercises/math/functions/trinoms/equation/secondDegreeInequation.js +73 -41
- package/lib/exercises/math/functions/trinoms/summitAndCanonical/alphaBetaInCanonicalForm.d.ts.map +1 -1
- package/lib/exercises/math/functions/trinoms/summitAndCanonical/alphaBetaInCanonicalForm.js +32 -16
- package/lib/exercises/math/functions/trinoms/summitAndCanonical/summitReading.d.ts.map +1 -1
- package/lib/exercises/math/functions/trinoms/summitAndCanonical/summitReading.js +1 -2
- package/lib/exercises/math/geometry/areas/circleRadiusFromArea.d.ts.map +1 -1
- package/lib/exercises/math/geometry/areas/circleRadiusFromArea.js +1 -0
- package/lib/exercises/math/geometry/areas/squareSideFromArea.d.ts.map +1 -1
- package/lib/exercises/math/geometry/areas/squareSideFromArea.js +1 -0
- package/lib/exercises/math/geometry/shapes/basicShapesNaming.d.ts +4 -1
- package/lib/exercises/math/geometry/shapes/basicShapesNaming.d.ts.map +1 -1
- package/lib/exercises/math/geometry/shapes/basicShapesNaming.js +97 -44
- package/lib/exercises/math/geometry/vectors/coordinatesReading.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/coordinatesReading.js +28 -14
- package/lib/exercises/math/geometry/vectors/determinant.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/determinant.js +26 -12
- package/lib/exercises/math/geometry/vectors/drawAVectorInGGB.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/drawAVectorInGGB.js +25 -11
- package/lib/exercises/math/geometry/vectors/equalCaracteristicFromGraph.d.ts +1 -0
- package/lib/exercises/math/geometry/vectors/equalCaracteristicFromGraph.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/equalCaracteristicFromGraph.js +60 -33
- package/lib/exercises/math/geometry/vectors/fourthParallelogramPoint.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/fourthParallelogramPoint.js +34 -19
- package/lib/exercises/math/geometry/vectors/paralellismViaColinearity.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/paralellismViaColinearity.js +42 -20
- package/lib/exercises/math/geometry/vectors/parallelogramViaEqualVectors.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/parallelogramViaEqualVectors.js +42 -20
- package/lib/exercises/math/geometry/vectors/traceOppositeVector.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/traceOppositeVector.js +4 -0
- package/lib/exercises/math/geometry/vectors/traceVectorDifference.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/traceVectorDifference.js +4 -0
- package/lib/exercises/math/geometry/vectors/traceVectorMultiple.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/traceVectorMultiple.js +4 -0
- package/lib/exercises/math/geometry/vectors/traceVectorSum.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/traceVectorSum.js +4 -0
- package/lib/exercises/math/geometry/vectors/vectorCoordinatesFromTwoPoints.d.ts +2 -0
- package/lib/exercises/math/geometry/vectors/vectorCoordinatesFromTwoPoints.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/vectorCoordinatesFromTwoPoints.js +45 -25
- package/lib/exercises/math/geometry/vectors/vectorLinearCombination.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/vectorLinearCombination.js +33 -14
- package/lib/exercises/math/geometry/vectors/vectorNormCalculation.d.ts.map +1 -1
- package/lib/exercises/math/geometry/vectors/vectorNormCalculation.js +9 -3
- package/lib/exercises/math/limits/limitReading.d.ts +5 -1
- package/lib/exercises/math/limits/limitReading.d.ts.map +1 -1
- package/lib/exercises/math/limits/limitReading.js +96 -38
- package/lib/exercises/math/limits/polynomLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/polynomLimit.js +0 -2
- package/lib/exercises/math/limits/rationalFracForbiddenValueLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/rationalFracForbiddenValueLimit.js +37 -20
- package/lib/exercises/math/limits/rationalFracLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/rationalFracLimit.js +34 -17
- package/lib/exercises/math/limits/sequenceGeometricLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/sequenceGeometricLimit.js +4 -0
- package/lib/exercises/math/limits/sequencePolynomLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/sequencePolynomLimit.js +23 -10
- package/lib/exercises/math/limits/sequencePolynomNoFILimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/sequencePolynomNoFILimit.js +24 -11
- package/lib/exercises/math/limits/sequencePolynomProductLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/sequencePolynomProductLimit.js +31 -18
- package/lib/exercises/math/limits/sequenceRationalFracLimit.d.ts.map +1 -1
- package/lib/exercises/math/limits/sequenceRationalFracLimit.js +33 -16
- package/lib/exercises/math/matrices/matrixGeneralTerm.d.ts.map +1 -1
- package/lib/exercises/math/matrices/matrixGeneralTerm.js +21 -8
- package/lib/exercises/math/matrices/matrixInversibilityDomain.d.ts.map +1 -1
- package/lib/exercises/math/matrices/matrixInversibilityDomain.js +44 -26
- package/lib/exercises/math/matrices/productCell.d.ts +2 -0
- package/lib/exercises/math/matrices/productCell.d.ts.map +1 -1
- package/lib/exercises/math/matrices/productCell.js +27 -12
- package/lib/exercises/math/powers/decimalToScientific.d.ts.map +1 -1
- package/lib/exercises/math/powers/decimalToScientific.js +9 -0
- package/lib/exercises/math/primitive/constantPrimitive.d.ts +2 -1
- package/lib/exercises/math/primitive/constantPrimitive.d.ts.map +1 -1
- package/lib/exercises/math/primitive/constantPrimitive.js +3 -3
- package/lib/exercises/math/primitive/exponentialPrimitive.d.ts +2 -1
- package/lib/exercises/math/primitive/exponentialPrimitive.d.ts.map +1 -1
- package/lib/exercises/math/primitive/exponentialPrimitive.js +3 -3
- package/lib/exercises/math/primitive/polynomialPrimitive.d.ts +2 -1
- package/lib/exercises/math/primitive/polynomialPrimitive.d.ts.map +1 -1
- package/lib/exercises/math/primitive/polynomialPrimitive.js +3 -3
- package/lib/exercises/math/primitive/sinCosPrimitive.d.ts +2 -1
- package/lib/exercises/math/primitive/sinCosPrimitive.d.ts.map +1 -1
- package/lib/exercises/math/primitive/sinCosPrimitive.js +3 -3
- package/lib/exercises/math/primitive/usualPrimitives.d.ts.map +1 -1
- package/lib/exercises/math/primitive/usualPrimitives.js +33 -6
- package/lib/exercises/math/probaStat/binomial/varianceOfBinomialProba.d.ts.map +1 -1
- package/lib/exercises/math/probaStat/binomial/varianceOfBinomialProba.js +1 -0
- package/lib/exercises/math/probaStat/stats1var/quartilesList.d.ts.map +1 -1
- package/lib/exercises/math/probaStat/stats1var/quartilesList.js +4 -1
- package/lib/exercises/math/probaStat/stats2var/averagePoint.d.ts.map +1 -1
- package/lib/exercises/math/probaStat/stats2var/averagePoint.js +1 -2
- package/lib/exercises/math/sequences/arithmetic/arithmeticExplicitFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticExplicitFormulaUsage.js +47 -23
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplicitFormula.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplicitFormula.js +4 -6
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplictFormulaFirstTermRandom.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindExplictFormulaFirstTermRandom.js +4 -0
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindRandomTermFromTwoTerms.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindRandomTermFromTwoTerms.js +30 -12
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReason.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReason.js +4 -0
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReasonRandomRange.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindReasonRandomRange.js +23 -9
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindTerm.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFindTerm.js +62 -41
- package/lib/exercises/math/sequences/arithmetic/arithmeticFirstTermsSum.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticFirstTermsSum.js +4 -2
- package/lib/exercises/math/sequences/arithmetic/arithmeticReasonUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticReasonUsage.js +4 -0
- package/lib/exercises/math/sequences/arithmetic/arithmeticRecurrenceFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticRecurrenceFormulaUsage.js +26 -10
- package/lib/exercises/math/sequences/arithmetic/arithmeticThresholdFind.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/arithmeticThresholdFind.js +33 -14
- package/lib/exercises/math/sequences/arithmetic/firstIntegersSum.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/firstIntegersSum.js +4 -2
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromFirstTerms.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromFirstTerms.js +35 -14
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromGraph.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/recognizeArithmeticFromGraph.js +37 -24
- package/lib/exercises/math/sequences/arithmetic/recognizeReasonFromFirstTerms.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/recognizeReasonFromFirstTerms.js +4 -0
- package/lib/exercises/math/sequences/arithmetic/recognizeReasonFromGraph.d.ts.map +1 -1
- package/lib/exercises/math/sequences/arithmetic/recognizeReasonFromGraph.js +29 -15
- package/lib/exercises/math/sequences/explicitFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/explicitFormulaUsage.js +27 -10
- package/lib/exercises/math/sequences/genericSequenceVariations.d.ts.map +1 -1
- package/lib/exercises/math/sequences/genericSequenceVariations.js +23 -10
- package/lib/exercises/math/sequences/geometric/geometricExplicitFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricExplicitFormulaUsage.js +9 -3
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormula.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormula.js +45 -17
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormulaFirstTermRandom.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindExplicitFormulaFirstTermRandom.js +20 -9
- package/lib/exercises/math/sequences/geometric/geometricFindReason.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindReason.js +20 -9
- package/lib/exercises/math/sequences/geometric/geometricFindTerm.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFindTerm.js +60 -41
- package/lib/exercises/math/sequences/geometric/geometricFirstTermsSum.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricFirstTermsSum.js +1 -0
- package/lib/exercises/math/sequences/geometric/geometricReasonUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricReasonUsage.js +26 -10
- package/lib/exercises/math/sequences/geometric/geometricRecognizeReasonFromFirstTerms.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricRecognizeReasonFromFirstTerms.js +4 -0
- package/lib/exercises/math/sequences/geometric/geometricRecurrenceFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricRecurrenceFormulaUsage.js +27 -10
- package/lib/exercises/math/sequences/geometric/geometricVariations.d.ts.map +1 -1
- package/lib/exercises/math/sequences/geometric/geometricVariations.js +4 -0
- package/lib/exercises/math/sequences/recurrenceFormulaUsage.d.ts.map +1 -1
- package/lib/exercises/math/sequences/recurrenceFormulaUsage.js +23 -11
- package/lib/exercises/math/sequences/sequenceEvaluation.d.ts.map +1 -1
- package/lib/exercises/math/sequences/sequenceEvaluation.js +45 -21
- package/lib/exercises/math/sets/intervals/intervalsUnion.d.ts.map +1 -1
- package/lib/exercises/math/sets/intervals/intervalsUnion.js +1 -2
- package/lib/exercises/pc/calibrationCurveOfSolution.d.ts.map +1 -1
- package/lib/exercises/pc/calibrationCurveOfSolution.js +56 -48
- package/lib/exercises/pc/chemicalElements/identifyRightElectronicConfiguration.js +3 -1
- package/lib/exercises/pc/chemicalElements/weightPercent.d.ts.map +1 -1
- package/lib/exercises/pc/chemicalElements/weightPercent.js +1 -0
- package/lib/exercises/pc/chemicalEquations.d.ts.map +1 -1
- package/lib/exercises/pc/chemicalEquations.js +0 -2
- package/lib/exercises/pc/chemicalReactions/chemicalEquations.d.ts +8 -0
- package/lib/exercises/pc/chemicalReactions/chemicalEquations.d.ts.map +1 -0
- package/lib/exercises/pc/chemicalReactions/chemicalEquations.js +62 -0
- package/lib/exercises/pc/chemicalReactions/chemicalReactionsProduct.d.ts +9 -0
- package/lib/exercises/pc/chemicalReactions/chemicalReactionsProduct.d.ts.map +1 -0
- package/lib/exercises/pc/chemicalReactions/chemicalReactionsProduct.js +70 -0
- package/lib/exercises/pc/chemicalReactions/index.d.ts +2 -0
- package/lib/exercises/pc/chemicalReactions/index.d.ts.map +1 -1
- package/lib/exercises/pc/chemicalReactions/index.js +2 -0
- package/lib/exercises/pc/delution.d.ts.map +1 -1
- package/lib/exercises/pc/delution.js +25 -12
- package/lib/exercises/pc/dosage/concentrationCalculation.d.ts.map +1 -1
- package/lib/exercises/pc/dosage/concentrationCalculation.js +5 -3
- package/lib/exercises/pc/electricity/calculateVoltage.d.ts.map +1 -1
- package/lib/exercises/pc/electricity/calculateVoltage.js +112 -90
- package/lib/exercises/pc/electricity/electricEnergyFromPower.d.ts.map +1 -1
- package/lib/exercises/pc/electricity/electricEnergyFromPower.js +1 -0
- package/lib/exercises/pc/energy/efficiencyCalculation.d.ts.map +1 -1
- package/lib/exercises/pc/energy/efficiencyCalculation.js +5 -3
- package/lib/exercises/pc/forces/calculateNormalOrFrictionForce.d.ts.map +1 -1
- package/lib/exercises/pc/forces/calculateNormalOrFrictionForce.js +0 -1
- package/lib/exercises/pc/forces/gravitationalAttractionObjectHeight.d.ts.map +1 -1
- package/lib/exercises/pc/forces/gravitationalAttractionObjectHeight.js +87 -38
- package/lib/exercises/pc/forces/gravitationalAttractionValue.d.ts.map +1 -1
- package/lib/exercises/pc/forces/gravitationalAttractionValue.js +31 -16
- package/lib/exercises/pc/forces/gravitationalForcePlanets.d.ts.map +1 -1
- package/lib/exercises/pc/forces/gravitationalForcePlanets.js +71 -31
- package/lib/exercises/pc/forces/massWeight.d.ts.map +1 -1
- package/lib/exercises/pc/forces/massWeight.js +53 -20
- package/lib/exercises/pc/forces/pressingForce.d.ts.map +1 -1
- package/lib/exercises/pc/forces/pressingForce.js +71 -31
- package/lib/exercises/pc/formulaFromComposition.d.ts.map +1 -1
- package/lib/exercises/pc/formulaFromComposition.js +28 -8
- package/lib/exercises/pc/identifyAtomicMassOrAtomicNb.d.ts.map +1 -1
- package/lib/exercises/pc/identifyAtomicMassOrAtomicNb.js +31 -12
- package/lib/exercises/pc/index.d.ts +4 -6
- package/lib/exercises/pc/index.d.ts.map +1 -1
- package/lib/exercises/pc/index.js +4 -6
- package/lib/exercises/pc/kineticEnergy.d.ts.map +1 -1
- package/lib/exercises/pc/kineticEnergy.js +22 -10
- package/lib/exercises/pc/math/isolateVariables.d.ts.map +1 -1
- package/lib/exercises/pc/math/isolateVariables.js +114 -32
- package/lib/exercises/pc/math/proportionnalityCoeffFromLine.d.ts.map +1 -1
- package/lib/exercises/pc/math/proportionnalityCoeffFromLine.js +34 -16
- package/lib/exercises/pc/mecanicalWaves/elongationReading.d.ts.map +1 -1
- package/lib/exercises/pc/mecanicalWaves/elongationReading.js +35 -13
- package/lib/exercises/pc/molarQuantity.d.ts.map +1 -1
- package/lib/exercises/pc/molarQuantity.js +29 -13
- package/lib/exercises/pc/mole/concentrationReading.d.ts +4 -1
- package/lib/exercises/pc/mole/concentrationReading.d.ts.map +1 -1
- package/lib/exercises/pc/mole/concentrationReading.js +28 -10
- package/lib/exercises/pc/mole/molFromMass.d.ts.map +1 -1
- package/lib/exercises/pc/mole/molFromMass.js +21 -8
- package/lib/exercises/pc/mole/molFromMolarMass.d.ts.map +1 -1
- package/lib/exercises/pc/mole/molFromMolarMass.js +21 -8
- package/lib/exercises/pc/mole/molarMass.d.ts +3 -1
- package/lib/exercises/pc/mole/molarMass.d.ts.map +1 -1
- package/lib/exercises/pc/mole/molarMass.js +22 -9
- package/lib/exercises/pc/mole/moleculeCountFromMassAndAvogadro.d.ts.map +1 -1
- package/lib/exercises/pc/mole/moleculeCountFromMassAndAvogadro.js +25 -11
- package/lib/exercises/pc/mole/moleculeCountFromMol.d.ts.map +1 -1
- package/lib/exercises/pc/mole/moleculeCountFromMol.js +18 -7
- package/lib/exercises/pc/moleculeFormula.d.ts.map +1 -1
- package/lib/exercises/pc/moleculeFormula.js +30 -9
- package/lib/exercises/pc/moleculeNomenclature.d.ts.map +1 -1
- package/lib/exercises/pc/moleculeNomenclature.js +23 -8
- package/lib/exercises/pc/motion/averageSpeed.d.ts.map +1 -1
- package/lib/exercises/pc/motion/averageSpeed.js +68 -55
- package/lib/exercises/pc/motion/averageSpeedCalculation.d.ts.map +1 -1
- package/lib/exercises/pc/motion/averageSpeedCalculation.js +97 -39
- package/lib/exercises/pc/motion/characteristicsOfVelocityVector.d.ts +4 -1
- package/lib/exercises/pc/motion/characteristicsOfVelocityVector.d.ts.map +1 -1
- package/lib/exercises/pc/motion/characteristicsOfVelocityVector.js +51 -49
- package/lib/exercises/pc/motion/motionReference.d.ts +1 -0
- package/lib/exercises/pc/motion/motionReference.d.ts.map +1 -1
- package/lib/exercises/pc/motion/motionReference.js +47 -26
- package/lib/exercises/pc/motion/typeOfAcceleration.d.ts +1 -1
- package/lib/exercises/pc/motion/typeOfAcceleration.d.ts.map +1 -1
- package/lib/exercises/pc/motion/typeOfAcceleration.js +61 -62
- package/lib/exercises/pc/motion/typeOfMovement.d.ts +2 -1
- package/lib/exercises/pc/motion/typeOfMovement.d.ts.map +1 -1
- package/lib/exercises/pc/motion/typeOfMovement.js +58 -57
- package/lib/exercises/pc/orderOfMagnitude.d.ts.map +1 -1
- package/lib/exercises/pc/orderOfMagnitude.js +24 -23
- package/lib/exercises/pc/pH.d.ts.map +1 -1
- package/lib/exercises/pc/pH.js +37 -16
- package/lib/exercises/pc/perceivedFrequency.d.ts.map +1 -1
- package/lib/exercises/pc/perceivedFrequency.js +26 -13
- package/lib/exercises/pc/potentialEnergy.d.ts.map +1 -1
- package/lib/exercises/pc/potentialEnergy.js +23 -11
- package/lib/exercises/pc/power/calculatePowerOfLight.d.ts +2 -2
- package/lib/exercises/pc/power/calculatePowerOfLight.d.ts.map +1 -1
- package/lib/exercises/pc/power/calculatePowerOfLight.js +65 -39
- package/lib/exercises/pc/recognizeRefractionOrReflectionAngles.d.ts +3 -1
- package/lib/exercises/pc/recognizeRefractionOrReflectionAngles.d.ts.map +1 -1
- package/lib/exercises/pc/recognizeRefractionOrReflectionAngles.js +48 -47
- package/lib/exercises/pc/snellDescartes.d.ts.map +1 -1
- package/lib/exercises/pc/snellDescartes.js +31 -13
- package/lib/exercises/pc/sound/findPeriodFromGraph.d.ts.map +1 -1
- package/lib/exercises/pc/sound/findPeriodFromGraph.js +42 -26
- package/lib/exercises/pc/sound/findPeriodOrFrequencyFromGraph.d.ts +1 -0
- package/lib/exercises/pc/sound/findPeriodOrFrequencyFromGraph.d.ts.map +1 -1
- package/lib/exercises/pc/sound/findPeriodOrFrequencyFromGraph.js +51 -32
- package/lib/exercises/pc/sound/findSoundFrequencyFromPeriod.d.ts.map +1 -1
- package/lib/exercises/pc/sound/findSoundFrequencyFromPeriod.js +20 -7
- package/lib/exercises/pc/sound/findSoundPeriodFromFrequency.d.ts.map +1 -1
- package/lib/exercises/pc/sound/findSoundPeriodFromFrequency.js +20 -7
- package/lib/exercises/pc/sound/frequencyComparison.d.ts.map +1 -1
- package/lib/exercises/pc/sound/frequencyComparison.js +25 -14
- package/lib/exercises/pc/spectral/spectralEnergy.d.ts +1 -3
- package/lib/exercises/pc/spectral/spectralEnergy.d.ts.map +1 -1
- package/lib/exercises/pc/spectral/spectralEnergy.js +98 -56
- package/lib/exercises/pc/waves/findDistanceFromEarth.d.ts.map +1 -1
- package/lib/exercises/pc/waves/findDistanceFromEarth.js +22 -9
- package/lib/exercises/pc/waves/lightDistanceConversion.d.ts.map +1 -1
- package/lib/exercises/pc/waves/lightDistanceConversion.js +104 -76
- package/lib/exercises/pc/waves/periodicWaveCelerity.d.ts +1 -0
- package/lib/exercises/pc/waves/periodicWaveCelerity.d.ts.map +1 -1
- package/lib/exercises/pc/waves/periodicWaveCelerity.js +81 -25
- package/lib/exercises/pc/weight/calculateWeight.d.ts.map +1 -1
- package/lib/exercises/pc/weight/calculateWeight.js +55 -26
- package/lib/exercises/pc/weight/weightOnTheMoon.d.ts.map +1 -1
- package/lib/exercises/pc/weight/weightOnTheMoon.js +67 -32
- package/lib/index.d.ts +58 -37
- package/lib/index.d.ts.map +1 -1
- package/lib/latexTester.js +7 -2
- package/lib/math/geometry/ray.d.ts +8 -1
- package/lib/math/geometry/ray.d.ts.map +1 -1
- package/lib/math/geometry/ray.js +11 -1
- package/lib/math/polynomials/trinom.d.ts +5 -0
- package/lib/math/polynomials/trinom.d.ts.map +1 -1
- package/lib/math/polynomials/trinom.js +6 -0
- package/lib/pc/constants/molecularChemistry/reaction.js +1 -1
- package/lib/pc/measure/measure.d.ts +11 -4
- package/lib/pc/measure/measure.d.ts.map +1 -1
- package/lib/pc/measure/measure.js +10 -6
- package/lib/playground.d.ts.map +1 -1
- package/lib/playground.js +8 -1
- package/lib/tests/exoTest.d.ts.map +1 -1
- package/lib/tests/exoTest.js +13 -0
- package/lib/tests/mega.test.d.ts +2 -0
- package/lib/tests/mega.test.d.ts.map +1 -0
- package/lib/tests/mega.test.js +13 -0
- package/lib/tests/megaxl.test.d.ts +2 -0
- package/lib/tests/megaxl.test.d.ts.map +1 -0
- package/lib/tests/megaxl.test.js +10 -0
- package/lib/tests/singleExo.test.d.ts.map +1 -1
- package/lib/tests/singleExo.test.js +2 -2
- package/lib/tree/nodes/operators/powerNode.d.ts.map +1 -1
- package/lib/tree/nodes/operators/powerNode.js +2 -1
- package/package.json +3 -1
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { Exercise } from "../../../exercises/exercise.js";
|
|
2
|
-
import { Measure } from "../../../pc/measure/measure.js";
|
|
3
2
|
type Identifiers = {
|
|
4
|
-
wavelengths:
|
|
3
|
+
wavelengths: number[];
|
|
5
4
|
targetColor: "bleue" | "verte" | "rouge";
|
|
6
|
-
energy: Measure;
|
|
7
5
|
};
|
|
8
6
|
export declare const SpectralEnergyExercise: Exercise<Identifiers>;
|
|
9
7
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spectralEnergy.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/spectral/spectralEnergy.ts"],"names":[],"mappings":"AACA,OAAO,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"spectralEnergy.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/spectral/spectralEnergy.ts"],"names":[],"mappings":"AACA,OAAO,EACL,QAAQ,EAcT,MAAM,6BAA6B,CAAC;AAYrC,KAAK,WAAW,GAAG;IACjB,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,WAAW,EAAE,OAAO,GAAG,OAAO,GAAG,OAAO,CAAC;CAC1C,CAAC;AA4MF,eAAO,MAAM,sBAAsB,EAAE,QAAQ,CAAC,WAAW,CAaxD,CAAC"}
|
|
@@ -1,58 +1,83 @@
|
|
|
1
1
|
import { addValidProp, shuffleProps, tryToAddWrongProp, } from "../../../exercises/exercise.js";
|
|
2
2
|
import { getDistinctQuestions } from "../../../exercises/utils/getDistinctQuestions.js";
|
|
3
|
-
import { Measure } from "../../../pc/measure/measure.js";
|
|
3
|
+
import { Measure, MeasureConstructor, } from "../../../pc/measure/measure.js";
|
|
4
4
|
import { randfloat } from "../../../math/utils/random/randfloat.js";
|
|
5
5
|
import { randint } from "../../../math/utils/random/randint.js";
|
|
6
6
|
import { lightSpeed, planckConstant } from "../../../pc/constants/quantic.js";
|
|
7
|
-
const
|
|
7
|
+
const wavelengthsBounds = {
|
|
8
8
|
bleue: { min: 400, max: 455 },
|
|
9
9
|
verte: { min: 500, max: 560 },
|
|
10
10
|
rouge: { min: 610, max: 660 },
|
|
11
11
|
};
|
|
12
12
|
const h = new Measure(planckConstant.value.significantPart, planckConstant.value.exponent);
|
|
13
13
|
const c = new Measure(lightSpeed.value.significantPart, lightSpeed.value.exponent);
|
|
14
|
-
const images = [
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
];
|
|
21
|
-
const
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
14
|
+
// const images = [
|
|
15
|
+
// `https://heureuxhasarddocsbucket.s3.eu-west-3.amazonaws.com/xpliveV2/activities/quizzes/generator/emissionSpectrum1.png`,
|
|
16
|
+
// `https://heureuxhasarddocsbucket.s3.eu-west-3.amazonaws.com/xpliveV2/activities/quizzes/generator/emissionSpectrum2.png`,
|
|
17
|
+
// `https://heureuxhasarddocsbucket.s3.eu-west-3.amazonaws.com/xpliveV2/activities/quizzes/generator/emissionSpectrum3.png`,
|
|
18
|
+
// `https://heureuxhasarddocsbucket.s3.eu-west-3.amazonaws.com/xpliveV2/activities/quizzes/generator/emissionSpectrum4.png`,
|
|
19
|
+
// `https://heureuxhasarddocsbucket.s3.eu-west-3.amazonaws.com/xpliveV2/activities/quizzes/generator/emissionSpectrum5.png`,
|
|
20
|
+
// ];
|
|
21
|
+
const getInstruction = (identifiers) => {
|
|
22
|
+
const { targetColor, wavelengths } = identifiers;
|
|
23
|
+
return `Vous travaillez dans un laboratoire de spectroscopie et vous êtes en train de réaliser une analyse des transitions électroniques d'un échantillon.
|
|
24
|
+
|
|
25
|
+
Vous avez utilisé un spectromètre pour mesurer les longueurs d'onde des raies d'émission de la lumière émise par l'échantillon.
|
|
26
|
+
|
|
27
|
+
Les mesures que vous avez obtenues sont les suivantes :
|
|
28
|
+
|
|
29
|
+
- Longueur d'onde de la lumière bleue : $\\lambda_{bleue} = ${wavelengths[0]}\\ \\textrm{nm}$,
|
|
30
|
+
- Longueur d'onde de la lumière verte : $\\lambda_{verte} = ${wavelengths[1]}\\ \\textrm{nm}$,
|
|
31
|
+
- Longueur d'onde de la lumière rouge : $\\lambda_{rouge} = ${wavelengths[2]}\\ \\textrm{nm}$.
|
|
32
|
+
|
|
33
|
+
En utilisant ces données, calculez l'énergie de transition en joules pour la lumière ${targetColor} émise par l'échantillon.`;
|
|
34
|
+
};
|
|
35
|
+
const getAnswer = (identifiers) => {
|
|
36
|
+
const { targetColor, wavelengths } = identifiers;
|
|
37
|
+
const wavelengthBlue = new Measure(wavelengths[0], -9);
|
|
38
|
+
const wavelengthGreen = new Measure(wavelengths[1], -9);
|
|
39
|
+
const wavelengthRed = new Measure(wavelengths[2], -9);
|
|
28
40
|
const energies = {
|
|
29
41
|
bleue: h.times(c).divide(wavelengthBlue).toSignificant(2),
|
|
30
42
|
verte: h.times(c).divide(wavelengthGreen).toSignificant(2),
|
|
31
43
|
rouge: h.times(c).divide(wavelengthRed).toSignificant(2),
|
|
32
44
|
};
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
- Longueur d'onde de la lumière rouge : $\\lambda_{rouge} = ${wavelengthRedNm}\\ nm$.
|
|
43
|
-
|
|
44
|
-
]})
|
|
45
|
+
const energy = energies[targetColor];
|
|
46
|
+
return MeasureConstructor.fromIdentifiers(energy).toTex();
|
|
47
|
+
};
|
|
48
|
+
const getHint = (identifiers) => {
|
|
49
|
+
return `La relation entre l'énergie et la longueur d'onde est :
|
|
50
|
+
|
|
51
|
+
$$
|
|
52
|
+
E = \\frac{hc}{\\lambda}
|
|
53
|
+
$$
|
|
45
54
|
|
|
46
|
-
En utilisant ces données, calculez l'énergie de transition en joules pour la lumière ${targetColor} émise par l'échantillon.`;
|
|
47
|
-
const hint = `La relation entre l'énergie et la longueur d'onde est : $E = \\frac{hc}{\\lambda}$. \n
|
|
48
55
|
Rappel des constantes :
|
|
56
|
+
|
|
49
57
|
- Constante de Planck : $h = ${h.toSignificant(2).toTex()}$
|
|
50
58
|
- Vitesse de la lumière : $c = ${c.toSignificant(2).toTex()}$`;
|
|
51
|
-
|
|
52
|
-
|
|
59
|
+
};
|
|
60
|
+
const getCorrection = (identifiers) => {
|
|
61
|
+
const { targetColor, wavelengths } = identifiers;
|
|
62
|
+
const wavelengthBlue = new Measure(wavelengths[0], -9);
|
|
63
|
+
const wavelengthGreen = new Measure(wavelengths[1], -9);
|
|
64
|
+
const wavelengthRed = new Measure(wavelengths[2], -9);
|
|
65
|
+
const energies = {
|
|
66
|
+
bleue: h.times(c).divide(wavelengthBlue).toSignificant(2),
|
|
67
|
+
verte: h.times(c).divide(wavelengthGreen).toSignificant(2),
|
|
68
|
+
rouge: h.times(c).divide(wavelengthRed).toSignificant(2),
|
|
69
|
+
};
|
|
70
|
+
const energy = energies[targetColor];
|
|
71
|
+
return `La relation entre l'énergie et la longueur d'onde est donnée par :
|
|
72
|
+
|
|
73
|
+
$$
|
|
74
|
+
E = \\frac{hc}{\\lambda}
|
|
75
|
+
$$
|
|
53
76
|
|
|
54
|
-
|
|
55
|
-
|
|
77
|
+
En utilisant les valeurs fournies pour $h$, $c$, et $\\lambda_{${targetColor}}$ (en mètres), on peut résoudre pour l'énergie :
|
|
78
|
+
|
|
79
|
+
$$
|
|
80
|
+
E_{${targetColor}} = \\dfrac{${h.toTex({ scientific: 2 })} \\times ${c.toTex({
|
|
56
81
|
scientific: 2,
|
|
57
82
|
})}}{${targetColor === "bleue"
|
|
58
83
|
? wavelengthBlue.toTex({
|
|
@@ -60,30 +85,45 @@ Rappel des constantes :
|
|
|
60
85
|
})
|
|
61
86
|
: targetColor === "rouge"
|
|
62
87
|
? wavelengthRed.toTex({ scientific: 2 })
|
|
63
|
-
: wavelengthGreen.toTex({ scientific: 2 })}} = ${
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
- Constante de Planck : $h = ${h.toSignificant(2).toTex()}$
|
|
68
|
-
- Vitesse de la lumière : $c = ${c.toSignificant(2).toTex()}$`;
|
|
88
|
+
: wavelengthGreen.toTex({ scientific: 2 })}} = ${energy.toTex()}\\ \\textrm{J}
|
|
89
|
+
$$`;
|
|
90
|
+
};
|
|
91
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
69
92
|
const question = {
|
|
70
|
-
answer:
|
|
71
|
-
instruction,
|
|
72
|
-
hint,
|
|
73
|
-
correction,
|
|
93
|
+
answer: getAnswer(identifiers),
|
|
94
|
+
instruction: getInstruction(identifiers),
|
|
95
|
+
hint: getHint(identifiers),
|
|
96
|
+
correction: getCorrection(identifiers),
|
|
74
97
|
keys: [],
|
|
75
98
|
answerFormat: "tex",
|
|
76
|
-
identifiers
|
|
77
|
-
wavelengths: [wavelengthBlue, wavelengthGreen, wavelengthRed],
|
|
78
|
-
targetColor,
|
|
79
|
-
energy: targetEnergy,
|
|
80
|
-
},
|
|
99
|
+
identifiers,
|
|
81
100
|
};
|
|
82
101
|
return question;
|
|
83
102
|
};
|
|
84
|
-
const
|
|
103
|
+
const getSpectralEnergyQuestion = () => {
|
|
104
|
+
const wavelengthBlueNm = randint(wavelengthsBounds.bleue.min, wavelengthsBounds.bleue.max);
|
|
105
|
+
const wavelengthGreenNm = randint(wavelengthsBounds.verte.min, wavelengthsBounds.verte.max);
|
|
106
|
+
const wavelengthRedNm = randint(wavelengthsBounds.rouge.min, wavelengthsBounds.rouge.max);
|
|
107
|
+
const colors = ["bleue", "verte", "rouge"];
|
|
108
|
+
const targetColor = colors[randint(0, colors.length - 1)];
|
|
109
|
+
const identifiers = {
|
|
110
|
+
wavelengths: [wavelengthBlueNm, wavelengthGreenNm, wavelengthRedNm],
|
|
111
|
+
targetColor,
|
|
112
|
+
};
|
|
113
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
114
|
+
};
|
|
115
|
+
const getPropositions = (n, { answer, targetColor, wavelengths }) => {
|
|
85
116
|
const propositions = [];
|
|
86
117
|
addValidProp(propositions, answer);
|
|
118
|
+
const wavelengthBlue = new Measure(wavelengths[0], -9);
|
|
119
|
+
const wavelengthGreen = new Measure(wavelengths[1], -9);
|
|
120
|
+
const wavelengthRed = new Measure(wavelengths[2], -9);
|
|
121
|
+
const energies = {
|
|
122
|
+
bleue: h.times(c).divide(wavelengthBlue).toSignificant(2),
|
|
123
|
+
verte: h.times(c).divide(wavelengthGreen).toSignificant(2),
|
|
124
|
+
rouge: h.times(c).divide(wavelengthRed).toSignificant(2),
|
|
125
|
+
};
|
|
126
|
+
const energy = energies[targetColor];
|
|
87
127
|
const incorrectValues = [
|
|
88
128
|
new Measure(randfloat(0.1, 10, 2), -19).toSignificant(2),
|
|
89
129
|
energy.times(new Measure(1, -8)),
|
|
@@ -97,11 +137,14 @@ const getPropositions = (n, { answer, energy }) => {
|
|
|
97
137
|
}
|
|
98
138
|
return shuffleProps(propositions, n);
|
|
99
139
|
};
|
|
100
|
-
const isAnswerValid = (ans, { answer,
|
|
140
|
+
const isAnswerValid = (ans, { answer, wavelengths, targetColor }) => {
|
|
141
|
+
const wavelengthBlue = new Measure(wavelengths[0], -9);
|
|
142
|
+
const wavelengthGreen = new Measure(wavelengths[1], -9);
|
|
143
|
+
const wavelengthRed = new Measure(wavelengths[2], -9);
|
|
101
144
|
const energies = {
|
|
102
|
-
bleue: h.times(c).divide(
|
|
103
|
-
verte: h.times(c).divide(
|
|
104
|
-
rouge: h.times(c).divide(
|
|
145
|
+
bleue: h.times(c).divide(wavelengthBlue).toSignificant(2),
|
|
146
|
+
verte: h.times(c).divide(wavelengthGreen).toSignificant(2),
|
|
147
|
+
rouge: h.times(c).divide(wavelengthRed).toSignificant(2),
|
|
105
148
|
};
|
|
106
149
|
const targetEnergy = energies[targetColor];
|
|
107
150
|
const validAnswer1 = targetEnergy.toSignificant(1).toTex();
|
|
@@ -114,9 +157,7 @@ const isAnswerValid = (ans, { answer, energy, wavelengths, targetColor }) => {
|
|
|
114
157
|
export const SpectralEnergyExercise = {
|
|
115
158
|
id: "spectralEnergy",
|
|
116
159
|
label: "Calculer l'énergie d'une lumière à partir de la longueur d'onde",
|
|
117
|
-
levels: ["TermSpé"],
|
|
118
160
|
isSingleStep: true,
|
|
119
|
-
sections: ["Quantique"],
|
|
120
161
|
generator: (nb) => getDistinctQuestions(getSpectralEnergyQuestion, nb),
|
|
121
162
|
qcmTimer: 60,
|
|
122
163
|
freeTimer: 60,
|
|
@@ -124,4 +165,5 @@ export const SpectralEnergyExercise = {
|
|
|
124
165
|
isAnswerValid,
|
|
125
166
|
subject: "Physique",
|
|
126
167
|
hasHintAndCorrection: true,
|
|
168
|
+
getQuestionFromIdentifiers,
|
|
127
169
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"findDistanceFromEarth.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/findDistanceFromEarth.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"findDistanceFromEarth.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/findDistanceFromEarth.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAYT,MAAM,6BAA6B,CAAC;AAUrC,KAAK,WAAW,GAAG;IACjB,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AAuFF,eAAO,MAAM,qBAAqB,EAAE,QAAQ,CAAC,WAAW,CAYvD,CAAC"}
|
|
@@ -4,25 +4,39 @@ import { Decimal } from "../../../math/numbers/decimals/decimal.js";
|
|
|
4
4
|
import { randfloat } from "../../../math/utils/random/randfloat.js";
|
|
5
5
|
import { randint } from "../../../math/utils/random/randint.js";
|
|
6
6
|
import { round } from "../../../math/utils/round.js";
|
|
7
|
-
const
|
|
8
|
-
const lightYear =
|
|
7
|
+
const getInstruction = (identifiers) => {
|
|
8
|
+
const { lightYear } = identifiers;
|
|
9
|
+
return `Une planète se trouve à $${lightYear.frenchify()}$ années-lumières de nous.
|
|
10
|
+
|
|
11
|
+
Calculer à quelle distance de la Terre se trouve la planète en mètres (en écriture scientifique avec $2$ chiffres significatifs).
|
|
12
|
+
`;
|
|
13
|
+
};
|
|
14
|
+
const getAnswer = (identifiers) => {
|
|
15
|
+
const { lightYear } = identifiers;
|
|
9
16
|
const speed = 300000000;
|
|
10
17
|
const secondsInAYear = 365.25 * 24 * 3600;
|
|
11
18
|
const lightDistanceTravelled = speed * secondsInAYear;
|
|
12
19
|
const lightDistanceTravelledDecimal = new Decimal(lightDistanceTravelled);
|
|
13
20
|
const lightDistanceTravelledDecimalScientificNotation = lightDistanceTravelledDecimal.toScientificNotation(1);
|
|
14
21
|
const distanceFromEarth = lightYear * lightDistanceTravelledDecimalScientificNotation.evaluate({});
|
|
15
|
-
|
|
22
|
+
return `${distanceFromEarth.toScientific(1).toTex({ scientific: 1 })}`;
|
|
23
|
+
};
|
|
24
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
16
25
|
const question = {
|
|
17
|
-
answer:
|
|
18
|
-
instruction:
|
|
19
|
-
`,
|
|
26
|
+
answer: getAnswer(identifiers),
|
|
27
|
+
instruction: getInstruction(identifiers),
|
|
20
28
|
keys: ["timesTenPower"],
|
|
21
29
|
answerFormat: "tex",
|
|
22
|
-
identifiers
|
|
30
|
+
identifiers,
|
|
23
31
|
};
|
|
24
32
|
return question;
|
|
25
33
|
};
|
|
34
|
+
const getFindDistanceFromEarthQuestion = () => {
|
|
35
|
+
const lightYear = round(randfloat(4.2, 50), 1);
|
|
36
|
+
// Aide : Passer par la distance parcourue par la lumière en une année. L'année-lumière est la distance parcourue par la lumière dans le vide en une année.
|
|
37
|
+
const identifiers = { lightYear };
|
|
38
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
39
|
+
};
|
|
26
40
|
const getPropositions = (n, { answer, lightYear }) => {
|
|
27
41
|
const propositions = [];
|
|
28
42
|
addValidProp(propositions, answer);
|
|
@@ -51,13 +65,12 @@ const isAnswerValid = (ans, { answer }) => {
|
|
|
51
65
|
export const findDistanceFromEarth = {
|
|
52
66
|
id: "findDistanceFromEarth",
|
|
53
67
|
label: "Calculer la distance d'une planète à la Terre",
|
|
54
|
-
levels: ["2nde"],
|
|
55
68
|
isSingleStep: true,
|
|
56
|
-
sections: ["Ondes"],
|
|
57
69
|
generator: (nb) => getDistinctQuestions(getFindDistanceFromEarthQuestion, nb),
|
|
58
70
|
qcmTimer: 60,
|
|
59
71
|
freeTimer: 60,
|
|
60
72
|
getPropositions,
|
|
61
73
|
isAnswerValid,
|
|
62
74
|
subject: "Physique",
|
|
75
|
+
getQuestionFromIdentifiers,
|
|
63
76
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"lightDistanceConversion.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/lightDistanceConversion.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"lightDistanceConversion.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/lightDistanceConversion.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,6BAA6B,CAAC;AAMrC,OAAO,EAAE,OAAO,EAAE,MAAM,6BAA6B,CAAC;AAGtD,KAAK,WAAW,GAAG;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,cAAc,EAAE,OAAO,CAAC;IACxB,mBAAmB,EAAE,OAAO,CAAC;CAC9B,CAAC;AA8MF,eAAO,MAAM,uBAAuB,EAAE,QAAQ,CAAC,WAAW,CAazD,CAAC"}
|
|
@@ -5,112 +5,141 @@ import { randint } from "../../../math/utils/random/randint.js";
|
|
|
5
5
|
import { lightSpeed } from "../../../pc/constants/mechanics/waves.js";
|
|
6
6
|
import { Measure } from "../../../pc/measure/measure.js";
|
|
7
7
|
import { coinFlip } from "../../../utils/alea/coinFlip.js";
|
|
8
|
-
const
|
|
9
|
-
const lightYear
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
const getInstruction = (identifiers) => {
|
|
9
|
+
const { lightYear, distanceMeters, isLightYearToMeters } = identifiers;
|
|
10
|
+
return isLightYearToMeters
|
|
11
|
+
? `Une planète se trouve à $${lightYear.frenchify()}$ années-lumières de nous.
|
|
12
|
+
|
|
13
|
+
Calculer à quelle distance de la Terre se trouve la planète en mètres (en écriture scientifique avec $2$ chiffres significatifs).`
|
|
14
|
+
: `Une planète se trouve à $${distanceMeters
|
|
15
|
+
.toSignificant(2)
|
|
16
|
+
.toTex()}\\ \\textrm{m}$ de nous.
|
|
17
|
+
|
|
18
|
+
Calculer à quelle distance en années-lumières se trouve la planète de la Terre (en écriture scientifique avec $2$ chiffres significatifs).`;
|
|
19
|
+
};
|
|
20
|
+
const getAnswer = (identifiers) => {
|
|
21
|
+
const { lightYear, distanceMeters, isLightYearToMeters } = identifiers;
|
|
15
22
|
const answer = isLightYearToMeters
|
|
16
|
-
?
|
|
23
|
+
? distanceMeters.toSignificant(2).toTex()
|
|
17
24
|
: lightYear.toScientific(2).toTex();
|
|
25
|
+
return answer;
|
|
26
|
+
};
|
|
27
|
+
const getHint = (identifiers) => {
|
|
28
|
+
const { lightYear, distanceMeters, isLightYearToMeters } = identifiers;
|
|
18
29
|
const hint = isLightYearToMeters
|
|
19
30
|
? `Pour convertir des années-lumière en mètres, utilisez les relations suivantes :
|
|
20
|
-
- Une année-lumière est la distance parcourue par la lumière en une année.
|
|
21
|
-
- La vitesse de la lumière est $c = 3 \\times 10^8 \\text{ m/s}$.
|
|
22
|
-
- Il y a $365.25 \\text{ jours} \\times 24 \\text{ heures/jour} \\times 3600 \\text{ secondes/heure}$ secondes dans une année (Le 0.25 compte pour la moyenne sur quatres années dont une bissextile).
|
|
23
|
-
|
|
24
|
-
La distance parcourue par la lumière en une année est :
|
|
25
|
-
$$
|
|
26
|
-
c \\times \\text{secondes par année}
|
|
27
|
-
$$
|
|
28
31
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
- La vitesse de la lumière est $c = 3 \\times 10^8 \\text{ m/s}$.
|
|
33
|
-
- Il y a $365.25 \\text{ jours} \\times 24 \\text{ heures/jour} \\times 3600 \\text{ secondes/heure}$ secondes dans une année (Le 0.25 compte pour la moyenne sur quatres années dont une bissextile).
|
|
32
|
+
- Une année-lumière est la distance parcourue par la lumière en une année.
|
|
33
|
+
- La vitesse de la lumière est $c = 3 \\times 10^8 \\ \\textrm{m}/\\textrm{s}$.
|
|
34
|
+
- Il y a $365,25 \\text{jours} \\times 24 \\text{heures/jour} \\times 3600 \\text{ secondes/heure}$ secondes dans une année (le $0,25$ compte pour la moyenne sur quatres années dont une bissextile).
|
|
34
35
|
|
|
35
|
-
|
|
36
|
+
La distance parcourue par la lumière en une année est :
|
|
37
|
+
|
|
38
|
+
$$
|
|
39
|
+
c \\times \\text{secondes par année}
|
|
40
|
+
$$
|
|
36
41
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
$$
|
|
42
|
+
Pour convertir des années-lumière en mètres, multipliez la distance en années-lumière par la distance parcourue par la lumière en une année.`
|
|
43
|
+
: `Pour convertir une distance en mètres en années-lumières, utilisez les relations suivantes :
|
|
40
44
|
|
|
41
|
-
|
|
45
|
+
- Une année-lumière est la distance parcourue par la lumière en une année.
|
|
46
|
+
- La vitesse de la lumière est $c = 3 \\times 10^8 \\textrm{m/s}$.
|
|
47
|
+
- Il y a $365,25 \\text{ jours} \\times 24 \\text{heures/jour} \\times 3600 \\text{ secondes/heure}$ secondes dans une année (Le $0,25$ compte pour la moyenne sur quatres années dont une bissextile).
|
|
48
|
+
|
|
49
|
+
La distance parcourue par la lumière en une année est :
|
|
50
|
+
|
|
51
|
+
$$
|
|
52
|
+
c \\times \\text{secondes par année}
|
|
53
|
+
$$
|
|
54
|
+
|
|
55
|
+
Pour convertir des mètres en années-lumière, divisez la distance en mètres par la distance parcourue par la lumière en une année.`;
|
|
56
|
+
return hint;
|
|
57
|
+
};
|
|
58
|
+
const getCorrection = (identifiers) => {
|
|
59
|
+
const { lightYear, distanceMeters, isLightYearToMeters } = identifiers;
|
|
42
60
|
const correction = isLightYearToMeters
|
|
43
61
|
? `La distance parcourue par la lumière en une année est donnée par :
|
|
44
|
-
|
|
45
|
-
$$
|
|
46
|
-
c \\times \\text{secondes par année} = 3 \\times 10^8 \\text{ m/s} \\times 365.25 \\times 24 \\times 3600 \\text{ s}
|
|
47
|
-
$$
|
|
48
62
|
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
3 \\times 10^8 \\text{ m/s} \\times 31,557,600 \\text{ s} = 9.46728 \\times 10^{15} \\text{ m}
|
|
53
|
-
$$
|
|
63
|
+
$$
|
|
64
|
+
c \\times \\text{secondes par année} = 3 \\times 10^8 \\text{ m/s} \\times 365.25 \\times 24 \\times 3600 \\text{ s}
|
|
65
|
+
$$
|
|
54
66
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
67
|
+
En simplifiant, nous obtenons :
|
|
68
|
+
|
|
69
|
+
$$
|
|
70
|
+
3 \\times 10^8 \\text{ m/s} \\times 31,557,600 \\text{ s} = 9.46728 \\times 10^{15} \\text{ m}
|
|
71
|
+
$$
|
|
72
|
+
|
|
73
|
+
Pour convertir des années-lumière en mètres, nous utilisons la relation suivante :
|
|
60
74
|
|
|
61
|
-
|
|
75
|
+
$$
|
|
76
|
+
\\text{distance en années-lumière} \\times 9.46728 \\times 10^{15} \\text{ m}
|
|
77
|
+
$$
|
|
62
78
|
|
|
63
|
-
|
|
64
|
-
|
|
79
|
+
En appliquant cette relation avec la valeur donnée de $${lightYear}$ années-lumière, nous obtenons :
|
|
80
|
+
|
|
81
|
+
$$
|
|
82
|
+
\\text{distance en mètres} = ${lightYear} \\times 9.46728 \\times 10^{15} = ${distanceMeters
|
|
65
83
|
.toSignificant(2)
|
|
66
84
|
.toTex()} \\text{ m}
|
|
67
|
-
|
|
85
|
+
$$`
|
|
68
86
|
: `La distance parcourue par la lumière en une année est donnée par :
|
|
69
|
-
|
|
70
|
-
$$
|
|
71
|
-
c \\times \\text{secondes par année} = 3 \\times 10^8 \\text{ m/s} \\times 365.25 \\times 24 \\times 3600 \\text{ s}
|
|
72
|
-
$$
|
|
73
87
|
|
|
74
|
-
|
|
88
|
+
$$
|
|
89
|
+
c \\times \\text{secondes par année} = 3 \\times 10^8 \\text{ m/s} \\times 365.25 \\times 24 \\times 3600 \\text{ s}
|
|
90
|
+
$$
|
|
75
91
|
|
|
76
|
-
|
|
77
|
-
3 \\times 10^8 \\text{ m/s} \\times 31,557,600 \\text{ s} = 9.46728 \\times 10^{15} \\text{ m}
|
|
78
|
-
$$
|
|
92
|
+
En simplifiant, nous obtenons :
|
|
79
93
|
|
|
80
|
-
|
|
94
|
+
$$
|
|
95
|
+
3 \\times 10^8 \\text{ m/s} \\times 31,557,600 \\text{ s} = 9.46728 \\times 10^{15} \\text{ m}
|
|
96
|
+
$$
|
|
81
97
|
|
|
82
|
-
|
|
83
|
-
\\frac{\\text{distance en mètres}}{9.46728 \\times 10^{15} \\text{ m}}
|
|
84
|
-
$$
|
|
98
|
+
Pour convertir des mètres en années-lumière, nous utilisons la relation suivante :
|
|
85
99
|
|
|
86
|
-
|
|
100
|
+
$$
|
|
101
|
+
\\frac{\\text{distance en mètres}}{9.46728 \\times 10^{15} \\text{ m}}
|
|
102
|
+
$$
|
|
103
|
+
|
|
104
|
+
En appliquant cette relation avec la valeur donnée de $${distanceMeters
|
|
87
105
|
.toSignificant(2)
|
|
88
106
|
.toTex()} \\text{m}$, nous obtenons :
|
|
89
107
|
|
|
90
|
-
|
|
91
|
-
|
|
108
|
+
$$
|
|
109
|
+
\\frac{${distanceMeters
|
|
92
110
|
.toSignificant(2)
|
|
93
|
-
.toTex()}}{9.46728 \\times 10^{15}} = ${lightYear
|
|
94
|
-
|
|
111
|
+
.toTex()}}{9.46728 \\times 10^{15}} = ${lightYear
|
|
112
|
+
.toScientific(2)
|
|
113
|
+
.toTex()}
|
|
114
|
+
$$`;
|
|
115
|
+
return correction;
|
|
116
|
+
};
|
|
117
|
+
const getQuestionFromIdentifiers = (identifiers) => {
|
|
95
118
|
const question = {
|
|
96
|
-
answer:
|
|
97
|
-
instruction:
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
.toSignificant(2)
|
|
101
|
-
.toTex()}\\ \\text{m}$ de nous. Calculer à quelle distance en années-lumières se trouve la planète de la Terre (en écriture scientifique avec 2 chiffres significatifs).`,
|
|
102
|
-
hint,
|
|
103
|
-
correction,
|
|
119
|
+
answer: getAnswer(identifiers),
|
|
120
|
+
instruction: getInstruction(identifiers),
|
|
121
|
+
hint: getHint(identifiers),
|
|
122
|
+
correction: getCorrection(identifiers),
|
|
104
123
|
keys: ["timesTenPower"],
|
|
105
124
|
answerFormat: "tex",
|
|
106
|
-
identifiers
|
|
107
|
-
lightYear,
|
|
108
|
-
distanceMeters: distanceFromEarthMeters,
|
|
109
|
-
isLightYearToMeters,
|
|
110
|
-
},
|
|
125
|
+
identifiers,
|
|
111
126
|
};
|
|
112
127
|
return question;
|
|
113
128
|
};
|
|
129
|
+
const getLightDistanceConversionQuestion = () => {
|
|
130
|
+
const lightYear = randfloat(10, 1000, 2);
|
|
131
|
+
const speed = lightSpeed.measure;
|
|
132
|
+
const secondsInAYear = 365.25 * 24 * 3600;
|
|
133
|
+
const lightDistanceTravelled = speed.times(secondsInAYear);
|
|
134
|
+
const distanceFromEarthMeters = lightDistanceTravelled.times(lightYear);
|
|
135
|
+
const isLightYearToMeters = coinFlip();
|
|
136
|
+
const identifiers = {
|
|
137
|
+
lightYear,
|
|
138
|
+
distanceMeters: distanceFromEarthMeters,
|
|
139
|
+
isLightYearToMeters,
|
|
140
|
+
};
|
|
141
|
+
return getQuestionFromIdentifiers(identifiers);
|
|
142
|
+
};
|
|
114
143
|
const getPropositions = (n, { answer, lightYear, distanceMeters, isLightYearToMeters }) => {
|
|
115
144
|
const propositions = [];
|
|
116
145
|
addValidProp(propositions, answer);
|
|
@@ -154,9 +183,7 @@ const isAnswerValid = (ans, { answer, lightYear, distanceMeters, isLightYearToMe
|
|
|
154
183
|
export const lightDistanceConversion = {
|
|
155
184
|
id: "lightDistanceConversion",
|
|
156
185
|
label: "Conversion entre années-lumière et distance en mètres",
|
|
157
|
-
levels: ["2nde"],
|
|
158
186
|
isSingleStep: true,
|
|
159
|
-
sections: ["Ondes"],
|
|
160
187
|
generator: (nb) => getDistinctQuestions(getLightDistanceConversionQuestion, nb),
|
|
161
188
|
qcmTimer: 60,
|
|
162
189
|
freeTimer: 60,
|
|
@@ -164,4 +191,5 @@ export const lightDistanceConversion = {
|
|
|
164
191
|
isAnswerValid,
|
|
165
192
|
subject: "Physique",
|
|
166
193
|
hasHintAndCorrection: true,
|
|
194
|
+
getQuestionFromIdentifiers,
|
|
167
195
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"periodicWaveCelerity.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/periodicWaveCelerity.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,
|
|
1
|
+
{"version":3,"file":"periodicWaveCelerity.d.ts","sourceRoot":"","sources":["../../../../src/exercises/pc/waves/periodicWaveCelerity.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,QAAQ,EAcT,MAAM,6BAA6B,CAAC;AAMrC,KAAK,WAAW,GAAG;IACjB,QAAQ,EAAE,MAAM,CAAC;IACjB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;CACX,CAAC;AA2KF,eAAO,MAAM,oBAAoB,EAAE,QAAQ,CAAC,WAAW,CActD,CAAC"}
|