Consider the Following List of Numbers

Consider the Following List of Numbers

Write down all elements of ({3, 4, 5} ∩ {4, 5, 6, 7}) ∪ {8, 9}. (Enter your answers as a comma-separated list.)

Consider the following list of numbers.

125, 687, 123, 513, 609, 53, 42

The height of a binary search tree is the maximum number of edges you have to go through to reach the bottom of the tree, starting at the root. What is the height of the tree for the numbers above, in the order given?

Define a function f : R→R by the formula

f(x) = 5x − 3.

define a function f : R→R by the formula f(x) = 5x − 3.

Prove that f is one-to-one.

Let a, bR, and suppose that f(a) = f(b).Then 5a − 3 = , so a = .

let G be the following directed graph.

style

Let V be the set of vertices in G and let E be the set of edges in G. This graph describes a function

i :E→V×V

where

i(e) = (a, b)

if edge e goes from vertex a to vertex b.
List the values of

i(e1), i(e2), ... , i(e8).

i(e1) / (a, b) / = /

i(e2) / (a, b) / = /

i(e3) / (a, b) / = /

i(e4) / (a, b) / = /

i(e5) / (a, b) / = /

i(e6) / (a, b) / = /

i(e7) / (a, b) / = /

i(e8) / (a, b) / = /

Let s be the following statement.

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

Give the contrapositive of s.

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

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

You are not studying hard and you are staying up late at night.

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

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

Use truth tables to establish the following equivalence.
Show that ¬(p∨q)

is logically equivalent to ¬p∧¬q.

This equivalence is one of De Morgan's laws, after the nineteenth-century logician Augustus De Morgan.

p / q / ¬p / ¬q / p∨q / ¬(p∨q) / ¬p∧¬q
T / T
T / F
F / T
F / F

Which derivation rule justifies the following argument?

If n is a multiple of 8, then n is even. However, n is not even. Therefore, n is not a multiple of 8.

modus ponens

modus tollens

simplification

double negation

De Morgan's Laws

Let Q be a quadrilateral. Given the statements

If Q is a rhombus, then Q is a parallelogram.
Q is not a parallelogram.

what statement follows by modus tollens?

Q is not a rhombus.

Q is a rhombus.

Q is a trapezoid.

Q may or may not be a rhombus.

Q is a square.

Write a statement that follows from the statement

It is cloudy and cold today.

by the simplification rule.

It is sunny today.

It is cloudy today.

It is either cloudy and cold today, or cold today.

It may or may not be cloudy today.

It is cloudy or cold today.

Let the following predicates be given. The domain is all mammals.

L(x) / = / "x is a lion."
F(x) / = / "x is fuzzy."

Translate the following statement into predicate logic.

All lions are fuzzy.

(∀x)(F(x) →¬L(x))

(∀x)(L(x) →F(x))

(∀x)(¬L(x) →F(x))

(∃x)(L(x) ∧F(x))

(∀x)(F(x) →L(x))

Consider the following theorem.

Theorem. Let x be a mabapie. If x has been schlumpfed, then x is a borfin.

Give the contrapositive of this theorem.

Let x be a borfin. If x has been schlumpfed, then x is a not mabapie.

Let x be a borfin. If x is not a mabapie, then x has not been schlumpfed.

Let x be a borfin. If x is not a mabapie, then x has been schlumpfed.

Let x be a mabapie. If x has been schlumpfed, then x is a not borfin.

Let x be a mabapie. If x is not a borfin, then x has not been schlumpfed.

Consider the following definitions.

Definition. An integer n is alphic if n = 4k + 1for some integer k.
Definition. An integer n is gammic if n = 4k + 3for some integer k.

Show that 23 is gammic.23 = 4

+ 3

Find a counterexample for the statement.

For every real number N > 0, there is some real number x such that

Nxx.

N =

Find a counterexample for the statement.

If p is prime, then

p2 + 4

is prime.

p =

Consider the following theorem.

Theorem. Let x be a quagrel. If x has been dorfelled, then x is a domel.

Give the converse of this theorem.

Let x be domel. If x is a quagrel, then x has been dorfelled.

Let x be quagrel. If x is a domel, then x has been dorfelled.

Let x be a quagrel. If x has been dorfelled, then x is not a domel.

Let x be domel. If x is a quagrel, then x has not been dorfelled.

Let x be a domel. If x has been dorfelled, then x is a quagrel.

Use a truth table to show that

p→q
¬p
/
¬q

is not a tautology. (This example shows that substitution isn't valid for inference rules, in general. Substituting the weaker statement, q, for the stronger statement, p, in the expression "¬p" doesn't work.)

p / q / p→q / ¬p / (p→q) ∧¬p / ¬q / ((p→q) ∧¬p) →¬q
T / T
T / F
F / T
F / F

Let s be the following statement.

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

Give the converse of s.

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

You are not studying hard and you are staying up late at night.

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

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

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