// Numbas version: exam_results_page_options {"name": "Derivadas R de la potencia", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "ungrouped_variables": ["num_terms", "powers", "coefficients", "x", "a", "m", "n", "l"], "name": "Derivadas R de la potencia", "tags": [], "advice": "

The derivative of $x^n$ is given by the following:

\n

\\[ \\frac{\\mathrm{d}}{\\mathrm{d}x}(x^n) = n \\times x^{n-1} \\]

\n

We can compute the derivative of $f(x)$ by computing the derivatives of each of the three terms, and then adding them together.

\n

\\begin{align}
\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[2]}*x^{powers[2]}}) &= \\simplify[basic]{{powers[2]}*{coefficients[2]}*x^({powers[2]}-1)} \\\\
&= \\simplify{{coefficients[2]*powers[2]}*x^{powers[2]-1}}
\\end{align}

\n

\\begin{align}
\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[1]}*x^{powers[1]}}) &= \\simplify[basic]{{powers[1]}*{coefficients[1]}*x^({powers[1]}-1)} \\\\
&= \\simplify{{coefficients[1]*powers[1]}*x^{powers[1]-1}}
\\end{align}

\n

The derivative of a constant is $0$. So,

\n

\\[ \\frac{\\mathrm{d}}{\\mathrm{d}x}(\\var{coefficients[0]}) = 0 \\]

\n

\\begin{align}
\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[0]}*x^{powers[0]}}) &= \\simplify[basic]{{powers[0]}*{coefficients[0]}*x^({powers[0]}-1)} \\\\
&= \\simplify{{coefficients[0]*powers[0]}*x^{powers[0]-1}}
\\end{align}

\n

Hence,

\n

\\[ \\frac{\\mathrm{d}f}{\\mathrm{d}x} = \\simplify{ {coefficients[2]*powers[2]}*x^{powers[2]-1} + {coefficients[1]*powers[1]}*x^{powers[1]-1} + {coefficients[0]*powers[0]}*x^{powers[0]-1} } \\]

", "rulesets": {}, "parts": [{"stepsPenalty": "1", "prompt": "

Differentiate the following function.

\n

\\[ f(x) = \\simplify[all,!noLeadingMinus]{ {coefficients[2]}*x^{powers[2]} + {coefficients[1]}*x^{powers[1]} + {coefficients[0]}*x^{powers[0]} } \\]

\n

$\\frac{\\mathrm{d}f}{\\mathrm{d}x} = $ [[0]]

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "gaps": [{"vsetrangepoints": 5, "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "answer": "{coefficients[2]*powers[2]}*x^{powers[2]-1} + {coefficients[1]*powers[1]}*x^{powers[1]-1} + {coefficients[0]*powers[0]}*x^{powers[0]-1}", "marks": "4", "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}], "steps": [{"prompt": "

The derivative of $x^n$ is given by the following:

\n

\\[ \\frac{\\mathrm{d}}{\\mathrm{d}x}(x^n) = n \\times x^{n-1} \\]

\n

Enter the derivatives of each of the three terms in $f(x)$:

", "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "marks": 0, "type": "information"}, {"variableReplacements": [], "prompt": "

$\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[2]}*x^{powers[2]}}) =$

", "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "vsetrangepoints": 5, "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "answer": "{coefficients[2]*powers[2]}*x^{powers[2]-1}", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}, {"variableReplacements": [], "prompt": "

$\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[1]}*x^{powers[1]}}) =$

", "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "vsetrangepoints": 5, "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "answer": "{coefficients[1]*powers[1]}*x^{powers[1]-1}", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}, {"variableReplacements": [], "prompt": "

$\\frac{\\mathrm{d}}{\\mathrm{d}x}(\\simplify{{coefficients[0]}*x^{powers[0]}}) =$

", "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "vsetrangepoints": 5, "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "scripts": {}, "answer": "{coefficients[0]*powers[0]}*x^{powers[0]-1}", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}], "marks": 0, "scripts": {}, "showCorrectAnswer": true, "type": "gapfill"}], "extensions": [], "statement": "

Numbas is really good at creating and marking randomised maths questions. In this question, you're given a random polynomial to differentiate.

\n

Notice how Numbas automatically simplifies the mathematical expressions so they look as if a human wrote them.

\n

See this question in the public editor

", "variable_groups": [], "variablesTest": {"maxRuns": 100, "condition": ""}, "preamble": {"css": "", "js": ""}, "variables": {"a": {"definition": "sort([x[0],x[1],x[2]])", "templateType": "anything", "group": "Ungrouped variables", "name": "a", "description": ""}, "m": {"definition": "a[0]", "templateType": "anything", "group": "Ungrouped variables", "name": "m", "description": ""}, "l": {"definition": "a[2]", "templateType": "anything", "group": "Ungrouped variables", "name": "l", "description": ""}, "n": {"definition": "a[1]", "templateType": "anything", "group": "Ungrouped variables", "name": "n", "description": ""}, "num_terms": {"definition": "5\n", "templateType": "anything", "group": "Ungrouped variables", "name": "num_terms", "description": ""}, "x": {"definition": "satisfy([a,b,c],[random(1..10),random(1..10),random(1..10)],\n [a<>b and a<>c and b<>c])", "templateType": "anything", "group": "Ungrouped variables", "name": "x", "description": ""}, "powers": {"definition": "sort(shuffle(list(0..8))[0..3])", "templateType": "anything", "group": "Ungrouped variables", "name": "powers", "description": ""}, "coefficients": {"definition": "repeat(random(-10..10 except 0),num_terms)", "templateType": "anything", "group": "Ungrouped variables", "name": "coefficients", "description": ""}}, "metadata": {"description": "", "licence": "Creative Commons Attribution 4.0 International"}, "type": "question", "showQuestionGroupNames": false, "question_groups": [{"name": "", "pickingStrategy": "all-ordered", "pickQuestions": 0, "questions": []}], "contributors": [{"name": "Marlon Arcila", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/321/"}]}]}], "contributors": [{"name": "Marlon Arcila", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/321/"}]}