File: /home/mmtprep/public_html/mathzen.mmtprep.com/assets/6G53-2pJLJUJT.js.map
{"version":3,"file":"6G53-2pJLJUJT.js","sources":["../../src/exercices/6e/6G53.js"],"sourcesContent":["import { codageAngleDroit } from '../../lib/2d/angles.js'\nimport { afficheLongueurSegment } from '../../lib/2d/codages.js'\nimport { distancePointDroite, droite } from '../../lib/2d/droites.js'\nimport { point, tracePoint } from '../../lib/2d/points.js'\nimport { polygoneAvecNom } from '../../lib/2d/polygones.js'\nimport { segment } from '../../lib/2d/segmentsVecteurs.js'\nimport { labelPoint } from '../../lib/2d/textes.js'\nimport { projectionOrtho } from '../../lib/2d/transformations.js'\nimport { choisitLettresDifferentes } from '../../lib/outils/aleatoires.js'\nimport { texNombre } from '../../lib/outils/texNombre.js'\nimport Exercice from '../Exercice.js'\nimport { mathalea2d } from '../../modules/2dGeneralites.js'\nimport { listeQuestionsToContenu, randint } from '../../modules/outils.js'\nimport { context } from '../../modules/context.js'\nexport const titre = 'Measure the distance from a point to a line'\n\nexport const dateDePublication = '01/03/2023'\n\n/**\n * Simple exercice de mesure de distance entre un point et une droite\n * @author Guillaume Valmont\n * Référence 6G53\n*/\nexport const uuid = '29c3b'\nexport const ref = '6G53'\nexport default class MesurerDistancePointDroite extends Exercice {\n constructor () {\n super()\n this.titre = titre\n this.nbQuestions = 1\n }\n\n nouvelleVersion () {\n this.listeQuestions = []\n this.listeCorrections = []\n this.autoCorrection = []\n\n for (let i = 0, texte, texteCorr, cpt = 0; i < this.nbQuestions && cpt < 50;) {\n const objetsEnonce = []\n const objetsCorrection = []\n const O = point(0, 0)\n const B = point(randint(-4, 4, [0]), randint(-3, 4, [0]))\n const d = droite(O, B, '(d)')\n let A = point(randint(-4, 4), randint(-3, 4), choisitLettresDifferentes(1, 'OH')[0])\n while (distancePointDroite(A, d) < 1) {\n A = point(randint(-4, 4), randint(-3, 4), choisitLettresDifferentes(1, 'OH')[0])\n }\n const traceA = tracePoint(A)\n traceA.taille = context.isHtml ? 2 : 1\n objetsEnonce.push(traceA, labelPoint(A), d)\n objetsCorrection.push(traceA, d)\n const H = projectionOrtho(A, d, 'H')\n if (A.y > H.y) H.positionLabel = 'below'\n const segmentAH = segment(A, H)\n segmentAH.pointilles = 5\n const AH = polygoneAvecNom(A, H)\n objetsCorrection.push(AH[0], AH[1], afficheLongueurSegment(A, H), codageAngleDroit(A, H, B))\n const xmin = -5\n const xmax = 5\n const ymin = -4\n const ymax = 5\n const paramsEnonce = { xmin, ymin, xmax, ymax, pixelsParCm: 20, scale: 1 }\n texteCorr = '' + mathalea2d(paramsEnonce, objetsCorrection) + '<br>'\n texteCorr += `To measure the distance between the point $${A.nom}$ and the line ($d$) :<br>\n - we use the square to draw the perpendicular to the line ($d$)) which passes through the point $${A.nom}$<br>\n - if we name $${H.nom}$ the foot of the perpendicular, then the distance between the point $${A.nom}$ and the line ($d$) is the length $${A.nom + H.nom} = ${texNombre(distancePointDroite(A, d), 1)} cm$`\n texte = `Measure the distance between the point $${A.nom}$ and the line ($d$).<br>`\n texte += mathalea2d(paramsEnonce, objetsEnonce)\n if (this.questionJamaisPosee(i, A.nom)) {\n this.listeQuestions.push(texte)\n this.listeCorrections.push(texteCorr)\n i++\n }\n cpt++\n }\n listeQuestionsToContenu(this)\n }\n}\n"],"names":["titre","dateDePublication","uuid","ref","MesurerDistancePointDroite","Exercice","texte","texteCorr","cpt","objetsEnonce","objetsCorrection","O","point","B","randint","d","droite","A","choisitLettresDifferentes","distancePointDroite","traceA","tracePoint","context","labelPoint","H","projectionOrtho","segmentAH","segment","AH","polygoneAvecNom","afficheLongueurSegment","codageAngleDroit","paramsEnonce","mathalea2d","texNombre","listeQuestionsToContenu"],"mappings":"kOAcY,MAACA,EAAQ,8CAERC,EAAoB,aAOpBC,EAAO,QACPC,EAAM,OACJ,MAAMC,UAAmCC,CAAS,CAC/D,aAAe,CACb,MAAO,EACP,KAAK,MAAQL,EACb,KAAK,YAAc,CACpB,CAED,iBAAmB,CACjB,KAAK,eAAiB,C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