0
$\begingroup$

This is almost like a puzzle.

This is the graph of $\csc(x).$

Now imagine I take each half-period and rotate it $180^{\circ},$ or flip it vertically, for both operations it would be with reference to the min/max point.

What kind of function would I need to get a graph like this?

Since my example graph is not precise, any function that creates something that looks similar will do.

Thanks for your consideration.

2 Answers 2

2

$$f(x) = -\csc(x) + 2 \sin (x)$$

Desmos plot:

Desmos plot

  • 0
    This formula approximates described transformation very well, however, it is not the exact solution.2017-01-29
  • 0
    From the original question: "any function that creates something that looks similar will do." I liked this one because it involved no "case" statements, and I'm guessing that OP will be using this in a computer program, so that's an advantage. But yours does in fact more closely follow OP's description of the way to get a graph that looks like the one OP wants. I think, however, there is no "exact" solution because OP explicitly says "anything close will do".2017-01-29
  • 0
    I mean that your solution is *correct* since it is *similar* function to described one in original question. Therefore, is an answer to this question. I just wanted to point it out that for somebody looking for exact representation of the described transformation. BTW I up-voted your post.2017-01-29
2

Note, it might be possible to find more beautiful formula, nonetheless, here it is

$$\forall_{k \in \mathbb{Z}} \left\{ \begin{array}{ccc} -\csc{x} + 2& \textrm{for} & x \in (k\pi,(k + 1)\pi)\\ -\csc{x} - 2 & \textrm{for} & x\in ((k+1)\pi, (k+2)\pi) \end{array} \right. $$

Function prooposed by John Hughes is very closed to this formula, however, it is not exactly the same, and is not the exact representation of the transformation outlined in the question.

enter image description here

Therefore, depending on the use case you might prefer to choose one of two.