You are on page 1of 10

COMP 3700, Homework #1 Key (1) See Figure 1.

Figure 1

(2) See Figure 2.

Figure 2

(3) See Figure 3.a 3.h.

Figure 3.a

Figure 3.b

Figure 3.c

Figure 3.d

Figure 3.e

Figure 3.f

Figure 3.g

Figure 3.h

(4) See points below. a. Aggregation; capital cities are parts of countries. More specifically, it passes the transitive closure test, capital cities are always associated to countries and vice versa, and some operations of countries apply to the country's capital cities as well. b. Association; forks and dining philosophers are separate entities that happen to be related by eating. c. Generalization; ordinary and directory files are files, but not vice versa. The former add extra information to the latter but can be treated as full instances of the latter. d. Aggregation; files generally consist of records, whether there be zero records, one record, or many records. The records taken together are the file. It passes the transitive closure test and the relatedness test. e. Generalization; a polygon is an ordered set of points, but an ordered set of points isn't necessarily a polygon. Since ordered sets of points are therefore the more general entity, and since they don't require the existence of polygons in their definition, it can't really be an aggregation. f. Generalization; three types of geometrical objects are given. g. Ternary association; generally unrelated related by this particular association. h. Generalization; mouse and keyboard are tpes of input device. i. Aggregation; classes are partially comprised of their attributes; that is, a class is a collection of information of which attribute is one kind. j. Ternary association; person, team, and year are fundamentally unrelated except in the specific instance in which the association applies. k. Aggregation; any definition of a route will consist of an origin and a destination. These are fundamental parameters for the structure. l. Association; again, the three things are related by this association, but in general they do not need to be.

(5) See Figure 5.

Figure 5

You might also like