// Numbas version: exam_results_page_options {"name": "Integration by parts", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"variablesTest": {"maxRuns": 100, "condition": ""}, "variables": {"s3": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "s3", "definition": "random(1,-1)"}, "a": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "a", "definition": "1"}, "s2": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "s2", "definition": "random(1,-1)"}, "s1": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "s1", "definition": "random(1,-1)"}, "a2": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "a2", "definition": "s2*random(1..9)"}, "c": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "c", "definition": "s3*random(1..9)"}, "b": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "b", "definition": "random(2..5)"}, "a1": {"group": "Ungrouped variables", "templateType": "anything", "description": "", "name": "a1", "definition": "s1*random(1..9)"}}, "advice": "

a)

\n

The formula for integrating by parts is
\\[ \\int u\\frac{dv}{dx} dx = uv - \\int v \\frac{du}{dx} dx. \\]

\n

We choose $u = \\simplify[std]{{a}x}$ and $\\displaystyle \\frac{dv}{dx} = \\simplify[std]{sin({b}x+{c})}$.

\n

So $\\displaystyle \\frac{du}{dx}$ = $\\var{a}$ and $v = \\simplify[std]{(-1/{b})*cos({b}x+{c})}$.

\n

Hence,
\\[ \\begin{eqnarray} \\int \\simplify[std]{{a}x*sin({b}x+{c})} dx &=& uv - \\int v \\frac{du}{dx} dx \\\\ &=& \\simplify[std]{(-{a}/{b})*x*cos({b}x+{c})} - \\int \\left( \\simplify[std]{(-{a}/{b})*cos({b}x+{c})}\\right) dx \\\\ &=& \\simplify[std]{(-{a}/{b})*x*cos({b}x+{c}) + ({a}/{b^2})*sin({b}x+{c}) + C} \\end{eqnarray} \\]

\n

b)

\n

For this part we choose $u = \\simplify[std]{{a}x}$ and $\\frac{dv}{dx} = \\simplify[std]{cos({b}x+{c})}$.

\n

So $\\displaystyle \\frac{du}{dx}$ = $\\var{a}$ and $\\displaystyle v = \\simplify[std]{(1/{b})*sin({b}x+{c})}$.

\n

Hence,
\\[ \\begin{eqnarray} \\int \\simplify[std]{{a}x*cos({b}x+{c})} dx &=& uv - \\int v \\frac{du}{dx} dx \\\\ &=& \\simplify[std]{({a}/{b})*x*sin({b}x+{c})} - \\int \\left( \\simplify[std]{({a}/{b})*sin({b}x+{c})}\\right) dx \\\\ &=& \\simplify[std]{({a}/{b})*x*sin({b}x+{c}) + ({a}/{b^2})*cos({b}x+{c}) + C} \\end{eqnarray} \\]

\n

c)

\n

Using the results from Parts a and b, we have \\[\\begin{eqnarray*}I &=& \\int \\simplify[std]{{a1}x*sin({b}x+{c})} dx + \\int \\simplify[std]{{a2}x*cos({b}x+{c})} dx\\\\ &=& \\simplify[std]{{a1}*((-{a}/{b})*x*cos({b}x+{c}) + ({a}/{b^2})*sin({b}x+{c}))+{a2}*(({a}/{b})*x*sin({b}x+{c}) +({a}/{b^2})*cos({b}x+{c}))+C}\\\\ &=&\\simplify[std]{(-{a1}/{b})*x*cos({b}x+{c}) + ({a1}/{b^2})*sin({b}x+{c})+({a2}/{b})*x*sin({b}x+{c}) +({a2}/{b^2})*cos({b}x+{c}) + C}\\\\ &=&\\simplify[std]{({a2}/{b}*x+{a1}/{b^2})*sin({b}x+{c})+({-a1}/{b}*x+{a2}/{b^2})*cos({b}x+{c})+C} \\end{eqnarray*}\\]
Hence
$\\displaystyle \\simplify[std]{f(x) = {a2}/{b}*x+{a1}/{b^2}}$

\n

$\\displaystyle \\simplify[std]{g(x) = {-a1}/{b}*x+{a2}/{b^2}}$

", "preamble": {"css": "", "js": ""}, "tags": [], "parts": [{"steps": [{"customMarkingAlgorithm": "", "marks": 0, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "type": "information", "showFeedbackIcon": true, "variableReplacements": [], "showCorrectAnswer": true, "prompt": "\n \n \n

The formula for integrating by parts is
\\[ \\int u\\frac{dv}{dx} dx = uv - \\int v \\frac{du}{dx} dx. \\]

\n \n \n ", "scripts": {}, "customName": "", "extendBaseMarkingAlgorithm": true}], "customMarkingAlgorithm": "", "marks": 0, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "type": "gapfill", "showFeedbackIcon": true, "sortAnswers": false, "variableReplacements": [], "showCorrectAnswer": true, "gaps": [{"vsetRangePoints": 5, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "showFeedbackIcon": true, "customName": "", "checkVariableNames": false, "valuegenerators": [{"name": "c", "value": ""}, {"name": "x", "value": ""}], "answer": "({a}/{b^2})sin({b}x+{c}) - ({a}/{b})*x*cos({b}x+{c}) + C", "customMarkingAlgorithm": "", "variableReplacements": [], "marks": 2, "vsetRange": [0, 1], "showCorrectAnswer": true, "checkingAccuracy": 0.001, "answerSimplification": "std", "checkingType": "absdiff", "failureRate": 1, "type": "jme", "showPreview": true, "scripts": {}, "notallowed": {"message": "

Do not input numbers as decimals, only as integers without the decimal point, or fractions

", "partialCredit": 0, "showStrings": false, "strings": ["."]}, "extendBaseMarkingAlgorithm": true}], "prompt": "\n

$\\displaystyle \\int \\simplify[std]{{a}x*sin({b}x+{c})} dx = \\phantom{{}}$[[0]]

\n

Input all numbers as fractions or integers and not decimals.

\n

Input the constant of integration as $C$.

\n

You can get help by clicking on Show steps. You will lose 1 mark if you do.

\n ", "scripts": {}, "stepsPenalty": 1, "customName": "", "extendBaseMarkingAlgorithm": true}, {"customMarkingAlgorithm": "", "marks": 0, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "type": "gapfill", "showFeedbackIcon": true, "sortAnswers": false, "variableReplacements": [], "showCorrectAnswer": true, "gaps": [{"vsetRangePoints": 5, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "showFeedbackIcon": true, "customName": "", "checkVariableNames": false, "valuegenerators": [{"name": "c", "value": ""}, {"name": "x", "value": ""}], "answer": "({a}/{b})*x*sin({b}x+{c}) + ({a}/{b^2})*cos({b}x+{c}) + C", "customMarkingAlgorithm": "", "variableReplacements": [], "marks": 2, "vsetRange": [0, 1], "showCorrectAnswer": true, "checkingAccuracy": 0.001, "answerSimplification": "std", "checkingType": "absdiff", "failureRate": 1, "type": "jme", "showPreview": true, "scripts": {}, "notallowed": {"message": "

Do not input numbers as decimals, only as integers without the decimal point, or fractions

", "partialCredit": 0, "showStrings": false, "strings": ["."]}, "extendBaseMarkingAlgorithm": true}], "prompt": "\n

$\\displaystyle \\int \\simplify[std]{{a}x*cos({b}x+{c})} dx = \\phantom{{}}$[[0]]

\n

Input all numbers as fractions or integers and not decimals.

\n

Input the constant of integration as $C$.

\n ", "scripts": {}, "customName": "", "extendBaseMarkingAlgorithm": true}, {"customMarkingAlgorithm": "", "marks": 0, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "type": "gapfill", "showFeedbackIcon": true, "sortAnswers": false, "variableReplacements": [], "showCorrectAnswer": true, "gaps": [{"vsetRangePoints": 5, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "showFeedbackIcon": true, "customName": "", "checkVariableNames": false, "valuegenerators": [{"name": "x", "value": ""}], "answer": "{a2}/{b}*x+{a1}/{b^2}", "customMarkingAlgorithm": "", "variableReplacements": [], "marks": 1, "vsetRange": [0, 1], "showCorrectAnswer": true, "checkingAccuracy": 0.001, "answerSimplification": "std", "checkingType": "absdiff", "failureRate": 1, "type": "jme", "showPreview": true, "scripts": {}, "notallowed": {"message": "

Do not input numbers as decimals, only as integers without the decimal point, or fractions

", "partialCredit": 0, "showStrings": false, "strings": ["."]}, "extendBaseMarkingAlgorithm": true}, {"vsetRangePoints": 5, "unitTests": [], "variableReplacementStrategy": "originalfirst", "useCustomName": false, "showFeedbackIcon": true, "customName": "", "checkVariableNames": false, "valuegenerators": [{"name": "x", "value": ""}], "answer": "{-a1}/{b}*x+{a2}/{b^2}", "customMarkingAlgorithm": "", "variableReplacements": [], "marks": 1, "vsetRange": [0, 1], "showCorrectAnswer": true, "checkingAccuracy": 0.001, "answerSimplification": "std", "checkingType": "absdiff", "failureRate": 1, "type": "jme", "showPreview": true, "scripts": {}, "notallowed": {"message": "

Do not input numbers as decimals, only as integers without the decimal point, or fractions

", "partialCredit": 0, "showStrings": false, "strings": ["."]}, "extendBaseMarkingAlgorithm": true}], "prompt": "\n

Using the first two parts find:
$\\displaystyle I=\\int \\simplify[std]{{a1}x*sin({b}x+{c})+{a2}x*cos({b}x+{c})} dx $
You are given that \\[I=\\simplify[std]{f(x)*sin({b}x+{c})+g(x)*cos({b}x+{c})+C}\\]
where $f(x)$ and $g(x)$ are polynomials of degree 1. You have to find $f(x)$ and $g(x)$.

\n

$f(x)=\\;$[[0]] $\\;\\;\\;\\;\\;g(x)=\\;$[[1]]

\n

Input all numbers as fractions or integers and not decimals.

\n ", "scripts": {}, "customName": "", "extendBaseMarkingAlgorithm": true}], "ungrouped_variables": ["a", "c", "b", "s3", "s2", "s1", "a1", "a2"], "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Find $\\displaystyle \\int x\\sin(cx+d)\\;dx,\\;\\;\\int x\\cos(cx+d)\\;dx $ and hence $\\displaystyle \\int ax\\sin(cx+d)+bx\\cos(cx+d)\\;dx$

"}, "rulesets": {"std": ["all", "!collectNumbers", "fractionNumbers", "!noLeadingMinus"]}, "statement": "\n

Find the following indefinite integrals.

\n

Input all numbers as fractions or integers and not decimals.

\n

Input the constant of integration as $C$ where needed.

\n ", "variable_groups": [], "functions": {}, "extensions": [], "name": "Integration by parts", "type": "question", "contributors": [{"name": "Bill Foster", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/6/"}, {"name": "Kevin Bohan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3363/"}, {"name": "Maria Aneiros", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3388/"}]}]}], "contributors": [{"name": "Bill Foster", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/6/"}, {"name": "Kevin Bohan", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3363/"}, {"name": "Maria Aneiros", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3388/"}]}