// Numbas version: exam_results_page_options {"showstudentname": true, "timing": {"allowPause": true, "timeout": {"action": "none", "message": ""}, "timedwarning": {"action": "none", "message": ""}}, "duration": 0, "navigation": {"onleave": {"action": "none", "message": ""}, "showresultspage": "oncompletion", "browse": true, "preventleave": false, "allowregen": true, "reverse": true, "showfrontpage": true}, "feedback": {"showactualmark": true, "advicethreshold": 0, "feedbackmessages": [], "showtotalmark": true, "showanswerstate": true, "intro": "

This is Numbas.

\n

A Numbas test consists of one or more questions, each of which is split up into one or more parts.

\n

Try the questions in this demo exam to see Numbas' advanced features for yourself.

\n

Use the Try another question like this one button to re-randomise a question, and the Reveal answers button to see a worked solution along with model answers.

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

Some questions to show off features of Numbas, linked from the Numbas homepage.

"}, "percentPass": 0, "question_groups": [{"pickingStrategy": "all-ordered", "name": "Question part types", "pickQuestions": 1, "questions": [{"name": "Numbas demo: JME part", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Chris Graham", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/369/"}], "variables": {"num_terms": {"name": "num_terms", "description": "", "templateType": "anything", "definition": "3", "group": "Ungrouped variables"}, "powers": {"name": "powers", "description": "", "templateType": "anything", "definition": "sort(shuffle(list(0..8))[0..3])", "group": "Ungrouped variables"}, "coefficients": {"name": "coefficients", "description": "", "templateType": "anything", "definition": "repeat(random(-10..10 except 0),num_terms)", "group": "Ungrouped variables"}}, "parts": [{"unitTests": [], "marks": 0, "sortAnswers": false, "steps": [{"unitTests": [], "marks": 0, "variableReplacements": [], "showCorrectAnswer": true, "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)$:

", "customMarkingAlgorithm": "", "type": "information", "scripts": {}, "customName": "", "useCustomName": false, "extendBaseMarkingAlgorithm": true, "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst"}, {"valuegenerators": [{"name": "x", "value": ""}], "vsetRange": [0, 1], "unitTests": [], "checkingAccuracy": 0.001, "marks": 1, "vsetRangePoints": 5, "answer": "{coefficients[2]*powers[2]}*x^{powers[2]-1}", "variableReplacements": [], "type": "jme", "customName": "", "useCustomName": false, "checkVariableNames": false, "showFeedbackIcon": true, "showCorrectAnswer": true, "prompt": "

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

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

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

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

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

", "failureRate": 1, "checkingType": "absdiff", "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "showPreview": true, "variableReplacementStrategy": "originalfirst"}], "variableReplacements": [], "showCorrectAnswer": true, "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]]

", "stepsPenalty": "1", "gaps": [{"valuegenerators": [{"name": "x", "value": ""}], "vsetRange": [0, 1], "unitTests": [], "checkingAccuracy": 0.001, "marks": "4", "vsetRangePoints": 5, "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}", "showFeedbackIcon": true, "variableReplacements": [], "showCorrectAnswer": true, "extendBaseMarkingAlgorithm": true, "customMarkingAlgorithm": "", "checkingType": "absdiff", "type": "jme", "scripts": {}, "customName": "", "useCustomName": false, "failureRate": 1, "checkVariableNames": false, "showPreview": true, "variableReplacementStrategy": "originalfirst"}], "customMarkingAlgorithm": "", "type": "gapfill", "scripts": {}, "customName": "", "useCustomName": false, "extendBaseMarkingAlgorithm": true, "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst"}], "variable_groups": [], "tags": [], "ungrouped_variables": ["num_terms", "powers", "coefficients"], "variablesTest": {"maxRuns": 100, "condition": ""}, "preamble": {"js": "", "css": ""}, "metadata": {"description": "", "licence": "Creative Commons Attribution 4.0 International"}, "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

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

", "functions": {}, "rulesets": {}}, {"name": "Numbas demo: part types", "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": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "tags": [], "metadata": {"description": "

Showing off the part types.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

Each part of a Numbas question asks the student to enter an answer, and is marked automatically. There are several part types, each with their own input methods and settings.

\n

See this question on the public editor.

", "advice": "", "rulesets": {}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"b": {"name": "b", "group": "Ungrouped variables", "definition": "random(1 .. 10#1)", "description": "", "templateType": "randrange", "can_override": false}, "a": {"name": "a", "group": "Ungrouped variables", "definition": "random(1 .. 10#1)", "description": "", "templateType": "randrange", "can_override": false}, "d": {"name": "d", "group": "Ungrouped variables", "definition": "random(-10 .. 10#1)", "description": "", "templateType": "randrange", "can_override": false}, "c": {"name": "c", "group": "Ungrouped variables", "definition": "random(-10..10 except 0)", "description": "", "templateType": "anything", "can_override": false}, "f": {"name": "f", "group": "Ungrouped variables", "definition": "random(-10 .. 10#1)", "description": "", "templateType": "randrange", "can_override": false}}, "variablesTest": {"condition": "a=4 and b=8", "maxRuns": "1000"}, "ungrouped_variables": ["a", "b", "c", "d", "f"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "numberentry", "useCustomName": true, "customName": "Number entry", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The number entry part asks the student to write a single number. It's marked correct if it's in the accepted range.

\n

I eat 5 apples per day. How many apples do I eat in a week?

", "minValue": "35", "maxValue": "35", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "jme", "useCustomName": true, "customName": "Mathematical expression", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The mathematical expression part type asks the student to write a mathematical expression as their answer. It's marked correct if it's equivalent to the expected answer.

\n

Differentiate the following function:

\n

\\[ f(x) = \\simplify[all,!noLeadingMinus]{{c}x^2+{d}x+{f}} \\]

", "answer": "{2*c}x+{d}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": [{"name": "x", "value": ""}]}, {"type": "matrix", "useCustomName": true, "customName": "Matrix entry", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The matrix entry part type asks the student to enter the elements of a matrix. It's marked correct if the student's matrix is equal to the expected matrix.

\n

Enter a $3 \\times 3$ identity matrix.

", "correctAnswer": "id(3)", "correctAnswerFractions": false, "numRows": "3", "numColumns": "3", "allowResize": true, "tolerance": 0, "markPerCell": false, "allowFractions": false, "minColumns": 1, "maxColumns": 0, "minRows": 1, "maxRows": 0}, {"type": "patternmatch", "useCustomName": true, "customName": "Match text pattern", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The match text pattern part type asks the student to enter a short string of text. It's marked correct if it matches the pattern specified by the author.

\n

Write \"Numbas\".

", "answer": "Numbas", "displayAnswer": "Numbas", "caseSensitive": true, "partialCredit": "50", "matchMode": "exact"}, {"type": "1_n_2", "useCustomName": true, "customName": "Choose one from a list", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The choose one from a list part asks the student to choose one item from a list of options. Each option can award a different number of marks.

\n

Which fruit is biggest?

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": true, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["Apple", "Strawberry", "Watermelon"], "matrix": [0, 0, "1"], "distractors": ["", "", ""]}, {"type": "m_n_2", "useCustomName": true, "customName": "Choose several from a list", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The choose several from a list part type asks the student to select one or more items from a list. Each option can award or subtract a different number of marks.

\n

Tick every prime number in the list below.

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": true, "displayType": "checkbox", "displayColumns": "1", "minAnswers": 0, "maxAnswers": 0, "warningType": "none", "showCellAnswerState": true, "choices": ["13", "7", "2", "6", "9", "51"], "matrix": ["1", "1", "1", "-1", "-1", "-1"], "distractors": ["", "", "", "$6 = 2 \\times 3$.", "$9 = 3 \\times 3$.", "$51 = 3 \\times 17$."]}, {"type": "m_n_x", "useCustomName": true, "customName": "Match choices with answers", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The match choices with answers part asks the student to match each of a list of 'choices' with a corresponding 'answer'. Each possible pair can award a different number of marks.

\n

Match countries with their capital cities.

", "minMarks": 0, "maxMarks": 0, "minAnswers": 0, "maxAnswers": 0, "shuffleChoices": true, "shuffleAnswers": true, "displayType": "radiogroup", "warningType": "none", "showCellAnswerState": true, "choices": ["France", "Argentina", "China"], "matrix": [["1", 0, 0, 0, 0], [0, "1", 0, 0, 0], [0, 0, "1", 0, 0]], "layout": {"type": "all", "expression": ""}, "answers": ["Paris", "Buenos Aires", "Beijing", "Brussels", "Melbourne"]}, {"type": "yes-no", "useCustomName": true, "customName": "Custom part type - Yes/no", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

It's possible to create custom part types, or use one somebody else has published. A custom part type consists of settings for question authors, an input widget, and a marking algorithm. This part uses the \"Yes/No\" custom part type, which provides a simple means of asking if the student agrees with a statement.

\n

Was the abacus invented before the mobile phone?

", "settings": {"correct_answer_expr": "true"}}, {"type": "gapfill", "useCustomName": true, "customName": "Gap-fill", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The gap-fill part type allows you to include multiple input areas in one block of text. They're marked independently of each other, but submitted simultaneously, and all the feedback is shown together.

\n

My dog is 3 years older than my cat, who is half the dog's age. What are their ages?

\n

My dog's age: [[0]]

\n

My cat's age: [[1]]

", "gaps": [{"type": "numberentry", "useCustomName": true, "customName": "Dog's age", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "6", "maxValue": "6", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": true, "customName": "Cat's age", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "3", "maxValue": "3", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "showFractionHint": true, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}, {"name": "Numbas demo: multiple choice", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "parts": [{"extendBaseMarkingAlgorithm": true, "prompt": "

John, Paul, George and Ringo stand in alphabetical order. Who goes first?

", "adaptiveMarkingPenalty": 0, "maxMarks": 0, "showCellAnswerState": true, "showFeedbackIcon": true, "customName": "Choose one from a list", "unitTests": [], "customMarkingAlgorithm": "", "scripts": {}, "useCustomName": true, "choices": ["

John

", "

Paul

", "

George

", "

Ringo

"], "showCorrectAnswer": true, "variableReplacements": [], "marks": 0, "displayType": "radiogroup", "displayColumns": 0, "shuffleChoices": false, "distractors": ["J comes after G in the alphabet, so John comes after George", "P comes after J in the alphabet, so Paul comes after John", "", "R comes after P in the alphabet, so Ringo comes after Paul"], "variableReplacementStrategy": "originalfirst", "matrix": [0, 0, "1", 0], "type": "1_n_2", "minMarks": 0}, {"extendBaseMarkingAlgorithm": true, "prompt": "

Which of the following numbers are congruent to $1$ modulo $3$?

", "adaptiveMarkingPenalty": 0, "maxMarks": 0, "showCellAnswerState": true, "showFeedbackIcon": true, "customName": "Choose several from a list", "unitTests": [], "customMarkingAlgorithm": "", "scripts": {}, "minAnswers": "0", "useCustomName": true, "choices": ["

1

", "

2

", "

3

", "

4

", "

5

", "

6

", "

7

", "

8

", "

9

"], "showCorrectAnswer": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "marks": 0, "displayType": "checkbox", "displayColumns": "3", "shuffleChoices": false, "distractors": ["", "2 is not congruent to 1, mod 3", "3 is congruent to 0, mod 3", "", "5 is congruent to 2, mod 3", "6 is congruent to 0, mod 3", "", "8 is congruent to 2, mod 3", "9 is congruent to 0, mod 3"], "maxAnswers": "0", "matrix": ["1", "-1", "-1", "1", "-1", "-1", "1", "-1", "-1"], "type": "m_n_2", "warningType": "none", "minMarks": 0}, {"extendBaseMarkingAlgorithm": true, "adaptiveMarkingPenalty": 0, "maxMarks": 0, "showCellAnswerState": true, "showFeedbackIcon": true, "customName": "Match choices with answers", "unitTests": [], "customMarkingAlgorithm": "", "scripts": {}, "shuffleChoices": true, "useCustomName": true, "choices": ["Dodo", "Blue whale", "Human", "Pterodactyl"], "showCorrectAnswer": true, "variableReplacements": [], "shuffleAnswers": true, "variableReplacementStrategy": "originalfirst", "marks": 0, "layout": {"expression": "", "type": "all"}, "displayType": "checkbox", "minAnswers": 0, "maxAnswers": 0, "matrix": [["1", "-1", "1"], ["1", "-1", "-1"], ["1", "-1", "-1"], ["-1", "1", "1"]], "type": "m_n_x", "warningType": "none", "minMarks": 0, "answers": ["Warm-blooded", "Can fly", "Extinct"]}], "statement": "

Numbas has comprehensive support for multiple choice questions. The order of choices can be randomised, the marking matrix can be calculated from question variables, and you can write specific feedback for each choice.

\n

See this question in the public editor

", "rulesets": {}, "ungrouped_variables": [], "variables": {}, "metadata": {"description": "", "licence": "Creative Commons Attribution 4.0 International"}, "preamble": {"css": "", "js": ""}, "tags": [], "functions": {}, "advice": "", "variablesTest": {"condition": "", "maxRuns": 100}, "variable_groups": []}]}, {"pickingStrategy": "all-ordered", "name": "Video", "pickQuestions": 1, "questions": [{"name": "Numbas demo: video", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "variable_groups": [], "parts": [{"stepsPenalty": 1, "gaps": [{"vsetrange": [11, 12], "showpreview": true, "marks": 3, "notallowed": {"partialCredit": 0, "strings": ["."], "message": "

Input all numbers as fractions or integers and not decimals.

", "showStrings": false}, "answer": "({d-a*c}/{b-a})*ln(x+{a})+({d-b*c}/{a-b})*ln(x+{b})+C", "vsetrangepoints": 5, "variableReplacements": [], "showCorrectAnswer": true, "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "scripts": {}, "checkingtype": "absdiff", "checkvariablenames": false, "answersimplification": "std", "variableReplacementStrategy": "originalfirst"}], "type": "gapfill", "marks": 0, "scripts": {}, "steps": [{"type": "information", "marks": 0, "scripts": {}, "variableReplacements": [], "showCorrectAnswer": true, "prompt": "

First of all, factorise the denominator.

\n

You have to find $a$ and $b$ such that $\\simplify[std]{x^2+{a+b}*x+{a*b}=(x+a)*(x+b)}$

\n

Then use partial fractions to write:
\\[\\simplify[std]{({c}*x+{d})/((x +a)*(x+b)) = A/(x+a)+B/(x+b)}\\]

\n

for suitable integers or fractions $A$ and $B$.

\n

This video solves a similar, simpler example.

\n

", "variableReplacementStrategy": "originalfirst"}], "variableReplacements": [], "showCorrectAnswer": true, "prompt": "

$I=$ [[0]]

\n

Enter the constant of integration as $C$.

\n

Click on Show steps for help if you need it: you'll be given a hint, and see a video which solves a similar example.

", "variableReplacementStrategy": "originalfirst"}], "statement": "

It's easy to include videos in Numbas questions. In this question, if the student gets stuck they can click on \"Show steps\" to be given a hint, and shown a video of someone working through a similar problem.

\n

See this question in the public editor

\n

Find the following integral.

\n

\\[I = \\simplify[std]{Int(({c}*x+{d})/(x^2+{a+b}*x+{a*b}),x )}\\]

", "showQuestionGroupNames": false, "tags": ["2 distinct linear factors", "Calculus", "calculus", "completing the square", "constant of integration", "factorising a quadratic", "indefinite integration", "integrals", "integration", "logarithms", "partial fractions", "Steps", "steps", "two distinct linear factors", "video"], "ungrouped_variables": ["a", "c", "b", "d", "s3", "s2", "s1", "b1", "d1"], "functions": {}, "preamble": {"js": "", "css": ""}, "metadata": {"description": "

Customised for the Numbas demo exam

\n

Factorise $x^2+cx+d$ into 2 distinct linear factors and then find $\\displaystyle \\int \\frac{ax+b}{x^2+cx+d}\\;dx,\\;a \\neq 0$ using partial fractions or otherwise.

\n

Video in Show steps.

", "notes": "\n \t\t \t\t

5/08/2012:

\n \t\t \t\t

Added tags.

\n \t\t \t\t

Added description.

\n \t\t \t\t

Added decimal point as forbidden string.

\n \t\t \t\t

Note the checking range is chosen so that the arguments of the log terms are always positive - could have used abs - might be better?

\n \t\t \t\t

Improved display of Advice. 

\n \t\t \t\t

Added information about Show steps, also introduced penalty of 1 mark.

\n \t\t \t\t

Added !noLeadingMinus to ruleset std for display purposes.

\n \t\t \n \t\t", "licence": "Creative Commons Attribution 4.0 International"}, "question_groups": [{"name": "", "pickingStrategy": "all-ordered", "questions": [], "pickQuestions": 0}], "type": "question", "variablesTest": {"maxRuns": 100, "condition": ""}, "advice": "

First we factorise $\\simplify[std]{x^2+{a+b}*x+{a*b}=(x+{a})*(x+{b})}$. You can do this by spotting the factors or by completing the square.

\n

Next we use partial fractions to find $A$ and $B$ such that

\n

\\[ \\simplify[std]{({c}*x+{d})/((x +{a})*(x+{b})) = A/(x+{a})+B/(x+{b})} \\]

\n

Multiplying both sides of the equation by $\\displaystyle \\simplify[std]{1/((x +{a})*(x+{b}))}$, we obtain

\n

\\begin{align}
&& \\simplify[std]{A*(x+{b})+B*(x+{a})} &= \\simplify[std]{{c}*x+{d}}\\\\
\\Rightarrow && \\simplify[std]{(A+B)*x+{b}*A+{a}*B} &= \\simplify[std]{{c}*x+{d}}
\\end{align}

\n

Coefficients of similar powers of $x$ on each side of the equation must be equal, so we can write down two new equations identifying the coefficients on each side:

\n

Constant term: $\\simplify[std]{{b}*A+{a}*B = {d}}$

\n

Coefficent of $x$: $ \\simplify[std]{A+B={c}}$ which gives $A =\\var{c} -B$

\n

On solving these equations, we obtain $\\displaystyle \\simplify[std]{A = {d-a*c}/{b-a}}$ and $\\displaystyle \\simplify[std]{B={d-b*c}/{a-b}}$, which gives

\n

\\[ \\simplify[std]{({c}*x+{d})/((x +{a})*(x+{b})) = ({d-a*c}/{b-a})*(1/(x+{a}) )+({d-b*c}/{a-b})*(1/(x+{b}))} \\]

\n

So

\n

\\begin{align}
I &= \\simplify[std]{int(({c}*x+{d})/(x^2+{a+b}*x+{a*b}),x )} \\\\[0.5em]
&= \\simplify[std]{int(({c}*x+{d})/((x +{a})*(x+{b})),x )} \\\\[0.5em]
&= \\simplify[std]{({d-a*c}/{b-a})*(int(1/(x+{a}),x)) +({d-b*c}/{a-b})int(1/(x+{b}),x)} \\\\[0.5em]
&= \\simplify[std]{({d-a*c}/{b-a})*ln(x+{a})+({d-b*c}/{a-b})*ln(x+{b})+C}
\\end{align}

", "variables": {"c": {"name": "c", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "random(2..9)"}, "s2": {"name": "s2", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "random(1,-1)"}, "b1": {"name": "b1", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "s2*random(1..9)"}, "a": {"name": "a", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "s1*random(1..9)"}, "d": {"name": "d", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "if(d1=a*c,if(d1+1=b*c,d1+2,d1+1),if(d1=b*c,if(d1+1=a*c,d1+2,d1+1),d1))"}, "b": {"name": "b", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "if(b1=a,b1+s3,b1)"}, "s3": {"name": "s3", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "random(1,-1)"}, "d1": {"name": "d1", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "s3*random(1..9)"}, "s1": {"name": "s1", "description": "", "templateType": "anything", "group": "Ungrouped variables", "definition": "random(1,-1)"}}, "rulesets": {"std": ["all", "!collectNumbers", "fractionNumbers", "!noLeadingMinus"]}}]}, {"pickingStrategy": "all-ordered", "name": "STEM", "pickQuestions": 1, "questions": [{"name": "Amount of substance needed to prepare a solution", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Bill Foster", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/6/"}, {"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}, {"name": "Chris Graham", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/369/"}], "statement": "

How would you prepare the following solutions?

\n

Note that you can click on Show steps for each of the following questions. There you can follow a sequence of steps to get the answer.

\n

However, you should be able (perhaps after practice) to answer these questions without using Show steps.

", "variablesTest": {"condition": "", "maxRuns": 100}, "variables": {"z9": {"definition": "precround(z5*z6*180.2/1000, 3)", "name": "z9", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z7": {"definition": "precround(z1*z2/1000, 3)", "name": "z7", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z4": {"definition": "random(0.1..3#0.1)", "name": "z4", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z3": {"definition": "random(5..100#5)", "name": "z3", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z5": {"definition": "random(0.1..0.9#0.1)", "name": "z5", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z8": {"definition": "precround(z3*z4*74.5/1000, 3)", "name": "z8", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z2": {"definition": "random(3..9#1)", "name": "z2", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z6": {"definition": "random(5..100#5)", "name": "z6", "description": "", "templateType": "anything", "group": "Ungrouped variables"}, "z1": {"definition": "random(100..500#5)", "name": "z1", "description": "", "templateType": "anything", "group": "Ungrouped variables"}}, "tags": [], "variable_groups": [], "parts": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "stepsPenalty": 0, "type": "gapfill", "variableReplacementStrategy": "originalfirst", "useCustomName": false, "adaptiveMarkingPenalty": 0, "gaps": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "allowFractions": false, "mustBeReduced": false, "minValue": "{z7 - 0.001}", "variableReplacements": [], "marks": 1, "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "{z7 + 0.001}", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}], "showFeedbackIcon": true, "prompt": "

$\\var{z1}~\\mathrm{ml}$ of a sucrose solution at a concentration $\\var{z2}~\\mathrm{g}/\\mathrm{l}$.

\n

Grams of sucrose needed = [[0]] $\\mathrm{g}$ in $\\var{z1}~\\mathrm{ml}$ (to $3$ decimal places).

", "steps": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "information", "variableReplacementStrategy": "originalfirst", "customMarkingAlgorithm": "", "showFeedbackIcon": true, "prompt": "

In this question you are given the required volume of the solution, $\\var{z1}~\\mathrm{ml}$, and the required concentration, $\\var{z2}~\\mathrm{g}/\\mathrm{l}$. You need to calculate how many grams are required per $\\var{z1}~\\mathrm{ml}$ to achieve this concentration. 

", "useCustomName": false, "variableReplacements": [], "marks": 0, "customName": "", "adaptiveMarkingPenalty": 0, "showCorrectAnswer": true, "unitTests": []}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

The first step is to express the required concentration in $\\mathrm{ml}$ by dividing by $1000$.

", "allowFractions": false, "mustBeReduced": false, "minValue": "z2/1000-0.001", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "z2/1000+0.001", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

Now multiply this by $\\var{z1}$ to obtain the amount of sucrose needed in the given volume of solution.

", "allowFractions": false, "mustBeReduced": false, "minValue": "z1*z2/1000-0.001", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "z1*z2/1000+0.001", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}], "sortAnswers": false, "variableReplacements": [], "marks": 0, "customName": "", "customMarkingAlgorithm": "", "showCorrectAnswer": true, "unitTests": []}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "stepsPenalty": 0, "type": "gapfill", "variableReplacementStrategy": "originalfirst", "useCustomName": false, "adaptiveMarkingPenalty": 0, "gaps": [{"extendBaseMarkingAlgorithm": true, "precisionMessage": "

You have not given your answer to the correct precision.

", "precisionPartialCredit": 0, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "allowFractions": false, "mustBeReduced": false, "minValue": "{z8 - 0.001}", "variableReplacements": [], "marks": 1, "strictPrecision": true, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "mustBeReducedPC": 0, "precision": "3", "customMarkingAlgorithm": "", "maxValue": "{z8 + 0.001}", "precisionType": "dp", "correctAnswerStyle": "plain", "useCustomName": false, "showPrecisionHint": false, "customName": ""}], "showFeedbackIcon": true, "prompt": "

$\\var{z3}~\\mathrm{ml}$ of a $\\var{z4}~\\mathrm{molar}$ (can be expressed as $\\mathrm{mol}/\\mathrm{l}$ or $\\mathrm{mol~l}^{-1}$, but usually expressed as $\\mathrm{M}$) solution of KCl (relative molecular mass $74.5$) in water.

\n

Grams of KCl needed = [[0]] $\\mathrm{g}$ in $\\var{z3}~\\mathrm{ml}$ (answer to $3$ decimal places).

", "steps": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "information", "variableReplacementStrategy": "originalfirst", "customMarkingAlgorithm": "", "showFeedbackIcon": true, "prompt": "

The first step is to express $1~\\mathrm{mol}$ of KCl in grams.

\n

$1~\\mathrm{mol}$ solution = $74.5~\\mathrm{g}$ KCl in $1~\\mathrm{L}$

", "useCustomName": false, "variableReplacements": [], "marks": 0, "customName": "", "adaptiveMarkingPenalty": 0, "showCorrectAnswer": true, "unitTests": []}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

Next, express $\\var{z4}~\\mathrm{mol}$ as grams of KCl by multiplying $74.5~\\mathrm{g}$ by $\\var{z4}$.

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

Since $1~\\mathrm{L} = 1000~\\mathrm{ml}$ we can find the number of grams in $1\\mathrm{ml}$ by dividing by $1000$.

", "allowFractions": false, "mustBeReduced": false, "minValue": "74.5*z4/1000", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "74.5*z4/1000", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

Finally, to get the number of grams needed to give $\\var{z3}~\\mathrm{ml}$ of $\\var{z4}~\\mathrm{M}$ KCl solution you multiply this result by $\\var{z3}$. Give your answer here to 3 decimal places.

", "allowFractions": false, "mustBeReduced": false, "minValue": "74.5*z3*z4/1000-0.001", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "74.5*z3*z4/1000+0.001", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}], "sortAnswers": false, "variableReplacements": [], "marks": 0, "customName": "", "customMarkingAlgorithm": "", "showCorrectAnswer": true, "unitTests": []}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "stepsPenalty": 0, "type": "gapfill", "variableReplacementStrategy": "originalfirst", "useCustomName": false, "adaptiveMarkingPenalty": 0, "gaps": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "allowFractions": false, "mustBeReduced": false, "minValue": "{z9 - 0.001}", "variableReplacements": [], "marks": 1, "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "{z9 + 0.001}", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}], "showFeedbackIcon": true, "prompt": "

$\\var{z5}~\\mathrm{L}$ of $\\var{z6}~\\mathrm{millimolar}$ ($\\mathrm{mmol}/\\mathrm{l}$, or $\\mathrm{mmol}^{-1}$ or $\\mathrm{mM}$) glucose (relative molecular mass $180.2$) in water.

\n

Grams of glucose needed = [[0]] $\\mathrm{g}$ in $\\var{z5}~\\mathrm{L}$ (answer to $3$ decimal places).

", "steps": [{"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "information", "variableReplacementStrategy": "originalfirst", "customMarkingAlgorithm": "", "showFeedbackIcon": true, "prompt": "

The first step is to express $1~\\mathrm{mol}$ of glucose in grams in $1~\\mathrm{L}$.

\n

$1~\\mathrm{mol}$ solution = $180.2~\\mathrm{g}$ glucose in $1~\\mathrm{L}$

", "useCustomName": false, "variableReplacements": [], "marks": 0, "customName": "", "adaptiveMarkingPenalty": 0, "showCorrectAnswer": true, "unitTests": []}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

Multiply this by $\\var{z5}$ to obtain the number of grams of glucose in $\\var{z5}~\\mathrm{l}$ of $1~\\mathrm{mol}$ solution.

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

Now you convert to $\\mathrm{mmol}$ by dividing by $1000$.

", "allowFractions": false, "mustBeReduced": false, "minValue": "180.2*z5/1000", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "180.2*z5/1000", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}, {"extendBaseMarkingAlgorithm": true, "scripts": {}, "type": "numberentry", "variableReplacementStrategy": "originalfirst", "adaptiveMarkingPenalty": 0, "showFeedbackIcon": true, "prompt": "

So for $\\var{z6}~\\mathrm{mmol}$ we multiply by $\\var{z6}$ to get the required number of grams of glucose in $\\var{z5}~\\mathrm{L}$. Give your answer here to 3 decimal places.

", "allowFractions": false, "mustBeReduced": false, "minValue": "180.2*z5*z6/1000-0.001", "variableReplacements": [], "marks": "0", "mustBeReducedPC": 0, "showCorrectAnswer": true, "unitTests": [], "correctAnswerFraction": false, "notationStyles": ["plain", "en", "si-en"], "showFractionHint": true, "customMarkingAlgorithm": "", "maxValue": "180.2*z5*z6/1000+0.001", "correctAnswerStyle": "plain", "useCustomName": false, "customName": ""}], "sortAnswers": false, "variableReplacements": [], "marks": 0, "customName": "", "customMarkingAlgorithm": "", "showCorrectAnswer": true, "unitTests": []}], "ungrouped_variables": ["z8", "z9", "z4", "z5", "z6", "z7", "z1", "z2", "z3"], "rulesets": {}, "preamble": {"css": "", "js": ""}, "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Preparing solutions to given concentrations/dilutions.

"}, "functions": {}, "advice": "

These question test your ability to convert between different SI units.

\n

a)

\n

Here, you are given the required volume of the solution, $\\var{z1}~\\mathrm{ml}$, and the required concentration, $3~\\mathrm{g}/\\mathrm{l}$. You need to calculate how many grams are required per $\\var{z1}~\\mathrm{ml}$. Therefore,

\n

$\\var{z2}~\\mathrm{g}/\\mathrm{l} = \\frac{\\var{z2}~\\mathrm{g}}{1000~\\mathrm{ml}} = \\frac{\\var{z2}~\\mathrm{g}}{\\var{1000/z1} \\times \\var{z1}~\\mathrm{ml}} = \\var{z1*z2/1000}~\\mathrm{g}$ in $\\var{z1}~\\mathrm{ml}$.

\n

b)

\n

This can be calculated in a similar way.

\n

$1~\\mathrm{mol}$ solution = $74.5$ KCl in $1~\\mathrm{L}$.

\n

$\\var{z4}~\\mathrm{mol}$ solution = $\\var{z4} \\times 74.5~\\mathrm{g}$ KCl in $1~\\mathrm{L}$.

\n

$\\var{z4}~\\mathrm{mol}$ solution = $\\var{z4*74.5}~\\mathrm{g}$ KCl in $1000~\\mathrm{ml}$.

\n

$\\var{z4}~\\mathrm{mol}$ solution = $\\frac{\\var{z4*74.5}}{1000}~\\mathrm{g}$ KCl in $1~\\mathrm{ml}$.

\n

$\\var{z4}~\\mathrm{mol}$ solution = $\\var{z3} \\times \\var{z4*74.5/1000}~\\mathrm{g}$ KCl in $\\var{z3}~\\mathrm{ml}$.

\n

$\\var{z4}~\\mathrm{mol}$ solution = $\\var{z8}~\\mathrm{g}$ KCl in $\\var{z3}~\\mathrm{ml}$.

\n

c)

\n

Again, this is similar.

\n

$1~\\mathrm{mol}$ solution = $180.2~\\mathrm{g}$ glucose in $1~\\mathrm{L}$.

\n

$1~\\mathrm{mol}$ solution = $\\var{z5} \\times 180.2~\\mathrm{g}$ glucose in $\\var{z5}~\\mathrm{L}$.

\n

$1000~\\mathrm{mmol}$ solution = $\\var{z5} \\times 180.2~\\mathrm{g}$ glucose in $\\var{z5}~\\mathrm{L}$.

\n

$1~\\mathrm{mmol}$ solution = $\\frac{\\var{z5} \\times 180.2}{1000}~\\mathrm{g}$ glucose in $\\var{z5}~\\mathrm{L}$.

\n

$\\var{z6}~\\mathrm{mmol}$ solution = $\\frac{\\var{z6} \\times \\var{z5} \\times 180.2}{1000}~\\mathrm{g}$ glucose in $\\var{z5}~\\mathrm{L}$.

\n

$\\var{z6}~\\mathrm{mmol}$ solution = $\\var{z9}~\\mathrm{g}$ glucose in $\\var{z5}~\\mathrm{L}$.

"}, {"name": "Volume of a swimming pool", "extensions": [], "custom_part_types": [], "resources": [["question-resources/pool_TB2Lho6.svg", "/srv/numbas/media/question-resources/pool_TB2Lho6.svg"]], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "variablesTest": {"condition": "", "maxRuns": 100}, "variables": {"volume": {"description": "

The volume of the pool, in m3

", "templateType": "anything", "definition": "cross_section*width", "name": "volume", "group": "Ungrouped variables"}, "depth2": {"description": "", "templateType": "anything", "definition": "depth1+random(2..5)", "name": "depth2", "group": "Ungrouped variables"}, "length": {"description": "", "templateType": "anything", "definition": "random(25,50)", "name": "length", "group": "Ungrouped variables"}, "num_lengths": {"description": "

Number of lengths Alex swims

", "templateType": "anything", "definition": "random(10..100)", "name": "num_lengths", "group": "Ungrouped variables"}, "total_distance_string": {"description": "", "templateType": "anything", "definition": "if(total_distance>=1000, total_distance/1000+' kilometres',total_distance+' metres')", "name": "total_distance_string", "group": "Ungrouped variables"}, "cross_section": {"description": "

The cross-section of the pool - the area of the trapezium face.

", "templateType": "anything", "definition": "(depth2+depth1)*length/2", "name": "cross_section", "group": "Ungrouped variables"}, "width": {"description": "", "templateType": "anything", "definition": "random(10..50#5)", "name": "width", "group": "Ungrouped variables"}, "total_distance": {"description": "

Total distance Alex swims

", "templateType": "anything", "definition": "length*num_lengths", "name": "total_distance", "group": "Ungrouped variables"}, "depth1": {"description": "", "templateType": "anything", "definition": "random(2..5)", "name": "depth1", "group": "Ungrouped variables"}}, "tags": [], "advice": "", "statement": "

Alex visited a swimming pool. The length of the pool is {length} metres.

", "variable_groups": [], "metadata": {"description": "

Work out the volume of a prism with a trapezium cross-section.

", "licence": "Creative Commons Attribution 4.0 International"}, "functions": {}, "ungrouped_variables": ["length", "width", "depth1", "depth2", "num_lengths", "total_distance", "total_distance_string", "cross_section", "volume"], "preamble": {"js": "", "css": ""}, "parts": [{"showCorrectAnswer": true, "customMarkingAlgorithm": "", "marks": 0, "scripts": {}, "variableReplacements": [], "extendBaseMarkingAlgorithm": true, "gaps": [{"showCorrectAnswer": true, "variableReplacements": [], "marks": 1, "customMarkingAlgorithm": "", "minValue": "num_lengths", "maxValue": "num_lengths", "scripts": {}, "correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "allowFractions": false, "mustBeReducedPC": 0, "type": "numberentry", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst", "unitTests": [], "correctAnswerStyle": "plain"}], "type": "gapfill", "unitTests": [], "sortAnswers": false, "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst", "prompt": "

Alex swims a total of {total_distance_string}.

\n

How many lengths did Alex swim?

\n

[[0]] lengths

"}, {"showCorrectAnswer": true, "type": "information", "customMarkingAlgorithm": "", "marks": 0, "scripts": {}, "prompt": "

Here is a sketch of the swimming pool.

\n

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

Work out the cross section of the pool.

\n

[[0]] m2

"}, {"showCorrectAnswer": true, "customMarkingAlgorithm": "", "marks": 0, "scripts": {}, "variableReplacements": [], "extendBaseMarkingAlgorithm": true, "gaps": [{"showCorrectAnswer": true, "variableReplacements": [], "marks": 1, "customMarkingAlgorithm": "", "minValue": "volume*1000", "maxValue": "volume*1000", "scripts": {}, "correctAnswerFraction": false, "extendBaseMarkingAlgorithm": true, "allowFractions": false, "mustBeReducedPC": 0, "type": "numberentry", "mustBeReduced": false, "notationStyles": ["plain", "en", "si-en"], "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst", "unitTests": [], "correctAnswerStyle": "plain"}], "type": "gapfill", "unitTests": [], "sortAnswers": false, "showFeedbackIcon": true, "variableReplacementStrategy": "originalfirst", "prompt": "

Work out the capacity of the pool in litres.

\n

(1 m3 = 1000 litres)

\n

[[0]] litres

"}], "rulesets": {}, "type": "question"}]}, {"pickingStrategy": "all-ordered", "name": "Adaptive marking", "pickQuestions": 1, "questions": [{"name": "Adaptive marking: Independent two sample t-test", "extensions": ["stats"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "tags": ["average", "data analysis", "differences", "elementary statistics", "hypothesis testing", "mean", "standard deviation", "statistics", "stats", "t-test", "two sample t-test", "variance"], "metadata": {"description": "

Two sample t-test to see if there is a difference between scores on questions between two groups when the questions are asked in a different order.

", "licence": "Creative Commons Attribution 4.0 International"}, "statement": "

An educational psychologist claimed that the order in which questions were asked affected the student’s ability to answer them correctly and hence their total score. In order to test this, $20$ students were randomly divided into two groups of $10$. The first group were given questions in increasing order of difficulty and the second group in decreasing order of difficulty. The ordered test scores obtained were:

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
Group 1{r1[0]}{r1[1]}{r1[2]}{r1[3]}{r1[4]}{r1[5]}{r1[6]}{r1[7]}{r1[8]}{r1[9]}
Group 2{r2[0]}{r2[1]}{r2[2]}{r2[3]}{r2[4]}{r2[5]}{r2[6]}{r2[7]}{r2[8]}{r2[9]}
\n

Carry out a two-sample t-test to decide if there is evidence of a difference in the average test scores for the two sets of students.

", "advice": "

We test the following hypothesis,

\n

$H_0:\\; \\mu_1=\\mu_2$ versus $H_1:\\; \\mu_1 \\neq \\mu_2$

\n

We find that the mean score of Group 1 is $\\overline{x}_1=\\var{mean1}$ with standard deviation $s_1=\\var{sd1}$ and the mean score of Group 2 is $\\overline{x}_2=\\var{mean2}$ with standard deviation $s_2=\\var{sd2}$.

\n

(All calculated to 3 decimal places.)

\n

Using the formula for the two-sample $t$-statistic as  shown above with $n_1=n_2=10$:

\n

The estimate of the pooled variance is calculated to be:

\n

\\[s^2=\\frac{(n_1-1)s_1^2+(n_2-1)s_2^2}{n_1+n_2-2}= \\frac{\\var{n1-1}\\times \\var{sd1}^2+\\var{n2-1}\\times \\var{sd2}^2}{\\var{n1+n2-2}}=\\var{s^2}.\\] 

\n

Hence $s = \\sqrt{\\var{s^2}}=\\var{s}$ to 3 decimal places.

\n

We find that the t-statistic has value:

\n

\\begin{align}
T &= \\frac{(\\overline{x}_1-\\overline{x}_2)-(\\mu_1-\\mu_2)}{s\\sqrt{\\frac{1}{n_1}+\\frac{1}{n_2}}} \\\\
&= \\frac{(\\var{mean1}-\\var{mean2})-(0)}{\\var{s}\\sqrt{\\frac{1}{\\var{n1}}+\\frac{1}{\\var{n2}}}} \\\\
&= \\var{t_statistic}
\\end{align}

\n

Our test statistic is $|T|=\\var{abs(t_statistic)}$.

\n

Given that we have $n_1+n_2-2=18$ degrees of freedom, we look up this value on the T-distribution table for $t_{18}$

\n

\\[\\begin{array}{r|rrrrr}&0.10&0.05&0.01&0.001\\\\\\hline18&1.734&2.101&2.878&3.922\\end{array}\\]

\n

We see that the t-statistic {t_statistic_range} and the table tells us that the $p$ value {p_value_range}.

\n

Hence we conclude that we {reject} the null hypothesis. There is {evidence_strength} evidence of a difference between the average scores of the two groups.

", "rulesets": {"std": ["all", "fractionNumbers", "!collectNumbers", "!noLeadingMinus"]}, "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"p_value_range": {"name": "p_value_range", "group": "Advice messages", "definition": "['is less than $0.001$','lies between $0.001$ and $0.01$','lies between $0.01$ and $0.05$','lies between $0.05$ and $0.10$','is greater than $0.10$'][scenario]", "description": "

Describe where the p-value lies in relation to the critical values

", "templateType": "anything", "can_override": false}, "sigma2": {"name": "sigma2", "group": "Setup", "definition": "random(8..10#0.2)", "description": "

Population standard deviation of sample 2

", "templateType": "anything", "can_override": false}, "t99": {"name": "t99", "group": "Critical t-values", "definition": "2.878", "description": "", "templateType": "anything", "can_override": false}, "n2": {"name": "n2", "group": "Setup", "definition": "10", "description": "

Size of sample 2

", "templateType": "anything", "can_override": false}, "t999": {"name": "t999", "group": "Critical t-values", "definition": "3.922", "description": "", "templateType": "anything", "can_override": false}, "t_statistic_range": {"name": "t_statistic_range", "group": "Advice messages", "definition": "['is greater than $\\\\var{t999}$','lies between $\\\\var{t99}$ and $\\\\var{t999}$','lies between $\\\\var{t95}$ and $\\\\var{t99}$','lies between $\\\\var{t90}$ and $\\\\var{t95}$','is less than $\\\\var{t90}$'][scenario]", "description": "

Describe where the t-statistic lies in relation to the critical values

", "templateType": "anything", "can_override": false}, "mu2": {"name": "mu2", "group": "Setup", "definition": "random(65..75#0.5)", "description": "

Population mean of sample 2

", "templateType": "anything", "can_override": false}, "evidence_strength": {"name": "evidence_strength", "group": "Advice messages", "definition": "['very strong','strong','slight','no','no'][scenario]", "description": "

How much evidence is there against the null hypothesis?

", "templateType": "anything", "can_override": false}, "n1": {"name": "n1", "group": "Setup", "definition": "10", "description": "

Size of sample 1

", "templateType": "anything", "can_override": false}, "mu1": {"name": "mu1", "group": "Setup", "definition": "random(55..75#0.5)", "description": "

Population mean of sample 1 (we'll generate samples from different distributions to produce different outcomes)

", "templateType": "anything", "can_override": false}, "reject": {"name": "reject", "group": "Advice messages", "definition": "if(scenario<2,'do reject','do not reject')", "description": "

Do we reject the null hypothesis?

", "templateType": "anything", "can_override": false}, "p_value": {"name": "p_value", "group": "Stats", "definition": "ttest(abs(t_statistic),19,2)", "description": "

p-value corresponding to the t-statistic

", "templateType": "anything", "can_override": false}, "t_statistic": {"name": "t_statistic", "group": "Stats", "definition": "(mean1-mean2)*sqrt(n1*n2)/(s*sqrt(n1+n2))", "description": "", "templateType": "anything", "can_override": false}, "t90": {"name": "t90", "group": "Critical t-values", "definition": "1.734", "description": "", "templateType": "anything", "can_override": false}, "decision_marking_matrix": {"name": "decision_marking_matrix", "group": "Advice messages", "definition": "[\n [1,0,0,0,0],\n [0,1,0,0,0],\n [0,0,1,0,0],\n [0,0,0,1,0],\n [0,0,0,0,1]\n][scenario]", "description": "

Marking matrix for the multiple choice questions

", "templateType": "anything", "can_override": false}, "sd2": {"name": "sd2", "group": "Stats", "definition": "precround(pstdev(r2),3)", "description": "

Sample standard deviation of sample 2

", "templateType": "anything", "can_override": false}, "t95": {"name": "t95", "group": "Critical t-values", "definition": "2.101", "description": "", "templateType": "anything", "can_override": false}, "r1": {"name": "r1", "group": "Samples", "definition": "repeat(round(normalsample(mu1,sigma1)),n1)", "description": "

Sample 1

", "templateType": "anything", "can_override": false}, "mean1": {"name": "mean1", "group": "Stats", "definition": "mean(r1)", "description": "

Sample mean of sample 1

", "templateType": "anything", "can_override": false}, "mean2": {"name": "mean2", "group": "Stats", "definition": "mean(r2)", "description": "

Sample mean of sample 1

", "templateType": "anything", "can_override": false}, "r2": {"name": "r2", "group": "Samples", "definition": "repeat(round(normalsample(mu2,sigma2)),n2)", "description": "

Sample 2

", "templateType": "anything", "can_override": false}, "scenario": {"name": "scenario", "group": "Advice messages", "definition": "sum(map(award(1,abs(t_statistic)Which scenario are we in - how many critical values of the t distribution does t_statistic exceed?

", "templateType": "anything", "can_override": false}, "sigma1": {"name": "sigma1", "group": "Setup", "definition": "random(8..10#0.2)", "description": "

Population standard deviation of sample 1

", "templateType": "anything", "can_override": false}, "sd1": {"name": "sd1", "group": "Stats", "definition": "precround(pstdev(r1),3)", "description": "

Sample standard deviation of sample 1

", "templateType": "anything", "can_override": false}, "s": {"name": "s", "group": "Stats", "definition": "precround(sqrt(((n1-1)*sd1^2+(n2-1)*sd2^2)/(n1+n2-2)),3)", "description": "

Used in the formula for the t statistic

", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "Setup", "variables": ["n1", "n2", "mu1", "sigma1", "mu2", "sigma2"]}, {"name": "Samples", "variables": ["r1", "r2"]}, {"name": "Stats", "variables": ["mean1", "sd1", "mean2", "sd2", "s", "t_statistic", "p_value"]}, {"name": "Advice messages", "variables": ["scenario", "decision_marking_matrix", "reject", "evidence_strength", "t_statistic_range", "p_value_range"]}, {"name": "Critical t-values", "variables": ["t90", "t95", "t99", "t999"]}], "functions": {"pstdev": {"parameters": [["l", "list"]], "type": "number", "language": "jme", "definition": "sqrt(len(l)/(len(l)-1))*stdev(l)"}}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Find the mean and standard deviations of the scores of the two groups. Round your answers to 3 decimal places.

\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n
MeanStandard deviation
Group 1[[0]][[1]]
Group 2[[2]][[3]]
\n

Now find the two sample t-test statistic $T$ using the values you have just calculated and enter it here: [[4]]

", "stepsPenalty": 0, "steps": [{"type": "information", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

The two-sample t-statistic for two independent sets of data where one set has $n_1$ data points and the other set $n_2$ data points is calculated as follows:

\n

\\[T = \\frac{(\\overline{x}_1-\\overline{x}_2)-(\\mu_1-\\mu_2)}{s\\times\\sqrt{\\frac{1}{n_1}+\\frac{1}{n_2}}}\\;\\;\\;\\]

\n

where $\\overline{x}_1,\\;\\overline{x}_2$ are the sample means and 

\n

\\[s^2=\\frac{(n_1-1)s_1^2+(n_2-1)s_2^2}{n_1+n_2-2}\\]

\n

where $s_1,\\;s_2$ are the sample standard deviations.

\n

Use the values you calculated to 3 decimal places in order to find $T$.

"}], "gaps": [{"type": "numberentry", "useCustomName": false, "customName": "", "marks": 0.5, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "mean1", "maxValue": "mean1", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 0.5, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "sd1", "maxValue": "sd1", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 0.5, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "mean2", "maxValue": "mean2", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 0.5, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "sd2", "maxValue": "sd2", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "You have not given your answer to the correct precision.", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}, {"type": "numberentry", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [{"variable": "mean1", "part": "p0g0", "must_go_first": false}, {"variable": "sd1", "part": "p0g1", "must_go_first": false}, {"variable": "mean2", "part": "p0g2", "must_go_first": false}, {"variable": "sd2", "part": "p0g3", "must_go_first": false}], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "minValue": "t_statistic", "maxValue": "t_statistic", "correctAnswerFraction": false, "allowFractions": false, "mustBeReduced": false, "mustBeReducedPC": 0, "displayAnswer": "", "precisionType": "dp", "precision": "3", "precisionPartialCredit": 0, "precisionMessage": "

You have not given your answer to the correct precision.

", "strictPrecision": false, "showPrecisionHint": false, "notationStyles": ["plain", "en", "si-en"], "correctAnswerStyle": "plain"}], "sortAnswers": false}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [{"variable": "t_statistic", "part": "p0g4", "must_go_first": false}], "variableReplacementStrategy": "alwaysreplace", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Given the value $|T|$ of the t-statistic you have found, choose the range for the $p$ value by looking up the t tables:

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": "1", "showCellAnswerState": true, "choices": ["

$p$ is less than $0.1\\%$

", "

$p$ lies between $0.1\\%$ and $1\\%$

", "

$p$ lies between $1 \\%$ and $5\\%$

", "

$p$ lies between $5 \\%$ and $10\\%$

", "

$p$ is greater than $10\\%$

"], "matrix": "decision_marking_matrix"}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [{"variable": "scenario", "part": "p1", "must_go_first": false}], "variableReplacementStrategy": "alwaysreplace", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

Given the $p$-value and the range you have found, what is the strength of evidence against the null hypothesis that there is no difference in the average times for the left and right hands?

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": 0, "showCellAnswerState": true, "choices": ["

Very Strong Evidence

", "

Strong Evidence

", "

Evidence

", "

Weak Evidence

", "

No Evidence

"], "matrix": "decision_marking_matrix"}, {"type": "1_n_2", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [{"variable": "scenario", "part": "p2", "must_go_first": false}], "variableReplacementStrategy": "alwaysreplace", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

What do you decide based on the above analysis?

", "minMarks": 0, "maxMarks": 0, "shuffleChoices": false, "displayType": "radiogroup", "displayColumns": "1", "showCellAnswerState": true, "choices": ["

We reject the null hypothesis at the $0.1\\%$ level

", "

We reject the null hypothesis at the $1\\%$ level.

", "

We reject the null hypothesis at the $5\\%$ level.

", "

We do not reject the null hypothesis but consider further investigation.

", "

We do not reject the null hypothesis.

"], "matrix": "decision_marking_matrix"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always"}]}], "name": "Kiosk demo", "showQuestionGroupNames": true, "type": "exam", "contributors": [{"name": "Christian Lawson-Perfect", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/7/"}], "extensions": ["stats"], "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": [["question-resources/pool_TB2Lho6.svg", "/srv/numbas/media/question-resources/pool_TB2Lho6.svg"]]}