// Numbas version: finer_feedback_settings {"name": "Polynomials: Expand and Simplify 2b", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Polynomials: Expand and Simplify 2b", "tags": [], "metadata": {"description": "

Finding the product of three linear functions of the form $mx+c$.

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

Given three functions, \\[ f(x) = \\simplify{{a1}x^2+{b1}x+{c1}}, \\quad g(x)=\\simplify{{b2}x+{c2}}, \\quad h(x)=\\simplify{{b3}x+{c3}}\\]

\n

calculate the product \\[\\simplify{f(x)g(x)h(x)}.\\]

", "advice": "

To find the product of the three functions $f(x)$, $g(x)$, and $h(x)$, we can first find the product of two of the functions, and then multiply the resulting polynomial by the third function. For the functions 

\n

\\[ f(x) = \\simplify{{a1}x^2+{b1}x+{c1}}, \\quad g(x)=\\simplify{{b2}x+{c2}}, \\quad h(x)=\\simplify{{b3}x+{c3}}, \\] 

\n

since all of the functions are linear, it does not matter which two you choose to multiply first. In this case, we will multiply $g(x)$ and $h(x)$ first:

\n

\\[ \\begin{split} g(x)h(x) &,=(\\simplify{{b2}x+{c2}})(\\simplify{{b3}x+{c3}}) \\\\ &\\,= \\simplify[!cancelTerms]{{b2*b3}x^2+{b2*c3}x+{b3*c2}x+{c2*c3}} \\\\ &\\,=\\simplify{{b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3}} \\end{split} \\]

\n

We can now find multiply this result by $f(x)$ to find the product of all three functions:

\n

\\[ \\begin{split} f(x)g(x)h(x) &\\,= (\\simplify{{a1}x^2+{b1}x+{c1}})(\\simplify{{b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3}}) \\\\ &\\,= \\simplify[all]{{a1}x^2({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})+{b1}x({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})+{c1}({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})}. \\end{split} \\]

\n

Expanding each bracket and collecting similar terms:

\n

\\[ \\begin{split} f(x)g(x)h(x) &\\,= \\simplify[all]{{a1}x^2({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})+{b1}x({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})+{c1}({b2*b3}x^2+{b2*c3+b3*c2}x+{c2*c3})} \\\\ &\\,=\\simplify[all,!collectNumbers, !cancelTerms]{{a1*b2*b3}x^4+{a1*b2*c3+a1*b3*c2}x^3+{a1*c2*c3}x^2+{b1*b2*b3}x^3+{b1*b2*c3+b1*b3*c2}x^2+{b1*c2*c3}x+{c1*b2*b3}x^2+{c1*b2*c3+c1*b3*c2}x+{c1*c2*c3}} \\\\ &\\,= \\simplify{{a1*b2*b3}x^4+{a1*b2*c3+a1*b3*c2}x^3+{a1*c2*c3}x^2+{b1*b2*b3}x^3+{b1*b2*c3+b1*b3*c2}x^2+{b1*c2*c3}x+{c1*b2*b3}x^2+{c1*b2*c3+c1*b3*c2}x+{c1*c2*c3}}. \\end{split} \\]

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a1": {"name": "a1", "group": "Ungrouped variables", "definition": "0", "description": "", "templateType": "anything", "can_override": false}, "b1": {"name": "b1", "group": "Ungrouped variables", "definition": "random(1..8)", "description": "", "templateType": "anything", "can_override": false}, "b2": {"name": "b2", "group": "Ungrouped variables", "definition": "random(1..5)", "description": "", "templateType": "anything", "can_override": false}, "c1": {"name": "c1", "group": "Ungrouped variables", "definition": "random(-10..10)", "description": "", "templateType": "anything", "can_override": false}, "c2": {"name": "c2", "group": "Ungrouped variables", "definition": "random(-10..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "b3": {"name": "b3", "group": "Ungrouped variables", "definition": "random(1..5)", "description": "", "templateType": "anything", "can_override": false}, "c3": {"name": "c3", "group": "Ungrouped variables", "definition": "random(-3..3 except [0,c2])", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["a1", "b1", "c1", "b2", "c2", "b3", "c3"], "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, "answer": "{a1*b2*b3}x^4+{a1*b2*c3+a1*b3*c2+b1*b2*b3}x^3+{a1*c2*c3+c1*b2*b3+b1*b2*c3+b1*b3*c2}x^2+{c1*b2*c3+c1*b3*c2+b1*c2*c3}x+{c1*c2*c3}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "mustmatchpattern": {"pattern": "$n`?*x^3+`+-$n`?x^2+`+-$n`?*x+`+-$n`?", "partialCredit": 0, "message": "", "nameToCompare": ""}, "valuegenerators": [{"name": "x", "value": ""}]}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}]}], "contributors": [{"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}