Derivative of a definite integral issue $g:\mathbb{(0,1]}\to \mathbb{R}$
We have the function $$g\left(x\right)=\int _x^1\left(\frac{\sin\left(t\right)}{t}dt\right)\:$$
Show that the function is strictly decreasing.
So I thought that I'd differentiate the function and prove that the derivative is $\lt0$. I found on-line that that the derivative of this function is:
$$\frac{d}{dx} \int _x^1\left(\frac{\sin(t)}{t}\right) \, dt=-\frac{\sin(x)}{x}$$
Why is that exactly? I thought that $\frac{d}{dx} \int _a^b (f(t)) \, dt = f(t)\text{ from }a\text{ to }b$.
 A: There is no need of differentiating:
If $0<x<y<1$ then
$$g(x)-g(y)=\int_x^1\frac{\sin t}tdt-\int_y^1\frac{\sin t}tdt=\int_x^y\frac{\sin t}tdt>0$$
since the integrand is positive and $y>x$.
If you still want to differentiate $g$, just write
$$g(x)=\int_0^1\frac{\sin t}tdt-\int_0^x\frac{\sin t}tdt$$
and apply the fundamental theorem of calculus.
Note that you can assume that the integrand is $1$ at $0$ since $\sin t/t\to 1$ when $t\to 0$. 
A: It is because the only dependence on $x$ is in the lower limit of the integral.
Remember that a definite integral, in your case, has the form 
$$
g(x)= F(1) - F(x)
$$
with $\frac{d}{dt} F(t) = \frac{\sin t}{t}$, hence the minus sign.
A: Assume that $x,y\in(0,1]$ and $x<y$. Then:
$$ g(x)-g(y) = \int_{x}^{y}\frac{\sin t}{t}\,dt \geq \frac{\sin 1}{1}(y-x), $$
since for any $t\in (0,1]$ we have $\frac{\sin t}{t}\geq \frac{\sin 1}{1}$, because $\sin x$ is a concave function over $(0,1]$.
A: Observe that $\mathop {\lim }\limits_{x \to 0} \frac{{\sin (x)}}{x} = 1$ 
and so the function $f(x) = \left\{ \begin{array}{l}
\frac{{\sin (x)}}{x}{\rm{  , }}x > 0\\
1{\rm{ ,   }}x = 0
\end{array} \right.$ is continuous in $[0,\infty )$. 
Now for $x > 0 $, $g(x) = \int_x^1 {\frac{{\sin (t)}}{t}dt}  = \int_x^1 {f(t)dt}  = \int_0^1 {f(t)dt}  - \int_0^x {f(t)} dt$ .
 Therefore, for $ x > 0 $, by the Fundamental Theorem of Calculus,
$\frac{d}{{dx}}g(x) = \frac{d}{{dx}}\left( {\int_0^1 {f(t)dt}  - \int_0^x {f(t)} dt} \right)$ 
$ =  - \frac{d}{{dx}}\int_0^x {f(t)} dt =  - f(x) =  - \frac{{\sin (x)}}{x}$ . 
Note that when you need to differentiate a function defined by an integral using the Fundamental Theorem of Calculus, you should check that the integrand function is continuous. Use the Fundamental Theorem of Calculus carefully.
For a reference to the Fundamental Theorem of Calculus see Fundamental Theorem of Calculus
