Final Exam Study Guide
Match logically equivalent expressions. p ⊕ q
(p ∨ q) ∧¬ (p ∧ q)
A true-false test contains 25 questions. In how many different ways can the 25-question test be answered?
2²⁵ There are 2 choices for each of the 25 questions. The choices are independent from each other. Thus, there are 2²⁵ choices.
Consider the following version of the Fibonacci sequence: f₀ = 1, f₁ = 1 and fₙ = fₙ₋₁ + fₙ₋₂ for all n ≥ 2. Find f₄.
5
True or False? 5x² is O(x²).
true
0 ∈ S; for all x ∈ S, x+2 ∈ S.
x is the set of non-negative even integrs
Evaluate 1010 OR 0011. Here, OR is the bitwise logical or, acting on bitstrings.
1011
At College X, 130 students were surveyed about their electronic possessions. 90 had a cell phone. 50 had an iPod. 80 had a computer. 70 had a cell phone and a computer. 20 had a cell phone and an iPod. 16 had a computer and an iPod. 13 had a cell phone, an iPod, and a computer. How many students had at least one of the devices?
127.0 (with margin: 0.0)
In a class of 3000 students, the professor gives a multiple choice quiz with 4 questions, possible answers A,B,C, D or E. Each student answers each question. Among the 3000 students, at least how many students will turn in the exact same answer sheet, except for identifying information?
5 There are 5⁴=625 possible answers for the quiz. Considering 625 · 4 = 2600 625 · 5 = 3125, we realize that there must be 5 students who will turn in the exact same answer sheet. This is because if each answer sheet was only turned in by at most 4 students, there would at most be 625 · 4 = 2600 students total.
Identify the converse, inverse and contrapositive of: If it's a square, then it is a rectangle. Inverse:
If its not a square, then its not a rectangle.
Determine the truth of the following statement: ∃x ∃y (x ≠ y ∧ x² = y²) The domain is the set of positive integers.
false The statement is false because x² = y² implies x = ±y. Thus, x ≠ y and x² = y² implies x = -y, but that is impossible for positive integers x and y.
True or false? "Mozart is a great composer" is a proposition.
fasle - 0pinion
True or False? x³ is O(3ˣ).
true
Find the smallest integer k so that S(n^3+n^4)/(n^2+1 ) is order of nᵏ.
2
Enter the smallest integer n so that the following function is O(xⁿ). f(x)=x²(x³ + 1)+x⁵log(x).
6
Identify the converse, inverse and contrapositive of: If it's a square, then it is a rectangle. Contrapositive:
If it's a not a rectangle, then its not a square.
Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 X 2 X X 3 X X X How many elements can be added to R so that R is still anti-symmetric? a. None b. One c. Two d. Three
a
Consider the following argument: If it rains, then the streets are wet. The streets are not wet. Therefore, it is not raining. It the argument is valid, select the valid argument form. If it is not valid, then select "fallacy". a. Conjunction. b. Fallacy. c. Modus Tollens. d. Modus Ponens
c
What is the correct meaning of the logical expression p→q∨r∧s ? a. ((p→q)∨r)∧s b. (p→(q∨r))∧s c. p→(q∨(r∧s)) d. p→((q∨r)∧s)
c
What is the negation of "all planets in our solar system are explored"? a. All non-planetary bodies in our solar system are explored. b. All planets outside of our solar system are unexplored. c. There is a planet in our solar system that is unexplored. d. All planets in our solar system are unexplored. e. There exists an explored, non-planetary body outside of our solar system. f. There is a planet outside of our solar system that is unexplored. g. There is a non-planetary body in our solar system that is unexplored. h. All non-planetary bodies outside of our solar system are unexplored. i. There exists a non-planetary body outside of our solar system that is unexplored.
c
Identify the argument form that is at the heart of each of the following arguments, other than modus ponens, or identify the argument as a fallacy. Students who have a disability or whose parents earn less than $30k per year can apply for the scholarship. Gentry's parents make less than $30k per year. Therefore, Gentry does not have a disability.
fallacy
Identify the argument form that is at the heart of each of the following arguments, other than modus ponens, or identify the argument as a fallacy. Domestic students can apply for scholarship A. International students can apply for scholarship B. Therefore, all students can apply for scholarship A or B.
resolution
p ∨ q
¬p → q
True or false? "Absence of evidence of illness is necessary for a clean bill of health from a doctor" means that if you have no evidence of illness, a doctor will give you a clean bill of health.
false The statement is false. "Absence of evidence of illness is necessary for a clean bill of health from a doctor" only means that lack of evidence of illness is a precondition for receiving a clean bill of health from a doctor, but may not guarantee it.
True of false? Uniqueness of prime factorization makes it impossible to have positive integers p and q with LaTeX: 6^p=9^q.
true It is impossible because a number with prime factors 2 and 3 cannot be equal to a number with only the prime factor 3.
True or false? "Having money is a necessary condition for happiness" means that having money guarantees happiness.
false "Having money is a necessary condition for happiness" does not mean that having money guarantees happiness. It means that having money is a precondition for happiness. It is saying that if you are happy, then you must have money.
Determine the truth of the quantified statement ∀x ∃y (xy > x). The domain of discourse is the set of real numbers.
false The statement is false because for x = 0, no such y can exist. With x = 0, xy = 0 regardless of what y is, and 0 is not greater than 0.
Find the lowest integer k so that 1⁵ + 2⁵ + 3⁵ + 4⁵ + 5⁵ + ... + n⁵ is O(nᵏ).
6
What is the minimum number of people you need to guarantee that there are three among them who were born on the same day? There are 366 possible birthdays.
733.0 (with margin: 0.0) With 2·366 = 732 people, there could be exactly two people that were born on each birthday. With 733 people, that is impossible, because up to two people for each birthday can only add up to 732 people total.
Identify the converse, inverse and contrapositive of: If it's a square, then it is a rectangle. Converse:
Converse: If its a rectangle, then it's a square.
Match the linear, constant-coefficient, homogeneous recurrence relation represented by its characteristic polynomial, to the general solution of the recurrence. (r-1)(r-2) a. aₙ=p₁+p₂·2ⁿ b. aₙ=p₁(-i)ⁿ+p₂(i)ⁿ c. aₙ=p₁+(p₂+p3n)·2ⁿ d. aₙ=p₁+p₂+(p3+p4n)·2ⁿ
a
At a job fair, the organizers offer some free gifts to the participants. There are 4 different bags, 3 different water bottles and 5 different binders. Each participant can choose a bag and a water bottle and a binder. How many different choices does a participant have? a. 4·3·5 b. 4+3+5 c. 4!·3!·5! d. 4!+3!+5! e. None of these.
a
Find the smallest integer k, so that f(x)=x^10 ·ln(x^4) +x^19 is big-O of xᵏ. Correct!
19
Select the smallest k so that f(x)=x·(lnx)⁴+x² is big-O of O(xᵏ).
2
True or false? The two statements (p ∧ q) → r and (p → r) ∨ (q → r) are logically equivalent.
True
Consider the statement "Unless you stop smoking, you will get sick". Select which one of the following statements are logically equivalent to that conditional above. a. You will get sick if you keep smoking. b. Continuing to smoke is sufficient to get sick. c. Continuing to smoke is necessary to get sick. d. If you get sick, that means you didn't stop smoking. e. You will get sick only if you keep smoking. Recall that "p only if q" does NOT mean "if q, then p". It means the converse: "If p, then q".
a, b
Let S be a set of strings defined recursively as follows : 1. 0 ∈ S. 2. For all a ∈ S, 2a0 ∈ S and 2aa1 ∈ S. (If a and b are strings then ab is the concatenation of a and b. For instance, if a = 0211 and b = 201 then ab = 0211201.) Let S₀ be the initial population. Let S₁ be all elements obtained by applying the recursion rule once to S₀. Let S₂ be all elements obtained by applying the recursion rule once to S₁. Check all elements of S ₀∪ S₁ ∪ S₂, and only those. a. 0 b. 200 c. 2001 d. 22000 e. 220010 f. 22002001 g. 2200120011 h. 22001 i. 220011 j. 201 k. 220000 l. 2200020001 m. 22200101 n. 2200100
abcdefg
Match the linear, constant-coefficient, homogeneous recurrence relation represented by its characteristic polynomial, to the general solution of the recurrence. r²+1 a. aₙ=p₁+p₂·2ⁿ b. aₙ=p₁(-i)ⁿ+p₂(i)ⁿ c. aₙ=p₁+(p₂+p3n)·2ⁿ d. aₙ=p₁+p₂+(p3+p4n)·2ⁿ
b
True or False? We can block-convert from binary (base-2) to octal (base-8) by grouping the binary digits into blocks of 4, possibly after padding with 0s on the left, to make the number of binary digits a multiple of 4. The block size 4 is due to 8/2 = 4.
false
p ∧ q
¬(¬p ∨¬q)
At a pet owner's meeting of 150 people, there are exactly 67 dog owners, and 56 cat owners. A sociologist wants to interview at least 10 people with unusual pets, which she defines as any pet that is neither cat nor dog. How many people does she need to select at random to interview, at least, to guarantee 10 people with unusual pets?
133.0 (with margin: 0.0) Let U be the universal set here, i.e. all pet owners at the meeting; A the set of dog owners at the meeting and B the set of cat owners at the meeting. Then |U| = 150; |A| = 67 and |B| = 56. By the inclusion-exclusion principle,|A∪B| = |A| + |B| - |A ∩ B| ≤ |A| + |B| = 123. The sociologist will have to interview 133 people to guarantee at least 10 pet owners who are not dog or cat owners.
Determine the truth of the quantified statement ∀x ∃y (xy > x). The domain of discourse is the set of positive real numbers.
True Suppose any positive real number x is given. Pick y = 2. Then xy = 2x. 2x > x since x > 0. [Adding x to both sides of x > 0 produces x + x > x, or 2x > x.]
Negate the statement ∃x (1 ≤ x < 2). a. ∀x ( 1 > x ≥ 2 ) b. ∃x (1 > x ∨ x ≥ 2) c. ∃x (1 > x ≥ 2) d. ∀x ( 1 ≥ x > 2 ) e. ∀x ( x ≥ 2 ∨ x < 1 ) d. ∀x ( x > 2 ∨ x ≤ 1 )
e
If f(x) is O(x³) and g(x) is O(x⁴), then what is the best we can say about f(x)+g(x)? Find the "lowest" big-O estimate that is guaranteed by the given information. a. f(x)+g(x) is O(x³). b. f(x)+g(x) is O(x⁴). c. f(x)+g(x) is O(x⁷). d. f(x)+g(x) is O(x¹²).
b
Suppose A and B are sets. No additional information is available. What can you say about |A∪B|? a. |A∪B| = |A| + |B| b. |A∪B| ≤ |A| + |B| c. |A∪B| ≥ |A| + |B| d. |A∪B| = |A| ∪ |B|
b
If p and q are distinct primes. Find the number of positive divisors of p2·q1 .
6
Negate the statement ∃y∀x(x>y). a. ∀y∃x ( ¬x > ¬y ) b. ∃y∀x ( ¬x > ¬y ) c. ∀y∃x ( x ≤ y )
c
Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 2 X 3 X X Check all properties that this relation has. a. Reflexive b. Symmetric c. Anti-symmetric d. Transitive
c d
Four authors are going together on a speaking tour. In each city, they hold one event for one evening where each of them speaks for the same amount of time. In consideration of the fact that the first and the last speaker of the evening have a special impact on the audience, they decide to rotate through all possible lineups, and to visit exactly as many cities as are needed to realize each lineup. How many cities are they visiting?
24.0 (with margin: 0.0) The lineups are ordered selections of 4 from 4 people without repetitions, aka permutations. The number of cities is 4! = 24.
The intersection of two sets contains 10 elements, and the union 45. What is the sum of the elements in the two sets? Correct!
55
Identify the argument form that is at the heart of each of the following arguments, other than modus ponens, or identify the argument as a fallacy. Students whose parents earn less than $30k per year can apply for the scholarship. Gentry plays chess, and his parents make less than $30k per year. Therefore, Gentry can apply for the scholarship.
simplification
True or False? Two polynomials p(x) and q(x) are of the same order exactly when their degrees are equal.
true
True or false? Any exponential function f(n) = aⁿ with a > 1 is NOT big-O of any polynomial function p(n).
true Exponential functions (with base > 1) grow faster than all polynomial functions. If 1< a, then aˣ is NOT a big-O of p(x), but p(x) is big-O of aˣ. .
True or False? If there are 22 people in a room, then it is certain that at least 4 of them were born on the same day of the week. True False
true If there were at most 3 born on each day of the week, there would be at most 21 people, because there are only 21 days of the week.
1 ∈ S; for all x ∈ S, 2x ∈ S.
the set of powers of 2
Let F be the relation on the set of commercial airports defined by: If x and y are two such airports, xRy if there is a commercial flight that flies from A directly to B (non-stop). Check all properties that the relation has and use common sense. a. Transitive b. Symmetric c. Reflexive d. Anti-symmetric
b F is not reflexive because airlines do not offer direct connections from an airport to itself. It is true that one can fly from an airport A to itself by flying to some other airport B and then taking a return flight, but then there is a stop at B. F is symmetric. When an airline offers a flight from A to B, there is always a return flight from B to A. F is not anti-symmetric because there are different airports A,B with flights from A to B and B to A. F is not transitive because when you can fly non-stop from A to B, and non-stop from B to C, it is not guaranteed that you can fly non-stop from A to C.
1 ∈ S; for all x ∈ S, x+2 ∈ S and x-2 ∈ S.
x is the set of odd integers
1 ∈ S and 2 ∈ S; for all x ∈ S, x+3 ∈ S.
x is the set of positive integers that are not divisible by 3
Match logically equivalent expressions. p ↔ q
¬ ( (p → q) → ¬(q → p) )
A device produces random 64-bit integers at a rate of one billion per second. After how many years of running is it unavoidable that the device produces an output for the second time? Round to the nearest number of years.
585.0 (with margin: 0.0) The device is capable of producing 2⁶⁴ many different outputs. The device produces 10⁹ outputs per second. Therefore, it produces 10⁹ · 3600 · 24 · 365.25 outputs per year. By the pigeonhole principle, it is unavoidable that the device has produced at least one output twice when it has produced 2⁶⁴ + 1 outputs. It takes the device (2⁶⁴ + 1)/(10⁹ · 3600 · 24 · 365.25) years to produce 2⁶⁴ + 1 outputs. That is 584.54 years, or 585 years when rounded to the nearest year. (Approximating the length of the year to 365 year does not change the rounded answer here.)
Select which of the following explains the conditional correctly. There may be more than one correct choice. For full credit on this question, you must check all correct explanations and none of the incorrect ones. (Precisely when means if and only if. Disjunctions are inclusive.) a. The conditional is false precisely when the premise is true and the conclusion is false. b. The conditional is true precisely when the premise is false or the conclusion is true. c. The conditional is false precisely when the premise is false and the conclusion is true. d. The conditional is true precisely when the premise is true or the conclusion is false.
a and b The conditional is best understood as a promise: if A happens, then B will happen. The only way a promise can be considered broken is if A happened but B did not happen. In all other cases, we consider the promise kept, including the case where A did not happen. Then, the promise was never put to the test, and is considered kept by default. Therefore, the promise is not only considered kept if A and B are both true, but also if A is false, regardless of whether B is true or false in that case.
A master's degree is necessary to work for Acme corporation. Check all logically equivalent forms of this statement. a. If you work for Acme, you have a master's. b. If you have a master's degree, then you work for Acme. c. If you don't have a master's degree, you don't work for d. If you don't work for Acme, you don't have a master's degree.
a and c
Check all the properties that the relation R = { (a,b) | ab ≥ 0 } has on the set of integers. a. Reflexive b. Symmetric c. Transitive d. Antisymmetric e. An equivalence relation
a b
FIX Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 X 2 X 3 X Which elements need to be added to make R reflexive? Check all that are required, and only those. a. (1,1) b. (3,3) c. No matter what elements are added, the relation cannot become reflexive.
a b
Let P be the relation defined on the set of all American citizens by xPy if and only if x and y are registered for the same political party. Not being registered or being registered as an independent also counts as a registration. Check all properties that P has. Correct Answer a.symmetric b. reflexive c. anti-symmetric d. transitive
b, d The relation is reflexive because you (generic meaning) always have the same party registration as yourself. The relation is symmetric because the property of two individuals sharing the same party registration is inherently symmetric; it only refers to a set of two individuals with no reference to an order. The relation is not anti-symmetric because there are non-trivial symmetric pairs. Clearly, there are different people who share the same party registration. The relation is transitive because if x and y have the same party registration, and y and z have the same party registration, then so do x and z.
Given real numbers x and y, find the inverse of x > 0 ∧ y ≥ 0 → x + y > 0. a. x < 0 ∧ y ≤ 0 → x + y < 0 b. ¬x > 0 ∧ ¬y ≥ 0 → ¬x + ¬y > 0 c. x ≤ 0 ∨ y < 0 → x + y ≤ 0 d. x ≤ 0 ∧ y < 0 → x + y ≤ 0 e. x < 0 ∨ y ≤ 0 → x + y < 0
c
Match the linear, constant-coefficient, homogeneous recurrence relation represented by its characteristic polynomial, to the general solution of the recurrence. (r-1)²(r-2)² a. aₙ=p₁+p₂·2ⁿ b. aₙ=p₁(-i)ⁿ+p₂(i)ⁿ c. aₙ=p₁+(p₂+p3n)·2ⁿ d. aₙ=p₁+p₂+(p3+p4n)·2ⁿ
d
FIX . THIS . Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 X 2 X 3 X X Also, let S be the relation on {1,2,3} given by the following table: S 1 2 3 1 X X 2 X 3 X Determine which of the following tables represents the relation S ∘ R. ? 1 2 3 1 X 2 X 3 X X X ? 1 2 3 1 X X X 2 X 3 X ? 1 2 3 1 X X 2 3 X You Answered ? 1 2 3 1 2 X X X 3 X
...b
Consider the statement If you break it, then you fix it. Select which one of the following statements is NOT logically equivalent to that conditional. a. You didn't break it unless you are fixing it. b. Breaking it is a sufficient condition for having to fix it. c. Fixing it is a necessary condition for having broken it. d. If you are not fixing it, then you didn't break it. e. You fix it only if you break it.
...e
Select which one of the following statements is logically equivalent to (p∨q) → r . a. ( p→ r ) ∧ ( q→ r ) b. ( p→r ) ∨ ( q→ r ) c. ¬( p ∨ q ) → r d. (¬p∨¬q ) ∨ r e. None of these.
A You can find the correct answer by doing a truth table, or, more efficiently, by using logical equivalences, the distributive and commutative properties, and De Morgan's law: (p∨q)→r ≡¬(p∨q)∨r ≡(¬p∧¬q)∨r ≡(¬p∨r)∧(¬q∨r) ≡(p→r)∧(q→r)
A and B are sets. A contains 12 elements, B contains 8. A and B have 5 elements in common. How many elements are in A∪B ?
15
How many distinct ternary logical operators are there? A ternary logical operator is an operator that takes three inputs, p, q and r, and for each truth configuration of the inputs, outputs true or false. Recall that a logical operator is defined by its truth table.
256 p can be true or false. Independently of p, q can be true or false. Independently of p and q, r can be true or false. By the multiplication principle, there are 8 different configurations of truth values that a ternary operator acts on (i.e. the truth table of such an operator has 8 rows, not counting the header). Put differently, a ternary logical operator is a function from a domain of 8 elements to a domain of 2 elements. There are 2⁸ = 256 such functions, again by the multiplication principle.
Given that the product of two positive integers is 400, and their greatest common divisor is 5, what is their least common multiple?
80
Find the smallest positive integer n so that f(x) = x7·log(x7 ) + x8·log(x1 ) is big-O of xⁿ.
9
True or False? There is a smallest real number k so that xlog(x) is O(xᵏ).
False xlog(x) is not O(x) because xlog(x)/x = log(x) goes to infinity. On the other hand, xlog(x) is O(xᵏ) for any k > 1. This is because xlog(x) / xᵏ = log(x) / xᵏ⁻¹, which goes to zero as x goes to infinity. (Use L'Hospital's rule to justify this statement.) It's a calculus fact that any positive power of x goes faster to infinity than log(x), so the denominator in log(x) / xᵏ⁻¹ (x has a positive power) "wins".
True or False? If P is the predicate defined by P(x,y) = "x likes y" (x and y are from the set of all people), then the meaning of the formal statement ∃y ∀x P(x,y) is "Everyone likes y". True False
False ∃y ∀x P(x,y) means "someone is liked by everyone", or "there is someone who is liked by everyone". y is not a person, it is a variable that represents a person. The proposed translation "Everyone likes y" confuses a variable that represents a person with an actual person, and it ignores the existential quantification that y is subject to. "Everyone loves y" is not even a proposition, because y is a free variable. Observe that the original statement is a proposition. It has no free variables because y is subject to the existential quantifier.
Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 2 X X 3 X X Which elements need to be added to R to make it symmetric? Check all that are required. a. (1,3) b. (3,2) c. (1,1) d. (2,1) e. (1,2)
a b
The conditional p → q of two propositions p and q can be expressed as follows (check all that are logically equivalent). Recall that ⊕ represents the exclusive or. a. (p ↔ q) ∨ q b. ¬ p ∨ q c. ¬( q → p ) d. ¬(p ⊕ q) ∨ q e. ¬q → ¬p
a b d e
Suppose R = { (1,1), (2,3), (3,4), (4,2), (2,4) } is a relation on the set S = { 1, 2, 3, 4 }. Check each ordered pair that is in the the relation R∘R. a. (1,1) b. (2,2) c. (1,4) d. (2,4) e. (3,2) f. (4,4) g. (4,3) h. (4,2) i. (2,1) j. (3,4) k. (2,3) l. (3,3)
a b d e f g
Check all functions f(x) that are O(x²). a. f(x) = log(xˣ) b. f(x) = x³/2 + x² c. f(x) = ⌊x+2⌋ · ⌈x⌉ d. f(x)=2x1.9 +2x-1.9 e. f(x) = (x⁴+2x+3)/(x²-2) f. f(x) = (x⁵+2x+3)/(x²-2) g. f(x) = x² · log(x) h. f(x) = 2ˣ +x²
a c d e
Find a big-O estimate of f(x)=(3x² + xlog(x²) + x²log(x²))·(πx³ + 2x + 4) + (x² + x⁴log(x)) such that in your estimate f(x) is O(g(x)) and g(x) is a simple function of the smallest order. a. g(x)=x⁵log(x) b. g(x)=x⁶ c. g(x)=x⁴log(x) d. g(x)=x⁵ e. None of these functions are big O estimates of f(x).
a
Find a closed-form representation of the following recursively defined sequence: aₙ = 9aₙ₋₂ for n ≥ 2, with initial conditions a₀ = 6 and a₁ = 12. a. aₙ =(-3)ⁿ +5·3ⁿ b. aₙ =3·(3)ⁿ +3 c. aₙ= 6 · 3ⁿ - 2n· 3ⁿ d. aₙ = 0.75 · 9ⁿ + 5.25 e. None of these.
a
Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 X 2 X X 3 X X X Select the table that describes the relation R². a. R 1 2 3 1 X X 2 X X X 3 X X X b. R 1 2 3 1 X X X 2 X X X 3 X X X c. R 1 2 3 1 X X 2 X X X 3 X X d. R 1 2 3 1 X X 2 X X 3 X
a
Let the relation R on {1,2,3} be given by the following table: R 1 2 3 1 X X X 2 X X 3 X X X Observe that R is not transitive, because 2R3 and 3R1, but not 2R1. The removal of which one of the following elements would make R transitive? a. (2,3) b. (1,1) c. (3,3) d. (2,2)
a
What is the negation of "Chris has a cat or a dog"? a. Chris has neither cat nor dog. b. Chris doesn't have a pet. c. Chris doesn't have a cat, or Chris doesn't have a dog. d. Chris has a cat but not a dog, or Chris has a dog but not a cat.
a
How many 3 letter "words" can be created from the letters ABCDEFG when 1. repetition allowed 2. repetition is not allowed? The words do not have to meaningful. a. 1.7³ 2. P(7,3) = 7·6·5 b. 1. 3⁷ 2. P(7,3) = 7·6·5 c. 1. 7+7+7 = 21 2. 7+6+5 = 18 d. 1. 7³ 2. C(7,3) = 7·6·5/(3·2·1) e. None of these.
a 1. There are 7 choices for each of the three letters. There are 7 choices for the first letter and 7 choices for the second letter and 7 choices for the third letter. 2. There are 7 choices for the first letter and 6 choices for the second letter and 5 choices for the third letter.
How many different four-digit code words can be constructed using the digits 0,1,2,3,4,5,6,7,8,9 with no repeated digits that start with either 0 or 9? a. 2·(9·8·7) b. 9·7·8 c. 2·(9+8+7) d. 2·(9·9·9) e. None of these.
a If the first digit is 0, then rest of the digits can be picked P(9,3) ways. If the first digit is 9, then the rest of the digits can be picked P(9,3) ways. Now we use the sum rule: the digits can be picked in P(9,3) + P(9,3) ways.
Consider the two statements 1. (p → q) ∧ (p → ¬q) 2. (p → q) ∧ (¬p → q). a. neither is a contradiction. b. 2. is a contradiction, 1. is not. c. They are both contradictions. d. 1. is a contradiction, 2. is not.
a You can see that 1 is not a contradiction because p false makes it true. You can see that 2 is not a contradiction because q true makes it true.
Identify the argument form that is at the heart of each of the following arguments, other than modus ponens, or identify the argument as a fallacy. Students can apply for the scholarship only if they have a disability or their parents earn less than $30k per year. Clancy can apply for the scholarship. Clancy has no disability. Therefore, Clancy's parents make less than $30k per year.
disjunctive syllogism
There are 10 applied math and 13 pure math professors on the faculty in the mathematics department. How many ways are there to select a committee of 7 members if the committee needs to have 4 applied math and 3 pure math members? a. C(10,4) · C(13,3) = 10·9·8·7/4! · 13·12·11/3! b. C(10,4) + C(13,3) = 10·9·8·7/4! + 13·12·11/3! c. P(10,4) · P(13,3) = 10·9·8·7 · 13·12·11 d. P(10,4) + P(13,3) = 10·9·8·7 + 13·12·11 e. None of these.
a We select 4 applied math people out of 10 (order of the selection does not matter). For each selection of the 4-member-applied math committee, we select pure math people out of the 13 (again the order of the selection does not matter).
True or False? There is a smallest real number a so that 3ˣx is O(aˣ).
false Let us use the notations f(x) = 3ˣx and g(x) = 3ˣ. f(x) is not O(g(x)) because f(x)/g(x)=x goes to infinity as x goes to infinity. On the other hand, f(x) is O(aˣ) for any real number a > 3. For example, f(x) is O(3.01ˣ). You can see that this is true by considering the quotient again: f(x)/g(x) = (3/a)ˣ·x. 3/a is less than 1, hence (3/a)ˣ goes to zero as x goes to infinity. Exponential decay beats polynomial growth (this is a calculus fact), so even (3/a)ˣ·x still goes to zero. Since 3ˣx is O(aˣ) for all a > 3, but not for a = 3, there is no smallest real number a so that 3ˣx is O(aˣ).
Let R be the relation defined on the set of all processors by: xRy iff x can carry out every instruction that y can carry out. For example, every x86-compatible processor can carry out all the instructions of the original Intel 8086 processor. Thus, if x is such a processor, and y is the 8086 processor, then xRy. As processor families evolved, more instructions were typically added to the original instruction set. For example, modern x86 compatible processors can carry out more instructions than the 8086. There are examples of different processors that have the same instruction set. For example, the CMOS 6502 and 6510 processors have the same instruction set. Check all properties that this relation has. a. Transitive b. Reflexive c. Symmetric d. Anti-symmetric
a,b Associated with every processor x is the set of instructions i(x) it can carry out (the "instruction set"). Thus, our relation is defined on the set of processor by xRy iff i(x)⊇i(y). R is reflexive because any superset relation is reflexive due to A⊇A for all sets A. Thus i(x)⊇i(x) is the case for all processors x. R is not symmetric. Again, this follows from general principle: Any superset relation fails to be symmetric if the set of sets it is defined on contains at least two sets that are in a proper subset relation.This is the case here: as the hint indicates, there are x86-compatible processors that contain more instructions than the original 8086. Thus, if x is such a processor, and y is the 8086 processor, i(x)⊇i(y) holds, but i(y)⊇i(x) does not. This means that xRy holds, but yRx does not. Any superset relation is transitive: A⊇B and B⊇C always implies A⊇C. Thus i(x)⊇i(y) and i(y)⊇i(z) imply i(x)⊇i(z) for any processors x,y,z. R is not anti-symmetric, even though the superset relation is. This is possible because the function i is not 1-1. If we let x be the 6502 processor, and y be the 6510, then x≠y but i(x)=i(y). Thus i(x)⊇i(y) and i(y)⊇i(x). This means xRy and yRx with x≠y, which makes R not anti-symmetric.
Identify the argument form that is at the heart of each of the following arguments, other than modus ponens, or identify the argument as a fallacy. Students who have a disability or whose parents earn less than $30k per year can apply for the scholarship. Gentry's parents make less than $30k per year. Therefore, Gentry can apply for the scholarship.
addition
If f(x) is O(x³) and g(x) is O(x⁴), then what is the best we can say about f(x)·g(x)? Find the "lowest" big-O estimate that is guaranteed by the given information. a. f(x)·g(x) is O(x³). b. f(x)·g(x) is O(x⁴). c. f(x)·g(x) is O(x⁷). d. f(x)·g(x) is O(x¹²).
c
Match the linear, constant-coefficient, homogeneous recurrence relation represented by its characteristic polynomial, to the general solution of the recurrence. (r-1)(r-2)² a. aₙ=p₁+p₂·2ⁿ b. aₙ=p₁(-i)ⁿ+p₂(i)ⁿ c. aₙ=p₁+(p₂+p3n)·2ⁿ d. aₙ=p₁+p₂+(p3+p4n)·2ⁿ
c
Select which one of the following statements is logically equivalent to (p → q) → r: a. (p ∧ q) ∨ ¬r b. (p ∧ q) ∨ r c. (p ∧ ¬q) ∨ r d. (¬p ∧ q) ∨ r
c
Consider the two statements: 1. (p → q) ∨ (p → ¬q) 2. (p → q) ∨ (¬p → q). a. Neither is a tautology. b. 2. is a tautology, 1. is not. c. They are both tautologies. d. 1. is a tautology, 2. is not.
c 1. is a tautology because q true makes (p → q) true and q false makes (p → ¬q) true, regardless of the truth value of p. Thus (p → q) ∨ (p → ¬q) is always true. 2. is a tautology because p false makes (p → q) true, and p true makes (¬p → q) true, regardless of the truth value of q. Thus (p → q) ∨ (¬p → q) is always true.
Let C be the relation defined on the set of all people by xCy if and only if x and y share a common interest (such as a hobby, a science, a sport, etc.) Consider that some people may have no interests at all. Check all properties that C has. a. reflexive b. symmetric c. transitive d. anti-symmetric
c C is not reflexive. It was given that some people have in interest at all. This means that if x is one such person, xCx is false. C is symmetric because when a person shares an interest with another person, then the other person shares that interest with the first person. Since we can find two different people x and y who share a common interest, i.e. xCy and yCx, C is not anti-symmetric. C is not transitive because when xCy and yCz, it is well possible that the interest that x has in common with y is not the interest that y has in common with z, and that x and z share no interest.
There are 193 member states of the United Nations. If you have 195 diplomats from these states in a room, then 1. It is certain that at least 2 of them are from the same state. 2. It is certain that at least 3 of them are from the same state. a. Both statements are true. b. Both statements are false. c. 1. is true, 2. is false. d. 1. is false, 2. is true.
c It is certain that at least 2 of them are from the same state, because if there was at most one diplomat from each state, then there would be at most 193 diplomats. It is not certain that at least 3 of them are from the same state. For example, 191 states might be represented by exactly 1 diplomat, and 2 states might be represented by 2 diplomats each.
What do you prove in the inductive step of an inductive proof of a statement P(n) for all positive integers n? a. You assume P(n+1) for some arbitrary positive integer n and show that P(n) must also be true. b. You assume P(n) for all positive integers n and show that P(n+1) must also be true. c. You show that P(2), P(3) and P(4) are true, then say "and the pattern continues", "etc", or other words to that effect. d. You assume P(n) for some arbitrary positive integer n and show that P(n+1) must also be true.
d
Let N be the "direct neighbor" relation defined on the set of all people: if x and y are persons, xNy iff x and y live directly next to each other, such as in two houses or apartments that are directly next to each other. If there is at least one unit between them, then they don't live directly next to teach other. Check all properties that this relation has. a. Anti-symmetric b. Reflexive c. Transitive d. Symmetric
d. N is not reflexive because there are people (this is true for most people in fact) who do not own two homes directly next to each other and are thus not their own direct neighbor. N is symmetric because if A is a direct neighbor of B, then B is also a direct neighbor of A. N is not anti-symmetric because there are different people who are direct neighbors of each other. N is not transitive because there are many situations where three homes are arranged on a straight line like this: A B C. A is a direct neighbor of B, B is a direct neighbor of C, but A is not a direct neighbor of C.
True or false? log(n) is big-O of n and n is big-Ω of log(n). True False
true Logarithms grow slower than linear functions. That is, both statements "log(n) is big-O of n" and "n is big-Ω of log(n)" are true.
True or false? To verify that 101 is prime, we merely need to test divide it by 2, 3, 5, 7. The fact that 101 is not divisible by those numbers guarantees that it is prime. True False
true To test n for primality through trial division, it is sufficient to check all primes no greater than the square root of n. Since 101 is strictly between 100 and 121, the square root of 101 is strictly between 10 and 11. The primes that are less than the square root of 101 are therefore 2, 3, 5, 7.