Interval in which a function's roots lie.

207 Views Asked by At

I have this problem:

The root of the function $f(x)=\cos(x) -x +2 $, lies in

a. [0,2]

b. [1,2]

c. [-1,1]

2

There are 2 best solutions below

3
On BEST ANSWER

Hint: $f(x)=\cos(x)-x+2$ is continuous on $[-1,2]$ as it is the sum of three continuous functions. Therefore, we can apply the intermediate value theorem.

The intermediate value theorem states that if a function $f(x)$ is continuous on an interval $[a,b]$ and if $f(a)<0$ and $f(b)>0$ (or vice-versa), then there is some third point $c$ with $a<c<b$ such that $f(c)=0$.

Therefore, you should find the value of $f(x)$ on the endpoints of the three intervals

  • $f(0)$ and $f(2)$ where $[a,b]=[0,2]$
  • $f(1)$ and $f(2)$ where $[a,b]=[1,2]$
  • $f(-1)$ and $f(1)$ where $[a,b]=[-1,1]$

The interval where $f(a)<0$ and $f(b)>0$ (or vice-versa) is where you will have a root of $f(x)$. In your case, two of the intervals contain a root of $f(x)$.

3
On

Hint:

Just plug in the upper and lower limits of the range and observe if there's a change in sign in the values of the function.

For example, $f(0) =3$, $f(2) \approx -0.416 $

where $f(x) = \cos x -x +2$