Download presentation
Published byJanel Brown Modified over 9 years ago
1
Course Outline Book: Discrete Mathematics by K. P. Bogart Topics:
Sets and statements Symbolic Logic Relations functions Mathematical Induction Counting Techniques Recurrence relations Trees Graphs Grades: First: 25% Second 25% Final 50% *Note: The outline is subject to change
2
Discrete Mathematics Is the one we use to analyze discrete processes that are carried out in a step-by-step fashion.
3
Algorithm A list of step by step instructions for carrying out a process
4
Chapter 1 Sets and Statements
5
Statements A declarative sentence can be true, false or ambiguous
A statement is an unambiguous declarative sentence that is either true or false
6
Example 5 plus 7 is 12 5 plus 7 is 5 5 plus 7 is large
Did you have coffee this morning?
7
Sets Set: an unambiguous description of a collection of objects EX:
Set of outcomes for flipping a coin S={H,T} However, the list of outcomes might be: HTTTHHH…….
8
Sets Members of a set are called elements
aA “a is an element of A” “a is a member of A” aA “a is not an element of A” EX: Set of +ve integers S={x |x>0} 3 S -5 S
9
Sets Universe of a statement is the set whose elements are discussed by the statement EX: x multiplied by x is +ve The universe could be: Set of +ve integers Set of –ve integers Set of all integers Flipping a coin -Universe: {H,T}
10
Sets Note: P, q, r, s are used to represent statements
X, y, z, w are used to represent variables
11
Compound Statements Simple statements are represented by symbols EX:
P: x is a positive integer Compound statements are represented by symbols+ logical connectives Logical Connectives: Conjunction AND. Symbol ^ Inclusive disjunction OR Symbol v Exclusive disjunction OR Symbol (+) Negation Symbol ¬ Implication Symbol
12
Compound Statements Example:
-I will take calculas1 and I will take physics class. Represented as: p ^ q I will have coffee or I will have tea Represented as: p v q Ali is at school or Ali is at home Represented as: p (+) q p: x is greater than 2 ¬p: x is not greater than 2 -George is at school and either Sue is at store or Sue is at home. P ^( q (+) r ) *Note the use of parentheses ( see example 4 page 7).
13
Truth sets The set of all values of x that make a symbolic statement p(x) true is called the truth set of the proposition p. (the set of all values in the universe that makes p true). The symbolic statements p(x) & q(x) are equivalent if they have the same truth sets.
14
Truth sets EX: Universe: The result of flipping 2 coins
P: the result has one head q: the result has one tail P and q are equivalent since they have the same truth sets.
15
Fundamental Principle of Set Equality
To show that the sets T and S are equal, we may show that each element in T is an element in S and vice versa. EX: Universe: 300 coin flips P: the result has 2 H’s q: the result has 298 T’s Show that p and q are equivalent.
16
Finite and infinite sets
- Examples: A = {1, 2, 3, 4} B = {x | x is an integer, 1 < x < 4} D = {dog, cat, horse} Infinite sets Z = {integers} = {…, -3, -2, -1, 0, 1, 2, 3,…} Natural numbers N = {0, 1, 2, 3, …} S={x| x is a real number and 1 < x < 4} = [0, 4]
17
Section 1.2: Sets
18
Venn diagrams A Venn diagram provides a graphic view of sets and their operations: union, intersection, difference and complements can be identified
19
Set operations Given two sets X and Y the following are operations that can be performed on them: Union Intersection Complement Difference
20
Union The union of X and Y is defined as the set A B = { x | x A or x B}
21
Intersection The intersection of X and Y is defined as the set: X Y = { x | x X and x Y} Two sets X and Y are disjoint if X Y = X Y xy X Y X Y =
22
Complement The complement of a set Y contained in a universal set U is the set Yc = U – Y Y Yc U
23
Difference The difference of two sets X – Y = { x | x X and x Y}
The difference is also called the relative complement of Y in X X Y X-y
24
Properties of set operations
Theorem : Let U be a universal set, and A, B and C subsets of U. The following properties hold: a) Associativity: (A B) C = A (B C) (A B) C = A (B C) b) Commutativity: A B = B A A B = B A
25
Properties of set operations (2)
c) Distributive laws: A(BC) = (A B) (A C) A(BC) = (A B) (A C) d) Identity laws: AU=A A = A e) Complement laws: AAc = U AAc =
26
Properties of set operations (3)
f) Idempotent laws: AA = A AA = A g) Bound laws: AU = U A = h) Absorption laws: A(AB) = A A(AB) = A
27
Properties of set operations (4)
i) Involution law: (Ac)c = A j) 0/1 laws: c = U Uc = k) De Morgan’s laws for sets: (AB)c = AcBc (AB)c = AcBc
28
Demorgan’s Laws for sets
~(A B) = (~A) (~B) -Proof: To be discussed in class ~(A B) = (~A) (~B) -Proof: exercise
29
Theorem Let p and q be statements and let P and Q be their truth sets, then: - P Q is the truth set of p^q (proof discussed in class) P Q is the truth set of pvq ~P is the truth set of ¬p
30
Example: Venn Diagrams
Show that P (Q R) = (P Q) (P R) Using Venn diagrams - See example 9 page 18
31
Subsets It is a relation between sets ( not operation)
A set S is a subset of set T if each element in S is also an element in T. Examples: A = {3, 9}, B = {5, 9, 1, 3}, is A B ? A = {3, 3, 3, 9}, B = {5, 9, 1, 3}, A = {1, 2, 3}, B = {2, 3, 4}, is A B ? Equality: X = Y if X Y and Y X
32
Subsets using Venn diagrams
The ellipse is a subset of the circle
33
Theorem Let R and S be two sets then: - R and S are subsets of R S
R S is a subset of both R and S R S = S if and only if R S R S=R if and only if R S
34
Example Prove that R (S T) S (R T)
35
The Empty Set The empty set has no elements.
Also called null set or void set. EX: P is the truth set of p: x>0 Q is the truth set of q: x<0 The truth set of p^q = P Q= P and Q are disjoint sets
36
Section 1.3 Determining the Truth of Symbolic Statements
37
Truth tables Truth tables are used to determine truth or falsity of compound statements
38
Truth table of conjunction
p ^ q is true only when both p and q are true. p q p ^ q T F
39
Truth table of disjunction
p q is false only when both p and q are false p q p v q T F
40
Exclusive disjunction
p (+) q is true only when p is true and q is false, or p is false and q is true. Example: p = "John is programmer, q = “John is a lawyer" p (+) q = "Either John is a programmer or John is a lawyer" p q p (+) q T F
41
Negation Negation of p: in symbols ¬p
¬ p is false when p is true, ¬ p is true when p is false Example: p = "John is a programmer" ¬ p = "It is not true that John is a programmer" p ¬ p T F
42
Truth tables Examples: Truth table for : ¬pvq (pvq) ^ ¬(p^q)
43
Definition 2 statements are equivalent if their truth tables have the same final column
44
Exercise Use the truth tables to find out whether the following statements are equivalent: (p^q) v (p^r) P^(qvr)
45
Section 1.4 The Conditional Connectives
46
Conditional propositions and logical equivalence
A conditional proposition is of the form “If p then q” In symbols: p q Example: p = " John is a programmer" q = " Mary is a lawyer " p q = “If John is a programmer then Mary is a lawyer"
47
Truth table of p q p q is true when both p and q are true
or when p is false
48
P q is equivalent to ¬pvq
Recall: 2 statements are equivalent if their truth tables have the same final column Exercise: Show that p q and ¬p v q are equivalent. Note: it is important to represent the implication() and the exclusive OR(+) using other connectives (^,V, ¬), why??
49
Example Rewrite without arrows: ¬r ( s v (r ^ t))
50
Example Consider flipping a coin 3 times
p is the statement “ the first flip comes up heads” q is the statement “there are at least 2 heads” Find the truth sets of p, q, pq Answer: {TTT,TTH,THT,THH,HHH,HHT,HTH}
51
Section 1.5 Boolean Algebra:
When we apply known laws about set operations to derive other ones algebraically, we say we are doing Boolean Algebra.
52
Example: ( not required)
Use Boolean algebra to prove the unique inverse property. if x P= and x P = U then x= ~P x = x U (identity law) = x (P ~P) (inverse law) = (x P) (x ~P) (distributive law) = (x ~P) (given property) = (P ~P) (x ~P) (Inverse law) = (P x) ~P (distributive law) = U ~P (given property) = ~P (Identity law)
53
Boolean Algebra for statements
A formula says that 2 truth sets are equal corresponds to a formula saying that 2 statements are equivalent ( so all set laws are translated directly into statement laws). The statements about a universe satisfy the following rules: a) Associativity: (p V q) V r = p v (q v r) (p ^ q) ^ r = p ^ (q^ r) b) Commutativity: p V q = q V p p ^ q = q ^ p
54
Boolean Algebra for Statements
c) Distributive laws: p ^ (q v r) = (p ^ q) V (p ^ r) p V ( q ^ r) = (p V q) ^(p V r) d) Identity laws: p^1=p pV0 = p e) Complement laws: p V ¬p = p ^ ¬p = 0 f) Idempotent laws: p V p = p p ^ p = p g) Bound laws: p V 1 = p ^ 0 = 0 h) Absorption laws: p v ( p ^ q ) = p p ^ ( p v q) = p
55
i) Double negation law: ¬ ¬p = p
j) De Morgan’s laws: ¬(p V q) = ¬ p ^ ¬ q ¬(p ^ q) = ¬ p V ¬q
56
Final Example Simplify: (¬ ¬r) V (s V (r ^ t)) Answer : r V s
(¬ (r ^ s) V (r V s)) ^ (¬ (r V s) V (r ^ s)) Answer: (¬r ^ ¬s ) V (r ^ s)
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.