0
$\begingroup$

On one of my piecewise questions I've split a graph into an exponential function, a cosine function and a parabolic function. I've done fine for exponential and parabola but I'm totally stuck on cosine and I have no idea what I'm doing... Please help!

$\endgroup$

closed as unclear what you're asking by Shailesh, JonMark Perry, drhab, Watson, user1551 Jul 18 '16 at 16:57

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    $\begingroup$ Can you show an image of the graph? It's hard to tell what you're asking. $\endgroup$ – f'' Jul 18 '16 at 4:00
  • $\begingroup$ @f'' Unfortunately I don't have enough reputation points to post an image directly under the question which is stupid but hopefully the link below will direct you to the image. $\endgroup$ – user505768 Jul 18 '16 at 4:07
  • $\begingroup$ @f'' twitter.com/JordanCocelli/status/754888920375058432?s=09 $\endgroup$ – user505768 Jul 18 '16 at 4:07
1
$\begingroup$

One issue is that the curve you have sketched has a continuous derivative, which rounds things off at the joints. The part you have labeled exp fits $y=2^x$ perfectly, but that is growing rapidly at $x=2$ and doesn't blend with the cos piece. If we let there be corners at $x=2,5$ it is not so hard to find a piecewise graph. $$y=\begin {cases} 2^x&-2 \le x \le 2\\\frac 52 +\frac 32 \cos \frac {x-2}\pi x& 2\lt x \le 5\\2+(x-6)^2&5\lt x \le 7 \end {cases}$$ If you want things to blend smoothly, you need more freedom in the function.

$\endgroup$
  • $\begingroup$ Please define continuous derivative. Also, are you saying that I should write my functions so that they fit with the continuity of the line? And if it wouldn't bother you, can you please elaborate on how you obtained the cosine function. Thanks $\endgroup$ – user505768 Jul 18 '16 at 4:50
0
$\begingroup$

I assume you want to find the equation of a cosine-shaped curve which has been possibly scaled and translated. This means that the curve has the form:

$$y(x) = a\cdot \cos{(bx + c)} + d$$

And all you have to do is identify the missing numbers $a, b, c, d$.

Here are some ways to analyze your cosine-shaped curve to find out how much it has been scaled and translated.

  • First, if you know the maximum and minimum height of the curve, then their average will be the value of $d$. (Every cosine-shaped curve oscillates around its midline, the horizontal line $y=d$.)
  • Second, if you know the maximum and minimum height of the curve, their difference is the overall height of your curve. Ordinarily, the curve $y(x)=\cos{x}$ spans from -1 to 1 and consequently has height 2. If the curve instead has been stretched vertically so that it has height $v$, you know that $a = v/2$.
  • Third, if you know the period of the curve (i.e. how long it takes for it to repeat itself), then you can compute $b$. Ordinarily, the curve $y(x) =\cos{x}$ repeats every $2\pi$ units. If it has been stretched horizontally so that it repeats every $h$ units instead, then you know that $b = 2\pi / h$.
  • Finally, how far has the curve been translated horizontally? There are many good answers. If you can find the x-coordinate $x$ of any point where the curve reaches its maximum height, then you can use $c\equiv -x$.
$\endgroup$

Not the answer you're looking for? Browse other questions tagged or ask your own question.