subject

You are consulting for a trucking company that does a large amount of business shipping packages between New York and Boston. The volume is high enough that they have to send a number of trucks each day between the two locations. Trucks have a fixed limit W on the maximum amount of weight they are allowed to carry. Boxes arrive at the New York station one by one, and each package i has a weight wi. The trucking station is quite small, so at most one truck can be at the station at any time. Company policy requires that boxes are shipped in the order they arrive; otherwise, a customer might get upset upon seeing a box that arrived after his make it to Boston faster. At the moment, the company is using a simple greedy algorithm for packing: they pack boxes in the order they arrive, and whenever the next box does not fit, they send the truck on its way. But they wonder if they might be using too many trucks, and they want your opinion on whether the situation can be improved. Here is how they are thinking. Maybe one could decrease the number of trucks needed by sometimes sending off a truck that was less full, and in this way allow the next few trucks to be better packed. Required:
Prove that, for a given set of boxes with specified weights, the greedy algorithm currently in use actually minimizes the number of trucks that are needed. Your proof should follow the type of analysis we used for the Interval Scheduling.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 00:30
At an open or uncontrolled intersection, yield if a. your road is paved and the crossroad is not b. the cross road is paved and yours is not c. you have two or more passengers in your vehicle d. you did not yield in the last intersection
Answers: 1
question
Computers and Technology, 22.06.2019 12:30
An atom's diameter is about 0.1 nanometer (1×10-9m), and a human hair is about 1×10-3m. how many times greater is a human hair than an atom's diameter? sorry pushed wronf button but this is math
Answers: 3
question
Computers and Technology, 24.06.2019 08:30
Why might you choose to create a functional resume
Answers: 1
question
Computers and Technology, 24.06.2019 13:20
In the insert table dialog box, you select the checkbox to create the first row as the header of the table.
Answers: 3
You know the right answer?
You are consulting for a trucking company that does a large amount of business shipping packages bet...
Questions
Questions on the website: 13722363