Question: 1 . Ecosystem Restoration in Algorithmia A wildlife conservation team in the land of Algorithmia is working on an ecosystem restoration project in a large
Ecosystem Restoration in Algorithmia A wildlife conservation team in the land of Algorithmia is working on an ecosystem restoration project in a large forest. They have identified n small water bodies ponds at locations x yxn yn To create larger habitats for aquatic life, they plan to merge the two closest ponds, reducing the number of ponds in the forest to n Since the researchers will merge the ponds by digging around a grid of trees, to find the two closest you will use Manhattan distance, aka dxi yixj yjxi xj yi yj Assumption: the coordinates are integers, but possibly large ones. You cannot use Radix Sort for this problem. a Design a deterministic On logn time algorithm for finding the two closest ponds. We are expecting: English description, pseudocode, and running time analysis. No proof of correctness required! Hint: A brute force algorithm that computes the distance between each pair of ponds takes On Back in section when we tackled the Maximum Sum Subarray problem, we used a divideand conquer approach to optimize our brute force algorithm for that problem from On to On log n Would a similar approach help us here again? The following fact may be useful: Fact There is some constant c aka c O such that in a d d square, there can be at most c ponds that are all distance at least d from each other. You can have a lot of fun trying to compute c but we advise that you do it only after finishing your homework!
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
