Last Minute Notes – Discrete Mathematics

28 Jun, 2021
See Last Minute Notes on all subjects here.
Implication( →): For any two propositions p and q, the statement “if p then q” is called an implication and it is denoted by p → q.if and only if(↔): For any two propositions p and q, the statement “p if and only if(iff) q” is called a biconditional and it is denoted by p ↔ q.De Morgan’s Law : Special Conditional Statements1.Implication : 2.Converse : The converse of the proposition  is 3.Contrapositive : The contrapositive of the proposition  is 4.Inverse : The inverse of the proposition  is Types of propositions based on Truth values1.Tautology – A proposition which is always true, is called a tautology.2.Contradiction – A proposition which is always false, is called a contradiction.3.Contingency – A proposition that is neither a tautology nor a contradiction is called a contingency.There are two very important equivalences involving quantifiers1.  

2.   
Rules of inferenceCombinatricsPermutation: A permutation of a set of distinct objects is an ordered arrangement of these objects.    Combination: A combination of a set of distinct objects is just a count of the number of ways a specific number of elements can be selected from a set of a certain size. The order of elements does not matter in a combination.which gives us-    Binomial Coefficients: The -combinations from a set of  elements if denoted by . This number is also called a binomial coefficient since it occurs as a coefficient in the expansion of powers of binomial expressions.Let  and  be variables and  be a non-negative integer. Then    The binomial expansion using Combinatorial symbolsSet TheoryA Set is an unordered collection of objects, known as elements or members of the set.An element ‘a’ belong to a set A can be written as ‘a ∈ A’, ‘a ∉ A’ denotes that a is not an element of the set A.Equal setsTwo sets are said to be equal if both have same elements. For example A = {1, 3, 9, 7} and B = {3, 1, 7, 9} are equal sets.NOTE: Order of elements of a set doesn’t matter.SubsetA set A is said to be subset of another set B if and only if every element of set A is also a part of other set B.Denoted by ‘⊆‘.‘A ⊆ B ‘ denotes A is a subset of B.To prove A is the subset of B, we need to simply show that if x belongs to A then x also belongs to B.To prove A is not a subset of B, we need to find out one element which is part of set A but not belong to set B.‘U’ denotes the universal set. Above Venn Diagram shows that A is a subset of B.Size of a SetSize of a set can be finite or infinite.For exampleFinite set: Set of natural numbers less than 100.
Infinite set: Set of real numbers.Size of the set S is known as Cardinality number, denoted as |S|.Note: Cardinality of a null set is 0.Power SetsThe power set is the set all possible subset of the set S. Denoted by P(S).Example: What is the power set of {0, 1, 2}?Solution: All possible subsets{∅}, {0}, {1}, {2}, {0, 1}, {0, 2}, {1, 2}, {0, 1, 2}.Note: Empty set and set itself is also the member of this set of subsets.Cardinality of power set is , where n is the number of elements in a set.Cartesian ProductsLet A and B be two sets. Cartesian product of A and B is denoted by A × B, is the set of all ordered pairs (a, b), where a belong to A and b belong to B.A × B = {(a, b) | a ∈ A ∧ b ∈ B}.The cardinality of A × B is N*M, where N is the Cardinality of A and M is the cardinality of B.Note: A × B is not the same as B × A.UnionUnion of the sets A and B, denoted by A ∪ B, is the set of distinct element belongs to set A or set B, or both.IntersectionThe intersection of the sets A and B, denoted by A ∩ B, is the set of elements belongs to both A and B i.e. set of the common element in A and B.DisjointTwo sets are said to be disjoint if their intersection is the empty set .i.e sets have no common elements.Set DifferenceDifference between sets is denoted by ‘A – B’, is the set containing elements of set A but not in B. i.e all elements of A except the element of B.ComplementThe complement of a set A, denoted by , is the set of all the elements except A. Complement of the set A is U – A.Formula:GroupA non-empty set G, (G, *) is called a group if it follows the following axiom:Closure:(a*b) belongs to G for all a, b ∈ G.Associativity: a*(b*c) = (a*b)*c ∀ a, b, c belongs to G.Identity Element:There exists e ∈ G such that a*e = e*a = a ∀ a ∈ GInverses:∀ a ∈ G there exists a-1 ∈ G such that a*a-1 = a-1*a = eRelations And Functions|A| = m and |B| = n, then1. No. of functions from A to B = nm2. No. of one to one function = (n, P, m)3. No. of onto function =nm – (n, C, 1)*(n-1)m + (n, C, 2)*(n-2)m .... +(-1)m*(n, C, n-1), if m >= n; 0 otherwise4. Necessary condition for bijective function |A| = |B|5. The no. of bijection function =n!6. No. of relations =2mn7. No. of reflexive relations =2n(n-1)8. No. of symmetric relations = 2n(n+1)/29. No. of Anti Symmetric Relations = 2n*3n(n-1)/210. No. of asymmetric relations = 3n(n-1)/211. No. of irreflexive relations = 2n(n-1)12. A relation is a partial order if    1) Reflexive
    2) Antisymmetric
    3) Transitive
13. Meet Semi Lattice :    For all a, b belongs to L a∧b exists 14. Join Semi Lattice    For all a, b belongs to L a∨b exists 15. A poset is called Lattice if it is both meet and join semi-lattice16. Complemented Lattice : Every element has complement17. Distributive Lattice : Every Element has zero or 1 complement .18. Boolean Lattice: It should be both complemented and distributive. Every element has exactly one complement.19. A relation is an equivalence if    1) Reflexive
    2) symmetric
    3) Transitive
Graph Theory1. No. of edges in a complete graph = n(n-1)/22. Bipartite Graph : There is no edges between any two vertices of same partition . In complete bipartite graph no. of edges =m*n3. Sum of degree of all vertices is equal to twice the number of edges.4. Maximum no. of connected components in graph with n vertices = n5. Minimum number of connected components =0 (null graph)
1 (not null graph) 
6. Minimum no. of edges to have connected graph with n vertices = n-17. To guarantee that a graph with n vertices is connected, minimum no. of edges required = {(n-1)*(n-2)/2 } + 18. A graph is euler graph if it there exists atmost 2 vertices of odd – degree9. Tree    -> Has exactly one path btw any two vertices
    -> not contain cycle
    -> connected
    -> no. of edges = n -1
10. For complete graph the no . of spanning tree possible = nn-211. For simple connected planar graphA graph is planar if and only if it does not contain a subdivision of K5 and K3, 3 as a subgraph.Let G be a connected planar graph, and let n, m and f denote, respectively, the numbers of vertices, edges, and faces in a plane drawing of G. Then n – m + f = 2.Let G be a connected planar simple graph with n vertices and m edges, and no triangles. Then m ≤ 2n – 4.Let G be a connected planar simple graph with n vertices, where n ? 3 and m edges. Then m ≤ 3n – 6.12.) Every bipartite graph is 2 colourable and vice versa13.) The no. of perfect matchings for a complete graph (2n)/(2nn!)14.) The no. of complete matchings for Kn.n = n!My Personal Notes
arrow_drop_upSave
Implication( →): For any two propositions p and q, the statement “if p then q” is called an implication and it is denoted by p → q.
if and only if(↔): For any two propositions p and q, the statement “p if and only if(iff) q” is called a biconditional and it is denoted by p ↔ q.
De Morgan’s Law :
 Special Conditional Statements
1.Implication : 2.Converse : The converse of the proposition  is 3.Contrapositive : The contrapositive of the proposition  is 4.Inverse : The inverse of the proposition  is 
Types of propositions based on Truth values1.Tautology – A proposition which is always true, is called a tautology.2.Contradiction – A proposition which is always false, is called a contradiction.3.Contingency – A proposition that is neither a tautology nor a contradiction is called a contingency.
There are two very important equivalences involving quantifiers
1.  

2.   

Rules of inference
Permutation: A permutation of a set of distinct objects is an ordered arrangement of these objects.
    
Combination: A combination of a set of distinct objects is just a count of the number of ways a specific number of elements can be selected from a set of a certain size. The order of elements does not matter in a combination.which gives us-
    
Binomial Coefficients: The -combinations from a set of  elements if denoted by . This number is also called a binomial coefficient since it occurs as a coefficient in the expansion of powers of binomial expressions.Let  and  be variables and  be a non-negative integer. Then
    
The binomial expansion using Combinatorial symbols
A Set is an unordered collection of objects, known as elements or members of the set.An element ‘a’ belong to a set A can be written as ‘a ∈ A’, ‘a ∉ A’ denotes that a is not an element of the set A.
Equal setsTwo sets are said to be equal if both have same elements. For example A = {1, 3, 9, 7} and B = {3, 1, 7, 9} are equal sets.
NOTE: Order of elements of a set doesn’t matter.
Subset
A set A is said to be subset of another set B if and only if every element of set A is also a part of other set B.Denoted by ‘⊆‘.‘A ⊆ B ‘ denotes A is a subset of B.
To prove A is the subset of B, we need to simply show that if x belongs to A then x also belongs to B.To prove A is not a subset of B, we need to find out one element which is part of set A but not belong to set B.
‘U’ denotes the universal set. Above Venn Diagram shows that A is a subset of B.
Size of a SetSize of a set can be finite or infinite.
For example
Finite set: Set of natural numbers less than 100.
Infinite set: Set of real numbers.
Size of the set S is known as Cardinality number, denoted as |S|.
Note: Cardinality of a null set is 0.
Power SetsThe power set is the set all possible subset of the set S. Denoted by P(S).Example: What is the power set of {0, 1, 2}?Solution: All possible subsets{∅}, {0}, {1}, {2}, {0, 1}, {0, 2}, {1, 2}, {0, 1, 2}.Note: Empty set and set itself is also the member of this set of subsets.
Cardinality of power set is , where n is the number of elements in a set.
Cartesian ProductsLet A and B be two sets. Cartesian product of A and B is denoted by A × B, is the set of all ordered pairs (a, b), where a belong to A and b belong to B.
A × B = {(a, b) | a ∈ A ∧ b ∈ B}.
The cardinality of A × B is N*M, where N is the Cardinality of A and M is the cardinality of B.
Note: A × B is not the same as B × A.
UnionUnion of the sets A and B, denoted by A ∪ B, is the set of distinct element belongs to set A or set B, or both.
IntersectionThe intersection of the sets A and B, denoted by A ∩ B, is the set of elements belongs to both A and B i.e. set of the common element in A and B.
DisjointTwo sets are said to be disjoint if their intersection is the empty set .i.e sets have no common elements.
Set DifferenceDifference between sets is denoted by ‘A – B’, is the set containing elements of set A but not in B. i.e all elements of A except the element of B.ComplementThe complement of a set A, denoted by , is the set of all the elements except A. Complement of the set A is U – A.
Formula:
GroupA non-empty set G, (G, *) is called a group if it follows the following axiom:
Closure:(a*b) belongs to G for all a, b ∈ G.
Associativity: a*(b*c) = (a*b)*c ∀ a, b, c belongs to G.
Identity Element:There exists e ∈ G such that a*e = e*a = a ∀ a ∈ G
Inverses:∀ a ∈ G there exists a-1 ∈ G such that a*a-1 = a-1*a = e
|A| = m and |B| = n, then1. No. of functions from A to B = nm2. No. of one to one function = (n, P, m)3. No. of onto function =nm – (n, C, 1)*(n-1)m + (n, C, 2)*(n-2)m .... +(-1)m*(n, C, n-1), if m >= n; 0 otherwise4. Necessary condition for bijective function |A| = |B|5. The no. of bijection function =n!6. No. of relations =2mn7. No. of reflexive relations =2n(n-1)8. No. of symmetric relations = 2n(n+1)/29. No. of Anti Symmetric Relations = 2n*3n(n-1)/210. No. of asymmetric relations = 3n(n-1)/211. No. of irreflexive relations = 2n(n-1)
12. A relation is a partial order if
    1) Reflexive
    2) Antisymmetric
    3) Transitive

13. Meet Semi Lattice :
    For all a, b belongs to L a∧b exists 
14. Join Semi Lattice
    For all a, b belongs to L a∨b exists 
15. A poset is called Lattice if it is both meet and join semi-lattice16. Complemented Lattice : Every element has complement17. Distributive Lattice : Every Element has zero or 1 complement .18. Boolean Lattice: It should be both complemented and distributive. Every element has exactly one complement.19. A relation is an equivalence if
    1) Reflexive
    2) symmetric
    3) Transitive

1. No. of edges in a complete graph = n(n-1)/22. Bipartite Graph : There is no edges between any two vertices of same partition . In complete bipartite graph no. of edges =m*n3. Sum of degree of all vertices is equal to twice the number of edges.4. Maximum no. of connected components in graph with n vertices = n5. Minimum number of connected components =
0 (null graph)
1 (not null graph) 

6. Minimum no. of edges to have connected graph with n vertices = n-17. To guarantee that a graph with n vertices is connected, minimum no. of edges required = {(n-1)*(n-2)/2 } + 18. A graph is euler graph if it there exists atmost 2 vertices of odd – degree9. Tree
    -> Has exactly one path btw any two vertices
    -> not contain cycle
    -> connected
    -> no. of edges = n -1

10. For complete graph the no . of spanning tree possible = nn-2
A graph is planar if and only if it does not contain a subdivision of K5 and K3, 3 as a subgraph.
Let G be a connected planar graph, and let n, m and f denote, respectively, the numbers of vertices, edges, and faces in a plane drawing of G. Then n – m + f = 2.
Let G be a connected planar simple graph with n vertices and m edges, and no triangles. Then m ≤ 2n – 4.
Let G be a connected planar simple graph with n vertices, where n ? 3 and m edges. Then m ≤ 3n – 6.
GATE CS
Writing code in comment?
Please use ide.geeksforgeeks.org,
generate link and share the link here.
Normal Forms in DBMS
Page Replacement Algorithms in Operating Systems
Introduction of Operating System - Set 1
Inter Process Communication (IPC)
Differences between TCP and UDP
Cache Memory in Computer Organization
Semaphores in Process Synchronization
Types of Network Topology
LRU Cache Implementation
Difference between Process and Thread