CS1800 Discrete Structures Spring 2018 February CS1800 Discrete Structures Midterm Version A

Similar documents
CS1800 Discrete Structures Final Version A

CS1800 Discrete Structures Fall 2017 October, CS1800 Discrete Structures Midterm Version A

CS1800 Discrete Structures Fall 2016 Profs. Gold & Schnyder April 25, CS1800 Discrete Structures Final

Midterm Examination # 1 Wednesday, February 25, Duration of examination: 75 minutes

CS 70 Discrete Mathematics and Probability Theory Fall 2016 Seshia and Walrand Midterm 1 Solutions

UC Berkeley, CS 174: Combinatorics and Discrete Probability (Fall 2008) Midterm 1. October 7, 2008

CS1800 Discrete Structures Fall 2016 Profs. Aslam, Gold, Ossowski, Pavlu, & Sprague 27 October, CS1800 Discrete Structures Midterm Version A

Math 13, Spring 2013, Lecture B: Midterm

Philadelphia University Student Name: Student Number:

CSE 20 Discrete Math. Algebraic Rules for Propositional Formulas. Summer, July 11 (Day 2) Number Systems/Computer Arithmetic Predicate Logic

Midterm 1. Your Exam Room: Name of Person Sitting on Your Left: Name of Person Sitting on Your Right: Name of Person Sitting in Front of You:

DISCRETE STRUCTURES AMIN WITNO

Packet #1: Logic & Proofs. Applied Discrete Mathematics

Preparing for the CS 173 (A) Fall 2018 Midterm 1

Exam Practice Problems

University of Ottawa CSI 2101 Midterm Test Instructor: Lucia Moura. February 9, :30 pm Duration: 1:50 hs. Closed book, no calculators

Problem Points Score Total 100

Math 230 Final Exam, Spring 2009

Discrete Mathematics and Probability Theory Summer 2014 James Cook Midterm 1 (Version B)

Problem # Number of points 1 /20 2 /20 3 /20 4 /20 5 /20 6 /20 7 /20 8 /20 Total /150

Math 10850, fall 2017, University of Notre Dame

MATH 114 Fall 2004 Solutions to practice problems for Final Exam

Philadelphia University Student Name: Student Number:

Do not open this exam until you are told to begin. You will have 75 minutes for the exam.

Exam in Discrete Mathematics

Do not start until you are given the green signal

(1) Which of the following are propositions? If it is a proposition, determine its truth value: A propositional function, but not a proposition.

(c) Give a proof of or a counterexample to the following statement: (3n 2)= n(3n 1) 2

Problem Points Score Total 100

UNIVERSITI TENAGA NASIONAL. College of Information Technology

HOMEWORK #2 - MATH 3260

McGill University Faculty of Science. Solutions to Practice Final Examination Math 240 Discrete Structures 1. Time: 3 hours Marked out of 60

Show Your Work! Point values are in square brackets. There are 35 points possible. Some facts about sets are on the last page.

Midterm Exam Solution

Math 230 Final Exam, Spring 2008

Midterm 2. Your Exam Room: Name of Person Sitting on Your Left: Name of Person Sitting on Your Right: Name of Person Sitting in Front of You:

Exam in Discrete Mathematics

UNIVERSITY OF VICTORIA DECEMBER EXAMINATIONS MATH 122: Logic and Foundations

CSCI Homework Set 1 Due: September 11, 2018 at the beginning of class

IVA S STUDY GUIDE FOR THE DISCRETE FINAL EXAM - SELECTED SOLUTIONS. 1. Combinatorics

A statement is a sentence that is definitely either true or false but not both.

CPSC 121 Midterm 1 Friday February 5th, 2016

Chapter 4, Logic using Propositional Calculus Handout

Propositional Logic: Equivalence

CSC 125 :: Final Exam December 14, 2011

Cs302 Quiz for MID TERM Exam Solved

CSE 20. Final Review. CSE 20: Final Review

ˆ The exam is closed book, closed calculator, and closed notes except your one-page crib sheet.

Algorithms and Data Structures 2016 Week 5 solutions (Tues 9th - Fri 12th February)

Problem 1: Suppose A, B, C and D are finite sets such that A B = C D and C = D. Prove or disprove: A = B.

1. Consider the conditional E = p q r. Use de Morgan s laws to write simplified versions of the following : The negation of E : 5 points

Computer Science Foundation Exam

Name: Exam 2 Solutions. March 13, 2017

Logic as a Tool Chapter 1: Understanding Propositional Logic 1.1 Propositions and logical connectives. Truth tables and tautologies

ECE20B Final Exam, 200 Point Exam Closed Book, Closed Notes, Calculators Not Allowed June 12th, Name

Math Final Exam December 14, 2009 Page 1 of 5

CSE 321 Solutions to Practice Problems

Tutorial Obtain the principal disjunctive normal form and principal conjunction form of the statement

1 Boolean Algebra Simplification

Numbers and Arithmetic

CprE 281: Digital Logic

Math 1: Calculus with Algebra Midterm 2 Thursday, October 29. Circle your section number: 1 Freund 2 DeFord

Simplification by Truth Table and without Truth Table

CS70: Discrete Math and Probability. Slides adopted from Satish Rao, CS70 Spring 2016 June 20, 2016

REVIEW QUESTIONS. Chapter 1: Foundations: Sets, Logic, and Algorithms

Strong Mathematical Induction

*Final Exam* EECS 203 Spring 2016

CS 173: Discrete Mathematical Structures, Spring 2008 Homework 1 Solutions

Undergraduate Notes in Mathematics. Arkansas Tech University Department of Mathematics. Introductory Notes in Discrete Mathematics Solution Guide

Homework 4 Solutions

SAMPLE ANSWERS MARKER COPY

MA EXAM 1 Green February 8, You must use a #2 pencil on the mark sense sheet (answer sheet).

Math 163 (23) - Midterm Test 1

Algorithms and Data Structures (COMP 251) Midterm Solutions

Midterm 2 Sample Introduction to Higher Math Fall 2018 Instructor: Linh Truong

Math 461 B/C, Spring 2009 Midterm Exam 1 Solutions and Comments

Midterm Exam. CS 3110: Design and Analysis of Algorithms. June 20, Group 1 Group 2 Group 3

UCSD CSE 21, Spring 2014 [Section B00] Mathematics for Algorithm and System Analysis

AMTH140 Trimester Question 1. [8 marks] Answer

MA 110 Algebra and Trigonometry for Calculus Spring 2017 Exam 1 Tuesday, 7 February Multiple Choice Answers EXAMPLE A B C D E.

University of Florida EEL 3701 Fall 1996 Dr. Eric M. Schwartz

Practice Midterm Exam Solutions

ECS 20: Discrete Mathematics for Computer Science UC Davis Phillip Rogaway June 12, Final Exam

RYERSON UNIVERSITY DEPARTMENT OF MATHEMATICS

University of Toronto Department of Electrical and Computer Engineering. Final Examination. ECE 345 Algorithms and Data Structures Fall 2016

Final Exam. ECE 25, Spring 2008 Thursday, June 12, Problem Points Score Total 90

Definition 2. Conjunction of p and q

Math 3000 Section 003 Intro to Abstract Math Homework 6

MA EXAM 3 INSTRUCTIONS VERSION 01 November 8, Section # and recitation time

Contents. Counting Methods and Induction

Notation Index. gcd(a, b) (greatest common divisor) NT-16

Efficient Algorithms and Intractable Problems Spring 2016 Alessandro Chiesa and Umesh Vazirani Midterm 2

*Final Exam* EECS 203 Spring 2016

CSI 4105 MIDTERM SOLUTION

MATH 363: Discrete Mathematics

Discrete Math I Exam II (2/9/12) Page 1

Math 430 Exam 1, Fall 2006

MA EXAM 3 Form A November 12, You must use a #2 pencil on the mark sense sheet (answer sheet).

MA FINAL EXAM Form 01 MAY 3, 2018

MTH001- Elementary Mathematics Solved Final Term Papers For Final Term Exam Preparation

Transcription:

CS1800 Discrete Structures Spring 2018 February 2018 CS1800 Discrete Structures Midterm Version A Instructions: 1. The exam is closed book and closed notes. You may not use a calculator or any other electronic device. 2. The exam is worth 100 total points. The points for each problem are given in the problem statement and in the table below. 3. You should write your answers in the space provided; use the back sides of these sheets, if necessary. 4. SHOW YOUR WORK FOR ALL PROBLEMS. 5. You have two hours to complete the exam. Section Title Points Section 1[12 points] Binary and Hexadecimal Section 2 [19 points] Logic Section 3 [21 points] Proofs Section 4 [25 points] Sets and Counting Section 5 [23 points] Permutations and Combinations Total Name: CS1800 (Lecture) Instructor: 1

Section 1 [12 pts: 6,6]: Binary, Octal, and Hexadecimal 1. Write the number 74 in (a) binary, (b) hexadecimal. (a) 1001010 (b) 4A 2. How many digits are in the octal (base 8) representation of 8 4? 5 (don t forget the 8 0 digit) 2

p Section 2 [19 pts: 4,5,2,4,4]: Logic q 1. (a) Write the logic expression that describes the following circuit (do not simplify your expression). p q ( p (p q)) 2 (b) Use logic rules to simplify your expression. Show each step and specify when you are applying the following rules: (1) De Morgan, (2) Distributive, (3) Double Negation. ( p (p q)) (( p p) ( p q)) (F ( p q)) ( p q) (p q) p q distributive law DeMorgan s law double negation (c) Draw the circuit that corresponds to the simplified expression. OR gate 3

2. Simplify the expression q ( p q). Your result should contain only variables and (the smallest possible number of) connectives selected from,,. q ( p q) q ( p q) ( q p) ( q q) ( q p) T ( q p) (q p) 3. Assume x and y are integers, and either explain why the following statement is true, or provide a counterexample: x y : y 2 = x False; if x = 2, for example, there is no integer y that is its square root. 4

Section 3 [21 pts (7 each)]: Proofs 1. A graph G = (V, E) is connected and undirected; a breadth-first search (BFS) traversal finds a path to vertex u of length 3 and finds a path to vertex v of length 7. Prove that the shortest path between u and v has at least 4 edges. If path(u, v) < 4 then a path to v that is shorter than 7 exists, and BFS finds the shortest path contradiction 2. Prove that a tree with n 3 vertices can have at most one vertex of degree n 1. A vertex with degree n 1 (call it A) must be connected to every other vertex. If any of those other vertices (B and C) are connected to each other, then that connection and the two edges out to those vertices forms a cycle (ABC), which is not allowed in a tree. So when one vertex is connected to all the others, none of the others can have any connections to each other, and thus none of them can have degree n 1. Alternate solution: The tree can t have two vertices of degree n 1 as otherwise, together with a third vertex which must have degree at least 1, these would yield a degree sum 2(n 1) + 1 > 2(n 1) and thus a number of edges > n 1, which can t be in a tree. 5

3. Prove by induction that Σ n i=1 4i3 = n 2 (n + 1) 2 for n 1. Base case: Substituting 1 into both sides gives 4=4. Inductive hypothesis: Assume true for n=k, so σi=1 k 4i3 = k 2 (k + 1) 2. Inductive step: For the sum to k + 1, by the inductive hypothesis and adding one more term we have k 2 (k + 1) 2 + 4(k + 1) 3. We can expand the second term a little to get (4k +4)(k +1) 2, which can be combined with the first term to get (k 2 + 4k + 4)(k + 1) 2. Factoring gives (k + 2) 2 (k + 1) 2, and this is clearly the target formula with k + 1 substituted. 6

Section 4 [25 pts: 2,2,2,3,4,3,4,5]: Sets and Counting 1. Consider sets A = {1, 2, 3, 6}, B = {2, 6, 7}, and C = {3, 4, 6, 7}. Use the listing method to describe the following sets (that is, list their elements between braces). (a) A B {1, 2, 3, 6, 7} (b) A B {2, 6} (c) C B {3, 4} (d) (A B) (A C) {2, 6} {3, 6} = {(2, 3), (2, 6), (6, 3), (6, 6)} (e) P(B) (the power set of B). {, {2}, {6}, {7}, {2, 6}, {2, 7}, {6, 7}, {2, 6, 7}} 2. If X = {x x Z, 1 x 1} and Y = {y y R, y 2 = 1}, what is X Y? 3*2 = 6 3. A college class has 81 students. All the students are known to be from 17 through 32 years of age. You want to make a bet that the class contains at least x students of the same age. How large can you make x and be sure to win your bet? There are 32 16 = 16 age groups. The average number of students per age is thus 81/16 = 5+ (slightly larger than 5). As the number of students in each age class is an integer, some age class will contain 6 students. 4. If A = 6, B = 5, and P(A B) = 256, what is A B? (P(A B) is the power set of A B.) From P(A B) = 256 follows that A B = 8. Applying the inclusion-exclusion formula for two sets, we have 8 = A B = A + B A B = 6 + 5 A B. Therefore A B = 3. 7

Section 5 [23 pts (4,3,6,5,5]: Permutations and Combinations Please complete your computations to arrive at a single integer answer for each problem. 1. How many positive divisors does the number 2 3 3 5 5 2 7 have? 4 6 3 2 = 144. 2. Three married couples are going to the movies. (a) In how many ways can the six persons stand in line at the ticket booth, assuming the couples don t need to stay together? 6! = 720 (b) In how many ways can they stand in line at the ticket booth if couples must stay together? order the couples order couple 1 order couple 2 order couple 3 3! = 6 2 2 2 There are 6 2 2 2 = 48 ways to arrange the 6 persons. 3. (a) A test has two sections of five questions each. The instructions say to answer three questions in each section. In how many ways can a student choose the questions to complete the exam? 3 questions from section 1 3 questions from section 2 ( 5 ) ( 3 = 10 5 ) 3 = 10 There are 10 10 = 100 ways to select questions. (b) Another test has three sections of four questions each. According to the instructions, the student must answer two questions from each of any two sections and one question from the other section. In how many ways can the student choose questions to answer? single question section single question 2 quest other section 2 quest last section ( 3 choices 4 choices 4 ) ( 2 = 6 4 ) 2 = 6 There are 3 4 6 6 = 432 ways to select questions. 8