Assignment on Algorithms and Dynamic programming

raguhmvnfg222
timer Asked: Nov 28th, 2014

Question Description

Algorithms project.pdf 

Hello Sir, Can you help me in doing this assignment? Thank you

Unformatted Attachment Preview

Final Project: File server allocation Introduction This problem is linked to the allocation of files on content distribution networks (CDN). In this problem we assume that each file can only be placed on a single server in the CDN. Each file will cause a bandwidth requirement on the server it is allocated to. The purpose of the problem is to find an allocation of the files on the server so as to minimize the bandwidth required by the server that requires the most bandwidth. Formally, the File Server Allocation (FSA) problem is defined by n files and m servers. Each file I has a bandwidth requirement b > 0. The purpose of the problem is to i choose for each file i a server S(i) ∈ {1, . . . , m} on which file i will be allocated. The total bandwidth requirement for server j is B(j) (sum of BWs for all files on server j) . The problem is to minimize max B(j).The purpose of the project is to provide both algorithmic solutions (algorithms, proofs, complexity, properties) AND implementation (code and evaluation) to obtain a higher understanding of the problem. Brute Force Design a brute force algorithm for the FSA problem. That is to say an algorithm that tries all the possible solutions for the problems and pick the best one. Dynamic Programming Design a dynamic programming algorithm for the problem. The key to designing the dynamic programming algorithm is to find the correct suboptimality property (optimal structure) in the problem. It is non trivial to exploit an optimal substructure in this problem.A way to think about the problem is to transform the optimization problem into a decision problem. That is to say, instead of trying to find the minimal max B(j), to try to decide whether there is a solution such that all machines have a B(j) ≤ B, where B is a parameter of the algorithm. A suggested way to design the algorithm follows (note that this is not the only way to design it): • Show how to solve the optimization problem assuming a blackbox algorithm for solving the decision problem. • Find a sub-optimality property on the decision problem (i.e., if this solution is feasible with this property, then that (smaller) solution is feasible with that property). Hint: encode the problem using m values that gives a budget in bandwidth for each server and one value that gives the number of files. • Deduce the dynamic programming formula. • Write the algorithm (either top-down or bottom-up). • Reconstruct the solution. Heuristic Design a heuristic algorithm for this problem. That is to say, design an algorithm that is not proven to be optimal but that should run faster than the previous two algorithms. Algorithm design This goes into the report. Provide the design for the 3 algorithms. That is to say, the report should include at least: • The algorithm itself (not code). To be clear on what level of details is expected: This should be clear enough so that a second year undergraduate student can simply read the explanation and be able to write the code that outputs the solution. In other word, give complete pseudo code. • An analysis of the time complexity of the algorithm. • An analysis of the memory complexity of the algorithm. • For the dynamic programming: – What problem is actually addressed by the dynamic programming (you might be using the decision version). And how does that relate to the FSA problem. – What is the sub-optimal structure leveraged by the dynamic programming, and the proof that this structure is correct. – The dynamic programming formula. – The complexity of the algorithm. Code The code should be written in Java, C or C++. It should be easy to read. And it should compile and run according to common practice. For easy testing, make one program per algorithm amd write the codes so that they take three parameters from the command line: the path to a file containing the bandwidth requirements b , the number of tasks n, and the number of servers m. The i file should contain the bandwidth requirement one per line. The file might be much longer than that n. Only use the first n lines of the file. Some instances will be provided. But feel free to create your own. The codes should output the solution to the problem. The time it took to compute the solution and the value of the objective (max B(j)) for this solution. j
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.

This question has not been answered.

Create a free account to get help with this and any other question!

Related Tags

Brown University





1271 Tutors

California Institute of Technology




2131 Tutors

Carnegie Mellon University




982 Tutors

Columbia University





1256 Tutors

Dartmouth University





2113 Tutors

Emory University





2279 Tutors

Harvard University





599 Tutors

Massachusetts Institute of Technology



2319 Tutors

New York University





1645 Tutors

Notre Dam University





1911 Tutors

Oklahoma University





2122 Tutors

Pennsylvania State University





932 Tutors

Princeton University





1211 Tutors

Stanford University





983 Tutors

University of California





1282 Tutors

Oxford University





123 Tutors

Yale University





2325 Tutors