// Numbas version: exam_results_page_options {"name": "Basic Set Theory: element not in a set", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"extensions": [], "metadata": {"description": "

", "licence": "Creative Commons Attribution-ShareAlike 4.0 International"}, "parts": [{"failureRate": 1, "vsetRange": [0, 1], "customMarkingAlgorithm": "", "valuegenerators": [], "extendBaseMarkingAlgorithm": true, "type": "jme", "checkVariableNames": false, "useCustomName": false, "showCorrectAnswer": true, "showFeedbackIcon": true, "checkingAccuracy": 0.001, "customName": "", "marks": 1, "variableReplacementStrategy": "originalfirst", "scripts": {"mark": {"order": "instead", "script": "// extract question variables\nvar variables = this.question.scope.variables;\nvar unwrap = Numbas.jme.unwrapValue;\nvar c = unwrap(variables.c);\nvar d = unwrap(variables.d);\n\n// compute its derivative\nvar tree;\ntry {\n tree = Numbas.jme.compile(this.studentAnswer);\n var ans = unwrap(Numbas.jme.evaluate(tree,this.question.scope));\n \n if (0 == ((ans - d) % c)) { \n // then ans = ck + d for some integer k\n this.setCredit(1,\"This is an element of $Y$. In fact $Y \\\\subseteq X$ so any element of $Y$ is automatically in $X$.\");\n if (ans != d) {\n this.markingComment('By the way, the easiest element to find is $' + d + '$ which is obtained when $k=0$.');\n }\n }\n}\ncatch(e) {\n this.markingComment(e);\n}\n"}}, "variableReplacements": [], "showPreview": true, "vsetRangePoints": 5, "unitTests": [], "answer": "{d}", "checkingType": "absdiff", "adaptiveMarkingPenalty": 0, "prompt": "

Find an element of $Y$ which is also an element of $X$.

"}, {"failureRate": 1, "vsetRange": [0, 1], "customMarkingAlgorithm": "", "valuegenerators": [], "extendBaseMarkingAlgorithm": true, "type": "jme", "checkVariableNames": false, "useCustomName": false, "showCorrectAnswer": true, "showFeedbackIcon": true, "checkingAccuracy": 0.001, "customName": "", "marks": 1, "variableReplacementStrategy": "originalfirst", "scripts": {"mark": {"order": "instead", "script": "// extract question variables\nvar variables = this.question.scope.variables;\nvar unwrap = Numbas.jme.unwrapValue;\nvar a = unwrap(variables.a);\nvar b = unwrap(variables.b);\nvar c = unwrap(variables.c);\nvar d = unwrap(variables.d);\n\n// compute its derivative\nvar tree;\ntry {\n tree = Numbas.jme.compile(this.studentAnswer);\n var ans = unwrap(Numbas.jme.evaluate(tree,this.question.scope));\n \n if (0 == ((ans - b) % a)) { \n // then ans = ck + d for some integer k\n this.setCredit(1,\"This is an element of $X$.\");\n }\n \n if (0 == ((ans - d) % c)) { \n // then ans = ck + d for some integer k\n this.setCredit(0,\"But it is also an element of $Y$.\");\n }\n}\ncatch(e) {\n this.markingComment(e);\n}"}}, "variableReplacements": [], "showPreview": true, "vsetRangePoints": 5, "unitTests": [], "answer": "{b}", "checkingType": "absdiff", "adaptiveMarkingPenalty": 0, "prompt": "

Find an element of $X$ which is not an element of $Y$.

"}, {"showCellAnswerState": true, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "maxMarks": 0, "useCustomName": false, "showCorrectAnswer": true, "shuffleChoices": false, "showFeedbackIcon": true, "matrix": ["1", 0], "customName": "", "marks": 0, "variableReplacementStrategy": "originalfirst", "displayColumns": 0, "scripts": {}, "variableReplacements": [], "minMarks": 0, "unitTests": [], "displayType": "radiogroup", "distractors": ["Yes. All you need to demonstrate is there is one element of $X$ which is not also in $Y$.", "This is true but irrelevant."], "type": "1_n_2", "choices": ["

$X \\nsubseteq Y$

", "

$Y \\subseteq X$

The sets $X$ and $Y$ are not equal because

"}], "variables": {"b": {"group": "Ungrouped variables", "definition": "random(6..9)", "description": "", "name": "b", "templateType": "anything"}, "u": {"group": "Ungrouped variables", "definition": "random(2..5)", "description": "", "name": "u", "templateType": "anything"}, "a": {"group": "Ungrouped variables", "definition": "random(2..5)", "description": "", "name": "a", "templateType": "anything"}, "c": {"group": "Ungrouped variables", "definition": "u*a", "description": "", "name": "c", "templateType": "anything"}, "d": {"group": "Ungrouped variables", "definition": "a+b", "description": "", "name": "d", "templateType": "anything"}}, "variable_groups": [], "advice": "

The first thing to note is that $Y \\subseteq X$. To prove this, show that every $y \\in Y$ is also in $X$. Essentially you have to prove an infinite amount of stuff here (because $Y$ is infinitely large), and we can do this by considering any generic element of $Y$ and checking that it is also in $X$.

\n

Suppose $y$ is any generic element of $Y$. Then it has the shape $y = \\var{c}k + \\var{d}$ for some $k \\in \\mathbb Z$. But elements of $X$ have the shape $\\var{a}n + \\var{b}$ for some integer $n$. We can $\\var{c}k + \\var{d}$ into $\\var{a}n + \\var{b}$ as follows:

\n

\\begin{align*} y & = \\var{c} k + \\var{d} \\\\ & = \\var{a}\\times\\var{u} k + \\var{a} + \\var{b} \\\\ & = \\var{a}(\\var{u} k + 1) + \\var{b} \\\\ & = \\var{a}n + \\var{b} \\end{align*}

\n

where $n = (\\var{u}k+1) \\in \\mathbb Z$. So $y=\\var{a}n + \\var{b}$ for some integer $n$, which means that any element of $Y$ is also an element of $X$, i.e. $Y \\subseteq X$.

\n

So for this part of this question you can choose any element of $Y$. All of them will automatically be included in $X$.

\n
\n

For the second question you need to find an element of $X$ which which is not an element of $Y$. This does not require an infinite amount of work - all you need is one element of $X$ which is not in $Y$. The easiest way to proceede is to just try a few different values of $X$.

\n
\n

By definition the sets $X$ and $Y$ are equal when both $Y\\subseteq X$ and $X \\subseteq Y$ are true. We showed in part b that $X \\nsubseteq Y$. So the sets are not equal. We can be more precise and see from part a that $Y\\subseteq X$ and so $X$ is a proper subset of $Y$: $X \\subset Y$.

", "preamble": {"js": "", "css": ""}, "tags": [], "functions": {}, "name": "Basic Set Theory: element not in a set", "variablesTest": {"maxRuns": 100, "condition": ""}, "rulesets": {}, "statement": "

Consider the sets $X = \\left\\{ \\var{a}n + \\var{b} | n \\in \\mathbb Z\\right\\}$ and $Y = \\left\\{ \\var{c}k + \\var{d} | k \\in \\mathbb Z\\right\\}$.

", "ungrouped_variables": ["a", "b", "u", "c", "d"], "contributors": [{"name": "Daniel Mansfield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/743/"}, {"name": "Sean Gardiner", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2443/"}]}]}], "contributors": [{"name": "Daniel Mansfield", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/743/"}, {"name": "Sean Gardiner", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2443/"}]}