// Numbas version: finer_feedback_settings {"name": "Write line as y=mx+b", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Write line as y=mx+b", "tags": [], "metadata": {"description": "
Students are given a line equation (where the coefficient of y is 1) and asked to rearrange it into gradient-intercept form.
", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "Write the following line in gradient-intercept form.
\n\n{line}
", "advice": "{line}
\nWe need to rearrange the line so that $+y$ is on one side and $mx$ and $b$ are on the other side.
\n{solution}
\n\nThis gives us $y=\\var{dispm} \\var{dispbwithsign}$.
\nThe gradient is $\\var{m}$ and the $y$-intercept is $\\var{b}$
", "rulesets": {}, "extensions": [], "variables": {"m": {"name": "m", "group": "Ungrouped variables", "definition": "random(-3,-2,-1,1,2,3)", "description": "gradient of the line
", "templateType": "anything"}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-5..5)", "description": "y-intercept of the line
", "templateType": "anything"}, "linetypes": {"name": "linetypes", "group": "Ungrouped variables", "definition": "random(0,5)", "description": "0 represents a homogeneous equation, y - mx - b = 0.
\n1 represents a line y - mx = b.
\n2 represents a line mx + b - y = 0
\n3 represents a line mx - y = b
\n4 represents a line y - b = mx
\n5 represents a line -mx = b - y
\n", "templateType": "anything"}, "lines": {"name": "lines", "group": "Ungrouped variables", "definition": "[\"$y \\\\var{dispminusmwithsign} \\\\var{dispminusbwithsign} = 0$\",\n \"$y \\\\var{dispminusmwithsign} = \\\\var{dispbwith0}$\",\n \"$\\\\var{dispm} \\\\var{dispbwithsign} - y = 0$\",\n \"$\\\\var{dispm} - y = \\\\var{dispminusbwith0} $\",\n \"$y \\\\var{dispminusbwithsign} = \\\\var{dispm}$\",\n \"$\\\\var{dispminusm} = \\\\var{dispb} - y$\"\n]", "description": "0 represents a homogeneous equation, y - mx - b = 0.
\n1 represents a line y - mx = b.
\n2 represents a line mx + b - y = 0
\n3 represents a line mx - y = b
\n4 represents a line y - b = mx
\n5 represents a line -mx = b - y
\n", "templateType": "anything"}, "dispm": {"name": "dispm", "group": "Ungrouped variables", "definition": "if(m=1,'$x$',if(m=-1,'$-x$','$\\\\var{m}x$'))", "description": "", "templateType": "anything"}, "dispb": {"name": "dispb", "group": "Ungrouped variables", "definition": "if(b=0,'',if(b<0,'$\\\\var{b}$','$\\\\var{b}$'))", "description": "", "templateType": "anything"}, "line": {"name": "line", "group": "Ungrouped variables", "definition": "lines[linetypes]", "description": "", "templateType": "anything"}, "dispminusm": {"name": "dispminusm", "group": "Ungrouped variables", "definition": "if(m=-1,'$x$',if(m=1,'$-x$','$\\\\var{m*(-1)}x$'))", "description": "", "templateType": "anything"}, "dispminusb": {"name": "dispminusb", "group": "Ungrouped variables", "definition": "if(b=0,'',if(b>0,'$\\\\var{b}$','$+\\\\var{b*(-1)}$'))", "description": "", "templateType": "anything"}, "dispminusmwithsign": {"name": "dispminusmwithsign", "group": "Ungrouped variables", "definition": "if(m=-1,'$+x$',if(m=1,'$-x$',if (m>0,'$\\\\var{m*(-1)}x$','$+\\\\var{m*(-1)}x$')))", "description": "", "templateType": "anything"}, "dispminusbwithsign": {"name": "dispminusbwithsign", "group": "Ungrouped variables", "definition": "if(b=0,'',if(b>0,'$\\\\var{b*(-1)}$','$+\\\\var{b*(-1)}$'))", "description": "", "templateType": "anything"}, "dispbwithsign": {"name": "dispbwithsign", "group": "Ungrouped variables", "definition": "if(b=0,'',if(b<0,'$\\\\var{b}$','$+\\\\var{b}$'))", "description": "", "templateType": "anything"}, "dispbwith0": {"name": "dispbwith0", "group": "Ungrouped variables", "definition": "if(b=0,'$0$',if(b<0,'$\\\\var{b}$','$\\\\var{b}$'))", "description": "", "templateType": "anything"}, "dispminusbwith0": {"name": "dispminusbwith0", "group": "Ungrouped variables", "definition": "if(b=0,'$0$',if(b>0,'$\\\\var{b*(-1)}$','$\\\\var{b*(-1)}$'))", "description": "", "templateType": "anything"}, "solutions": {"name": "solutions", "group": "Ungrouped variables", "definition": "[\"We need to move $\\\\var{dispminusmwithsign}$ and $\\\\var{dispminusbwith0}$ to the right hand side of the equation, by adding $\\\\var{dispm}$ and $\\\\var{dispbwith0}$ to both sides.\",\n\"We need to move $\\\\var{dispminusmwithsign}$ to the other side of the equation by adding $\\\\var{dispm}$ to both sides.\",\n\"We need to move $-y$ to the other side of the equation by adding $y$ to both sides.\",\n\"We need to move $-y$ to the other side of the equation by adding $y$ to both sides. Then we need to move \\\\var{dispminusbwith0} to the other side of the equation by adding $\\\\var{dispbwith0}$ to both sides.\",\n\"We need to move $\\\\var{dispminusbwith0}$ to the other side of the equation by adding $\\\\var{dispbwith0}$ to both sides.\", \n\"We need to move $-y$ to the other side of the equation by adding $y$ to both sides. Then we need to move $\\\\var{dispminusm}$ to the other side of the equation by adding $\\\\var{dispm}$ to both sides.\"\n]", "description": "[\"$y \\\\var{dispminusmwithsign} \\\\var{dispminusbwithsign} = 0$\",
\"$y \\\\var{dispminusmwithsign} = \\\\var{dispbwith0}$\",
\"$\\\\var{dispm} \\\\var{dispbwithsign} - y = 0$\",
\"$\\\\var{dispm} - y = \\\\var{dispminusbwith0} $\",
\"$y \\\\var{dispminusbwithsign} = \\\\var{dispm}$\",
\"$\\\\var{dispminusm} = \\\\var{dispb} - y$\"
]
$y = $ [[0]] $x + $ [[1]]
", "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "m", "maxValue": "m", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "b", "maxValue": "b", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "What is the gradient?
", "minValue": "m", "maxValue": "m", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "What is the $y$-intercept?
", "minValue": "b", "maxValue": "b", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}]}], "contributors": [{"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}