// Numbas version: finer_feedback_settings {"name": "Trigonometry: Alternative Trigonometric Forms Combined", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"name": "Trigonometry: Alternative Trigonometric Forms Combined", "tags": [], "metadata": {"description": "
Rewriting a trigonometric expression of the form $A\\cos(\\theta)\\pm B\\sin(\\theta)$ to either $R\\sin(\\theta+\\alpha)$ or $R\\cos(\\theta+\\alpha)$ by calculating $R$ and $\\alpha$.
", "licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International"}, "statement": "If
\n{question}
\nfind the values for $R$ and $\\alpha$, given $R>0$ and $0<\\alpha<\\frac{\\pi}{2}$.
", "advice": "\n{answer}
", "rulesets": {}, "extensions": [], "builtin_constants": {"e": true, "pi,\u03c0": true, "i": true}, "constants": [], "variables": {"A": {"name": "A", "group": "Ungrouped variables", "definition": "random(1..5)", "description": "", "templateType": "anything", "can_override": false}, "B": {"name": "B", "group": "Ungrouped variables", "definition": "random(1..5 except A)", "description": "", "templateType": "anything", "can_override": false}, "R": {"name": "R", "group": "Ungrouped variables", "definition": "sqrt(A^2+B^2)", "description": "", "templateType": "anything", "can_override": false}, "Rround": {"name": "Rround", "group": "Ungrouped variables", "definition": "precround(R,2)", "description": "", "templateType": "anything", "can_override": false}, "alpha": {"name": "alpha", "group": "Ungrouped variables", "definition": "arctan(B/A)", "description": "", "templateType": "anything", "can_override": false}, "Rsol": {"name": "Rsol", "group": "Ungrouped variables", "definition": "if(R=round(R),'{Rsol1}','{Rsol2}')", "description": "", "templateType": "anything", "can_override": false}, "Rsol1": {"name": "Rsol1", "group": "Ungrouped variables", "definition": "\"\\\\[ \\\\begin{split} R^2\\\\cos^2(\\\\alpha) + R^2 \\\\sin^2(\\\\alpha) &\\\\,= \\\\var{A}^2+\\\\var{B}^2 \\\\\\\\ R^2 (\\\\cos^2(\\\\alpha) +\\\\sin^2(\\\\alpha)) &\\\\,= \\\\var{A^2+B^2} \\\\\\\\ R &\\\\,= \\\\var{R}. \\\\end{split} \\\\]
\"", "description": "", "templateType": "long string", "can_override": false}, "Rsol2": {"name": "Rsol2", "group": "Ungrouped variables", "definition": "\"\\\\[ \\\\begin{split} R^2\\\\cos^2(\\\\alpha) + R^2 \\\\sin^2(\\\\alpha) &\\\\,= \\\\var{A}^2+\\\\var{B}^2 \\\\\\\\ R^2 (\\\\cos^2(\\\\alpha) +\\\\sin^2(\\\\alpha)) &\\\\,= \\\\var{A^2+B^2} \\\\\\\\ R &\\\\,= \\\\sqrt{\\\\var{A^2+B^2}}\\\\\\\\ &\\\\,=\\\\var{Rround} \\\\text{ (2 d.p.)}. \\\\end{split} \\\\]
\"", "description": "", "templateType": "long string", "can_override": false}, "alpharound": {"name": "alpharound", "group": "Ungrouped variables", "definition": "precround(alpha,2)", "description": "", "templateType": "anything", "can_override": false}, "question": {"name": "question", "group": "Ungrouped variables", "definition": "if(Q=1,'{q1}','{q2}')", "description": "", "templateType": "anything", "can_override": false}, "Q": {"name": "Q", "group": "Ungrouped variables", "definition": "random(1,2)", "description": "", "templateType": "anything", "can_override": false}, "sign": {"name": "sign", "group": "Ungrouped variables", "definition": "random(1,-1)", "description": "", "templateType": "anything", "can_override": false}, "q1": {"name": "q1", "group": "Ungrouped variables", "definition": "\"\\\\[ \\\\simplify[unitFactor]{{A}sin(theta)+{sign*B}cos(theta)} = \\\\simplify[unitFactor]{R sin (theta+{sign}*alpha)},\\\\]
\"", "description": "", "templateType": "long string", "can_override": false}, "q2": {"name": "q2", "group": "Ungrouped variables", "definition": "\"\\\\[ \\\\simplify[unitFactor]{{A}cos(theta)-{sign*B}sin(theta)} = \\\\simplify[unitFactor]{R cos (theta+{sign}*alpha)},\\\\]
\"", "description": "", "templateType": "long string", "can_override": false}, "a1": {"name": "a1", "group": "Ungrouped variables", "definition": "\"To find $R$ and $\\\\alpha$ we want to first rewrite our equation using the double-angle formula, $\\\\simplify[unitFactor]{sin(a+{sign}*b)=sin(a)cos(b)+{sign}*sin(b)cos(a)}$:
\\n\\\\[ \\\\begin{split}\\\\simplify[unitFactor]{{A}sin(theta)+{sign*B}cos(theta)} &\\\\,= \\\\simplify{R sin(theta+{sign}*alpha)} \\\\\\\\ &\\\\,= \\\\simplify{R(sin(theta)cos(alpha) + {sign}*sin(alpha)cos(theta))} \\\\\\\\ &\\\\,= \\\\simplify{Rsin(theta)cos(alpha) + {sign}*R sin(alpha)cos(theta)}. \\\\end{split} \\\\]
\\nBy comparing the coefficients of $\\\\sin(\\\\theta)$ and $\\\\cos(\\\\theta)$, we find that
\\n\\\\[ R\\\\cos(\\\\alpha) = \\\\var{A},\\\\quad \\\\text{and} \\\\quad R\\\\sin(\\\\alpha) = \\\\var{B}. \\\\]
\\nTo calculate $R$, we want to square these results and add them together, allowing us to make use of $\\\\sin^2(\\\\alpha)+\\\\cos^2(\\\\alpha) = 1$:
\\n{Rsol}
\\nSimilarly, to find $\\\\alpha$ we can divide $R\\\\sin(\\\\alpha) = \\\\var{B}$ by $R\\\\cos(\\\\alpha) = \\\\var{A}$, and use the identity $\\\\tan(\\\\alpha) = \\\\frac{\\\\sin(\\\\alpha)}{\\\\cos(\\\\alpha)}$:
\\n\\\\[ \\\\frac{R\\\\sin(\\\\alpha)}{R\\\\cos(\\\\alpha)} = \\\\frac{\\\\var{B}}{\\\\var{A}} \\\\implies \\\\tan(\\\\alpha) = \\\\simplify[fractionNumbers]{{B/A}}.\\\\]
\\nTherefore, \\\\[ \\\\begin{split} \\\\alpha &\\\\,= \\\\tan^{-1}\\\\left(\\\\simplify[fractionNumbers]{{B/A}}\\\\right) \\\\\\\\ &\\\\,= \\\\var{alpharound} \\\\text{ (2 d.p.)}. \\\\end{split} \\\\]
\\n\"", "description": "", "templateType": "long string", "can_override": false}, "a2": {"name": "a2", "group": "Ungrouped variables", "definition": "\"To find $R$ and $\\\\alpha$ we want to first rewrite our equation using the double-angle formula, $\\\\simplify{cos(a+{sign}*b)=cos(a)cos(b)-{sign}*sin(a)sin(b)}$:
\\n\\\\[ \\\\begin{split}\\\\simplify[unitFactor]{{A}cos(theta)-{sign*B}sin(theta)} &\\\\,= \\\\simplify[unitFactor]{R cos (theta + {sign}*alpha)} \\\\\\\\ &\\\\,= \\\\simplify{R(cos(theta)cos(alpha) - {sign}*sin(theta)sin(alpha))} \\\\\\\\ &\\\\,= \\\\simplify{Rcos(theta)cos(alpha) - {sign}*R sin(theta)sin(alpha)}. \\\\end{split} \\\\]
\\nBy comparing the coefficients of $\\\\cos(\\\\theta)$ and $\\\\sin(\\\\theta)$, we find that
\\n\\\\[ R\\\\cos(\\\\alpha) = \\\\var{A},\\\\quad \\\\text{and} \\\\quad R\\\\sin(\\\\alpha) = \\\\var{B}. \\\\]
\\nTo calculate $R$, we want to square these results and add them together, allowing us to make use of $\\\\sin^2(\\\\alpha)+\\\\cos^2(\\\\alpha) = 1$:
\\n{Rsol}
\\nSimilarly, to find $\\\\alpha$ we can divide $R\\\\sin(\\\\alpha) = \\\\var{B}$ by $R\\\\cos(\\\\alpha) = \\\\var{A}$, and use the identity $\\\\tan(\\\\alpha) = \\\\frac{\\\\sin(\\\\alpha)}{\\\\cos(\\\\alpha)}$:
\\n\\\\[ \\\\frac{R\\\\sin(\\\\alpha)}{R\\\\cos(\\\\alpha)} = \\\\frac{\\\\var{B}}{\\\\var{A}} \\\\implies \\\\tan(\\\\alpha) = \\\\simplify[fractionNumbers]{{B/A}}.\\\\]
\\nTherefore, \\\\[ \\\\begin{split} \\\\alpha &\\\\,= \\\\tan^{-1}\\\\left(\\\\simplify[fractionNumbers]{{B/A}}\\\\right) \\\\\\\\ &\\\\,= \\\\var{alpharound} \\\\text{ (2 d.p.)}. \\\\end{split} \\\\]
\\n\"", "description": "", "templateType": "long string", "can_override": false}, "answer": {"name": "answer", "group": "Ungrouped variables", "definition": "if(Q=1,'{a1}','{a2}')", "description": "", "templateType": "anything", "can_override": false}}, "variablesTest": {"condition": "", "maxRuns": 100}, "ungrouped_variables": ["Q", "A", "B", "sign", "R", "Rround", "alpha", "alpharound", "Rsol", "Rsol1", "Rsol2", "question", "q1", "q2", "answer", "a1", "a2"], "variable_groups": [], "functions": {}, "preamble": {"js": "", "css": ""}, "parts": [{"type": "gapfill", "useCustomName": false, "customName": "", "marks": 0, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "prompt": "$R=$[[0]]
\n$\\alpha=$[[1]]
\n(Give your answers to 2 decimal places where necessary.)
", "gaps": [{"type": "jme", "useCustomName": true, "customName": "Gap 0", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{Rround}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}, {"type": "jme", "useCustomName": false, "customName": "", "marks": 1, "scripts": {}, "customMarkingAlgorithm": "", "extendBaseMarkingAlgorithm": true, "unitTests": [], "showCorrectAnswer": true, "showFeedbackIcon": true, "variableReplacements": [], "variableReplacementStrategy": "originalfirst", "nextParts": [], "suggestGoingBack": false, "adaptiveMarkingPenalty": 0, "exploreObjective": null, "answer": "{alpharound}", "showPreview": true, "checkingType": "absdiff", "checkingAccuracy": 0.001, "failureRate": 1, "vsetRangePoints": 5, "vsetRange": [0, 1], "checkVariableNames": false, "singleLetterVariables": false, "allowUnknownFunctions": true, "implicitFunctionComposition": false, "caseSensitive": false, "valuegenerators": []}], "sortAnswers": false}], "partsMode": "all", "maxMarks": 0, "objectives": [], "penalties": [], "objectiveVisibility": "always", "penaltyVisibility": "always", "type": "question", "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}]}], "contributors": [{"name": "Ruth Hand", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/3228/"}, {"name": "Ben McGovern", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/4872/"}]}