Function for drawing $\sin x$ with a maximum value of $360$ and minimum of $70$? I want a function to draw $\sin x$ between an upper limit of $360$ and a lower limit of $70$.

Attempt: I know how to handle the lower limit but I'm having trouble with the upper limit.

$$y = a(\sin(x)+1) + 70$$
Since $\sin x$ goes from $-1$ to $+1$ you only need to make

$$f(x)=a\sin x+b$$ and solve the system $$\begin{cases}a+b=360\\-a+b=70\end{cases}$$ hence $$\color{red}{(a,b)=(145,215)}$$
Figured it out seconds after posting by luck. :)

$$y= \frac{290}{2}(\sin(x)+1)+70,$$

since $\sin (x)$ occupies a total height of $2$.