Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Let S be a nonempty set, a partition of S is a collection C of subsets of S with

ID: 3854060 • Letter: L

Question

Let S be a nonempty set, a partition of S is a collection C of subsets of S with the following properties: 1. Every element of C is nonempty. 2. Every element of S belongs to one of members of C. 3. Every two different elements of S are disjoint: this is, if C_1, C_2 elementof C with C_1 notequalto C_2 then C_1 Intersection C_2 notequalto Phi This definition might be a little dry, but some examples may enlighten us a little: set S = {1, 2, 3, 4} and C = {{1}, {2, 4}, {3}} is a partition of S, but D_1 = {{1, 2}, {2, 4}, {3}}, D_2 = {{1}, {2, 4}}, and D_3 = {{1, 2}, {4}, {3}, {}} are not. (Why?) Assignment Given a finite set of integers S, generate all possible partitions of S Example Set S = {1, 2, 3) then the following are all partitions of S: 1. {{1}, {2}, {3}}. 2. {{1}, {2, 3}}. 3. {{1, 2}, {3}}. 4. {{1, 3}, {2}}. 5. {{1, 2, 3}}.

Explanation / Answer

If you are programming in a language having the following restrictions:

Then the set of all programs is countable, as it is a subset of all the finite strings in the language which itself is countable.

Also, what does it mean to "print out a real number"? If it has an infinite decimal expansion (e.g. an irrational number) then printing it never halts, is this a legal behavior for your program? If not then certainly you cannot write a program which prints every real number.

If you are allowed to print an infinite length output, and your program is finite then you have to calculate the number somehow, but there is only a countable number of numbers which you can compute their values. So yet again, you cannot print all the real numbers.

30down vote

If you are programming in a language having the following restrictions:

  1. There are only finitely many characters in the language.
  2. Every program is finite.

Then the set of all programs is countable, as it is a subset of all the finite strings in the language which itself is countable.

Also, what does it mean to "print out a real number"? If it has an infinite decimal expansion (e.g. an irrational number) then printing it never halts, is this a legal behavior for your program? If not then certainly you cannot write a program which prints every real number.

If you are allowed to print an infinite length output, and your program is finite then you have to calculate the number somehow, but there is only a countable number of numbers which you can compute their values. So yet again, you cannot print all the real numbers.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at drjack9650@gmail.com
Chat Now And Get Quote