• Tidak ada hasil yang ditemukan

MODELS INVOLVING NONLINEAR COSTS

Dalam dokumen Introduction to Distribution Logistics (Halaman 101-106)

B.8 For further reading

2.3 MODELS INVOLVING NONLINEAR COSTS

The careful reader has certainly noticed something strange in the last model we have considered: \Thy didn’t we consider the possibility of shipping goods directly from a factory t o a retail store? Extending the model by the inclusion of a new set of decision variables. say z , ~ , to model the direct flow from factory z to retail store J would be rather trivial; we just have t o adjust constraints on outflows from factories and on inflows t o retail stores. The real issue is t h a t this linear model is not able t o capture economies of scale.

Since the objective function includes linearly variable transportation costs.

if it is convenient t o ship a large amount directly rather t h a n through the distribution center. this will also be the case for a small amount. SVhat we observe in practice is t h a t direct shipments are used only for large demand volumes at destination. The reason, as we have hinted at in section 2 . 1 . 2 . is that we must achieve economies of scale in transportation. We should better represent costs. which are actually nonlinear. In fact, equation ( 2 . 7 ) on page 63, despite its limitations. suggests that the cost associated t o a transportation link is not only a nonlinear function of flow, which in this case is essentially given by demand d per unit time: this function is also concave. because it includes the square root of d.I3 Concave cost functions model economies of scale. The total cost function of the Economic Order Quantity model offers a similar suggestion.

The actual cost associated with transportation flows on a link, with inven- tory holding. and with material handling at a facility is a comp1icatc.d function depending on dynamic system behavior. At the network design level. we must settle for a suitable approxiniation by some anticipation function, aggregating costs on a relatively long-term horizon: then we may validate the solution we have obtained by simulating operational decisions. One possible approach is t o postulate some functional form. like

where C is the cost per unit time. V is the flow volume. and u and 3 are coefficients we should estimate. For values of 3 such a h 0.5 or 0.8. this cost function is concave. One possible way of finding suitable values for the coef- ficients in the assumed functional forin is by analyzing approximate models.

An interesting alternative is carrying out siniulation experiments and then

I3See section B.3 for t h e definition of convex a n d concave functions.

fitting a functional form against experimental results. e.g., by least-squares methods (see section A.10.6).14

Introducing a nonlinear cost function in a network optimization model may significantly change the nature of the model, the nature of the solution, and the computational effort to get this solution by solving the model:

In general, nonlinear programming models are harder to solve than their linear counterparts. and this may limit the size of the model we can afford t o tackle.

Location models involve binary decision variables; solving a nonlinear mixed-integer model may be difficult.

Recent research has spawned a host of efficient algorithms for general convex optimization. and solvers have been introduced for nonlinear mixed-integer programming. Regrettably, minimizing a concave func- tion is not a convex problem. For a model with a nonconvex objective.

even solving a continuous relaxation within a branch and bound strategy (see section B.6.1) may be difficult because of potential local optima.

We should use possibly demanding global optimization methods.

Even if we refrain from dwelling too deeply in algorithmic details. we imme- diately see th at solving a suitably accurate network optimization model may be a time-consuming task. Network design is not a real-time decision-making task and that possibly significant savings are involved by proper analysis;

hence. much CPU time can be afforded, but if we want to play with alterna- tive scenarios to get a robust solution. we should try to keep computational requirements as low as possible.

One way out of this difficulty is approximating a nonlinear cost function by a piecewise-linear function, like those illustrated in figure 2.7. Given a function f ( z ) . we can define a set of “knots” z(’) which separate intervals over which the function is approximated by a linear piece. Determining how many linear pieces are needed and how knots should be placed requires some skill and experience. but we see th at we may boil down a possibly complex model to a linear programming model. The nature of the function dictates if this may be solved as a continuous linear programming model or if mixed- integer modeling is necessary. We have the first case when the function we approximate is convex. so that its approximation may be convex too. For instance. let us consider a function like

14The approach of using a simulation model t o build an approximate analytical model is called meta-modeling.

MODELS INVOLVING NONLINEAR COSTS 85

Fig. 2.7

cave. (c) neither convex nor concave.

Piecewise approximations of nonlinear functions f ( z ) : ( a ) conwx. (b) con-

modeling a cost depending on the level 5 of some activity. If c1 < c2 < c3. like the case of figure 2.7a. then marginal costs are increasing: in other words we have a diseconomJ- of scale. which is represented by a convex cost function.

If. on the contrary. c1

>

c2

>

c3, marginal costs are decreasing and we have a concave function displaying economies of scale, as depicted in figure 2.7b.

In our applications. this is the case most likely to occur, but in principle we might have the case of a generic function. like in figure 2 . 7 ~ .

If the piecewise linear function is convex, its minimization is easily recast as a continuous linear program which can be efficiently solved. We have to transform the function f ( z ) into the sum of linear terms. depending on auxiliary variables. say y1. y2. and y3 if the function consists of three pieces:

fig. 2.8 Modeling a nonconvex piecewise linear function.

In practice, each variable yz is associated with an interval, and the original variable is expressed as the sum of auxiliary variables. In order for this ap- proximation to work properly, auxiliary variables should be “activated” in the correct order. First we use y1. and we should activate further variables only if 2

>

x ( l ) ; in other words, each “subinterval” must be saturated before using the next one. But since in the convex case we have c1

<

~ 2 % y2 will be positive in the optimal solution only if y1 reaches its upper bound ~ ( ~ 1 . We will not use yy~ in place of y1. unless strictly necessary. because y2 is more expensive to use. By the same token, y3 is activated only if both y1 and y2 reach their upper bounds.

This reasoning applies for the minimization of a convex function, or the maximization of a concave one. But if we are minimizing a concave function, due to decreasing marginal costs, the solution algorithm would find it advan- tageous to use variable y3 first, because it is the cheapest one. Of course this is no surprise. because we cannot expect to recast a nonconvex problem into a convex one. However. we may trade one nonconvexity for another one, by transforming the model into a mixed-integer linear programming model. The trick is associating a binary decision variable with each interval, making sure tha t only one interval is used. To see the idea. let us refer t o figure 2.8, in which the piecewise linear approximation is encoded by a set of points of co- ordinates (z,. yz). where yz = f ( z , ) . i = 0 , 1 . 2 , 3 . Each point on the segment from (zc2.yz) to (x,+1.yz+1) can be expressed as a convex combination15 of

I5A convex combination of a n arbitrary number points in Rn is j u s t a linear combination of those points, such t h a t weights are non-negative and their sum is 1. Given a set of points S. the set of all of the possible convex combinations of them is called the conuez hull of S.

MODELS INVOLVING NONLINEAR COSTS 87

those two extreme points:

J: = xz,

+

(1 - A)Z,+l.

Y = AY,

+

(1 - A ) Y 2 + 1 %

where 0

I

A

I

1. Now. let us see what happens if we form a convex comhi- nation of all four points:

3

i=O 3

i = O 3

z=O

M-hat we get is not really the piecewise linear function. but rather the convex hull of the four knots. which is depicted as the shaded area in figure 2.8.

Nevertheless, we are close to our aim. JVe should find a way to enforce the use of only pairs of adjacent points in forming the convex combinations. In other words, only pairs of adjacent coefficients A, can be positive. For instance.

if A 0 and A 1 are allowed to take positive values. whereas A2 and A:3 are stuck a t zero, we get the first line segment: if only A 1 and A2 are free. me get the second one. and so on. To accomplish this. we may introduce a set of three binary variables, s,. z = 1.2.3, one for each segment (z - 1. i), and link these variables to the weights A, by the following constraints:

CS.= 1. s, E (0. l}.

2 = 1

This may look like a rather involved trick. but many software packages for mathematical programming ease the burden of introducing binary decision variables b) just requiring the knots of the approximation. and automating the generation of auxiliary variables. However. it is important to realize what’s happening behind the scenes: when we approximate a nonconvcx function in a mininiization problem, we introduce binary decision variables. and the resulting model may be hard to solve. l y e must be careful in striking a suitable compromise between accuracy of the approximation and the computational effort for solving tht. resulting model.

While we are discussing modeling by binary variables. we should also men- tion another typical modeling trick. To motivate it. suppose that we are considering the use of some transportation link, which should not be used if flow traveling on it is below a certain minimal threshold. Note that we are not saying that a certain activity level x must lie in the range [L, U ] , where L and U are lower and upper bounds, respectively. Doing so would enforce a strictly positive value of x; however, what we want to express is that zf x is positive. then it must stay within t h at interval. hlore formally, the feasible region for z is (0) U [L, U ] . Since this set is not convex,16 we cannot just re- sort to continuous linear programming. Yet. we may express the requirement within the mixed-integer linear programming framework, by introducing a bi- nary decision variable s, set to 1 if the service is activated (x

>

0). and set t o 0 otherwise. Our aim is easily accomplished by the following constraints:

x

2

Ls, x 5 us.

We see that if s = 0, then x = 0; if s = 1, then x E [L. U ] .

Dalam dokumen Introduction to Distribution Logistics (Halaman 101-106)