subject

Barr the bear has started a business to sell fish to poe and his fellow penguins. the penguin customers submit many fish orders, but barr can only process one order at a time. suppose that barr currently has orders from n penguin customers (label them as 1, 2, . . , n). customer i’s order takes ti time to complete. barr is going to process each penguin’s order one by one, and the scheduling of orders can be described as a permutation of the customers. let ci denote the completion time of order i. for instance, if customer j’s order is the first to be completed, then we would have cj = tj (assume barr begins processing orders at time 0); if customer k’s order is the second to be completed after that, then ck = cj + tk = tj + tk, and so on. each customer is of different importance to barr’s business, and we denote this relative weight by wi (for customer i). barr wishes to minimize the weighted sum of the completion times of n orders, pn i=1 wi · ci . intuitively, the more important a customer is, the sooner barr wishes to complete the customer’s order. design an o(n log n) algorithm to solve this problem to barr. you are given a set of n orders with a processing time ti and a weight wi for each customer i (assume ti , wi are positive integers). you want to decide an ordering of the customer orders so as to minimize the weighted sum of the completion times. prove correctness of your algorithm (i. e., optimality) and analyze its runtime.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 20:20
Wireless communications is likely to be viewed as an essential part of an enterprise network infrastructure when: select one: a. mobile communication is needed b. communication facilities must be installed at low initial cost c. communication must take place in a hostile or difficult terrain that makes wired communication difficult or impossible d. the same information must be broadcast to many locations
Answers: 1
question
Computers and Technology, 22.06.2019 12:00
Which of the following does 3d animation create an illusion of on the screen? a. depth b. emotion c. length d. dialogue
Answers: 1
question
Computers and Technology, 23.06.2019 19:30
What are loans to a company or government for a set amount of time
Answers: 1
question
Computers and Technology, 24.06.2019 18:00
Hacer un algoritmo que me permita ingresar el nombre de una parcela de terreno y muestre junto al mensaje “tipo de suelos: suelos fumíferos, ¡excelente!
Answers: 1
You know the right answer?
Barr the bear has started a business to sell fish to poe and his fellow penguins. the penguin custom...
Questions
question
Mathematics, 27.05.2021 20:00
question
Mathematics, 27.05.2021 20:00
question
Mathematics, 27.05.2021 20:00
question
Mathematics, 27.05.2021 20:00
question
Mathematics, 27.05.2021 20:00
Questions on the website: 13722363