Countable Sets
Countable Sets
Countable Sets
Feedback of Students
Applications
Artificial Intelligence
Fuzzy Logic
It use sets to keep the elements of the system Sets and Propositions Experts systems
Pascal Triangle
Pascal Triangle
0 0 1 0 2 0 3 0 4 0 5 0 5 1 4 1 5 2 3 1 4 2 5 3 2 1 3 2 4 3 5 4 1 1 2 2 3 3 4 4 5 5 1 1 5 1 4 10 3 6 10 3 4 5 1 1 1 1 2 1 1 1 1
Pascal Triangle
C(n,k)
n A
A is a k-subset of (n-1)+
Recurrence Equation
S(5,4) = { S(3,2) + 3*S(2,2)} + 4*1 S(5,4) = {{S(2,1)+2*S(2,2)} + 3*1} + 4 S(5,4) = (1 + 2*1 + 3) + 4 S(5,4) = 6 + 4 S(5,4) = 10
Recurrence Equation
k n 1 2 3 4 5 1 1 15 1 7 25 1 3 6 10 1 1 1 1 1 1 2 3 4 5
Recurrence Relation
The Stirling numbers can be characterized in terms of the following recurrence relation: subject to the following initial conditions: there is only one way to partition n objects into 1 group (everything is in that group), and only one way to partition n objects into n groups (every object is a group all by itself).
Recurrence Relation
Proceeding recursively, a division of n objects a1, a2, ,an-1, an into k groups can be achieved by only one of two basic maneuvers:
We could partition the first n-1 objects into k groups, and then add object an into one of those groups. There are k * S(n-1,k). We could partition the first (n-1) objects into (k-1) groups and then add object an as a new, 1 element group. This gives an additional S(n-1,k-1) ways to create the desired partition
Countable Sets
A set is countable if there is a bijection from that set to N. An alternate way to define countable is: If there is a way to enumerate the elements of a set, then the set has the same cardinality as N and is called countable A set that is infinite and not countable is called uncountable.
Countable Sets
Example
C=Z
1 2 3 4 5 6 0 1 -1 2 -2 3 1 2 3 4 5 6
C = B*
0 0 1 00 01 10
Countable Sets
An Algorithm is a specification of a mechanical or systematic procedure for carrying out a computation. An Algorithm is a finite set of precise instructions for performing a computation or for solving a problem
Integers and Induction Recursion Algebras and proposition Algebraic Expressions Algebraic Structures Algebraic Flowchart Language Syntax and Semantics
2.
P(k) = is true For all n k; P(n) => P(n+1) Then the principle asserts that
P(n) is true for all n k.
1.
2.
The proposition is true for the smallest integer under consideration (in this case k) The assumption (inductive hypothesis) that the proposition is true for some integer n k implies that it is true for the next largest integer n + 1
Induction
Induction is like heridity: If Adam had big feet, and big feet are heriditary then every person (except possibly Eve) has/had big feet
Example
The sum of first n odd positive integers is n2 P(1) = 12 = 1 P(k) = 1 + 3 + 5 + + (2k-1) = k2 P(k+1) = 1 + 3 + 5 + + (2k-1) + (2k+1) = {1+3+5++(2k-1)} + (2k+1) = k2 + 2k + 1 = (k+1)2
Example
P(1) = 1(2) /2 = 2/2 = 1 P(n+1) = (n+1)((n+1)+1) /2 = (n+1)(n+2) / 2 = (n+1) + = (n+1) + n(n+1) /2 = (2n + 2 + n2 + n) / 2 = (n2 + 3n + 2) / 2 = (n+1)(n+2) / 2
Example
Example
=(n+1)2 + = (n+1)2 + n(n+1)(2n+1)/6
Division Algorithm
n divides m (n|m) if there exists an integer q such that m = q.n that is, if m is an integer multiple of n We can define the integer quotient m / n = tr (m.n) E.g. m = 22 and n = 5
Division Algorithm
For any integers a, b Z+, there exist unique integers q and r such that a = b.q + r and 0 r < b
Division Algorithm
Example
a = b.q + r 22 = 5.4 + 2
and 0 2 < 5
d|a , d|b c|a, c|b => c|d a = b.q1 + r1 b = r 1 . q 2 + r2 r1 = r 2 . q 3 + r3 rk-2 = rk-1. qk + rk rk-1 = rk. qk+1 0 r1 <b 0 < r2 < r 1 0 < r3 < r 2 0 < rk < rk-1 0 = rk+1
Division Algorithm
Division Algorithm
Example
Let a = 252 ; b = 180 q = a/b = tr(a/b) and 252 = 180*1 +72 180 = 72*2 + 36 72 = 36*2 + 0 So