-
Notifications
You must be signed in to change notification settings - Fork 25
/
Copy pathch-riemann.tex
3570 lines (3271 loc) · 104 KB
/
ch-riemann.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
\chapter{The Riemann Integral} \label{int:chapter}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\section{The Riemann integral}
\label{sec:rint}
%mbxINTROSUBSECTION
\sectionnotes{1.5 lectures}
An integral is a way to \myquote{sum} the values of a function.
There is sometimes confusion among students of
calculus between the \emph{integral} and the \emph{antiderivative}.
The integral is (informally) the area under the curve, nothing else.
That we can compute an antiderivative using the integral is a nontrivial
result we must prove.
We will define the \emph{Riemann integral}%
\footnote{Named after the German mathematician
\href{https://en.wikipedia.org/wiki/Riemann}{Georg Friedrich Bernhard Riemann}
(1826--1866).}
using the Darboux integral%
\footnote{Named after the French mathematician
\href{https://en.wikipedia.org/wiki/Darboux}{Jean-Gaston Darboux} (1842--1917).},
an equivalent but technically simpler definition.
\subsection{Partitions and lower and upper integrals}
We want to integrate a bounded function defined on an interval $[a,b]$.
We first define two auxiliary integrals that are defined for all
bounded functions. Only then can we talk about the Riemann integral and
the Riemann integrable functions.
\begin{defn}
A \emph{\myindex{partition}} $P$ of $[a,b]$ is
a finite set of numbers $\{ x_0,x_1,x_2,\ldots,x_n \}$ such that
\begin{equation*}
a = x_0 < x_1 < x_2 < \cdots < x_{n-1} < x_n = b .
\end{equation*}
We write
\begin{equation*}
\Delta x_i \coloneqq x_i - x_{i-1} .
\end{equation*}
Suppose $f \colon [a,b] \to \R$ is bounded and $P$ is a partition of
$[a,b]$.
Define
\begin{align*}
& m_i \coloneqq \inf \, \bigl\{ f(x) : x_{i-1} \leq x \leq x_i \bigr\} , &
& M_i \coloneqq \sup \, \bigl\{ f(x) : x_{i-1} \leq x \leq x_i \bigr\} , \\
& L(P,f) \coloneqq
\sum_{i=1}^n m_i \Delta x_i , &
& U(P,f) \coloneqq
\sum_{i=1}^n M_i \Delta x_i .
\avoidbreak
\end{align*}
We call $L(P,f)$ the \emph{\myindex{lower Darboux sum}} and
$U(P,f)$ the \emph{\myindex{upper Darboux sum}}\index{Darboux sum}.
\glsadd{not:lowerdarbouxsum}
\glsadd{not:upperdarbouxsum}
\end{defn}
The geometric idea of Darboux sums is indicated in
\figureref{darbouxfig}. The lower sum is the area of the shaded
rectangles, and the upper sum is the area of the entire
rectangles, shaded plus unshaded parts. The width of the $i$th rectangle is $\Delta x_i$,
the height of the shaded rectangle is $m_i$, and the height
of the entire rectangle is $M_i$.
\begin{myfigureht}
\includegraphics{figures/darbouxfig}
\caption{Sample Darboux sums.\label{darbouxfig}}
\end{myfigureht}
\begin{prop} \label{sumulbound:prop}
Let $f \colon [a,b] \to \R$ be a bounded function. Let $m, M \in \R$ be
such that for all $x \in [a,b]$, we have $m \leq f(x) \leq M$. Then for every partition $P$
of $[a,b]$,
\begin{equation}
\label{sumulbound:eq}
m(b-a) \leq
L(P,f) \leq U(P,f)
\leq M(b-a) .
\end{equation}
\end{prop}
\begin{proof}
Let $P$ be a partition of $[a,b]$. Note that $m \leq m_i$ for all $i$ and
$M_i \leq M$ for all $i$. Also $m_i \leq M_i$ for all $i$. Finally,
$\sum_{i=1}^n \Delta x_i = (b-a)$. Therefore,
\begin{multline*}
m(b-a) =
m \left( \sum_{i=1}^n \Delta x_i \right)
=
\sum_{i=1}^n m \Delta x_i
\leq
\sum_{i=1}^n m_i \Delta x_i
\leq
\\
\leq
\sum_{i=1}^n M_i \Delta x_i
\leq
\sum_{i=1}^n M \Delta x_i
=
M \left( \sum_{i=1}^n \Delta x_i \right)
=
M(b-a) .
\end{multline*}
Hence we get \eqref{sumulbound:eq}. In particular, the set of lower and
upper sums are bounded sets.
\end{proof}
\begin{defn}
As the sets of lower and upper Darboux sums are bounded, we define
\begin{align*}
& \underline{\int_a^b} f(x)\,dx \coloneqq
\sup \, \bigl\{ L(P,f) : P \text{ a partition of } [a,b] \bigr\} , \\
& \overline{\int_a^b} f(x)\,dx \coloneqq
\inf \, \bigl\{ U(P,f) : P \text{ a partition of } [a,b] \bigr\} .
\end{align*}
We call $\underline{\int}$\glsadd{not:lowerdarboux}
the \emph{\myindex{lower Darboux integral}} and
$\overline{\int}$\glsadd{not:upperdarboux} the
\emph{\myindex{upper Darboux integral}}\index{Darboux integral}.
To avoid worrying about the variable of integration,
we often simply write
\begin{equation*}
\underline{\int_a^b} f \coloneqq
\underline{\int_a^b} f(x)\,dx
\qquad \text{and} \qquad
\overline{\int_a^b} f \coloneqq
\overline{\int_a^b} f(x)\,dx .
\end{equation*}
\end{defn}
If integration is to make sense, then the lower and upper Darboux
integrals should be the same number, as we want a single number to call
\emph{the integral}. However, these two integrals may differ for
some functions.
\begin{example} \label{example:dirichletfunc}
Take the \myindex{Dirichlet function}
$f \colon [0,1] \to \R$, where $f(x) \coloneqq 1$ if
$x \in \Q$ and $f(x) \coloneqq 0$ if $x \notin \Q$. Then
\begin{equation*}
\underline{\int_0^1} f = 0 \qquad \text{and} \qquad
\overline{\int_0^1} f = 1 .
\end{equation*}
The reason is that for any partition $P$ and every $i$, we have
$m_i = \inf \bigl\{ f(x) : x \in [x_{i-1},x_i] \bigr\} = 0$ and
$M_i = \sup \bigl\{ f(x) : x \in [x_{i-1},x_i] \bigr\} = 1$. Thus
\begin{equation*}
L(P,f) = \sum_{i=1}^n 0 \cdot \Delta x_i = 0 , \quad \text{and} \quad
U(P,f) = \sum_{i=1}^n 1 \cdot \Delta x_i = \sum_{i=1}^n \Delta x_i = 1 .
\end{equation*}
\end{example}
\begin{remark}
The same definition of $\underline{\int_a^b} f$ and
$\overline{\int_a^b} f$
is used when $f$ is defined on a larger set $S$ such that
$[a,b] \subset S$. In that case, we use the restriction of $f$ to $[a,b]$
and we must ensure that the restriction is bounded on $[a,b]$.
\end{remark}
To compute the integral, we often take a partition $P$ and make it finer.
That is, we cut intervals in the partition into yet smaller pieces.
\begin{defn}
Let $P = \{ x_0, x_1, \ldots, x_n \}$ and
$\widetilde{P} = \{ \widetilde{x}_0, \widetilde{x}_1, \ldots,
\widetilde{x}_{\ell} \}$ be
partitions of $[a,b]$. We say $\widetilde{P}$ is a
\emph{refinement}\index{refinement of a partition} of $P$
if as sets $P \subset \widetilde{P}$.
\end{defn}
That is, $\widetilde{P}$ is a refinement of a partition if it contains all the
numbers in $P$ and perhaps some other numbers in between. For example,
$\{ 0, 0.5, 1, 2 \}$ is a partition of $[0,2]$ and
$\{ 0, 0.2, 0.5, 1, 1.5, 1.75, 2 \}$ is a refinement.
The main reason for introducing refinements is the following proposition.
\begin{prop} \label{prop:refinement}
Let $f \colon [a,b] \to \R$ be a bounded function, and let $P$
be a partition of $[a,b]$. Let $\widetilde{P}$ be a refinement of $P$.
Then
\begin{equation*}
L(P,f) \leq L(\widetilde{P},f)
\qquad \text{and} \qquad
U(\widetilde{P},f) \leq U(P,f) .
\end{equation*}
\end{prop}
\begin{proof}
The tricky part of this proof is to get the notation correct.
Let $\widetilde{P} = \{ \widetilde{x}_0, \widetilde{x}_1, \ldots,
\widetilde{x}_{\ell} \}$ be
a refinement of
$P = \{ x_0, x_1, \ldots, x_n \}$. Then
$x_0 = \widetilde{x}_0$ and
$x_n = \widetilde{x}_{\ell}$. In fact, there are integers
$k_0 < k_1 < \cdots < k_n$ such that $x_i = \widetilde{x}_{k_i}$ for
$i=0,1,2,\ldots,n$.
Let $\Delta \widetilde{x}_q \coloneqq \widetilde{x}_q - \widetilde{x}_{q-1}$ for
$q=0,1,2,\ldots,\ell$.
See \figureref{fig:refinement}.
We get
\begin{equation*}
\Delta x_i
=
x_i - x_{i-1} =
\widetilde{x}_{k_i} - \widetilde{x}_{k_{i-1}} =
\sum_{q=k_{i-1}+1}^{k_i}
\widetilde{x}_{q} - \widetilde{x}_{q-1}
=
\sum_{q=k_{i-1}+1}^{k_i} \Delta \widetilde{x}_q .
\end{equation*}
\begin{myfigureht}
\subimport*{figures/}{figrefinement.pdf_t}
\caption{Refinement of a subinterval. Notice $\Delta x_i =
\Delta \widetilde{x}_{q-2} +
\Delta \widetilde{x}_{q-1} +
\Delta \widetilde{x}_{q}$,
and also
$k_{i-1}+1 = q-2$ and
$k_{i} = q$.\label{fig:refinement}}
\end{myfigureht}
Let $m_i$ be as before and correspond to the partition $P$.
Let $\widetilde{m}_q \coloneqq \inf \bigl\{ f(x) : \widetilde{x}_{q-1} \leq x \leq
\widetilde{x}_q \bigr\}$.
Now, $m_i \leq \widetilde{m}_q$ for $k_{i-1} < q \leq k_i$. Therefore,
\begin{equation*}
m_i \Delta x_i
=
m_i \sum_{q=k_{i-1}+1}^{k_i} \Delta \widetilde{x}_q
=
\sum_{q=k_{i-1}+1}^{k_i} m_i \Delta \widetilde{x}_q
\leq
\sum_{q=k_{i-1}+1}^{k_i} \widetilde{m}_q \Delta \widetilde{x}_q .
\end{equation*}
So
\begin{equation*}
L(P,f) =
\sum_{i=1}^n m_i \Delta x_i
\leq
\sum_{i=1}^n \,
\sum_{q=k_{i-1}+1}^{k_i} \widetilde{m}_q \Delta \widetilde{x}_q
=
\sum_{q=1}^{\ell}
\widetilde{m}_q \Delta \widetilde{x}_q = L(\widetilde{P},f).
\end{equation*}
The proof of $U(\widetilde{P},f) \leq U(P,f)$ is left as an exercise.
\end{proof}
Armed with refinements we prove the following.
The key point of this next proposition is that
the lower Darboux integral is less than or equal to the upper Darboux
integral.
\begin{prop} \label{intulbound:prop}
Let $f \colon [a,b] \to \R$ be a bounded function. Let $m, M \in \R$ be
such that for all $x \in [a,b]$, we have $m \leq f(x) \leq M$. Then
\begin{equation}
\label{intulbound:eq}
m(b-a) \leq
\underline{\int_a^b} f \leq \overline{\int_a^b} f
\leq M(b-a) .
\end{equation}
\end{prop}
\begin{proof}
By \propref{sumulbound:prop}, for every partition $P$,
\begin{equation*}
m(b-a) \leq L(P,f) \leq U(P,f) \leq M(b-a).
\end{equation*}
The inequality
$m(b-a) \leq L(P,f)$ implies $m(b-a) \leq \underline{\int_a^b} f$.
The inequality
$U(P,f) \leq M(b-a)$ implies $\overline{\int_a^b} f \leq M(b-a)$.
The middle inequality in
\eqref{intulbound:eq} is the main point of the proposition.
Let $P_1, P_2$ be partitions of $[a,b]$. Define
$\widetilde{P} \coloneqq P_1 \cup P_2$.
The set $\widetilde{P}$ is a partition of $[a,b]$, which
is a refinement of $P_1$ and a refinement of $P_2$.
By \propref{prop:refinement},
$L(P_1,f) \leq L(\widetilde{P},f)$ and
$U(\widetilde{P},f) \leq U(P_2,f)$. So
\begin{equation*}
L(P_1,f) \leq L(\widetilde{P},f) \leq U(\widetilde{P},f) \leq U(P_2,f) .
\end{equation*}
In other words, for two arbitrary partitions $P_1$ and $P_2$, we have
$L(P_1,f) \leq U(P_2,f)$.
Recall \propref{infsupineq:prop}, and take the supremum and
infimum over all partitions:
\begin{multline*}
\underline{\int_a^b} f =
\sup \, \bigl\{ L(P,f) : P \text{ a partition of } [a,b] \bigr\}
\\
\leq
\inf \, \bigl\{ U(P,f) : P \text{ a partition of } [a,b] \bigr\}
=
\overline{\int_a^b} f . \qedhere
\end{multline*}
\end{proof}
\subsection{Riemann integral}
We can finally define the Riemann integral. However, the Riemann
integral is only defined on a certain class of functions, called the
Riemann integrable functions.
\begin{defn}
Let $f \colon [a,b] \to \R$ be a bounded function such that
\begin{equation*}
\underline{\int_a^b} f(x)\,dx = \overline{\int_a^b} f(x)\,dx .
\end{equation*}
Then $f$ is said to be \emph{\myindex{Riemann integrable}}.
The set of Riemann integrable functions on $[a,b]$ is denoted
by $\sR\bigl([a,b]\bigr)$.\glsadd{not:integrablefunc}
When $f \in \sR\bigl([a,b]\bigr)$, we define\glsadd{not:riemannint}
\begin{equation*}
\int_a^b f(x)\,dx \coloneqq
\underline{\int_a^b} f(x)\,dx = \overline{\int_a^b} f(x)\,dx .
\end{equation*}
As before, we often write
\begin{equation*}
\int_a^b f \coloneqq \int_a^b f(x)\,dx.
\end{equation*}
The number $\int_a^b f$ is called the \emph{\myindex{Riemann integral}}
of $f$, or sometimes simply the \emph{integral} of $f$.
\end{defn}
By definition, a Riemann integrable function is bounded.
Appealing to \propref{intulbound:prop}, we immediately obtain
the following proposition. See also \figureref{fig:integralminmax}.
\begin{prop} \label{intbound:prop}
Let $f \colon [a,b] \to \R$ be a Riemann integrable function.
Let $m, M \in \R$ be
such that $m \leq f(x) \leq M$ for all $x \in [a,b]$. Then
\begin{equation*}
m(b-a) \leq
\int_a^b f
\leq M(b-a) .
\end{equation*}
\end{prop}
\begin{myfigureht}
\includegraphics{figures/integralminmax}
\caption{The area under the curve is bounded from above by
the area of the entire rectangle, $M(b-a)$, and from below by
the area of the shaded part, $m(b-a)$.\label{fig:integralminmax}}
\end{myfigureht}
A weaker form of this proposition is often useful:
If $\abs{f(x)} \leq M$ for all $x \in [a,b]$, then
\begin{equation*}
\abs{\int_a^b f} \leq M(b-a) .
\end{equation*}
\begin{example}
We integrate constant functions using
\propref{intulbound:prop}.
If $f(x) \coloneqq c$ for some constant $c$, then we take $m = M = c$.
In inequality \eqref{intulbound:eq}
all the inequalities must be equalities.
Thus $f$ is integrable on $[a,b]$ and $\int_a^b f = c(b-a)$.
\end{example}
\begin{example}
Let $f \colon [0,2] \to \R$ be defined by
\begin{equation*}
f(x) \coloneqq
\begin{cases}
1 & \text{if } x < 1,\\
\nicefrac{1}{2} & \text{if } x = 1,\\
0 & \text{if } x > 1.
\end{cases}
\end{equation*}
We claim $f$ is Riemann integrable and $\int_0^2 f = 1$.
Proof: Let $0 < \epsilon < 1$ be arbitrary.
Let $P \coloneqq \{0, 1-\epsilon, 1+\epsilon, 2\}$ be a partition. We use the notation from
the definition of the Darboux sums. Then
\begin{align*}
m_1 &= \inf \bigl\{ f(x) : x \in [0,1-\epsilon] \bigr\} = 1 , &
M_1 &= \sup \bigl\{ f(x) : x \in [0,1-\epsilon] \bigr\} = 1 , \\
m_2 &= \inf \bigl\{ f(x) : x \in [1-\epsilon,1+\epsilon] \bigr\} = 0 , &
M_2 &= \sup \bigl\{ f(x) : x \in [1-\epsilon,1+\epsilon] \bigr\} = 1 , \\
m_3 &= \inf \bigl\{ f(x) : x \in [1+\epsilon,2] \bigr\} = 0 , &
M_3 &= \sup \bigl\{ f(x) : x \in [1+\epsilon,2] \bigr\} = 0 .
\end{align*}
Furthermore, $\Delta x_1 = 1-\epsilon$, $\Delta x_2 = 2\epsilon$, and
$\Delta x_3 = 1-\epsilon$.
See \figureref{darbouxfigstep}.
\begin{myfigureht}
\includegraphics{figures/darbouxfigstep}
\caption{Darboux sums for the step function. $L(P,f)$ is the area of the
shaded rectangle, $U(P,f)$ is the area of both rectangles, and
$U(P,f)-L(P,f)$ is the area of the unshaded rectangle.\label{darbouxfigstep}}
\end{myfigureht}
We compute
\begin{align*}
& L(P,f) = \sum_{i=1}^3 m_i \Delta x_i =
1 \cdot (1-\epsilon) + 0 \cdot 2\epsilon + 0 \cdot (1-\epsilon)
= 1-\epsilon , \\
& U(P,f) = \sum_{i=1}^3 M_i \Delta x_i =
1 \cdot (1-\epsilon) + 1 \cdot 2\epsilon + 0 \cdot (1-\epsilon)
= 1+\epsilon .
\end{align*}
Thus,
\begin{equation*}
\overline{\int_0^2} f -
\underline{\int_0^2} f
\leq
U(P,f) - L(P,f)
=
(1+\epsilon)
- (1-\epsilon) = 2 \epsilon .
\end{equation*}
By \propref{intulbound:prop}, $\underline{\int_0^2} f \leq \overline{\int_0^2} f$.
As $\epsilon$ was arbitrary,
$\overline{\int_0^2} f = \underline{\int_0^2} f$. So $f$ is Riemann
integrable. Finally,
\begin{equation*}
1-\epsilon = L(P,f) \leq \int_0^2 f \leq U(P,f) =
1+\epsilon.
\end{equation*}
Hence, $\bigl\lvert \int_0^2 f - 1 \bigr\rvert \leq \epsilon$. As $\epsilon$ was arbitrary,
we conclude $\int_0^2 f = 1$.
\end{example}
It may be worthwhile to extract part of the technique of the example into a
proposition. Note that $U(P,f)-L(P,f)$ is exactly the total area of the white
part of the rectangles in \figureref{darbouxfig}.
\begin{prop}
Let $f \colon [a,b] \to \R$ be a bounded function. Then $f$ is Riemann
integrable if for every $\epsilon > 0$, there exists a partition $P$ of
$[a,b]$ such that
\begin{equation*}
U(P,f) - L(P,f) < \epsilon .
\end{equation*}
\end{prop}
\begin{proof}
If for every $\epsilon > 0$ such a $P$ exists, then
\begin{equation*}
0 \leq
\overline{\int_a^b} f -
\underline{\int_a^b} f
\leq
U(P,f) - L(P,f) < \epsilon .
\end{equation*}
Therefore,
$\overline{\int_a^b} f = \underline{\int_a^b} f$, and $f$ is integrable.
\end{proof}
\begin{example}
Let us show $\frac{1}{1+x}$ is integrable on $[0,b]$ for all $b > 0$.
We will see later that continuous functions are integrable, but let us
demonstrate how we do it directly.
Let $\epsilon > 0$ be given. Take $n \in \N$ and
let $x_i \coloneqq \nicefrac{ib}{n}$ form the
partition $P \coloneqq \{ x_0,x_1,\ldots,x_n \}$ of $[0,b]$.
Then $\Delta x_i = \nicefrac{b}{n}$ for all $i$.
As $f$ is decreasing, for every subinterval $[x_{i-1},x_i]$,
\begin{equation*}
m_i = \inf \left\{ \frac{1}{1+x} : x \in [x_{i-1},x_i] \right\} = \frac{1}{1+x_i} ,
\quad
M_i = \sup \left\{ \frac{1}{1+x} : x \in [x_{i-1},x_i] \right\} =
\frac{1}{1+x_{i-1}} .
\end{equation*}
Then
\begin{multline*}
U(P,f)-L(P,f)
=
\sum_{i=1}^n
\Delta x_i
(M_i-m_i)
=
\frac{b}{n}
\sum_{i=1}^n
\left( \frac{1}{1+\nicefrac{(i-1)b}{n}} - \frac{1}{1+\nicefrac{ib}{n}} \right)
=
\\
=
\frac{b}{n}
\left( \frac{1}{1+\nicefrac{0b}{n}} - \frac{1}{1+\nicefrac{nb}{n}} \right)
=
\frac{b^2}{n(b+1)} .
\end{multline*}
The sum telescopes, the terms successively cancel each other, something
we have seen before.
Picking $n$ to be such that
$\frac{b^2}{n(b+1)} < \epsilon$, the proposition is satisfied, and the
function is integrable.
\end{example}
\begin{remark}
A way of thinking of the integral is that it adds up (integrates) lots of
local information---it sums $f(x)\,dx$ over all $x$.
The integral sign was chosen by Leibniz to be the long S to mean summation.
Unlike derivatives, which are \myquote{local,}
integrals show up in applications when
one wants a \myquote{global} answer: total distance travelled, average
temperature, total charge, etc.
\end{remark}
\subsection{More notation}
When $f \colon S \to \R$ is defined on a larger set $S$ and
$[a,b] \subset S$,
we say $f$ is Riemann integrable on $[a,b]$ if the restriction of $f$
to $[a,b]$ is Riemann integrable.
In this case,
we say $f \in \sR\bigl([a,b]\bigr)$,
and
we write $\int_a^b f$ to mean the Riemann integral
of the restriction of $f$ to $[a,b]$.
It is useful to define the integral $\int_a^b f$ even if
$a \not< b$. Suppose $b < a$ and $f \in \sR\bigl([b,a]\bigr)$,
then define
\begin{equation*}
\int_a^b f \coloneqq - \int_b^a f .
\end{equation*}
For any function $f$, define
\begin{equation*}
\int_a^a f \coloneqq 0 .
\end{equation*}
At times, the variable $x$ may already have some other meaning. When
we need to write down the variable of integration, we may simply
use a different letter. For example,
\begin{equation*}
\int_a^b f(s)\,ds \coloneqq \int_a^b f(x)\,dx .
\end{equation*}
\subsection{Exercises}
\begin{exercise}
Define $f \colon [0,1] \to \R$ by $f(x) \coloneqq x^3$
and let $P \coloneqq \{ 0, 0.1, 0.4, 1 \}$. Compute $L(P,f)$ and $U(P,f)$.
\end{exercise}
\begin{exercise}
Let $f \colon [0,1] \to \R$ be defined by $f(x) \coloneqq x$.
Show that $f \in \sR\bigl([0,1]\bigr)$ and
compute $\int_0^1 f$ using the definition of the integral
(but
feel free to use the propositions of this section).%\propref{intulbound:prop}).
\end{exercise}
\begin{exercise}
Let $f \colon [a,b] \to \R$ be a bounded function.
Suppose there exists a sequence of partitions $\{ P_k \}_{k=1}^\infty$ of $[a,b]$
such that
\begin{equation*}
\lim_{k \to \infty} \bigl( U(P_k,f) - L(P_k,f) \bigr) = 0 .
\end{equation*}
Show that $f$ is Riemann integrable and that
\begin{equation*}
\int_a^b f =
\lim_{k \to \infty} U(P_k,f)
=
\lim_{k \to \infty} L(P_k,f) .
\end{equation*}
\end{exercise}
\begin{exercise}
Finish the proof of \propref{prop:refinement}.
\end{exercise}
\begin{exercise}
Suppose $f \colon [-1,1] \to \R$ is defined as
\begin{equation*}
f(x) \coloneqq
\begin{cases}
1 & \text{if } x > 0, \\
0 & \text{if } x \leq 0.
\end{cases}
\end{equation*}
Prove that $f \in \sR\bigl([-1,1]\bigr)$ and
compute $\int_{-1}^1 f$ using the definition of the integral
(but
feel free to use the propositions of this section).
%(feel free to use \propref{intulbound:prop}).
\end{exercise}
\begin{exercise}
Let $c \in (a,b)$ and let $d \in \R$.
Define $f \colon [a,b] \to \R$ as
\begin{equation*}
f(x) \coloneqq
\begin{cases}
d & \text{if } x = c, \\
0 & \text{if } x \not= c.
\end{cases}
\end{equation*}
Prove that $f \in \sR\bigl([a,b]\bigr)$ and
compute
$\int_a^b f$ using the definition of the integral
%(feel free to use \propref{intulbound:prop}).
(but
feel free to use the propositions of this section).
\end{exercise}
\begin{exercise} \label{exercise:taggedpartition}
Suppose $f \colon [a,b] \to \R$ is Riemann integrable. Let $\epsilon
> 0$ be given. Then show that there exists a partition $P = \{ x_0, x_1,
\ldots, x_n \}$
such that for every
set of numbers $\{ c_1, c_2, \ldots, c_n \}$ with
$c_k \in [x_{k-1},x_k]$ for all $k$, we have
\begin{equation*}
\abs{\int_a^b f - \sum_{k=1}^n f(c_k) \Delta x_k} < \epsilon .
\end{equation*}
\end{exercise}
\begin{exercise}
Let $f \colon [a,b] \to \R$ be a Riemann integrable function.
Let $\alpha > 0$ and $\beta \in \R$.
Then define $g(x) \coloneqq f(\alpha x + \beta)$ on the interval
$I = [\frac{a-\beta}{\alpha}, \frac{b-\beta}{\alpha}]$. Show
that $g$ is Riemann integrable on $I$.
\end{exercise}
\begin{exercise}
Suppose $f \colon [0,1] \to \R$ and $g \colon [0,1] \to \R$
are such that for all $x \in (0,1]$,
we have $f(x) = g(x)$. Suppose $f$ is Riemann integrable.
Prove $g$ is Riemann integrable and $\int_{0}^1 f = \int_{0}^1 g$.
\end{exercise}
\begin{exercise}
Let $f \colon [0,1] \to \R$ be a bounded function.
Let $P_n = \{ x_0,x_1,\ldots,x_n \}$ be a uniform partition of $[0,1]$,
that is, $x_i = \nicefrac{i}{n}$. Is $\bigl\{ L(P_n,f) \bigr\}_{n=1}^\infty$
always monotone? Yes/No: Prove or find a counterexample.
\end{exercise}
\begin{exercise}[Challenging]
For a bounded function $f \colon [0,1] \to \R$, let
$R_n \coloneqq (\nicefrac{1}{n})\sum_{i=1}^n f(\nicefrac{i}{n})$ (the
uniform right-hand rule).
\begin{enumerate}[a)]
\item
If $f$ is Riemann integrable show $\int_0^1 f = \lim\limits_{n\to\infty} R_n$.
\item
Find an $f$ that is not Riemann integrable, but $\lim\limits_{n\to\infty} R_n$ exists.
\end{enumerate}
\end{exercise}
\begin{exercise}[Challenging] \label{exercise:riemannintdarboux}
Generalize the previous exercise.
Show that $f \in \sR\bigl([a,b]\bigr)$ if and only if there exists an $I \in \R$,
such that for every $\epsilon > 0$ there exists
a $\delta > 0$ such that if $P$ is a partition with $\Delta x_i < \delta$
for all $i$, then
$\abs{L(P,f) - I} < \epsilon$ and
$\abs{U(P,f) - I} < \epsilon$. If $f \in \sR\bigl([a,b]\bigr)$, then $I = \int_a^b f$.
\end{exercise}
\begin{exercise}
Using \exerciseref{exercise:riemannintdarboux} and the idea of
the proof in \exerciseref{exercise:taggedpartition}, show that
Darboux integral is the same as the standard definition
of Riemann integral, which you have most likely seen in calculus. That is,
show that
$f \in \sR\bigl([a,b]\bigr)$ if and only if there exists an $I \in \R$,
such that for every $\epsilon > 0$ there exists
a $\delta > 0$ such that if $P = \{ x_0,x_1,\ldots,x_n \}$
is a partition with $\Delta x_i < \delta$
for all $i$, then
$\abs{\sum_{i=1}^n f(c_i) \Delta x_i - I} < \epsilon$ for every set
$\{ c_1,c_2,\ldots,c_n \}$ with $c_i \in [x_{i-1},x_i]$.
If $f \in \sR\bigl([a,b]\bigr)$, then $I = \int_a^b f$.
\end{exercise}
\begin{exercise}[Challenging]
Construct functions $f$ and $g$,
where
$f \colon [0,1] \to \R$ is Riemann integrable,
$g \colon [0,1] \to [0,1]$ is one-to-one and onto,
and such that the composition $f \circ g$ is not Riemann integrable.
\end{exercise}
\begin{exercise}
Suppose that $f \colon [a,b] \to \R$ is a bounded function, and $P$ is a
partition of $[a,b]$ such that $L(P,f)=U(P,f)$. Prove that $f$ is a
constant function.
\end{exercise}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\sectionnewpage
\section{Properties of the integral}
\label{sec:rintprop}
%mbxINTROSUBSECTION
\sectionnotes{2 lectures, integrability of functions with
discontinuities can safely be skipped}
\subsection{Additivity}
Adding a bunch of things in two parts and then adding those two parts
should be the same as adding everything all at once.
The corresponding property for integrals is called the
\myindex{additive property of the integral}. First, we prove the additivity
property for the lower and upper Darboux integrals.
\begin{lemma} \label{lemma:darbouxadd}
Suppose $a < b < c$ and $f \colon [a,c] \to \R$ is a bounded function.
Then
\begin{equation*}
\underline{\int_a^c} f
=
\underline{\int_a^b} f
+
\underline{\int_b^c} f
\quad \text{and} \quad
\overline{\int_a^c} f
=
\overline{\int_a^b} f
+
\overline{\int_b^c} f .
\end{equation*}
\end{lemma}
\begin{proof}
If we have partitions $P_1 = \{ x_0,x_1,\ldots,x_k \}$
of $[a,b]$ and $P_2 = \{ x_k, x_{k+1}, \ldots, x_n \}$ of $[b,c]$,
then the set $P \coloneqq P_1 \cup P_2 = \{ x_0, x_1, \ldots, x_n \}$ is
a partition of $[a,c]$. We find
\begin{equation*}
L(P,f) =
\sum_{i=1}^n m_i \Delta x_i
=
\sum_{i=1}^k m_i \Delta x_i
+
\sum_{i=k+1}^n m_i \Delta x_i
=
L(P_1,f) + L(P_2,f) .
\end{equation*}
When we take the supremum of the right-hand side over all $P_1$ and $P_2$,
we are taking a supremum of the left-hand side
over all partitions $P$ of $[a,c]$ that contain $b$. If $Q$ is a partition
of $[a,c]$ and $P = Q \cup \{ b \}$, then $P$ is a refinement of $Q$
and so $L(Q,f) \leq L(P,f)$. Therefore, taking a supremum only over the $P$
that contain $b$ is sufficient to find the supremum of $L(P,f)$
over all partitions $P$, see \exerciseref{exercise:dominatingb}.
Finally, recall \exerciseref{exercise:supofsum}
to compute
\begin{equation*}
\begin{split}
\underline{\int_a^c} f
& =
\sup \, \bigl\{ L(P,f) : P \text{ a partition of } [a,c] \bigr\}
\\
& =
\sup \, \bigl\{ L(P,f) : P \text{ a partition of } [a,c], b \in P \bigr\}
\\
& =
\sup \, \bigl\{ L(P_1,f) + L(P_2,f) :
P_1 \text{ a partition of } [a,b], P_2 \text{ a partition of } [b,c] \bigr\}
\\
& =
\sup \, \bigl\{ L(P_1,f) : P_1 \text{ a partition of } [a,b] \bigr\}
+
\sup \, \bigl\{ L(P_2,f) : P_2 \text{ a partition of } [b,c] \bigr\}
\\
&=
\underline{\int_a^b} f + \underline{\int_b^c} f .
\end{split}
\end{equation*}
Similarly, for $P$, $P_1$, and $P_2$ as above, we obtain
\begin{equation*}
U(P,f) =
\sum_{i=1}^n M_i \Delta x_i
=
\sum_{i=1}^k M_i \Delta x_i
+
\sum_{i=k+1}^n M_i \Delta x_i
=
U(P_1,f) + U(P_2,f) .
\end{equation*}
We wish to take the infimum on the right
over all $P_1$ and $P_2$, and so we are taking the infimum
over all partitions $P$ of $[a,c]$ that contain $b$. If $Q$ is a partition
of $[a,c]$ and $P = Q \cup \{ b \}$, then $P$ is a refinement of $Q$
and so $U(Q,f) \geq U(P,f)$. Therefore, taking an infimum only over the $P$
that contain $b$ is sufficient to find the infimum of $U(P,f)$ for
all $P$.
We obtain
\begin{equation*}
\overline{\int_a^c} f
=
\overline{\int_a^b} f + \overline{\int_b^c} f . \qedhere
\end{equation*}
\end{proof}
\begin{prop}
Let $a < b < c$. A function $f \colon [a,c] \to \R$ is Riemann integrable
if and only if $f$ is Riemann integrable on $[a,b]$ and $[b,c]$. If
$f$ is Riemann integrable, then
\begin{equation*}
\int_a^c f
=
\int_a^b f
+
\int_b^c f .
\end{equation*}
\end{prop}
\begin{proof}
Suppose $f \in \sR\bigl([a,c]\bigr)$, then it is bounded and
$\overline{\int_a^c} f =
\underline{\int_a^c} f =
\int_a^c f$. The lemma gives
\begin{equation*}
\int_a^c f
=
\underline{\int_a^c} f
=
\underline{\int_a^b} f + \underline{\int_b^c} f
\leq
\overline{\int_a^b} f + \overline{\int_b^c} f
=
\overline{\int_a^c} f
=
\int_a^c f .
\end{equation*}
Thus the inequality is an equality,
\begin{equation*}
\underline{\int_a^b} f + \underline{\int_b^c} f
=
\overline{\int_a^b} f + \overline{\int_b^c} f .
\end{equation*}
As we also know
$\underline{\int_a^b} f \leq \overline{\int_a^b} f$
and
$\underline{\int_b^c} f \leq \overline{\int_b^c} f$, we
conclude
\begin{equation*}
\underline{\int_a^b} f
=
\overline{\int_a^b} f
\qquad \text{and} \qquad
\underline{\int_b^c} f
=
\overline{\int_b^c} f .
\end{equation*}
Thus $f$ is Riemann integrable on $[a,b]$ and $[b,c]$ and the desired formula
holds.
Now assume $f$ is Riemann integrable on $[a,b]$ and on $[b,c]$.
Again it is bounded, and the lemma gives
\begin{equation*}
\underline{\int_a^c} f
=
\underline{\int_a^b} f + \underline{\int_b^c} f
=
\int_a^b f + \int_b^c f
=
\overline{\int_a^b} f + \overline{\int_b^c} f
=
\overline{\int_a^c} f .
\end{equation*}
Therefore, $f$ is Riemann integrable on $[a,c]$, and the integral is computed
as indicated.
\end{proof}
An easy consequence of the additivity is the following corollary. We
leave the details to the reader as an exercise.
\begin{cor} \label{intsubcor}
If $f \in \sR\bigl([a,b]\bigr)$ and
$[c,d] \subset [a,b]$, then
the restriction $f|_{[c,d]}$ is in $\sR\bigl([c,d]\bigr)$.
\end{cor}
\subsection{Linearity and monotonicity}
A sum is a linear function of the summands. So is the integral.
\begin{prop}[Linearity]
\index{linearity of the integral}\label{prop:integrallinear}
Let $f$ and $g$ be in $\sR\bigl([a,b]\bigr)$ and $\alpha \in \R$.
\begin{enumerate}[(i)]
\item $\alpha f$ is in $\sR\bigl([a,b]\bigr)$ and
\begin{equation*}
\int_a^b \alpha f(x) \,dx = \alpha \int_a^b f(x) \,dx .
\end{equation*}
\item $f+g$ is in $\sR\bigl([a,b]\bigr)$ and
\begin{equation*}
\int_a^b \bigl( f(x)+g(x) \bigr) \,dx =
\int_a^b f(x) \,dx
+
\int_a^b g(x) \,dx .
\end{equation*}
\end{enumerate}
\end{prop}
\begin{proof}
\pagebreak[2]
Let us prove the first item for $\alpha \geq 0$.
Let $P$ be a partition of $[a,b]$, and
$m_i \coloneqq \inf \bigl\{ f(x) : x \in [x_{i-1},x_i] \bigr\}$ as usual.
As $\alpha \geq 0$, the multiplication by $\alpha$ moves
past the infimum,
\begin{equation*}
\inf \bigl\{ \alpha f(x) : x \in [x_{i-1},x_i] \bigr\}
=
\alpha \inf \bigl\{ f(x) : x \in [x_{i-1},x_i] \bigr\} = \alpha m_i .
\end{equation*}
Therefore,
\begin{equation*}
L(P,\alpha f) =
\sum_{i=1}^n \alpha m_i \Delta x_i = \alpha \sum_{i=1}^n m_i \Delta x_i = \alpha
L(P,f).
\end{equation*}
Similarly,
\begin{equation*}
U(P,\alpha f) = \alpha U(P,f) .
\end{equation*}
Again, as $\alpha \geq 0$, we
may move multiplication by $\alpha$ past the supremum. Hence,
\begin{equation*}
\begin{split}
\underline{\int_a^b} \alpha f(x)\,dx & =
\sup \, \bigl\{ L(P,\alpha f) : P \text{ a partition of } [a,b] \bigr\}
\\
& =
\sup \, \bigl\{ \alpha L(P,f) : P \text{ a partition of } [a,b] \bigr\}
\\
& =
\alpha \,
\sup \, \bigl\{ L(P,f) : P \text{ a partition of } [a,b] \bigr\}
\\
& =
\alpha
\underline{\int_a^b} f(x)\,dx .
\end{split}
\end{equation*}
Similarly, we show
\begin{equation*}
\overline{\int_a^b} \alpha f(x)\,dx
=
\alpha
\overline{\int_a^b} f(x)\,dx .
\end{equation*}
The conclusion now follows for $\alpha \geq 0$.
To finish the proof of the first item (for $\alpha < 0$), we need to show
that $-f$ is Riemann integrable and
$\int_a^b - f(x)\,dx =
-
\int_a^b f(x)\,dx$. The proof of this fact is left as
\exerciseref{exercise:proofoflinpropparti}.
The proof of the second item is left as
\exerciseref{exercise:proofoflinproppartii}.
It is not difficult, but it is not as
trivial as it may appear at first glance.
\end{proof}
The second item in the proposition does not hold with
equality for the Darboux integrals, but we do obtain inequalities.
The proof of the following proposition is \exerciseref{exercise:upperlowerlinineq}.
It follows for upper and lower sums on a fixed partition by \exerciseref{exercise:sumofsup},
that is, supremum of a sum is less than or equal to the sum of
suprema and similarly for infima.
\begin{prop} \label{prop:upperlowerlinineq}
Let $f \colon [a,b] \to \R$ and $g \colon [a,b] \to \R$ be bounded
functions. Then
\begin{equation*}
%\overline{\int_a^b} \bigl(f(x)+g(x)\bigr)\,dx \leq
%\overline{\int_a^b}f(x)\,dx+\overline{\int_a^b}g(x)\,dx
\overline{\int_a^b} (f+g) \leq \overline{\int_a^b}f+\overline{\int_a^b}g
,
\qquad
\text{and}
\qquad
\underline{\int_a^b} (f+g) \geq \underline{\int_a^b}f+\underline{\int_a^b}g
%\underline{\int_a^b} \bigl(f(x)+g(x)\bigr)\,dx \geq
%\underline{\int_a^b}f(x)\,dx+\underline{\int_a^b}g(x)\,dx
.
\end{equation*}