// Numbas version: exam_results_page_options {"name": "Solve a linear equation $ax+b = cx+d$", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"ungrouped_variables": ["d", "f", "g", "h", "x", "gcd_hfdg", "hf_coprime", "dg_coprime", "finalb"], "parts": [{"variableReplacements": [], "prompt": "

What is the value of $x$?

\n

$x = $ [[0]]

", "variableReplacementStrategy": "originalfirst", "scripts": {}, "gaps": [{"maxValue": "finalb", "correctAnswerStyle": "plain", "variableReplacementStrategy": "originalfirst", "notationStyles": ["plain", "en", "si-en"], "showFeedbackIcon": true, "correctAnswerFraction": false, "marks": "2", "mustBeReduced": false, "minValue": "finalb", "scripts": {}, "mustBeReducedPC": 0, "showCorrectAnswer": true, "variableReplacements": [], "allowFractions": false, "type": "numberentry"}], "showFeedbackIcon": true, "marks": 0, "type": "gapfill", "showCorrectAnswer": true}], "rulesets": {}, "variables": {"finalb": {"definition": "hf_coprime/dg_coprime", "group": "Ungrouped variables", "templateType": "anything", "name": "finalb", "description": ""}, "f": {"definition": "random(2..6)", "group": "Ungrouped variables", "templateType": "anything", "name": "f", "description": ""}, "gcd_hfdg": {"definition": "gcd((h+f),(d-g))", "group": "Ungrouped variables", "templateType": "anything", "name": "gcd_hfdg", "description": ""}, "d": {"definition": "random(g+2..8)", "group": "Ungrouped variables", "templateType": "anything", "name": "d", "description": ""}, "h": {"definition": "(x*(d-g))-f", "group": "Ungrouped variables", "templateType": "anything", "name": "h", "description": ""}, "dg_coprime": {"definition": "(d-g)/gcd_hfdg", "group": "Ungrouped variables", "templateType": "anything", "name": "dg_coprime", "description": ""}, "x": {"definition": "random(2..6)", "group": "Ungrouped variables", "templateType": "anything", "name": "x", "description": ""}, "hf_coprime": {"definition": "(h+f)/gcd_hfdg", "group": "Ungrouped variables", "templateType": "anything", "name": "hf_coprime", "description": ""}, "g": {"definition": "random(2..5)", "group": "Ungrouped variables", "templateType": "anything", "name": "g", "description": ""}}, "extensions": [], "statement": "

Consider the equation \\[ \\var{d}x-\\var{f}=\\var{g}x+\\var{h} \\]

", "advice": "

We are asked to solve the equation

\n

\\[ \\var{d}x-\\var{f}=\\var{g}x+\\var{h} \\]

\n

In this equation, there are $x$ terms and constant terms on both sides of the equals sign.

\n

To solve this equation, we must rearrange it to get $x$ on its own.

\n

\\begin{align}
\\var{d}x-\\var{f} &= \\var{g}x+\\var{h} \\\\[0.5em]
\\var{d}x-\\var{g}x &= \\var{h}+\\var{f} & \\text{Move } x \\text{ terms to the left, and constant terms to the right.}\\\\[0.5em]
\\simplify{{d-g}*x} &= {\\var{h+f}} & \\text{Collect like terms together.}\\\\[0.5em]
x &=\\frac{\\var{h+f}}{\\var{d-g}} & \\text{Divide both sides by } \\var{d-g} \\text{.} \\\\[0.5em]
x &= \\simplify{{h+f}/{d-g}}
\\end{align}

", "variablesTest": {"condition": "", "maxRuns": 100}, "name": "Solve a linear equation $ax+b = cx+d$", "functions": {}, "tags": [], "preamble": {"js": "", "css": ""}, "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Solve a simple linear equation algebraically. The unknown appears on both sides of the equation.

"}, "variable_groups": [], "type": "question", "contributors": [{"name": "Adrian Jannetta", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/164/"}]}]}], "contributors": [{"name": "Adrian Jannetta", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/164/"}]}