// Numbas version: exam_results_page_options {"name": "Modulus & Argument of a Complex Number", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"variablesTest": {"maxRuns": 100, "condition": ""}, "functions": {}, "advice": "

If \$$Z={x}+{}yj\$$

\n

The modulus of \$$Z\$$ is given by \$$|Z|=\\sqrt{{x}^2+{y}^2}\$$

\n

In this example \$$Z=\\var{x1}+\\var{y1}j\$$

\n

\$$|Z|=\\sqrt{\\var{x1}^2+\\var{y1}^2}=\\var{mod}\$$

\n

The argument of \$$Z\$$ is defined by

\n

\$$\\theta=tan^{-1}\\left(\\frac{{y}}{{x}}\\right)\$$    if   \$$x>0\$$       and       \$$\\theta=tan^{-1}\\left(\\frac{{y}}{{x}}\\right)+\\pi\$$    if   \$$x<0\$$

\n

", "ungrouped_variables": ["x1", "y1", "theta", "mod"], "tags": [], "metadata": {"licence": "Creative Commons Attribution 4.0 International", "description": "

modulus & argument of a complex number

"}, "variable_groups": [], "extensions": [], "parts": [{"scripts": {}, "prompt": "

Calculate the modulus of the complex number

\n

\$$|Z|\$$ = [[1]]

\n

Calculate the argument of \$$Z\$$

\n

\$$arg(Z)=\\theta\$$ = [[0]]

", "variableReplacementStrategy": "originalfirst", "marks": 0, "type": "gapfill", "showFeedbackIcon": true, "variableReplacements": [], "gaps": [{"precisionType": "dp", "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "minValue": "{theta}", "precisionPartialCredit": 0, "showCorrectAnswer": true, "showFeedbackIcon": true, "scripts": {}, "precision": "2", "allowFractions": false, "correctAnswerStyle": "plain", "marks": 1, "correctAnswerFraction": false, "strictPrecision": false, "maxValue": "{theta}", "variableReplacements": [], "precisionMessage": "You have not given your answer to the correct precision.", "showPrecisionHint": true, "variableReplacementStrategy": "originalfirst"}, {"precisionType": "dp", "notationStyles": ["plain", "en", "si-en"], "type": "numberentry", "minValue": "sqrt({x1}^2+{y1}^2)", "precisionPartialCredit": 0, "showCorrectAnswer": true, "showFeedbackIcon": true, "scripts": {}, "precision": "2", "allowFractions": false, "correctAnswerStyle": "plain", "marks": 1, "correctAnswerFraction": false, "strictPrecision": false, "maxValue": "sqrt({x1}^2+{y1}^2)", "variableReplacements": [], "precisionMessage": "You have not given your answer to the correct precision.", "showPrecisionHint": true, "variableReplacementStrategy": "originalfirst"}], "showCorrectAnswer": true}], "rulesets": {}, "variables": {"x1": {"group": "Ungrouped variables", "name": "x1", "description": "", "templateType": "randrange", "definition": "random(-5..5#0.3)"}, "y1": {"group": "Ungrouped variables", "name": "y1", "description": "", "templateType": "randrange", "definition": "random(0.1..5#0.2)"}, "theta": {"group": "Ungrouped variables", "name": "theta", "description": "", "templateType": "anything", "definition": "if({x1}<0,arctan({y1}/{x1})+pi,arctan({y1}/{x1}))"}, "mod": {"group": "Ungrouped variables", "name": "mod", "description": "", "templateType": "anything", "definition": "sqrt({x1}^2+{y1}^2)"}}, "name": "Modulus & Argument of a Complex Number", "preamble": {"js": "", "css": ""}, "statement": "

Given a complex number \$$Z=\\var{x1}+\\var{y1}j\$$

", "type": "question", "contributors": [{"name": "Michael Proudman", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/269/"}]}]}], "contributors": [{"name": "Michael Proudman", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/269/"}]}