ITEC 122 HW (Essentials Of Discrete Mathematics (3rd Edition))

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

2.2.22.

(1, 1), (1, 2), (2, 1), (2, 2)

1.5.6. (Chapter, Section, Question) Proof.

(By contraposition.) Let n be an integer. Suppose that n is even, i.e., n = 2k for some integer k. Then n^2 = 4k^2 = 2(2k^2) is also even.

1.4.24. (Chapter, Section, Question) Consider the following model for four-point geometry: Points: 1, 2, 3, 4 Lines: (1, 2), (1, 3), (1, 4), (2, 3), (2, 4), (3, 4) A point "is on" a line if the line's box contains the point. (a) Give a pair of parallel lines in this model. (Refer to Definition 1.8.) (b) Give a pair of intersecting lines in this model. (Use your definition from Exercise 23.)

(a) (1, 2) and (3, 4) because they have no points in common (b) (1, 2) and (1, 4) intersect because they both contain the point 1.

1.4.10. (Chapter, Section, Question) Consider the domain of all quadrilaterals. Let A(x) = "x has four right angles." R(x) = "x is a rectangle." Write the meaning of each mathematical statement in predicate logic, keeping in mind the logical distinction between definitions and theorems. (a) Definition. A quadrilateral is a rectangle if it has four right angles. (b) Theorem. A quadrilateral is a rectangle if it has four right angles.

(a) (∀x)(A(x) ↔ R(x)) (b) (∀x)(A(x) → R(x))

1.3.14. (Chapter, Section, Question) In the domain of all people, consider the following predicate. P(x, y) = "x needs to love y." (a) Write the statement "Everybody needs somebody to love" in predicate logic. (b) Formally negate your statement from part (a). (c) Write the English translation of your negated statement.

(a) (∀x)(Ǝy)P(x, y) (b) ¬(∀x)(Ǝy)P(x, y) ⇒ (Ǝx)¬(Ǝy)P(x, y) ⇒ (Ǝx)(∀y)¬P(x, y) (c) There is somebody who doesn't need to love anybody.

1.3.2. (Chapter, Section, Question) In the domain of all penguins, let D(x) be the predicate "x is dangerous." Translate the following quantified statements into simple, everyday English.

(a) (∀x)D(x) All penguins are dangerous. (b) (Ǝx)D(x) Some penguins are dangerous. (c) ¬(Ǝx)D(x) No penguin is dangerous. (could be written as "No penguins are dangerous.") (d) (Ǝx) ¬D(x) Some penguins are not dangerous

2.2.6.

(a) A ∩ B ∩ C (b) (A ∪ B ∪ C)′ (c) A ∩ (B ∪ C)′

1.3.4. (Chapter, Section, Question) Let the following predicates be given. The domain is all mammals.L(x) = "x is a lion." L(x) = "x is a lion." F(x) = "x is fuzzy." Translate the following statements into predicate logic.

(a) All lions are fuzzy. (∀x)(L(x) → F(x)) (b) Some lions are fuzzy. (∃x)(L(x) ∧ F(x))

1.4.18. (Chapter, Section, Question) Consider the following theorem. Theorem. Let x be a wamel. If x has been schlumpfed, then x is a borfin. Answer the following questions. (a) Give the converse of this theorem. (b) Give the contrapositive of this theorem. (c) Which statement, (a) or (b), is logically equivalent to the Theorem?

(a) Converse: Let x be a wamel. If x is a borfin, then x has been schlumpfed. (b) Contrapositive: Let x be a wamel. If x is not a borfin, then x has not been schlumpfed. (c) b

1.3.8. In the domain of integers, consider the following predicates: Let N(x) be the statement "x ≠ 0." Let P(x, y) be the statement "xy = 1." (a) Translate the following statement into the symbols of predicate logic (b) Write the negation of your answer to part (a) in the symbols of predicate logic. Simplify your answer so that it uses the ∧ connective. (c) Translate your answer from part (b) into an English sentence. (d) Which statement, (a) or (b), is true in the domain of integers? Explain.

(a) For all integers x, there is some integer y such that if x ≠ 0, then xy = 1. (∀x)(∃y)(N(x) → P(x,y)) (b) (∃x)(∀y)(N(x) ∧ ¬P(x,y)) (c) There is a nonzero integer x such that xy ̸= 1 for all integers y. (d) Statement (b) is true; for example, x = 2 works.

1.3.10. (Chapter, Section, Question) The domain of the following predicates is the set of all traders who work at the Tokyo Stock Exchange. P(x, y) = "x makes more money than y." Q(x, y) = "x ≠ y" Translate the following predicate logic statements into ordinary, everyday English. (Don't simply give a word-for-word translation; try to write sentences that make sense.) (a) (∀x)(Ǝy)P(x, y) (b) (Ǝy)(∀x)(Q(x, y) → P(x, y)) (c) Which statement is impossible in this context? Why?

(a) For every trader, there is a trader that makes the same amount of money or less. (b) There is some trader who makes the same amount of money of less than every other trader. (c) Statement a is impossible because there must be some trader that makes the smallest amount of money.

1.4.15a. (Chapter, Section, Question) Find a counterexample for each statement.

(a) If n is prime, then 2^n - 1 is prime. Try, n = 2, 3, 5, 7, 11. With n = 11, then 2^11 - 1 = 2047 which is not prime, so n = 11 is a counterexample.

1.4.6. (Chapter, Section, Question) Consider the following definition of the "⊲" symbol. Definition. Let x and y be integers. Write x ⊲ y if 3x + 5y = 7k for some integer k. (a) Show that 1 ⊲ 5, 3 ⊲ 1, and 0 ⊲ 7. (b) Find a counterexample to the following statement: If a ⊲ b and c ⊲ d, then a · c ⊲ b · d.

(a) Prove: 1 ⊲ 5 Proof: 1. x ⊲ y if 3x + 5y = 7k given 2. 28 = 28 3. 28 = 7 · 4 4. 3 + 25 = 7 · 4 5. 3 · 1 + 5 · 5 = 7 · 4 6. 1 ⊲ 5 1, 5 with k = 4 Prove: 3 ⊲ 1 Proof: (left to reader) Prove: 0 ⊲ 7 Proof: (left to reader) (b) Counterexample: Choose a = 1, b = 5, c = 3, d = 1. Evaluate whether the following is true: 1 · 3 ⊲ 5 · 1 By contradiction (see section 1.5 in the text), assume 1 · 3 ⊲ 5 · 1. Then 3 ⊲ 5 which means 9 + 25 = 7k for some integer k. Then 34 = 7k for some integer k, but this is a contradiction since there is no integer k such that 34 = 7k (i.e., 34 is not divisible by 7). Thus our assumption is false and 1 · 3 not ⊲ 5 · 1.

1.5.16. (Chapter, Section, Question) Consider the following definitions: Definition. An integer n is alphic if n = 4k + 1 for some integer k. Definition. An integer n is gammic if n = 4k + 3 for some integer k. (a) Show 19 is gammic. (b) Suppose that x is alphic and y is gammic. Prove that x + y is even. (c) Prove by contraposition: If x is not odd, then x is not alphic.

(a) Since 19 = 4 · 4 + 3, 19 is gammic. Just to understand this a little better: 5 = 4 · 1 + 1, so 5 is alphic. 7 = 4 · 1 + 3, so 7 is gammic. 9 = 4 · 2 + 1, so 9 is alphic. 11 = 4 · 2 + 3, so 11 is gammic. Note that even numbers are neither alphic nor gammic since there is no k you can come up with for any even integer to fit into either of these definitions. (b) Proof. Suppose that x is alphic and y is gammic. Then there are integers j and k such that x = 4j + 1 and y = 4k + 3. Therefore x + y = 4j + 4k + 4 = 2(2j + 2k + 2), so x + y is even. (c) Proof. (By contraposition.) Suppose that x is alphic. Then x = 4k + 1 for some integer k. Therefore x = 2(2k) + 1, so x is odd.

1.3.6. (Chapter, Section, Question) The domain of the following predicates is the set of all plants. P(x) = "x is poisonous." Q(x) = "Jeff has eaten x." Translate the following statements into predicate logic.

(a) Some plants are poisonous. (Ǝx)P(x) (b) Jeff has never eaten a poisonous plant. (∀x)(P(x) → ¬Q(x)) (could be written as in contrapositive form (∀x)(Q(x) → ¬P(x))) (c) There are some nonpoisonous plants that Jeff has never eaten. (Ǝx)(¬P(x) → ¬Q(x))

2.1.10 (Chapter, Section, Question)

(a) Yes. Links have a direction from a page to a page. (b) No. There are pages with no links that are never linked to. (c) No. There are lots of pages that don't link to each other. (d) No. A page can link to itself. (e) The outdegree is the number of links on page p. (f) The indegree is the number of pages that have links to p.

1.3.1c. (Chapter, Section, Question) In the domain of integers, let P(x, y) be the predicate "x · y = 12." Tell whether each of the following statements is true or false.

(c) P(2, 6) ∨ P(3, 7) T ∨ F ⇒ T, so the statement is true.

1.1.12. (Chapter, Section, Question) Show that (a ∨ b) ∧ (¬(a ∧ b)) is logically equivalent to a ↔ ¬b.

(columns) 1. a 2. b 3. a ∨ b 4. a ∧ b 5. ¬(a ∧ b) 6. (a ∨ b) ∧ (¬(a ∧ b)) 7. ¬b 8. a ↔ ¬b (rows) 1. T T T T F F F F 2. T F T F T T T T 3. F T T F T T F T 4. F F F F T F T F Since the 6th and 8th columns of the truth table are the same, the statements for those columns are logically equivalent.

1.1.10b. (Chapter, Section, Question) Show that ¬(p ∧ q) is logically equivalent to ¬p ∨ ¬q.

(columns) 1. p 2. q 3. p ∧ q 4. ¬(p ∧ q) 5. ¬p 6. ¬q 7. ¬p ∨ ¬q (rows) 1. T T T F F F F 2. T F F T F T T 3. F T F T T F T 4. F F F T T T T Since the 4th and 7th columns of the truth table are the same, the statements for those columns are logically equivalent.

1.1.26a. (Chapter, Section, Question) Construct a truth table for S.

(columns) 1. p 2. q 3. p ∧ q 4. ¬q 5. p ∧ ¬q 6. (p ∧ q) ∨ (p ∧ ¬q) (rows) 1. T T T F F T 2. T F F T T T 3. F T F F F F 4. F F F T F F

1.1.10a. (Chapter, Section, Question) Show that ¬(p ∨ q) is logically equivalent to ¬p ∧ ¬q.

(columns) 1. p 2. q 3. p ∨ q 4. ¬(p ∨ q) 5. ¬p 6. ¬q 7. ¬p ∧ ¬q (rows) 1. T T T F F F F 2. T F T F F T F 3. F T T F T F F 4. F F F T T T T Since the 4th and 7th columns of the truth table are the same, the statements for those columns are logically equivalent.

1.1.13. (Chapter, Section, Question)

(columns) 1. p 2. q 3. p ∨ q 4. ¬p 5. (p ∨ q) ∧ (¬p) 6. [(p ∨ q) ∧ (¬p)] → q (rows) 1. T T T F F T 2. T F T F F T 3. F T T T T T 4. F F F T F T

1.1.14b. (Chapter, Section, Question)

(columns) 1. p 2. q 3. r 4. p ∧ q 5. (p ∧ q) → r (rows) 1. T T T T T 2. T T F T F 3. T F T F T 4. T F F F T 5. F T T F T 6. F T F F T 7. F F T F T 8. F F F F T

1.1.30. (Chapter, Section, Question) Write ¬p in terms of p and ↑.

(columns) 1. p 2. ¬p 3. p ↑ p (rows) 1. T F F 2. F T T Since columns 2 and 3 are the same, the corresponding expressions are logically equivalent (i.e., ¬p can be written as p ↑ p). You could also write this as "p nand p" or "p not and p".

1.2.4. (Chapter, Section, Question) Is the proof in exercise 2 reversible? No Why or why not? The proof is not reversible because it uses inference rules (simplification and modus ponens). Here is what a proof using truth tables looks like for this same problem:

(columns) 1. p 2.q 3. r 4. q ∧ r 5. ¬p 6. ¬p ∧ q 7. ¬(¬p ∧ q) 8. (q ∧ r) ∧ ¬(¬p ∧ q) 9. ((q ∧ r) ∧ ¬(¬p ∧ q)) → p (rows) 1. T T T T F F T T T 2. T T F F F F T F T 3. T F T F F F T F T 4. T F F F F F T F T 5. F T T T T T F F T 6. F T F F T T F F T 7. F F T F T F T F T 8. F F F F T F T F T Since column 9 is all T, the truth table proves that the 2 givens imply p.

1.2.27. (Chapter, Section, Question) Use a truth table to show that (a → b) ∧ (a ∧ ¬b) is a contradiction.

(columns) 1a 2b 3¬b 4a → b 5a ∧ ¬b 6(a → b) ∧ (a ∧ ¬b) (rows) 1. T T F T F F 2. T F T F T F 3. F T F T F F 4. F F T T F F Column 6 is all F so (a → b) ∧ (a ∧ ¬b) is a contradiction.

1.1.14a. (Chapter, Section, Question)

(p ∧ q) → r

2.2.14. How many integers in the set {n ∈ Z | 1 ≤ n ≤ 700} are divisible by 2, 5, or 7?

(using results from 2.2.13) {n ∈ Z | 1 ≤ n ≤ 70} 35 + 14 + 10 − 7 − 5 − 2 + 1 = 46 {n ∈ Z | 1 ≤ n ≤ 700} 350 + 140 + 100 − 70 − 50 − 20 + 10 = 460 = 46 * 10

2.2.10. Proof. Let A and B be finite sets.

(→). Suppose A and B are disjoint. Since A ∩ B = ∅, |A ∩ B| = 0. Therefore, by the inclusion-exclusion principle, |A ∪ B| = |A| + |B|. (←). Suppose |A ∪ B| = |A| + |B|. By the inclusion-exclusion principle, |A ∪ B| = |A| + |B| − |A ∩ B|, so |A ∩ B| = 0. Therefore A ∩ B contains no elements, so A ∩ B = ∅.

1.4.10b. (Chapter, Section, Question)

(∀x)(A(x) → R(x))

1.3.18. (Chapter, Section, Question) Write the following statement in predicate logic, and negate it. Say what your predicates are, along with the domains. Let x and y be real numbers. If x is rational and y is irrational, then x + y is irrational. R(x) = "x is rational.", domain the real numbers

(∀x)(∀y)((R(x) ∧ ¬R(y)) → ¬R(x + y)) ¬(∀x)(∀y)((R(x) ∧ ¬R(y)) → ¬R(x + y)) (Ǝx)¬(∀y)((R(x) ∧ ¬R(y)) → ¬R(x + y)) (Ǝx)(Ǝy)¬((R(x) ∧ ¬R(y)) → ¬R(x + y)) (Ǝx)(Ǝy)(¬(R(x) ∧ ¬R(y)) ∨ R(x + y)) (Ǝx)(Ǝy)(¬R(x) ∨ R(y) ∨ R(x + y))

2.2.2.

+--------------------------------------+ |**************************************| |*******+---------+****+---------+*******| |*******|A######\**/***********B|*******| |*******|#######/\*************|*******| |*******|######/*****\***********|*******| |*******|######\*****/***********|*******| |*******|#######\*/************|*******| |*******|#######/\*************|*******| |*******+---------+****+---------+*******| |**************************************| +--------------------------------------+ # shading is A ∩ B′ * is unshaded middle diamond (unshaded) is A ∩ B

1.2.16. (Chapter, Section, Question) Write a proof sequence for the following assertion. Justify each step.

1. p given 2. p → r given 3. q → ¬r given 4. r modus ponens, 1, 2 5. ¬(¬r) double negation, 4 6. ¬q modus tollens, 5, 3

1.2.20. (Chapter, Section, Question) Write a proof sequence to establish that p ⇔ p ∨ p is a tautology. (Hint: Use De Morgan's laws and Exercise 19.)

1. p ∨ p given 2. ¬¬(p ∨ p) double negation, 1 3. ¬(¬p ∧ ¬p) De Morgan, 2 4. ¬¬p Exercise 19, 3 5. p double negation, 4 This establishes that p ∨ p → p. Since all steps of this proof sequence are reversible, p → p ∨ p is also true. Therefore p ⇔ p ∨ p is a tautology.

1.2.2. (Chapter, Section, Question) Fill in the reasons in the following proof sequence. Make sure you indicate which step(s) each derivation rule refers to.

1. q ∧ r given 2. ¬(¬p ∧ q) given 3. ¬¬p ∨ ¬q De Morgan, 2 4. p ∨ ¬q double negation, 3 5. ¬q ∨ p commutativity, 4 6. q → p implication, 5 7. q simplification, 1 8. p modus ponens, 7, 6

2.1.24a. (Chapter, Section, Question)

123 / \ 121 684 / / 50 511 / \ 43 602

2.1.24c. (Chapter, Section, Question) 123, 50, 602, 43, 121, 511, 684

123 / \ 50 602 / \ / \ 43 121 511 684

2.1.24c. (Chapter, Section, Question)

123, 50, 602, 43, 121, 511, 684 123 / \ 50 602 / \ / \ 43 121 511 684

2.1.24b. (Chapter, Section, Question)

3

2.2.14.

350 + 140 + 100 − 70 − 50 − 20 + 10 = 460

2.1.1a. (Chapter, Section, Question)

9

2.2.6.c.

A ∩ (B ∪ C)′ or A ∩ B′ ∩ C′

10 1.3.22ai. (Chapter, Section, Question)

All sports cars are fast. (∀x)(S(x) → F(x))

3.2.14. (Chapter, Section, Question) Analyze the sequence 1, 6, 15, 100, 501, 1746, 4771, 11040, 22665, 42526, 74391 using sequences of differences. From what degree polynomial does this sequence appear to be drawn? (Don't bother finding the coefficients of the polynomial.)

Function: 1, 6, 15, 100, 501, 1746, 4771, 11040, 22665, 42526, 74391 First: 5, 9, 85, 401, 1245, 3025, 6269, 11625, 19861, 31865. Second: 4, 76, 316, 844, 1780, 3244, 5356, 8236, 12004. Third: 72, 240, 528, 936, 1464, 2112, 2880, 3768. Fourth: 168, 288, 408, 528, 648, 768, 888. Fifth: 120, 120, 120, 120, 120, 120. This suggests the sequence comes from a degree 5 polynomial.

3.2.16. (Chapter, Section, Question) Refer to Example 3.7. Guess at a closed-form solution to the recurrence relation for the number of edges in Kn, the complete graph on n vertices. Prove that your guess is correct.

Guess: E(n) = 0 for n = 1 E(n) = n * (n - 1) / 2 for n > 1. Proof (by induction on n): Let f(n) = n * (n - 1) / 2. Base Case: If n = 1, the recurrence relation says that E(1) = 0, and the formula says that f(1) = 1 * (1 − 1) / 2 = 0, so they match. Inductive Hypothesis: Suppose as inductive hypothesis that E(k − 1) = (k − 1) * (k − 2) / 2 for some k > 1. Inductive Step: Using the recurrence relation, E(k) = E(k − 1) + k − 1, by the second part of the recurrence relation = (k − 1) * (k − 2) / 2 + k − 1, by inductive hypothesis = ((k − 1) * (k − 2) + (k − 1) * (2)) / 2 = k * (k - 1) / 2 so, by induction, E(n) = f(n) for all n >= 1.

2.1.6. (Chapter, Section, Question) Any such undirected complete graph with 5 vertices must have 10 edges. For example, a graph with these 10 edges is an undirected complete graph with 5 vertices: 1-2,1-3,1-4,1-5 2-3,2-4,2-5 3-4,3-5 4-5

I used this Wolfram Alpha query to draw the graph: https://www.wolframalpha.com/input/?i=complete+graph+5+vertices

1.2.8. (Chapter, Section, Question) Which derivation rule justifies the following argument?

If n is a multiple of 4, then n is even. However, n is not even. Therefore, n is not a multiple of 4. p: n is a multiple of 4 q: n is even 1. ¬q given 2. p → q given 3. ¬p modus tollens, 1, 2

1.1.2b. (Chapter, Section, Question)

If you are in Kwangju, then you are in South Korea, but not Seoul.

2.1.22. (Chapter, Section, Question)

In the (h,t,w) notation below for the directed graph, h is the head of the edge, t is the tail of the edge, and w is the weight (w = t-h). (11,12,1),(11,13,2),(11,15,4),(11,17,6), (12,13,1),(12,15,3),(12,17,5) (13,15,2),(13,17,4) (15,17,2)

1.2.12. (Chapter, Section, Question) Write a statement that follows from the statement

It is sunny and warm today. by the simplification rule. p: It is sunny today q: It is warm today The simplification rule applied to p ∧ q gives p. The simplification rule applied to p ∧ q also gives q.

1.1.32. (Chapter, Section, Question) Use the symbols of propositional logic to explain the difference between the following two statements.

My team will win if I yell at the TV. My team will win only if I yell at the TV. Look up the word "only" in a dictionary. This word has several different meanings. Which meaning applies when we use the phrase "if and only if" in logic? Let w be the statement "my team will win" and let y be the statement "I yell at the TV." The first statement ("my team will win if I yell at the TV") is y → w, and the second statement is w → y. The applicable meaning of "only" is "exclusively; solely."

3.2.20. (Chapter, Section, Question) Is 1 + (17/6)n - 2n^2 + (7/6)n^3 a closed-form solution for the following recurrence relation? P(n) = 1 for n = 0 P(n) = 4*P(n-1) - n^2 for n > 0 Prove or disprove.

No. Counterexample: 76 = P(4) not = 1 + (17/6)4 − (2)4^2 + (7/6)4^3 = 55. n 0 1 2 3 4 P(n) 1 3 8 23 76 formula 1 3 8 23 55

2.2.20

P(P({1})) = {∅,{∅},{1},{∅,{1}}}

1.1.22. (Chapter, Section, Question) Mathematicians say that "Statement P is a sufficient condition for statement Q" if P → Q is true. In other words, in order to know that Q is true, it is sufficient to know that P is true. Let x be an integer. Give a sufficient condition on x for x/2 to be an even integer.

P: x = -4 Q: x/2 is an even integer P is a sufficient condition (but not necessary) for Q to be true. (another example) P: x is a multiple of 2 Q: x/2 is an even integer P is a sufficient condition (and necessary) for Q to be true.

1.2.14. (Chapter, Section, Question) Recall Exercise 31 of Section 1.1. Suppose that all of the following status reports are correct:

Processor B is not working and processor C is working. Processor A is working if and only if processor B is working. At least one of the two processors A, B is not working. Let a = "A is working", b = "B is working", and c = "C is working". 1.2.14a. If you haven't already done so, write each status report in terms of a, b, and c, using the symbols of formal logic. A's report is ¬b ∧ c B's report is a ↔ b C's report is ¬a ∨ ¬b (can also be written as ¬(a ∧ b))

3.2.4. (Chapter, Section, Question) Consider the following recurrence relation: P(n) = 0 if n = 0 P(n) = 5 * P(n - 1) if n > 0. Use induction to prove P(n) = (5^n - 1) / 4 for n >= 0.

Proof (by induction on n): Let f(n) = (5^n − 1) / 4. Base Case: If n = 0, the recurrence relation says that P(0) = 0, and the formula says that f(0) = (5^0 − 1) / 2 = 0, so they match. Inductive Hypothesis: Suppose as inductive hypothesis that P(k - 1) = (5^(k - 1) - 1) / 4 for some k > 0. Inductive Step: Using the recurrence relation, P(k) = 5 * P (k − 1) + 1, by the second part of the recurrence relation = 5 * (5^(k - 1) - 1) / 4 + 1, by the inductive hypothesis = (5^k − 5) / 4 + 4 / 4 = (5^k - 1) / 4 so, by induction, P(n) = f(n) for all n >= 0.

3.2.3. (Chapter, Section, Question) Consider the following recurrence relation: B(n) = 2 if n = 1 B(n) = 3 * B(n - 1) + 2 if n > 1. Use induction to prove that B(n) = 3^n - 1.

Proof (by induction on n): Let f(n) = 3^n - 1 for all n >= 1. Base Case: If n = 1, the recurrence relation says that B(1) = 2, and the formula says that f(1) = 3^1 - 1 = 2, so they match. Inductive Hypothesis: Suppose as inductive hypothesis that B(k - 1) = 3^(k - 1) - 1 for some k > 1. Inductive Step: Using the recurrence relation, B(k) = 3 * B(k - 1) + 2, by 2nd part of recurrence relation = 3 * (3^(k - 1) - 1) + 2, by inductive hypothesis = 3^k - 3 + 2 = 3^k - 1 so, by induction, B(n) = f(n) for all n >= 1.

3.2.8. (Chapter, Section, Question) Guess a closed-form solution for the following recurrence relation: K(n) = 1 if n = 0 K(n) = 2 * K(n - 1) - n + 1 if n > 0. Prove that your guess is correct.

Proof (by induction on n): Let f(n) = n + 1. Base Case: If n = 0, the recurrence relation says that K(0) = 1, and the formula says that f(0) = 0 + 1 = 1, so they match. Inductive Hypothesis: Suppose as inductive hypothesis that K(k − 1) = (k − 1) + 1 for some k > 0. Inductive Step: Using the recurrence relation, K(k) = 2 * K(k − 1) − k + 1, by the second part of the recurrence relation = 2k − k + 1, by inductive hypothesis = k + 1 so, by induction, K(n) = f(n) for all n >= 0.

3.2.18. (Chapter, Section, Question) Recall that n! = 1·2·3···(n - 1)·n for n > 0, and by definition, 0! = 1. Prove that F(n) = n! for all n >= 0, where F(n) = 1 for n = 0 F(n) = n * F(n - 1) for n > 0.

Proof (by induction on n): Let f(n) = n!. Base Case: If n = 0, the recurrence relation says that F(0) = 1, and the formula says that f(0) = 0! = 1, so they match. Inductive Hypothesis: Suppose as inductive hypothesis that F(k − 1) = (k − 1)! for some k > 1. Inductive Step: Using the recurrence relation, F(k) = k·F(k − 1), by the second part of the recurrence relation = k·(k − 1)!, by inductive hypothesis = k·(1·2·3···(k - 1)) = k! so, by induction, F(n) = f(n) for all n >= 0.

2.2.26a.

Proof. Let n ∈ X. Then n = x + y for some odd integers x and y. By Exercise 1.5/10, n is even. Therefore n ∈ E.

2.2.24.

Proof. Let x ∈ (S′)′. In other words, if P(x) is the statement "x ∈ S", we are starting with the assumption ¬¬(P(x). By double negation, this is equivalent to P(x), which means x ∈ S. Proof (alternate). Let x ∈ (S′)′. Then by definition of ′, x ∉ (S′). Again by the definition of ′, x ∈ S.

1.5.16a. (Chapter, Section, Question)

Since 19 = 4 · 4 + 3, 19 is gammic.

10 1.3.4b. (Chapter, Section, Question)

Some lions are fuzzy. (∃x)(L(x) ∧ F(x))

1.5.4. (Chapter, Section, Question) Proof.

Suppose a, b, c are integers with a | b and b | c. Then b = ja and c = kb for some integers j and k. Therefore c = k(ja) = (kj)a, so a | c.

1.5.2. (Chapter, Section, Question) Proof.

Suppose a, b, c are integers, and a | b and a | c. By the definition of |, b = aj and c = ak for some integers j and k. Therefore b · c = ajak = (ajk)a, and ajk is an integer, so a | b · c.

1.1.14c. (Chapter, Section, Question)

The 6th row of the truth table is the only row in which (p ∧ q) → r is T, r is F, and q is T. Therefore p is F, that is, Andy is not hungry.

2.1.14. (Chapter, Section, Question)

The five countries surrounding Bolivia form a subgraph that requires four colors, in a similar manner as in Exercise 12.

2.1.2c. (Chapter, Section, Question)

The sum of the indegrees equals the sum of the outdegrees (7).

2.1.18. (Chapter, Section, Question)

The trapezoidal loops on the sides have five nodes, and since they must alternate colors, three colors are needed to complete these circuits.

1.2.28. (Chapter, Section, Question) Is a → ¬a a contradiction? No

Why or why not? Truth table column 3 (a → ¬a) is NOT all F: (columns) 1. a 2. ¬a 3. a → ¬a (rows) 1. T F F 2. F T T

2.1.8. (Chapter, Section, Question)

Yes. It has exactly two vertices of odd degree.

2.1.2a. (Chapter, Section, Question)

a : 1 b : 1 c : 1 d : 2 e : 2

2.1.2b. (Chapter, Section, Question)

a : 1 b : 3 c : 1 d : 1 e : 1

2.1.1c. (Chapter, Section, Question)

a : 4 b : 4 c : 2 d : 4 e : 4

2.1.1b. (Chapter, Section, Question)

a : 4 b : 4 c : 2 d : 4 e : 4

1.1.4b. (Chapter, Section, Question)

contrapositive: If you are not staying up late at night, then you are not studying hard.

1.1.4a. (Chapter, Section, Question)

converse: If you are staying up late at night, then you are studying hard.

3.2.22. (Chapter, Section, Question) Let f(n) = An^2 + Bn + C. Show that the expression f(n + 1) - f(n) is a linear function of n. (This calculation shows that a quadratic sequence has a linear sequence of differences.)

f(n + 1) − f(n) = A(n + 1)^2 + B(n + 1) + C − (An^2 + Bn + C) = 2An + A + B, which is a linear function of n.

3.2.12. (Chapter, Section, Question) Find a polynomial function f(n) such that f(1), f(2),... , f(8) is the following sequence: 2, 7, 12, 17, 22, 27, 32, 37.

f(n) = 5n − 3

3.2.13. (Chapter, Section, Question) Find a polynomial function f(n) such that f(1), f(2), ... , f(8) is the following sequence: 1, 1, 2, 4, 7, 11, 16, 22.

f(n) = n^2/2 − 3n/2 + 2

1.3.22a. (Chapter, Section, Question) Let the following predicates be given. The domain is all cars. F(x) = "x is fast." S(x) = "x is a sports car." E(x) = "x is expensive." A(x, y) = "x is safer than y." (a) Write the following statements in predicate logic. i. All sports cars are fast. ii. There are fast cars that aren't sports cars. iii. Every fast sports car is expensive.

i. (∀x)(S(x) → F(x)) ii. (Ǝx)(F(x) ∧ ¬S(x)) iii. (∀x)((S(x) ∧ F(x)) → E(x))

2.1.28. (Chapter, Section, Question)

lust / \ gluttony sloth / \ / \ envy greed pride rath

1.5.14a. (Chapter, Section, Question)

n = 5 is an odd integer that isn't sane.

1.3.16d. (Chapter, Section, Question) Any equation or inequality with variables in it is a predicate in the domain of real numbers. For each of the following statements, tell whether the statement is true or false. (d) (∀x)(Ǝy)(x2 + y = 4)

true

2.2.3b.

{(3, 2), (3, 3), (3, 4), (4, 2), (4, 3), (4, 4)}

2.2.18.

{(x, y) ∈ ℤ | 3x + 4 = 7y}


Set pelajaran terkait

MKTG 361 - Test 2 Study Guide (Ch. 8, 17, 18): Ch. 8

View Set

Death Penalty Exam 1, Chapter 13 Sentencing, 13- sentencing the death penalty and other forms of punishment, Ch 13: Sentencing, the Death Penalty, and Other Forms of Punishment, death penalty test, Death Penalty Final, Death Penalty Final

View Set

mgmt 311 mid-term exam study guide

View Set

Unit 4: Chemistry I Compound Nomenclature

View Set