// Numbas version: finer_feedback_settings {"name": "Denis's copy of Divide two elements of $\\mathbb{Z}[i]$", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"functions": {}, "ungrouped_variables": ["a", "c", "p1", "d", "m", "n", "p", "b", "t", "v"], "name": "Denis's copy of Divide two elements of $\\mathbb{Z}[i]$", "tags": ["algebra", "checked2015", "division", "euclidean rings", "factorization in rings", "gaussian integers", "gcd", "gcd in euclidean rings", "MAS2213", "remainders", "rings"], "type": "question", "advice": "
We have:
\n\\[\\begin{align}\\simplify[all,!collectNumbers]{({a} + {b} * i) / ({c} + {d} * i)}& = \\simplify[all,!collectNumbers]{(({a} + {b} * i) * ({c} + { -d} * i)) / (({c} + {d} * i) * ({c} + { -d} * i))}\\\\& = \\simplify[all,!collectNumbers]{{a * c + b * d} / {c ^ 2 + d ^ 2} + ({b * c -(a * d)} / {c ^ 2 + d ^ 2}) * i}\\\\&=\\simplify[all,!collectNumbers]{{(a * c + b * d) / (c ^ 2 + d ^ 2)} + {(b * c -(a * d)) / (c ^ 2 + d ^ 2)} * i}\\\\& \\approx \\simplify[all,!collectNumbers]{{t} + {v}* i}\\end{align}\\]
\non taking the nearest integer values.
\nTaking $z= \\simplify[all,!collectNumbers]{{t} + {v}* i}$ and on calculating we find:
\n\\[\\simplify[all,!collectNumbers]{{a} + {b} * i = ({c} + {d} * i) * ({t} + {v} * i) + {m} + {n} * i}\\]
\nSo the remainder is $r=\\simplify{{m}+{n}*i}$.
\nNote that: \\[N(r) = \\simplify{{m ^ 2 + n ^ 2}} \\lt \\simplify[all,!collectNumbers]{N({c} + {d} * i) = {c ^ 2 + d ^ 2}}.\\]
", "rulesets": {}, "parts": [{"prompt": "Remainder $r=\\;$[[0]]
\nFind $z=c+di$ such that $\\simplify[all,!collectNumbers]{{a}+{b}*i=({c}+{d}*i)*z+r}$
\n$z=\\;$[[1]]
\nPlease input your answers in the form a+b*i where a and b are integers. Do not include decimal numbers.
", "marks": 0, "gaps": [{"notallowed": {"message": "Please input your answers in the form a+b*i where a and b are integers. Do not include decimal numbers.
", "showStrings": false, "strings": ["."], "partialCredit": 0}, "expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "vsetrangepoints": 5, "showCorrectAnswer": true, "answersimplification": "all,!collectNumbers", "scripts": {}, "answer": "{m}+{n}i", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}, {"expectedvariablenames": [], "checkingaccuracy": 0.001, "type": "jme", "showpreview": true, "vsetrangepoints": 5, "showCorrectAnswer": true, "answersimplification": "all,!collectNumbers", "scripts": {}, "answer": "{t}+{v}*i", "marks": 1, "checkvariablenames": false, "checkingtype": "absdiff", "vsetrange": [0, 1]}], "showCorrectAnswer": true, "scripts": {}, "type": "gapfill"}], "preamble": {"css": "", "js": ""}, "statement": "In the Gaussian integer ring $\\mathbb{Z}[i]$ , find the remainder $r=a+bi$, where $a \\gt 0,\\;b \\gt 0$ , on dividing $\\simplify[all,!collectNumbers]{{a}+{b}*i}$ by $\\simplify[all,!collectNumbers]{{c}+{d}*i}$ .
", "variable_groups": [], "variablesTest": {"maxRuns": 100, "condition": ""}, "question_groups": [{"pickingStrategy": "all-ordered", "name": "", "questions": [], "pickQuestions": 0}], "variables": {"a": {"definition": "c*t-d*v+m", "templateType": "anything", "group": "Ungrouped variables", "name": "a", "description": ""}, "c": {"definition": "(n+m)*p1", "templateType": "anything", "group": "Ungrouped variables", "name": "c", "description": ""}, "p1": {"definition": "random(2..4)", "templateType": "anything", "group": "Ungrouped variables", "name": "p1", "description": ""}, "d": {"definition": "(n-m)*p1", "templateType": "anything", "group": "Ungrouped variables", "name": "d", "description": ""}, "m": {"definition": "random(1..5)", "templateType": "anything", "group": "Ungrouped variables", "name": "m", "description": ""}, "n": {"definition": "if(m=1,random(2..5),if(m=2,random(1,3,4,5),if(m=3,random(1,2,4,5),if(m=4,random(1,2,3,5),random(1..4)))))", "templateType": "anything", "group": "Ungrouped variables", "name": "n", "description": ""}, "p": {"definition": "random(3..5)", "templateType": "anything", "group": "Ungrouped variables", "name": "p", "description": ""}, "b": {"definition": "d*t+c*v+n", "templateType": "anything", "group": "Ungrouped variables", "name": "b", "description": ""}, "t": {"definition": "random(1..4)", "templateType": "anything", "group": "Ungrouped variables", "name": "t", "description": ""}, "v": {"definition": "random(1..4)", "templateType": "anything", "group": "Ungrouped variables", "name": "v", "description": ""}}, "showQuestionGroupNames": false, "metadata": {"notes": "16/01/2013:
\nBased on iassess questions.
", "description": "In the Gaussian integer ring $\\mathbb{Z}[i]$ , find the remainder $r=r_1+r_2i$, where $a \\gt 0,\\;b \\gt 0$ , on dividing $a+bi$ by $c+di$ .
", "licence": "Creative Commons Attribution 4.0 International"}, "contributors": [{"name": "Denis Flynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1216/"}]}]}], "contributors": [{"name": "Denis Flynn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/1216/"}]}