// Numbas version: exam_results_page_options {"name": "Domain of a trigonometric function (radians)", "extensions": [], "custom_part_types": [], "resources": [], "navigation": {"allowregen": true, "showfrontpage": false, "preventleave": false, "typeendtoleave": false}, "question_groups": [{"pickingStrategy": "all-ordered", "questions": [{"tags": [], "parts": [{"variableReplacementStrategy": "originalfirst", "maxMarks": 0, "marks": 0, "shuffleChoices": true, "choices": ["

$\\mathbb{R}$

", "

$(-\\infty,\\infty)$

", "

$[\\var{d},\\infty)$

", "

$[\\var{a},\\infty)$

", "

$\\left[\\simplify{{-c}/{d}},\\infty\\right)$

", "

$\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{b}<={inp}<={c}}\\}$

"], "prompt": "

Which of the following represents the domain of {sincos}?

", "showCorrectAnswer": true, "maxAnswers": 0, "displayColumns": "1", "distractors": ["", "", "", "", "", ""], "displayType": "checkbox", "warningType": "none", "type": "m_n_2", "matrix": ["1", "1", 0, 0, 0, 0], "showFeedbackIcon": true, "minAnswers": 0, "minMarks": 0, "variableReplacements": [], "scripts": {}}, {"variableReplacementStrategy": "originalfirst", "maxMarks": 0, "marks": 0, "shuffleChoices": true, "choices": ["

$\\mathbb{R}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k=\\ldots, -1,0,1,\\ldots\\right\\}$

", "

$\\mathbb{R}\\setminus\\left\\{\\frac{\\pi}{2}+k\\pi:\\, k\\in \\mathbb{Z}\\right\\}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\pm\\frac{\\pi}{2}\\right\\}$

", "

$\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}>={d2}}\\}$

", "

$\\mathbb{R}\\setminus\\left\\{k\\pi:\\, k\\in \\mathbb{Z}\\right\\}$

"], "prompt": "

Which of the following represents the domain of {easytan}?

", "showCorrectAnswer": true, "maxAnswers": 0, "displayColumns": "1", "distractors": ["", "", "", "", "", "", ""], "displayType": "checkbox", "warningType": "none", "type": "m_n_2", "matrix": ["0", "1", "1", "1", 0, 0, 0], "showFeedbackIcon": true, "minAnswers": 0, "minMarks": 0, "variableReplacements": [], "scripts": {}}, {"variableReplacementStrategy": "originalfirst", "maxMarks": 0, "marks": 0, "shuffleChoices": true, "choices": ["

$\\mathbb{R}$

", "

$\\left\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{inp}}\\ne\\left(\\simplify[fractionNumbers,simplifyFractions]{{(1/2-c2)/b2}}+\\simplify[fractionNumbers,simplifyFractions]{{1/b2}}k\\right)\\pi \\text{  for  }  k\\in\\mathbb{Z} \\right\\}$

", "

$\\left\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{inp}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k=\\ldots, -1,0,1,\\ldots\\right\\}$

", "

$\\mathbb{R}\\setminus\\left\\{\\frac{\\pi}{2}+k\\pi:\\, k\\in \\mathbb{Z}\\right\\}$

", "

$\\left\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{inp}}\\ne \\pm\\frac{\\pi}{2}\\right\\}$

", "

$\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{inp2}>={d2}}\\}$

", "

$\\left\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify[fractionNumbers]{{b2}{inp}+{c2}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

"], "prompt": "

Which of the following represents the domain of {hardtan}?

", "showCorrectAnswer": true, "maxAnswers": 0, "displayColumns": "1", "distractors": ["", "", "", "", "", "", ""], "displayType": "checkbox", "warningType": "none", "type": "m_n_2", "matrix": ["0", "1", "0", "0", 0, 0, "1"], "showFeedbackIcon": true, "minAnswers": 0, "minMarks": 0, "variableReplacements": [], "scripts": {}}, {"variableReplacementStrategy": "originalfirst", "maxMarks": 0, "marks": 0, "shuffleChoices": true, "choices": ["

$\\mathbb{R}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{cos({inp2})}\\ne 0\\right\\}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{sin({inp2})}\\ne 0\\right\\}$

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\pm\\frac{\\pi}{2}\\right\\}$

", "

$\\mathbb{R}\\setminus\\left\\{\\frac{\\pi}{2}k:\\, k\\in \\mathbb{Z}\\right\\}$

\n

", "

$\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

"], "prompt": "

Which of the following represents the domain of {seccsc}?

", "showCorrectAnswer": true, "maxAnswers": 0, "displayColumns": "1", "distractors": ["", "", "", "", "", "", ""], "displayType": "checkbox", "warningType": "none", "type": "m_n_2", "matrix": ["0", "if(select=1,1,0)", "if(select=1,1,0)", "if(select=0,1,0)", 0, "0", "if(select=0,1,0)"], "showFeedbackIcon": true, "minAnswers": 0, "minMarks": 0, "variableReplacements": [], "scripts": {}}, {"variableReplacementStrategy": "originalfirst", "maxMarks": 0, "marks": 0, "shuffleChoices": true, "choices": ["

$\\mathbb{R}$

", "

$\\left\\{\\theta\\in\\mathbb{R}:\\,\\theta\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

", "

$\\left\\{\\theta\\in\\mathbb{R}:\\,\\cos(\\theta)\\ne 0\\right\\}$

", "

$\\left\\{\\theta\\in\\mathbb{R}:\\,\\sin(\\theta)\\ne 0\\right\\}$

", "

$\\left\\{\\theta\\in\\mathbb{R}:\\,\\theta\\ne \\pm\\frac{\\pi}{2}\\right\\}$

", "

$\\mathbb{R}\\setminus\\left\\{\\frac{\\pi}{2}k:\\, k\\in \\mathbb{Z}\\right\\}$

\n

", "

$\\left\\{\\theta\\in\\mathbb{R}:\\,\\theta\\ne k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$

"], "prompt": "

Which of the following represents the domain of $f(\\theta)=\\simplify[fractionNumbers]{{b2}cot(theta)+{a2}}$?

", "showCorrectAnswer": true, "maxAnswers": 0, "displayColumns": "1", "distractors": ["", "", "", "", "", "", ""], "displayType": "checkbox", "warningType": "none", "type": "m_n_2", "matrix": ["0", "0", "0", "1", 0, "0", "1"], "showFeedbackIcon": true, "minAnswers": 0, "minMarks": 0, "variableReplacements": [], "scripts": {}}], "variable_groups": [{"variables": ["out", "inp", "sincos", "a", "b", "c", "d"], "name": "a"}, {"variables": ["inp2", "easytan", "a2", "d2", "out2"], "name": "b"}, {"variables": ["hardtan", "b2", "c2"], "name": "c"}], "ungrouped_variables": ["seccsc", "select"], "variables": {"sincos": {"group": "a", "description": "", "definition": "random(['\\$\\\\simplify{{out}({inp})={a}sin({b}{inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})=sin({b}{inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}sin({inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}sin({b}{inp})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}sin({b}{inp}+{c})}\\$','\\$\\\\simplify{{out}({inp})=sin({b}{inp}+{c})}\\$','\\$\\\\simplify{{out}({inp})={a}sin({b}{inp})}\\$','\\$\\\\simplify{{out}({inp})={a}sin({inp})+{d}}\\$',\n'\\$\\\\simplify{{out}({inp})={a}cos({b}{inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})=cos({b}{inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}cos({inp}+{c})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}cos({b}{inp})+{d}}\\$','\\$\\\\simplify{{out}({inp})={a}cos({b}{inp}+{c})}\\$','\\$\\\\simplify{{out}({inp})=cos({b}{inp}+{c})}\\$','\\$\\\\simplify{{out}({inp})={a}cos({b}{inp})}\\$','\\$\\\\simplify{{out}({inp})={a}cos({inp})+{d}}\\$'])", "name": "sincos", "templateType": "anything"}, "d2": {"group": "b", "description": "", "definition": "random(-12..12 except 0)", "name": "d2", "templateType": "anything"}, "d": {"group": "a", "description": "", "definition": "random(-12..12 except 0)", "name": "d", "templateType": "anything"}, "a2": {"group": "b", "description": "", "definition": "random(-12..12 except 0)", "name": "a2", "templateType": "anything"}, "out2": {"group": "b", "description": "", "definition": "expression(random('f','h','g','p','q','y'))", "name": "out2", "templateType": "anything"}, "c2": {"group": "c", "description": "

expression(random(['pi/3','pi/2','pi/4','pi/6','-pi/3','-pi/2','-pi/4','-pi/6']))

", "definition": "random([1/3,1/8,1/4,1/6,1,1/12])", "name": "c2", "templateType": "anything"}, "inp": {"group": "a", "description": "", "definition": "expression(random('x','r','s','t','w'))", "name": "inp", "templateType": "anything"}, "a": {"group": "a", "description": "", "definition": "random(-12..12 except 0)", "name": "a", "templateType": "anything"}, "hardtan": {"group": "c", "description": "", "definition": "random(['\\$\\\\simplify[basic,fractionNumbers]{{out}({inp})={a2}tan({b2}{inp}+{c2}pi)+{d2}}\\$','\\$\\\\simplify[basic,fractionNumbers]{{out}({inp})=tan({b2}{inp}+{c2}pi)+{d2}}\\$','\\$\\\\simplify[basic,fractionNumbers]{{out}({inp})={a2}tan({b2}{inp}+{c2}pi)}\\$'])", "name": "hardtan", "templateType": "anything"}, "inp2": {"group": "b", "description": "", "definition": "expression(random('x','r','s','t','w'))", "name": "inp2", "templateType": "anything"}, "b": {"group": "a", "description": "", "definition": "random(-12..12 except 0)", "name": "b", "templateType": "anything"}, "b2": {"group": "c", "description": "", "definition": "random(2,3,4,1/2,1/3,1/4)", "name": "b2", "templateType": "anything"}, "out": {"group": "a", "description": "", "definition": "expression(random('f','h','g','p','q','y'))", "name": "out", "templateType": "anything"}, "seccsc": {"group": "Ungrouped variables", "description": "", "definition": "['\\$\\\\simplify{{out2}({inp2})={b}csc({inp2})+{c}}\\$', '\\$\\\\simplify{{out2}({inp})={b}sec({inp2})+{c}}\\$'][select]", "name": "seccsc", "templateType": "anything"}, "easytan": {"group": "b", "description": "", "definition": "random(['\\$\\\\simplify{{out2}({inp2})={a2}tan({inp2})+{d2}}\\$','\\$\\\\simplify{{out2}({inp2})=tan({inp2})+{d2}}\\$','\\$\\\\simplify{{out2}({inp2})={a2}tan({inp2})}\\$'])", "name": "easytan", "templateType": "anything"}, "c": {"group": "a", "description": "", "definition": "random(-12..12 except 0)", "name": "c", "templateType": "anything"}, "select": {"group": "Ungrouped variables", "description": "", "definition": "random(0,1)", "name": "select", "templateType": "anything"}}, "functions": {}, "preamble": {"css": "", "js": ""}, "metadata": {"licence": "Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International", "description": "

Multiple choice questions. Given randomised trig functions select the possible ways of writing the domain of the function.

"}, "type": "question", "statement": "

Given the real functions below (which are defined in terms of radians), you should be able to determine their domain. 

\n

", "rulesets": {}, "advice": "

a) The sine and cosine functions accept any real number input. Regardless of the value of $\\simplify{{inp}}$, the function $\\simplify{{out}}$ will output a number. That is, the domain of $\\simplify{{out}}$ is the set of all real numbers. We can write this as 

\n

\\[\\text{dom}(\\simplify{{out}})=\\mathbb{R}\\]

\n

or as the open interval

\n

\\[\\text{dom}(\\simplify{{out}})=(-\\infty,\\infty).\\]

\n

\n

\n

b) Recall that $\\tan(x)=\\frac{\\sin(x)}{\\cos(x)}$ by definition and so is not defined when $\\cos(x)=0$ since division by zero is undefined. These $x$ values correspond to asymptotes. There are an infinite number of asymptotes to $y=\\tan(x)$, equally spaced with $\\pi$ radians between each adjacent asymptote. The asymptotes closest to the origin are $x=-\\dfrac{\\pi}{2}$ and $x=\\dfrac{\\pi}{2}$. We can write the set of asymptotes as $\\left\\{\\dfrac{\\pi}{2}+k\\pi:\\, k=\\ldots,-1,0,1,\\ldots\\right\\}$, or $\\left\\{\\dfrac{\\pi}{2}+k\\pi:\\, k\\in\\mathbb{Z}\\right\\}$ (where $\\mathbb{Z}$ is the set of integers). This means the domain of $\\tan(x)$ would be all the real numbers except for the asymptotes, which we can write as $\\mathbb{R}\\setminus \\left\\{\\dfrac{\\pi}{2}+k\\pi:\\, k\\in\\mathbb{Z}\\right\\}$, or $\\mathbb{R}\\setminus \\left\\{\\dfrac{\\pi}{2}+k\\pi:\\, k=\\ldots,-1,0,1,\\ldots\\right\\}$, or $\\left\\{x\\in\\mathbb{R}:\\,x\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}$, or $\\left\\{x\\in\\mathbb{R}:\\,x\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\ldots,-1,0,1,\\ldots\\right\\}$.

\n

\n

\n

c) The tan function doesn't accept inputs of $\\dfrac{\\pi}{2}+k\\pi$ for $k\\in\\mathbb{Z}$. Since in the function {hardtan}, tan acts on $\\simplify[fractionNumbers]{{b2}{inp}+{c2}pi}$, we require that 

\n

\\[\\simplify[fractionNumbers]{{b2}{inp}+{c2}pi}\\ne \\dfrac{\\pi}{2}+k\\pi \\text{  for  }  k\\in\\mathbb{Z}.\\]

\n

To get a better description of the domain we rearrange for $\\simplify{{inp}}$: 

\n

$\\begin{align}&&\\simplify[fractionNumbers]{{b2}{inp}+{c2}pi}&\\ne \\dfrac{1}{2}\\pi+k\\pi \\text{  for  }  k\\in\\mathbb{Z}\\\\ &\\implies&\\simplify[fractionNumbers]{{b2}{inp}}&\\ne \\simplify[simplifyFractions,fractionNumbers]{{1/2-c2}pi}+k\\pi \\text{  for  }  k\\in\\mathbb{Z}\\\\ &\\implies&\\simplify{{inp}}&\\ne \\simplify[fractionNumbers,simplifyFractions]{{(1/2-c2)/b2}pi+{1/{b2}}pi*k} \\text{  for  }  k\\in\\mathbb{Z} \\\\&\\implies&\\simplify{{inp}}&\\ne \\left(\\simplify[fractionNumbers,simplifyFractions]{{(1/2-c2)/b2}}+\\simplify[fractionNumbers,simplifyFractions]{{1/b2}}k\\right)\\pi \\text{  for  }  k\\in\\mathbb{Z} \\end{align}$

\n

and so we can write the domain as $\\left\\{\\simplify{{inp}}\\in\\mathbb{R}:\\,\\simplify{{inp}}\\ne\\left(\\simplify[fractionNumbers,simplifyFractions]{{(1/2-c2)/b2}}+\\simplify[fractionNumbers,simplifyFractions]{{1/b2}}k\\right)\\pi \\text{  for  }  k\\in\\mathbb{Z} \\right\\}$.

\n

\n

\n

d) Recall that $\\sec(x)=\\dfrac{1}{\\cos(x)}$ by definition and so $\\sec(x)$ is not defined when $\\cos(x)=0$ since division by zero is undefined. Note this is the same condition that was on $\\tan(x)$ and so $\\sec(x)$ and $\\tan(x)$ have the same domain. In particular, for {seccsc}:

\n

$\\begin{align}\\text{dom}(\\simplify{{out2}})&=\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{cos({inp2})}\\ne 0\\right\\}\\\\&=\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne \\frac{\\pi}{2}+k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}\\end{align}$

\n

d) Note, $\\csc$ is also denoted $\\text{cosec}$ by some people. Recall that $\\csc(x)=\\dfrac{1}{\\sin(x)}$ by definition and so $\\csc(x)$ is not defined when $\\sin(x)=0$ since division by zero is undefined. In particular, for {seccsc}:

\n

$\\begin{align}\\text{dom}(\\simplify{{out2}})&=\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{sin({inp2})}\\ne 0\\right\\}\\\\&=\\left\\{\\simplify{{inp2}}\\in\\mathbb{R}:\\,\\simplify{{inp2}}\\ne k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}\\end{align}$

\n

\n

e) Recall that $\\cot(\\theta)=\\dfrac{\\cos(\\theta)}{\\sin(\\theta)}$ by definition and so $\\cot(\\theta)$ is not defined when $\\sin(\\theta)=0$ since division by zero is undefined. In particular, for $f(\\theta)=\\simplify[fractionNumbers]{{b2}cot(theta)+{a2}}$:

\n

$\\begin{align}\\text{dom}(f)&=\\left\\{\\theta\\in\\mathbb{R}:\\,\\sin(\\theta)\\ne 0\\right\\}\\\\&=\\left\\{\\theta\\in\\mathbb{R}:\\,\\theta\\ne k\\pi \\text{ for } k\\in \\mathbb{Z}\\right\\}\\end{align}$

", "extensions": [], "name": "Domain of a trigonometric function (radians)", "variablesTest": {"condition": "", "maxRuns": 100}, "contributors": [{"name": "Ben Brawn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/605/"}, {"name": "Xiaodan Leng", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2146/"}]}]}], "contributors": [{"name": "Ben Brawn", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/605/"}, {"name": "Xiaodan Leng", "profile_url": "https://numbas.mathcentre.ac.uk/accounts/profile/2146/"}]}