// Numbas version: finer_feedback_settings
{"name": "2.6.2 Task 1", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "2.6.2 Task 1", "tags": [], "metadata": {"description": "
Draw the annulus given by a double inequality. The user moves circles on an interactive jsxgraph.
", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "Draw the annulus defined by the inequalities
\n$\\var{R12}<(\\var{simplify(expression(\"x-\"+Cx),\"all\")})^2+(\\var{simplify(expression(\"y-\"+Cy),\"all\")})^2<\\var{R22}$
", "advice": "The quantity $\\var{expr}$ is the square of the distance of a point $(x, y)$ from the point $(\\var{Cx},\\var{Cy})$.
\nHence, as we saw earlier, the left-hand inequality
\n$\\var{R12} < \\var{expr}\\qquad$ which is the same as $\\qquad \\var{expr} > \\var{R12}$
\nis the region exterior to the circle $C_1$ centre $(\\var{Cx}, \\var{Cy})$ radius $\\var{R1}$.
\nSimilarly the right-hand inequality
\n$\\var{expr} < \\var{R22}$
\ndefines the interior of the circle $C_2$ centre $(\\var{Cx}, \\var{Cy})$ radius $\\var{R2}$. Hence the double inequality holds for any point in the annulus between $C_1$ and $C_2$.
\n{correctGraph}
", "rulesets": {}, "extensions": ["jsxgraph"], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"R1": {"name": "R1", "group": "The annulus", "definition": "random(1..5)", "description": "The inner radius
", "templateType": "anything", "can_override": false}, "R12": {"name": "R12", "group": "The annulus", "definition": "R1*R1", "description": "R1 squared
", "templateType": "anything", "can_override": false}, "R2": {"name": "R2", "group": "The annulus", "definition": "random(R1+1..9)", "description": "The outer radius
", "templateType": "anything", "can_override": false}, "R22": {"name": "R22", "group": "The annulus", "definition": "R2*R2", "description": "R2 squared
", "templateType": "anything", "can_override": false}, "Cx": {"name": "Cx", "group": "The annulus", "definition": "random(-5..5)", "description": "Centre x
", "templateType": "anything", "can_override": false}, "Cy": {"name": "Cy", "group": "The annulus", "definition": "random(-5..5)", "description": "Centre y
", "templateType": "anything", "can_override": false}, "correctGraph": {"name": "correctGraph", "group": "the graph", "definition": "jessiecode(\n 400,400,[{xmin},{ymax},{xmax},{ymin}],\"r1={R1};r2={R2};Cx={Cx};Cy={Cy};\"+safe(\n \"\"\"\n C=point(Cx,Cy) <>;\n circle(C,r2) << fillcolor:'yellow', fillOpacity:0.2, strokeOpacity:0.3 >>;\n circle(C,r1) << fillcolor:'white', fillOpacity: 0.6, strokeOpacity:0.3 >>;\n \"\"\"),\n [\n \"axis\": true\n ]\n)", "description": "", "templateType": "anything", "can_override": false}, "xmin": {"name": "xmin", "group": "the graph", "definition": "min(-1,Cx-R2-1)", "description": "", "templateType": "anything", "can_override": false}, "ymax": {"name": "ymax", "group": "the graph", "definition": "if(ymaxtemp-ymin > xmaxtemp-xmin,ymaxtemp,ymin+xmaxtemp-xmin)", "description": "", "templateType": "anything", "can_override": false}, "ymin": {"name": "ymin", "group": "the graph", "definition": "min(-1,Cy-R2-1)", "description": "", "templateType": "anything", "can_override": false}, "xmaxtemp": {"name": "xmaxtemp", "group": "the graph", "definition": "max(1,Cx+R2+1)", "description": "", "templateType": "anything", "can_override": false}, "xmax": {"name": "xmax", "group": "the graph", "definition": "if(xmaxtemp-xmin > ymaxtemp-ymin,xmaxtemp,xmin+ymaxtemp-ymin)", "description": "", "templateType": "anything", "can_override": false}, "ymaxtemp": {"name": "ymaxtemp", "group": "the graph", "definition": "max(1,Cy+R2+1)", "description": "", "templateType": "anything", "can_override": false}, "expr": {"name": "expr", "group": "Advice", "definition": "simplify(expression(\"(x-\"+Cx+\")^2+(y-\"+Cy+\")^2\"),\"all\")", "description": "", "templateType": "anything", "can_override": false}, "graph": {"name": "graph", "group": "the graph", "definition": "jessiecode(\n 400,400,[{xmin},{ymax},{xmax},{ymin}],\"Cx={Cx};Cy={Cy};\"+safe(\n \"\"\"\n Cx=0; Cy=0;\n P1x = 1; P2x=2;\n C=point(Cx,Cy) <>;\n P1=point(P1x,Cy) <>;\n P2=point(P2x,Cy) <>;\n \n C2=circle(C,P2) <>;\n C1=circle(C,P1) <>;\n \"\"\"),\n [\n \"axis\": true\n ]\n)", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": [], "variable_groups": [{"name": "The annulus", "variables": ["R1", "R12", "R2", "R22", "Cx", "Cy"]}, {"name": "the graph", "variables": ["correctGraph", "xmin", "ymin", "xmaxtemp", "ymaxtemp", "xmax", "ymax", "graph"]}, {"name": "Advice", "variables": ["expr"]}], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "extension", "useCustomName": false, "customName": "", "marks": "3", "scripts": {}, "customMarkingAlgorithm": "centre: jxg_position(graph[\"C\"])\n\ninnerRadius: jxg_radius(graph[\"C1\"])\n\nouterRadius: jxg_radius(graph[\"C2\"])\n\ncentre_good: \n if(centre[0]=Cx and centre[1]=Cy,\n add_credit(1, \"The centre of your circle is in the correct location.\")\n , negative_feedback(\"Your centre of your circle is not in the correct location.\")\n )\n\ninnerRadius_good:\n if(innerRadius=R1,\n add_credit(1, \"The inner circle is the correct size.\")\n , negative_feedback(\"The inner circle is not the correct size.\")\n )\n\nouterRadius_good:\n if(outerRadius=R2,\n add_credit(1, \"The outer circle is the correct size.\")\n , negative_feedback(\"The outer circle is not the correct size.\")\n )\n\nmark:\n apply(centre_good);\n apply(innerRadius_good);\n apply(outerRadius_good)\n\ninterpreted_answer: [centre, innerRadius, outerRadius]", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "Drag the blue point to move the centre of the circles.
\nThen drag the red point to set the radius for the inner circle.
\nFinally drag the black point to set the radius for the outer circle.
\n{graph}
"}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}]}], "contributors": [{"name": "Merryn Horrocks", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4052/"}]}