§1FundamentalConcepts
Hereweintroducetheideasofsettheory,andestablishthebasicterminologyand notation.Wealsodiscusssomepointsofelementarylogicthat,inourexperience,are apttocauseconfusion.
BasicNotation
Commonlyweshallusecapitalletters A , B , ... todenotesets,andlowercaseletters a , b , todenotethe objects or elements belongingtothesesets.Ifanobject a belongstoaset A ,weexpressthisfactbythenotation
a ∈ A .
If a doesnotbelongto A ,weexpressthisfactbywriting
a / ∈ A .
Theequalitysymbol = isusedthroughoutthisbooktomean logicalidentity.Thus, whenwewrite a = b ,wemeanthat“a ”and“b ”aresymbolsforthesameobject.This iswhatonemeansinarithmetic,forexample,whenonewrites 2 4 = 1 2 .Similarly,the equation A = B statesthat“ A ”and“ B ”aresymbolsforthesameset;thatis, A and B consistofpreciselythesameobjects.
If a and b aredifferentobjects,wewrite a = b ;andif A and B aredifferentsets, wewrite A = B .Forexample,if A isthesetofallnonnegativerealnumbers,and B isthesetofallpositiverealnumbers,then A = B ,becausethenumber0belongsto A andnotto B
Wesaythat A isa subset of B ifeveryelementof A isalsoanelementof B ;and weexpressthisfactbywriting
A ⊂ B .
Nothinginthisdefinitionrequires A tobedifferentfrom B ;infact,if A = B ,itistrue thatboth A ⊂ B and B ⊂ A .If A ⊂ B and A isdifferentfrom B ,wesaythat A isa propersubset of B ,andwewrite
A B
Therelations ⊂ and arecalled inclusion and properinclusion,respectively.If A ⊂ B ,wealsowrite B ⊃ A ,whichisread“ B contains A .” Howdoesonegoaboutspecifyingaset?Ifthesethasonlyafewelements,one cansimplylisttheobjectsintheset,writing“ A isthesetconsistingoftheelements a , b ,and c .”Insymbols,thisstatementbecomes
A ={a , b , c }, wherebracesareusedtoenclosethelistofelements.
Theusualwaytospecifyaset,however,istotakesomeset A ofobjectsandsome property thatelementsof A mayormaynotpossess,andtoformthesetconsisting ofallelementsof A havingthatproperty.Forinstance,onemighttakethesetof realnumbersandformthesubset B consistingofallevenintegers.Insymbols,this statementbecomes
B ={ x | x isaneveninteger}.
Herethebracesstandforthewords“thesetof,”andtheverticalbarstandsforthe words“suchthat.”Theequationisread“ B isthesetofall x suchthat x isaneven integer.”
TheUnionofSetsandtheMeaningof“or”
Giventwosets A and B ,onecanformasetfromthemthatconsistsofalltheelements of A togetherwithalltheelementsof B .Thissetiscalledthe union of A and B and isdenotedby A ∪ B .Formally,wedefine
A ∪ B ={ x | x ∈ A or x ∈ B }.
Butwemustpauseatthispointandmakesureexactlywhatwemeanbythestatement “ x ∈ A or x ∈ B .”
InordinaryeverydayEnglish,theword“or”isambiguous.Sometimesthestatement“ P or Q ”means“ P or Q ,orboth”andsometimesitmeans“ P or Q ,butnot both.”Usuallyonedecidesfromthecontextwhichmeaningisintended.Forexample, supposeIspoketotwostudentsasfollows:
“MissSmith,everystudentregisteredforthiscoursehastakeneitheracoursein linearalgebraoracourseinanalysis.”
“Mr.Jones,eitheryougetagradeofatleast70onthefinalexamoryouwillflunk thiscourse.”
Inthecontext,MissSmithknowsperfectlywellthatImean“everyonehashadlinear algebraoranalysis,orboth,”andMr.JonesknowsImean“eitherhegetsatleast70 orheflunks,butnotboth.”Indeed,Mr.Joneswouldbeexceedinglyunhappyifboth statementsturnedouttobetrue!
Inmathematics,onecannottoleratesuchambiguity.Onehastopickjustone meaningandstickwithit,orconfusionwillreign.Accordingly,mathematicianshave agreedthattheywillusetheword“or”inthefirstsense,sothatthestatement“ P or Q ” alwaysmeans“ P or Q ,orboth.”Ifonemeans“ P or Q ,butnotboth,”thenonehasto includethephrase“butnotboth”explicitly.
Withthisunderstanding,theequationdefining A ∪ B isunambiguous;itstatesthat A ∪ B isthesetconsistingofallelements x thatbelongto A orto B ortoboth.
TheIntersectionofSets,theEmptySet,andtheMeaningof“If ... Then”
Givensets A and B ,anotherwayonecanformasetistotakethecommonpartof A and B .Thissetiscalledthe intersection of A and B andisdenotedby A ∩ B .Formally, wedefine
Butjustaswiththedefinitionof A ∪ B ,thereisadifficulty.Thedifficultyisnotinthe meaningoftheword“and”;itisofadifferentsort.Itariseswhenthesets A and B happentohavenoelementsincommon.Whatmeaningdoesthesymbol A ∩ B have insuchacase?
Totakecareofthiseventuality,wemakeaspecialconvention.Weintroducea specialsetthatwecallthe emptyset,denotedby ∅,whichwethinkofas“theset havingnoelements.”
Usingthisconvention,weexpressthestatementthat A and B havenoelementsin commonbytheequation
A ∩ B = ∅.
Wealsoexpressthisfactbysayingthat A and B are disjoint.
Nowsomestudentsarebotheredbythenotionofan“emptyset.”“How,”theysay, “canyouhaveasetwithnothinginit?”Theproblemissimilartothatwhicharose manyyearsagowhenthenumber0wasfirstintroduced.
Theemptysetisonlyaconvention,andmathematicscouldverywellgetalong withoutit.Butitisaveryconvenientconvention,foritsavesusagooddealof awkwardnessinstatingtheoremsandinprovingthem.Withoutthisconvention,for instance,onewouldhavetoprovethatthetwosets A and B dohaveelementsin commonbeforeonecouldusethenotation A ∩ B .Similarly,thenotation
C ={ x | x ∈ A and x hasacertainproperty}
couldnotbeusedifithappenedthatnoelement x of A hadthegivenproperty.Itis muchmoreconvenienttoagreethat A ∩ B and C equaltheemptysetinsuchcases.
Sincetheemptyset ∅ ismerelyaconvention,wemustmakeconventionsrelating ittotheconceptsalreadyintroduced.Because ∅ isthoughtofas“thesetwithno elements,”itisclearweshouldmaketheconventionthatforeachobject x ,therelation x ∈ ∅ doesnothold.Similarly,thedefinitionsofunionandintersectionshowthatfor everyset A weshouldhavetheequations
A ∪ ∅ = A and A ∩ ∅ = ∅.
Theinclusionrelationisabitmoretricky.Givenaset A ,shouldweagreethat ∅ ⊂ A ?Oncemore,wemustbecarefulaboutthewaymathematiciansusetheEnglish language.Theexpression ∅ ⊂ A isashorthandwayofwritingthesentence,“Every elementthatbelongstotheemptysetalsobelongstotheset A .”Ortoputitmore
formally,“Foreveryobject x ,if x belongstotheemptyset,then x alsobelongstothe set A .”
Isthisstatementtrueornot?Somemightsay“yes”andotherssay“no.”You willneversettlethequestionbyargument,onlybyagreement.Thisisastatementof theform“If P ,then Q ,”andineverydayEnglishthemeaningofthe“if then” constructionisambiguous.Italwaysmeansthatif P istrue,then Q istruealso. Sometimesthatisallitmeans;othertimesitmeanssomethingmore:thatif P isfalse, Q mustbefalse.Usuallyonedecidesfromthecontextwhichinterpretationiscorrect.
Thesituationissimilartotheambiguityintheuseoftheword“or.”OnecanreformulatetheexamplesinvolvingMissSmithandMr.Jonestoillustratetheambiguity. SupposeIsaidthefollowing:
“MissSmith,ifanystudentregisteredforthiscoursehasnottakenacoursein linearalgebra,thenhehastakenacourseinanalysis.”
“Mr.Jones,ifyougetagradebelow70onthefinal,youaregoingtoflunkthis course.”
Inthecontext,MissSmithunderstandsthatifastudentinthecoursehasnothadlinear algebra,thenhehastakenanalysis,butifhehashadlinearalgebra,hemayormaynot havetakenanalysisaswell.AndMr.Jonesknowsthatifhegetsagradebelow70,he willflunkthecourse,butifhegetsagradeofatleast70,hewillpass.
Again,mathematicscannottolerateambiguity,soachoiceofmeaningsmustbe made.Mathematicianshaveagreedalwaystouse“if ... then”inthefirstsense,so thatastatementoftheform“If P ,then Q ”meansthatif P istrue, Q istruealso,but if P isfalse, Q maybeeithertrueorfalse.
Asanexample,considerthefollowingstatementaboutrealnumbers:
Ifx > 0,thenx 3 = 0.
Itisastatementoftheform,“If P ,then Q ,”where P isthephrase“ x > 0”(called the hypothesis ofthestatement)and Q isthephrase“ x 3 = 0”(calledthe conclusion ofthestatement).Thisisatruestatement,forineverycaseforwhichthehypothesis x > 0holds,theconclusion x 3 = 0holdsaswell.
Anothertruestatementaboutrealnumbersisthefollowing:
Ifx 2 < 0,thenx = 23;
ineverycaseforwhichthehypothesisholds,theconclusionholdsaswell.Ofcourse, ithappensinthisexamplethattherearenocasesforwhichthehypothesisholds.A statementofthissortissometimessaidtobe vacuouslytrue.
Toreturnnowtotheemptysetandinclusion,weseethattheinclusion ∅ ⊂ A doesholdforeveryset A .Writing ∅ ⊂ A isthesameassaying,“If x ∈ ∅,then x ∈ A ,”andthisstatementisvacuouslytrue.
ContrapositiveandConverse
Ourdiscussionofthe“if ... then”constructionleadsustoconsideranotherpointof elementarylogicthatsometimescausesdifficulty.Itconcernstherelationbetweena statement,its contrapositive,andits converse
Givenastatementoftheform“If P ,then Q ,”its contrapositive isdefinedtobe thestatement“If Q isnottrue,then P isnottrue.”Forexample,thecontrapositiveof thestatement
Ifx > 0,thenx 3 = 0, isthestatement
Ifx 3 = 0,thenitisnottruethatx > 0.
Notethatboththestatementanditscontrapositivearetrue.Similarly,thestatement
Ifx 2 < 0,thenx = 23, hasasitscontrapositivethestatement
Ifx = 23,thenitisnottruethatx 2 < 0.
Again,botharetruestatementsaboutrealnumbers.
Theseexamplesmaymakeyoususpectthatthereissomerelationbetweenastatementanditscontrapositive.Andindeedthereis;theyaretwowaysofsayingprecisely thesamething.Eachistrueifandonlyiftheotheristrue;theyare logicallyequivalent.
Thisfactisnothardtodemonstrate.Letusintroducesomenotationfirst.Asa shorthandforthestatement“If P ,then Q ,”wewrite
P ⇒ Q ,
whichisread“ P implies Q .”Thecontrapositivecanthenbeexpressedintheform (not Q ) ⇒ (not P ), where“not Q ”standsforthephrase“ Q isnottrue.”
Nowtheonlywayinwhichthestatement“ P ⇒ Q ”canfailtobecorrectisifthe hypothesis P istrueandtheconclusion Q isfalse.Otherwiseitiscorrect.Similarly, theonlywayinwhichthestatement(not Q ) ⇒ (not P )canfailtobecorrectisif thehypothesis“not Q ”istrueandtheconclusion“not P ”isfalse.Thisisthesame assayingthat Q isfalseand P istrue.Andthis,inturn,ispreciselythesituationin which P ⇒ Q failstobecorrect.Thus,weseethatthetwostatementsareeitherboth correctorbothincorrect;theyarelogicallyequivalent.Therefore,weshallaccepta proofofthestatement“not Q ⇒ not P ”asaproofofthestatement“ P ⇒ Q .”
Thereisanotherstatementthatcanbeformedfromthestatement P ⇒ Q .Itis thestatement
Q ⇒ P ,
whichiscalledthe converse of P ⇒ Q .Onemustbecarefultodistinguishbetweena statement’sconverseanditscontrapositive.Whereasastatementanditscontrapositive arelogicallyequivalent,thetruthofastatementsaysnothingatallaboutthetruthor falsityofitsconverse.Forexample,thetruestatement
Ifx > 0,thenx 3 = 0,
hasasitsconversethestatement
Ifx 3 = 0,thenx > 0, whichisfalse.Similarly,thetruestatement
Ifx 2 < 0,thenx = 23, hasasitsconversethestatement
Ifx = 23,thenx 2 < 0, whichisfalse.
Ifitshouldhappenthatboththestatement P ⇒ Q anditsconverse Q ⇒ P are true,weexpressthisfactbythenotation
P
⇐⇒ Q , whichisread“ P holdsifandonlyif Q holds.”
Negation
Ifonewishestoformthecontrapositiveofthestatement P ⇒ Q ,onehastoknow howtoformthestatement“not P ,”whichiscalledthe negation of P .Inmanycases, thiscausesnodifficulty;butsometimesconfusionoccurswithstatementsinvolvingthe phrases“forevery”and“foratleastone.”Thesephrasesarecalled logicalquantifiers. Toillustrate,supposethat X isaset, A isasubsetof X ,and P isastatementabout thegeneralelementof X .Considerthefollowingstatement:
Foreveryx ∈ A,statementPholds. (∗)
Howdoesoneformthenegationofthisstatement?Letustranslatetheprobleminto thelanguageofsets.Supposethatwelet B denotethesetofallthoseelements x of X forwhich P holds.Thenstatement (∗) isjustthestatementthat A isasubset of B .Whatisitsnegation?Obviously,thestatementthat A is not asubsetof B ;that is,thestatementthatthereexistsatleastoneelementof A thatdoesnotbelongto B Translatingbackintoordinarylanguage,thisbecomes
Foratleastonex ∈ A,statementPdoesnothold.
Therefore,toformthenegationofstatement(∗),onereplacesthequantifier“forevery” bythequantifier“foratleastone,”andonereplacesstatement P by its negation.
Theprocessworksinreversejustaswell;thenegationofthestatement
Foratleastonex ∈ A,statementQholds, isthestatement
Foreveryx ∈ A,statementQdoesnothold.
TheDifferenceofTwoSets
Wereturnnowtoourdiscussionofsets.Thereisoneotheroperationonsetsthatis occasionallyuseful.Itisthe difference oftwosets,denotedby A B ,anddefinedas thesetconsistingofthoseelementsof A thatarenotin B .Formally,
B ={ x | x ∈ A and x / ∈ B }.
Itissometimescalledthe complement of B relativeto A ,orthecomplementof BinA . OurthreesetoperationsarerepresentedschematicallyinFigure1.1.
RulesofSetTheory
Givenseveralsets,onemayformnewsetsbyapplyingtheset-theoreticoperationsto them.Asinalgebra,oneusesparenthesestoindicateinwhatordertheoperationsare tobeperformed.Forexample, A ∪ ( B ∩ C ) denotestheunionofthetwosets A and B ∩ C ,while ( A ∪ B ) ∩ C denotestheintersectionofthetwosets A ∪ B and C .The setsthusformedarequitedifferent,asFigure1.2shows.
Figure1.2
Figure1.1
Sometimesdifferentcombinationsofoperationsleadtothesameset;whenthat happens,onehasaruleofsettheory.Forinstance,itistruethatforanysets A , B , and C theequation
holds.TheequationisillustratedinFigure1.3;theshadedregionrepresentsthesetin question,asyoucancheckmentally.Thisequationcanbethoughtofasa“distributive law”fortheoperations ∩ and ∪.
Otherexamplesofset-theoreticrulesincludethesecond“distributivelaw,”
and DeMorgan’slaws,
Weleaveittoyoutochecktheserules.Onecanstateotherrulesofsettheory,but thesearethemostimportantones.DeMorgan’slawsareeasiertorememberifyou verbalizethemasfollows:
Thecomplementoftheunionequalstheintersectionofthecomplements. Thecomplementoftheintersectionequalstheunionofthecomplements.
CollectionsofSets
Theobjectsbelongingtoasetmaybeofanysort.Onecanconsiderthesetofalleven integers,andthesetofallblue-eyedpeopleinNebraska,andthesetofalldecksof playingcardsintheworld.Someoftheseareoflimitedmathematicalinterest,we admit!Butthethirdexampleillustratesapointwehavenotyetmentioned:namely, thattheobjectsbelongingtoasetmay themselves besets.Foradeckofcardsisitself aset,oneconsistingofpiecesofpasteboardwithcertainstandarddesignsprintedon them.Thesetofalldecksofcardsintheworldisthusasetwhoseelementsare themselvessets(ofpiecesofpasteboard).
Figure1.3
Wenowhaveanotherwaytoformnewsetsfromoldones.Givenaset A ,wecan considersetswhoseelementsaresubsetsof A .Inparticular,wecanconsidertheset ofallsubsetsof A .Thissetissometimesdenotedbythesymbol P ( A ) andiscalled the powerset of A (forreasonstobeexplainedlater).
Whenwehaveasetwhoseelementsaresets,weshalloftenrefertoitasa collection ofsetsanddenoteitbyascriptlettersuchas A or B .Thisdevicewillhelpus inkeepingthingsstraightinargumentswherewehavetoconsiderobjects,andsetsof objects,andcollectionsofsetsofobjects,allatthesametime.Forexample,wemight use A todenotethecollectionofalldecksofcardsintheworld,lettinganordinary capitalletter A denoteadeckofcardsandalowercaseletter a denoteasingleplaying card.
Acertainamountofcarewithnotationisneededatthispoint.Wemakeadistinctionbetweentheobject a ,whichisan element ofaset A ,andtheone-elementset {a }, whichisa subset of A .Toillustrate,if A istheset {a , b , c },thenthestatements
a ∈ A , {a }⊂ A , and {a }∈ P ( A ) areallcorrect,butthestatements {a }∈ A and a ⊂ A arenot.
ArbitraryUnionsandIntersections
Wehavealreadydefinedwhatwemeanbytheunionandtheintersectionoftwosets. Thereisnoreasontolimitourselvestojusttwosets,forwecanjustaswellformthe unionandintersectionofarbitrarilymanysets.
Givenacollection A ofsets,the union oftheelementsof A isdefinedbythe equation
={ x | x ∈ A foratleastone A ∈ A}.
∈A
The intersection oftheelementsof A isdefinedbytheequation
Thereisnoproblemwiththesedefinitionsifoneoftheelementsof A happenstobe theemptyset.Butitisabittrickytodecidewhat(ifanything)thesedefinitionsmean ifweallow A tobetheemptycollection.Applyingthedefinitionsliterally,weseethat noelement x satisfiesthedefiningpropertyfortheunionoftheelementsof A.Soitis reasonabletosaythat
if A isempty.Ontheotherhand,every x satisfies(vacuously)thedefiningpropertyfor theintersectionoftheelementsof A.Thequestionis,every x inwhatset?Ifonehasa givenlargeset X thatisspecifiedattheoutsetofthediscussiontobeone’s“universeof discourse,”andoneconsidersonlysubsetsof X throughout,itisreasonabletolet
when A isempty.Notallmathematiciansfollowthisconvention,however.Toavoid difficulty, weshallnotdefinetheintersectionwhen A isempty
CartesianProducts
Thereisyetanotherwayofformingnewsetsfromoldones;itinvolvesthenotionofan “orderedpair”ofobjects.Whenyoustudiedanalyticgeometry,thefirstthingyoudid wastoconvinceyourselfthatafteronehaschosenan x -axisanda y -axisintheplane, everypointintheplanecanbemadetocorrespondtoauniqueorderedpair ( x , y ) of realnumbers.(Inamoresophisticatedtreatmentofgeometry,theplaneismorelikely tobe defined asthesetofallorderedpairsofrealnumbers!)
Thenotionoforderedpaircarriesovertogeneralsets.Givensets A and B ,we definetheircartesianproduct A × B tobethesetofallorderedpairs (a , b ) forwhich a isanelementof A and b isanelementof B .Formally,
× B ={(a , b ) | a ∈ A and b ∈ B }.
Thisdefinitionassumesthattheconceptof“orderedpair”isalreadygiven.Itcanbe takenasaprimitiveconcept,aswasthenotionof“set”;oritcanbegivenadefinitionin termsofthesetoperationsalreadyintroduced.Onedefinitionintermsofsetoperationsis expressedbytheequation
(a , b ) ={{a }, {a , b }};
itdefinestheorderedpair (a , b ) asacollectionofsets.If a = b ,thisdefinitionsaysthat (a , b ) isacollectioncontainingtwosets,oneofwhichisaone-elementsetandtheother atwo-elementset.The firstcoordinate oftheorderedpairisdefinedtobetheelement belongingtobothsets,andthe secondcoordinate istheelementbelongingtoonlyoneof thesets.If a = b ,then (a , b ) isacollectioncontainingonlyoneset {a },since {a , b }= {a , a }={a } inthiscase.Itsfirstcoordinateandsecondcoordinatebothequaltheelement inthissingleset.
Ithinkitisfairtosaythatmostmathematiciansthinkofanorderedpairasaprimitive conceptratherthanthinkingofitasacollectionofsets!
Letusmakeacommentonnotation.Itisanunfortunatefactthatthenotation (a , b ) isfirmlyestablishedinmathematicswithtwoentirelydifferentmeanings.Onemeaning,asanorderedpairofobjects,wehavejustdiscussed.Theothermeaningisthe oneyouarefamiliarwithfromanalysis;if a and b arerealnumbers,thesymbol (a , b ) isusedtodenotetheintervalconsistingofallnumbers x suchthat a < x < b .Mostof thetime,thisconflictinnotationwillcausenodifficultybecausethemeaningwillbe clearfromthecontext.Wheneverasituationoccurswhereconfusionispossible,we shalladoptadifferentnotationfortheorderedpair (a , b ),denotingitbythesymbol
instead.
A
Exercises
1. Checkthedistributivelawsfor ∪ and ∩ andDeMorgan’slaws.
2. Determinewhichofthefollowingstatementsaretrueforallsets A , B , C ,and D . Ifadoubleimplicationfails,determinewhetheroneortheotherofthepossible implicationsholds.Ifanequalityfails,determinewhetherthestatementbecomestrueifthe“equals”symbolisreplacedbyoneortheotheroftheinclusion symbols ⊂ or ⊃.
(a) A ⊂ B and A ⊂ C ⇔ A ⊂ ( B ∪ C ).
(b) A ⊂ B or A ⊂ C ⇔ A ⊂ ( B ∪ C )
(c) A ⊂ B and A ⊂ C ⇔ A ⊂ ( B ∩ C ).
(d) A ⊂ B or A ⊂ C ⇔ A ⊂ ( B ∩ C ).
(e) A ( A B ) = B .
(f) A ( B A ) = A B
(g) A ∩ ( B C ) = ( A ∩ B ) ( A ∩ C ).
(h) A ∪ ( B C ) = ( A ∪ B ) ( A ∪ C ).
(i) ( A ∩ B ) ∪ ( A B ) = A .
(j) A ⊂ C and B ⊂ D ⇒ ( A × B ) ⊂ (C × D ).
(k)Theconverseof(j).
(l)Theconverseof(j),assumingthat A and B arenonempty.
(m) ( A × B ) ∪ (C × D ) = ( A ∪ C ) × ( B ∪ D ).
(n) ( A × B ) ∩ (C × D ) = ( A ∩ C ) × ( B ∩ D ).
(o) A × ( B C ) = ( A × B ) ( A × C ).
(p) ( A B ) × (C D ) = ( A × C B × C ) A × D
(q) ( A × B ) (C × D ) = ( A C ) × ( B D ).
3. (a)Writethecontrapositiveandconverseofthefollowingstatement:“If x < 0, then x 2 x > 0,”anddeterminewhich(ifany)ofthethreestatementsare true.
(b)Dothesameforthestatement“If x > 0,then x 2 x > 0.”
4. Let A and B besetsofrealnumbers.Writethenegationofeachofthefollowing statements:
(a)Forevery a ∈ A ,itistruethat a 2 ∈ B
(b)Foratleastone a ∈ A ,itistruethat a 2 ∈ B .
(c)Forevery a ∈ A ,itistruethat a 2 / ∈ B .
(d)Foratleastone a / ∈ A ,itistruethat a 2 ∈ B .
5. Let A beanonemptycollectionofsets.Determinethetruthofeachofthe followingstatementsandoftheirconverses:
(a) x ∈ A ∈A A ⇒ x ∈ A foratleastone A ∈ A. (b) x ∈ A ∈A A ⇒ x ∈ A forevery A ∈ A.
(c) x ∈ A ∈A A ⇒ x ∈ A foratleastone A ∈ A.
(d) x ∈ A ∈A A ⇒ x ∈ A forevery A ∈ A
6. WritethecontrapositiveofeachofthestatementsofExercise5.
7. Givensets A , B ,and C ,expresseachofthefollowingsetsintermsof A , B , and C ,usingthesymbols ∪, ∩,and
D ={ x | x ∈ A and( x ∈ B or x ∈ C )},
E ={ x | ( x ∈ A and x ∈ B )or x ∈ C },
F ={ x | x ∈ A and( x ∈ B ⇒ x ∈ C )}
8. Ifaset A hastwoelements,showthat P ( A ) hasfourelements.Howmany elementsdoes P ( A ) haveif A hasoneelement?Threeelements?Noelements? Whyis P ( A ) calledthepowersetof A ?
9. FormulateandproveDeMorgan’slawsforarbitraryunionsandintersections.
10. Let R denotethesetofrealnumbers.Foreachofthefollowingsubsetsof R × R, determinewhetheritisequaltothecartesianproductoftwosubsetsof R.
(a) {( x , y ) | x isaninteger}.
(b) {( x , y ) | 0 < y ≤ 1}
(c) {( x , y ) | y > x }.
(d) {( x , y ) | x isnotanintegerand y isaninteger}.
(e) {( x , y ) | x 2 + y 2 < 1}.
§2Functions
Theconceptof function isoneyouhaveseenmanytimesalready,soitishardlynecessarytoremindyouhowcentralitistoallmathematics.Inthissection,wegivethe precisemathematicaldefinition,andweexploresomeoftheassociatedconcepts.
Afunctionisusuallythoughtofasa rule thatassignstoeachelementofaset A , anelementofaset B .Incalculus,afunctionisoftengivenbyasimpleformulasuch as f ( x ) = 3 x 2 + 2orperhapsbyamorecomplicatedformulasuchas f ( x ) =
k =1 x k .
Oneoftendoesnotevenmentionthesets A and B explicitly,agreeingtotake A tobe thesetofallrealnumbersforwhichtherulemakessenseand B tobethesetofallreal numbers.
Asonegoesfurtherinmathematics,however,oneneedstobemorepreciseabout whatafunctionis.Mathematicians think offunctionsinthewaywejustdescribed, butthedefinitiontheyuseismoreexact.First,wedefinethefollowing:
Definition. A ruleofassignment isasubset r ofthecartesianproduct C × D oftwo sets,havingthepropertythateachelementof C appearsasthefirstcoordinateof at mostone orderedpairbelongingto r .
Thus,asubset r of C × D isaruleofassignmentif [(c , d ) ∈ r and (c , d ) ∈ r ] ⇒[d = d ]
Wethinkof r asawayofassigning,totheelement c of C ,theelement d of D for which (c , d ) ∈ r .
Givenaruleofassignment r ,the domain ofrisdefinedtobethesubsetof C consistingofallfirstcoordinatesofelementsof r ,andthe imageset of r isdefinedas thesubsetof D consistingofallsecondcoordinatesofelementsof r .Formally,
domain r ={c | thereexists d ∈ D suchthat (c , d ) ∈ r },
image r ={d | thereexists c ∈ C suchthat (c , d ) ∈ r }.
Notethatgivenaruleofassignment r ,itsdomainandimageareentirelydetermined. Nowwecansaywhatafunctionis.
Definition. A function f isaruleofassignment r ,togetherwithaset B thatcontains theimagesetof r .Thedomain A oftherule r isalsocalledthe domain ofthe function f ;theimagesetof r isalsocalledthe imageset of f ;andtheset B iscalled the range of f †
If f isafunctionhavingdomain A andrange B ,weexpressthisfactbywriting f : A −→ B , whichisread“ f isafunctionfrom A to B ,”or“ f isamappingfrom A into B ,”or simply“ f maps A into B .”Onesometimesvisualizes f asageometrictransformation physicallycarryingthepointsof A topointsof B .
If f : A → B andif a isanelementof A ,wedenoteby f (a ) theuniqueelement of B thattheruledetermining f assignsto a ;itiscalledthe value of f at a ,or sometimesthe image of a under f .Formally,if r istheruleofthefunction f ,then f (a ) denotestheuniqueelementof B suchthat (a , f (a )) ∈ r Usingthisnotation,onecangobacktodefiningfunctionsalmostasonedidbefore, withnolackofrigor.Forinstance,onecanwrite(letting R denotetherealnumbers)
“Let f bethefunctionwhoseruleis {( x , x 3 + 1) | x ∈ R} andwhose rangeis R,” oronecanequallywellwrite
“Let f : R → R bethefunctionsuchthat f ( x ) = x 3 + 1.”
Bothsentencesspecifypreciselythesamefunction.Butthesentence“Let f bethe function f ( x ) = x 3 + 1”isnolongeradequateforspecifyingafunctionbecauseit specifiesneitherthedomainnortherangeof f .
† Analystsareapttousetheword“range”todenotewhatwehavecalledthe“imageset”of f Theyavoidgivingtheset B aname.
Definition. If f : A → B andif A 0 isasubsetof A ,wedefinethe restriction of f to A 0 tobethefunctionmapping A 0 into B whoseruleis
{(a , f (a )) | a ∈ A 0 }.
Itisdenotedby f | A 0 ,whichisread“ f restrictedto A 0 .”
E XAMPLE 1.Let R denotetherealnumbersandlet R+ denotethenonnegativereals. Considerthefunctions
f : R −→ R definedby f ( x ) = x 2 , g : R+ −→ R definedby g ( x ) = x 2 , h : R −→ R+ definedby h ( x ) = x 2 , k : R+ −→ R+ definedby k ( x ) = x 2 .
Thefunction g isdifferentfromthefunction f becausetheirrulesaredifferentsubsetsof R × R;itistherestrictionof f totheset R+ .Thefunction h isalsodifferentfrom f ,even thoughtheirrulesarethesameset,becausetherangespecifiedfor h isdifferentfromthe rangespecifiedfor f .Thefunction k isdifferentfromallofthese.Thesefunctionsare picturedinFigure2.1.
Restrictingthedomainofafunctionandchangingitsrangearetwowaysofforminganewfunctionfromanoldone.Anotherwayistoformthecompositeoftwo functions.
Definition. Givenfunctions f : A → B and g : B → C ,wedefinethe composite g ◦ f of f and g asthefunction g ◦ f : A → C definedbytheequation ( g ◦ f )(a ) = g ( f (a ))
Formally, g ◦ f : A → C isthefunctionwhoseruleis {(a , c ) | Forsome b ∈ B , f (a ) = b and g (b ) = c }
Weoftenpicturethecomposite g ◦ f asinvolvingaphysicalmovementofthepoint a tothepoint f (a ),andthentothepoint g ( f (a )),asillustratedinFigure2.2.
Notethat g ◦ f isdefinedonlywhentherangeof fequals thedomainof g .
Figure2.1
E XAMPLE 2.Thecompositeofthefunction f : R → R givenby f ( x ) = 3 x 2 + 2and thefunction g : R → R givenby g ( x ) = 5 x isthefunction g ◦ f : R → R givenby
Thecomposite f ◦ g canalsobeformedinthiscase;itisthequitedifferentfunction f ◦ g : R → R givenby
.
Definition. Afunction f : A → B issaidtobe injective (or one-to-one)ifforeach pairofdistinctpointsof A ,theirimagesunder f aredistinct.Itissaidtobe surjective (or f issaidtomap A onto B )ifeveryelementof B istheimageofsomeelement of A underthefunction f .If f isbothinjectiveandsurjective,itissaidtobe bijective (oriscalleda one-to-onecorrespondence).
Moreformally, f isinjectiveif
[ f (a ) = f (a )] ⇒[a = a ], and f issurjectiveif
[b ∈ B ] ⇒[b = f (a ) foratleastone a ∈ A ].
Injectivityof f dependsonlyontheruleof f ;surjectivitydependsontherange of f aswell.Youcancheckthatthecompositeoftwoinjectivefunctionsisinjective,andthecompositeoftwosurjectivefunctionsissurjective;itfollowsthatthe compositeoftwobijectivefunctionsisbijective.
If f isbijective,thereexistsafunctionfrom B to A calledthe inverse of f .Itis denotedby f 1 andisdefinedbyletting f 1 (b ) bethatuniqueelement a of A for which f (a ) = b .Given b ∈ B ,thefactthat f issurjectiveimpliesthatthere exists suchanelement a ∈ A ;thefactthat f isinjectiveimpliesthatthereis onlyone such element a .Itiseasytoseethatif f isbijective, f 1 isalsobijective.
E XAMPLE 3.Consideragainthefunctions f , g , h ,and k ofFigure2.1.Thefunction f : R → R givenby f ( x ) = x 2 isneitherinjectivenorsurjective.Itsrestriction g tothe nonnegativerealsisinjectivebutnotsurjective.Thefunction h : R → R+ obtainedfrom f
Figure2.2
bychangingtherangeissurjectivebutnotinjective.Thefunction k : R+ → R+ obtained from f byrestrictingthedomain and changingtherangeisbothinjectiveandsurjective, soithasaninverse.Itsinverseis,ofcourse,whatweusuallycallthe square-rootfunction. Ausefulcriterionforshowingthatagivenfunction f isbijectiveisthefollowing, whoseproofislefttotheexercises:
Lemma2.1. Let f : A → B .Iftherearefunctions g : B → A and h : B → A suchthat g ( f (a )) = a forevery a in A and f (h (b )) = b forevery b in B ,then f is bijectiveand g = h = f 1 .
Definition. Let f : A → B .If A 0 isasubsetof A ,wedenoteby f ( A 0 ) theset ofallimagesofpointsof A 0 underthefunction f ;thissetiscalledthe image of A 0 under f .Formally,
f ( A 0 ) ={b | b = f (a ) foratleastone a ∈ A 0 }
Ontheotherhand,if B0 isasubsetof B ,wedenoteby f 1 ( B0 ) thesetofallelements of A whoseimagesunder f liein B0 ;itiscalledthe preimage of B0 under f (orthe “counterimage,”orthe“inverseimage,”of B0 ).Formally, f 1 ( B0 ) ={a | f (a ) ∈ B0 }
Ofcourse,theremaybenopoints a of A whoseimagesliein B0 ;inthatcase, f 1 ( B0 ) isempty.
Notethatif f : A → B isbijectiveand B0 ⊂ B ,wehavetwomeaningsforthe notation f 1 ( B0 ).Itcanbetakentodenotethe preimage of B0 underthefunction f ortodenotethe image of B0 underthefunction f 1 : B → A .Thesetwomeanings givepreciselythesamesubsetof A ,however,sothereis,infact,noambiguity. Somecareisneededifoneistousethe f and f 1 notationcorrectly.Theoperation f 1 ,forinstance,whenappliedtosubsetsof B ,behavesverynicely;itpreserves inclusions,unions,intersections,anddifferencesofsets.Weshallusethisfactfrequently.Buttheoperation f ,whenappliedtosubsetsof A ,preservesonlyinclusions andunions.SeeExercises2and3.
Asanothersituationwherecareisneeded,wenotethatitisnotingeneraltruethat f 1 ( f ( A 0 )) = A 0 and f ( f 1 ( B0 )) = B0 .(Seethefollowingexample.)Therelevant rules,whichweleavetoyoutocheck,arethefollowing:If f : A → B andif A 0 ⊂ A and B0 ⊂ B ,then
A 0 ⊂ f 1 ( f ( A 0 )) and f ( f 1 ( B0 )) ⊂ B0 .
Thefirstinclusionisanequalityif f isinjective,andthesecondinclusionisanequality if f issurjective.
E XAMPLE 4.Considerthefunction f : R → R givenby f ( x ) = 3 x 2 + 2(Figure2.3).
Let [a , b ] denotetheclosedinterval a ≤ x ≤ b .Then f 1 ( f ([0, 1])) = f 1 ([2, 5]) =[−1, 1], and f ( f 1 ([0, 5])) = f ([−1, 1]) =[2, 5].
Exercises
1. Let f : A → B .Let A 0 ⊂ A and B0 ⊂ B .
(a)Showthat A 0 ⊂ f 1 ( f ( A 0 )) andthatequalityholdsif f isinjective.
(b)Showthat f ( f 1 ( B0 )) ⊂ B0 andthatequalityholdsif f issurjective.
2. Let f : A → B andlet A i ⊂ A and Bi ⊂ B for i = 0and i = 1.Showthat f 1 preservesinclusions,unions,intersections,anddifferencesofsets:
(a) B0 ⊂ B1 ⇒ f 1 ( B0 ) ⊂ f 1 ( B1 ).
(b) f 1 ( B0 ∪ B1 ) = f 1 ( B0 ) ∪ f 1 ( B1 )
(c) f 1 ( B0 ∩ B1 ) = f 1 ( B0 ) ∩ f 1 ( B1 ).
(d) f 1 ( B0 B1 ) = f 1 ( B0 ) f 1 ( B1 ).
Showthat f preservesinclusionsandunionsonly:
(e) A 0 ⊂ A 1 ⇒ f ( A 0 ) ⊂ f ( A 1 ).
Figure2.3
(f) f ( A 0 ∪ A 1 ) = f ( A 0 ) ∪ ( A 1 ).
(g) f ( A 0 ∩ A 1 ) ⊂ f ( A 0 ) ∩ f ( A 1 );showthatequalityholdsif f isinjective.
(h) f ( A 0 A 1 ) ⊃ f ( A 0 ) f ( A 1 );showthatequalityholdsif f isinjective.
3. Showthat(b),(c),(f),and(g)ofExercise2holdforarbitraryunionsandintersections.
4. Let f : A → B and g : B → C .
(a)If C 0 ⊂ C ,showthat ( g ◦ f ) 1 (C 0 ) = f 1 ( g 1 (C 0 ))
(b)If f and g areinjective,showthat g ◦ f isinjective.
(c)If g ◦ f isinjective,whatcanyousayaboutinjectivityof f and g ?
(d)If f and g aresurjective,showthat g ◦ f issurjective.
(e)If g ◦ f issurjective,whatcanyousayaboutsurjectivityof f and g ?
(f)Summarizeyouranswersto(b)–(e)intheformofatheorem.
5. Ingeneral,letusdenotethe identityfunction foraset C by i C .Thatis,define i C : C → C tobethefunctiongivenbytherule i C ( x ) = x forall x ∈ C .
Given f : A → B ,wesaythatafunction g : B → A isa leftinverse for f if g ◦ f = i A ;andwesaythat h : B → A isa rightinverse for f if f ◦ h = i B .
(a)Showthatif f hasaleftinverse, f isinjective;andif f hasarightinverse, f issurjective.
(b)Giveanexampleofafunctionthathasaleftinversebutnorightinverse.
(c)Giveanexampleofafunctionthathasarightinversebutnoleftinverse.
(d)Canafunctionhavemorethanoneleftinverse?Morethanonerightinverse?
(e)Showthatif f hasbothaleftinverse g andarightinverse h ,then f is bijectiveand g = h = f 1 .
6. Let f : R → R bethefunction f ( x ) = x 3 x .Byrestrictingthedomainand rangeof f appropriately,obtainfrom f abijectivefunction g .Drawthegraphs of g and g 1 .(Thereareseveralpossiblechoicesfor g .)
§3Relations
Aconceptthatis,insomeways,moregeneralthanthatoffunctionistheconceptof a relation.Inthissection,wedefinewhatmathematiciansmeanbyarelation,and weconsidertwotypesofrelationsthatoccurwithgreatfrequencyinmathematics: equivalencerelations and orderrelations.Orderrelationswillbeusedthroughoutthe book;equivalencerelationswillnotbeuseduntil§22.
Definition. A relation onaset A isasubset C ofthecartesianproduct A × A .
If C isarelationon A ,weusethenotation xCy tomeanthesamethingas ( x , y ) ∈ C .Wereadit“ x isintherelation C to y .”
Aruleofassignment r forafunction f : A → A isalsoasubsetof A × A .Butit isasubsetofaveryspecialkind:namely,onesuchthateachelementof A appearsas thefirstcoordinateofanelementof r exactlyonce. Any subsetof A × A isarelation on A .
E XAMPLE 1.Let P denotethesetofallpeopleintheworld,anddefine D ⊂ P × P by theequation
D ={( x , y ) | x isadescendantof y }
Then D isarelationontheset P .Thestatements“ x isintherelation D to y ”and“ x is adescendantof y ”meanpreciselythesamething,namely,that ( x , y ) ∈ D .Twoother relationson P arethefollowing:
B ={( x , y ) | x hasanancestorwhoisalsoanancestorof y }, S ={( x , y ) | theparentsof x aretheparentsof y }
Wecancall B the“bloodrelation”(punintended),andwecancall S the“siblingrelation.” Thesethreerelationshavequitedifferentproperties.Thebloodrelationshipissymmetric, forinstance(if x isabloodrelativeof y ,then y isabloodrelativeof x ),whereasthe descendantrelationisnot.Weshallconsidertheserelationsagainshortly.
EquivalenceRelationsandPartitions
An equivalencerelation onaset A isarelation C on A havingthefollowingthree properties:
(1)(Reflexivity) xCx forevery x in A .
(2)(Symmetry)If xCy ,then yCx .
(3)(Transitivity)If xCy and yCz ,then xCz .
E XAMPLE 2.AmongtherelationsdefinedinExample1,thedescendantrelation D is neitherreflexivenorsymmetric,whilethebloodrelation B isnottransitive(Iamnota bloodrelationtomywife,althoughmychildrenare!)Thesiblingrelation S is,however, anequivalencerelation,asyoumaycheck.
Thereisnoreasononemustuseacapitalletter—orindeedaletterofanysort— todenotearelation,eventhoughit is aset.Anothersymbolwilldojustaswell. Onesymbolthatisfrequentlyusedtodenoteanequivalencerelationisthe“tilde” symbol ∼.Statedinthisnotation,thepropertiesofanequivalencerelationbecome (1) x ∼ x forevery x in A .
(2)If x ∼ y ,then y ∼ x
(3)If x ∼ y and y ∼ z ,then x ∼ z
Therearemanyothersymbolsthathavebeendevisedtostandforparticularequivalencerelations;weshallmeetsomeoftheminthepagesofthisbook.
Givenanequivalencerelation ∼ onaset A andanelement x of A ,wedefinea certainsubset E of A ,calledthe equivalenceclass determinedby x ,bytheequation
E ={ y | y ∼ x }.
Notethattheequivalenceclass E determinedby x contains x ,since x ∼ x .Equivalenceclasseshavethefollowingproperty:
Lemma3.1. Twoequivalenceclasses E and E areeitherdisjointorequal.
Proof. Let E betheequivalenceclassdeterminedby x ,andlet E betheequivalence classdeterminedby x .Supposethat E ∩ E isnotempty;letybeapointof E ∩ E . SeeFigure3.1.Weshowthat E = E .
Bydefinition,wehave y ∼ x and y ∼ x .Symmetryallowsustoconcludethat x ∼ y and y ∼ x ;fromtransitivityitfollowsthat x ∼ x .Ifnow w isanypointof E , wehave w ∼ x bydefinition;itfollowsfromanotherapplicationoftransitivitythat w ∼ x .Weconcludethat E ⊂ E .
Thesymmetryofthesituationallowsustoconcludethat E ⊂ E aswell,sothat E = E
Givenanequivalencerelationonaset A ,letusdenoteby E thecollectionofall theequivalenceclassesdeterminedbythisrelation.Theprecedinglemmashowsthat distinctelementsof E aredisjoint.Furthermore,theunionoftheelementsof E equals allof A becauseeveryelementof A belongstoanequivalenceclass.Thecollection E isaparticularexampleofwhatiscalledapartitionof A :
Definition. A partition ofaset A isacollectionofdisjointnonemptysubsetsof A whoseunionisallof A
Studyingequivalencerelationsonaset A andstudyingpartitionsof A arereally thesamething.Givenanypartition D of A ,thereisexactlyoneequivalencerelation on A fromwhichitisderived.
Theproofisnotdifficult.Toshowthatthepartition D comesfromsomeequivalencerelation,letusdefinearelation C on A bysetting xCy if x and y belongto thesameelementof D .Symmetryof C isobvious;reflexivityfollowsfromthefact thattheunionoftheelementsof D equalsallof A ;transitivityfollowsfromthefact thatdistinctelementsof D aredisjoint.Itissimpletocheckthatthecollectionof equivalenceclassesdeterminedby C ispreciselythecollection D .
Toshowthereisonlyonesuchequivalencerelation,supposethat C 1 and C 2 are twoequivalencerelationson A thatgiverisetothesamecollectionofequivalence classes D .Given x ∈ A ,weshowthat yC 1 x ifandonlyif yC 2 x ,fromwhichwe concludethat C 1 = C 2 .Let E 1 betheequivalenceclassdeterminedby x relativeto therelation C 1 ;let E 2 betheequivalenceclassdeterminedby x relativetotherelation C 2 .Then E 1 isanelementof D ,sothatitmustequaltheuniqueelement D of D that
Figure3.1
contains x .Similarly, E 2 mustequal D .Nowbydefinition. E 1 consistsofall y such that yC 1 x ;and E 2 consistsofall y suchthat yC 2 x .Since E 1 = D = E 2 ,ourresultis proved.
E XAMPLE 3.Definetwopointsintheplanetobeequivalentiftheylieatthesame distancefromtheorigin.Reflexivity,symmetry,andtransitivityholdtrivially.Thecollection E ofequivalenceclassesconsistsofallcirclescenteredattheorigin,alongwiththeset consistingoftheoriginalone.
E XAMPLE 4.Definetwopointsoftheplanetobeequivalentiftheyhavethesame y -coordinate.Thecollectionofequivalenceclassesisthecollectionofallstraightlinesin theplaneparalleltothe x -axis.
E XAMPLE 5.Let L bethecollectionofallstraightlinesintheplaneparalleltotheline y =− x .Then L isapartitionoftheplane,sinceeachpointliesonexactlyonesuchline. Thepartition L comesfromtheequivalencerelationontheplanethatdeclaresthepoints ( x 0 , y0 ) and ( x 1 , y1 ) tobeequivalentif x 0 + y0 = x 1 + y1 .
E XAMPLE 6.Let L bethecollectionof all straightlinesintheplane.Then L isnot apartitionoftheplane,fordistinctelementsof L arenotnecessarilydisjoint;twolines mayintersectwithoutbeingequal.
OrderRelations
Arelation C onaset A iscalledan orderrelation (ora simpleorder,ora linearorder) ifithasthefollowingproperties:
(1)(Comparability)Forevery x and y in A forwhich x = y ,either xCy or yCx
(2)(Nonreflexivity)Forno x in A doestherelation xCx hold.
(3)(Transitivity)If xCy and yCz ,then xCz Notethatproperty(1)doesnotbyitselfexcludethepossibilitythatforsomepairof elements x and y of A ,boththerelations xCy and yCx hold(since“or”means“one ortheother,orboth”).Butproperties(2)and(3)combineddoexcludethispossibility;forifboth xCy and yCx held,transitivitywouldimplythat xCx ,contradicting nonreflexivity.
E XAMPLE 7.Considertherelationonthereallineconsistingofallpairs ( x , y ) ofreal numberssuchthat x < y .Itisanorderrelation,calledthe“usualorderrelation,”onthe realline.Alessfamiliarorderrelationonthereallineisthefollowing:Define xCy if x 2 < y 2 ,orif x 2 = y 2 and x < y .Youcancheckthatthisisanorderrelation.
E XAMPLE 8.ConsideragaintherelationshipsamongpeoplegiveninExample1.The bloodrelation B satisfiesnoneofthepropertiesofanorderrelation,andthesiblingrelation S satisfiesonly(3).Thedescendantrelation D doessomewhatbetter,foritsatisfies both(2)and(3);however,comparabilitystillfails.Relationsthatsatisfy(2)and(3)occur oftenenoughinmathematicstobegivenaspecialname.Theyarecalled strictpartial order relations;weshallconsiderthemlater(see§11).