File: /home/mmtprep/public_html/mathzen.mmtprep.com/assets/3L13-4-IIhynmrN.js
import{E as k}from"./Exercice-FKaS4mj7.js";import{c as S,l as G}from"./index-XCg2QAX4.js";import{a as P,t as q,b as L,r as Q,c as v,d as u}from"./outilsMathjs-KwNosraq.js";import{G as V,n as h}from"./GraphicView-eiBEBpR6.js";import{c as O,a as R}from"./create-9DBTQ71r.js";const b=O(R);b.config({number:"number",randomSeed:S.graine});const E="Find perimeter or area by solving an equation",U="04/03/2022",W="cd2f2",X="3L13-4";class Y extends k{constructor(){super(),this.titre=E,this.nbQuestions=2,this.correctionDetailleeDisponible=!0,this.correctionDetaillee=!1,this.besoinFormulaire2Numerique=["Types of values in the equation",2,`1 - Positive integers
2 - Relative integers`]}nouvelleVersion(){this.listeQuestions=[],this.listeCorrections=[],this.autoCorrection=[];for(let A=0,y=0,g={};A<this.nbQuestions&&y<50;){switch(this.nbQuestions%2===0?A%2+1:Math.floor(Math.random()*2)+1){case 1:{const e=new V(0,0,7,5),s=e.addRectangle(),[o,r,i,d]=s.vertices,F=e.addAnglesPolygon(o,r,i,d),t=e.addSegment(o,r);t.direct=e.addAngle(o,r,i).direct;const n=e.addSegment(r,i);n.direct=t.direct;const m=e.addSegment(i,d),T=e.addSegment(d,o),a=P({a:this.sup2!==1,c:this.sup2!==1,x:this.sup2!==1,AB:(10*e.distance(o,r)).toFixed(0),BC:(10*e.distance(r,i)).toFixed(0),b:"AB-a*x",d:"BC-c*x",p:"2*(a*x+b+c*x+d)",test:"a*x+b>0 and c*x+d>0 and a!=c"});delete a.x;const $=q(L("a*x+b",a)),c=q(L("c*x+d",a));t.text=S.isHtml?`${$}`.replaceAll("*",""):`$${$}$`.replaceAll("*",""),n.text=S.isHtml?`${c}`.replaceAll("*",""):`$${c}$`.replaceAll("*","");const p=a.p,w=e.getFigure(s,t,n,...F.map(B=>(B.right=!0,B))),f=Q(`${p}=2*(${$}) + 2*(${c})`,{suppr1:!1,substeps:this.correctionDetaillee}),x=v("a*(x)+b".replace("x",f.solution.exact),{name:t.name,suppr1:!1,substeps:this.correctionDetaillee,variables:a}),C=v("c*(x)+d".replace("x",f.solution.exact),{name:n.name,suppr1:!1,substeps:this.correctionDetaillee,variables:a}),D=v(`${x.result}*${C.result}`,{name:"\\mathcal{A}",suppr1:!1,substeps:this.correctionDetaillee,variables:a});let l=b.fraction(D.result.replaceAll(" ","")).valueOf();const H=l===b.round(l,2)?"":"approximately";l=b.round(l,2).toString(),g.texte=h`
$${s}$ is a rectangle.
$x$ is a number such that $ {${t}=${u($)}}$ and $ {${n}=${u(c)}}$ (in $cm$).
The perimeter of $${s}$ measures $${p}~cm$.
Determine its area in $cm^2$.
${w}`,g.texteCorr=h`
$${s}$ is a rectangle so its opposite sides are the same length.
Hence $${t}=${m}$ and $${n}=${T}$.
Thus, $${u(h`${p} = 2*${t} + 2*${n}`)}$.
Or again $${u(`${p} = 2*(${$}) + 2*(${c})`)}$.
$\textbf{Let's solve this equation of unknown $x$}$.
${f.texteCorr}
$\textbf{Let's calculate $${t}$ in cm.}$
${x.texteCorr}
$\textbf{Let's calculate $${n}$ in cm.}$
${C.texteCorr}
$\textbf{Let's calculate the area $\mathcal{A}$ of $${s}$ in $cm^2$.}$
${D.texteCorr}
So the area of rectangle $${s}$ is ${H} $${u(l)}~cm^2$. `;break}default:{const e=new V(0,0,7,5),s=e.addRectangle(),[o,r,i,d]=s.vertices,F=e.addAnglesPolygon(o,r,i,d),t=e.addSegment(o,r);t.direct=e.addAngle(o,r,i).direct;const n=e.addSegment(r,i),m=e.addSegment(i,d);m.direct=t.direct;const T=e.addSegment(d,o),a=P({c:this.sup2!==1,x:this.sup2!==1,a:this.sup2!==1,AB:(10*e.distance(o,r)).toFixed(0),BC:(10*e.distance(r,i)).toFixed(0),b:"AB-a*x",d:"AB-c*x",p:"2*(AB+BC)",test:"a!=c and a*x+b>0"});delete a.x;const $=q(L("a*x+b",a)),c=q(L("c*x+d",a));t.text=S.isHtml?`${$}`.replaceAll("*",""):`$${$}$`.replaceAll("*",""),m.text=S.isHtml?`${c}`.replaceAll("*",""):`$${c}$`.replaceAll("*","");const p=a.p,w=e.getFigure(s,t,m,...F.map(B=>(B.right=!0,B))),f=Q(`${$}=${c}`,{suppr1:!1,substeps:this.correctionDetaillee}),x=v("a*(x)+b".replace("x",f.solution.exact),{name:t.name,suppr1:!1,substeps:this.correctionDetaillee,variables:a}),C=Q(h`${p} = 2*${x.result} + 2*${n}`,{suppr1:!1,substeps:this.correctionDetaillee}),D=v(`${x.result}*${C.solution.exact}`,{name:"\\mathcal{A}",suppr1:!1,substeps:this.correctionDetaillee,variables:a});let l=b.fraction(D.result.replaceAll(" ","")).valueOf();const H=l===b.round(l,2)?"":"environ";l=b.round(l,2).toString(),g.texte=h`$${s}$ is a rectangle.
$x$ is a number such that $ {${t}=${u($)}}$ and $ {${m}=${u(c)}}$ (in $cm$) .
The perimeter of $${s}$ measures $${p}~cm$.
Determine its area in $cm^2$.
${w}`,g.texteCorr=h`$${s}$ is a rectangle so its opposite sides are the same length.
Hence $${t}=${m}$ and $${n}=${T}$.
So $${u(`${$}=${c}`)}$.
$\textbf{Let's solve the equation.}$
${f.texteCorr}
$\textbf{Let's calculate $${t}$ in cm}.$
${x.texteCorr}
Thus, $${u(h`${p} = 2* (${x.result}) + 2* ${n}`)}$.
$\textbf{Let's solve this equation of unknown $${n}$}$.
${C.texteCorr}
$\textbf{Let's calculate the area $\mathcal{A}$ of $${s}$ in $cm^2$.}$
${D.texteCorr}
So the area of rectangle $${s}$ is ${H} $${u(l)}~cm^2$.`;break}}this.questionJamaisPosee(A,A)&&(this.listeQuestions.push(g.texte.replaceAll(`
`,"<br>")),this.listeCorrections.push(g.texteCorr.replaceAll(`
`,"<br>")),A++),y++}G(this)}}export{U as dateDePublication,Y as default,b as math,X as ref,E as titre,W as uuid};
//# sourceMappingURL=3L13-4-IIhynmrN.js.map