// Numbas version: exam_results_page_options {"name": "Algebra. Procedures. Version 3", "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 3.3 andWorkshop 3.5.

", "name": "Algebra. Procedures. Version 3", "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[1]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "fx[1]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"numColumns": 1, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "numRows": 1, "correctAnswer": "matrix([x[2]])", "type": "matrix", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "markPerCell": false, "marks": 1, "correctAnswerFractions": false, "allowResize": true, "unitTests": [], "variableReplacements": [], "scripts": {}, "tolerance": 0, "showFeedbackIcon": true, "allowFractions": false}, {"numColumns": 1, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "numRows": 1, "correctAnswer": "matrix([x[3]])", "type": "matrix", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "markPerCell": false, "marks": 1, "correctAnswerFractions": false, "allowResize": true, "unitTests": [], "variableReplacements": [], "scripts": {}, "tolerance": 0, "showFeedbackIcon": true, "allowFractions": false}, {"extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "checkingAccuracy": 0.001, "checkingType": "absdiff", "type": "jme", "variableReplacementStrategy": "originalfirst", "vsetRange": [0, 1], "showCorrectAnswer": true, "vsetRangePoints": 5, "marks": 1, "answer": "{mult1}*a+{mult1*add1-sub1}", "showPreview": true, "unitTests": [], "variableReplacements": [], "checkVariableNames": false, "answerSimplification": "all", "failureRate": 1, "expectedVariableNames": [], "scripts": {}, "showFeedbackIcon": true}], "unitTests": [], "variableReplacements": [], "scripts": {}, "prompt": "

Consider the following procedure:

\n

Pick a number $\\rightarrow$ add $\\var{add1}$ $\\rightarrow$ multiply by $\\var{mult1}$ $\\rightarrow$ subtract $\\var{sub1}$

\n

\n

If I start with the number $\\var{x[1]}$, what number do I end with? [[0]]

\n

If I end with the number $\\var{fx[2]}$, what number(s) could I start with? [[1]]

\n

If I end with the number $\\var{fx[3]}$, what number(s) could I start with? [[2]]

\n

If I start with the number $a$, what do I end with? [[3]]

\n

"}, {"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": "gy[0]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "gy[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": "gy[1]", "mustBeReducedPC": 0, "allowFractions": false, "unitTests": [], "variableReplacements": [], "maxValue": "gy[1]", "scripts": {}, "showFeedbackIcon": true, "correctAnswerStyle": "plain"}, {"numColumns": "1", "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "numRows": 1, "correctAnswer": "matrix([ymin[3]])", "type": "matrix", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "markPerCell": false, "marks": 1, "correctAnswerFractions": false, "allowResize": true, "unitTests": [], "variableReplacements": [], "scripts": {}, "tolerance": 0, "showFeedbackIcon": true, "allowFractions": false}, {"numColumns": "1", "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "numRows": 1, "correctAnswer": "matrix([ymin[2],ymax[2]])", "type": "matrix", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "markPerCell": false, "marks": 1, "correctAnswerFractions": false, "allowResize": true, "unitTests": [], "variableReplacements": [], "scripts": {}, "tolerance": 0, "showFeedbackIcon": true, "allowFractions": false}, {"extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "checkingAccuracy": 0.001, "checkingType": "absdiff", "type": "jme", "variableReplacementStrategy": "originalfirst", "vsetRange": [0, 1], "showCorrectAnswer": true, "vsetRangePoints": 5, "marks": 1, "answer": "(p+{add2})^2 - {sub2}", "showPreview": true, "unitTests": [], "variableReplacements": [], "checkVariableNames": false, "answerSimplification": "all", "failureRate": 1, "expectedVariableNames": [], "scripts": {}, "showFeedbackIcon": true}, {"numColumns": "1", "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "numRows": 1, "correctAnswer": "matrix([ymin[0],ymax[0]])", "type": "matrix", "variableReplacementStrategy": "originalfirst", "showCorrectAnswer": true, "markPerCell": false, "marks": 1, "correctAnswerFractions": false, "allowResize": true, "unitTests": [], "variableReplacements": [], "scripts": {}, "tolerance": 0, "showFeedbackIcon": true, "allowFractions": false}], "unitTests": [], "variableReplacements": [], "scripts": {}, "prompt": "

Consider the following procedure:

\n

Pick a number $\\rightarrow$ add $\\var{add2}$ $\\rightarrow$ square $\\rightarrow$ subtract $\\var{sub2}$

\n

\n

If I start with the number $\\var{ymax[0]}$, what number do I end with? [[0]]

\n

If I start with the number $\\var{ymin[1]}$, what number do I end with? [[1]]

\n

If I end with the number $\\var{gy[3]}$, what number(s) could I start with?

\n

[[2]]

\n

\n

If I end with the number $\\var{gy[2]}$, what number(s) could I start with?

\n

[[3]]

\n

\n

If I start with the number $p$, what do I end with? [[4]]

\n

Solve the equation $(d+\\var{add2})^2 - \\var{sub2} = \\var{gy[0]}$.

\n

[[5]]

"}], "variable_groups": [{"name": "part a", "variables": ["add1", "mult1", "sub1", "x", "fx", "add2", "sub2", "ymax", "ymin", "shift", "gy"]}], "variables": {"sub1": {"description": "", "name": "sub1", "group": "part a", "templateType": "anything", "definition": "random(1..7)"}, "add1": {"description": "", "name": "add1", "group": "part a", "templateType": "anything", "definition": "random(1..7)"}, "x": {"description": "", "name": "x", "group": "part a", "templateType": "anything", "definition": "vector(shuffle(-4..8)+shuffle(0..6))"}, "fx": {"description": "", "name": "fx", "group": "part a", "templateType": "anything", "definition": "x*mult1+vector(mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1,mult1*add1 - sub1)"}, "ymax": {"description": "", "name": "ymax", "group": "part a", "templateType": "anything", "definition": "vector(-add2,-add2,-add2,-add2)+shift"}, "gy": {"description": "", "name": "gy", "group": "part a", "templateType": "anything", "definition": "vector((ymax[0]+add2)^2-sub2,(ymax[1]+add2)^2-sub2,(ymax[2]+add2)^2-sub2,(ymax[3]+add2)^2-sub2)"}, "mult1": {"description": "", "name": "mult1", "group": "part a", "templateType": "anything", "definition": "random(2..5)"}, "ymin": {"description": "", "name": "ymin", "group": "part a", "templateType": "anything", "definition": "vector(-add2,-add2,-add2,-add2)-shift"}, "add2": {"description": "", "name": "add2", "group": "part a", "templateType": "anything", "definition": "random(1..5)"}, "shift": {"description": "", "name": "shift", "group": "part a", "templateType": "anything", "definition": "vector(shuffle(2..8 # 3)+[0])"}, "sub2": {"description": "", "name": "sub2", "group": "part a", "templateType": "anything", "definition": "random(1..5)"}}, "variablesTest": {"maxRuns": 100, "condition": ""}, "ungrouped_variables": [], "tags": [], "statement": "

If a question has more than one answer, increase the number of COLUMNS and list your answers in ASCENDING ORDER.

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

Simple procedures are given and student is asked to carry them out or un-do them.

\n

Version 1: bi and bii have the same answer. biii and biv both have two answers.

\n

Version 2: bi and bii have different answers. biii has two answers, biv has one answer.

\n

Version 3: bi and bii have different answer. biii has one answer, biv has two answers.

\n

Version 4: bi and bii have the same answer. biii has one answer, biv has two answers.

"}, "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/"}]}