Thurs. Feb. 26 Math 42 ______

Professor Jackson Quiz #1 Name

30 minutes, calculator allowed, explain your answers for full credit.

20 points total (5 points each problem)

1. Determine whether or not the following statements are logically equivalent;

p  (q  r) and (p  ~q)  r.

2. Determine whether or not the following argument is valid.

1) p  r 2) q  r 3) ~r 4)  ~p  ~q

3. Write negations for the following statements.

a)  SJSU student S,  a general education course C that they must take.

b)  a prime P, such that 1000 < p < 2000 (1000 < p and p < 2000).

4. Prove the following universal statement.

 integer n, if n is odd then 2n2 + 3n + 4 is odd.

Due Mon. Dec. 8 Math 42 ______

Professor Jackson Sample Final Name

Total = 15 pts. [1 pt. each]

Two pages of notes and a calculator allowed. Show your work for full credit.

  1. Use a truth table to determine whether or not the following statement is a tautology (a statement that is always true), ((p  q)  r)  ((p  ~q)  r).
  1. Let A be the set containing all the binary sequences of length 2 or more. For every x,y  A we say that x R y if and only if x and y have the same first letter and x and y also have the same last letter. Show that R is an equivalence relation. How many different equivalence classes does R have?

3. For all sets A,B, and C show that (A  B) x C = (A x C)  (B x C).

4. Write a negation for each of the following statements

a)Bill is healthy and wealthy and wise.

b)For every computer science student there exists a required math course that they do not like.

5. Prove by induction for all n  0, 0 + 2 + 4 + … + 2n < (n + 1)2 .

  1. Prove by induction for all n  1, if d | ai , i = 1,2,…,n, then dn | (a1a2 … an), where we assume that (a1a2 … an+1) = ((a1a2 … an)an+1).
  1. Let A be a set with 4 elements and let B be a set with 5 elements.

a)Find the number of different functions f: A  B.

b)Find the number of different binary relations R: A  B.

  1. Solve the following second-order linear recurrence, an = an-1 + 6an-2, with initial conditions

a0 = 1, a1 = 2.

  1. A 1 x n rectangle is constructed from 1 x 1 tiles that come in three colors, red, white, and blue. Find a recurrence relation (with initial conditions) for an, the number of 1 x n rectangles that can be formed with no two consecutive white squares.
  1. a) How many arrangements of the 9 letters in DIFFICULT begin with the letter D and end with the letter T? b) How many arrangements of the 9 letters in DIFFICULT have 2 consecutive F’s but not 2 consecutive I’s?
  1. In a mail-order catalog there are 20 different kinds of pants and 12 different kinds of shirts that can be ordered. a) How many sets of 5 pairs of pants and 5 shirts can be ordered if no repetition is allowed? b) Repeat a) if instead repetition is allowed.
  1. A poker hand contains 5 cards chosen from the standard deck (52 cards).

a)What is the probability that it contains at least one ace (out of 4 possible aces)?

b)What is the probability that it contains exactly two aces?

  1. The light in a car is controlled by 3 different switches. When switch A is on the light is always on. If switch A is off the light is on when either switch B is on or switch C is on (or both). Design a circuit with 3 input switches A, B, and C that operates the light in the desired manner.
  1. Design a finite-state automaton that reads in sequences of 0’s and 1’s accepting any sequence that begins with 01 or begins with 10.
  1. Prove that the following statements are true for any integer n.

a)If n is even, then n3 + 1 is odd.

b)If n3 + 1 is odd, then n is even (Hint: Proof by contradiction.).

The End

Sample Exam Math 42 ______

Professor Jackson Midterm 1 Name

One page of notes and a calculator allowed. Show your work for full credit.

  1. [8 points] What is the hexadecimal number 3C916 written in

a) decimal notation? b) binary notation?

  1. [8 points] The ceiling light in an automobile is controlled by three switches: an automatic switch in each door and a manual switch in the ceiling. When the ceiling switch is in the off position the light is always off and when the ceiling switch is on the light is on when one or both doors are opened. Design a circuit to contol the switches.
  1. [8 points] Write a negation for each of the following statements.

a)There exists a person P in Math 42 who hasn’t taken any computer science classes.

b)If it rains today then I won’t juggle outside.

c)I will turn in every homework assignment and pass every midterm in discrete math.

  1. [8 points] Determine whether or not the following argument is valid.

a)No surfer is willing to read.

b)All students read willingly.

c)All Santa Cruz residents are surfers.

No Santa Cruz resident is a student.

  1. [8 points] Use a truth table to determine whether or not the statements p  q and

(p  q)  (p q) are logically equivalent.

6. [8 points] Prove the following statements or find a counterexample.

a)For every positive integer n, n3 - n is divisible by 3.

b)For every positive integer n, n3 - n is divisible by 4.

7. [8 points] Use symbols to represent the logical form of the argument below and analyze it to determine whether or not it is a valid argument.

a)Bill must get a student loan or find a job if he wants to stay in school.

b)He can’t get a loan.

c)He definitely wants to stay in school.

He will find a job.

8. [8 points] Prove the following statement.

For all positive integers a,b,c, and d, if a|b and c|d then ac|bd.

The End

Professor Jackson Midterm #2 ______

Sample Exam Math 42 Name

One page of notes and a calculator allowed. Explain your answers for full credit.

1. [8 points] For every integer n  2, prove by induction that 1/(22 – 1) + 1/(32 – 1) + … + 1/(n2 – 1) < ¾ - (2n+1)/[2n(n+1)].

2. [8 points] Prove by induction for all n  1 that 52n – 1 is divisible by 6.

3. For any sets A,B,C, if A  B then (AxC)  (BxC).

4. For any sets A,B,C, if A  B  C then (A – C)  (A – B) = .

5. a) Find the number of different arrangements of the letters in COMMITTEE.

b) Find the number of different arrangements in a) that have two consecutive M’s, two consecutive T’s, and two consecutive E’s.

6. A party store has 10 different types of balloons. a) In how many different ways can a customer choose 30 different balloons (the order in which the balloons are selected is unimportant)? b) In how many ways can the 30 balloons be selected if at least two balloons of each type are selected?

7. A single die is rolled five times. a) What is the probability that the highest die rolled is equal to 6? b) What is the probability that the highest die rolled is equal to 6 and the lowest die rolled is equal to 1?

The End