CS412 Assignment a couple of Ref Answer
Question one particular: Assume a base cuboid of 10 sizes contains just three foundation cells: (1) (a1, b2, c3, d4;..., d9, d10), (2) (a1, c2, b3, d4,..., d9, d10), and (3) (b1, c2, b3, d4,..., d9, d10), exactly where a_i! sama dengan b_i, b_i! = c_i, etc . The measure of the cube is count. you, How many non-empty cuboids will a full data cube contain? Response: 210 sama dengan 1024 a couple of, How many non-empty aggregate (i. elizabeth., non-base) skin cells will a complete cube consist of? Answer: You will have 3 в€— 210 в€’ 6 в€— 27 в€’ 3 = 2301 nonempty aggregate skin cells in the complete cube. The number of cells overlapping twice is 27 while the number of cells overlapping when is four в€— twenty-seven. So the final calculation is usually 3 в€— 210 в€’ 2 в€— 27 в€’ 1 в€— 4 в€— 27 в€’ 3, which in turn yields the result. 3, Just how many non-empty aggregate cells will an iceberg dice contain in case the condition of the 4, iceberg cube is " rely > sama dengan 2"? Answer: There are as a whole 5 в€— 27 sama dengan 640 nonempty aggregate cellular material in the iceberg cube. To calculate the actual result: fix the first 3 dimensions since (***), (a1**), (*c1*), (**b3) or (*c1b3), and differ the rest seven ones. 5, How a large number of closed skin cells are in the full cube? Answer: There're 6 shut cells in the full cube: 3 foundation cells; (a1, *, 5., d4, вЂ¦, d10); (*, c2, b3, d4, вЂ¦, d10): count number 2; (*, *, 5., d4,.., d10): count several. Question two: (Half open up questions, make sure your algorithm and assumptions happen to be correct, no requirement to be very specific) Suppose a base cuboid has the following tuples: A B C D Rely Sales a2 b1 c1 d1 one particular a1 b2 c2 d1 1 a1 b3 c1 d2 1 a2 b4 c1 d2 1 a2 b3 c2 d3 you 6 5 2 twelve 12
one particular, Show the rep steps to demonstrate how a full data dice (with Rely and SUM(Sales) as measures) is calculated by the multiway array assimilation algorithm; Answer (from fang2): Suppose measurements A, N, C, D are prepared into two, 4, a couple of, 3 partitioning respectively. So in total you will find 2*4*2*3 sama dengan 48 portions. The cardinality of sizes A, N, C, Deb is 2, 4, two, 3 correspondingly, i. at the. A and C have the smallest size, followed by M, and lastly W has the major sieze). From the base cuboid given, we can compute 3D-, 2D-, 1D- and top cuboids just as the plan. The amount scan buy is always 1st along the tiniest dimension, then simply along next smallest dimensions, then along 3rd littlest dimension, and so on. For example , once computing
3D-cuboids from the base cuboid, we all first scan chunks along the A dimensions, then C, D and B, through this ascending order of the scale the dimensions. In other words, we aggregates initially towards CDB, so only 1 chunk of CDB has to be held in memory space at any once; then aggregates towards ADB, so only 1 row of ADB needs to be held in recollection at any single time, so on etc. For calculation of 2D-, 1D- and apex cuboids, a similar approach is adopted, where the portions are sought first along the smallest measurements. During calculation of a cuboid, both steps (count and sales) happen to be aggregated.
two, Do the same using the BUC algorithm; and Answer (from duan9): Initially we buy the measurements in descending order by cardinality: BDAC. Then we certainly have the collectiong order inside the tree contact form:
At the beginning of the recursion, we all aggregate all of the dimensions to get the apex cuboid using the two measures: count number and total of sales. Then we all start partitioning the stand according to the pattern BDAC the following:
Through this recursive collectiong and rupture process we get the following cuboids: apex, M, BD, BDA, BDAC. Then we navigate back (as part of the recursion) and receive BDC, and traverse backside further we get BA, PARCHEMIN and so on. several, Do the same using the Star-Cubing algorithm. Solution (from duan9): First we order the dimensions as we did in BUC: BDAC. Based on the order, we have the following calculation ordering:
Then we build a Star-Tree for the base table. Since we are truly computing the complete cube, you cannot find any star on the star shrub. Similarly, it will have no compressed table (or you can do your own assumption and build the own compressed table).
Then simply we start off...