Lecture 3: Counting
Rajat Mittal
?
IIT Kanpur
Counting problems arise in almost every aspect of computer science. In this lecture we will learn some
basic techniques and principles for counting.
1
Basic counting
There are two very simple rules used extens
Lattice
and
Boolean Algebra
INTRODUCTION
The English mathematician George Boole
(1815-1864) sought to give symbolic form to
Aristotle's system of logic.
His mathematical system became known as
Boolean algebra.
INTRODUCTION 2
Boole wrote a treatise on th
Isomorphism and Special Graphs
Isomorphism of Graphs
Definition: The simple graphs G1 = (V1, E1) and G2 = (V2, E2)
are isomorphic if there is a bijection (an one-to-one and
onto function) f from V1 to V2 with the property that a and
b are adjacent in G1 i
Graphs
Basic Concepts
Some applications of Graph Theory
Models for communications and electrical
networks
Models for computer architectures
Network optimization models for
operations analysis, including scheduling
and job assignment
Analysis of Finite
Formal Power Series and
Generating Functions
Notation
The notation r means summation over r, and
r assumes values from 0 (zero) to infinity ()
The notation r=k means summation over r,
and r assumes values from k to infinity ()
Formal Power Series
A(X)
Relations and Their Properties
1
What is a relation
Let A and B be sets. A binary relation R is a subset of
AB
Example
Let A be the students in a the CS major
A = cfw_Amar, Bhima, Charu, Dinesh
Let B be the courses the department offers
B = cfw_CP2,
T1: Ch 4 Relations and
Digraphs
Binary Relation
Geometric and Algebraic Representation Method
Properties
Equivalence Relations
Operations
Product Sets
An ordered pair (a,b) is a listing of the objects a
and b in a prescribed order.
If A and B are two no
Solving Recurrence Relations
Notation
The notation r means summation over r, and
r assumes values from 0 (zero) towards infinity
().
The notation r=k means summation over r,
and r assumes values from k towards infinity
().
The notation cfw_arr denotes
Todays Topic
Recurrence Relations (contd.)
Solving Recurrence Relations
Def 1. A linear homogeneous recurrence relation of
degree k (i.e., k terms) with constant coefficients
is a recurrence relation of the form
an = c1an-1+c2an-2+ckan-k
where ciR and ck0
Todays Topic
Recurrence Relations
Sequences of Numbers
There are several means of defining sequences of
numbers.
Representing by a general term, usually denoted as tn
(the nth term) enclosed in braces.
So cfw_tn denotes an entire sequence whose nth ter
Properties of Trees
A tree with n vertices has n1 edges.
An full m-ary tree with i internal vertices
contains n = mi + 1 vertices.
A rooted m-ary tree of height h is called
balanced if all leaves are at levels h or h1.
Example
Is this tree balanced?
Ex
Welcome to
Discrete Structures for
Computer Science
MATH C222
Team of Instructors: MUKESH KUMAR ROHIL
Nirmal Kumar Gupta
MATH C222 (Course Handout Part-II)
BITS_2012_1_Handout_DSCS_MAT
H_C222.doc
Course Web-site
CMT for all kinds of course information and
Class 19-20
1
Relations and directed graph
Equivalence relations
Partially ordered set(POSET)
Totally ordered set
Hasse diagram
Well ordered set
Applications
Class 19-20
2
A(binary) relation R from set A to set B is subset of AxB.
More generally an n-ary
Lecture 7: Probability
Rajat Mittal
IIT Kanpur
All of us encounter various situations in our life where we need to take a decision based on the chance/likelihood/probability
of some event. We will try to make a mathematical model of these situations and s
Lecture 4: Number theory
Rajat Mittal
IIT Kanpur
In the next few classes we will talk about the basics of number theory. Number theory studies the
properties of natural numbers and considered one of the most beautiful branches of mathematics. In this
lect
Lecture 6: Graph Properties
Rajat Mittal
IIT Kanpur
In this lecture, we will take a look at various graph properties and constructs around them. Initially we
will discuss independent sets. The bulk of the discussion will be about properties like coloring,
Lecture 2: Proofs
Rajat Mittal
IIT Kanpur
All of you must have proved lot of mathematical statements by now and have pretty good intuition
about what proofs are. So we will take an informal approach of proofs. The ideas of rigorous and correct
mathematica
Lecture 10: Quadratic residues
Rajat Mittal
IIT Kanpur
Solving polynomial equations, an xn + + a1 x + a0 = 0 , has been of interest from a long time in
mathematics. For equations up to degree 4, we have an explicit formula for the solutions. It has also b
Lecture 9: Probabilistic methods
Rajat Mittal
IIT Kanpur
This lecture will focus on probabilistic methods. This is used to prove the existence of a good structure
using probability. We will define a probability distribution over the set of structures. The
Lecture 1: Introduction to discrete mathematics
Rajat Mittal
IIT Kanpur
Please look at the course policies mentioned in the course homepage. Most importantly, any immoral
behavior like cheating and fraud will be punished with extreme measures and without
Lecture 8: Expectations
Rajat Mittal
IIT Kanpur
Many a times in probability theory, we are interested in a numerical value associated to the outcomes
of the experiment. For example, number of heads in a sequence of tosses, payout of a lottery, number of
c
Lecture 6: Graph Properties
Rajat Mittal
IIT Kanpur
In this lecture, we will take a look at various graph properties and constructs around them. Initially we
will discuss independent sets. The bulk of the discussion will be about properties like coloring,
Lecture 4: Number theory
Rajat Mittal
IIT Kanpur
In the next few classes we will talk about the basics of number theory. Number theory studies the
properties of natural numbers and is considered one of the most beautiful branches of mathematics. In this
l
Todays Topic
Recurrence Relations (contd.)
Generating Functions
Used to:
- To represent sequences efficiently by coding the
terms of a sequence as coefficients of powers of
a variable x in a formal power series
- To solve recurrence relations
- To prove
Elementary Counting
Techniques & Combinatorics
Combinatorics
the branch of discrete mathematics concerned
with determining the size of finite sets without
actually enumerating each element.
Combinatorics
The Sum Rule (task formulation):
Suppose that a
The 5-Color Theorem:
All SCP graphs are 5 colorable.
Proof: Proceed as proof of 6-Color Theorem.
Clearly, any connected simple planar graph
with 5 or fewer vertices is 5-colorable. This
forms our basis.
Assume every connected simple planar graphs
with k
PART-RKM
Question-1 ' [10]
(a) It has been observed that the cost of a certain type of process vessel is directly
proportional to the weight of the vessel. If the vessel is thin walled and spherical,
what power factor (exponent) will correlate the cost of
CS201 : Discrete Mathematics
Semester II, 2010-11, CSE, IIT Kanpur
Lecture 14 (31 January)
1
Aim of the lecture
In this lecture we continued developing more familiarity and insight into the group theory. The pace of the
lecture was quite low and it was in