Design an efficient algorithm that chooses a subset

Assignment Help Data Structure & Algorithms
Reference no: EM133074036

Question 1: Consider the flow network drawn in the figure below, with a starting flow f in blue (assume all edges without a blue number have flow 0). Starting with the flow f, simulate the Ford-Fulkerson

2172_figure.jpg

Figure 1: Black numbers are capacities, blue numbers are flow.

algorithm to find a maximum flow on this network. A complete answer will contain a list of successive augmenting paths and, for each augmenting path chosen, a picture of the new flow network after augmenting the flow along that path. Finally, list every minimum capacity cut on this network.

Question 2: Suppose that G is a flow network such that every edge in G has the same capacity d. Construct an algorithm that outputs a maximum flow on G in 0 (|V||E|) time (note the run time does not depend on d).

Question 3: Let G = (V, E) be any flow network with edge capacities c(e), let U be any minimum capacity s-t cut in G, and let (u, v) ∈ E be any edge such that u ∈ U, v 1428_notin.jpg U. Prove that in any maximum flow f on G, f (u, v) = c(u,v) (that is, the edge (u, v) is fully saturated with flow).

Question 4: You are planning seating for a wedding, and would like to mix-and-match people from different families so that everyone can mingle. However, you only have a limited number of tables which can each seat a limited number of people. To solve this problem, you will come up with a general algorithm that can either match people to tables so that no two people from the same family are seated at the same table, or determine if it is impossible to do so.

The input to the algorithm will be the following. You are given a list of n positive integers f1,...., fn, where fi is the number of people in the ith family, as well as m positive integers t1,t2 tm where tj represents the number of people that can be seated at table j. Give an efficient algorithm that will decide if it is possible to seat everyone at the tables so that no two members from the same family are seated at the same table.

Question 5. The Montreal Jazz Fest is on this summer, and you know what that means: it's time to make some money by selling bootleg recordings! You have a list of the events that are being played at the Jazz Fest, namely: their start times, the length of each event, and also the location at which the event is playing. However, it may be impossible to attend every event in order to make a bootleg recording, so, you will have to hire some accomplices to help you out Naturally, in order to maximize your profit, you would prefer to figure out the minimum number of people you need to hire in order to cover every single event. Being a computer scientist, you decide to come up with an algorithm to solve the job.

Give an efficient algorithm for the following problem. As input, you receive a list of locations L1,....Lm and a list of events E1...E2,...En occuring on a single day, where each event Ei is specified by a start time an event length 4, and the location Li that the event occurs at (you may assume that all events are scheduled so that no two overlap at the same location). You also receive a list of integers tii for each pair of locations Li, Lj that represents the travel time from location i to location j in minutes. Your algorithm should determine the fewest number of people required to attend all of the events, and output an event schedule for each of the persons.

Question 6. Suppose you have a computer with n applications. Let's (imaginatively) call these applications A1, A2,.....An. You would like to update some of these applications to their latest and greatest versionst; however, there may be new problems introduced between the newly updated applications and legacy software. Your goal is to figure out how to choose a subset of applications so that your overall benefit is maximized.

As input, you receive a list of applications A1, ..... An and subset S ⊆ [n] of applications that have available updates. For each i ∈ S, the input contains a positive integer bi representing the benefit you get by updating that application. Finally, for each (unordered) pair of applications Ai, Aj, the input contains a positive integer xij which represents the penalty you have to pay if you update one application and not the other application. Design an efficient algorithm that chooses a subset U ⊆ S of the applications to update in order to maximize the quantity.

i∈U bi - ∑i∈U,i1428_notin.jpgU xij

Reference no: EM133074036

Questions Cloud

Calculate the price of the bond : Crane issued $490,000 of 5%, 5-year bonds on January 1, 2021. Interest is payable semi-annually. Calculate the price of the bond
What should the final repayment be : Given a rate of inflation of 3.5% per annum during the period, and if Beta's real cost of the loan is 16% per annum, what should the final repayment be
Analysis of the super bowl : State tax dollars were used to fund the Glendale, Arizona Super Bowl. Which of the following people would you count in an economic impact analysis of the Super
Appraise the role of treasury management : For TATA Motors Corp., candidates are required to identify an actual, or potential, major strategic decision which impacts, or has impacted, on significant fina
Design an efficient algorithm that chooses a subset : Design an efficient algorithm that chooses a subset U ? S of the applications to update in order to maximize the quantity
Calculate the stock price after the recapitalization : It will issue $570,798 of perpetual debt to repurchase its stocks. If its tax rate is 31.1%, calculate the stock price after the recapitalization.
Calculate the npv of the project : YYY is a company considering a new capital budgeting project. The project requires an initial investment in a machine with a cost of $250,000.
Reasons for the saving and loan crisis of the 1980 : What does that episode tell us about the regulation of financial institutions in the 21st Century? Do you think that we, as a financial system
How many years does this bond have left till maturity : A corporation has 9.0% coupon bond with YTM of 8.2%. The current market value of the bond is $1,057.00, and the coupon payments are paid annually.

Reviews

len3074036

1/26/2022 9:28:22 PM

READ THE INSTRUCTIONS VERY CAREFULLY AND DO EVERY LITTLE SUBSECTION THAT IS REQUESTED!

Write a Review

Data Structure & Algorithms Questions & Answers

  Implement an open hash table

In this programming assignment you will implement an open hash table and compare the performance of four hash functions using various prime table sizes.

  Use a search tree to find the solution

Explain how will use a search tree to find the solution.

  How to access virtualised applications through unicore

How to access virtualised applications through UNICORE

  Recursive tree algorithms

Write a recursive function to determine if a binary tree is a binary search tree.

  Determine the mean salary as well as the number of salaries

Determine the mean salary as well as the number of salaries.

  Currency conversion development

Currency Conversion Development

  Cloud computing assignment

WSDL service that receives a request for a stock market quote and returns the quote

  Design a gui and implement tic tac toe game in java

Design a GUI and implement Tic Tac Toe game in java

  Recursive implementation of euclids algorithm

Write a recursive implementation of Euclid's algorithm for finding the greatest common divisor (GCD) of two integers

  Data structures for a single algorithm

Data structures for a single algorithm

  Write the selection sort algorithm

Write the selection sort algorithm

  Design of sample and hold amplifiers for 100 msps by using n

The report is divided into four main parts. The introduction about sample, hold amplifier and design, bootstrap switch design followed by simulation results.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd