// Numbas version: exam_results_page_options {"name": "Differentiation: Equation of Tangent- Quadratic", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {"plot": {"definition": "// This functions plots a cubic with a certain number of\n// stationary points and roots.\n// It creates the board, sets it up, then returns an\n// HTML div tag containing the board.\n\n\n// Max and min x and y values for the axis.\nvar x_min = -7;\nvar x_max = 7;\nvar y_min = -20;\nvar y_max = 20;\n\n\n// First, make the JSXGraph board.\nvar div = Numbas.extensions.jsxgraph.makeBoard(\n '500px',\n '600px',\n {\n boundingBox: [x_min,y_max,x_max,y_min],\n axis: false,\n showNavigation: false,\n grid: false,\n axis:false,\n }\n);\n\n\n\n// div.board is the object created by JSXGraph, which you use to \n// manipulate elements\nvar board = div.board; \n\n// create the x-axis and y-axis\nvar xaxis = board.create('line',[[0,0],[1,0]], { strokeColor: 'black', fixed: true});\nvar xticks = board.create('ticks',[xaxis,1],{\n drawLabels: true,\n label: {offset: [-4, -10]},\n minorTicks: 0\n});\n\n// create the y-axis\nvar yaxis = board.create('line',[[0,0],[0,1]], { strokeColor: 'black', fixed: true });\n\n\n\n\n// Plot the function.\n board.create('functiongraph',\n [function(x){ return a*x*x+b*x+c},x_min,x_max],\n {strokeWidth:2});\n\n//Plot the tangent.\n board.create('functiongraph',\n [function(x){ return y0+(x-x0)*(2*x0*a+b)},x_min,x_max]);\n\n// Plot coordinates.\n board.create('circle',[[x0,y0],0.1],{color:'red'});\n\n\nreturn div;", "language": "javascript", "parameters": [["a", "number"], ["b", "number"], ["c", "number"], ["x0", "number"], ["y0", "number"]], "type": "html"}}, "extensions": ["jsxgraph"], "variable_groups": [{"name": "part a", "variables": ["a", "b", "c", "x", "fx", "m", "absfx"]}], "ungrouped_variables": [], "parts": [{"gaps": [{"tolerance": 0, "showCorrectAnswer": true, "numColumns": "2", "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "unitTests": [], "correctAnswer": "matrix([x,fx])", "extendBaseMarkingAlgorithm": true, "markPerCell": false, "scripts": {}, "type": "matrix", "allowResize": false, "correctAnswerFractions": false, "customName": "", "marks": "0.5", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "numRows": 1, "allowFractions": true, "variableReplacements": [], "useCustomName": false}], "showCorrectAnswer": true, "prompt": "

{plot(a,b,c,x, fx)}

\n

The curve above is the graph of the quadratic function: $y = \\simplify{{a}x^2+{b}x+{c}}$.

\n

The tangent to the curve at  $x=\\var{x}$   has also been drawn. 

\n

What are the coordinates of the point where the tangent touches the curve?

\n

[[0]]

", "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "unitTests": [], "extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "gapfill", "sortAnswers": false, "customName": "", "marks": 0, "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "variableReplacements": [], "useCustomName": false}, {"gaps": [{"showFractionHint": true, "adaptiveMarkingPenalty": 0, "minValue": "m", "type": "numberentry", "notationStyles": ["plain", "en", "si-en"], "marks": "1.5", "mustBeReduced": false, "correctAnswerFraction": false, "allowFractions": false, "useCustomName": false, "showCorrectAnswer": true, "customMarkingAlgorithm": "", "unitTests": [], "correctAnswerStyle": "plain", "extendBaseMarkingAlgorithm": true, "scripts": {}, "variableReplacements": [], "maxValue": "m", "customName": "", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "mustBeReducedPC": 0}], "showCorrectAnswer": true, "prompt": "

What is the gradient (slope) of the tangent line?

\n

(Hint, you will need to differentiate the function and use your answer to find this...)

\n

Gradient $m =  $ [[0]]

\n

", "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "unitTests": [], "extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "gapfill", "sortAnswers": false, "customName": "", "marks": 0, "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "variableReplacements": [], "useCustomName": false}, {"gaps": [{"adaptiveMarkingPenalty": 0, "answer": "x*{m}+{fx-x*m}", "marks": "1", "type": "jme", "checkingType": "absdiff", "checkingAccuracy": 0.001, "checkVariableNames": false, "failureRate": 1, "useCustomName": false, "vsetRangePoints": 5, "showCorrectAnswer": false, "customMarkingAlgorithm": "", "unitTests": [], "extendBaseMarkingAlgorithm": true, "scripts": {}, "vsetRange": [0, 1], "variableReplacements": [], "customName": "", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "showPreview": true, "valuegenerators": [{"value": "", "name": "x"}]}], "showCorrectAnswer": true, "prompt": "

What is the equation of the tangent line in $y=mx+c$  form ?

\n

$y=$ [[0]]

", "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "unitTests": [], "extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "gapfill", "sortAnswers": false, "customName": "", "marks": 0, "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "variableReplacements": [], "useCustomName": false}], "variables": {"m": {"description": "", "definition": "2*a*x+b", "group": "part a", "name": "m", "templateType": "anything"}, "absfx": {"description": "", "definition": "abs(fx)", "group": "part a", "name": "absfx", "templateType": "anything"}, "fx": {"description": "", "definition": "a*x*x+b*x+c", "group": "part a", "name": "fx", "templateType": "anything"}, "a": {"description": "", "definition": "random(-2..2 except 0)", "group": "part a", "name": "a", "templateType": "anything"}, "b": {"description": "", "definition": "random(-5..5 except 0)", "group": "part a", "name": "b", "templateType": "anything"}, "x": {"description": "", "definition": "random(-3..3 except 0)", "group": "part a", "name": "x", "templateType": "anything"}, "c": {"description": "", "definition": "random(-2..2 except 0)", "group": "part a", "name": "c", "templateType": "anything"}}, "advice": "

See 10.1 and 10.2.

\n

See Maths 1 for equations of lines, and for background on gradients of curves.

", "preamble": {"css": "", "js": ""}, "tags": [], "statement": "

Finding the equation of the tangent to a curve.

", "variablesTest": {"maxRuns": 100, "condition": "and(m<>0,(absfx<15))"}, "rulesets": {}, "name": "Differentiation: Equation of Tangent- Quadratic", "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": ""}, "contributors": [{"name": "Clare Lundon", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/492/"}, {"name": "Lovkush Agarwal", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1358/"}]}]}], "contributors": [{"name": "Clare Lundon", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/492/"}, {"name": "Lovkush Agarwal", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1358/"}]}