The question states find the maximum and minimum values of $1/(\cos x + \sin x)$ and I turned it into $1/(\sqrt{2} \sin(x+pi/4))$ and my answers are $1/\sqrt{2}$ for the maximum and $-1/\sqrt{2}$ minimum but the answer is $1/\sqrt{2}$ for the minimum and $-1/\sqrt{2}$ for the maximum.

Why are those the answers?


  • 4
    $\begingroup$ Yes, the local minima might all be bigger than the local maxima! Look at the graph of $1/\cos x$. The present function is rather similar. $\endgroup$ – Lord Shark the Unknown Apr 27 '19 at 16:53
  • $\begingroup$ @LordSharktheUnknown is there a difference between the local minimum and the minimum value? $\endgroup$ – user639649 Apr 27 '19 at 16:57
  • $\begingroup$ $cosx+sinx=0$ for $x=-\frac{\pi}{4}$ or $x=\frac{3\pi}{4}$.so min and max of $\frac{1}{cosx+sinx}$ are $\pm \infty$. $\endgroup$ – herb steinberg Apr 27 '19 at 16:59
  • $\begingroup$ @user639649 Yes, your function does not have a minimum value. Look at the graph and you will see that all of the local minima are larger than the local maxima. $\endgroup$ – kccu Apr 27 '19 at 16:59
  • $\begingroup$ We can use math.stackexchange.com/questions/2150994/… to validate it. The reason is the function is not continuous everywhere. See math.stackexchange.com/questions/1727241/… $\endgroup$ – lab bhattacharjee Apr 27 '19 at 17:00

Hint: Let $$f(x)=\frac{1}{\sin(x)+\cos(x)}$$ then $$f'(x)=-{\frac {\cos \left( x \right) -\sin \left( x \right) }{ \left( \sin \left( x \right) +\cos \left( x \right) \right) ^{2}}} $$

  • $\begingroup$ The question requires us to use the concept of harmonic equations so I wouldnt be able to do this $\endgroup$ – user639649 Apr 27 '19 at 17:02
  • 1
    $\begingroup$ You must only solve the equation $$f'(x)=0$$ $\endgroup$ – Dr. Sonnhard Graubner Apr 27 '19 at 17:03
  • $\begingroup$ So the normal way you would find maximum points? $\endgroup$ – user639649 Apr 27 '19 at 17:07
  • 1
    $\begingroup$ Yes, this is the way to solve such problems. $\endgroup$ – Dr. Sonnhard Graubner Apr 27 '19 at 17:08

Hint: $\sin x + \cos x = \sqrt{2}\sin(x+\pi/4)$. What is the maximal value of this expression? What is the maximal value of this expression? What happens if we invert these extremal values? What happens with the inverse if this value is $0$?

  • $\begingroup$ I mentioned using this form in my question, so my question is why is 1/root2 the minimum? and not the maximum $\endgroup$ – user639649 Apr 27 '19 at 17:07
  • $\begingroup$ If the sum is equal to $0$ we get a singularity. Hence, the function grows unbounded. Note that we are talking about local extrema. The function is unbounded in both directions. The square root of 2 was a local maximum but we have to invert it and it will become the minimum. Similarly, we had $-\sqrt{2}$ as a minimum which will become a local maximum after inverting. $\endgroup$ – MachineLearner Apr 27 '19 at 17:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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