##### Differences

This shows you the differences between two versions of the page.

 cs-236:homework-7 [2014/09/03 11:52]egm created cs-236:homework-7 [2018/11/30 17:25] (current)pdiddy [Problems] 2018/11/30 17:25 pdiddy [Problems] 2018/08/15 13:25 pdiddy 8th edition2017/11/02 15:38 jrtyler [Problems] 2017/11/02 15:37 jrtyler [Problems] 2017/11/02 13:17 jrtyler [Problems] 2017/11/02 13:16 jrtyler [Problems] 2017/11/02 12:48 jrtyler [Problems] 2016/09/13 10:44 gbspend [Problems] 2016/09/13 10:44 gbspend [Problems] 2015/10/29 09:58 egm [Problems] 2015/06/11 14:10 egm 2015/06/11 14:04 egm 2015/02/17 10:02 egm 2015/01/05 13:40 egm [Problems for all sections] 2014/09/03 11:52 egm created Next revision Previous revision 2018/11/30 17:25 pdiddy [Problems] 2018/08/15 13:25 pdiddy 8th edition2017/11/02 15:38 jrtyler [Problems] 2017/11/02 15:37 jrtyler [Problems] 2017/11/02 13:17 jrtyler [Problems] 2017/11/02 13:16 jrtyler [Problems] 2017/11/02 12:48 jrtyler [Problems] 2016/09/13 10:44 gbspend [Problems] 2016/09/13 10:44 gbspend [Problems] 2015/10/29 09:58 egm [Problems] 2015/06/11 14:10 egm 2015/06/11 14:04 egm 2015/02/17 10:02 egm 2015/01/05 13:40 egm [Problems for all sections] 2014/09/03 11:52 egm created Line 1: Line 1: - This homework covers sections 5.1 and 5.3 - ==Objectives== + The objectives are - * Practice inductive proofs applied to different problem domains + * Identify properties of relations - * Identify faulty reasoning in inductive proofs + * Apply relational operators (excepting join) + * Prove properties of relational operators + * Represent binary-relations as graphs + * Represent binary-relations as matrixes - ==Problems ​for all sections== + ==Problems== - All problems ​are worth 3 points. + The book notation and the class notation is slightly different. Here is how the two are related given that $R$ and $S$ are relations:​ + * The select operation is identified by $\sigma_C\ R$ in class, but $s_C(R)$ in the book. In both cases $C$ is an expression that determines when a row is ''​selected''​ and when it is not. + * The project operation is identified by $\pi_{i_1i_2i_3\ldots}\ R$ in class but $P_{i_1i_2i_3\ldots}(R)$ in the book. In both cases, the columns in the subscript are the columns that remain. + * The natural join operation is identified by $R \bowtie S$ in class, but $J_p(R,S)$ in the book. + * The book does not define a rename operation identified by $\rho_{A \leftarrow B}\ R$ to indicate that $A$ becomes $B$ in the schema. - # 5.1.4 + All problems are worth 3 points and reference problems in the course text. - # 5.1.6 + - # 5.1.10 + # (4 points) 9.1.4 (int'l 7.1.4) - # 5.1.18 + # (8 points) 9.1.6  ​(int'​l 7.1.6) - # 5.1.26 + # (2 points) 9.1.10 (int'l 7.1.8 also missing the word both before symmetric in part a) - # 5.1.38 + # (1 points) 9.1.12 (int'l 7.1.10) - # 5.1.42 + # (2 points) 9.1.38  ​(int'​l 7.1.36; 8th ed. 9.1.40) - # 5.1.50 + # (5 points) 9.1.50 (int'l 7.1.48; 8th ed. 9.1.52) - # 5.4.18 ''​'(Sections 1 and 2 -- don't do this problem)''​' + # (2 points) 9.2.26 (int'l 7.2.26) + # (2 points) 9.2.28 (int'l 7.2.28 change to Part_needs ​and Part_number) Express your answer to part a using $\pi$, $\sigma$, and $\rho$. + # (5 points) 9.3.14. Example 5 defines the $\circ$-operator. It relies on that $\odot$-operator that indicates Binary product. Binary product is defined in 2.6 example 8 (p. 182; 8th ed. p. 192) of the text. Intuitively $M_a \odot M_b$ is matrix multiplication only the multiply uses Boolean $\wedge$-operator to multiply two elements and the addition operator uses the Boolean $\vee$-operator to sum the multiplied elements. (int'l 7.3.14) + # (1 points) 9.3.28 ​ (int'l 7.3.28) If you see a point that is unlabeled, it should be an "​a",​ matching the position of the four points on the other problems. + # (1 points) 9.4.28 part a only (int'l presumably 7.4.28; 8th edition needs to be checked, as well)