// Numbas version: exam_results_page_options {"name": "De Moivre's theorem 2", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"advice": "

To evaluate \\(\\sqrt{\\var{x}+\\var{y}j}\\) we must first express \\(Z=\\var{x}+\\var{y}j\\)  in polar form.

\n

The modulus of \\(\\var{x}+\\var{y}j\\) = \\(\\sqrt{\\var{x}^2+(\\var{y})^2}=\\sqrt{\\simplify{{x^2}+{y}^2}}\\)

\n

The argument of the complex number is given by \\(\\theta=tan^{-1}\\left(\\frac{\\var{y}}{\\var{x}}\\right)=\\var{theta}\\)

\n

According to De Moivre's theorem \\(Z^{\\var{n}}=|Z|^{\\var{n}}\\left(cos(\\var{n}*\\theta)+jsin(\\var{n}*\\theta)\\right)\\)

\n

\\((\\simplify{{x}+{y}j})^\\var{n}=\\left(\\sqrt{\\simplify{{x^2}+{y}^2}}\\right)^{\\var{n}}\\left(cos(\\simplify{{n}*{theta}})+jsin(\\simplify{{n}*{theta}})\\right)\\)

\n

=\\(\\simplify{{x2}+{y2}j}\\)

\n

\\(A=\\var{x2}\\)  and  \\(B=\\var{y2}\\)

\n

", "parts": [{"prompt": "

\\(\\sqrt{\\var{x}+\\var{y}j}=\\pm(A+Bj)\\)

\n

Calculate \\(A\\) and \\(B\\)

\n

\n

\\(A\\) = [[0]]

\n

\\(B\\) = [[1]]

", "showFeedbackIcon": true, "marks": 0, "scripts": {}, "variableReplacements": [], "type": "gapfill", "showCorrectAnswer": true, "variableReplacementStrategy": "originalfirst", "gaps": [{"correctAnswerStyle": "plain", "precisionType": "dp", "marks": 1, "allowFractions": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "showPrecisionHint": true, "correctAnswerFraction": false, "precision": "1", "showCorrectAnswer": true, "scripts": {}, "precisionPartialCredit": 0, "variableReplacements": [], "minValue": "{x2}-0.1", "strictPrecision": false, "maxValue": "{x2}+0.1", "precisionMessage": "You have not given your answer to the correct precision."}, {"correctAnswerStyle": "plain", "precisionType": "dp", "marks": 1, "allowFractions": false, "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "variableReplacementStrategy": "originalfirst", "showFeedbackIcon": true, "showPrecisionHint": true, "correctAnswerFraction": false, "precision": "1", "showCorrectAnswer": true, "scripts": {}, "precisionPartialCredit": 0, "variableReplacements": [], "minValue": "{y2}-0.1", "strictPrecision": false, "maxValue": "{y2}+0.1", "precisionMessage": "You have not given your answer to the correct precision."}]}], "variable_groups": [], "statement": "

Use De Moivre's theorem to find a square root of \\(Z=\\var{x}+\\var{y}j\\)

", "preamble": {"css": "", "js": ""}, "functions": {}, "tags": [], "name": "De Moivre's theorem 2", "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

Calculating the square root of a complex number using De Moivre.

"}, "ungrouped_variables": ["x", "y", "n", "theta", "mod", "x2", "y2"], "extensions": [], "variablesTest": {"maxRuns": 100, "condition": ""}, "rulesets": {}, "variables": {"y2": {"name": "y2", "description": "", "definition": "{mod}^{n}*sin({n}*{theta})", "templateType": "anything", "group": "Ungrouped variables"}, "y": {"name": "y", "description": "", "definition": "random(1..15#1)", "templateType": "randrange", "group": "Ungrouped variables"}, "mod": {"name": "mod", "description": "", "definition": "sqrt({x}^2+{y}^2)", "templateType": "anything", "group": "Ungrouped variables"}, "n": {"name": "n", "description": "", "definition": "0.5", "templateType": "number", "group": "Ungrouped variables"}, "x": {"name": "x", "description": "", "definition": "random(1..12#1)", "templateType": "randrange", "group": "Ungrouped variables"}, "x2": {"name": "x2", "description": "", "definition": "{mod}^{n}*cos({n}*{theta})", "templateType": "anything", "group": "Ungrouped variables"}, "theta": {"name": "theta", "description": "", "definition": "arctan({y}/{x})", "templateType": "anything", "group": "Ungrouped variables"}}, "type": "question", "contributors": [{"name": "Frank Doheny", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/789/"}]}]}], "contributors": [{"name": "Frank Doheny", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/789/"}]}