// Numbas version: exam_results_page_options {"name": "MATH6058 Pythagoras' Theorem and naming sides of right angled triangle", "extensions": [], "custom_part_types": [], "resources": [["question-resources/Q2_0UOrG2O.png", "/srv/numbas/media/question-resources/Q2_0UOrG2O.png"]], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"variablesTest": {"maxRuns": 100, "condition": ""}, "name": "MATH6058 Pythagoras' Theorem and naming sides of right angled triangle", "variables": {"l21": {"templateType": "anything", "name": "l21", "group": "Ungrouped variables", "definition": "random(30..45)", "description": ""}, "ans2": {"templateType": "anything", "name": "ans2", "group": "Ungrouped variables", "definition": "sqrt(l21^2-l22^2)", "description": ""}, "ans3": {"templateType": "anything", "name": "ans3", "group": "Ungrouped variables", "definition": "sqrt(l32^2-l31^2)", "description": ""}, "lent2": {"templateType": "anything", "name": "lent2", "group": "Ungrouped variables", "definition": "random(45..60)", "description": ""}, "l32": {"templateType": "anything", "name": "l32", "group": "Ungrouped variables", "definition": "random(60..70)", "description": ""}, "ans1": {"templateType": "anything", "name": "ans1", "group": "Ungrouped variables", "definition": "sqrt(lent1^2+lent2^2)", "description": ""}, "lent1": {"templateType": "anything", "name": "lent1", "group": "Ungrouped variables", "definition": "random(25..35)", "description": ""}, "ang2": {"templateType": "anything", "name": "ang2", "group": "Ungrouped variables", "definition": "random(48..65)", "description": ""}, "l31": {"templateType": "anything", "name": "l31", "group": "Ungrouped variables", "definition": "random(30.5..45.5)", "description": ""}, "ang1": {"templateType": "anything", "name": "ang1", "group": "Ungrouped variables", "definition": "random(63..65)", "description": ""}, "l22": {"templateType": "anything", "name": "l22", "group": "Ungrouped variables", "definition": "random(12..18)", "description": ""}, "l33": {"templateType": "anything", "name": "l33", "group": "Ungrouped variables", "definition": "random(40..50)", "description": ""}, "l23": {"templateType": "anything", "name": "l23", "group": "Ungrouped variables", "definition": "random(9..15)", "description": ""}}, "preamble": {"css": "", "js": ""}, "parts": [{"prompt": "

Write the name of each side in the correct box:

\n

Note: The bottom right angle is a right angle (90$^{\\circ}$).

\n

{tri(30,45,56)}

\n

x = [[0]]

\n

y = [[1]]

\n

z = [[2]]

", "variableReplacementStrategy": "originalfirst", "gaps": [{"answer": "Opposite", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Hypotenuse", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Adjacent", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}], "variableReplacements": [], "marks": 0, "steps": [{"prompt": "

The hypotenuse is the side across from the right angle.

\n

The line touching the important angle is called it's adjacent line.

\n

The line opposite the important angle is called it's opposite line.

", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "marks": 0, "scripts": {}, "type": "information", "showCorrectAnswer": true}], "scripts": {}, "type": "gapfill", "showCorrectAnswer": true, "stepsPenalty": 0}, {"prompt": "

Write the name of each side in the correct box:

\n

Note: The bottom left angle is a right angle (90$^{\\circ}$).

\n

{tri2(25,19,16,48)}

\n

x = [[0]]

\n

y = [[1]]

\n

z = [[2]]

", "variableReplacementStrategy": "originalfirst", "gaps": [{"answer": "Opposite", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Adjacent", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Hypotenuse", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}, {"prompt": "

Write the name of each side in the correct box:

\n

Note: The bottom left angle is a right angle (90$^{\\circ}$).

\n

{tri3(10,33,73)}

\n

x = [[0]]

\n

y = [[1]]

\n

z = [[2]]

", "variableReplacementStrategy": "originalfirst", "gaps": [{"answer": "Hypotenuse", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Adjacent", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Opposite", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}, {"prompt": "

Write the name of each side in the correct box:

\n

Note: The top right angle is a right angle (90$^{\\circ}$).

\n

{tri4(60,78,48)}

\n

x = [[0]]

\n

y = [[1]]

\n

z = [[2]]

", "variableReplacementStrategy": "originalfirst", "gaps": [{"answer": "Adjacent", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Opposite", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}, {"answer": "Hypotenuse", "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "expectedvariablenames": [], "checkingtype": "absdiff", "scripts": {}, "showCorrectAnswer": true, "checkvariablenames": false, "vsetrangepoints": 5, "checkingaccuracy": 0.001, "marks": 1, "vsetrange": [0, 1], "type": "jme", "showpreview": true}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}, {"prompt": "

Find the value of x:

\n

Note: The bottom right angle is a right angle (90$^{\\circ}$).

\n

{tri5(lent1,lent2,ang1)}

\n

x = [[0]] mm

", "variableReplacementStrategy": "originalfirst", "gaps": [{"allowFractions": false, "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "minValue": "{ans1}", "scripts": {}, "showCorrectAnswer": true, "showPrecisionHint": false, "marks": 1, "precisionMessage": "You have not given your answer to the correct precision.", "correctAnswerFraction": false, "precision": "2", "precisionType": "dp", "strictPrecision": false, "type": "numberentry", "precisionPartialCredit": 0, "maxValue": "{ans1}"}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}, {"prompt": "

Find the value of x:

\n

Note: The bottom left angle is a right angle (90$^{\\circ}$).

\n

{tri6(l21,l22,l23,ang2)}

\n

x = [[0]] mm

", "variableReplacementStrategy": "originalfirst", "gaps": [{"allowFractions": false, "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "minValue": "{ans2}", "scripts": {}, "showCorrectAnswer": true, "showPrecisionHint": false, "marks": 1, "precisionMessage": "You have not given your answer to the correct precision.", "correctAnswerFraction": false, "precision": "2", "precisionType": "dp", "strictPrecision": false, "type": "numberentry", "precisionPartialCredit": 0, "maxValue": "{ans2}"}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}, {"prompt": "

Find the value of x:

\n

Note: The bottom left angle is a right angle (90$^{\\circ}$).

\n

{tri7(l31,l32,l33)}

\n

x = [[0]] mm

", "variableReplacementStrategy": "originalfirst", "gaps": [{"allowFractions": false, "variableReplacementStrategy": "originalfirst", "variableReplacements": [], "minValue": "{ans3}", "scripts": {}, "showCorrectAnswer": true, "showPrecisionHint": false, "marks": 1, "precisionMessage": "You have not given your answer to the correct precision.", "correctAnswerFraction": false, "precision": "2", "precisionType": "dp", "strictPrecision": false, "type": "numberentry", "precisionPartialCredit": 0, "maxValue": "{ans3}"}], "variableReplacements": [], "marks": 0, "scripts": {}, "type": "gapfill", "showCorrectAnswer": true}], "functions": {"tri": {"parameters": [["x", "number"], ["y", "number"], ["z", "number"]], "definition": "\nvar c = document.createElement('canvas');\n $(c).attr('width',700).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,800);\n context.lineTo((x*8+300),800);\n context.lineTo((x*8+300),(800-(y*8)));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Z';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/2)),820);\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'X';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(320+((8*x))),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Y';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(280+((8*x)/2)),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,315,790);\n\n \n return c;\n ", "language": "javascript", "type": "html"}, "tri7": {"parameters": [["x", "number"], ["x1", "number"], ["y", "number"]], "definition": "\nvar c = document.createElement('canvas');\n $(c).attr('width',900).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,(800-(y*8)));\n context.lineTo((x*8+300),800-(y*8));\n context.lineTo((x*8+300),(800));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'X';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/2)),790-(y*8));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = x1 + 'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/8)),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/8)),(820-((y*8))));\n\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = x+'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(310+((8*x))),(800-((y*8)/2)));\n\n \n\n return c;\n ", "language": "javascript", "type": "html"}, "tri2": {"parameters": [["a", "number"], ["b", "number"], ["c", "number"], ["d", "number"]], "definition": "x=b\ny=c\n\nvar c = document.createElement('canvas');\n $(c).attr('width',900).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,800);\n context.lineTo((x*12+300),800);\n context.lineTo((300),(800-(y*12)));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Z';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((12*x)/2)),(800-((y*12)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'x';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((12*x)/2)),820);\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'y';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,280,(800-((y*12)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,305,(840-(y*12)));\n\n \n\n return c;\n ", "language": "javascript", "type": "html"}, "tri6": {"parameters": [["a", "number"], ["b", "number"], ["c", "number"], ["d", "number"]], "definition": "x=b\ny=c\n\nvar c = document.createElement('canvas');\n $(c).attr('width',900).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,800);\n context.lineTo((x*12+300),800);\n context.lineTo((300),(800-(y*12)));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = a+'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((12*x)/2)),(800-((y*12)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'X';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((12*x)/2)),820);\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = x+'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,240,(800-((y*12)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,305,(840-(y*12)));\n\n \n\n return c;\n ", "language": "javascript", "type": "html"}, "tri4": {"parameters": [["x", "number"], ["x1", "number"], ["y", "number"]], "definition": "\nvar c = document.createElement('canvas');\n $(c).attr('width',900).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,(800-(y*8)));\n context.lineTo((x*8+300),800-(y*8));\n context.lineTo((x*8+300),(800));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'X';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/2)),790-(y*8));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Z';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(400+((8*x)/8)),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/8)),(820-((y*8))));\n\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Y';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(310+((8*x))),(800-((y*8)/2)));\n\n \n\n return c;\n ", "language": "javascript", "type": "html"}, "tri5": {"parameters": [["x", "number"], ["y", "number"], ["z", "number"]], "definition": "var c = document.createElement('canvas');\n $(c).attr('width',700).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,800);\n context.lineTo((x*8+300),800);\n context.lineTo((x*8+300),(800-(y*8)));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = x+'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((8*x)/2)),820);\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = y+'mm';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(320+((8*x))),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'X';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(280+((8*x)/2)),(800-((y*8)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,315,790);\n\n \n return c;", "language": "javascript", "type": "html"}, "tri3": {"parameters": [["x", "number"], ["y", "number"], ["a", "number"]], "definition": "\nvar c = document.createElement('canvas');\n $(c).attr('width',900).attr('height',900);\n var context = c.getContext('2d');\n\n context.beginPath();\n context.moveTo(300,800);\n context.lineTo((x*12+300),800);\n context.lineTo((300),(800-(y*12)));\n context.closePath();\n context.stroke();\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'y';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(300+((12*x)/2)),815);\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'x';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(310+((12*x)/2)),(800-(y*12)/2));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '20px sans-serif';\n var wstring = 'Z';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,270,(800-((y*12)/2)));\n\n //draw labels\n context.fillStyle = '#000';\n context.font = '12px sans-serif';\n var wstring = 'Ang';\n var tw = context.measureText(wstring).width;\n context.fillText(wstring,(250+(x*12)),790);\n\n \n\n return c;\n ", "language": "javascript", "type": "html"}}, "extensions": [], "variable_groups": [], "advice": "

 $x^2 = \\var{lent1}^2 + \\var{lent2}^2$

\n

$x = \\sqrt(\\var{lent1}^2 + \\var{lent2}^2)$

\n

$x = \\var{ans1}$

\n

\n

$\\var{l21}^2 = x^2 + \\var{l22}^2$

\n

$x^2 = \\var{l21}^2 - \\var{l22}^2$

\n

$x = \\sqrt(\\var{l21}^2 - \\var{l22}^2)$

\n

$x = \\var{ans2}$

\n

\n

$\\var{l32}^2 = x^2 + \\var{l31}^2$

\n

$x^2 = \\var{l32}^2 - \\var{l31}^2$

\n

$x = \\sqrt(\\var{l32}^2 - \\var{l31}^2)$

\n

$x = \\var{ans3}$

", "question_groups": [{"questions": [], "name": "", "pickQuestions": 0, "pickingStrategy": "all-ordered"}], "rulesets": {}, "tags": ["rebelmaths"], "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Pythagoras' Theorem and naming sides of right angled triangle

\n

rebelmaths

"}, "ungrouped_variables": ["ang1", "lent1", "ans1", "l21", "ang2", "lent2", "ans2", "l22", "l23", "l31", "l32", "l33", "ans3"], "type": "question", "showQuestionGroupNames": false, "statement": "

Write Adjacent, Opposite or Hypotenuse in the label answer boxes that correspond to the triangle above them, in parts(a - d).

\n

The angle labelled \"ang\" is the important one in each case.

\n

In parts(e - g), find the length of the unknown side using Pythagorass Theorem.

\n

Solve the following mensuration questions to 2 decimal places:

\n

Note: You may need to scroll down to see the diagrams.

", "contributors": [{"name": "Catherine Palmer", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/423/"}]}]}], "contributors": [{"name": "Catherine Palmer", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/423/"}]}