You are on page 1of 322
A PRIMER OF REAL FUNCTIONS RALPH P BOAS, JR. ; FOURTH EDITION * REVISED AND UPDATED ~ BY HAROLD P BOAS fore 32 3 % 4s, Hono” Fame The Carus Mathematical Monographs A “The Carus Mathematical Monographs are an expression of the desire of Mrs. Mary Hegeler Carus and of her Son, Dr. Edward H. Cars, to contribute to the disemiration of mathematical knowledge by making acoessble a series of expository presenta- tions of the best thoughts and keenest researches in pure and applied mathematics. ‘The publication of the fist four of these monographs was made possible by Mrs. Carus as sole trustee of the Edward C. Hegeler Trust Fund The sales from these have resulted in the Carus Monograph Fund, and the Mathematical Association of Aseria has used this as a revolving book fund to publish the succeeding monographs. ‘The expositions of mathematical subjects thatthe monographs contain are st forth in 4 manner comprehensible not only to teach- es and students specializing in mathematics, but also to scientific workers i other fields. More generally, the monographs are intend- co forthe wide circle of thoughtful people familiar with basic graduate or advanced undergraduate mathematics, encountered in the sudy of mathematics itself or inthe con text of related disciplines, who wish to ‘extend their knowedge without prolonged ‘and cttcal study of the mathematical jour nals and treatises. A PRIMER OF REAL FUNCTIONS Fourth ston ©1986 ty The Mathematical Associaton of Amerie, Ie Litvary of Congress Munber 9677785, ISBN 0-68585.029-x ISBN O-88385 000-1 (Complete Se) Printed in the United Stes of America Curent ining st ig: woe 7654321 The Carus Mathematical Monographs NUMBER THIRTEEN A PRIMER OF REAL FUNCTIONS RALPH P. BOAS revised and updated by HAROLD P. BOAS ‘THE CARUS MATHEMATICAL MONOGRAPHS Published by ‘THE MATHEMATICAL ASSOCIATION OF AMERICA Committee on Publications JAMES W, DANIEL, Chair Carus Mathematical Monographs Editorial Board MARIORIE L. SENECHAL, Ealitor KATALIN A. BENCSATH ROBERT BURCKEL GIULIANA P. DAVIDOFF JOSEPH A. GALLIAN ‘The following monographs have been published: Coleus of Vraions. by GA. Biss (ut of pri) Ana Functions of «Comper Variable, by D. R. Criss (ot of rin ‘Mathematical taistis,by HL. Rie (ut of print) 4. Projctive Geometry by J. W. Young (out of prit) 4 History of Mathematics in Ameria before 1800, by. . Sith and “euthielGinsbrg (out of pit) Fourier Series and Orthogonal Pobnomiat, by Danksm Jeckaon (ot ot pein) tors and Matrices, by C.C. MacDutee out fit) ‘Rings ond Ideal. by N. H. McCoy (ou of pit The Theory of Algebraic Number, second etn, by Har Pll and Haro G. Diamond The Arihmaic Theory of Quadratic Forms, by B. W. Sones (out of in) “rational Numbers, by Ian Niven ‘Statistical Independence ix Probably, Ans and Number Theory, by Mask Kee A Primer of Real Functions, fur etn, by Ralph. Boas, evsed ‘nd updated by Harold P. Boas Combinatorial Mathematics, by Herbert 3. Ryser . Noncommutative Rigs by LN. Hesein (ut of prin) Deseind Sums, by Hans Rademacher and Eni Grossvald The Schware Function and its Aplications, by Philp J Devis Cetesil Mechanics. by Bary Pola Field Theory and its Clasico! Problems, by Cares Robert Hadick ‘The Generalize Riemann Inegral, by Robert M. MeLend From Error-Corecing Codes trough Spare Pacing o Simple Groups by Thomas M. Thompson ‘Random Woks and Elecric Newer, by Peer G. Doyle and J Laure Seal Complex Anassis: The Geomedie Vewpont,by Steven. Krantz ‘Knot Theory by Charles Livingston Algebra and Tiling: Homomorphons inthe Sere of Geometry, by ‘Sheman Stein and Sindr Sab MAA Service Caer PO. Box 91112 Washingon, DC 20080-1112 {00-33-IMAA FAX: |-301-2069789 Preface to the Fourth Edition ‘This book is an heirloom and a memorisl. The first tion, dedicated “To My Epsilons,” appeared in the year that I (the youngest of my father’s “little ones") turned six years old. Now, many years later, my siblings being of ‘a nonmathematical bent, the familial interest in the book resides in me. The most fitting tribute I can pay to my father's memory is to pass on a new edition of this mono- graph to the next generation of epsilons. ‘The principal change in this edition is the addition of a ‘chapter on integration and some of its applications. ‘This topic was deliberately omitted from previous editions, “re- Iuctantly, because of the many technical details that are needed before one gets to the interesting results.” My fa- ther eventually decided that it would be acceptable and enjoyable to present some of the interesting results with- out all the technical details, on the principle that one need not understand the inner workings of the motor to appre- ciate a drive in the country. Chapter 3 is my reworking of ‘a draft that my father left at his death. Besides revising ‘this material, I have added most of the notes, exercises, vill PREFACE TO THE FOURTH EDITION and solutions for Chapter 3. Resetting the book in BTEX afforded the opportunity to renumber the exercises and to relocate the notes from the end of the volume to the ends of individual sections. have also made minor revisions throughout Chapters 1 and 2. T thank Robert B. Burckel for reading the manuscript with great care and for suggesting many improvements, Harold P. Boas ‘Texas ALM University uly 1995 Preface to the Third Edition 1. To the beginner. In this little book I have presented some of the concepts and methods of “real variables" and used them to obtain some interesting results. I have not sought great generality or great completeness. My idea is to go reasonably far in a few directions with a minimum, amount of special terminology. I hope that in this way I hhave been able to preserve some of the sense of wonder that was associated with the subject in its early days but, has now largely been lost. I hope also that someone who hhas read this book will be able to go on to one of the many more forbidding systematic treatises. of which there is no lack. No previous knowledge of the subject is assumed, but the reader should have had at least a course in calculus. In general, each topic is developed slowly but rises to a moderately high peak; a reader who finds the slope too steep may skip to the beginning of the next section. Since this is not a handbook, but more in the nature of a course of informal lectures, I have not been at all consistent either about the proportion of detailed proof to x PREFACE TO THE THIRD EDITION general discussion or about strict logical arrangement of material All phrase ike “tis clea,” “plainly,” “itis trivial” are intended as abbreviations for a statement something like “Tt should seem reasonable, you should be able to supply the proof, and you are invited to do so." On the other hand, “It can be shown ... ” is usually to suggest that the proof is too complicated to give here, or depends on notions that are not discussed here, and that you are not expected to try to supply the proof yourself In stating definitions, T have frequently used “if” where 1 should really have used “if and only i" For example, “If ‘set is both bounded above and bounded below its called lounded” ‘This definition is to be understood to earry an additional clause, “and itis not both bounded above and bounded below, i is not called bounded,” ‘There are a number of exercises, some of which merely supply illustrative material, and some of which are exer tial parts of the book. “An exercise that merely states a proposition isto be interpreted as a demand fora proof of the propesition. Answers to all exercises are given at the end of the book. Paragraphs in small type deal ether with peripheral raterial or with more dificult questions. apologize in advance for whatever mistakes the alert, reader may be able to detect. None were intentionally in- cluded; nevertheless, the detection and rectification of mis- takes is a good exercise, and fosters a healthy skepticism about the printed word. Tl. To the expert. Experts are not supposed to read this book at all; since this statement will doubtless be taken as an invitation for them to do so, I must explain PREFACE TO THE THIRD EDITION xi what I have tried (and not tried) to do. I have set out to tell readers with no previous experience of the subject some of the results that I find particularly interesting. 1 hhave therefore tried to present the material that: seemed ‘essential for the results I had in mind, together with as ‘much related material as seemed interesting and not too complicated. Since this is not a systematic treatise, I have deliberately tried not to introduce any concepts or nota- tions, however significant or convenient, that I did not re- ally need to use. I have omitted integration, reluctantly, because of the many technical details that are needed be- fore one gets to the interesting results. Since this is not a treatise it has not been written like one. The style is deliberately wordy. The axiom of choice is frequently used but never mentioned; this book is not the place to discuss philosophical questions, and, in any case, after Gédel’s results, the assumption of the axiom of ‘choice can do no mathematical harm that has not already been done. On the other hand, according to the more re- cent work of P. J. Cohen, by assuming the axiom of choice rather than its negative we are selecting one kind of math- cematics rather than another, say Zermelonian rather then non-Zermelonian, With this selection, there is no point in avoiding the axiom of choice whenever it seems natural to use it, even in cases where itis known to be avoidable. TIL. Acknowledgments. I am indebted to my teach- ‘ers, J. L. Walsh and D. V. Widder, for introducing me to this kind of mathematics; to M. L. Boas and to E. F. and R. C. Buck for criticizing early drafts of the book; and to H. M. Clark and H. M. Gehman for help with the proofreading. I am grateful to several people who have xii PREFACE TO THE THIRD EDITION pointed out oversights or suggested improvements, and es- pecially to Richard L. Baker, E. M. Beesley, H. P. Boas, A.M. Bruckner, G. T. Cargo, 8. Haber, A. P. Morse, C. C. Ochting, J. M. H. Olmsted, J. C. Oxtoby, A. C. Se ‘gal, A. Shuchat, and H. A. Thurston In preparing this revision, I have tried to resist the temptation to insert additional material; but a consider able number of references have been added to the notes. Ralph P. Boas, Jr Northwestern University ‘March 1960 June 1965 March 1972 October 1979 Contents Preface to the Fourth Edition Preface to the Third Edition 1 Sets Seis... eee Sets of real numbers Countable and uncountable sets . Metric spaces... 2. . Open and closed sets... . ‘Dense and nowhere dense sets . ‘Compactness : ‘Convergence and completeness . . Nested sets and Baire’s theorem Sets of measure zero . 2 Functions 12 Functions . 13. Continuous functions 14 Properties of continuous functions 15 Upper and lower limits... . xiii Some applications of Baire's Theorem . . . 16 Sequences of functions . 17 Uniform convergence . . . - 18 Pointorise limits of continuous functions 19 Approximations to continuous functions 20 Linear functions. 21 Derivatives 2... 2 Monotonic functions 28 Convex functions . - - . 24 Infinitely differentiable functions... 3 Integration 25 Lebesgue measure. 26 Measurable functions . : 27 Definition of the Lebesgue integral 28 Properties of Lebesgue integrals . 29 Applications of the Lebesgue integral 30 Stielzjes integrals 31 Applications of the Stieltjes integral 32 Partial sums of infinite series . . Answers to Exercises Index Chapter 1 Sets 1. Sets. Inorder to read anything about our subject, you will have to learn the language that is used in it. I have ttied to keep the number of technical terms as small as possible, but there is certain minimum vocabulary that is essential. Much of it consists of ordinary words used in special senses; this practice has both advantages and disedvantages, but has in any case to be endured since it is now too late to change the language completely. Much of the standard language is taken from the theory of set, a subject with which we are not concemed for its own sake. The theory of sets is, indeed, an independent branch of mathematics. Tt has its own basic undefined concepts, subject to various axioms; one of these undefined concepts is the notion of “set” itself. From an intuitive point of view, however, we may think ofa set as being a collection of objects of some kind, called its elements, or members, or points. We say that a set contains its elements, or thatthe elements belong tothe set for simply are in the set. ‘The normal usage of se, asin “a 1 2 sers Chap. 1 ‘set of dishes” or “a set of the works of Bourbali,” is fairly ‘lose to what we should have in mind, although the second phrase suggests some sort of arrangement of the elements ‘which is irrelevant to the mathematical concept. Sets may, for example, consist of ordinary geometrical points, or of functions, or indeed of other sets. We shall use the words class, aggregate, and collection interchangeably with set, especially to make complicated situations clearer: thus we ‘may speak of a collection of aggregates of sets rather than a.set of sets of sets, If Bis a set,’ a set H is called a subset of E if every clement of H is also an element of E. For example, if E is the set whose elements are the numbers 1, 2, and 3, then there are eight subsets of B. Three of them contain one clement each; three contain two elements each; one is the ‘et E itself (a subset does not have to be, in any sense, “smaller” than the original set); the eighth subset of E is, by convention, the empty set, which is the set that has no elements at all. If H is a subset of B, we write HC E or E > H; sometimes we say that E contains H or that, E covers H. If H is a subset of E but is not all of , we call Ha proper subset of E. We write x € E to mean that 2 is an element of E. We often say that 2 is in E, or that x belongs to E, or that, E contains x, meaning the same thing. Since the elements of sets are usually things of a different kind from the sets themselves, we should distinguish between the element 2 ‘and the set whose only element is x. It is often convenient to denote the latter set by {2}. The notations x € E and {2} CE mean the same thing. ‘A space is a set that is being thought of as a universe “Weis ereditonal co call sets for “et” ie “encemble.” presumably because the French See. 1 sers 3 from which sets can be extracted. If is a space and E CO, then the complement of E (with respect to ) is the set consisting ofall the elements of © that are not clements of E. The complement of F is denoted by C(E). For example, if © consists of the letters of the alphabet ‘and E of the consonants (including y as a consonant), then C(E) consists ofthe vowels. If, however! E consists of the single letter a, then C(E) consists ofthe letters bc...» 52 If E consists of the entire alphabet, then C(E) is empty. IF B is empty, then C(E) =. Exercise 1-1. Show that C(C(E)) = E. If B and F are two sets, there are two other sets that can be formed by using them, and that occur so frequently that they have special names. One of these sets is the union of the two sets, written EU F (sometimes called their sum, and written B+ F); it consists ofall elements that are in E or in F (or in both; an element that isin both is counted only once). ‘The other is the intersection of the two sets, written EN F (sometimes called their product, and written EF or EF); it consists ofall elements that are in both E and F. If EMF is empty, then B and F are called disjoint; that is, E and F are disjoint if they have no element in common. Exercise 1.2. Let 10 consist of the 26 letters of the alphabet Let E consist of all the consonants (Including y), and F of all the letters that occur in the words real functions (the n is ‘counted only once). Show that (a) EU F = 9; (b) F > C(E); (©) CLF) CE; (8) FE and C(B) ave disjoint. TFor dimplciy of wotation we frequently use, as here, a letter has just been used asthe name of a st, that we are now through with, to denote different st. 4 sens Chap. 1 ‘There are various logical difficulties inherent in the unerit- cal use of the terminclogy of the theory of sets, and they have sven rise to 2 great deal of discussion. Fortunately, however, they arise only at a higher level of abstraction than we shall attain in the rest of this book, and in contexts that we should consider rather artificial, so that we may safely ignore ther hereafter. Some forms of words which appear to define sets may not actually do s0, somewhat as some combinations of letters which might well represent English words (for instance, ‘irong”) do not actually do so. For example, although we can safely speak of sets whose elements are sets, we cannot safely talk about the set of all sets whatsoever. Supposing that we could, the set ofall sets would necessarily have itself as one of its elements. ‘This is a peculiar property, although there are other ostensible sets that have it, for example, the set ofall ob- jects definable in fewer than thirteen words (since this “set” is itself defined in fewer than thirteen words). We might well de- ‘ide to exclude from consideration those sets that are elements of themselves. The remaining sets do not have themselves a8 clements; form the aggregate A ofall such acceptable sets. Now is A one of the sets that we accept, or one of the sets that we exclude? If we accept A, it does not have itself as an element ‘and so must be included in the aggregate of all sets with this property; that is, A belongs to A, and therefore we do not ac cept A. On the other hand, if we do not accept A, then A is fan element of itself then since all elements of A are eete that are not elements of themselves, and c0 are acceptable, we must ceept A. Thus if A ie a set at all, we are involved in a logical ‘contradiction. ‘The only way out sooms to be to declare that the words that seem to define A do not actually define a set. Another paradoxical property of “the set of all sets” will ‘turn up in §3. Exercise 1.3. A Ubrarian proposes to compile a bibliography listing those, and only these, bibliographies that do not list themselves, Comment on this proposal. See. 2 SETS OF REAL NUMBERS 5 2. Sets of real numbers. Since we have to start some- where, T assume that you are familiar with the system of, real numbers, T will take completely for granted its alge- braic properties—those connected with addition, subtrec- tion, multiplication, and division, and with inequalities. However, there is one property of the real mumbers that is less familiar to most people, even though it underlies concepts, such as limit and convergence, that are funda- ‘mental in calculus. This property ean be stated in many ‘equivalent forms, and the particular one thet we selec is 4 matter of taste. I shall take as fundamental the so-called Least upper bound property. Before we can state what this property is, we need some more terminology. Let E be a nonempty set of real numbers, We say that E is bounded above if there is a number M such that every 2 in E satisfies the inequality, 2 A. ‘The supremum of E may or may not belong to E. In the example just given, it does not. However, if we change the example so that B consists of all numbers not grester than 2, the supremum of F is stil 2, and now it belongs to E. So far, although we have talked about the supremum of aset, we have not known (except in our illustrative ex- 6 sers Chap. 1 amples) whether there is any such thing. The least upper bound property, which we take as one ofthe axioms about real numbers, Is just that every nonempty set E that is bounded above does in fact have a supremum. In other words, if we form the collection of all upper bounds of E, {is collection has a smallest element (hence the name) We denote the supremum of E by sup or SuP,ee ‘When sup E belongs to E, we sometimes write mas in stead, Thus max B is the largest element of B if B has a largest element. The greatest lower bound, or infimum, of E, denoted by inf E, and the minimum min B, are de- fined similarly. (See Exercise 2.2.) ‘An interval is a set consisting ofall the real numbers between two given numbers, or of all the real numbers on. one side or the other of a given number. More precisely, fan interval consists ofall real numbers x that satisfy an inequality of one of the forms.aa,r2>0, © and a parenthesis to suggest < or >, we shall often ‘tse the following notations for the corresponding interval: (6,8), {0B}, (28s 8}, (0500) [a, 00), (~20,0); (—c0,2) ‘Thus (0,1) means the set of all real numbers such that 0 <2 <1. (The use of the symbol oo in the notation for intervals is simply 2 matter of convenience and is not to be taken as uggesting that there isa number oo.) Exercise 2.1. For each of the sets B indicated below, descibe the set ofall upper bounds, the set of al lower bounds, sup, and inf E. (6) B isthe interval (0,1). (b) B isthe interval (0,1). (6) Bis the itera (0,1 (@) Eis the interval (0,1) See. 2 SETS OF REAL NUMBERS 7 (c) B consists of the numbers 1, $, $$). (8) Bits the set containing the single point 0. (8) B= (n+ (-1 :n=1,2,...) (h) B= {n+ (-1)" (nin = 1,2, (j) Eis the set of real numbers z between 0 end 1 such that sing > Exercise 2.2. Give a detailed definition of inf E, formulate a sreatest lower bound property, and prove that itis equivalent to the least upper bound property If E is not bounded above, we write sup E = +00; if Eis not bounded below, we write inf E = —oo. These are convenient abbreviations, but are not to be interpreted as implying that there are real numbers +00 and —co; there are not. We can, if we like, create such infinite numbers and adjoin them to the real number system, but for most ‘purposes it is undesirable to do so. No matter how we in- troduce infinite numbers, we are bound to make arithmetic worse than it already is: there is one impossible operation to begin with (division by zero), but if we make this oper- ation possible we render even more operations impossible. Exercise 2.8. Explore the consequences of introducing num- ‘bers +00 and —co such that 6/0 = +00 ifa > 0, and a/0 = ~00 ifa<0. Can a reasonable meaning be given to +00 + (—00)? To 0- (+00)? Ifa set is both bounded above and bounded below, itis called bounded. A bounded nonempty set F is character- ized by having inf B and sup £ both finite, or equivalently. by being contained in some finite interval (a,6).. We have supposed in our discussion of upper and lower bounds that we have been considering nonempty sets. So that we shall not have to make reservations about whether 8 sers Chap. 1 for not our sets have elements, we make the (rather pe- culiat) convention that if E is empty, then sup E = —o0 and inf E = +co. This convention allows us to say, for example, that sup(EUF) is the larger of sup E and sup F, without having to consider whether E or F may be empty. Bxercise 2.4. If E is not empty, then inf E < sup B; there is strict inequality if E contains at least two points 3. Countable and uncountable sets. If we have a set E with (say) ive elements, for instance, the fingers on a hand, we can count these elements (or, for short, count E) ‘This means exactly what: we might expect: we can point to the elements of E, one by one, naming the integers 1, 2, 8, 4, 5, successively, as we do so. In slightly more formal language, we label all the elements of E by using the inte- gers 1, 2, 3,4, 5 once each. In still more formal language, ‘we put the elements of E into one-to-one correspondence with the integers 1, 2, 8, 4 5 Tt turns out to be usefl to extend the concept of count ing to sets that have infinitely many elements. Suppose, for example, that E is now the set of all even positive inte- gers. We can no longer point to all the elements of B, one after another, naming successive integers, because E has too many elements. However, we can still imagine lIabel- ing all the elements of E with all the positive integers, so that each element of E has a different integer attached to wwe just have to label each even integer with the in- teger whose double it is, that is, we label the integer 2n with the label n. Since the even integers can be put into ~The exercise that simply makes a statement calle for a proof of ‘that statement See. 3 CCOUNTABLE AND UNCOUNTABLE SETS 9 one-to-one correspondence with all the integers in this way, ‘we may reasonably say that there are the same number of each, without, however, committing ourselves as to what the number of integers may be. Its interesting that there actually are sets that cannot be counted (as we shall soon prove), so that we can classify sets according to whether they ean be counted or not. The ‘ones that cannot be counted can be thought of as “bigger” than those that can be counted. (As we have just seen, « set is not necessarily bigger, in this sense, than one of its proper subsets.) Before establishing the existence of un- countable sets, we shall introduce some more terminology and give additional examples of sets that can be counted. ‘To count a set means to put its elements into one-to- cone correspondence with some set of consecutive postive integers starting from 1; this set is not necessarily to be a proper subset of the set of all positive intogers. If @ set can be counted we eal it countable. (The empty set is also called countable: here the relevant subset of the positive integers can be thought of, with alittle effort, os the empty set.) We can write the elements of a nonempty countable set in some such form a8 2, 22,23, .- 5 Where ‘atypical element of the set would be denoted by z and the subscripts are the consecutive integers that are used as labels in counting the set. If we start out counting ‘ countable set, either eventuslly we find a last element, or else the cour process continues indefinitely. In the first case, the set is called finite: in the second, countably infinite ‘The set ofall the postive and negative integers together is countable, since we can use the odd postive integers to label all the postive integers and the even postive integers to label all the negative integers, thus: 10 sers Chap. 1 elements... -$ -2 -1 123 lbs. 6 2S Exercise 3.1. Show similarly that the union of any two count ably infinite sets is countable ‘A tess obviously countable set is the st of atice points the plane: these are the points with both coordinates integral, for example (1,2) or (—5, 18). It is easy to see how to count them from the diagram (which, for conve- nience, shows only the lattice points in the first quadrant; ‘we can count all the lattice points by using Exercise 3.1 repeatedly). Without drawing the picture, we can think of first grouping all the lattice points (m,n) for which m-+n is 0, 1, 2,3, .., and then counting the groups, one after another. We can alternatively view the diagram as repre- senting the lattice points in the fst quadrant as the union ofa countable colletion of countable sets: the sets are the successive horizontal rows. N \ \ (0,2) (1,2) (2,2) TON \ \ (0,1) (Qy) (2,1) \ \ \ 0) = (0) ” (2.0) + Some rather more complicated sets can be discussed by using the fact that every subset of a countable set is countable. Expressed in another way, this theorem says that a set whose elements can be labeled with some of Sec. 3 COUNTABLE AND UNCOUNTABLE SETS 11 the positive integers, using each only once, can equally ‘wel be labeled with consecutive positive integers (possibly all of them). ‘To see this, observe that each element of ‘the given subset of a countable set is Inbeled with some Positive integer. Take the element with the smallest label and relabel it 1; then take the element with the smallest label from the rest of the subset (if there is any more of ‘the subset) and relabel it 2; and so on. Tt is now easy to see thatthe positive rational numbers orm a countable set. A positive rational number can be represented asa fraction p/q in lowest terms, where p and g are positive integers. If we associate the fraction 3/11 with the lattice point (8,11), and generally p/q with (p,q), we have the rational numbers in one-to-one correspondence with a subset of the lattice points, that i, witha subset of 2 countable set. Hence the postive rational numbers form a countable set. Exercise 8.2. Show that the union of ony countable collection of countable sets ie countable. Exercise 3.3. The set ofall points inside a circle is called @ disk, Let $ be a set of nonoverlapping disks in the plane—that Js, no disk in $ has a nonempty intersection with any other disk in §. Show that $ must be countable. ‘A still less obvious example is furnished by the alge- baie numbers: these are the numbers (real or complex) that can be roots of polynomials with integral coefficients (for example, all rational numbers, V2, i, 29/3-+ Y7). To see that the set of algebraic numbers is countable, we notice first that there are only countably many linear polynomials ‘with integral coefficients, countably many quadratic poly- nomials with integral coefficients, and so on. 2 sens Chap. 1 integral coef ficients have at most n roots each, thus countably many altogether. The aggregate of roots of polynomials of every degree with integral coefficients is accordingly a countable collection of countable sets, and so countable." ‘A more abstract example isthe class of all finite subsets of a given countable set. For, the class of subsets with one element each is countable, the class of subsets with two ‘elements each is countable, and so on. We again have ‘a countable collection of countable sets. (As we shall see Iter (page 16), the set of all subsets of a countably infinite set is not countable.) ‘The notion of countability can sometimes be used to show the existence of things of a particular kind. For a simple illustration, we prove that not all eal numbers are algebraic. (A number that is not algebraic is called tran- soendental.) The real algebraic numbers are, as we know, countable; our first step is to suppose that they have been counted, and represented ss decimals. It will simplify the notation somewhat, and do no harm, if we consider only real numbers between 0 and 1. Every real number between 0 and 1 has an ordinary decimal expansion, for example, .14285714285714285714 .14159265358979323846. Conversely, every such expansion defines real number between 0 and 1; if we write down, for example, 123456789101112131415... , Sec. 3 COUNTABLE AND UNCOUNTABLE ses 13 then z is certainly a real number between 0 and 1, although we cannot connect it in any simple way with more familiar numbers. ‘Now suppose that the real algebraic numbers between 0 and 1 have been counted, so that there are a first, & second, a third, and so on; call them a1, a2, a3, and so on. ‘We then have a column of decimals, which might start like this: 215367... 1652489... 061259. 300921 ‘This list is supposed to contain all the real algebraie num- bers between 0 and 1; that is, any such number will appear in the list if we go far enough. It is now eesy to construct @ decimal that does not appear anywhere in this list and so cannot be an algebraic number. For example, if we write down 0.5655, then we have the start of a decimal that differs from a in the first decimal place, from az in the second, from as in the third, and from ay in the fourth; obviously it is not going to be any of these four numbers. ‘We can go on in the same way, putting 5 in the nth deci mal place if ag has anything except 5 there, and putting 6 in the nth place if ay does have 5 there. The resulting. decimal differs from each a, in the nth decimal place and s0 cannot appear in our hypothetical list of all algebraic numbers, s0 it is not algebraic. ‘We can describe the construction more concisely if we let the digits of the nth algebraic number be dp.1; @n.25 ‘dn,3y +, and construct a new number = O.bibnby... by “ sens Chap. 1 taking by = 5 if ann # 5, and by =6 if Gan = 5. (There is no particular significance to the numbers 5 and 6.) It is sometimes alleged that a proof ofthis kind is only 1 “pure existence proof” and furnishes no explicit example of a transcendental number. This is not the case. At least in principle itis possible to count the algebraic mumbers explicitly, find their decimal expansions, and so write down as many digits as we like of at least one transcendental number. The reason that the number 7, say, seems more cconerete is that = occurs in more contexts than the number ‘we have just been talking about, so that more is known about it; in particular, people have been interested enough to compute billions? of decimal places of 7 already. ‘We have shown how to find @ transcendental number; to show that some given number is transcendental is much harder: it is © problem in number theory and requires deeper methods than the simple argument used here. The transcendence of e is fairly difficult, that of consider ably harder, e* and 2Y? much harder again;? and it is rot known whether 1 is transcendental or not, or even whether it is irrational. Another transcendental number {is 0.10100100000010...., where there are n! zeros after the nth 1. This transcendental number is in a sense simpler than x ore, since we could say without: much trouble what any particular digit, say the quadrilionth, is, whereas we cannot, at least at present, do this for or If we look over the proof of the existence of transcen- dental numbers, we see that no use was made of the fact that ai, a2, ... , were algebraic numbers beyond the fact ‘that the algebraic numbers form a countable set. The same argument applies, word for word, to show that if Eis any «given countable set of real numbers between 0 and 1, then there is @ real number between 0 and 1 that is not in E. Sec. 3. COUNTAPLE AND UNCOUNTABLE seTs 15 Hence no countable set can exhaust the set of real numbers between 0 and 1, or in other words the set of real nurnbers between 0 and 1 cannot be countable. Exercise 8.5. The particular interval (0,1) isnot significant; modify the preceding argument, or use the result, to show that the set of real numbers in any interval, however shor, is not countable, Exercise 8.6. Show thatthe set of real numbers in (0,1) whooe decimal expansions do not contain any S's ie nat countable. (The number 3 has no particular significance here.) Exercise 3.7. Critcize the following "proof that the set of real numbers between 0 and 1 is countable: First count the decimals that have only one nonzero digit, then those with at ‘most two nonzero digits, and so on; we have then broken the set Into a countable colletion of countable sets. We defined a set to be finite if itis countable but not countably infinite. We naturally calla set infinite, whether it is countable or not, as long as it is not finite. Every infinite set contains a countably infinite subset. To see th choose a first element 2;, quite arbitrarily. The set with 2 removed is still infinite (why?); choose an element 22 from this reduced set; and so on. This process cannot terminate (again, why’), 80 our set contains the countably infinite subset 21, 22, Exercise 3.8. Supply answers to the two questions in the preceding paragraph. Exercise 3.0. Show that if E is any infinite set and F is with one point deleted, then E and F can be put into one-to- fone correspondence with each other. Thus every infinite set ‘can be put into one-to-one correspondence with o proper subset of itself 16 sers Chap. 1 Exercise 3.10, Establish a one-to-one correspondence be- tween a finite interval and the set ofall real numbers. ‘As another application ofthe kin of reasoning that we have been using, we prove that the aggregate A of subsets of any given. nonempty set E is “larger” thon E, in the sense that A cannot be put into one-to-one correspondence with E, or indeed with any subset H of E. We shall not mske any use ofthis fact, but it helps to justify the remark on page 4 about the paradaxical character of “the set ofall set.” Exercise 3.11. Use the theorem Just stated to show that the notion of the eet of al sets fe paradoxical. For finite sets we could show without much trouble that there are two subsets of set with one element (the st itelf ‘and the empty’ set); four subsets ofa set with two element (the ‘whole set, two sets containing one element each, and the empty tet) eight subsets of «set with three elements; and generally 2 subsets of oaet with m elements, So cur statement fs true foe finite sete; the general proof wil, in fat, cover ll sts with least one element. ‘Suppece, then, that Eis sot with atleast one element, and suppoee that the collection ofall the subsets of ean be put into one-to-one correrpondience with a subset Hof E. In other ‘words, suppose that the subsets of E can be labeled, say a8 F,, where = runs through the elements of Hf, 0 that every subset is labeled end no element of H is used twice. We ate now going to deduce a contradiction, and this contradiction will show that the alleged one-to-one correspondence cannot exist. We frm & subset G of B in the following way. For each z in H, we look ‘at F and see whether F, contains =. If Fy doesnot contain 1, put = in G. (In particular, the z for which Fis empty is pot in G; the + for which Fis E isnot put in G.) Then G is «proper subset of and so by assumption corresponds to some © in H, that i, Cis F. However, by construction, if 2 is in F, then we did not put the element + Into G, so G is not Sec. 3 COUNTABLE AND UNCOUNTABLE SETS «IT. Fy; if, on the other hand, 2 is not in Fy then G contains 2 and F; does not, so again G is not F. We have thus deduced from our initial assumption the contradictory statements that Gis F, and that G is not Fy, so that the initial assumption is untenable ‘The preceding theorem shows, for example, that there are ‘more sets of real numbers than there are real numbers. In a rather similar way we could show that there are more real-valued functions, with domain the real numbers, than there fare real numbers. Exercise 3.12. Prove the preceding statement. We now establish the fact, which seems surprising at fist sight, that there are just as many points in a line seg- rment as in a square area: that is, the real numbers between 0 and 1 can be put into one-to-one correspondence with the points in a square. (The points in a square are ordered pairs of real numbers, their coordinates; see page 22.) The general idea of the correspondence is easy to grasp: if we have two real numbers, represented as decimals, we can in- terlace their digits to get a single real number; conversely, given a real number, we can dissect its decimal expansion to get a peir of real numbers. The details are not quite obvious, however. Suppose, to make decimal representa- tions unique, that we select the nonterminating decimal ‘when there is a choice: thus we take 0.243099... instead of 0.244000... ‘The obvious procedure of making (p,q) p= Opipapy... and q = O.ngas-.. correspond to Omiapag --. does not work because, for example, the dec- imal 0.13201020... would correspond to (p,q) with p 0.1212... and ¢= 0.300... and the latter is @ decimal of ‘the kind we are not allowing. Once we recognize this diff culty, we can easily avoid it, however. All that is necessary is to attach to each nonzero digit any string of consecutive 18 sens Chap. 1 zeros that immediately precedes it and treat these groups of digits as units. Thus 0.13201020.... now corresponds to (pa) with p = 0.1202... and q = 0.301...; and to (.g) with p = 0.008100054... and q = 0.100358... cor- responds the real number 0,003110080005549. Tt is often quite hard to exhibit » one-to-one correspon dence between two sets explicitly itis sometimes easier to show that each get ean be put ino one-to-one correspondence with f subset ofthe other. The following propostin, known as the Schroeder-Bernstein theorem suet in such situations. 1A and B ae sets, fA canbe put nto one-to-one correspondence witha oubeet of B, ond if B con be put ita one-to-one cor respondence with a subset of A, then A and B can be put into one-to-one corespndence with each other We may suppose that initially the subsets of B end A with vwhich we ae concerned are not B and A themselves, since if they are, there is nothing to prove. We are suppesed to have ‘two one-to-one correspondences, one (call it S) between A and a sult of B, the other (call it T) between Band subset Of A. Take any clement ay ofA, Bod it image bin B Under 5, find the image an of by under and 20 on. Ths proces may lend us beck to-oy afer a finite number of stepe or ft may 0 on Indefnely. What it cannot do le to give a chain of flements that crosses itealf, for example, o that a5 ~ ay; for, if thi happened, T would carry by into op and also cary by into ap, This would contradict the assumption that is one torone unles y= a, in whlch case cy = a. In addition, i tay happen that a cocurs asthe image of rome element of under T, and in this case we can prolong the chain backwards from oy, possibly Indefely. If any elements ofA remain pick cone and start a new chain. Tn this way, the elements of A fall into disjoint classes: Ay consists of elements that belong to chains with one pait of elements (symbolically, o1 5 by % ay): Ap consists of ele rents that belong to chains with two pairs of elements (a1 by 5, ay 5s by 50); and so on. ‘There may be, in edition, Sec. 3 COUNTABLE AND UNCOUNTABLE sexs «19 lements of A that belong to infinite chains. ‘There are three kinds of infinite chains: those with a first element in A that hhas no antecedent in B to produce it under T; these with a first element in Bj and those with no fret element at all. We call these classes Ao, A-1, Ax respectively. The classes A.1, ‘Ao, Ai, Aay s+ Are are al disjoint from each other, and every tlement of A isin one of them. Let By be the clas of element of B that belong to chains containing elements of As. ‘Then the By are also disjoint and every element of B is in one of them (since we can start a chain from an clement of Bas well as from an element of A). ‘Now A: and By are obviously in one-to-one correspondence already. Since Az consists of pairs of elements of A connected with pairs of elements of By, we can put Az and By into one-to- one correspondence by pairing off the elements in the obvious way (the first element of a pair in A with the frst element of the corresponding pair in B, and so on). We proceed similarly with Ap and By for k= 3, 4,.... We put Ay into one-to-one correspondence with By by opersting on each chain separately: pair the first element 1 with its image by under S; pair e2 with by; and so on. In other words, use Son As to carry An Into Bo. Here we use the fact that chains of elements in Ay do not terminate. Similarly, for A-1 we use T to establish the one- to-one correspondence. Finally, As. and By. consist of chains that axe infinite in both directions; here we can use either $ ‘or T. Thus we have established one-to-one correspondences between each Ay and the corresponding Br, snd hence a one- to-one correspondence between all of A and all of B. ‘As an application of the Schroeder-Bernstein theorem we show that there ore just os many sets of postive integers as there are real numbers (in contrast to the fact, noted on page 12, that there are only countably many finite sets of positive in- tegers). By Exercise 3.10, we only need to consider the real numbers between 0 and J. If we have a real number r between (and 1, we can represent it. as a nonterminating decimal, for instance, as 0:20015907.... To this real number we assign the set of integers 20, 10000, 500000, $000000, ... In the general 20 sers Chap. 1 case, ifthe digit « # 0 occurs in the nth decimal place ofr, we Incorporate in our set the integer whose decimal representation {is a, followed by n zeros. In this way the set consists of differ- cent integers, and two different real numbers r generate diferent seta of integers. Te may seem at fist sight that we get only a relatively small proportion of all the possible sets of integers in thie way. How- ever, lt us now consider an arbitrary set of positive integers. ‘To $ we assign « unique reel number as follows. First write the decimal u = 0.123456789101112... (formed by writing down all the positive integers in their natural order). I the integer ‘occurs in S, replace it in u by a string of zeros. For example, if = (1,8,12,13,17), the corresponding decimal will be 0.02845670910110000141516001819 . IS consists of all even positive integers, its decimal represen- tative is 0.10305070900110013.... Thus we have a one-to-one correspondence between all ets of positive integers and a set of real numbers, and another one-to-one correspondence between the set of all real numbers and a class of sets of postive in- tegers. Then, by the Schroeder-Bernstein theorem, there Is & ‘one-to-one correspondence between the class of all sets of posl- tive integers and the clas ofall rel numbers. Exercite 3.13. Show that there are just as many sequences of real numbers as there are real numbers. NoTES For 9 direct proof ofthe countability of the polynomials with Integral coeficlents, see Alan Frank, The countsblty ofthe rational polynomials, Americen Mathematical Monthly 87 (1980), 610-811 "he third edition of the book cited a paper of D, Shanks snd J.W. Wrench, J Caleslaion of «to 10,000 decimal, athe ics of Computation 16 (1962), 76-08, and noted that one milion decimal digits ofr were known, but not widely availble. Nowadays, finding one milion digits of + i « feasible computation on & typ. Jeal office workstation at typiel university. Por an entertaining Seo. 4 ‘METRIC SPACES a sccount of how the Chudnoveky brothers cleulated over two Billion digits of on s home-made supercomputer ste Richard Preston, The Mountains of Pi, The New Yorker, March 2, 1992, pp. 36-67. The Chodnovskys' own secount of thet work ie D. V. and G. V. Ch noveky, The computation of claasial constants, Procedings of the National Academy of Sciences 86 (1989), 8178-8162 For Informa. ton about moder algorithms for computing m, see J. M. Borwein ‘nd P. B, Borwein, Ptand the AGM: a Study in Anclytic Number Theory end Computationel Complesity, Wiley, New York, 1087 See Caros Mathematical Monogreph number 11, Irrational Num- berg by Ivan Niven “inst proved by Felix Bernstein as a 19yearcld stent, ive proofs tee M. Reichbech, Une simple démoneration di ann, A short proof of an equivalent form of the Schroeder-Bernstain theorem, American Mathematical Monthly 68 (1961), 770; LHL. Cox. A proof ofthe Schroeder-Bernstein theorem, ‘American Mathematical Monthly 75 (1968), 508: and Keith Devlin, The Joy of Seta, second edition, Springer, New York, 1993, p. 78 4. Metric spaces. A space is just another name for a set, with emphasis on the possibility of considering its sub- sets. However, when we call a set a space we usually intend to imply that some sort of additional conditions are to be imposed on the points of the set, which, of course, need not be points in the ordinary sense. A metric space is a (nonempty) set in which we can speak of the distance be- ‘tween two points. It is @ generalization of the ordinary lines, planes, and three-dimensional spaces of geometry, but only some of the geometrical properties have been pre- served. ‘We require the distance between two points to satisfy the following conditions (which the ordinary distance in Buclidean geometry certainly does satisfy): the distance is ‘nonnegative real number, zero only if the points coincide; ‘is the same in either direction; and the sum of two sides of| 2 sens Chap. 1 triangle is at least as much as the third side. In symbols, if (x,y) denotes the distance between the points = and v, ‘we are to have (1) d(z,y) > 0; d(e,2) = (positivity); (2) d(z,y) = d(y,z) (symmetry); (8) d(z,z) < d(z,y) + d(v, 2) (triangle inequality). We often refer to the distance function for the space as the metric ofthe space. Tt turns out that a good deal of geometry depends only on these three properties of distance. Consequently, many facts about ordinary space can be carried over to other spaces that at first sight are very different because their points are not points in the ordinary sense, but. may, for example, be functions. The possiblity of using geometrical Jenguage in metric spaces makes many of their properties more intuitive, although, of course, it may on occasion be risleading as well Here are some examples of metric spaces, Rj, Euclidean one-dimensional space, real numbers, with d(2,y) = |x — ul. Re, Enclidean two-dimensional space, is the ordinary plane of analytic geometry, and the distance is the ordi- nary distance. The points are ordered pairs of real num- bers (‘ordered” means that (71,22) is not the same as (2x21). While in elementary mathematic it ie usual to denote points in the plane as (r,y), where xis the abscissa and y is the ordinate, it is more in keeping with our nota- tion for other metric spaces to use the letter z to denote a point of the plane with coordinates (e),.r2), and similarly to denote a point of the plane with coordinates (yn, 42). ‘The distance from (1,22) to (v1s4n) is {eu — v0)? + (ae any}? ; diay) > Oe xy the set of all Sec. 4 ernic spaces 23 R,, Buclidean n-dimensional space, is defined simi: daly, Exercise 41. Are the following objects metre spaces, of not? (a) The Buclidean plane with points 2 = (21,22), but with diszance defined by d(z,3) = [21 —m- () The st of cities in the United States that have airports, with d(A,B) = “scheduled ar travel time from A to B” (6) The postive real numbers with d(zy) = 2/y. (@) Asin (c) but with a(e,y) = |tog(2/0) (©) The set ofall postive numbers represented by termi nating decimals, with d(z,y) = |x — yl rounded to 10 decimal places. Exercise 4.2, If we use the seme points, but change the de inition of distance, we get a new space. For instance, change the distance in Ra by saying that the distance from (21,2) 0 (1.42) is the sum [21 ~u1|++[0—D]- Show that the result i @ Ineitic space; show that there is now a nondegenerate triangle such thatthe sum of two sides is equal to the thd side; draw the locus of points that are at unit distance from (0,0). Do the same things if the distance from (21,22) to (un.4n) is taken to be the larger of [2s ~yn| and [zx ~ 2 In our next three examples, the elements of the space will be infinite sequences of numbers. Since the elements of R, are sequences of n numbers, these “sequence spaces” may be thought of as infinite dimensional generalizations of Re. ‘The space cy is the space of sequences that converge to zero. Its points are sequences of numbers: {¢1, 22, zu.--), where limz, = 0. If we denote such a sequence by the single letter 2, the distance d(z,y) is defined to be suPq>s [tm ~ wal. For example, if z = {1, }, ~}, -$, 3, J and y = {1, —1, 0,0, ...), then d(z,y) a sers Chap. 1 ‘The space m is the space of bounded sequences. Its elements are agnin sequences of numbers, bt now required only to be bounded. ‘The distance i the same as for cy. ‘Thus we could have x = {1, 0, 1, 0, ...} and y = {1, 4, 1, 5, 9, 2, 6, 5, -..}, where no tp is to be negative or exceed 8,’ Here the distance d(x, y) cannot be computed until we know more about the law of formation of y. Given that yo = 3, mo = 5; m1 = 8, and nia = 9, however, we see that d(z,y) = 9, the largest posible value. "The space I is the space of sequences for which the sum_ of the squares of the components converges. Its elements are soquences = = {21,22,-..} with 2} +f 42] +--+ < co. We take d(z,a) = {Soz-a(tn ~ te)?}"”. To verify the triangle inequality in this case, we need Minkowsk's ate,2) = {Tle aah)" = {Sollee m0) + Ge — 20” <{Xten— we)? + (oe — af = dea) + a2) Next we have some examples of metre spaces whose pots ae funtion, ‘The space C is the space of continuous functions de- fined on the closed interval [0,1]. Its elements are contin- ‘uous functions x = x(t), where 0 ¢ are close (see page 8). Open sets in Ry have an especially simple structure: if they are not empty, then they consist of countably many disjoint open intervals. ‘The word countable is redundant here; any collection of disjoint intervals in Ry is countable, since each interval contains a rational number that is in no other interval, and so our collection of intervals is in one-to- one correspondence with a subset ofthe rtional numbers. ‘To show that a given nonempty open set G in Ry is @ union of disjoint intervals is rather tedious in detail, but the idea of the proof is simple. Since Gis open and not, ‘empty, it contains a point and then a neighborhood of that point. We let this neighborhood, which is an open inter- ‘al, expand until it is a8 large as possible. Ifthe enlarged See. 5 (OPEN AND CLOSED SETS 31 interval does not exhaust G, pick a new point and a neigh- borhood of it in G, and repeat the process; and so on. No point of G can escape, since if one did we could proceed to enclose it in an interval as before. To do this carefully, it is convenient to suppose frst that G is bounded. If we show that there is a largest open interval contained in G and containing a given point , then there is a largest open interval contained in G (for there are only a finite number of intervals of length greater than 1, a finite number of intervals of lngth greater than }, and so on). If there is more than one largest interval, we can arrange them according to the magnitudes of their left-hand endpoints. Then we do the same for the next largest intervals, and so on. In this way we can see that the representation of G as a union of disjoint open intervals is unique. Te remains to show that there is a largest open interval that is a subset of @ and contains a given point 2. There is certainly some interval (a,b) (a neighborhood of z) that is in G. Let B be the least upper bound of numbers such that the interval (z,b) isin G. Similarly, let A be the ‘greatest lower bound of numbers a such that the interval (q,2) is in G. Since G is bounded, A and B will be finite. ‘Then Bis not a point of G, since ifit were, G would contain ancighborhood of B, and B would not be an upper bound of the set used in defining it. A similar argument applies to A. Hence the interval (A,B) is in G and cannot be enlarged without including points outside G. Finally, suppose that G is unbounded. If G # Ry (when G = Ry there is nothing to prove), then we may 1s well assume that @ is bounded from one side; for if «is, 1 point of the complement of G, we may treat the parts, of G to the right of a and to the left of « separately. Sup- pose, then, that G is bounded below, and let a denote its 2 sens Chap. 1 sreatest lower bound. If the complement of G has a finite supremum, say b, then G consists of the interval (b, 0) together with the countably many disjoint open intervals that make up the bounded part of G between a and b. If CG) is not: bounded above, then we can choose an in- creasing sequence of points of O(G) tending to oo, and the part of G between each pair of these points is a countable union of disjoint open intervals by the argument for the bounded case If we look for subsets (other than the empty set and the whole space) of Ri or Re that are both open and closed, a little experiment will convince us that there are none. ‘That this conclusion isin fact correct will be proved shortly. The property of Ry and Re (and generally of Ry) that allows only trivial sets to be both open and closed is called connectedness. We define this property first for ‘open sets. An open set (in particular, the whole space) is connected if it cannot be represented as the union of two disjoint open sets, neither of which is empty. Thus, for ‘example, in Ry, the union of the two open intervals (0,3) and (},1) is not connected, since the two intervals are each ‘open and not empty, and are disjoint. More generally, a set E (not necessarily open) is con- nected ifit cannot be covered by two open sets whose in- tersections with E are disjoint and not empty. This notion of connectedness is pethaps not completely in accord with intuition. We shall show presently that Ry and Re are con- nected, The set of rational points in Ry is not connected, since, for example, itis covered by the open sets defined by the inequalities x > ¥2 and z < v2. On the other hand, a set such as the one indicated in the figure, consisting of an oscillating curve condensing toward a line segment, together with the line segment, is connected. (The graph of y= sin(I/2), together with the segment —1 < y <1, Sec. § (OPEN AND CLOSED SETS 33 has a similar character.) We might think that the line segment L at the left could be separated from the rest of the set, just as two abutting open intervals can be sepa- rated from each other. However, an open set that covers ‘any point of L would have to contain a neighborhood of a point of L, and the oscillating part of the graph enters any such neighborhood. Indeed, for the same reason, the set is still connected if we include only the rational points on L, cor only the irrational points on L. By combining two sets of this kind it is possible to construct two connected sets inside a square, one of which joins two opposite corners of the square, and the other of which joins the other two corners, although the two sets have no point in common. It is also possible to have a set that is connected but has the property that after one particular point is removed, the remainder has no connected subsets containing more than one point. (A construction is outlined on page 42.) ‘A set may be open or not according tothe space in which i is considered. However, we must not suppose, merely because connectedness was defined by using open sets, that a set can change from being connected to not being connected if itis considered as a subset ofa different space. Infact, the property Ey sers Chap. 1 of being connected, unlike the property of being open, isan intrinsic property ofthe set. That i, ia set i connected when considered in one space, iti still connected when considered in another space, os long as the metric remains the same on points of the set ‘We shall show (equivalently) that the property of not being connected depends only on the set. Suppose that Fis set ina metic space S, that Bis not connected, and that 5) is 2 subapace of § and 5 is a subspace ofS, with E cS). We have to show that, whether we have added points to 5 (to set Sp) of taken points avay fom $ (to get 5), the set Eis Sill disconnected. We start with the asumption that B.C AUB, where A and B are open (ia), and the intersections ANE and BNE are disjoint aad nonempty. ‘To show that is disconnected in the space S), we replace thesets and B by subsets Ay and B ofS, where Ay contains all the points ofA tht ae in 5, and By contains all he points of B that are in S. ‘These sets stil cover E (since EB 5) tnd their intersections with B are still nonempty and disjoint ‘We need to show that A, and By are open subsets of S. If isa pot of A, then p is certeialy a point of A, and since ‘Ais open in S, all points of $ at distance leas than some 7 ftom p belong to A. Consequently, all points of Sst distance tes than + fom p belong to A. ‘Thus every point of A is an interior point of Ay (with respect to 5). Similarly Bi is open respect to S. Hence Es stil disconnected in $ ‘To show that is disconnected in the space Sy, we inflate the covering sets A and B into subsets and By of S a8 fl lows. Ip i a point of A, then since Ais open in 5. all points ‘of $ at distance less than some r from p belong to A. We ad- join to A all points of S; at distance les than r fom p. Do {his for each point pin A, and denote the enlarged set by Ar Notice that Ay is an open set relative toy by Exercise 5.18, because each pont of Ay belongs toa neghbothood in Sy that incontained in Ay. We abtain the open set By hy sinilariy en- larg B. Theses Az and By stil cover E and have nonempty See. 5 (OPEN AND CLOSED SETS 35 Intersections with B. It may happen that Ay and By have some points in common, but thei intersections with B are stil die Joint, because the points we added to and B are points that outside Sand in particular ie outside. Hence Estill disconnected in It's easy to show thet Ry is connected. It were no, it would be the union of two disjoint nonempty open sets. ‘These sets would also be closed (Exercise 5.20), since each is the complement of the other. Hence itis enough to prove that Ry has no nonempty subset that is both open and closed and is not all of Ry. Suppose there is such ‘subset call it G. Then G is made up of countably many ‘open intervals whose endpoints are notin G, as we saw on page 30. On the other hand, thee endpoints are boundary points (also limit points) of G, and since G is also closed, they belong to G. This contradiction shows that G cannot oss. "To show that Ry is connected, tis sufficient to show that it contains no set, other than itself and the empty set, that is both open and closed. Let B be such a set let PCE and Q € C(E). Consider the infinite straight line through P and Q, regarded asa space L, with the distance between two points in L equal to their distance in Re ‘Then Lis @copy of Ri. The sets BOL and O(E)AL are both open and closed in L, and neither of them is empty (cinee ene contains P and the other contains Q). ‘This contradicts the connectedness of Fy Exercise 5.27. Show that every nonempty set in Ra, except for Re itself, has a nonempty boundary. Exercise 5.28. The closure of a set B is the union of E and the set ofall limit points of EB. Show that it is also the union 36 sers Chap. 1 ‘of B and the set of all boundary points of E, end that closed. Bxercise 5.29. If F isnot finite, must some point of E be en Interior point of the closure of E? Exercise 5.80. What are the closures of the sets in Exer- cise 5.25? Exercise 5.81. A neighborhood of x consists of the points y ‘such that d(x,y) , then there is a neighborhood of p con- taining no point of Ez (other than p); the smaller of these neighborhoods contains no point of ether Fy or Ep (other than p), contr that p isa limit point of By U Ee ‘Thus pis limit point of at least one of E and Ey. Since By and FE are both closed, p € Ey if p is limit point of Ej, and p € Bp if pis a limit point of Ey. Hence p be- longs to at least one of Ey and By, that is, p belongs to E,UEp. Therefore E; UE; contains all its limit points and so is closed. ‘To see that the intersection of two closed ses is closed, consider a limit point q of E; Ez. Every neighborhood ‘of ¢ contains points, other than 9, belonging both to BE See. 5 (OPEN AND CLOSED sers 37 and to Ey. This property makes a limit point of Ey and a limit point of E. Since F and Bz are both closed, q belongs to both and so to Ei 9 Ez. ‘Therefore E19 Ee contains all its limit points and so is closed. Exercise 5.32. Prove by induction that the union of any finite number of closed sets is closed. Exercise 5.88. Show that the intersection of any collection (possibly uncountable) of closed sets is closed. Exercise 5.34. Find an example to show that the union of ‘8 countably infinite collection of closed sets is not necessarily closed. Exercise 5.35. By arguing in a similar way, or by considering the complements of the sets concerned, show that the union of any collection of open sets is open; that the intersection of finitely many open sets is open; and that the intersection of a countably infinite collection of open sets need not be open. Exercise 5.86. Let 2 be a given point of a metric space. IE.N; is the neighborhood of z consisting of all y such that d{z, y) WV (compare the more detailed discussion of convergence in §8). Let i, 12, yy be rational numbers such that [za ral <¢ for n=, 200-4 Ne Thea = (P1sP2yon- 476500.) i the required point. Tn the space C of continuous functions, the set of all polynomials is everywhere dense, as we shall sho in §19. Exercise 6.8. Show that there are uncountably many polyno- nial Exercise 6.9. Show that there are countably many polynomi- als all of whose coefficients are rational Exercise 6.10. Show thet ifthe set of all polynomials is dense in C, 20 isthe set of all polynomials all of whose coeficients are rational. Deduce that C is separable. ‘The space m of bounded sequences of real numbers sree ssesmple oa sae thet nt eartle fen sets lows 4 sers Chap. 1 Exercise 611. Show that there i an uncountable set Sin m, all the points of 5 being represented by sequences containing only O's and I's, Exercise 6.12. What is the distance in m between any two of the points ofthe sot $ of Exercise 6.117 ‘Take any everywhere dense set E in m. We shall put theset $ (described in Exercise 6.11) into one-to-one corre- spondence with a subset of E. This wil show that con- tains an uncountable subset and so is uncountable. There- fore m can contain no countable dense set. To put $ into one-to-one correspondence with a subset of E, we proceed asfollows. Take any point p of 8. Thereis a point gof E at distance less than } from p, since E is everywhere dense. ‘The distance from to any other point s of $ is more than f, since 1 = d(p,s) < d(p,q) + d(a,8) < $+ dla). In this way we have associated a different point of E with cach point ofS, so that E has atleast as many points as S, ‘and hence uncountsbly many. Exercise 6.13. Show similarly thet the space B of bounded functions (page 25) is not separable. Notes "When Iwasa sophomore, an older student showed the the Cantor set, but admitted thet he had never been abe toad a limit point ‘thar was not an endpoat. He ater left mathematics for biology See, for example, Lyon Arthur Steen and J. Arthur Seabed, Jn, Gounterezamples in Topology, second edition, Springer-Verlag, ‘New York, 1078, pp. 145-147; J. Cobb and W. Verran, Dispersion points and fixed points, Americen Methemetical Monthly 87 (1080), 278-261 See. 7 compactwess 45 7. Compactness. It is frequently desirable to be able to assert that a set possesses a limit point, even though we may not be able to say just where that limit point Js. Suppose, for example, we are trying to prove that. a bounded, continuous, real-valued function f, defined on a sven set E in Ry, has a maximum. ‘That is, we want to show that there isa point 2 of B such that f(a) is actually equal to the supremum of all numbers f(y) for y in E. (You are supposed to have at least: a rough idea already of ‘what « continuous function is; the formal definition wil be discussed in §13.) We are then trying to show that there is an in E such that f(z) > fly) for ally in E. ‘We supposed that {fis bounded, that is, the values Jv) for y in B form a bounded set of real numbers. Such a set has a finite least upper bound M, s0 f(y) M—1/n, since otherwise some smaller number than M would also be an upper bound. Moreover, we can suppose for the same reason that the 2» are all diferent, if Bis not a inte set (and if E is Gnite there is nothing to prove). Ifthe 2 have a limit point z in B, the continuity of f makes f(z) > M because f(z,) > M —1/n. Since f(z) < M in any case, by the definition of M, it follows that f(z) = M. ‘Now under what cizcumstances can we assert that a set {2} of infinitely many different point of E has a limit point in E? This cannot always be true: for example, in Ry the set Ey = {4,4,4,;5,-.-} has the limit point 0, but this limit point is not in Ey. The set Fz = {1,2,3,4,...} hhas no limit point at all in Ry. The Bolzano- Weierstrass theorem exists for the purpose of furnishing simple con- ditions that ensure that a set contains a limit point. It says that on infinite bounded set in Ry has a limit point in Ry; if the set is also closed, it then contains a limit 46 sens Chap. 1 point, Assuming the truth of this theorem, for the mo- ‘ment, we see that a bounded, continuous, real-valued func- tion attains a mazimum on any closed bounded set in Ry ‘The examples (i) f(2) = 2, with F the interval (0,1); and (i) f(@) =1—2", with B the interval (1,00); show that, both “closed” and “bounded” are essential conditions on the set B. Exercise 7-1. Deduce from the Bolzano- Weierstrass theorem ‘that the boundedness of the function is redundant: it follows from the other hypotheses. ‘We may prove the Bolzano-Weierstrass theorem by a process that has been suggested as a method for catching ‘lion inthe Sahara Desert We surround the desert by a fence, and then bisect the desert by a fence running (say) north and south. The lion i in one half or the other; bisect this half by a fence running east and west. The lion is now in one of two quarters; bisect this by a fence; and so on: the lion ultimately becomes enclosed by an arbitrarily small enclosure. The idea is actually employed in the Heligoland bird trap? ‘The essential point in applying this dea to our problem is that if a set has infinitely many points and les in some finite interval I, then at least one half of I must contain in- ly many points of E. Let Iz be one of the halves, con- taining infinitely many points of E, and bisect Jp. Again, one of the halves of fz contains infinitely many points of E; call such a half Jy. Continue this process. We obtain nested sequence of intervals Jy, Js)... , each containing infinitely many points of E. ‘The left-hand endpoints of the intervals Jy form a set which is bounded above (since it isin 1) and so has a least upper bound 2. Every neigh- borhood of z contains some In, since the length of Jy tends See. 7 ‘compactuess ar to 0, and so contains infinitely many points of E. That is, is. limit point of B. Exercise 7.2. Prove the Bolzano-Welrstrase theorem for Rs ‘As an application of the Bolzano-Weierstrass theorem together with the uncountability of the set of eal num- bers, we prove a theorem about the approximation of 8 function by the partial sums of its power series. Let f(z) TkLo cu2*, with the series converging in [a] <1. Suppose that, for each x in (0,1), f(x) coincides with some partial sum ofits power series, that is, for each = there is an n such that S294, 42 =0. Then f is a polynomial? Let By be the set of points 2 in (0,}] for which the partial sum faq 42" = f(z). Since there are countably ‘many integers and uncountably many points in (0, }], some E, must be uncountable, and so infinite. Then Ey has a limit point in (0,3), and’ f coincides on Ey with a poly- nomial, the same at every point of Ey. But an analytic function cannot coincide with a polynomial on a set hav- ing a limit point inside the interval of convergence without being itself a polynomial. (See §24 for more about analytic functions.) ‘The statement that every infinite bounded set has a limit point makes sense in any metric space, although it ay fal to be true. For example it fils forthe space con- sisting ofthe rational points of Ry with the Ry metric. We can see this by considering the set consisting ofthe rational approximations 1, 1.4, L4l, 1.414, 14142,... to v2. This set is bounded; itis closed (since V/2 is notin the space); but it contains no limit point. ‘The Bolzano-Weierstrass property fails here because the space has, soto speak, too few points. It can also fail fora space that has too many points. For example, take the space B whose points are 48 sens Chap. 1 ‘bounded functions on (0,1]- We have seen (Exercise 6.13) how to construct infinitely many such functions, each at distance 1 from the others; such a set of points of B can- not have a limit point. A set E with the property that every infinite subset of E has a limit point in Fused to be called compact; wwe have just seen that bounded closed sets in Ry or Ry hhave this property. However, the term compact is now usu- ally applied to sets with a les intuitive property (formerly called bicompsctness). A set is called compact if, whenever itis covered by a collection of open sets, it is also covered by a finite subcollection of these sets. (To say that E is covered by a collection of sets {G} means that each point of B is in at least one G.) ‘To see how the property of compactness can be ap- plied, we shall use it to show that a continuous real-valued function f defined on a compact set E in a metric space ‘has a mazimum on E. First we show that the function is bounded. To each 2 in E we assign a neighborhood NV with center at 2 such that f(y) < f(z) +1 for all y in N. We can do this because J, being continuous, does not change much if we change x only a little. These neighborhoods are ‘open sets, and every 2 is in at least one of them, so since Eis compact, a finite number of them cover B. Let these be Mi, Nay ---5 Nn. If tx is the center of Ne, then f(2) ‘cannot exceed the largest of the fnite class of numbers S(ex) +1; 80 f is bounded above. Similarly f is bounded below. [Now we suppose that f does not attain = maximum on E and deduce a contradiction. The values f(z) for 2 in E form a bounded set, as we have just seen, so they have a supremum M, which we are supposing is not at- tained. To each z we can then assign a neighborhood IV such that f(y) < f(2)+4(M-~ (2) for ally in N (by the Sec. 7 compacriess: 49 continuity of the function f). Again finitely many of these neighborhoods, Ni, No, ..-, Na (not the same neighbor- hoods as before), cover E. Let M’ (< M) be the largest of the numbers f(x), where 2p is the center of Ny. Then for every y in E we find, by taking an zp that is in the same Nj as y, that Ju) < Fle) + $M - f(a) = EF la) + EM IN. This definition extends immediately to quences whose elements are points of any metric space: we have only to replace |8q — Z| by d(sq,). ‘Thus the se- ‘quence of points {(cos(1/n), sin(1/n))} of Re converges to (1,0); if elements z= of the space C’of continuous func- tions are defined by z,(t) = "(1)", 0 N, we have d(sn,L) <¢/2; let m > N; then d(sq,) < €/2 also. By the triangle inequel- ity, dle; $n) $ den, L) + dlem,L) N and n > N, then sq and sq agree at least through the Nth decimal place, and 50 [6m ~ éq| <10-. However, the sequence does not converge toa point ofthe space, because v2 is an irrational number. Exercise &.1. A sequence {s.) of real numbers whooe con- secutive terms eventually become cae together (Chat i oxy, [ss ~ sveil ~» 0) need not be a Cauchy sequence. Give an example. ‘A metric space for which every Cauchy sequence con- ‘verges to a point of the space is called complete. The metric space of rational numbers is not complete. However, Ry is complete, as we shall see shortly. It is, in fact, always possible to make a metric space complete by adding new points to it to make a larger space, somewhat as the real numbers can be constructed from the rational numbers. ‘We shall not discuss this construction here, however.” ‘We shall now show that the completeness of Ry follows from the least upper bound property that we took as fun- damental in §2. Let {sq} be a Cauchy sequence. ‘Then if € is a given positive number, there is an N such that Im — S91 < ef n > Nand m > N. In the fist place, the different numbers sq must form a bounded set. ‘TD see this, take ¢ = 1, find the corresponding NV, and take a convenient m > N. Then én = sm + (Sq — Sn) Whence lenl $lom[-+1 ifm > WN. Since the nite set {51,821 885-+- uw} See. 8 ‘CONVERGENCE AND COMPLETENESS 37 is bounded, so is the whole set of numbers s Now let Lg be the supremum of the set consisting of all the different s, for n > k. Since taking a larger k means that we are considering the supremum of a smaller set of numbers, we have Le > Lxy1 >--+ Let Z be the infimum of the set of all Lx. We shall show that s, — L. Let ‘¢be any positive number, and take the IV corresponding to this ¢, 60 that if n > NV and m > NV, we have [fm ~ | <€ By the definition of infimum, there must be an Lx, with ke > N, between L and L+e. Since Le is the supremum. Of the set of s, with n > k, there is an sm (with m > k) between Ly —e and Ly; hence L—¢< Sm diam E —1/n. Infinitely any of the a» or ofthe yy willbe different (otherwise we have already found x and y such that d(x,y) = diam E). If there are infinitely many different <_, then they have a limit point (by the Bolzano-Weierstrass theorem), and ‘we can select a subsequence having this limit point as a limit. If there are only a finite number of diferent 2, one of them, say 21, wil occur infinitely often, and then a sequence al of whose elements are equal to 2 will have 2) as a limit. We can proceed similarly with the that correspond to the aq already selected. The result is that wwe have sequences, which fr simplicity of notation we may call {q} and {tj} again, such that rq —+ x0, and th — tes and d(2q, ym) —* diam E. Then we must have d(r, )) — diam. For, on the one hand, d(zo,y) cannot exceed diam E, since E is closed and so 29 and y are in B. On the other hand, the triangle inequality shows that (ens Un) < d{n, 0) + ava, Yo) + d(z0, 2); Sec. 9 NESTED SETS AND BAIRE'S THEOREM = 61 so that diam E < (0,4). Exercise 8.10. Define the distance between two sets F and @ tobe inf d(z,y) for xin F and yin G. Show that if F end G are closed and nonempty sets in Rs, and F is bounded, then there are points z in F and y in G such thet d(z,y) is the distance Detween F and G. Exercise 8.11. IfN is a neighborhood of y, consisting of all 2 such that d(x,y) <7, is diam N = 2r? (Consider (8) Ri ot Re; (b) general metric spaces.) Exercise 8.12. Show that B and its closure have the same diameter NOTES "Any method, other than convergence, for attaching & sum to an infinite series i called « method of summebility. See O. Sedsa, Introduction to the Theory of Divergent Series, Hafner, New York, 1945; GH. Hardy, Divergent Series, Clarendon Press, Oxford, 1040, K. Zeller and W. Beckmann, Theorie der Limticrongsverfabren Se: ond edition, Springer, New York. 1970 See, for example, E. T- Copsoo, Metric Spaces, Cambridge Uni- versity Press, 1968, §35; ving Keplanshy, Set Theory and Metric ‘Spaces, second edition, Chelsen, New York, 1977, pp. 90-03, 9. Nested sets and Baire’s theorem. Suppose that ‘we have two sets E, and Ea, that E, > Ea, and that Ey is not empty. Then there is at least one point that is simultaneously in both sets, since Ey Ey = E. Si larly, if we have a finite number of sets that are nested: Ey > By > Ey D+ D Eq, and if the last set Ey is not ‘empty, then there is atleast one point that is simultene- cously in all the sets. There is nothing corresponding to this when we have infinitely many nested sets, none of which e sors Chap. 1 is empty; the intersection ofall the sets may quite well be empty nevertheless. Consider the following three exam- piles: (i) By is the open interval (0,1/n) in Ry; (il) Ey is the closed interval [n, 00) in Ry; (il) Ey isthe set of those points x in the metric space of rational points in Ry that ‘are subject to the inequality |z— v/2| < 1/n. In each of these cases, the intersection ofall the sets Ey is empty. We now state conditions that prevent a nested colle tion of sets from having an empty intersection. Cantor’s rested set theorem: If Ey > Ea > Ey >-°+4 if each Ey is closed and not empty; if the underlying space is complete; ‘and if diam Ey —+ 0; then there is exactly one point in the intersection of all the Ey Cantor's theorem involves three conditions besides the condition that the sets are nested and not empty: closed- ness and small diameter of the sets, and completeness of the space. In each of our three examples of nested sets with empty intersection, a different one of these conditions fails, ‘To prove Cantor's theorem, let» be any point belong- ing to B,. ‘The sequence {x} is a Cauchy sequence since ifm > n, then tm € Eq, and 80 dltq,zm) S diam Eq, which approaches zero. Since the space is complete, {2»} thas a limit in the space. If we select any E,, then the xy belong to E, when k > n, so the limit belongs to Ey because Fy is closed. That is, the limit is in every B,, Finally, there cannot be two points that are in every En, since diam Ey is at least as large as the distance between any two of the points of Ey Tes sometimes useful to have the following weaker theorem: Af we keep all the hypotheses of Cantor's theorem except that wwe no longer require thet diam Ey — 0, bul require instead hat the Ey are compact, we still can soy that the intersection of the By is not empty (although it may now contain more than one point). Since we have kept the hypothesis that Ey is Sec. 9 [NBSTED SETS AND BAIRE'S THEOREM 6 close, in any Re our new hypothesis amounts to supposing {hat By i also bounded. In Ry, the generalized theorem isan «ny spplication ofthe subsequence principe: a eequence (a-) ansisting of one point from each st has a subecquence that has imi, and this imi is «point of the required kin. In the general case we have to proced differently, Let us cover Ey by neighborhoods ofl its pnt, each of diameter at ‘moet 1. Besse Bj i compact, ite numberof thse, sy ‘Mirsc-y Nyscower By. One of the Ny most contain points ofall the B, (om m= 1 onward), Forit Midst from Bn, and 1a is disjoint from Ex, and soon, then, because the E.are ‘nested, no Ny contains points of Ey for n = max(mi,...,1mp), contradicting thatthe N's cover By. Thus it most be tae, a tueerted, that some N contains points of al the E. for n 2, and wo on. We now replace each Ey by the closure of NE. to gt ceed nested sete of ameter at most 1. Repeat this ea soning with neighborhoods of ameter at rest covering then with neighborhcods of dismeter st most { covering Es td 00 on. We obtain nested aubeets ofthe orginal Em, with diameters approaching ero, and we can then apply Cantor's theorem ints orginal form. ‘We can sometimes use Cantor's theorem to show that ‘set in which we are interested cannot be empty. If we ‘rant to know that there are things with a certain prop- erty, we can be sure that there are some if we can exhibit them as the intersection of a nested cellectin of sets sat- infying the hypotheses of Cantor's theorem. However, ti ‘often more ecient not to use the nested sts direct, but to use instead another theorem that is a consequence of Cantor's theorem. ‘To state this new theorem we need to Introduce a new class of sts: namely, sets that canbe rep- resented as unions of countably many sets, each nowhere dense. (“Countably many” includes none, or one, or & f= nite number, as well as a countable infinity.) A set that can be represented as the union of countably many nowhere 64 sers Chap. 1 dense sets is called a set of frst category. (Since the name is not at all descriptive, the name meager set has been suggested as an alternative; the reeson for using this name will appear shortly.) In Ry, any set consisting of a finite number of points is of first category. So is any countable set, for example, the set ofall rational numbers, since although this st is ‘everywhere dense, it is the union of countably many sets, ‘each consisting of @ single point. ‘The Cantor set, being nowhere dense, is of first category but uncountable. If ‘we form the union of the Cantor set with the set of all rational points, we obtain a set of first category which is both everywhere dense and uncountable. Sets that are not of first category are said to be of second eategory. Since the empty set is nowhere dense, it is of first category; hence a set of second category cannot te empty. This fect is the basis for the principal use of the notion of category: if we can show that a set is of second category, then it must contain points. We can sometimes ‘exhibit the aggregate of things of a particular kind as @ set of second category; there must then be things of this kind. Some examples will be given in §10. The technique for applying this idea depends on Baire’s theorem, which states that a complete metric space is of second category. Before proving Baire’s theorem we make afew remarks, First, the completeness of the metric space is an essential part of the theorem. The metric space whose points are the rational points of Ry, with the Ry distance, is not complete; each point of the space, regarded as a set, is nowhere dense; the whole space is therefore the union of countably many nowhere dense sets. ‘We cannot state without reservation that countable sot is of first category, although the preceding example may ‘make this seem plausible. As we noted in Exercise 6.1, 8 Sec. 9 NESTED SETS AND BAIRE'S THEOREM 65, single point need not form @ nowhere dense set. In par- ticular, single points are neighborhoods in any space that contains only a finite number of points. The next exercise ‘considers the other extreme. Exercise 9.1. Show that if all the points of a space are limit, Points, any set containing only a single point is nowhere dense, Exercise 9.2. Hence show that Baite’s theorem implies that both Ry and the Cantor set are uncountable. We now prove Baire’s theorem. Let {,} be a sequence cof nowhere dense sets in a complete metric space. We are to prove that there is at least one point of the space that is in none of the Ey. ‘The idea of the proof is that since E; is nowhere dense, its complement contains @ neighbor- hhood WV; then Nj, in turn, contains a subneighborhood Nz that is in the complement of Ep as well asin the comple- ment of Ei; and s0 on. In this way we obtain a nested sequence of neighborhoods that are disjoint from more and more of the Er, and a common point ofall the neighbor- hoods cannot be in any Es. ‘To show that there actually s a common point, we must take a certain amount of care so that we can apply Can- tor’s theorem. First select neighborhood Ni in C(Ei) whose radius is less than 1. Let Mj be the closure of the concentric subneighborhood of N%, whose radius is half the radius of Ny. ‘Then M; isa subset of Ni (by Exercise 5.36), and 60 M; is disjoint from Ej. Next, since E, is nowhere dense, IM contains a neighborhood Nz that isin C(E2) (es well as in C(E,)). Let Mz be the closure of the concen tric subneighborhood of No whose radius is half the radius of Nz. Continuing in this way, we obtain nested closed sets Mz, whose diameters tend to 0, which are not empty, 6 sers Chap. 1 fand which have the property that Mf is disjoint from Fi, Ea, «5 Ex. The common point of all the My is a point of the required kind, since it cannot be in any Ex. 10. Some applications of Baire’s Theorem. In this section, I assume that you are familiar with elementary no- tions of derivatives and integrals (antiderivatives) as dis- cussed in a first calculus course. (i) A Prorenry oF REPEATED INTEGRALS. Let f be ‘continuous real-valued function on @ real interval, say [0,1]. Let fi be any integral of f (that is, the constant of integration may be chosen arbitrarily), fo any integral of fi, and so on. If some fy vanishes identically, s0 does f we have only to differentiate fy repeatedly. ‘The following proposition generalizes this simple fact: if for each x there is an integer k, possibly differing from one = to another, such that fu(z) =0, then f vanishes identically. ‘To prove this theorem, let Ej, be the set of points for which f(z) = 0; then our hypothesis says that every x in [0,1] isin some Ex. By Baire's theorem, not every Ey is nowhere dense. Hence there is some k for which the closure of By fils an interval I,. For this particular k, since fe is continuous and vanishes on Ey, we must have fe(2) for every z in Ir; and as we observed above, this impl that f vanishes identically on J.. If Jy is not all of (0,1), wwe repeat this argument with any remaining part of (0,1), and 90 on. In this way we have f(z) = 0 for all points 2 of an everywhere dense set; and since J is continuous, it then follows that f(x) = 0 for every 2 in (0,1). ‘Thus if f(z) #0, then no matter how the integrals fy are selected, there must be some = (indeed, « somewhere dense set of 2) such that f(x) #0 for every k. Sec. 10 SOME APPLICATIONS OF BAIRE'S THEOREM — 67 (i) A Cuanactenization oF PouyNoMIALs. Again consider a continuous real-valued function f on (0,1). If {has an nth derivative that is identically zero, it is easily proved, for example by Taylor's theorem with remainder (Gee page 187), that f coincides on [0,1] with a polynomial (of degree at most n~ 1). The following theorem general- izes this in the sprit of example (i). Let f have derivatives of all orders on {0,1}, and suppose that at each point some derivative of fis 270, That is, for each x there is an in- teger n(x) such that f(z) =0. Then f coincides on [0,1] with some polynomial! We can start the proof just as in (i). Let Ey be the set of points x for which f(")(z) = 0. By hypothesis, every isin at least one E,. By Baire’s theorem, there is an interval I in which some B, is everywhere dense Since f'*) is a continuous function, f(°)(«) f coincides in T with a polynomial. We may expand I as much as possible, so that there is no larger interval containing I in which ©) ig identically zero. If Tis not all of [0,1], repeat the reasoning in any remaining part of [0,1], and s0 on. In this way, we see that there is a set Of intervals whose union is everywhere dense and in each of which f coincides with a polynomial. We still have to show that f coincides with the same polynomial in all the intervals. ‘To do this, we are going to apply Baire’s theorem again to the nowhere dense set, H that is left when we remove the interiors of our dense set of intervals from [0,1]. (Here “interior” means interior with respect to the metric space (0,1]. ‘Thus, the points 0 and 1 could possibly get re- moved.) We first need to show that H is perfect. In the first place H is close, since it is obtained by removing a collection of open sets from a metric spece. If H is not perfect, then H must have a point y that is not a limit 68 sens Chap. 1 point. ‘This point isthe common endpoint of two maximal intervals in each of which f coincides with some polyno- nial. Then ifn equals the larger of the degrees of the two polynomials, f("*)(z) = 0 for z in both intervals, and at the endpoint by the continuity of "+. ‘Therefore the in- tervals were not maximal, and the point y does not belong to H afterall ‘The preceding discussion shows that is perfect, and ‘we may suppose it to be not empty (otherwise there was only one interval to begin with, and there is nothing to prove). Consider H a8 a complete metric space. By Baire's theorem for H, some E,, is everywhere dense in some neigh- borhood inf, that i, in the part of HT that is in some open interval J. In other words, there is an open interval J that contains points of H, and f(")(x) = 0 for every x in JAH (with the same n). Since every point of JH is a limit of other points of J H, it follows from the def inition of the derivative as a limit of diference quotients that all derivatives of f of order greater than n are zero at all points of JH. Now J also contains intervals com- plementary to H, and in each such interval K we have f(z) = 0 for some m (depending on K). If m < n, wwe have /')(z) = 0 in K, by differentiating. If m > m, we have f(z) = f(x) f(z) = 0 at the endpoints of K, since these are points of JH; so by inte- grating f) repeatedly, we get f()(x) = 0 throughout K. ‘This reasoning applies to every interval K that is comple- mentary to H and is in J; s0 ")(c) = 0 throughout J. ‘Thus J contains no points of H afterall. But we arrived fat J as an interval containing points of H on the assump- tion that H was not empty. This contradiction means that +H must be empty, there was only one interval I = [0,1] to begin with, and f coincides with a single polynomial throughout this interval Sec. 10 SOME APPLICATIONS OF RAIRE’S THEOREM — 69 Exercise 10.1. Prove the proposition on page 47 without appealing to properties of analytic functions. (ii) Cowninvous EVERYWHERE OSCILLATING FUNC- TONS. In our next application of Baire's theorem, the underlying metric space will be the space C’ of continu- ous functions on a real interval. It will be shown later (page 112) that this space is complete. Let us seek frst to construct a continuous function that is not monotonic any interval. This ean actually be done more directly? Dut it is a good illustration of the use of Baire’s theorem a fairly uncomplicated situation. ‘The intervals with two rational endpoints form @ countable set. Let them be li, J, Iy,... ,in some order, and let Ey be the set of elements of the space C that are monotonic on In. We are going to show that each set Ey is nowhere dense in C; it then will follow from Baire's theorem that there is an element of C that is not in any Ey. In other words, there is « continu- cous funetion that is not monotonic on any In, and hence not monotonic on any interval (since every interval in Ry contains an interval with rational endpoints). ‘The technique for showing that Eis nowhere dense is ‘one that is useful in many applications: we show that the complement C(Ey) is open and everywhere dense. Exercise 10.2. Show that a closed set with an everywhere dense complement is nowhere dense. ‘We first show that C(E,) is open. If f is in C(E,), then {fis not monotonic in. Jn. This means thet there are three 8 2, y, and z in Ip, with x fly) and fle) > flu) Recalling that the distance between elements f and g of C is max|f(z)—9(2)], we see that if gis closer tof than half 70 sens Chap. 1 the smaller of the numbers f(y) ~ f(z) and f(y) ~ f(2), wwe also have g(x) < g(y) and 9(2) < g(y), s0 that g is not monotonic in Jy. That is, all elements g sufficiently close to f are not in B,, which is to say that C(E,) is open. ‘To say that the complement of Ey is everywhere dense is to say that in every neighborhood in C there exists a funetion f that is not monotonic in Jy. It is rather intu- itive that there is a very wiggly function close to any given Continuous function. To justify this intuition, we can (for example) let g be the center of the given neighborhood in C; we can approximate g in the metric of C, as closely as we like, by a polynomial p (§19). Now p has a bounded derivative, s0 if we add to p a small saw-tooth function with very'steep teeth we obtain a function f that is as close as we like to g and is not monotonic in Iq. (jv) Bxisrexce oF Contmuous NowHERE DIFFER- ENTIABLE FUNCTIONS. The fact thet 2 continuous func- tion may fail to have a derivative at any point came as a shocking surprise to the mathematicians of the nineteenth century. However, it turns out that “most” continuous fonctions have this property, and we should rather be sur- prised that any continuous functions are differentiable at all? Still more surprising isthe fect that a function may be everywhere oscillating and still have a finite derivative at every point. Unfortunately all known examples ofthis last phenomenon are too complicated to give here.* ‘What we are going to show is that® the elements of the space C that have, even at one point, a finite derivative, even on one side (see page 140) form a set of frst category in. This theorem shows that all the functions that are or- dinarily encountered in calculus form only a set of first cat- egory in. We do not exclude the possibility that “most” elements of C might have infinite one-sided derivatives at Sec. 10 SOME APPLICATIONS OF DAIRE'S THEOREM 71 most points (geometrically, their graphs might have cusps). ‘We shall see later (page 152) that a continuous function aec- tually cannot have a vertical tangent at all the points of an interval. Although there really are nowhere differentiable functions that do not even have one-sided infinite deriva- tives, they are much harder to construct,” the greater dif ficulty may be connected with the fact (which we cannot prove here) that these functions form only a set of first category.® The “typical” continuous function has an ev- exywhere dense set of cusps (like the graph of y = [x[!/? at the origin). A nowhere differentiable function must be everywhere oscillating, since a monotonic function has @ derivative at most points (page 165). ‘We now prove thet the nowhere differentiable functions form a set of second category in C. Consider the set. Ex formed of all those elements f of C such that, for some point z in the interval (0,1 — 1/n], [2 +h)= fle ry 0 0, whereas fi(0) = 1, f2(0) =I, and fs(0) =0. Then fr is continuous on the right at 0, fe is continuous on the left, Ja is continuous on neither side, and all three functions are discontinuous at 0. Exercise 13.2. If fis simultaneously continuous on the right at zo and continuous on the left at zo, then f is continuous at ze In this connection, it is interesting that for any real- ‘valued function whatsoever (whose domain is an interval) there is a dense (but countable) set F such that f, re- stricted to E, is continuous on E.° On the other hand, there is a function whose restriction to every set E that ccan be put into one-to-one correspondence with Ra is dis- ccontinuous.© 8 FuxcTions Chap. 2 Exercise 13.8. Show that ify is a point of a metric space, then the function f defined by f(z) = d(z,y) is continuous on the space. Exercise 13.4. Let E be a closed set in a metric space; let D be the function such that D(a) is, for each point 2 in the space, the distance (see Exercise 8.10) from z to E. Show that is continuous If we want to consider continuous functions on spaces that are not metric, a definition of continuity in terms of distance naturally will not do. Although we shall consider only metric spaces in this book, we shall rephrase the def- nition of continuity ina form that can be extended to more general spaces, if only because it is oten a convenient form to use even in metric spaces. This more sophisticated def- inition reads: f is continuous on its domain if and only if the inverse image of each open set in the range space is ‘an open set in the domain. (Here the domain of f is to be regarded as the space with respect to which open sets are defined.) The inverse image of a set E means, of course, the set of points of the domain whose image points are in E. For example, if f(z) = sinz with domain Rx, then the inverse image ofthe interval (0,2) consists of the union of the intervals (0,7), (2x,3x), (—2x,—m), ... . which is an open set. If, however, f(z) = 1 for z > 0, f(0) = 0, and f(z) =I for <0, then the inverse image of the open interval (~f, ) contains the single point 0, and so is not open. ‘Exercise 13.5. Give an example to show that the image of an ‘open set under 2 continuous function is not necessarily open, ‘To verify the equivalence of the two definitions of con- tinuity in a metrie space, suppose first that is continuous See. 13 ‘continuous FUNCTIONS 89 under the original definition. Let E be an open set in the range space, and let z be a point in the inverse image of E. ‘Then f(2a) € F, and if¢ is small enough, every y such that a(f(eo),4) < € belongs to E (since E is open). Since f is continuous, there is a positive 6 such that d(z,2%) < 8 implies d(f(z), f(2a)) <€. Hence all points x sufiiently near 2» have their images in B; that isto say, the inverse image of E contains a neighborhood of each ofits points, s0 itis open. Conversely, suppose that the inverse image of every open set is open. In particular, the inverse im- age of any neighborhood in the range space, defined by an inequality d(y,f(zo)) < 6, is open and s0 contains @ neighborhood defined by an inequality d(x, 0) < 6; this is an appropriate neighborhood to associate with ¢ in the original definition. ‘We have proved a little more than we set out to do, namely that f is continuous at x9 if and only if the inverse mage of every neighborhood of (za) contains « neighbor hood of 29. Exercise 15.6. Show thet ifthe range off is in Ry, and fs continuous at zo, and f(ze) #0, then there i a neighborhood ‘fz in which f(2)| has a postive lower bound, tht i f(2)] = m>o. Exercise 13.7. Show that if f has an interval in Ry as its domain, has is vange in Ry, and is continuous at 24, then fs bounded in some neighborhood of 29 Exercise 18.8. Ifa fonction f with range in Ry i discontine- ‘ous at zo, then there are a positive ¢and a sequence {2} with limit xe such that [f(2») ~ f(20)] > 6 NOTES "Phe distinction between continulty and the intermediate value property was first clarified by G. Darboux, Memoire su les fonctions 90 FUNCTIONS Chap. 2 Ascootinves, Anna della Scuola Normate Superiore di Pisa, Cleave {4 Scienze d (1875), 67-112. Therefore functions possessing the i termediate value property are sometimes called Darboux functions. TH. Lebeegve, Lepons sur lintératin et la recherche des fone- tions primitives, 2d ed, Gauthier-Vilars, Pais, 1928, p. 97. 3H, Fast, Une remarque sur Ia proprité de Weierstrass, Collo uty Mathematicum 7 (1959), 75-77. *Y, Pambuceian, Another example ofan exotic fonction, Ameri an Methemeticel Monthy 96 (1989), 919-914. For more information bout fonctions with the intermediate valve property, see Chapter 1 ‘of Differentiation of Real Functions by Andrew Bruckner, Prov dence, American Mathematical Society, 1094, and its references. SH. Blumberg, New properties ofall eal functions, Transactions of the American Mathematical Soctety 4 (1022), 113-128 SW. Sierpski and A: Zygmund, Sur Une fontion qui est dis- continue sur tout ensemble de puissance du continu, Fundamenta ‘Mathematieae 4 (1923), 316-318. 14. Properties of continuous functions. It is a com- rmonplace that sums, products, and quotients of continuous functions are continuous (provided that the divisor in the quotient is not zero). More precisely, we should suppose that the two functions f and g have the same domain, and ‘that their values are in Ry. Then we can define f +9, £9, and f/9 in the usual (and natural) way, provided in the iast cease that g is not zero anywhere on the common domain of the functions. Then if f and g are both continuous at 29, so are f+9, fg, and f/g ifitis defined. However, itis usu ally not necessary to be so meticulous. When f and g have difierent domains, we are likely to write f +g for the sum of their restrictions to the intersection of the domains of f and g, and similarly f/9 for the quotient of the restrictions ‘of f and g to the patt of the intersection of their domains where g does not take the value 0. Note in this connec- tion that the function ft defined by fi(z) = 2/z and the function fy defined by fa(z) = 1 are different functions Sec. 14 PROPERTIES OF CONTINUOUS FUNeTIONS 91 since their domains are different; we cannot say that fi is continuous at 0. In discussing the continuity of a product, it is convenient to use Exercise 13.7 Exercise 14.1. Show that if f is continuous at zp and g is not, then /-+9 is not. Can f +g be continuous at zo if neither {J nor gs continuous at 257 Exercise 14.2. Carty out the detailed proofs for the continuity of f +9, fa, and f/g when f and 9 are continuous, A function f is said to be univalent, or one-to-one, if in the set of ordered pairs that constitute the function, not only does no 2 in the domain occur twice, but also no y in the range occurs twice. In this case the ordered pairs (y, 2) with y in the range and sin the domain also constitute a function, the inverse of f, often denoted by f~! (not to be confused with 1/f, which isthe reciprocal off); ts domain is the range of f and its range is the domain of f. It is often useful to know that under certain circumstances the inverse of « continuous univalent function is continuous. This statement is true if the domain of the function is a compact set in some Ry or, more generally, whenever the domain has the property that every infinite subset of it has 1 limit point (the conclusion of the Bolzano-Welerstrass theorem) "owt the preceding aston, we have to show that the images of open sets are open, since these will be the inverse images of open sets under f-! It is an equiva- lent statement that the images of closed sets are closed, fa statement which is somewhat more convenient for us to Exercise 14.8. Establish the equivalence asserted in the pre- ‘ceding sentence. 2 Functions Chap. 2 Let, then, E be a closed set in the domain of f, let F be the image of B, and let w be a limit point of F wwe have to show that yp € F. Let {yn} be # sequence of distinct points of F with yy — mp, and let ye = f(). ‘There is by tnivalence, just one 2» for each yp, and the ae all different since the i are all diferent. ‘Then the fet whooe points are the has a limit point zo, and a subsequence {a,} has zo 8s its limit. (See page 59.) We have zp € E since E is closed. Since f is continuous, tae = f(n,) — f (eo); DU tay — ths 90 th = f(z0) € F. Although the intermediate value property that was dis- cussed in §13 does not characterize continuous functions, it is a property that (under some conditions) continuous functions do have. It is possessed by @ continuous func- tion with values in Ry if its domain is a connected set in a metric space S. To see this, et f(a) = A and /(6) = B, and suppose A < C < B. Consider the sets E, and Ey in consisting, respectively, ofthe points x ofS for which f(a) C. ‘These sets are disjoint, since f(2) cannot (or the same 2) be simultaneously less than Cand greater than C. They ‘are not empty, since a € B; and b € Bz. They are open, since they are inverse images of open sets. Since the do- main of f was assumed connected, it cannot be the union of two disjoint, nonempty, open sets. ‘Hence the domain ‘of f must contain at least one point c that isin neither Ej nor Ez. The only possible value for f(c) is C. ‘A continuous function whose domain is compact and whose range is in Ry has a largest and a smallest value (age 48) Exercise 14.4. A more elegant proof of the preceding state- ‘ment can be given by supposing that the least upper bound Mf of the values of fis not a value of f, and then considering the Sec. 14 PROPERTIES OF CONTINUOUS FUNCTIONS 93, function 1/(M — f). Exercise 14.5. Deduce that if the domain is both compact ‘and connected, then the range of a continuous function with values in Ri is e closed bounded interval ot a point. Compactness is of course not necessary for the existence of a maximum. Exercise 14.6. Let f be a nonnegative continuous function with domain (a, 00) and range in Ry, and suppose that f(2) —» 0 as z+ 00. Then f has a maximum on [a,00) Exercise 14.7. If fis asin the preceding exercise, but strictly postive, then there is a sequence {2s} such that zy ~» oo, and H(z) < fle) for all z > 2». That is, 28 2 ~ oo the function f never again takes as large & value as it had at 29 We now give some interesting applications of the inter- mediate value property. ‘Consider @ function f, from an interval in Ry into Ra, ‘that has the intermediate value property on every inter: val in its domain and has a discontinuity at the point c. ‘Then (Exercise 13.8) there is a sequence {2} with limit such that for some positive ¢, either fl) > f(c) +¢ for all not f(,) < f(@) ~€ for all n; say the former. Since f has the intermediate value property on every interval, it takes every value between f(c) and f(c)-+¢. Furthermore it does thie infinitely often, since we ean always consider a ‘smaller neighborhood of c. Hence if a function from an in- terval into Ry has the intermediate value property on every subinterval and is discontinuous, it must take some values infinitely often. (Thus the discontinuous function with the intermediate value property, constructed on page 84, il lustrates the typical situation better than one might have 4 FuNeTIONs Chap. 2 expected.) As a corollary, we have that if «function has the intermediate value property on every interval and takes no value more than once, then iis continuous. In partir ‘lar, a function must be continuous if it takes each value between f(a) and f(b) exactly once, in every interval (a, 5] in its domain." ‘A strictly monotonic function (page 158) is an exam- ple ofa function that takes no value more than once, but not every function with this property is strictly monotonic: (Consider f(z) = 241 for 1<2 <0, and f(2)= 2-1 for 0-< 2 <1) However, a continuous function that tales no value more than ence is indeed strictly mono- tonic. For, if it were not stiictly monotonic, then there would have to be points 21 < 22 < 2a with f(z) < f(a) and f(z) < f(za) (or the corresponding inequalities te- versed); and so f would have (in the first case) a maximum ‘at some point ¢ between 2; and ay (because f is contin- tous), and the maximum would be proper (since / takes no value more than once). ‘Then f(z) < f(c) for values of z on both sides of c, and 20 by the intermediate value property f would take some value near f(c) twice, contra- dicting the hypothesis. (The same reasoning shows that a continuous function is monotonic between its consecutive local maxima and minima: that is, if f has a maximum at zy and a minimum at 2» > 2m, and neither a maxi mum not a minimum in (21,23), then f is monotonic in (1,22) ‘We have just sen that the continuous functions (rom ‘an interval in Ry into R,) that take each value exactly once are strictly monotonic. What sort of continuous functions take each value exactly twice? The answer is that there are no such functions.” Infact, itis just as easy to show that no continuous function on a closed bounded interval can take each ofits Sec. 14 PROPERTIES OF CONTINUOUS FUNCTIONS 95 values exactly n times, where n> 1. For suppose that there is such a function f. ‘Then f has an absolute maxi ‘mum and an absolute minimum, and each must be attained at interior points except in the case n = 2, when the min- imum (say) might be attained at both endpoints. Henoe ‘we may suppose that the maximum is attained at an inte- rior point cy. Let ca, ci, «++» G be the other points where {J takes its maximum value. Then f(2) < f(c,) ina deleted neighborhood of each cy (a one-sided neighborhood if cis an endpoint). For a sulficently small positive ¢, the line v= J(cx) ~€ intersects the graph of f twice near ¢, and at least once near each other cx, by the intermediate value theorem, so there is a value that f takes at least n+1 times, a contradiction, ince f cannot be continuous and exactly two-to-one, let us suppose now that J takes each value at most twice. ‘Then we may conclude that the graph of f falls into at ost three monotonic pieces? (like the graph on page 99, ‘with a small piece removed at one end). It adds interest to this theorem to observe that: nothing similar holds for continuous functions that take each value at most three times: the graph of such a function does not have to be ‘composed of a finite number of monotonic pieces,* as is indicated by the sketch, where the nth square from the right has side an, and dq < 00. Let us suppose, then, that fis continuous on (a,6] and ‘at’ most two-to-one. By the principle mentioned above, f is monotonic between any two consecutive local maxima and minima. Thus if maxima and minima of f are attained only at the endpoints, then f is itself monotonic. If it is not monotonic, then it has af least one maximum or mini- ‘mum inside the interval, say a maximum at c. If f has no ‘ther interior maxima of minima, it must be monotonic on (a,c) and on (c,b). The next case is the one where f has 96 FUNCTIONS Chap. 2 precisely one interior maximum at) and one interior mini- ‘mum at ¢2, say with a < ¢ < c flor), Hes) > flea); suppose for definiteness that f(c1) > f(cs). Then takes some valve slightly less than f(s) at least twice near cs; taking this value to be greater than f(cr) it will be less than f(c,), and by the intermediate value property it will be talen again between ¢) and gy, fora total of three times, contradicting the hypothesis, We turn now to different application of the interme- diate value property. Let f be a continuous function from. an interval in R, into R,. We say that f has a horizon- Sec. 14 PROPERTIES OF CONTINUOUS FUNeTIONS 9 tal chord of length a (where a > 0) if there is a point 2 such that 2 and 2 +a are both in the domain of f and F(z) = f(e+ a). ‘This means that there is a horizontal line seginent of length a having both ends on the graph of the function; we do not care whether or not the sog- rent has other points in common with the graph. For example, if f(z) = 1 for every z, then f has horizontal chords of all lengths; the segment from (—1, 1) to (1,1) i ‘horizontal chord of length 2 of the function f defined by f(z) = 2'—2+1; the function f defined by f(z) = 2° has zo horizontal chords. ‘A function f whose domein is all of Ry is said to be periodic with period p if f(x +) = f(z) for all z. (Of course p #0; normally pis understood to be positive.) Exercise 14.8. A continuous periodic function is bounded. Exercise 14.9. A continuous periodic function has a maxi Exercise 14-10. If fis continuous and has period p, then the integral [2° f(z) dz has a value independent of a. We first notice that a continuous periodic function f has horizontal chords of all length. Thats, i f as pe- od p, and a is any teal number, then there isan = such that f(z +a) ~ f(z) =0. "To see this, consider /2[f(= + a) ~ f(2)] de, which is zero (by Exercise 1410). Hence the integrand cannot have 8 fixed sign on the interval (0, p): it must be equal to zero at some point. The periodic integrand must return to the Same value at pasit has e¢ 0, st must actually be equal to zero at least twice on the interval (0, p). Accordingly, there are at least two points z in (0, p) for which f(x+a) = f(x), and we see that a continuous function of period p has two 98, FUNCTIONS Chap. 2 horizontal chords of any given length, with their lefichand endpoints at different points of 0,p)> Exercise 14.11. Show that « periodic continuous function always has a chord (not necessarily horizontal), of prescribed span, with its midpoint on the graph: that i, foreach positive a there isan z such that f(2+ a) — f(z) = fle) ~ f(e— a), For functions that are not periodic, the situation is quite different. A given continuous function f, say with domain [0, 1], may have no horizontal chords at all. (For instance, f could be strictly increasing.) However, let us suppose to begin with that f does have one horizontal chord. More specifically, suppose that f(0) = f(1), s0 that f has @ horizontal chord of length 1. The universal chord theorem® states that there are then horizontal chords of 1 s-=» but not necessarily a horizontal chord of any given length that is not the reciprocal of an integer. ‘To prove the positive half ofthis theorem, let k be & pesitive integer and consider the continuous function 9, defined by o(z) = f(x + 1/k) ~ f(z), whose domain is (0,1—1/R}. Tassert that 0 is in the range of g. Ifnot, then {9 would be either positive for all x in its domain or else negative forall x in its domain (by the intermediate value property), and so 9(0) + 9(1/R) + 9(2/k)-+---+ 9(1~1/) would be either positive or negative; on the other hand, this sum “telescopes” and is equal to f(1) — f(0) = 0. ‘Alternatively, if g(z) > 0 for all z, that is, if f(z) < F(a +1/k) for all «, then f(0) < f(1/k) < f(2/k) << H(&—1)/k) < f(/k) = FQ) = F(0), a contradiction. ‘The figure indicates & function that has horizontal chord of length 1 but no horizontal chord of length a for 4} 1. If-+a > 1, then 0.< 2-0-1 <1, and so @ horizontal chord of length 1a. for g (also for f) starts at x-+a—1 and ends at x. Exercise 14.13. Prove the universal chord theorem by in duction, starting from the fact that if f(0) = f(1), then f has tither a horizontal chord of length a or one of length 1 ~ 0. 100 FUNCTIONS Chap. 2 In the same way, we can show that if f has a deriva tive fin (0,1), and f'(0) = "(), then for any postive integer n there are points z and 2+? such that f has the same slope at both points. This depends on the fact (page 143) that « derivative always has the intermediate value property; this property (for g, not merely for f) was all that was used in the proof ofthe universal chord theo- ‘Another application of the same idea yields a simple fixed-point theorem. This says that a continuous mapping of compact interval into (part or all of) itself has at least one fized point; that is, there is at least one point that coincides with its image. Another way of saying this is that if f is a continuous function on (0,1] such that 0 < f(z) < 1, then the graph of the function must cross the line y =<. Exercise 14.14. Prove the preceding statement; that is, prove that if fis continuous in (a, 8] and all the values off aren [,8), then there is an x in fo] for which f(2) = 2. Exercise 14.15. Suppose thet a clock runs irregularly, but at the end of 24 hours it has neither gained nor lost overall. Is there some hour for which this clock shows an elapsed time of ‘exactly one hout? Is there some continuous 576 minutes during ‘which it shows an elapsed time of 576 minutes? (Assume thet the indicated time is continuous increasing function)* Another closely related theorem states that if @ contin- ‘uous periodic function, of period 2p, has the property that f(x) = —f(# +p) for every z (like the graph of y = sinz, ‘with p= 7), then f(x) = 0 for at least one x. This is ob- vvious from the intermediate value theorem. If formulated in a different way, it beoomes a simple ease of Borsul’s antipodal-point theorem, which is much harder to prove Sec. 14 PROPERTIES OF CONTINUOUS FUNeTIONS 101 in higher-dimensionel situations.® In this formulation we consider a continuous function f whose domain isthe cir- cumference of a circle in Ry and whose range is in Ri. Suppose that the image of every pair of antipodal points (points at opposite ends ofa diameter) is pair of points that are symmetric with respect to the origin. ‘Then some point of the circumference maps into the origin. Sill another application ofthe intermediate value the- orem shows that « (two-dimensional) pancale of arbitrary shape can be bisected by a knife cut in any specified direc- tion. At leat if the boundary of the pancake is sufiientiy simple itis easy to see that the part of the pancake ly- on one side of a line inthe given direction has an area that varies continuously as the line is moved parallel to itself. Since this area can be either 0 or the total area of, the pancake, it must at some time be exactly haf the total area ‘We now indicate how two pancakes ina plane can be bi sected simultaneously by some line. Let the two pancakes bbe A and B. As we have just seen, there isa line in any given direction bisecting B. For the direction determined by any point P on a given circle in Ra, with center O, find 2 line bisecting B, and let f(P) be the signed difference between the area of the past of A on the lft of this ine and the area of the part of A on the right. We have a function whose domain is a circumference; whose range is in Ry; and which maps antipodal points into points sym- metric about the origin, since replacing P by its antipode interchanges left and right. If we can show that fis con- tinuous, then the special case of Borsuk’s theorem, noted above, shows that {(P) = 0 for some P, which isto say that @ line in the direction of OP bisects both A and B. The continuity of f is plausible, but not quite obvious. It is enough to show that 2 small change in the position 102 FUNCTIONS Chap. 2 of P produces not only a small change in the direction of the line bisecting B, but also 2 small change in tion, for example, a small change in its intercept on one of the coordinate axes. For, if this statement is true, {(P) will change by only a small amount. Now the preceding statement about lines bisecting B is true without reserva- tion only if we impose some restriction on the admissible shape of a pancake; for example, a “pancake” shaped like Caan be bisected by many vertical lines. If we re- Strict ourselves to convex pancales there is no dificlty, as is clear from a figure.” Exercise 14.16. Given 2 convex closed curve in the plane, there is a ine that simultaneously bisects the curve and the ‘area that it surrounds."” ‘There are similar theorems in more dimensions, but they are harder to prove. The three-dimensional fixed- point theorem can be stated in picturesque, if misleading, lenguege: if @ cup of coffe is stimed in any continuous fashion, there is at least one molecule that ends up in its original position. (This is correct only ifthe cofie occupies ‘every point inside the cup and “molecule” is interpreted as “point.”) The three-dimensional antipodal-point theorem states that a continuous mapping of the surface of a sphere into the space Ri that carries every pair of antipodal points into @ pair of points symmetric with respect to the origin rust carry some point of the surface of the sphere into the origin. This can be used to show that any three volumes in space can be bisected simultaneously by some plane (the “ham sandwich” theorem)! Nores "Thin alo follows from the defaition of continuity on page 88, since the property In question requires the inverse image of every Sec. 14 PROPERTIES OF CONTINUOUS FUNCTIONS 103, ‘open Interval to be an open Interval (and hence the inverse image of ‘every open set to be an open set). For e mare thorough teestment Sed. B Disn Daeasion tnd enon o's teres of ese ‘concerning functions which assume sll intermediate vale, Journal of Mathematics end Mechanics 18 (1968/6). 617-626; also the re- view ofthis paper in Mathematieal Reviews 30 #370. Fora localized version of the property Just dlacussed see E, W. Chitenden, Note fn functions which epproach limit at every pont of an interval, ‘American Mathematical Monthly 25 (1918), 249-250. gore generally there ie no continuous transformation of an in- terval such that each image point hes exactly two inverses See 0. G. Harrold, The nomesstence of » certain type of continuous transformation, Duke Mathematicl Journal § (1020), 780-799, and for extensions, J. H. Roberts, Twoto-one transtorinations, Dute Mathematical Journal 6 (1940), 256-262; P. Cin, Two-to-one map- Pings of manifolds, Duke Mathematical Journal 10 (1943), 40-57. ‘There is a substantial amount of literature on related topes. See, for example, Mathematical Reviews 94b:54094, 94b:54003, 9054021, aepeaTa, 3693320, $2443, 3092478, 2642547, 269-4910, 2649021, 2442054, 244.A1708, 2,9244; and Problems E 1004 end E 1715, ‘American Mathematical Monthly (1954, 425; 1965, 784). 3D. C. Gillesple, A property of continuity. Bulletin ofthe Ameri- can Mathematical Society 28 (1822), 245-250. “nthe paper cited inthe preceding note, Gllepie give a formula for such function: f(=) = rz +2" sn(n/2), 0< © 1 83. B. Dias and F. T. Metcalf A continuous period function has every chord twice, American Mfethematicel Monthly 74 (1967), {835-835 give a diferent proof. Fr extensions to almost periodic and tore general functions eee J.C. Oxtoby, Horizontal ehord theorems ‘American Mothematicl Monthly 79 (1072), 468-475 Although T. M. Flett (Bulletin ofthe Jnatitute of Mathematics and its Applieations 11 (1978), 38) has discovered tht the postive part of the universal chord theorem was proved by A. M. Ampére In 1606 (cee Mathematical Reviews 80 #5805), the modern history of the theorem begins with P. Lévy, Sur une généralication du théoréme de Rolle, Comptes Rendus de Académie dea Sciences Paris 108 (1934), 424-425; i has been repeatedly rediscovered. See HE. Hop, Uber die Sehnen ebener Kontinuen und die Scliefen gechlowener Were, Commentarit Mathematict Hectic! 9 (1987), 808-819, for extensions For s discussion of the possible lengths of horizontal ‘chords for given functlon, s¢e Hop's paper; also Oxtoby's paper ‘ited in the preceding note, and Re J. Levit, The finite diference 104 FUNCTIONS Chap. 2 extension of Rolle's theorem, Amerisan Mathematical Monthly 70 (1963), 26-90. For further information and some applications see 1. T. Rorerbasm, Some consequences ofthe universal chord theorem, “American Mathemetical Monthly 78 (1971), 509-613. ‘Rosenbaum ‘so gave pituresque interpretation of the theorem: How to build & plenie table for use on a mountain range of known period, Notions Of the American Mathematica! Society 18 (1960), 9 ‘Another application was shown to me by J.C. Oxtoby: If fig continuous and f(2-+y) = 9(/(2)y) forall and y then fs ether Stletly monotonic or conrtant. (This i problem 152246, Americ ‘Mothematial Monthly 78 (1071), 670-677.) For iff is not stetly monotone, then f(z0-+ 4) = f(2e) for some zp and some h > 0 ‘Then for ll 2, feh)= fllev+h)+(e-20))= sl/l tAhe~ a) ali 20)2 20) = fl20 + (2 20)) =f). Since f has arbitratly shot horizontal chord (by the universal chord ‘theorem, this formula shows that f has arbitrarily short periods, and toisconstant. Oxtoby remarks that converely, if iscontinoous tod tither strictly monotonic or constant, then thee ea function g sich that fle + y) = o/2).0). “Hopf, preceding note. Suggested ty J. D. Memory, Kinematics problem for joggers, American Journal of Physics Al (1973), 1205-1206. "'For an elementary and detsled exposition of this and related theorems, see A. W. Tucker, Some topological properties of disk and sphere, Proceedings of the First Canadian Mathemattal Congress 1045, University of Toronto Pres, 1946, pp. 285-209. ‘See W. G. Chinn and N-E. Steenrod, Firat Concepts of Topology (New Mathematical Library, 20. 18), Random House, New York, 196, p65. 144.6. Brennan, A property ofa plane convex region, Mathemat- ‘eal Gazette 42 (1988), 301-802; A.'C. Zitronesbaum, Bseeting a3 satea and its boundary, Methematical Gazette 48 (1959), 190-131. WiRor a proof, references, and extensions, see A. H. Stone and J.W. Tukey, Generalized “sandwich” theorems, Dube Mathematica ‘ournal 8 (1942), 856-859; Chinn and Steentod, book cited above, p.120. See. 15 UPPER AND LOWER LIMITS 105 15. Upper and lower limits. We shall need to use a generalization of the notion of limit of a sequence of real numbers. If {6a} is such a sequence, and the numbers form a bounded set, then (Exercise 15.1) there is always ‘a number L with the following property: Given any p tive ¢, we have 55 < L-+€ whenever n is suficiently large, and in addition an infinite numberof sy satisfy sn > L~e. ‘This number Lis called the upper limit of {8p}, and is writ- ten limsups, or lim sq. If {8} isnot bounded above, then no such number L exists, and we write limsup , = +00. If {sn} is bounded above but unbounded below, L may or ray not exist; in the case that it fails to exist, we waite limsup 5. = -00. ‘Consider some examples. (i) Let s, = (~1)", 0 that cour sequence is -1, +1, —1, +1, .... Then imsup s, = 1 (ii) Let 5, =n; the sequence is 1, 2, ,.... Then we have limsup 8, = +00. (ji) Let {8} = {—1,—2,...}- Then limsup sq = —00. (iv) Let sy = 1/n, n= 1,2, 3 « ‘Then lim sup s, = lims, to={ then lim sup, 0. (v) Let 1314 BESTEST SL (i) Let 1 {-.5. Bxercise 15.1. By considering the numbers Ly defined by m= mupas for k > n, show that Limsup se exists (Gnite) i {fo} is Bounded. ‘Thus lim up 5. = lity ae (S0Pp3» S). Exercise 15.2. Define the lower limit, lim in, or lim, similarly, ‘and determine it for the six examples given above for lim sup. {5a} then lim sup s 106 FUNCTIONS Chap. 2 ‘The definition of upper limit resembles that of least up- per bound, from which it difers in that finite subsets of the elements {2,} are disregarded. For example, the value of limsups, is unchanged ifthe frst thousand sp are re placed by other numbers. We could also define limsup sy a the largest limit obtainable by picking convergent sub- sequences out of {4n}- ‘We have imsup(sn +t.) Le. Slight modifications have to be made if L = too. In a similar way we can de- fine limsup, 4 f(z) ifthe domain off i «subset of Fy that is unbounded above, Examples: Sec. 15 UPPER AND LOWER LIMITS 107 (i) If f(a) =sinz for x € Ry, then limeup f(2)=+1 and liming (2) (ii) If J(@) =e sine for 2 > 0, then Jimsup f(2)=400 and liming f(e) = (ii) If f(@) = e'/* for x # 0, then limsup, gs f(2) = “+00 and liminf.g- f(z) Exercise 15.4. Show that iflimsups» = liminf s. = , and Lis finite, then lim 5, = L according to the definition given on age 54. Exercise 15.5. If limsups, < L and liminf , > L, then lim se exists (and equals Z), Up to this point, although we have considered limits of sequences, we have not had to consider limits of more general functions. For functions with values in Ra, it is simplest to define lim-.2, f(2) to be the common value (if there is one) of limsup,.., f(z) and liminfs-.2y f(z). IF the domain off includes @ right-hand neighborhood of z, we define as limsup,..,,~ f(t) the upper limit of the re- striction off to a right-hand neighborhood of 2; similarly for lim inf. The common value (if any) of these right-hand upper and lower limits is denoted by limyazy- f(2), 0F more compactly by f(zo*). There is ¢ similar definition for f(e07)- NOTES For an interesting analysis of the concept of continuty In terms oflimit, see K.P. Wiliams, Note on continuous factions, American ‘Mathematical Monthly 25 (1918), 246-240. 108 Functions Chap. 2 16. Sequences of functions. Before we go on to con- sider the special properties of further clases of functions, it will be convenient to discuss several kinds of convergence of sequences of functions. This subject was a source of confusion to mathematicians in the fist half of the nine- teenth century. Even the famous Cauchy, before he hit on the notion we call “Cauchy sequence,” mistakenly thought that the limit of « convergent series of continuous functions ‘ust be continous." Nowadays, we can use the terminol- ay of metric spaces to help clarify the different notions of convergence, Suppose that we have a sequence whose elements are functions s, with a common domain and with values 8 (z) belonging to Ry. We may fix our attention either on the sequence {s,}, whose elements are the functions them- selves, or on the sequences {s,(z)} whose elements are the values of the functions at the individual points z of the domain. We say that {s,} converges pointwise on a set § if the sequences {(z)} of real numbers can- verge for each z in S. For example, let s,(2) = 2", with O< 2 <1. For each z in (0,1), the sequence {¢,(z)} converges; the limit defines the discontinuous funetion L such that L(2) = 0 for 0< 2 <1, but (1) = 1. On the other hand, we may consider the same functions & a points of the metric space C. Then the sequence {sy} does not converge; indeed, d(s,,82x) = maxycecs(z" — 2"), and if we take 2 = 2" we see that we certainly have (50,520) > 2"—2"" = }. Hence {s,} cannot be a Cauchy sequence in the space C: Exercise 16.1. Examine {s,} for convergence in C, (8) if a) = #°(1~ 2), (0) oe@) = mo" (1— 2); in ach ase Sz. Sec. 16 SEQUENCES OF FUNCTIONS 109 We see that sequence of continuous functions can con verge pointwise even though the same sequence of func- tions, considered as elements of the space C, does not converge. It is clesr that convergence of a sequence of elements of C- does imply the pointwise convergence of the corresponding sequence of functions. There are, how- ever, other metric spaces whose elements ae functions for which convergence of a sequence of elements of the space does not guarantee the pointwise convergence of the so quence of functions. An example is the space, mentioned ‘on page 25, whose elements are continuous functions on (0,1), with metric given by we ten ={ fe -wop ar} Consider a sequence of elements of this space defined as follows: if 2" < k < 2°, then z1(t) = 0 except in the interval (£—1, 4:11); in this interval, the graph of zy is 2 triangle with base of length 2-" and altitude 1; this ti- angle moves back and forth as k increases, thus preventing pointwise convergence; but d(ze,0) < 2-*/? —0, ‘Whether or not a sequence of functions converges point- wise, we can always define the pointwise upper and lower limits lim sup s(x) and lim inf q(x) ifthe functions have ‘common domain, and range in Ry. If these upper and lower limits are finite, they define two functions, which we ‘can call imsup 6 and liminf 6. It is often convenient to generalize the space C of con- ‘imuous funetions by considering functions whose domains are sets more general than intervals in R. In defining C, wwe used the existence of the maximum of @ continuous function whose domain is a compact interval. Since every continuous function whose domain is a compact set has a 0 FUNCTIONS Chap. 2 ‘maximum, we can use just the same definition: let B be ‘compact set in @ metrie space; then the space Cs con- sists of continuous functions f with domain E and range in Ry, and metric d(f,9) defined by max |f(e) ~ o(2 larly, we can define the space Br of bounded func- tions with domain E by taking the metric d(f,g) to be supy [f(2) ~ o(z)k; here B does not have to be compact. If a sequence of continuous functions, regarded as a sequence of elements of Cx, converges, it is customary to. say that it converges uniformly on E. More generally, sup- pose that we have a sequence of functions (bounded oF not, continuous or not); if the difference of each two of the func- tons is bounded, we can form the distance between them in the metric of Bp; and ifthe sequence of functions isa ‘Cauchy sequence in this metric, we say that it converges tniformly on E. For example, if f(c) = 1/2, then the sequence {f, f,,...} converges uniformly on 0 <2 <1. ‘The sequence {&,} with sq(2) = 2° converges uniformly on any specified interval [0,a] with 0 Mp converges, the sequence {s, } converges uniformly on E. For, ifm > n we have [85 (2) ~ (2)| S My + Masi too + Mn, and the sum on the right is small when m and n are large. This is known as the Weierstrass M-test,? and is usually stated in the equivalent form that it assumes when the are the partial sums of a series. This reads as fllows: If eq are functions with domain , and |ey(2)| < My forall in E (where we emphasize that My is independent of 2), then eq converges uniformly if > My converges. Tt is sometimes useful to consider another kind of con- vergence: pointwise convergence together with uniform boundedness, that is, boundedness in the metric of Bp. We call this Bounded convergence. For example, the se- quence {sq} with sq(z) = 2" is boundedly convergent on (0,1), although it is uniformly convergent only on each (0,0), 0 se+1(z) for every n and every = in See. 17 ‘UNIFORM CONVERGENOR. 13 the interval, or else (2) < su4a(2) for every n and every = in the interval. Let us take the hypothesis inthe form s(z) > sre1(2) Call the limit function £; then (2) ~ L(z) > 0. If the con- vergence isnot uniform, then max. |s»(z) ~ L(2)] does not ap- proach zero, so there is a sequence of values of n for which rmaxr[6(z)~ L(z)] > b > 0. Since sy ~ Zi «continuous fune- tion, it attains its maximum sta points; from the set (2) we can, by Exercise 8, select a sequence {yy} with amit s. Then wwe have s(sn)—L(au) > b, and consequently s,(42)—L(an) > b for each n < (itis only here that we make easential use of the inequality s5(=) > sy41(2)). Letting &—» co, with fixed n, vw infer (by the continuity of 5 —L) that ay(2) ~ L(2) > for every n. On the other hand, 6, (2) ~ L(2) ~ 0, since we have convergence st the point z. Thus the assumption of nonuniform convergence leads to a contradiction. ‘Another condition that produces the same result is that the functions ss are monotone (even if they are not necesarily continuous). More precisely, lets +L pointwise on a com pect intereal [0], let L be continuous, and lt all the se nondecreasing functions. Then ¢q —> uniformly. ‘The proof of this theorem requites @ fact fom §19, but since the theorem fits in well here, I prove it now. Fix a pos ive number ¢, and choose & finite set of points x in [a,b] such that @ =n < mp <*> < zm = 6 and 0 < L(zs) ~ D(si-1) < € for k = 2, 8, -..4 m. Since L is uniformly con tinwous (see page 127) and nondecreasing, these inequalities will certainly hold ifthe distances between consecutive 2s are small enough. Moreover, since L is nondecreasing, we have 0S L(zx) ~ L(z) < ¢ for 21-1 Sz < zy. Now since the sequence of functions {6} converges pointwise, and there are only a finite numberof peints 21, we can choose nso large thet leu(ae)—L(24)| < efor all k, Since each 2 isin some f2n-1, 34], and L is nondecreasing, we have (2) < to (zn) < Lae) +6 < (a) +26, ‘where we use successively the hypothesis that 5, is nonde- ua FUNCTIONS Chap. 2 creasing, the inequality s(z+) < L(zs) +6, and the inequality Has) < L(a) +e. Similarly, Ue) ~ 2e< Lfay-1) ~€< oo (st—i) S (2). ‘These two sets of inequalities together imply tha, ifn i large enough, [n(2) ~ L{a)| < 2 for every 2 i (ob; tis isthe statement of the uniform convergence of {4 )- Exercise 17.1. ‘The limit of « sequence of discontinuous func. tions may be either continuous or discontinuous, whether or not ‘the convergence is uniform. One reason for the importance of the idea of uniform convergence is that a good way to construct a function with some special property is often to exhibit it as the uniform limit of functions that do not quite have the property. ‘Asan llustration of this principle (sometimes called the condensation of singularities), we shall exhibit a continu- ‘ous curve that passes through every point of a plane area, (Such space-filling curves are known as Peano curves.) We rast of course decide in advance what the phrase “con- timous curve” is to mean; the lesson of our construction is that a plausible definition of continuous curve may lead to an object that does not fit the intuitive idea of what a continuous curve should look like * One natural way of defining a continuous curve in Re is to say that it is a continuous image of a line segment, that is, the set of values of a continuous function from convenient closed interval (say (0,1) into Ra. OF course, different functions may lead to the same image, but this is irrelevant here; we are going to show that there is atleast ‘one function for which the image ofthe interval covers ev- ery point of @ whole square, indeed, covers some points more than once. We may represent the points pin the im- ‘age by their coordinates, letting the image point (x(t), v(t) See. 17 ‘UNIFORM CONVERGENCE, us correspond to the point ¢ of the domain, ‘This amounts to saying that we are thinking of a continous curve as de- fined by a pair of parametric equations, x = x(t), y= v(t), with continuous functions z and y. ‘We are now going to construct a continuous curve, in this sense, that passes through every point of the square where 0 <7 <1 and 0 My converges; and if p= p(F) = co when k + co; then li Uh) + A(R) ++ SH} = Dn. Exercise 17.4. As an application of Tannery's theorem, prove that line (1 2/8)" = D9 nl ‘There are fairly simple situations in which the theorem on term-by-term integration of a uniformly convergent se- quence is inadequate. For example, 1 = 2-422 —----+ (-2)" = [1 (-2)"*/(142), and hence 1—z428@—--- = 1/(1+2) if fz] <1. Formal integration suggests that a ae i [ee [aoe fre ee atg ate ‘We cannot justify this calculation by the theorem on. uniform convergence, since the sequence {fm} with fu (2) = Jog 2= Sec. 17 UNIFORM CONVERGENCE 121 [1 (-2)"1/(1 +2) does not converge uniformly on [0,1] (ince it does not converge at 1), and does not converge uniformly even on (0,1). Indeed, if it did, the supremum con 0,1) of [2"|/(1 + 2) would approach zero as n —+ co; but since [2/"/(1 +2) > dlz\", the supremam in question at least } and so cannot approsch zero. Tn this case it is easy to verify the result of the formal calculation: yet ‘This calculation shows simultaneously that the series 1 — $4} —--> converges and that its sum is log2. Similarly, itis not very dificult to show (although we shall not do it) that aregem Niels Abel gave this example? to refute Cauchy's mistaken carly belief that a convergent series of continuous funct ‘must have a continuous sum: the series converges at but to 0, not to 2/2. Formal integration yields Ba [je $M [omsote 12 FuxcTions Chsp. 2 (111 cosnz) 2 ee so that we have a simple way of summing the mmerical series 1a ptt Since the original series is not uniformly convergent on the interval [0,7] (because the sum is discontinuous at 7), the justification of our evaluation of the numerical series ‘eludes the elementary theory. We will consider some more sophisticated convergence theorems for integrals in §28. r NOTES "This is nown a Dinis theorem. For it and the following theo- ‘rem, see G. Pélye and G. Seege, Problems and Theorems in Analysis, vol, Sprager, New York, 1972, pp. 61 and 200-270, problems 126 fand 127 of part I “Por analyses of the notion of continuous curve from diferent points of view, ose G. T- Whyburn, What le curve?, American Mathematical Monthly 49 (1942), 408-497; J. W.T. Youngs, Curve tnd surfaces, American Mathemticl Monthly 51 (1944), 1-11, BW. Hurewice, Uber dimensionserh&hendersttige Abbildangen, Journal fr die Reine und Angewendte Mathematik 169 (1933) 71 me ‘1, 3, Schoenberg, On the Peano curve of Lebesgue, Bulletin of the Americen Mathematical Society 4 (1088), 819. Another simple onstruction waa given by Liu Wen, A space filing curve, American Mathematical Monthly 90 (1983), 28. it cen be shown thet there is no pol where 2 and y are imul- taneously diferentiele, thet is the curve has a tangent ano pent James Aline, The Pesvo curve of Schoenberg is nowher tinble Journal of Approzimation Theory 33 (1961), 28-42, Por extensions vee Lee Lorch, Derivatives of infite order, Po- cific Journel of Mathematics § (1953), 73-778. "pala and Szeg8, book eted above, pp. $7 and 214, problem 105. of par Sec. 18 PonvTWIsE LIMITS OF CONTINUOUS FUNCTIONS 123 See. J.1°A. Bromwich, An Introduction tothe Theory of I {rite Series, second edition, MacMillan, London, 192, reprinted 1965, pp. 196-197. ‘Abe, Untersuchungen ber die Rehe: 14 Br UP=Mat 4 p= et+..., Journal fer de Reine und Angewandte Math- cematit (1826), 311-339; a French verion sppearsin Abel's Oevires Completes, Grondshl, Cristiani, 181, pp. 219-280. 18. Pointwise limits of continuous functions. We consider functions from an interval in Ry into Ry. Although pointwise limit of continuous functions is not necessarily eon- tinuous, it cannot be extremely discontinuous, as we shall now show: its points of continuity must at least form an everyhere dense set (Hence, for example, the everywhere discontinuous function mentioned on page 82, which was obtained from con- tinuous functions by two successive limiting processes, cannot be obtained by one limiting process involving only continuous functions.) ‘We begin by observing that if function f is discontinuous fat e point z, then the images of arbitrarily small neighbor- hoods of x do not have arbitrarily small diameters. That is, there is en integer m such that the diameter of the image of each neighborhood of x is at least 1/n. (The images of larger neighbothoods have, if anything, lager diameters, so we can sty "every neighborhood” instead of “small neighborhoods") Now suppose that f is discontinuous at every peint of an i terval, and let E, be the set of points 2 in this interval for which the diameter of the image of every neighborhood of z is atleast I/n. As we have jut seen, every z belongs to some Ey ‘Moreover, Ey isa closed set. For, ify is limit point of Ey, ev ‘ery neighborhood of y contains some point 2 of Bs, and hence contains @ neighborhood of z, and so the diameter ofthe image of every neighborhood of y is also atleast 1/n. ‘We now use Baire's theorem, which tells us that some Er is dense in some subinterval J. Since By is closed, Ex contains J ‘That is, we have found an interval J with the property that 124 Functions Chap. 2 the image of every subnterval of J has diameter a leas 1/M. ‘The existence of such an interval J is, then, ® consequence of the property of being discontinuous at every point of some interval. Weshall now show that a pointwise limit of continuous functions cannot have such intervals J, and hence cannot be discontinuous at every point ofan interval. “The range of f, being some subeet of Ry, can be covered by countably many Intervals Ip = (ae by), enc of length las. than 1/Mf, Let us look a the inverse images Hy ofthese I ‘The sets H, collectively cover the interval J, but none of them can contain a eubinterval of J since the images of subintervals (of J all have dlametersgreaier than 1/M. On the other hand, ty Bales theorem one of the Hy is dense In a subinteral of J. If we knew that the Hy were cloed, we should bave 2 contradiction, since a closed set that fs dence in an interval ‘Contain that interval ven when f i a pointwise linit of continuous functions, there eno reason to sppote thatthe Hare closed. However ‘we can show that each fy ita countable union of closed sets, fd this property will do just aswell. For ifthe Hy have this property, then by still another application of Bates theorem, fone ofthe cloted sets is dense in 8 subnteral of, and 0 cm tains that subinterval. Since the cloed seta are subsets of ie follows that Hy will slo contain a aunterval of J ‘We have this reduced the prof of our theorem to showing that iff is pointwise lit of continuous functions fe, then the sets are countable unlons of closed sets. We recall hat eis the inverse imege under f of the interval (on bx) thats Hr i the set of pants = such that oy < f(z) 1/n. Every point of discontinuity isin some En; 126 FUNCTIONS Chap. 2 that i, the set of points of discontinuity i a subset ofthe union of the By. Since there are countably many Ex, our theorem is proved if we show that each By is nowhere dense. If some Ey failed to be nowhere dense, some point x where fis continuous would be a limit point of that Ey. If we choose « positive 6 buch that jy] < 6 implies that [f(y) ~ f(=)] < 1/(2n), and then choose a point w of By so that |Ww— 2 < $6, and let yx be the points occurring inthe definition of Ey, we have Laon) = Feo) < Ulan) ~ f(2)1+ Lf(2) ~ f0)] < 1m tly large k, contradicting the definition of Ey. NOTES LW. B, Osgood. For more on the subject of thie ection, see E.R Lorch, Continuity and Baire functions, American Mathematical ‘Menihly 78 (1971), 748-702; A.C. M. van Roct} and W. H.Sehikbet, 1A Second Course on Real Functions, Cambridge University Pres, I9é2, §f10-11 and 16-17; C. de La Vallée Poussin, Intégales de Lehengue, Fonctiont d'ensemile, Classes de Bair, cond edition, Gauthier Villas, Paris, 1994, chap. VIT-VIT. "Rend Bair, Legone sur les Fonctions Discontinues, Gautler- ‘Vass, Pas, 1906. 3H. Lebesgue. For a slple proof, sae F. W. Carrol, Separately continuous fonctions are Baie fonctions, American Mathematical ‘Monthly 78 (1971), 15 for oul 19. Approximations to continuous functions. We have seen (page 68) that a continuous function from Ry into Ry may have a rather iregular graph, at least to the extent of having cecillations in every interval. On the other hhand, thee is always a quite smooth function whose graph is very close to the graph of a given continuous function. More precisely, ifthe domain af a continuous function is 4 compact interul, then we can find, as close as we please to the function, each of the following: a step function, a continuous polygonal function, and a polynomial. A step Sec. 19 APPROXIMATIONS TO CONTINUOUS FUNCTIONS 127 function has a graph made up ofa finite number of horizon- tal line segments; « polygonal function has a graph made ‘up of @ finite number of line segments of any orientation (not vertical). Here “as close as we please” is to be inter- preted in the metric of the space B. In other words, if fis the continuous function, and ¢ is a given positive number, there are a step function fi, a continuous polygonal func tion fa, and a polynomial fg such that [f(x) — fa(z)] < (for is =1, 2, and 3) forall z in the interval in question. ‘The property that makes such approximations passible is called uniform continuity. A function f is continuous at 2 if, given a positive ¢, there is a positive & such that Uf) — f(a)| < € if |e = yl <6. Here we shall in general have to take smaller and smaller 6's as we consider dif ferent 2's. If it is always possible (for a given f) to find 2.6 that will work simultaneously for all x in a given set, the function f is said to be uniformly continuous on that set. We now show that a continuous function is uniformly continuous on any compact set in its domain. Indeed, we shall establish this theorem in a more general set continuous function whose domain and range are in metric spaces is uniformly continuous on any compact subset. $ of its domain. ‘The idea of the proof is that if @ certain 6 works for a certain z, then a slightly smaller 6 works for all nearby 2's. Using compactness, we can find a finite set of 6's one of Which works for any given 2; the minimum of this finite set of 6's works simultaneously for all x ‘To make this idea precise, fix a postive number ¢. At- tach to 2 first a neighborhood NV such that d(J/(2),S(w)) < ¢/2for ally in N, and then the neighborhood M of center 2 and half the radius of N. The neighborhoods M cover S, and since S is compact, some finite number of ther still cover S. Let these covering neighborhoods be Mi, Ms, 128 Fucrions Chap. 2 | My. Let 5 be the smallest radius of any Me. Now let 2 and y be any two points of $ such that d(z,y) <6. Since zis in some Mj, there isa point z that is the oen- ter of an My in which z lies, By the triangle inequality, d{y,2) S d(z,y) +d(e,2) < d(x, 2) +6. ‘Since 6 is the smallest radius of an Mf, this inequality shows that yis in the Ni, whose canter is 2. Hence both f(z), f(2)) < ¢/2 and a f(y), f(2)) < €/2, 80 that by the triangle inequality d(f(z), f(y)) 0 and f(z) + L (nite) as -+ 400, must f be uniformly continuous for z > 0? Exercise 19.8. If fis uniformly continuous for z > 0, must ‘{{@) appronch& init (Bate or infinite) as 2 +00? We now construct the three approximating functions whose existence was asserted above. Let S be a compact interval fat] in Rx. We have just seen that if a positive tolerance ¢ is prescribed, we ean find « positive 6 such that the given function f varies by less than ¢ on each subinterval of [a8] of length less than 8. ‘To construct @ step function f; that approximates f within ¢ divide (a, 8) into finite mumber of subintervals, each of length less than 6, and over each subinterval draw a hori- zontal line segment whose height is (for example) equal to the value of f at the midpoint of the subinterval ‘To construct a continuous polygonal approximation fa, shorten each step of fr by a small amount at each end, and then join the right-hand endpoint of each reduced step to the left-hand endpoint of the next reduced step by a line segment. Sec. 19 APPROXIMATIONS TO CONTINUOUS FUNCTIONS 129 ‘To construct a polynomial approximation fy is some- what harder. One procedure is es follows. We may sup- pose, merely in order to simplify the formulas, that the domain of our given continuous function is an interval (1 — A), where 0 < h < $. We can extend our func- tion in an obvious way so that the extended function f continuous on Ry and is zero outside (fh, 1 ~ A). Now consider the function I defined by MG me [HOU 0° wee Men -fo -eyr at. Evidently Tis polynomial of degree (at mest) 2n. The factor in brackets in the integrand has a peak att == and (wen m i large) is small wen fs not near x, 80 may Sem plausible that (2) shouldbe close to f(z). We now Sho that this is realy the case. ‘We can write ta)=e [fle 90-8, and since f(t) = 0 when t <0 or t > 1, this is the same as 1e)=o [fle 9) ae. Because of the way cy was defined, we can write 12) ~ fe) =e [ [e=9) = Fe) 0.— 2) a 130 FUNCTIONS Chap. 2 ‘We now break the integral up into three parts, toa nosy ans where 0.< 8 <1, and 8 isto be chosen in a moment, At this point we use the uniform continuity of f. If ¢ is an arbitrary postive number, we can find 6 small enowgh sothat |f(2—s)~f()] < deifls| <6, where the inequality holds for all = with the sane &. We use this inequality to estimate I on 2m een ft 2) € mick? favre f'o-oraed Next, since fis continuous on a compact set, itis bounded, say |f| (1 — #2)" dt > 6(1 — 462)". f= fae ae [a -eprar> sae) Hence we have Wal same (=a ds / <2M6-i(1 61-84)" - B82)", Since (1 - 6)/(1 — }#) <1, this estimate shows that Ts +0 as n+ oo. Exactly similar reasoning applies to 1. By taking n large enough, we then have |/j| and |J5| each Jess than fe, 80 te) — fel < Vil + Val + Ul <6 provided that n is large enough. ‘Therefore the polyno- ‘ial I furnishes the approximation fy ifn is large enough. Sec. 19 APPROXIMATIONS TO CONTINUOUS FUNCTIONS 131 Graph of 9 0 1 Interval where f(z) > 0 ‘The possibility of approximating 2 continuous function by polynomials has many applications. It was used in §10, in the proof of the existence of continous nowhere dilfer- entiable functions. Here is another application Let f be continuous on the interval [a,8). ‘The quanti- ties {2 f(x)2" dz (for n= 0, 1, 2,... ) are called the mo- ‘ments of f.. We shall show that a continuous function with a compact domain in Ry is determined by its moments; that is, two continuous functions with the same sequence ‘of moments are identical? (We do not say anything about how a continuous function can actually be caleulated fom its moments.) It is an equivalent statement that a contin- uuous function all of whose moments are zero must vanish ldenticaly, and this we now prove. Suppose that all the moments of fare zero. Without loss of generality, we sup- pose that a = 0 and b=1. If f is not identically zero, it is positive (or negative) in some interval, and we can construct a contimious function g that is zero outside this interval and that makes fj fgdr = 2h > 0. (See the fig- ure.) Let Mf be an upper bound for |f| on the interval [0,1]. Construct & polynomial P such that |g(z) ~ P(2)| < h/M for all z. Then [seem [tote [[ $-(@-P yee © ah masta) = PC] > he 12 FUNCTIONS Chap. 2 But fi {P dz =, since all the moments of f vanish. ‘The contradiction can be avoided only by having f identically ‘As a corollary of the theorem about moments, we see that the set of all continuous functions can be put into ‘one-to-one correspondence with a class of sequences of real ‘numbers, sine different continuous functions have differ- lent sequences of moments. Since there are just as many sequences of real numbers as there are real numbers (Exer- cise 3.13), it follows that there are just as many continuous functions as there are real numbers. (A more direct. way of seeing this is to observe that a continuous function is ‘determined by its values at the rational points, that is, by ‘a sequence of real numbers.) Noes "ihe theorem that 8 continous fonction can be uniformly ap proximated by polynomials on an interval is own as the Weler- frase approximation theorem. The proof given here was invented by B: Landau fora more general result, see David Vernon Widder, The Laplace ‘Transform, Princeton University Pres, elghthpeating, 1972, pp. 6O- 61 and Chapter I 20. Linear functions. A function f whose domain is Ry is said to be linear if f(z)+ f(y) = f(2-+y) forall z and y. (This is a more special use of the term “linear” than is of- ten made: the function f defined by f(z) = az + is not linear in our sense when b #0.) Clearly if f(2) = ax then {is linear, and we might expect that all linear functions ‘would be of this form; but not all of them are. ‘To ex- hibit one that is not, we should have to appeal to one of, ‘the more abstruse properties of the real number system, ‘which depends on ideas that have not been introduced in See. 20 LINEAR FUNCTIONS 133 this book.! What is also not immediately obvious, but will be established shortly, is that a discontinuous linear func- tion is necessarily wildly discontinuous: it is, for example, unbounded in every interval, and indeed its graph must be everywhere dense in Rp. Itis only to be expected that no very simple construction will produce a funetion ofthis kind. der & linear function f. For every 2 we Sle +2) = 2f(2), and s0 by induction ‘lna) = nf(2) for every positive integer n. Since f(2 fle +0) = fle) + 70), we have f(0) = 0. Since $(0) = f(e~2) = f(z) + f(-2), we have f(-2) = ~f(2) ‘Therefore f(nz) = nf(z) for every integer, postive or neg ative. Replacing x by 2/n, we obtain f(2) = nf(z/n), or fle/n) = n-1f(2). Now replace by me, and we have f(mz/n) = n-*f(mz) = (m/n)f(2)- In other words, 4(rz) = rf(2) for every rational number r. In particular (put 2=1), f(r) = +f) for every rational mumber r. Tt follows that iff is continuous for all 2, then f(z) = =/(1) for all =. We can exsly strengthen this result by showing that (2) = 2f(1) forall z provided merely that fis continuous at some point ¢. For then f(c-+ 6) ~ fl) -» 0 as 6 —» 0; but f(c+8) ~ f(c) = f(6), 0 f(6) — 0 as 6+ 0. That is, fis continuous at 0. Now if is any real number, then fle +6) ~ f(z) = f(6) + 0 as 6 +0, so f is continuous ‘tz. Thus / is continuous throughout Rj, and we know this implies that f(2) = 2f(1)- ‘We can go sil further in weakening the hypothesis and nevertheless being able to prove that linear function is continous. Suppose that f is merely bounded on some interval, or even on some set E having the following prop- erty: the set of all differences = —y between points and y of B contains a neighborhood of 0. That is, there is a pos- 134 FUNCTIONS Chap. 2 itive § such that if |< 6, then there are points + and y jin E such that x—y = t. Then we can still conclude” that fis continuous if tis linear, and so a linear f that is bounded on a set ofthe kind just described must be of the form f(e) = er. ‘Suppose |f(z)| < M on B. For numbers ¢ that are differences between points of E, we can write [f(0)) = Ife —v)| = [FG ~ f()| < 2M. Therefore if ju < &/n, ove have [f(u)] = nL f(u)] < 2M/n. Now lets be any Teal mumber, and let r be a rational number such thet |r —s| <6/n. Then we have Is) - sf) =|fls—n) + r- 9) F(0)] 2M + 61F(0)) Since n can be as large as we please, f(s) ~ sf(1) =0. There are many sets E, other than intervals, having the property used in this proof. They include the sets of Positive Lebesgue measure (see §25), and some sets of mea- sure zero. For example, the Cantor set (page 38) has the property. The proof of this fact can be given a very inte itive geometrical form. ‘Take the usual coordinate system in Ra, and construct Cantor sets on the intervals (0, 1] of both the 2 and y axes, removing from the plane not only the middle thirds of intervals, but also all the points of the unit square that have one coordinate (at least) in 2 deleted interval, so that at each step we remove some cross-shaped sets.” (See the figure.) Consider a line with equation y = zc, where 0 <¢ <1. At each step, the line meets at least one of the squares that is not deleted in this step; these squares are closed, and nested, so their intersection contains some point (z,y) with y = 26, and both 2 and y are points of the Cantor set. See. 20 LINEAR FUNCTIONS 135 To show! that f(z) = cr for a linear function f whose ‘graph is not everywhere dense in Rz, we may appeal to an elementary fact from the theory of numbers. Let (21,2) and (41,92) be two pairs of real numbers that are not pro- portional; this means that zye # 221, or in geomettical language that the points (71,22) and (yi,12) of Ra are not on the same straight line through the origin. ‘Then if a and 6 are any two real numbers whatsoever, we can find rational multipliers ry and rz 60 that r121 +ry22 is as close as we like to a and simultaneously ritn + Faye is as clase as we like to b. To prove this, we solve the equ ur; +22 = @ and wn + vyp = b (which we can do since their determinant is not zero), and then choose r and rz close to u and v, respectively. Now suppose that f is linear and not ofthe form f(z) = 136 Functions Chap. 2 cz. The second hypothesis implies that we must be able to find points 2 and zz such that f(2i)/z1 # flz2)/20. ‘Then for any point (2,8) in Re, we can find rtional num- bers ry and rz such that f(ri2i-+raza) = rif(i)4raf(e2) difers arbitarily little fom b, and at the same time 2 + raza differs arbitrarily litle from a. ‘Thus there is a point of the graph of f as close as we please to the point (a,b) of Re. Another proof that yields some additional insight can be given as follows. Suppose that f is linear but not of the form f(z) = ex, and we wish to show that the graph of fs dense in Rp. Since f(t+r) = f(t)+rf (1) for rational ‘enough to show that f takes, arbitrarily close to the origin, values arbitrarily close to every real number, or, whats the ‘same thing, arbitrarily close to every rational number. Let A be a positive rational number and € < 1 a small positive number that we use to specify closeness. We know that f is unbounded in (0,¢); suppose, for definiteness, that 4 takes arbitrarily large postive values there. Then there is an integer n exceeding A/e such that for some s in (0,¢) we have n+1> f(s) > m. Since f(rz) = rf(z) for all rational r and all x, we have {(4s/n) = (4/n){(6), s0 A+e> A(n+1)/n> f(As/n) > A, and As/n is a point ‘ofthe interval (0,¢). We have therefore constructed a point arbitrarily close to 0 where f takes a value arbitrarily close to Ayif A> 0. IF A.< 0, there is point close to 0 where f takes a value close to —A, and since f(—z) = —f(c), the same conclusion follows, Here is an application in calculus of our theorems about linear functions.> Suppose that the limit im 2 mR I, exists for every real 2; denote it by (2). We shall now yd See. 20 LINEAR FUNCTIONS 137 show that (p(x) is necessarily of the form az-+ >. By the definition of (2), shen oe—) = im nae | non {Oia ier reas taal. mh om [re petty wan Consequently, (er — h) + (+h) = 2p(z). IF we replace z—hand z+h by z and y, this says that y(z) + o(y) = 2p(F(2-+ y))- Let (2) — o(0) = W(2); then we have ¥(2) + ¥() = (2) + ov) ~ 2000) =2(He+u)-20(0) (+) =2UEe ty). ‘This is true for every y, and so in particular for y = 0} bet 4) 50, 9 Ye) =i. Next replace 2 by 2+ y to get W(x + uv) = 20(3(2 + a). However, (+) above tape at 292 9) =e) Va). The ve) Y(v) = VlE + D); that is, Wis linear. Now ys a limit of continuous functions, and so must have points of continuity (Page 123). But we know that « linear function that has 4 point of continuity has the form (2) = (1), which is to say that (2) = 9(0) + 29(1), as asserted. 138 FuNcTions Chap. 2 Exercise 20.1. Let (2) denote® inf" so)eu, supposed to exist for every real x. Then (2) = ax. NOTES What it needed is the existence of « Hamel basis fr the real rnombern: see K. Hrbdéek and T. Jech, Introduction to Set Theory ‘Mareel Deker, New York, 1978, pp. 144-147 (a eecond edition ap ‘peared in 1984). A discontinuous linear fonction is constructed in G.'H. Hardy, 2. E Littlewood, and G. Pélya, Znepuaitis, second tition, Cambridge University Pres, 1952, p96. Hamels original paper is cited in note 4 below. See alo GS. Young, The near functional equation, American ifathematicl Monthy 65 (1958), S7- 438. Additional hatory and references are given by J. W. Green and W. Gustin, Quasheonver sets, Canadien Journal of Methematics 2 (2950), 489-507. “Por this proof, and extensions, see H. Kestelman, On the fonctional equation {lz + y) = f(2) + f(y), Fundamente Meth- cemeticae $4 (1947), 144-147. See also A. Wllansky, Additive {anetions, In Lectures on Calculus, K. O. May, ed, Holden-Day, Sen Francisco, 1967, pp. 97-124; and L. Reich, Uber Apprexim Won durch Werte addtiver Punktionen, Osterricheche Absdemie der Wissenschaften Mathematische-Netwrwissenschafliche Klasse. Siteungsberichte. Abteilung 1. Mathematische, Phystalische end ‘Techntche Wissenschaften 201 (1992), no. 1-10, 169-18 3A. Zygmund, Trgonometric Series cond edition, vol. 1, Cam= bridge University Pre, reprinted 1977, p. 238. The property wes discovered by H Stenhaus. For a simple arithmetical proof see J-F. Randolph, Distances between points of the Cantor set, Amer- ican Mathematical Monthly 47 (1040), 640-551. For related proper. ties of Cantor sets, see N.C. Base Majumder, On the distance set of the Cantor middle third set, IT, American Mathematical Monthy 72 (1965), 725-729, J. M. Brown and K. W. Lee, ‘The distance st of Cy'x Ch, Journal of the London Mathematical Society (2) 15 (1077, 551-360; Roger L, Kraft, Whats the diference between Cantor sxt?, American Mathematical Monthly 10) (1994), 640-€30, Stephen Silverman, Intervals contained in arithmetic combinations of sets, American Mathemetical Monthly 102 (1995), 351-859: Ro- ‘vigo Bamén, Sergio Plaza, and Jaime Vers, On centre Cantor sete See. 21 DERIVATIVES 139 ‘ith slbarithmeticdiference of positive Lebeogue measure, Journal ofthe London Mathematical Society (8) 52 (10995), 137-146. 4G. Hamel, Bine Basis aller Zahlen und die unstetigen Laeungen er Funktionsigeichung f(=-+) = f(z) + fly), Mathemetische An nelen 60 (1905), 459-462. i, Plancherel and G. Pélya, Sur les valeurs moyennes de fone: tons sells dfn pour toutes le valeurs dela variable, Commen- tarit Mathematici Heletics§ (1951), 114-121; reprinted in George Palye: Collected Works, Vol. HI, Joseph Hersch and Giaa-Carlo Rota, eds, MIT Press, Cambridge, MA, 198, pp. 134-141 See the following papere by R. P. Agnew: Limits af integrals Date Mathemetical Journel 9 (192), 10-19; Mean values and Fr lani integrals, Procndings of the Americen Mathematical Secety 2 (1081), 257-241; Frllant integrals and variants of the Egorofftheo- ‘em on esoentially uniform convergence, Acad. Serbe Sei Publ. Ina. ‘Mat. 6 (1954), 12-16. 21. Derivatives. We consider only functions whose do- ‘mains are intervals in Ry and whose ranges are in Ry ‘Along with the derivative! of a function f, which can be defined in the usual way, we shall consider some general- iwations that have the advantage of applying to functions that are not necessarily differentiable in the usual sense. ‘These are the four Dini derivates, for which we shall use the following notations and definitions: timoup £244) =f@), mo ing Lle+ A) ~ Hla), at tiny HH), liminf ae f(z +h)~ fle), & Mo FuNcTiOns Chap. 2 the + and — refer to right and left, respectively, and their (upper or lower) positions refer to upper and lower limits. For each 2, the four derivates exist, nite or infinite, for any function f at all It is common practice to use the phrase “the deriva. tive of f" to mean, according to context, ether the num- ber f'(2), that is, the derivative of f at the particular point 7, or the function f” whose value at 2 is the mum- ber f(z). We shall use the same ambiguous terminology for the Dini derivates. Ifwe are going to talk about them as functions, we have to extend our usual notion of function by considering funetions whose values may include -+oo of ~00. We must be careful about such generalized func- tions; there aredificulties about forming sums or products, ot (for example) about trying to differentiate them, Tt wil be found that: we do not in fact do anything ambiguous with derivates. If {*(e) = f(2), we say that there is a right-hand derivative atx, and we denote it by f(x); similarly forthe leftchand derivative f(z). Finally, the ordinary detive- tive f"(2) exits (finite or infinite) if and only if all four derivates are equal Even when f*(2) and g*(2) are both finite, we do not necessarily have (f-+0)* (2) = £*(e) + 9*(2); but if f"(@) exists (finite), we do have (f + 9)*(z) = F(z) + 9*(2) (compare page 106). Exercise 21.1. If f,(2) exists and is finite, then {is contin- ‘uous on the right at x; if f'(2) exists and is finite, then f is ‘continuous at. Exercise 21.2. Show that f may be discontinuous at 2 when F(z) exists, but is infinite. Sec. 21 DERIVATIVES Mai On the other hand, we have already seen (page 7) that « continuous function does not have to have a derivative anywhere (finite or infinite). Exercise 21.8. Show that if f(a) exits (Gnite), we can write M2) = fa) = (2 — o)ff'(0) + €(2)}, where lim. e(2) = 0. ‘The so-called “chain rule” for differentiation says that if f'(@) exists (Gnite), if g(b) = a, and if o(b) exists (f- nite), then for the function i such that (x) = f(o(z)), the derivative ¢(b) exists and is equal to f'(a)g(®). A fallacious proof proceeds as follows: as h +0, (b+ h)— ol) __ flolb-+h))~ Flot) _ (6+ A) - 6) h g(b+ h) (6) h = F)d @. Exercise 21.4. Find the fallacy; give a correct proof by using Bxercise 21:3. Exercise 21.5. Show that if f'(z) > 0, then f is increasing at 2, in the sense that there isan interval (2 ~ h,x +h) suck that if and ¢ are in the interval and <2 < t, then f(s) < S(2) < f(0). More generally, if f(z) > 0, then f is increasing ‘on the right at x, in an obvious sense Exercise 21.6. A necessary and sufficient condition for f4 (zo) to-exst (Gnite or infinite) i that for every real number K, with at most one exception, f(2) + Ke is monotonic on the right at za? Exercise 21.7. ‘The only functions f for which f(z) + Ke is ‘monotonic on (2,8) for every real K, with at most one excep- ton, are of the form f(z) = px +q on (2,8) a2 FUNCTIONS Chap. 2 ‘Note, for comparison with the preceding exercise, that, S{z) = sin has f(2) + Kx monotonic whenever |K| > 1 We say that f has a mazimum at x (an interior point of the domain of f) if there is @ neighborhood NV of z such that f(y) < f(z) for all y in N; the maximum is proper if there is a neighborhood 1V’ of x such that f(u) < f(2) for yin W" and y #2. Bxercise 21.8. Show that if f has a maximum at 2, then J*(2) c and 7'(B) g(a) in a right-hand neighborhood of a, tnd so the largest value of g between a and bis not attained ‘at a; similarly at 6); or (B) that g(a) = g(2) (since then ‘either is constant or has a proper maximum or minimum between a and 8). Hypothesis (A) leads to the observation that derivatives have the intermediate value property:® if 4 derivative takes two values, it takes every value between them. Exercise 21.9. Let f be a periodic differentiable function; let a be a given positive number; then there is @ point x such that the tangent at 2 meets the graph again at a point @ units farther along the 2-exis (thet is, f(2 +0) ~ f(2) = of'(2)). Hypothesis (B) leads to the mean-value theorem (also known as the law of the mean), which states that every ifference quotient [f(2) ~ f(y)]/(2—) of a differentiable function f is in the range of f" (the usual formulation ue FuNcTioNs Chap. 2 is—superficially—different). A proof is suggested by the diagram.” ‘The function g(t) = f(e) - F—SUs(0) - fo) takes the same value f(a) at b and at a, soit has a max- jmum at some point ¢ between @ and b; at this point, the derivative of gis 0, and so f"(e) = [f(0) - F(a)]/(0— a). ‘A less conventional procedure is to start from g(a) = (0) and infer from the universal chord theorem (page 98) that there are intervals (zy, tn) in (@,8), each half as long as its predecessor, with 9(c) = 9(tn)- ‘These intervals are nested and henoe converge to a point ¢, which will be in the open interval (a,8) if we pick the first two intervals to avoid a and b. Since we have sequence of horizontal chords of g whose endpoints approach ¢, the tangent at ¢ (ssumed to exist) must be horizontal, that is, g/(c) = 0. One should not overemphasize the existence of the termediate point ¢, whose location is usually unknown; ‘what is generally wanted in practice is that the difer Sec. 21 DeRivanives M5 ence quotient [f(0) ~ f(a)|/(6— a) is between sup f" and inf’ thisis actually an equivalent property because "has the intermediate value property. Another way of stat- ing all this is to say that the range of f' is an inter- val which contains the range of the difference quotients [f(2)-F(0)}/(2—v). The range ofthe difference quotients, however, does not necessarily contain the range of f in ‘other words, the converse of the mean-value theorem may fail, An example is given by f(x) = 23, where f’ takes the ‘value 0, whereas no difference quotient is 0. However, the least upper and greatest lower bounds of the set of values of difference quotients are the same as the corresponding ‘bounds of f': for each value of f" is a limit of difference quotients, and therefore so are the least upper and greatest lower bounds of f'. In the mean-value theorem we supposed that f is con- tinuous in the closed interval [a8]. We can, as & matter of fact, drop the continuity of f at the endpoints provided ‘that we require continuity on the right at a and on the lft at bin the case where the limits f(a*) and f(b") exist, and otherwise require nothing at all at the endpoints. However, the greater generality so obtained is illusory, sine if f(a*) does not exist and fis finite near a, then J assumes ev- ey finite value in every right-hand neighbothood ofa, 50 that. (b— a) f"(@) can have any finite value we please.!° For, if k is any number, then f(z) ~ kr does not have a right-hand limit at a, and so cannot be monotonic in a right-hand neighborhood of a. Tt therefore hss maxima ‘and minima in every right-hand neighborhood of a, and its derivative is zero at such points 2; then f*(c) = k. ‘As an application of the mean-value theorem, we now prove a theorem on the termwise differentiation of a se- ‘quence of functions. The elementary theorem on page 119 ‘demands integrability of the derivatives, and its proof uses 6 Funcrions Chap. 2 ‘the theorem on the integration of @ uniformly convergent sequence of functions; but it is possible to prove a more general theorem without using any integration at all. This is: let the functions fy, have (finite) derivatives ff, in an ‘interval 1; let the sequence {fn(a)} converge for some a in I, and let {f.} converge uniformly, say to 9. Then fe converges toa limit f, uniformly on I if I is com ‘pact, otherwise uniformly on each compact subset of I; and £2) = 9(2) for all in I. Exercise 21.10. Show, without using any integration, that a continuous function onan interval 0,9 bas an aniderivative™ ‘To prove the theorem on termwise diflerentiation, frst apply the mean-value theorem to the difference f~ fn (aC) ~ Sm (2)) ~ nC) ~ Sm) (20) (40) - fale), where ¢ is between 2 and a (and, of course, may depend fon m and n). ‘The uniform convergence of {ff} and the convergence of {fx (a)} thus male {f,} converge uniformly as long as [za] is bounded. Let f be the limit of the fn, and let ¢ be an arbitrary positive number. We have \(fa(z) — Sue) ~ (fa) = fon(a))| < fo — ae if n and m exceed some integer no. Letting m —» 00, we see that \(Sn() - f(@)) = (fala) = f(e))| <2 - ale, > m9. That is, fal2) = fale) _ Le) - H( See. 21 DERIVATIVES adr Also, |f,(a) — 9(a)] < € ifn > m; because of the conver- gence of the derivatives. Now fix an n that exceeds both np and ny. ‘Then if Jz — al is small enough, jes (2) = ra (2) _ (a) <6 and so. fed=se) =H) ~ Hilo] <2 if fe — ol is small enough. But |f,(a) ~ 9(a)] <¢, 80 f2)— Ho —9(a)| <3. ‘This inequality shows that f'(a) exists and is equal to g(a) Since we now know that (fq) converges everywhere, we can take a to be any point whatever in I, and the theorem follows. ‘Another application of the mean-value theorem yields the following theorem,!? which has a transparent geometri- cal interpretation. Suppose that f is differentiable in [a,b] and that f"(a) = f'(); then there isa point c in (a,b) such that ‘This says that if the graph of f has the same slope at @ and at, there must be a point ¢ at which the tangent passes through the initial point (a, f(a)): a sketch will make this ‘geometrically plausible. Tn proving this, we may suppose that /"a) = '(2) = 0, since otherwise we would consider the function defined by 148 FUNCTIONS Chap. 2 (2) —2f"(a). Consider the function g defined by L29=10) cect, g(a (2) ‘The function g is continuous in [2,4] and diferentiabe in (o,. We have (8) = ~9(8)/(6~a). If g(t) > 0, then we have g/(b) <0 and hence g decreasing at b (Exercise 21.5), while g(a) = 0, s0 9 attains its maximum at a point ¢ between a and b. Hence, there i a point at which ¢/c) 0. A similar argument applies if (0) < 0. If o(5) = we have g(a) = 9(8) = 0, and again ¢/(c) = 0 for some intermediate e. Since £0 _ f- fle) cma (ena * (= ‘our conclusion follows. Still another application of the mean-value theorem justifies the intuitive idea that derivatives tend to behave ‘worse than the functions from which they are derived." Bxercise 21.11. If f(z) > 0, /(0*) =, fis differentiable in (0,1), A(z) > 0, and f(s) de diverges a0, then K(J(2)/°@) is unbounded as 2 ~ 0; for example, (2)/f(z) is unbounded, and so is f'(z)/{ f(x) log f(2)}- ‘We might hope to extend the mean-value theorem to cases where the derivative does not necessarily exist, but the most obvious generalization is certainly false. For ex- ample, if f(2) = |r| we have ff (2) = —1 for 2 <0 and Fi (2) = Lfor 2 2 0, 0 that although f(1) = f(-1), wedo int have f.(2) = O for any x at all. Still ess éan we expect ‘a mean-value theorem to hold for one of the Dini derivates. Hlowever, something analogous to the mean-value theorem See. 21 DERIVATIVES us does hold for Dini derivates and can substitute for the mean-value theorem in some applications.'* ‘We shall establish the following result. Let f be con- ‘tinuous in [a,b]. If C is any number that is larger than (40) ~ F(0)|/(0~ 0), then at wncountably many points 2 ‘in (a,b) we have ft (x) < C. Similarly f,(z) > c at un- countably many points 2 if ¢< [/(8) ~ H(a]/(@~a); no, in general, the same points in both cases. The left-hand derivates have the same property ‘The proof of this proposition is much like the conven- tional proof of the mean-value theorem. Let C be any number larger than [f(b) — f(a)]/(b—«a), and consider the function g defined by (2) = f(z) — fla) - C- (2-2). ‘Then g(a) = 0, and o(2) = f(0)- f(a) -C-(b-a) <0. Let s be any number such that 0 = g(a) > s > 9(b). ‘The set of points x in fab] such that g(x) > 6 is the inverse image of a clooed get and s0 is closed, since g is continuous. ‘This set is also bounded, soit has largest point, say z,. Since gis continuous, we must have g(x.) = 2 while gz, +h) <8 when Och /(c) whenever y > 2. We can use the theorem that we have just proved to establish a result that is stronger in two directions: we do not need to suppose 150 FUNCTIONS Chap. 2 that ' exists, and we can omit countably many points. ‘More precisely, iff is continuous, and one Dini derivate is nonnegative except perhaps for countably many points, it follows that f is nondecreasing® For suppose that f(z) > 0 for a < x < b except for countably many points. (The hypothesis f, (2) > 0 ‘implies this, and the proof for f~(x) is similar.) If f fails to be nondecreasing, there must be two points z and y such that y > z and f(y) < f(z) Our generalization of the mean-value theorem, with [f(y) ~ f(z))/(y-2) < C <0, then says that there are uncountably many points between x and y at which f* is negative, contradicting our hypothesis. Exercise 21.12. The continuity of fis essential for the pre- ceding theorem: construct discontinuous funetion f for which F(a) 20 forall z, yet F(1) < #(-D). ‘We can now show that iff is continuous, then all four Dini derivates have the same upper and lower bounds in an, fnterval; more generally, the collection of difference quo- tients [f(c +h) ~ f(2)}/h has the same upper and lover bounds as the Dini derivates, provided, of course, that both « and z+ h belong to the interval in question. Sup- pose, for example, that m is a lower bound for ft. Let (2) = f(z) me. Since g*(x) > 0, the function 9 is non- decreasing. If > 0, we therefore have g(z+h)—g(2) 2 0, or in other words (ce +h) — f(z) — m(z + h) + mx > 0; that is, LE*N= 12) > ms for h > 0,50 f,(2) 2 me Sinitarly, (2) © f(e— A) ~ me + m(e —) > 0, that is, LE-M~I®) 5 om for b> 0, 90 f- (2) > f(z) > m. See. 21 penivarives: 11 Next, suppose that one derivate, say /+, is continous at z. This means thet its upper and lower bounds are arbi trarily close to f*(z) in a sufficiently small neighborhood of 1; the preceding theorem tells us that the same is true for the upper and lower bounds ofthe other three derivates. ‘This means that all four derivates coincide (with f*(z)) st the point 2. That is, if one derivate of a continuous fume- tion ts continuous at a point, then there is a derivative at that point. ‘A common error of students of calculus i to suppose ‘that /"(y) cannot exist if ims f"(z) does not exist. Exercise 21.18. The function / given by f(z) = 2" sin(1/2) for 2 4 0 and f(0) = 0 is everywhere differentiable, but the Timit tim, f'(2) does not exist Exercise 21.14. Show that /'(y) does exist if tim, f'(2) (One reason for this misunderstanding, perhaps, is that ‘a derivative, if discontinuous, is very discontinuous, so that functions with discontinuous derivatives are not commonly encountered in calculus. More precisely, a derivative can- not have a simple jump. This is to be interpreted in the following sense: if f"(z) exists at every point = of an in- terval, and (for a point y ofthis interval) the limits f"(y*) and f'(y") both exist, then both these limits are equal to J'(y). On the other hand, the example J(2) = J2| shows that the limits of f* from both sides can exist and be dif ferent at y if f"(u) does not exist. The impossibility of a simple jump for a derivative is an immediate consequence of the intermediate value property of derivatives. ‘A continuous function cannot have a derivative that is everywhere infinite, Indeed, we can say mich more: @.con- 152 FuNcrions Chap. 2 tinuous funetion must have {+(z) < -+oo on an uncount able set,® a fact that follows at once from the generalized rmean-value theorem on page 149, Indeed, the generalized rmean-value theorem says that j*(z) < C on an uncount- able set if C > (f(b) ~ f(a)]/(b— a). Tt follows from a general theorem that we shall uote later (page 155) that whether f is continuous or not, it ean have an infinite right-hand derivative f, at most on a set of measure zero. On the other hand, if we do not require f to be contin ‘ous, we can have {*(z) = -to0 at every point z. An example ofthis phenomenon can be constructed as follows.” Let real ‘numbers in [0,1] be represented in base 8 as 0.0.02 ..., where each ay 10, 1,02. If has two representations, we choose the fone that terminetes. Then we put {(2) = O.bbs... (base 2), Where bs = Lif ay = 2 and otherwise by = 0. Now, since ‘we excluded ternary representations ending in repeated 2's, the temary representation of every 2 contains an infinite sequence of digits that are 0 or 1. Let one of these O's or 1's occur at the rth ternry place. Let 2! differ from = only by having 2 as rth ternary digit; then 2” > 2, and in fect a! ~ 2 = 3°" or 2-37 Tn either ease (2) f{e) = 2" Hence Se')- Ha) eae 2 eT Since r can be arbitrarily large, it follows that f*(z) = 400. Tt can be shown that this function f is continuous except ot the points that have terminating teary expensons and in fects continuous on the ight at these points, but dacontinuous on the let ‘Another intresting result about posible value of derive ties (of not necaserly continuous functions) is that fone level set of fis dense, then every other level et offi of fit cate sory. Thetis to say, i) = A (possibly infinite) on a dense bet, then (2) ean exist and be diferent from A ot most ona set of ise catogory.* It is enough to consider the set $ where f(z) < A, See. 21 DERIVATIVES 153 the set where f"(2) > A isthe set where (—fY'(«) <—A. When A is finite, Sis contained in the union of the sete Ey. where 2 € En.m provided that |y ~ 2| < 1/m implies £0) 2) v=

You might also like