// Numbas version: exam_results_page_options {"name": "Find the discontinuity in a piecewise-defined function", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"preventleave": false, "showfrontpage": false, "allowregen": true}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"statement": "

Find the point at which the following function $f:\\mathbb{R} \\rightarrow \\mathbb{R}$ is not continuous.

\n

", "metadata": {"notes": "", "description": "", "licence": "Creative Commons Attribution 4.0 International"}, "variable_groups": [], "name": "Find the discontinuity in a piecewise-defined function", "question_groups": [{"pickingStrategy": "all-ordered", "name": "", "questions": [], "pickQuestions": 0}], "type": "question", "variables": {"t": {"description": "", "templateType": "anything", "name": "t", "group": "Ungrouped variables", "definition": "if(w=1,0,1)"}, "v": {"description": "", "templateType": "anything", "name": "v", "group": "Ungrouped variables", "definition": "if(w=3,0,1)"}, "er2": {"description": "", "templateType": "anything", "name": "er2", "group": "Ungrouped variables", "definition": "u*0+(1-u)*random(-2,-1,1,2,3)"}, "b": {"description": "", "templateType": "anything", "name": "b", "group": "Ungrouped variables", "definition": "a+random(1..3)"}, "q1": {"description": "", "templateType": "anything", "name": "q1", "group": "Ungrouped variables", "definition": "random(1..4)"}, "a": {"description": "", "templateType": "anything", "name": "a", "group": "Ungrouped variables", "definition": "random(-3..3)"}, "q2": {"description": "", "templateType": "anything", "name": "q2", "group": "Ungrouped variables", "definition": "-random(1..3)"}, "u": {"description": "", "templateType": "anything", "name": "u", "group": "Ungrouped variables", "definition": "if(w=2,0,1)"}, "w": {"description": "", "templateType": "anything", "name": "w", "group": "Ungrouped variables", "definition": "random(1..3)"}, "p": {"description": "", "templateType": "anything", "name": "p", "group": "Ungrouped variables", "definition": "random(-9..9)"}, "er3": {"description": "", "templateType": "anything", "name": "er3", "group": "Ungrouped variables", "definition": "v*0+(1-v)*random(-2,-1,1,2,3)"}, "er1": {"description": "", "templateType": "anything", "name": "er1", "group": "Ungrouped variables", "definition": "t*0+(1-t)*random(-2,-1,1,2,3)"}, "c": {"description": "", "templateType": "anything", "name": "c", "group": "Ungrouped variables", "definition": "b+random(1..3)"}, "dis": {"description": "", "templateType": "anything", "name": "dis", "group": "Ungrouped variables", "definition": "if(w=1,a,if(w=2,b,c))"}}, "variablesTest": {"condition": "", "maxRuns": 100}, "functions": {"discont": {"parameters": [["a", "number"], ["b", "number"], ["c", "number"], ["p", "number"], ["q1", "number"], ["q2", "number"], ["er1", "number"], ["er2", "number"], ["er3", "number"], ["dis", "number"]], "type": "html", "definition": "var boxup=Math.max(3,p,p+er1,q1*(b-a)+p+er1,q1*(b-a)+p+er1+er2,q2*(c-b)*(c-b)+q1*(b-a)+p+er1+er2,q2*(c-b)*(c-b)+q1*(b-a)+p+er1+er2+er3)+2;\nvar boxdown=Math.min(-3,p,p+er1,q1*(b-a)+p+er1,q1*(b-a)+p+er1+er2,q2*(c-b)*(c-b)+q1*(b-a)+p+er1+er2,q2*(c-b)*(c-b)+q1*(b-a)+p+er1+er2+er3)-2;\nvar div = Numbas.extensions.jsxgraph.makeBoard('400px','400px', {axis:true, boundingbox:[Math.min(-2,a-2),boxup,Math.max(c+2,2),boxdown]});\nvar brd=div.board;\nvar l1=brd.create('functiongraph',[function(x){return p;},a-2,a],{strokeColor:'red'});\nvar l2=brd.create('functiongraph',[function(x){return q1*x+(p+er1-q1*a);},a,b],{strokeColor:'red'});\nvar l3=brd.create('functiongraph',[function(x){return q2*x*x-2*b*q2*x+(p+er1+er2+q2*b*b+q1*(b-a));},b,c],{strokeColor:'red'});\nvar l4=brd.create('functiongraph',[function(x){return q2*(c-b)*(c-b)+q1*(b-a)+p+er1+er2+er3;},c,c+2],{strokeColor:'red'});\nreturn div;\n", "language": "javascript"}}, "tags": ["checked2015", "MAS2224"], "advice": "

{discont(a,b,c,p,q1,q2,er1,er2,er3,dis)}

\n

\n

The function is discontinuous at $x=\\var{dis}$.

\n

At $x=\\var{dis}$ we have:

\n

\$\\lim_{x \\nearrow\\; \\var{dis}} f(x) \\neq \\lim_{x \\searrow\\; \\var{dis}} f(x)\$

\n

\n

\n

See graph of $f$ above.

", "ungrouped_variables": ["q1", "a", "c", "q2", "er1", "er2", "er3", "p", "b", "u", "t", "w", "v", "dis"], "parts": [{"prompt": "\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\n\n\n\n
 $f(x) = \\left \\{ \\begin{array}{l} \\phantom{{.}} \\\\ \\phantom{{.}} \\\\ \\phantom{{.}} \\\\\\phantom{{.}} \\\\ \\phantom{{.}} \\\\ \\phantom{{.}}\\end{array} \\right .$ $\\var{p},$ $x \\leq \\var{a},$ $\\simplify{{q1}*x+{p+er1-q1*a}},$ $\\var{a} \\lt x \\leq \\var{b},$ $\\simplify{{q2}*x^2+{-2*q2*b}*x+{q2*b^2+q1*(b-a)+p+er1+er2}},$ $\\var{b}\\lt x \\leq \\var{c},$ $\\var{q2*(c-b)^2+q1*(b-a)+p+er1+er2+er3},$ $x \\gt \\var{c}.$
\n

$f$ is discontinuous at $x=a$ where $a=\\;$[[0]].

\n

", "showCorrectAnswer": true, "gaps": [{"marks": 3, "showCorrectAnswer": true, "minValue": "dis", "correctAnswerFraction": false, "allowFractions": false, "type": "numberentry", "scripts": {}, "maxValue": "dis", "showPrecisionHint": false}], "marks": 0, "type": "gapfill", "scripts": {}}], "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}], "preamble": {"css": "", "js": ""}, "showQuestionGroupNames": false, "rulesets": {}}]}], "contributors": [{"name": "Newcastle University Mathematics and Statistics", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/697/"}]}