Title: Algorithms and Discrete Mathematics 20072008
1Algorithms and Discrete Mathematics 2007/2008
Ioannis Ivrissimtzis
30-Nov-2007
2Revision
- Exponentials - Logarithms
- Properties of exponentials
- Properties of logarithms
- Big-O notation
- Definition
- Basic Big-O categories
- Big-O of polynomials
- Combinatorics
- Counting principles
- Permutations - combinations
- Binomial theorem
- Pascals triangle
3Exponentials
- For a real number b?0 we define
Let b?0 be a real number and let n be a positive
integer. We define
Let b0 be a real number and let n be a positive
integer. We define as the n-th root of b. That
is, a real number x with the property
4Exponentials
- The exponential functions
- are everywhere positive
- For bgt1 they increase
- monotonically.
1
0
5Exponentials
- Properties of the real exponents
- Let a,b,x,y be real numbers, with a,bgt0. We have
6Logarithms
- For real positive numbers x,b with b?1, the
logarithm of x to the base - b, written logbx is the unique real number y that
satisfies byx. - That is, if we raise b to the power of logbx we
get x.
7Logarithms
- The logarithms are inverses
- of the exponentials.
- They are only defined on
- positive real numbers.
1
0
8Logarithms
- Proposition 4.1 Let b,r,s be positive real
numbers with b?1. We have -
-
-
- These properties are related to properties of the
exponents.
9Revision
- Exponentials - Logarithms
- Properties of exponentials
- Properties of logarithms
- Big-O notation
- Definition
- Basic Big-O categories
- Big-O of polynomials
- Combinatorics
- Counting principles
- Permutations - combinations
- Binomial theorem
- Pascals triangle
10The Big-O notation
- Let f and g be functions from the set of integers
or the set of real - numbers to the set of real numbers. We say that
f(x) is O(g(x)) if there - are constants C and k such that
- whenever x gt k. This is read as f(x) is
big-oh of g(x). - Rosen, p.180
11The Big-O notation
- Some orders that often occur in practice are
12Big-O of polynomials
- Proposition 5.1 Rosen, p.184 Any polynomial
function is Big-O its - leading degree without leading constant.
13Revision
- Exponentials - Logarithms
- Properties of exponentials
- Properties of logarithms
- Big-O notation
- Definition
- Basic Big-O categories
- Big-O of polynomials
- Combinatorics
- Counting principles
- Permutations - combinations
- Binomial theorem
- Pascals triangle
14Counting principles
- The product rule Rosen, p.336 Suppose that a
procedure can be - broken down into a sequence of two tasks. If
there are n1 ways to do - the first task and for each of these ways of
doing the first task, there are - n2 ways to do the second task, then there are
n1n2 ways to do the - procedure.
The sum rule Rosen, 338 If a task can be done
either in one of n1 ways or in one of n2 ways,
where none of the set of n1 ways is the same as
any of the set of n2 ways, then there are n1n2
ways to do the task.
15Counting principles
- Inclusion-exclusion principle Rosen, p.342 Let
A1, A2 be finite sets, - we have
16Permutations
Definition 6.2 Rosen, p.355 An ordered
arrangement of r elements of a set is called an
r-permutation.
- Theorem 6.1 Rosen, p.356 If n and r are
integers with 1 r n, then - there are
- r-permutations of a set with n distinct elements.
17Combinations
- Definition 6.4 Rosen, p.355 An r-combination
of elements of a set is - an unordered selection of r elements from the
set. - Thus, an r-combination is simply a subset with r
elements.
Theorem 6.2 Rosen, p.358 The number of
r-combinations of a set with n elements, where n
and r are integers with 0 r n, equals
18Binomial theorem
- The Binomial Theorem Rosen, p.363 Let x and y
be variables, and - let n be a nonnegative integer. Then
19Pascals triangle
By Pascals identity
20Pascals triangle