// Numbas version: exam_results_page_options {"showstudentname": true, "feedback": {"intro": "

Welcome to this test, please answer both questions.

", "allowrevealanswer": true, "showanswerstate": true, "advicethreshold": 0, "showtotalmark": true, "showactualmark": true, "feedbackmessages": []}, "showQuestionGroupNames": false, "metadata": {"licence": "All rights reserved", "description": "

Open and answer

"}, "duration": 0, "percentPass": "50", "question_groups": [{"pickQuestions": 1, "pickingStrategy": "all-ordered", "name": "Group", "questions": [{"name": "Matthew's copy of Vicky's copy of Julie's copy of Plot the graph of a quadratic function", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Julie Crowley", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/113/"}, {"name": "Vicky Mason", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2687/"}, {"name": "Matthew Jones", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2846/"}], "variable_groups": [], "functions": {}, "variables": {"c": {"name": "c", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "random(-4..4 except 0)"}, "a": {"name": "a", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "random(-2,-1,-0.5,0.5,1,2)"}, "values": {"name": "values", "group": "Ungrouped variables", "templateType": "anything", "description": "", "definition": "map(a*x^2+c,x,-3..3)"}}, "statement": "

You are given the quadratic function $y=\\simplify[std]{{a}x^2+{c}}$

", "ungrouped_variables": ["a", "c", "values"], "metadata": {"description": "

Compute a table of values for a quadratic function. A JSXgraph (the graph paper) plot shows the curve going through the entered values. The student input is now disconnected from the graph so that they slide the points usually after they input the values and the answer fields are not updated.

", "licence": "Creative Commons Attribution 4.0 International"}, "tags": [], "preamble": {"js": "\nfunction dragpoint_board() {\n\n var scope = question.scope; \n var a = scope.variables.a.value;\n\n var c = scope.variables.c.value;\n var maxy = Math.max(Math.abs(a*9+c),Math.abs(c));\n \n var div = Numbas.extensions.jsxgraph.makeBoard('250px','400px',{boundingBox:[-5,maxy+3,5,-maxy-3],grid:true});\n $(question.display.html).find('#dragpoint').append(div);\n \n var board = div.board;\n \n //shorthand to evaluate a mathematical expression to a number\n function evaluate(expression) {\n try {\n var val = Numbas.jme.evaluate(expression,question.scope);\n return Numbas.jme.unwrapValue(val);\n }\n catch(e) {\n // if there's an error, return no number\n return NaN;\n }\n }\n \n // set up points array\n var num_points = 7;\n var points = [];\n \n \n // this function sets up the i^th point\n function make_point(i) {\n \n // calculate initial coordinates\n var x = i-(num_points-1)/2;\n \n // create an invisible vertical line for the point to slide along\n var line = board.create('line',[[x,0],[x,1]],{visible: false});\n \n // create the point\n var point = points[i] = board.create(\n 'glider',\n [i-(num_points-1)/2,0,line],\n {\n name:'',\n size:2,\n snapSizeY: 0.1, // the point will snap to y-coordinates which are multiples of 0.1\n snapToGrid: true\n }\n );\n \n // the contents of the input box for this point\n var studentAnswer = question.parts[2].gaps[i].display.studentAnswer;\n \n //Here I have commented out the functions which connect the student input to the graph and the filling in of the answer fields\n //when the student drags the points on the graph.\n \n // watch the student's input and reposition the point when it changes. \n // ko.computed(function() {\n // y = evaluate(studentAnswer());\n //if(!(isNaN(y)) && board.mode!=board.BOARD_MODE_DRAG) {\n // point.moveTo([x,y],100);\n // }\n // });\n \n // when the student drags the point, update the gapfill input\n point.on('drag',function(){\n var y = Numbas.math.niceNumber(point.Y());\n studentAnswer(y);\n });\n \n }\n \n // create each point\n for(var i=0;iThe graph of this function is:

", "choices": ["

An upwards-opening parabola

", "

A downwards-opening parabola

"], "customMarkingAlgorithm": "", "matrix": ["if(a>0,1,0)", "if(a>0,0,1)"], "extendBaseMarkingAlgorithm": true, "showFeedbackIcon": true, "displayColumns": 0, "showCorrectAnswer": true, "minMarks": 0, "distractors": ["", ""], "variableReplacements": []}, {"unitTests": [], "marks": 0, "variableReplacementStrategy": "originalfirst", "scripts": {}, "type": "gapfill", "prompt": "

Fill in the table of values for $y=\\simplify[std]{{a}x^2+{c}}$:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
$x$$-3$$-2$$-1$$0$$1$$2$$3$
$y$[[0]][[1]][[2]][[3]][[4]][[5]][[6]]
\n", "customMarkingAlgorithm": "", "gaps": [{"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*9+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*9+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*4+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*4+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*1+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*1+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*1+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*1+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*4+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*4+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}, {"unitTests": [], "marks": 0.5, "allowFractions": false, "minValue": "{a}*9+{c}", "variableReplacementStrategy": "originalfirst", "scripts": {}, "mustBeReducedPC": 0, "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "maxValue": "{a}*9+{c}", "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "correctAnswerStyle": "plain", "showFeedbackIcon": true, "showCorrectAnswer": true, "mustBeReduced": false, "variableReplacements": []}], "extendBaseMarkingAlgorithm": true, "sortAnswers": false, "showFeedbackIcon": true, "showCorrectAnswer": true, "variableReplacements": []}], "rulesets": {"std": ["all", "fractionNumbers"]}, "type": "question"}, {"name": "Simple addition", "extensions": [], "custom_part_types": [{"source": {"pk": 1, "author": {"name": "Christian Lawson-Perfect", "pk": 7}, "edit_page": "/part_type/1/edit"}, "name": "Yes/no", "short_name": "yes-no", "description": "

The student is shown two radio choices: \"Yes\" and \"No\". One of them is correct.

", "help_url": "", "input_widget": "radios", "input_options": {"correctAnswer": "if(eval(settings[\"correct_answer_expr\"]), 0, 1)", "hint": {"static": true, "value": ""}, "choices": {"static": true, "value": ["Yes", "No"]}}, "can_be_gap": true, "can_be_step": true, "marking_script": "mark:\nif(studentanswer=correct_answer,\n correct(),\n incorrect()\n)\n\ninterpreted_answer:\nstudentAnswer=0\n\ncorrect_answer:\nif(eval(settings[\"correct_answer_expr\"]),0,1)", "marking_notes": [{"name": "mark", "description": "This is the main marking note. It should award credit and provide feedback based on the student's answer.", "definition": "if(studentanswer=correct_answer,\n correct(),\n incorrect()\n)"}, {"name": "interpreted_answer", "description": "A value representing the student's answer to this part.", "definition": "studentAnswer=0"}, {"name": "correct_answer", "description": "", "definition": "if(eval(settings[\"correct_answer_expr\"]),0,1)"}], "settings": [{"name": "correct_answer_expr", "label": "Is the answer \"Yes\"?", "help_url": "", "hint": "An expression which evaluates to true or false.", "input_type": "mathematical_expression", "default_value": "true", "subvars": false}], "public_availability": "always", "published": true, "extensions": []}], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Matthew Jones", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2846/"}], "variable_groups": [], "variablesTest": {"maxRuns": "1", "condition": "1"}, "tags": [], "functions": {}, "metadata": {"licence": "None specified", "description": "

Simple addition, is it true?

"}, "statement": "

2+2=4

", "variables": {"prob_no": {"group": "Ungrouped variables", "templateType": "anything", "definition": "0", "name": "prob_no", "description": "

Probability of 4 not being 2+2

"}, "prob_yes": {"group": "Ungrouped variables", "templateType": "anything", "definition": "100", "name": "prob_yes", "description": "

The probability of 2+2=4 

"}}, "preamble": {"css": "", "js": ""}, "advice": "

It's true

", "rulesets": {}, "parts": [{"marks": 1, "variableReplacementStrategy": "originalfirst", "unitTests": [], "prompt": "

Probability of 4, when 2+2?

", "customMarkingAlgorithm": "", "scripts": {}, "showFeedbackIcon": true, "settings": {"correct_answer_expr": "true"}, "type": "yes-no", "variableReplacements": [], "extendBaseMarkingAlgorithm": true, "showCorrectAnswer": true}], "ungrouped_variables": ["prob_yes", "prob_no"], "type": "question"}]}], "timing": {"timeout": {"action": "none", "message": ""}, "allowPause": false, "timedwarning": {"action": "none", "message": ""}}, "navigation": {"preventleave": true, "allowregen": true, "onleave": {"action": "none", "message": ""}, "reverse": true, "showresultspage": "oncompletion", "browse": true, "showfrontpage": true}, "name": "Two question test (SCOs)", "type": "exam", "contributors": [{"name": "Matthew Jones", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2846/"}], "extensions": ["jsxgraph"], "custom_part_types": [{"source": {"pk": 1, "author": {"name": "Christian Lawson-Perfect", "pk": 7}, "edit_page": "/part_type/1/edit"}, "name": "Yes/no", "short_name": "yes-no", "description": "

The student is shown two radio choices: \"Yes\" and \"No\". One of them is correct.

", "help_url": "", "input_widget": "radios", "input_options": {"correctAnswer": "if(eval(settings[\"correct_answer_expr\"]), 0, 1)", "hint": {"static": true, "value": ""}, "choices": {"static": true, "value": ["Yes", "No"]}}, "can_be_gap": true, "can_be_step": true, "marking_script": "mark:\nif(studentanswer=correct_answer,\n correct(),\n incorrect()\n)\n\ninterpreted_answer:\nstudentAnswer=0\n\ncorrect_answer:\nif(eval(settings[\"correct_answer_expr\"]),0,1)", "marking_notes": [{"name": "mark", "description": "This is the main marking note. It should award credit and provide feedback based on the student's answer.", "definition": "if(studentanswer=correct_answer,\n correct(),\n incorrect()\n)"}, {"name": "interpreted_answer", "description": "A value representing the student's answer to this part.", "definition": "studentAnswer=0"}, {"name": "correct_answer", "description": "", "definition": "if(eval(settings[\"correct_answer_expr\"]),0,1)"}], "settings": [{"name": "correct_answer_expr", "label": "Is the answer \"Yes\"?", "help_url": "", "hint": "An expression which evaluates to true or false.", "input_type": "mathematical_expression", "default_value": "true", "subvars": false}], "public_availability": "always", "published": true, "extensions": []}], "resources": []}