Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A cookie manufacturer has two warehouses W 1 and W 2 , from which identical boxes of cookies are to be shipped to n stores

A cookie manufacturer has two warehouses W1 and W2, from which identical boxes of cookies are to be shipped to n stores Si, for i = 1,...,n. Let si be the number of boxes of cookies ordered by Si, for i = 1,...,n, and w1,w2 be the numbers of boxes of cookies available at W1,W2, respectively. Assume that there are exactly enough boxes of cookies available to fill the orders, i.e., w1 +w2 = image text in transcribed . Let cki be the cost of shipping one box of cookies from Wk to Si, for k = 1, 2 and i = 1, . . . , n. To minimize the shipping cost, the cookie manufacturer wishes to determine the actual number of boxes of cookies to send from Wk to Si, denoted by xki for k=1,2 and i=1,...,n such that:

the order made by Si is filled, i.e., x1i+x2i = si, fori=1,...,n

the inventory at Wk is exactly sufficient, i.e., image text in transcribed , for k = 1,2

and the total shipping cost, image text in transcribed , is minimized.

Question (a): Let g(j, x) be the cost incurred when W1 has an inventory of x boxes of cookies and the cookies are sent to store Si for i = 1,...,j in the optimal manner. Write a recursive definition for g(j, x).

(Note that W2 is not mentioned because knowledge of the inventory for W1 implies knowledge of the inventory for W2 since w1 + w2 = image text in transcribed . i.e., if y is the inventory available at W2, then image text in transcribed )

Question (b): Use this recurrence to devise a dynamic programming algorithm to compute the minimum shipping cost to fill all orders.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Professional Visual Basic 6 Databases

Authors: Charles Williams

1st Edition

1861002025, 978-1861002020

More Books

Students also viewed these Databases questions