// Numbas version: exam_results_page_options {"name": "Odd Functions", "extensions": ["jsxgraph"], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"statement": "

Geometrically, a function is called odd if it is symmetric in the origin. The picture below is an example of an odd function because every point \\(A\\) on the curve can be reflected through the origin to produce another point on the curve \\(B\\).

\n

Here the line from \\(A\\) to the vertical axis is shown as a solid line, and the reflection through the origin to \\(B\\) is shown as a dashed line.

\n

{graph(a)}

\n

Algebraicly, a function has this kind of symmetry whenever

\n

\\(f(-x) \\equiv -f(x).\\)

", "metadata": {"licence": "Creative Commons Attribution-ShareAlike 4.0 International", "description": "

A graphical introduction to the concept of even functions a symmery

"}, "preamble": {"css": "", "js": ""}, "parts": [{"mustBeReduced": false, "correctAnswerStyle": "plain", "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "mustBeReducedPC": 0, "prompt": "

If the \\(x\\) coordinate of the point \\(A\\) is \\(\\var{x1}\\) then what is the \\(x\\)-coordinate of the point \\(B\\)?

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

If the \\(y\\) coordinate of the point \\(A\\) is \\(\\var{a*x1^3}\\) then what is the \\(y\\)-coordinate of the point \\(B\\)?

", "maxValue": "{-a*x1^3}", "extendBaseMarkingAlgorithm": true, "marks": 1, "variableReplacements": [], "showCorrectAnswer": true, "minValue": "{-a*x1^3}", "correctAnswerFraction": false, "allowFractions": false, "unitTests": [], "customMarkingAlgorithm": "", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "scripts": {}}], "tags": [], "variable_groups": [], "variablesTest": {"maxRuns": 100, "condition": ""}, "functions": {"graph": {"parameters": [["a", "number"]], "definition": "var div = Numbas.extensions.jsxgraph.makeBoard('400px','400px',\n{boundingbox: [-2.5, a*8.5, 2.5, -a*8.5],\n axis: true,\n showNavigation: false,\n grid: true\n});\n\nvar board = div.board;\n\nfunction f(x) {\n return a*x*x*x;\n}\n\nvar curve = board.createElement('functiongraph', f, {visible:true});\n\nvar Y = board.createElement('point', [0,1],{visible:false});\nvar O = board.createElement('point', [0,0],{visible:true, fixed: true, name:\"O\"});\n//var yaxis = board.createElement('line', [Y,O]);\n\nvar A = board.createElement('glider', [-1,a, curve], {name:\"A\"});\nvar B = board.createElement('point', [function () { return -1*A.X();}, function () {return -1*A.Y();}], {name:\"B\",color:\"blue\"});\n//var C = board.createElement('point', [0, function () {return A.Y();}], {name:\"C\",color:\"blue\",visible:false});\n\nboard.createElement('segment', [A,O],{strokeWidth:4});\nboard.createElement('segment', [O,B],{strokeWidth:4,dash:1});\n\nreturn div;", "language": "javascript", "type": "html"}}, "advice": "

Suppose that the point \\(A\\) has coordinates \\((\\var{x1}, \\var{a*x1^3})\\). Then by the symmetry of the graph the point \\(B\\) has coordinates \\((\\var{-1*x1}, \\var{-a*x1^3})\\).

", "rulesets": {}, "name": "Odd Functions", "ungrouped_variables": ["a", "x1"], "extensions": ["jsxgraph"], "variables": {"x1": {"name": "x1", "definition": "random(-2..2 except 0)", "group": "Ungrouped variables", "templateType": "anything", "description": ""}, "a": {"name": "a", "definition": "random(1..4)", "group": "Ungrouped variables", "templateType": "anything", "description": ""}}, "type": "question", "contributors": [{"name": "Daniel Mansfield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/743/"}]}]}], "contributors": [{"name": "Daniel Mansfield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/743/"}]}