What is the maximum and minimum value of the following function?

85 Views Asked by At

I came across a question in the book Calculus for the Practical Man. The question stated to find the maximum or minimum value of the following function:

$$f(x) = \frac{1}{4}\cos^2x - \sin 2x$$

I tried to find first the critical value by differentiating this function to get:

$$f'(x) = \frac{-\sin2x}{4}-2\cos2x$$

However, I am unable to solve it further to get the value of $x$ for the maximum or minimum. Can someone please help me out? Thanks for helping.

4

There are 4 best solutions below

0
On BEST ANSWER

Rewrite, $$f(x)=\frac18\left(1+\cos(2x)-8\sin(2x)\right)$$ Note that $a\sin x +b\cos x$ has maximum $\sqrt{a^2+b^2}$ and minimum $-\sqrt{a^2+b^2}$. Thus, $$\max f = \frac{1+\sqrt{65}}8$$ $$\min f = \frac{1-\sqrt{65}}8$$

Proof:

$$a\sin x + b\cos x = \sqrt{a^2+b^2}\left(\frac{a}{\sqrt{a^2+b^2}}\sin x + \frac{b}{\sqrt{a^2+b^2}}\cos x\right) = \sqrt{a^2+b^2}\sin(x+\theta)$$ where $\theta = \arctan \left(\frac{b}{a}\right)$. Note $-1\le \sin(x+\theta)\le 1$. This proves our claim. We can also figure out that maximum occurs when $\sin(x+\theta)=1$ and minimum when $\sin(x+\theta)=-1$. Thus, you can also figure where the $\max$ and $\min$ are attained.

0
On

Write $\cos^2 x $ in terms of $\cos 2x$

Then you will get $f(x)$ in the form of $k + a \sin2x + b \cos2x$ where $a,b,k$ are constants.Then you can use the fact that the max value of $a \sin\alpha + b \cos\alpha $ is $\sqrt{a^2 + b^2}$. So the maximum value becomes $k + \sqrt{a^2 + b^2}. $

0
On

(from one of my comments) “Of course, the values of the tangent function can be “pushed through” with some work to obtain max/min values of the function (evaluate sine and cosine functions at the inverse-tangent values), $\ldots$

What follows is probably not what the author intended, but I'm posting it on the off-chance that someone wants to see some details for what I suggested. My guess is that this problem was NOT intended to be a calculus problem, which in my opinion is a bit disingenuous to include in a calculus text without some kind of warning or prior expectation that non-calculus methods should sometimes be used.

First, solve $f'(x) = 0.$ Since $f'(x) = -\frac{1}{2}\cos x \sin x - 2\cos 2x = -\frac{1}{4}\sin 2x - 2\cos 2x,$ we get $-\frac{1}{4}\sin 2x = 2 \cos 2x,$ or $\tan 2x = -8.$

The reason for converting $\cos x \sin x$ to $\frac{1}{2}\sin 2x$ is that it allows us to get a quotient of sine and cosine having the same argument/input, which then allows us to put the equation into the form “trig function of something = a number”. If instead we use the double angle formula for $\cos 2x$ to rewrite the equation in terms of sine and cosine evaluated at $x,$ then we will get a trig equation that seems a lot more difficult to deal with -- doesn’t factor into a product equal to $0,$ so would have to express everything in terms of one trig function using $\sin^2 x + \cos^2 x = 1,$ resulting a somewhat messy radical equation.

Since $\tan 2x = \frac{2\tan x}{1 - \tan^2 x},$ our last version of $f'(x) = 0$ becomes $\frac{2\tan x}{1 - \tan^2 x} = -8,$ or $4\tan^2 x - \tan x - 4 = 0.$ Using the quadratic formula gives $\tan x = \frac{-(-1) \; \pm \; \sqrt{(-1)^2 - 4(4)(-4)}}{2(4)} = \frac{1 \; \pm \; \sqrt{65}}{2}.$

Let’s just deal with $\frac{1 \; + \; \sqrt{65}}{2}$ and see where that takes us. We have to evaluate $f(x)$ at $x = \arctan \left( \frac{1 \; + \; \sqrt{65}}{2} \right),$ which will involve evaluating sine and cosine for $x = \arctan \left(\frac{1 \; + \; \sqrt{65}}{2}\right).$ This can be done by a standard method using an appropriately labeled right triangle or by using an appropriate Pythagorean identity (e.g. see “Example 3: Evaluate a Mixed Composition of Trig Functions” here).

An “appropriately labeled right triangle” has an acute angle of $x$ and opposite side $1 + \sqrt{65}$ and adjacent side $8$ and hypothenuse $\sqrt{130 + 2\sqrt{65}},$ where the value of the hypothenuse is obtained from $\text{hyp}^2 = \text{opp}^2 + \text{adj}^2 = \left(1 + \sqrt{65}\right)^2 + 8^2.$

Since $f(x) = \frac{1}{4}\cos^2 x - \sin 2x = \frac{1}{4}\cos^2 x - 2\sin x \cos x$ and $\cos x = \frac{\text{adj}}{\text{hyp}} = \frac{8}{\sqrt{130 + 2\sqrt{65}}}$ and $\sin x = \frac{\text{opp}}{\text{hyp}} = \frac{1 + \sqrt{65}}{\sqrt{130 + 2\sqrt{65}}},$ we get

$$ f(x) \;\; = \;\; \frac{1}{4}\left(\frac{8}{\sqrt{130 + 2\sqrt{65}}}\right)^2 \; - \; 2 \left(\frac{1 + \sqrt{65}}{\sqrt{130 + 2\sqrt{65}}}\right) \left(\frac{8}{\sqrt{130 + 2\sqrt{65}}}\right) $$

$$ = \;\; \frac{1}{4}\left(\frac{64}{130 + 2\sqrt{65}}\right) \; - \; 16\left(\frac{1 + \sqrt{65}}{130 + 2\sqrt{65}}\right) $$

$$ = \;\; \frac{16 - 16 - 16\sqrt{65}}{130 + 2\sqrt{65}} \;\; = \;\; \frac{-16\sqrt{65}}{130 + 2\sqrt{65}} $$

Now rationalize the denominator to get

$$ \frac{-16\sqrt{65}(130 - 2\sqrt{65})}{(130 + 2\sqrt{65})(130 - 2\sqrt{65})} \;\; = \;\; \frac{-2080\sqrt{65} + 2080}{{130}^2 - (2\sqrt{65})^2} $$

$$ = \;\; \frac{-2080(\sqrt{65} - 1)}{16640} \;\; = \;\; \frac{1 - \sqrt{65}}{8} $$

At this point we need to determine whether this is a maximum or a minimum (or neither). I suppose we could use the 2nd derivative test -- find $f''(x)$ (not difficult) and evaluate it at $x = \arctan \left(\frac{1 \; + \; \sqrt{65}}{2}\right)$ using the numerical values we obtained above for $\cos x$ and $\sin x.$ Then there is the matter of dealing with the other value we found for $x,$ namely $x = \arctan \left(\frac{1 \; - \; \sqrt{65}}{2}\right).$

0
On

Without using the result about $a\cos(x)+b\sin(x)$, here is a solution.

Continue... So, $f^\prime(x)=0$ if $\tan(2x)=-8$. Then, $\cos(2x)=\pm1/\sqrt{65}$. Take $a$ and $b$ such that $$\cos(2a)=+\frac{1}{\sqrt{65}}$$ $$\cos(2b)=-\frac{1}{\sqrt{65}}$$ Then, $$f^{\prime\prime}(x)=-\frac12\cos(2x)+4\sin(2x)=-\frac12\cos(2x)\left(1-8\tan(2x)\right)$$ so $f^{\prime\prime}(a)<0$ and $f^{\prime\prime}(b)>0$. Hence, $a$ is a point of local maximum and $b$ is a point of local minimum. Now, note $$f(x)=\frac14\cos^2(x)-\sin(2x)=\frac14\left(\frac{1+\cos(2x)}{2}\right)-\cos(2x)\tan(2x)$$ Thus, $$f(a)=\frac18\left(1+\frac{1}{\sqrt{65}}\right)+\frac{8}{\sqrt{65}}=\frac{1+\sqrt{65}}{8}$$ $$f(b)=\frac18\left(1-\frac{1}{\sqrt{65}}\right)-\frac{8}{\sqrt{65}}=\frac{1-\sqrt{65}}{8}$$ You can verify these are the global maximum and minimum.

Hope this helps. :)