The NETFLOW Procedure

Example 5.7: Using a Constrained Solution Warm Start

Suppose the 25-inch screen TVs produced at factory 1 in May can be sold at either shop with an increased profit of 40 dollars each. What is the new optimal solution? Because only arc costs have been changed, information about the present solution in DUALOUT=dual4 and CONOUT=con4 can be used as a warm start in the following PROC NETFLOW run. It is still necessary to specify CONDATA=con3 SPARSECONDATA RHSOBS='CHIP/BO LIMIT', since the CONDATA= data set is always read.

  
   title 'Using a Constrained Solution Warm Start'; 
   title2 'Production Planning/Inventory/Distribution'; 
   data new_con4; 
      set con4; 
      oldcost=_cost_; 
      oldflow=_flow_; 
      oldfc=_fcost_; 
      if _tail_='f1_may_2' 
         & (_head_='shop1_2' | _head_='shop2_2') 
         then _cost_=_cost_-40; 
      run; 
  
   proc netflow 
      warm 
      arcdata=new_con4 
      dualin=dual4 
      condata=con3 
      sparsecondata 
      rhsobs='CHIP/BO LIMIT' 
      dualout=dual5 
      conout=con5; 
      run; 
  
   proc print data=con5 (drop = _status_ _rcost_); 
      var _tail_ _head_ _capac_ _lo_ _supply_ _demand_ _name_ 
          _cost_ _flow_ _fcost_ oldcost oldflow oldfc 
          diagonal factory key_id mth_made _anumb_ _tnumb_; 
             /* to get this variable order */ 
              sum oldfc _fcost_; 
      run; 
  
   proc print data=dual5; 
      run;
 

The following messages appear on the SAS log:

  
   NOTE: The following 1 variables in NODEDATA do not belong to 
         any SAS variable list. These will be ignored. 
         _VALUE_ 
   NOTE: Number of nodes= 21 . 
   NOTE: Number of supply nodes= 4 . 
   NOTE: Number of demand nodes= 5 . 
   NOTE: The greater of total supply and total demand= 4350 . 
   NOTE: Number of <= side constraints= 5 . 
   NOTE: Number of == side constraints= 0 . 
   NOTE: Number of >= side constraints= 0 . 
   NOTE: Number of arc and nonarc variable side constraint 
         coefficients= 16 . 
   NOTE: Number of iterations, optimizing with constraints= 7 . 
   NOTE: Of these, 1 were degenerate. 
   NOTE: Optimum reached. 
   NOTE: Minimal total cost= -1295661.8 . 
   NOTE: The data set WORK.CON5 has 64 observations and 21 
         variables. 
   NOTE: The data set WORK.DUAL5 has 25 observations and 14 
         variables.
 

Output 5.7.1: CONOUT=CON5
Using a Constrained Solution Warm Start
Production Planning/Inventory/Distribution

Obs _tail_ _head_ _capac_ _lo_ _SUPPLY_ _DEMAND_ _name_ _cost_ _FLOW_ _FCOST_ oldcost oldflow oldfc diagonal factory key_id mth_made _ANUMB_ _TNUMB_
1 fact1_1 _EXCESS_ 99999999 0 1000 200   0.00 5.000 0.00 0.00 5.000 0.00 . .     65 1
2 fact2_1 _EXCESS_ 99999999 0 850 200   0.00 45.000 0.00 0.00 45.000 0.00 . .     66 10
3 fact1_2 _EXCESS_ 99999999 0 1000 200   0.00 0.000 0.00 0.00 0.000 0.00 . .     67 11
4 fact2_2 _EXCESS_ 99999999 0 1500 200   0.00 150.000 0.00 0.00 150.000 0.00 . .     68 20
5 fact1_1 f1_apr_1 600 50 1000 . prod f1 19 apl 78.60 533.333 41920.00 78.60 533.333 41920.00 19 1 production April 4 1
6 f1_mar_1 f1_apr_1 50 0 . .   15.00 0.000 0.00 15.00 0.000 0.00 19 1 storage March 5 2
7 f1_may_1 f1_apr_1 20 0 . . back f1 19 may 33.60 0.000 0.00 33.60 0.000 0.00 19 1 backorder May 6 4
8 f2_apr_1 f1_apr_1 40 0 . .   11.00 0.000 0.00 11.00 0.000 0.00 19 . f2_to_1 April 7 6
9 fact1_2 f1_apr_2 550 50 1000 . prod f1 25 apl 174.50 250.000 43625.00 174.50 250.000 43625.00 25 1 production April 36 11
10 f1_mar_2 f1_apr_2 40 0 . .   20.00 0.000 0.00 20.00 0.000 0.00 25 1 storage March 37 12
11 f1_may_2 f1_apr_2 15 0 . . back f1 25 may 49.20 0.000 0.00 49.20 0.000 0.00 25 1 backorder May 38 14
12 f2_apr_2 f1_apr_2 25 0 . .   21.00 0.000 0.00 21.00 0.000 0.00 25 . f2_to_1 April 39 16
13 fact1_1 f1_mar_1 500 50 1000 . prod f1 19 mar 127.90 333.333 42633.33 127.90 333.333 42633.33 19 1 production March 1 1
14 f1_apr_1 f1_mar_1 20 0 . . back f1 19 apl 33.60 20.000 672.00 33.60 20.000 672.00 19 1 backorder April 2 3
15 f2_mar_1 f1_mar_1 40 0 . .   10.00 40.000 400.00 10.00 40.000 400.00 19 . f2_to_1 March 3 5
16 fact1_2 f1_mar_2 400 40 1000 . prod f1 25 mar 217.90 400.000 87160.00 217.90 400.000 87160.00 25 1 production March 33 11
17 f1_apr_2 f1_mar_2 30 0 . . back f1 25 apl 38.40 30.000 1152.00 38.40 30.000 1152.00 25 1 backorder April 34 13
18 f2_mar_2 f1_mar_2 25 0 . .   20.00 25.000 500.00 20.00 25.000 500.00 25 . f2_to_1 March 35 15
19 fact1_1 f1_may_1 400 50 1000 .   90.10 128.333 11562.83 90.10 128.333 11562.83 19 1 production May 8 1
20 f1_apr_1 f1_may_1 50 0 . .   12.00 0.000 0.00 12.00 0.000 0.00 19 1 storage April 9 3
21 f2_may_1 f1_may_1 40 0 . .   13.00 0.000 0.00 13.00 0.000 0.00 19 . f2_to_1 May 10 7
22 fact1_2 f1_may_2 350 40 1000 .   113.30 350.000 39655.00 113.30 350.000 39655.00 25 1 production May 40 11
23 f1_apr_2 f1_may_2 40 0 . .   18.00 0.000 0.00 18.00 0.000 0.00 25 1 storage April 41 13
24 f2_may_2 f1_may_2 25 0 . .   13.00 0.000 0.00 13.00 0.000 0.00 25 . f2_to_1 May 42 17
25 f1_apr_1 f2_apr_1 99999999 0 . .   11.00 13.333 146.67 11.00 13.333 146.67 19 . f1_to_2 April 14 3
26 fact2_1 f2_apr_1 480 35 850 . prod f2 19 apl 62.40 480.000 29952.00 62.40 480.000 29952.00 19 2 production April 15 10
27 f2_mar_1 f2_apr_1 30 0 . .   18.00 0.000 0.00 18.00 0.000 0.00 19 2 storage March 16 5
28 f2_may_1 f2_apr_1 15 0 . . back f2 19 may 30.00 0.000 0.00 30.00 0.000 0.00 19 2 backorder May 17 7
29 f1_apr_2 f2_apr_2 99999999 0 . .   23.00 0.000 0.00 23.00 0.000 0.00 25 . f1_to_2 April 46 13
30 fact2_2 f2_apr_2 680 35 1500 . prod f2 25 apl 196.70 550.000 108185.00 196.70 577.500 113594.25 25 2 production April 47 20
31 f2_mar_2 f2_apr_2 50 0 . .   28.00 0.000 0.00 28.00 0.000 0.00 25 2 storage March 48 15
32 f2_may_2 f2_apr_2 15 0 . . back f2 25 may 64.80 0.000 0.00 64.80 0.000 0.00 25 2 backorder May 49 17
33 f1_mar_1 f2_mar_1 99999999 0 . .   11.00 0.000 0.00 11.00 0.000 0.00 19 . f1_to_2 March 11 2
34 fact2_1 f2_mar_1 450 35 850 . prod f2 19 mar 88.00 290.000 25520.00 88.00 290.000 25520.00 19 2 production March 12 10
35 f2_apr_1 f2_mar_1 15 0 . . back f2 19 apl 20.40 0.000 0.00 20.40 0.000 0.00 19 2 backorder April 13 6
36 f1_mar_2 f2_mar_2 99999999 0 . .   23.00 0.000 0.00 23.00 0.000 0.00 25 . f1_to_2 March 43 12
37 fact2_2 f2_mar_2 650 35 1500 . prod f2 25 mar 182.00 650.000 118300.00 182.00 650.000 118300.00 25 2 production March 44 20
38 f2_apr_2 f2_mar_2 15 0 . . back f2 25 apl 37.20 0.000 0.00 37.20 0.000 0.00 25 2 backorder April 45 16
39 f1_may_1 f2_may_1 99999999 0 . .   16.00 115.000 1840.00 16.00 115.000 1840.00 19 . f1_to_2 May 18 4
40 fact2_1 f2_may_1 250 35 850 .   128.80 35.000 4508.00 128.80 35.000 4508.00 19 2 production May 19 10
41 f2_apr_1 f2_may_1 30 0 . .   20.00 0.000 0.00 20.00 0.000 0.00 19 2 storage April 20 6
42 f1_may_2 f2_may_2 99999999 0 . .   26.00 0.000 0.00 26.00 350.000 9100.00 25 . f1_to_2 May 50 14
43 fact2_2 f2_may_2 550 35 1500 .   181.40 150.000 27210.00 181.40 122.500 22221.50 25 2 production May 51 20
44 f2_apr_2 f2_may_2 50 0 . .   38.00 0.000 0.00 38.00 0.000 0.00 25 2 storage April 52 16
45 f1_mar_1 shop1_1 250 0 . 900   -327.65 143.333 -46963.17 -327.65 143.333 -46963.17 19 1 sales March 21 2
46 f1_apr_1 shop1_1 250 0 . 900   -300.00 250.000 -75000.00 -300.00 250.000 -75000.00 19 1 sales April 22 3
47 f1_may_1 shop1_1 250 0 . 900   -285.00 13.333 -3800.00 -285.00 13.333 -3800.00 19 1 sales May 23 4
48 f2_mar_1 shop1_1 250 0 . 900   -297.40 250.000 -74350.00 -297.40 250.000 -74350.00 19 2 sales March 24 5
49 f2_apr_1 shop1_1 250 0 . 900   -290.00 243.333 -70566.67 -290.00 243.333 -70566.67 19 2 sales April 25 6
50 f2_may_1 shop1_1 250 0 . 900   -292.00 0.000 0.00 -292.00 0.000 0.00 19 2 sales May 26 7
51 f1_mar_2 shop1_2 99999999 0 . 900   -559.76 0.000 0.00 -559.76 0.000 0.00 25 1 sales March 53 12
52 f1_apr_2 shop1_2 99999999 0 . 900   -524.28 0.000 0.00 -524.28 0.000 0.00 25 1 sales April 54 13
53 f1_may_2 shop1_2 99999999 0 . 900   -515.02 350.000 -180257.00 -475.02 0.000 0.00 25 1 sales May 55 14
54 f2_mar_2 shop1_2 500 0 . 900   -567.83 500.000 -283915.00 -567.83 500.000 -283915.00 25 2 sales March 56 15
55 f2_apr_2 shop1_2 500 0 . 900   -542.19 50.000 -27109.50 -542.19 400.000 -216876.00 25 2 sales April 57 16
56 f2_may_2 shop1_2 500 0 . 900   -491.56 0.000 0.00 -491.56 0.000 0.00 25 2 sales May 58 17
57 f1_mar_1 shop2_1 250 0 . 900   -362.74 250.000 -90685.00 -362.74 250.000 -90685.00 19 1 sales March 27 2
58 f1_apr_1 shop2_1 250 0 . 900   -300.00 250.000 -75000.00 -300.00 250.000 -75000.00 19 1 sales April 28 3
59 f1_may_1 shop2_1 250 0 . 900   -245.00 0.000 0.00 -245.00 0.000 0.00 19 1 sales May 29 4
60 f2_mar_1 shop2_1 250 0 . 900   -272.70 0.000 0.00 -272.70 0.000 0.00 19 2 sales March 30 5
61 f2_apr_1 shop2_1 250 0 . 900   -312.00 250.000 -78000.00 -312.00 250.000 -78000.00 19 2 sales April 31 6
62 f2_may_1 shop2_1 250 0 . 900   -299.00 150.000 -44850.00 -299.00 150.000 -44850.00 19 2 sales May 32 7
63 f1_mar_2 shop2_2 99999999 0 . 1450   -623.89 455.000 -283869.95 -623.89 455.000 -283869.95 25 1 sales March 59 12
64 f1_apr_2 shop2_2 99999999 0 . 1450   -549.68 220.000 -120929.60 -549.68 220.000 -120929.60 25 1 sales April 60 13
65 f1_may_2 shop2_2 99999999 0 . 1450   -500.00 0.000 0.00 -460.00 0.000 0.00 25 1 sales May 61 14
66 f2_mar_2 shop2_2 500 0 . 1450   -542.83 125.000 -67853.75 -542.83 125.000 -67853.75 25 2 sales March 62 15
67 f2_apr_2 shop2_2 500 0 . 1450   -559.19 500.000 -279595.00 -559.19 177.500 -99256.23 25 2 sales April 63 16
68 f2_may_2 shop2_2 500 0 . 1450   -519.06 150.000 -77859.00 -519.06 472.500 -245255.85 25 2 sales May 64 17
                    -1295661.80     -1282708.63            



Output 5.7.2: DUALOUT=DUAL5
Using a Constrained Solution Warm Start
Production Planning/Inventory/Distribution

Obs _node_ _supdem_ _DUAL_ _NNUMB_ _PRED_ _TRAV_ _SCESS_ _ARCID_ _FLOW_ _FBQ_ _VALUE_ _RHS_ _TYPE_ _row_
1 f1_apr_1 . -100000278.00 3 1 6 2 4 483.333 4 . .    
2 f1_apr_2 . -100000405.92 13 19 11 2 -60 220.000 36 . .    
3 f1_mar_1 . -100000326.65 2 8 1 20 -21 143.333 1 . .    
4 f1_mar_2 . -100000480.13 12 19 13 1 -59 455.000 33 . .    
5 f1_may_1 . -100000284.00 4 1 7 3 8 78.333 8 . .    
6 f1_may_2 . -100000363.43 14 18 10 1 -55 350.000 40 . .    
7 f2_apr_1 . -100000289.00 6 3 4 1 14 13.333 14 . .    
8 f2_apr_2 . -100000390.60 16 20 18 3 47 515.000 46 . .    
9 f2_mar_1 . -100000281.90 5 10 3 1 12 255.000 11 . .    
10 f2_mar_2 . -100000399.07 15 19 16 1 -62 125.000 43 . .    
11 f2_may_1 . -100000300.00 7 4 9 2 18 115.000 18 . .    
12 f2_may_2 . -100000375.30 17 20 19 6 51 115.000 50 . .    
13 fact1_1 1000 -100000193.90 1 2 21 19 -1 283.333 -1 . .    
14 fact1_2 1000 -100000224.09 11 13 15 1 -36 200.000 -33 . .    
15 fact2_1 850 -100000193.90 10 21 5 2 -66 45.000 -33 . .    
16 fact2_2 1500 -100000193.90 20 21 17 10 -68 150.000 -65 . .    
17 shop1_1 -900 -99999999.00 8 22 2 21 0 0.000 21 . .    
18 shop1_2 -900 -99999848.41 18 16 14 2 57 50.000 53 . .    
19 shop2_1 -900 -100000001.00 9 7 22 1 32 150.000 27 . .    
20 shop2_2 -1450 -99999856.24 19 17 12 5 64 150.000 59 . .    
21   . -1.83 2 8 . . 25 243.333 . 2600 2600 LE FACT1 APL GIZMO
22   . -1.62 0 8 . . 23 13.333 . 2600 2600 LE FACT1 MAR GIZMO
23   . 0.00 3 3 . 3 . 110.000 . 3640 3750 LE FACT2 APL GIZMO
24   . 0.00 1 1 . 1 . 280.000 . 3470 3750 LE FACT2 MAR GIZMO
25   . -15.05 4 2 . . 2 20.000 . 50 50 LE TOTAL BACKORDER



Previous Page | Next Page | Top of Page