// Numbas version: exam_results_page_options
{"name": "Indefinite integral by substitution 3 (custom feedback)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"variablesTest": {"maxRuns": 100, "condition": ""}, "functions": {}, "tags": [], "parts": [{"variableReplacementStrategy": "originalfirst", "customMarkingAlgorithm": "", "showFeedbackIcon": true, "variableReplacements": [], "showCorrectAnswer": true, "extendBaseMarkingAlgorithm": true, "gaps": [{"variableReplacementStrategy": "originalfirst", "failureRate": 1, "showPreview": true, "customMarkingAlgorithm": "malrules:\n [\n [\"ln(abs({a}*x^2+{b}*x+{c}))\", \"Almost there! Did you forget to include the integration constant?\"],\n [\"ln(u)+C\",\"Don't forget to fill back in for $u$. You must give your answer in terms of the original variable i.e. in terms of $x$.\"],\n [\"ln(u)\",\"Don't forget to fill back in for $u$. You must give your answer in terms of the original variable i.e. in terms of $x$.\"],\n [\"1/({a}*x^2+{b}*x+{c})+C\",\"You haven't actually integrated here. You simply subbed in for $\\\\simplify[std]{{a}*x^2+{b}*x+{c}}$ and then subbed back again.\"],\n [\"1/({a}*x^2+{b}*x+{c})\",\"You haven't actually integrated here. You simply subbed in for $\\\\simplify[std]{{a}*x^2+{b}*x+{c}}$ and then subbed back again.\"],\n [\"1/u+C\",\"You haven't actually integrated here. You simply subbed in for $\\\\simplify[std]{{a}*x^2+{b}*x+{c}}$. Also, once you have integrated, make sure you sub back in for $u$ - give your answer in terms of the original variable (i.e. in terms of $x$).\"],\n [\"1/u\",\"You haven't actually integrated here. You simply subbed in for $\\\\simplify[std]{{a}*x^2+{b}*x+{c}}$. Also, once you have integrated, make sure you sub back in for $u$ - give your answer in terms of the original variable (i.e. in terms of $x$).\"],\n [\"({a}*x^2+{b}*x)/({a}*x^3/3+{b}*x^2/2+{c}*x)+C\",\"You cannot simply integrate each part of a quotient individually. Look closely at the integrand (what you were asked to integrate). Is one part of the integrand equal to the derivative (or a multiple of the derivative) of another part? If so, try substitution.\"], \n [\"({a}*x^2+{b}*x)/({a}*x^3/3+{b}*x^2/2+{c}*x)\",\"You cannot simply integrate each part of a quotient individually. Look closely at the integrand (what you were asked to integrate). Is one part of the integrand equal to the derivative (or a multiple of the derivative) of another part? If so, try substitution.\"], \n [\"(2*{a}*({a}*x^2+{b}*x+{c})-(2*{a}*x+{b})^2)/(({a}*x^2+{b}*x+{c})^2)+C\", \"It looks like you have differentiated rather than integrating. Remember, there is no quotient rule for integration. If you have a quotient, check if the derivative of the bottom is what's on top of the line (or a multiple of what's on top of the line). If so, try substitution.\"],\n [\"(2*{a}*({a}*x^2+{b}*x+{c})-(2*{a}*x+{b})^2)/(({a}*x^2+{b}*x+{c})^2)\", \"It looks like you have differentiated rather than integrating. Remember, there is no quotient rule for integration. If you have a quotient, check if the derivative of the bottom is what's on top of the line (or a multiple of what's on top of the line). If so, try substitution.\"]\n ]\n\n\nparsed_malrules: \n map(\n [\"expr\":parse(x[0]),\"feedback\":x[1]],\n x,\n malrules\n )\n\nagree_malrules (Do the student's answer and the expected answer agree on each of the sets of variable values?):\n map(\n len(filter(not x ,x,map(\n try(\n resultsEqual(unset(question_definitions,eval(studentexpr,vars)),unset(question_definitions,eval(malrule[\"expr\"],vars)),settings[\"checkingType\"],settings[\"checkingAccuracy\"]),\n message,\n false\n ),\n vars,\n vset\n )))
\\[I=\\simplify[std]{Int(({2 * a} * x + {b}) / ({a} * x ^ 2 + {b} * x + {c}),x)}\\]
\n$I=\\;$[[0]]
\nInput the constant of integration as $C$.
\nInput all numbers as integers or fractions not as decimals.
\nClick on Show steps if you need help. You will lose 1 mark if you do so.
", "type": "gapfill", "sortAnswers": false, "scripts": {}, "marks": 0, "steps": [{"variableReplacementStrategy": "originalfirst", "scripts": {}, "customMarkingAlgorithm": "", "showFeedbackIcon": true, "marks": 0, "showCorrectAnswer": true, "extendBaseMarkingAlgorithm": true, "variableReplacements": [], "unitTests": [], "prompt": "Try the substitution $u=\\simplify[std]{{a} * (x ^ 2) + ({b} * x) + {c}}$
", "type": "information"}], "unitTests": [], "stepsPenalty": 1}], "rulesets": {"std": ["all", "!collectNumbers", "fractionNumbers", "!noLeadingMinus"]}, "variable_groups": [], "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "Find $\\displaystyle \\int \\frac{2ax + b}{ax ^ 2 + bx + c}\\;dx$
"}, "name": "Indefinite integral by substitution 3 (custom feedback)", "advice": "\n\tThis exercise is best solved by using substitution.
\n\tNote that the numerator $\\simplify[std]{{2 * a} * x + {b}}$ of \\[\\simplify[std]{({2 * a} * x + {b}) / ({a} * x ^ 2 + {b} * x + {c})}\\] is the derivative of the denominator $\\simplify[std]{{a} * x ^ 2 + {b} * x + {c}}$
\n\tSo if you use as your substitution $u=\\simplify[std]{{a} * (x ^ 2) + ({b} * x) + {c}}$ you then have $\\simplify[std]{ du = ({2 * a} * x + {b}) * dx}$
\n\tHence we can replace $\\simplify[std]{ ({2 * a} * x + {b}) * dx}$ by $du$
\n\tHence the integral becomes:
\n\t\\[\\begin{eqnarray*} I&=&\\int\\;\\frac{du}{u}\\\\ &=&\\ln(|u|)+C\\\\ &=& \\simplify[std]{ln(abs({a} * (x ^ 2) + ({b} * x) + {c}))+C} \\end{eqnarray*}\\]
A Useful Result
This example can be generalised.
Suppose \\[I = \\int\\; \\frac{f'(x)}{f(x)}\\;dx\\]
The using the substitution $u=f(x)$ we find that $du=f'(x)\\;dx$ and so using the same method as above:
\\[I = \\int \\frac{du}{u} = \\ln(|u|)+ C = \\ln(|f(x)|)+C\\]
Find the following integral.
\n\tInput the constant of integration as $C$.
\n\tInput all numbers as integers or fractions.
\n\t\n\t \n\t \n\t", "type": "question", "contributors": [{"name": "Julie Crowley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/113/"}, {"name": "Clodagh Carroll", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/384/"}]}]}], "contributors": [{"name": "Julie Crowley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/113/"}, {"name": "Clodagh Carroll", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/384/"}]}