Advanced algorithms: Assignment 2
Due: 2 Aug 2004
- (10 points) The parallel algorithm for matrix-vector
multiplication, based on a 2-dimensional decomposition, distributed
the vectors b and c over the first colum of processors. Give an
efficient parallel algorithm that distributes it over the first row of
processors, and derive its time complexity.
- (10 points) Give two algorithms for matrix-vector multiplication,
one which has a cache complexity of O(n2) and another that
has a cache complexity of O(n2/L), under the ideal cache
model that we discussed.
- (10 points) Show how the randomized quicksort algorithm sorts the input 8, 7, 6, 5, 4, 3, 2, 1, given a floating point random number sequence 0.5, 0.25, 0.75, 0.3, 0.1, 0.9, 0.8, 0.6.
- (20 points) Given the following points: P = {(1,1), (2,1), (3,1), (1,2), (2,2), (3,2), (1,3), (2,3), (3,3)}, show the composite numbers that correspond to this, and construct a layered range tree from the composite numbers. Then show how this tree is used to search for all points in the region: x = 0.9, x' = 2.1, y = 2, y' = 3.
Last modified: 28 Jul 2004