// Numbas version: finer_feedback_settings {"name": "Surds: Simplifying Expressions 7 - Rationalising the Denominator", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Surds: Simplifying Expressions 7 - Rationalising the Denominator", "tags": ["Category: Surds"], "metadata": {"description": "

Rewriting fractions involving surds by rationalising the denominator.

", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "

Rationalise the denominator in the following expression:

\n

\\[\\simplify[unitFactor]{sqrt({b})/({a}+{sgn}*sqrt({b}))}\\]

", "advice": "

To rationalise the denominator of a fraction which has the form $\\frac{n}{a\\pm\\sqrt{b}}$, we must multiply the numerator and denominator by $a \\mp\\sqrt{b}$.

\n

Therefore, 

\n

{advice}

\n

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1..9)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(2,3,5,6,7)", "description": "", "templateType": "anything", "can_override": false}, "simplify": {"name": "simplify", "group": "Ungrouped variables", "definition": "\"

\\\\[\\\\begin{split} \\\\simplify[unitFactor]{sqrt({b})/({a}+{sgn}*sqrt({b}))} &\\\\,=\\\\simplify[unitFactor]{sqrt({b})({a}-{sgn}*sqrt({b}))/(({a}+{sgn}*sqrt({b}))({a}-{sgn}*sqrt({b})))} \\\\\\\\\\\\\\\\ &\\\\,= \\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2}-{sgn*a}sqrt({b})+{sgn*a}sqrt({b}) -{b})} \\\\\\\\\\\\\\\\ &\\\\,=\\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2}-{b})}\\\\\\\\\\\\\\\\ &\\\\,=\\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2-b})}\\\\\\\\\\\\\\\\ &\\\\,=\\\\simplify[unitFactor]{({a/simp}sqrt({b})-{sgn*b/simp})/({(a^2-b)/simp})}\\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "simplified": {"name": "simplified", "group": "Ungrouped variables", "definition": "\"

\\\\[\\\\begin{split} \\\\simplify[unitFactor]{sqrt({b})/({a}+{sgn}*sqrt({b}))} &\\\\,=\\\\simplify[unitFactor]{sqrt({b})({a}-{sgn}*sqrt({b}))/(({a}+{sgn}*sqrt({b}))({a}-{sgn}*sqrt({b})))} \\\\\\\\\\\\\\\\ &\\\\,= \\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2}-{sgn*a}sqrt({b})+{sgn*a}sqrt({b}) -{b})} \\\\\\\\\\\\\\\\ &\\\\,=\\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2}-{b})}\\\\\\\\\\\\\\\\ &\\\\,=\\\\simplify[unitFactor]{({a}sqrt({b})-{sgn*b})/({a^2-b})}\\\\end{split} \\\\]

\"", "description": "", "templateType": "long string", "can_override": false}, "advice": {"name": "advice", "group": "Ungrouped variables", "definition": "if (simp>1,{simplify},{simplified})", "description": "", "templateType": "anything", "can_override": false}, "sgn": {"name": "sgn", "group": "Ungrouped variables", "definition": "random(-1,1)", "description": "", "templateType": "anything", "can_override": false}, "simpa": {"name": "simpa", "group": "Ungrouped variables", "definition": "gcf(a^2-b,a)", "description": "", "templateType": "anything", "can_override": false}, "simpb": {"name": "simpb", "group": "Ungrouped variables", "definition": "gcd(a^2-b,b)", "description": "", "templateType": "anything", "can_override": false}, "simp": {"name": "simp", "group": "Ungrouped variables", "definition": "gcd(simpa,simpb)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "a^2-b>0", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "simplify", "simplified", "advice", "sgn", "simpa", "simpb", "simp"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "jme", "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": "

You can type sqrt(x) to get $\\sqrt{x}$.

", "answer": "({a/simp}*sqrt({b})-{sgn*b/simp})/{(a^2-b)/simp}", "answerSimplification": "all,simplifyFractions,cancelTerms", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}]}], "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}