// Numbas version: exam_results_page_options {"name": "Absorb to a only", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Absorb to a only", "tags": [], "metadata": {"description": "", "licence": "None specified"}, "statement": "

Consider a simple random walk with absorbing barrier at $a=\\var{a}$

\n

If we start in state $\\var{j}$

\n

Find the following to three decimal places:

", "advice": "

The formula for absorbing to state $a$ with one absorbing barrier when $p<q$ is:

\n

\\[p_j = \\Big(\\frac{p}{q}\\Big)^{a-j}\\]

\n

The formula for absorbing to state $a$ with one absorbing barrier when $p\\geq q$ is:

\n

\\[p_j = 1\\]

", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"a": {"name": "a", "group": "Ungrouped variables", "definition": "random(5..10)", "description": "", "templateType": "anything", "can_override": false}, "b": {"name": "b", "group": "Ungrouped variables", "definition": "random(-5..(a-2))", "description": "", "templateType": "anything", "can_override": false}, "j": {"name": "j", "group": "Ungrouped variables", "definition": "if(b<0, random(0..(a-1)), random((b+1)..(a-1)))", "description": "", "templateType": "anything", "can_override": false}, "p": {"name": "p", "group": "Ungrouped variables", "definition": "random(1..49)/100", "description": "", "templateType": "anything", "can_override": false}, "pj": {"name": "pj", "group": "Ungrouped variables", "definition": "ratio^(a-j)", "description": "", "templateType": "anything", "can_override": false}, "qj": {"name": "qj", "group": "Ungrouped variables", "definition": "1", "description": "", "templateType": "anything", "can_override": false}, "ratio": {"name": "ratio", "group": "Ungrouped variables", "definition": "p/qlt", "description": "", "templateType": "anything", "can_override": false}, "plt": {"name": "plt", "group": "Ungrouped variables", "definition": "random(1..49)/100", "description": "", "templateType": "anything", "can_override": false}, "qlt": {"name": "qlt", "group": "Ungrouped variables", "definition": "random(((p*100)+1)..((1-p)*100))/100", "description": "", "templateType": "anything", "can_override": false}, "qgt": {"name": "qgt", "group": "Ungrouped variables", "definition": "random(1..((p*100)+1))/100", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "and(p1))", "maxRuns": 100}, "ungrouped_variables": ["a", "b", "j", "p", "pj", "qj", "ratio", "plt", "qlt", "qgt"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {"mark": {"script": "// Reveal answers, score and advice\nthis.display.revealAnswer();\nthis.display.showScore();\nNumbas.controls.getAdvice();", "order": "before"}}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "

What is the probability of absorbing to state $a$ if $p=\\var{p}$ and $q=\\var{qlt}$: $p_j =$[[0]]

\n

What is the probability of absorbing to state $a$ if $p=\\var{p}$ and $q=\\var{qgt}$: $p_j =$[[1]]

", "gaps": [{"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{pj}", "showPreview": true, "checkingType": "dp", "checkingAccuracy": 3, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}, {"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{qj}", "showPreview": true, "checkingType": "dp", "checkingAccuracy": 3, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "contributors": [{"name": "adam bretherton", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/18177/"}]}]}], "contributors": [{"name": "adam bretherton", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/18177/"}]}