Exam Template v1.0

advertisement
UNIVERSITY OF ABERDEEN
SESSION 2005-2006
Sample questions for CS1512 (topics: logic and HCI)
(Date …)
(time ….)
.
1. The formula (pq) (qp) is
(a) a tautology V
(b) a contingency
(c) a contradiction
(d) a combination of two or more of the above
2. The number of rows in a truth table for a propositional formula in which there occur exactly 6 variables (i.e., 6
propositional letters) is
(a) 32
(b) 64 V
(c) 144
(d) 16
3. Which of the following sets of logical connectives is functionally complete?
(a) {}
(b) {}
(c) {,,} V
(d) {set complement, set intersection}
4. Consider the following (somewhat unusual) syntax definition:
Each propositional letter is a formula: p1,p2,…
The negation of each propositional letter is a formula: p1,p2,…
If  is a formula then  is a formula.
If and  are formulas then () is a formula
According to this definition (without any simplifying conventions), which of the following statements is true
(a)
(b)
(c)
(d)
p1 is a formula but p1 is not a formula
neither of p1 and p1 is a formula
(p3p5)p6 is a formula
p1, p1, p1 , p1, p1, , p1, p1 are all formulas
V
5. Out of the following formulas, which pairs are logically equivalent?
Formulas: (1) pq
(2) qp
(3) qp
(4) (qp) (pq)
(a)
(b)
(c)
(d)
2 and 4
1 and 2
2 and 4
1 and 4
V
TURN OVER
Examination in CS3511 (Discrete Methods)
- 2 of 3 -
May/June 2005
6. Which of the following statements are true?
Statements: (1) It follows logically from (qq) that p
(2) It follows logically from p that (qq)
(3) It follows logically from p that qp
(4) It follows logically from p and pq that q.
(a) All V
(b) None
(c) Just one
(d) Just two
7. In predicate logic, which of the following are well-formed formulas (assuming that F and G are one-place predicates)?
(You may assume that all the usual simplifying conventions are in place.)
(1) xy
(2) F(a)  G(b)
(3) x(F(x)  G(x))
(a)
(b)
(c)
(d)
all
none
just 2 and 3
just 3
V
8. Which of the following ‘models’ (i.e., situations) makes the formula xy(x adores y) true while making the formula
yx (y adores x) false. Each of the following models contains 3 people m1, m2, m3, and nothing else:
(a)
(b)
(c)
(d)
Model a: No one adores anyone.
Model b: Everyone adores everyone.
Model c: everyone adores just himself. V
Model d: m1 adores m1 and m2; m2 adores m1; m3 adores m1 and m2 and m3.
9. Which of the following statements is false:
Electronic circuits are optimised (using e.g. Karnaugh diagrams) because, in comparison with non-optimised ones
(a) they have a more regular and elegant form V
(b) they take up less space
(c) they generate less heat
(d) they are cheaper to manufacture
10. Which of the following statements are true.
Statements: (1) every propositional logic statement is equivalent to a sum of maxterms
(i.e. to a disjunction of disjunctions of literals)
(2) every propositional logic statement is equivalent to a product of minterms
(i.e. to a conjunction of conjunctions of literals)
(a)
(b)
(c)
(d)
none of the above
both of the above
1 but not 2
2 but not 1
V
11. If we disregard the carry, then which connective implements addition (summation) of digital numbers?
(a)
(b)
(c)
(d)
NAND (i.e., the Sheffer stroke, which is the negation of the conjunction)
Conjunction (i.e. AND)
Inclusive disjunction
Exclusive disjunction V
TURN OVER
Examination in CS3511 (Discrete Methods)
- 3 of 3 -
May/June 2005
12. Which of these expressions denote the same set: (Z is the set of all integers; R is the set of all real numbers.)
Set expressions:
(1) {x  Z: x>4  x<3}
(2) {x  R: x+1 > x}
(3) {x  Z: x-x =0}
(a)
(b)
(c)
(d)
1 and 3 only
none of the three
all three V
1 and 2 only
13. Suppose you want to check whether two expressions denote the same set. Both expressions contain 8 constants
(i.e., 8 names of sets). What might constitute a good reason against using a membership table:
Reason 1: the membership table would take too long to construct
Reason 2: membership table do not always give the right answer to such questions
(a)
(b)
(c)
(d)
Both 1 and 2
Neither of 1 and 2
1 not 2 V
2 not 1
14. Which statement describes HCI best?
Statements: (1) HCI is the art of writing readable computer programs
(2) HCI is the art of constructing computer programs and systems that are easy and effective to use
(3) HCI is the art of testing programs with all legitimate inputs
(4) HCI is the art of giving disabled people the best possible chance
to use computing systems and programs easily and effectively
V
15. Suppose someone claims to have invented an interface that is easy to use. How would you expect them to substantiate
their claim?
(1) By experimentation with human subjects
(2) By proving their claim mathematically
(a)
(b)
(c)
(d)
1 not 2 V
2 not 1
1 and 2
neither 1 nor 2
16. Suppose you want to convert equivalence laws of propositional logic into ones of set theory. This can be done by
(a)
(b)
(c)
(d)
replacing  by ,  by ,  by set complement , T by the domain, and F by the empty set.
replacing  by ,  by ,  by set complement, T by the domain, and F by the empty set. V
replacing  by ,  by ,  by set complement, F by the domain, and T by the empty set.
leaving everything exactly as it is
17. Which of these statements describes the relation between propositional logic (P) and set theory (S) best?
(a) P and S are essentially the same
(b) S is essentially the same as P, except that S does not have anything analogous to truth tables
(c) S is essentially the same as P, except that P does not have anything analogous to set builder notation (i.e. the
notation {x  A: ….}
V
(d) P and S are entirely different formalisms, of which it would be difficult to say what they have in common
TURN OVER
Examination in CS3511 (Discrete Methods)
- 4 of 3 -
May/June 2005
18. The set expression A(B1B2B3B4B5) is equivalent to
(a)
(b)
(c)
(d)
(AB1)(AB2 (AB3)  (AB4)  (AB5)
A( B1’B2’B3’B4’B5’)
A( B1’B2’B3’B4’B5’)
(AB1)(AB2)(AB3)(AB4)(AB5) V
19. The propositional logic expression pr is logically equivalent to
(a)
(b)
(c)
(d)
pq
rr
pr
rp
V
20. If the predicate logic expression yx Rxy is true, then the following formulas must also be true:
(a)
(b)
(c)
(d)
xyR(xy) V
xyR(xy)
xyR(xy)
xyR(xy)
21.If the predicate logic expression yF(y) xG(x) is true, then the following formulas must also be true:
(a)
(b)
(c)
(d)
y(F(y)G(y))
xF(x)
V
yx(F(y)G(x)xy)
yF(y) xG(x)
22. If the predicate logic expression yF(y) xG(x) is true, then the following formulas must also be true:
(a)
(b)
(c)
(d)
y(F(y)G(y)) V
xF(x)
yx(F(y)G(x)xy)
xF(x) xG(x)  yx(xy)
23. The following trends can be discerned in the history of ergonomics/HCI after the second world war:
(a) From adapting tools to people, to adapting people to tools
(b) From military, towards exclusively peaceful applications
(c) From adapting people to tools, towards adapting tools to people
(d) From number crunching towards experimentation with human users
24. The affordances of a tool (in the terminology of Donald Norman) are those of its properties which
(a)
(b)
(c)
(d)
Make it look better than its competitors in the marketplace
Make it more affordable than its competitors in the marketplace
Determine its price
Suggest how it may be used. V
25. The formula (pq) (q((rs)((pr)s))) is
(a) a tautology V
(b) a contingency
(c) a contradiction
(d) a combination of two or more of the above
TURN OVER
Examination in CS3511 (Discrete Methods)
- 5 of 3 -
May/June 2005
26. The formula  ((pq)(qp)) is
(a) a tautology
(b) a contingency
(c) a contradiction V
(d) a combination of two or more of the above
27. Consider the following (somewhat unusual) syntax definition:
Each propositional letter is a formula: p1,p2,…
The negation of each propositional letter is a formula: p1,p2,…
If  is a formula then () is a formula.
If and  are formulas then  is a formula
If and  are formulas then  is a formula
Call a formula ambiguous if it can be construed using the syntax rules in more than one way.
This syntax
(a)
(b)
(c)
(d)
makes p1p2 an ambiguous formula.
makes p1p2 an ambiguous formula.
makes p1p2p3 an ambiguous formula. V
makes ((p1)) an ambiguous formula.
28. The formula pp (where  is the exclusive or) is
(a) a tautology
(b) a contingency
(c) a contradiction V
(d) a combination of two or more of the above
29. The formula p|p (where | is the NAND or Sheffer stroke) is equivalent to
(a) p
(b) p V
(c) pp
(d) pp
30. What does it mean to say that a formula  is a tautology? It means that  …
(a)
(b)
(c)
(d)
is syntactically wellformed
cannot be false, regardless of how whether the propositional variables in  are true or false
cannot be true, regardless of how whether the propositional variables in  are true or false
can be true or false, depending on whether the propositional variables in  are true or false
TURN OVER
Examination in CS3511 (Discrete Methods)
- 6 of 3 -
May/June 2005
TURN OVER
Download