// Numbas version: exam_results_page_options {"name": "Algebra: graphs of functions, straight line", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"preamble": {"js": "", "css": ""}, "extensions": ["jsxgraph"], "advice": "

See Lecture 4.1 for most questions. See Lecture 4.3 for equation of line.  See Lecture 3.4 for the phrase `solving equations'.

\n

\n\n

\n\n

\n

", "name": "Algebra: graphs of functions, straight line", "parts": [{"extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "type": "gapfill", "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst", "sortAnswers": false, "showCorrectAnswer": true, "marks": 0, "gaps": [{"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "fx[0]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "fx[0]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "fx[1]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "fx[1]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "x[2]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "x[2]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "x[3]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "x[3]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "x[4]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "x[4]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "checkingAccuracy": 0.001, "checkingType": "absdiff", "type": "jme", "variableReplacementStrategy": "originalfirst", "vsetRange": [0, 1], "showCorrectAnswer": true, "vsetRangePoints": 5, "marks": "2", "answer": "{mf}x+{cf}", "showPreview": true, "unitTests": [], "variableReplacements": [], "checkVariableNames": false, "failureRate": 1, "expectedVariableNames": [], "scripts": {}, "showFeedbackIcon": true}, {"correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "marks": "1", "minValue": "x[2]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "x[2]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}], "unitTests": [], "variableReplacements": [], "scripts": {}, "prompt": "

This is the graph of a function $f$.

\n

{eqnline(mf, cf)}

\n

\n

(i) $f(\\var{x[0]}) =$ [[0]]

\n

(ii) $f(\\var{x[1]}) =$ [[1]]

\n

(iii) What value for $a$ do you need so that $f(a) = \\var{fx[2]}$? [[2]]

\n

(iv) What is $f^{-1}(\\var{fx[3]})$? [[3]]

\n

(v) Solve the equation $f(x) = \\var{fx[4]}$.    $x=$[[4]]

\n

(vi) What is the equation of the line?  $y=$ [[5]]

\n

(vii) $f^{-1}(\\var{fx[2]})=$ [[6]]

"}], "variable_groups": [{"name": "part a", "variables": ["mf", "cf", "x", "fx"]}], "variables": {"fx": {"description": "", "name": "fx", "group": "part a", "templateType": "anything", "definition": "x*mf+vector(cf,cf,cf,cf,cf,cf,cf,cf)"}, "x": {"description": "", "name": "x", "group": "part a", "templateType": "anything", "definition": "vector(shuffle(-4..4 except (0)))"}, "mf": {"description": "", "name": "mf", "group": "part a", "templateType": "anything", "definition": "random(-4..4 except 0)"}, "cf": {"description": "", "name": "cf", "group": "part a", "templateType": "anything", "definition": "random(-5..5)"}}, "variablesTest": {"maxRuns": 100, "condition": ""}, "ungrouped_variables": [], "tags": [], "statement": "

This is a non-calculator question.

", "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

A graph of a straight line $f$ is given. Questions include determining values of $f$, of $f$ inverse, and determing the equation of the line.

"}, "rulesets": {}, "functions": {"eqnline": {"parameters": [["m", "number"], ["c", "number"]], "type": "html", "language": "javascript", "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 = -6;\nvar x_max = 6;\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: true,\n grid: true\n }\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('axis',[[0,0],[1,0]]);\n\n// create the y-axis\nvar yaxis = board.create('axis',[[0,0],[0,1]], );\n\n\n\n\n// Plot the function.\n board.create('functiongraph',\n [function(x){ return m*x+c},x_min,x_max]);\n\n\n\nreturn div;"}}, "type": "question", "contributors": [{"name": "Lovkush Agarwal", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1358/"}]}]}], "contributors": [{"name": "Lovkush Agarwal", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1358/"}]}