Range of $y=a\sin(x)+b\,\mathrm{cosec}(x)$ where $a$ and $b$ are real and $a,b\ne0$

algebra-precalculusfunctionstrigonometry

I’m trying to figure out the range of the function $y=a\sin(x)+b\,\mathrm{cosec}(x)\;$ where $a,b\in\mathbb R\setminus\{0\}$, without using calculus (as I have not started it yet)
Here is my approach:

$y=a\sin x+b\csc x$
$\implies a\sin^2(x)-y\sin(x)+b=0$
$\implies \sin(x)=\dfrac{y\pm\sqrt{y^2-4ab}}{2a}$

now the inequality under the square root yields

$y=\left(-\infty,-2\sqrt{ab}\,\right]\cup\left[2\sqrt{ab},+\infty\right)\;\;$ if $\,ab>0$
or, $\;y=\mathbb R\;\;$ if $\,ab<0\;.$

But $\;\sin(x)=\dfrac{y\pm\sqrt{y^2-4ab}}{2a}\in[-1,1]\setminus\{0\}$
the interval should impose additional restrictions on the value of "$y$".
So how do I solve for "$y$" from the interval? And what is the range?
After analysing some graphs of asin(x)+bcosec(x) for different values of a and b,this is what I came up with:

1.If ab>0 and |a|≤|b|; y=(-∞,-|a+b|]∪[|a+b|,+∞)
2.If ab>0 and |a|>|b|; y=(-∞,-2√(ab)]∪[2√(ab),+∞)
3.If ab<0 and |a|<|b|; y=(-∞,-|a+b|]∪[|a+b|,+∞)
4.If ab<0 and |a|≥|b|; y=R
(where a and b are the coefficients of sin(x) and cosec(x) respectively)

Is it correct?

Best Answer

This answer was written before revision 4 of the question.


It's less confusing if you start with getting rid of the trigonometry by reinterpreting $$ \text{range of } f(x) = a\sin x + b\operatorname{cosec} x \text{ when } \sin x \ne 0 $$ as $$ \text{range of } g(u) = au + \frac bu \text{ when } u \in [-1,1]\setminus \{0\} $$ The benefit of this is that you're now free to imagine how $g(u)$ behaves on the entire real line, without being distracted by the fact that most of the real line isn't sines of anything. Even though we're only interested in the range for $-1\le u\le 1$, knowing how the rest of the function looks will help getting a sense of what's going on.

In particular we can sketch the graph of $au+b/u$ under various assumptions for the signs of $a$ and $b$.

When $a$ and $b$ are both positive, the graph for $u>0$ starts coming down from infinity (vertical asymptote at $u=0$), reaches a minimum and then starts climbing to meet an asymptote with slope $a$. (For $u<0$ the graph is just the same, rotated by $180^\circ$ because $g$ is odd). In order to figure out the behavior further, you'll need to determine whether the minimum is to the left or right of $u=1$. If the minimum is to the right of $u=1$, the graph shows us that the range on $(0,1]$ is $[g(1),\infty)$; otherwise it is $[g(\text{the minimum}), \infty)$.

Your idea of using the quadratic formula to invert $g$ is good when you can't rely on calculus to find the minimum -- from the graph we can see that the minimum is the $y$ where the quadratic formula gives exactly one solution, that is, when $y^2-4ab = 0$. You've already found that this happens when $y=2\sqrt{ab}$. The $u$-coordinate of the minimum is just $y/2a$, which you can then compare to $1$ to find out which case you're in.

You should end up with a result that gives different forms of the range depending on conditions on $a$ and $b$. Remember to include the part of the range produced by $u\in[-1,0)$.

If $b$ is positive but $a$ is negative, the graph of $g$ still comes down from infinity, but now it keeps decreasing forever without ever reaching any minimum. The range on $(0,1]$ is then again $[g(1), \infty)$. Again we need to combine that with a range on $[-1,0)$, but now there's a chance that the union of those two ranges is actually all of $\mathbb R$, namely if $g(1)\le 0$.

There are then two similar cases to do when $b$ is negative.

Related Question