examples/dea.mod
author Alpar Juttner <alpar@cs.elte.hu>
Mon, 06 Dec 2010 13:09:21 +0100
changeset 1 c445c931472f
permissions -rw-r--r--
Import glpk-4.45

- Generated files and doc/notes are removed
alpar@1
     1
/* Data Envelopment Analysis (DEA)
alpar@1
     2
 *
alpar@1
     3
 * DEA quantifies the relative efficiency of decision making units (DMUs) by
alpar@1
     4
 * finding the efficient frontier in multiple input multiple output data.  The
alpar@1
     5
 * inputs are resources (eg. number of employees, available machines, ...),
alpar@1
     6
 * the outputs are productive outputs (eg. contracts made, total sales, ...).
alpar@1
     7
 * The method is non-parametric.  More details are available in the paper
alpar@1
     8
 * below.
alpar@1
     9
 *
alpar@1
    10
 * Models according to: Seiford, Threall, "Recent developments in DEA", 1990.
alpar@1
    11
 *
alpar@1
    12
 * Implementation: Sebastian Nowozin <nowozin@gmail.com>
alpar@1
    13
 */
alpar@1
    14
alpar@1
    15
### SETS ###
alpar@1
    16
alpar@1
    17
set dmus;       # Decision Making Units (DMU)
alpar@1
    18
set inputs;     # Input parameters
alpar@1
    19
set outputs;    # Output parameters
alpar@1
    20
alpar@1
    21
alpar@1
    22
### PARAMETERS ###
alpar@1
    23
alpar@1
    24
param input_data{dmus,inputs} >= 0;
alpar@1
    25
param output_data{dmus,outputs} >= 0;
alpar@1
    26
alpar@1
    27
alpar@1
    28
### PROGRAM ###
alpar@1
    29
alpar@1
    30
var theta{dmus} >= 0;
alpar@1
    31
var lambda{dmus,dmus} >= 0;
alpar@1
    32
alpar@1
    33
minimize inefficiency: sum{td in dmus} theta[td];
alpar@1
    34
alpar@1
    35
s.t. output_lower_limit{o in outputs, td in dmus}:
alpar@1
    36
    sum{d in dmus} lambda[d,td]*output_data[d,o] >= output_data[td,o];
alpar@1
    37
s.t. input_upper_limit{i in inputs, td in dmus}:
alpar@1
    38
    sum{d in dmus} lambda[d,td]*input_data[d,i] <= theta[td]*input_data[td,i];
alpar@1
    39
alpar@1
    40
    s.t. PI1{td in dmus}:
alpar@1
    41
        sum{d in dmus} lambda[d,td] = 1;
alpar@1
    42
/*
alpar@1
    43
possibilities:
alpar@1
    44
      i) (no constraint)
alpar@1
    45
     ii) s.t. PI1{td in dmus}:
alpar@1
    46
        sum{d in dmus} lambda[d,td] <= 1;
alpar@1
    47
    iii) s.t. PI1{td in dmus}:
alpar@1
    48
        sum{d in dmus} lambda[d,td] >= 1;
alpar@1
    49
*/
alpar@1
    50
alpar@1
    51
alpar@1
    52
### SOLVE AND PRINT SOLUTION ###
alpar@1
    53
alpar@1
    54
solve;
alpar@1
    55
alpar@1
    56
printf "DMU\tEfficiency\n";
alpar@1
    57
for {td in dmus} {
alpar@1
    58
    printf "%s\t%1.4f\n", td, theta[td];
alpar@1
    59
}
alpar@1
    60
alpar@1
    61
### DATA ###
alpar@1
    62
alpar@1
    63
data;
alpar@1
    64
alpar@1
    65
set dmus := 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
alpar@1
    66
    21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40
alpar@1
    67
    41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
alpar@1
    68
    61 62 63 64 65 66 67 68 69 ;
alpar@1
    69
set inputs := AvgInventory LaborCost OperatingCost Population ;
alpar@1
    70
set outputs := PrescrVol kDollarValue ;
alpar@1
    71
alpar@1
    72
param input_data default 0.0 :
alpar@1
    73
alpar@1
    74
        AvgInventory LaborCost OperatingCost Population :=
alpar@1
    75
alpar@1
    76
1 8000 17030 1280 1410
alpar@1
    77
2 9000 25890 2779 1523
alpar@1
    78
3 13694 29076 2372 1354
alpar@1
    79
4 4250 17506 1385 822
alpar@1
    80
5 6500 23208 639 746
alpar@1
    81
6 7000 12946 802 1281
alpar@1
    82
7 4500 18001 1130 1016
alpar@1
    83
8 5000 14473 1097 1070
alpar@1
    84
9 27000 31760 5559 1694
alpar@1
    85
10 21560 50972 15010 1910
alpar@1
    86
11 15000 39523 4799 1745
alpar@1
    87
12 8500 13076 3489 1353
alpar@1
    88
13 35000 35427 1704 500
alpar@1
    89
14 18000 27554 2882 1016
alpar@1
    90
15 59750 53848 14208 2500
alpar@1
    91
16 19200 38253 1480 2293
alpar@1
    92
17 40000 109404 83016 2718
alpar@1
    93
18 8466 18198 1278 2877
alpar@1
    94
19 16000 40891 7599 4150
alpar@1
    95
20 10000 45444 5556 4421
alpar@1
    96
21 25000 35623 2121 3883
alpar@1
    97
22 14000 20192 5515 3519
alpar@1
    98
23 12500 34973 10475 32366
alpar@1
    99
24 17260 32284 14498 3393
alpar@1
   100
25 7000 17920 7585 4489
alpar@1
   101
26 14000 42094 3742 2217
alpar@1
   102
27 16400 35422 14236 4641
alpar@1
   103
28 13000 19100 3529 5968
alpar@1
   104
29 30000 72167 8656 8715
alpar@1
   105
30 12530 19970 1714 5968
alpar@1
   106
31 31500 39183 4919 5607
alpar@1
   107
32 10000 32048 3483 7324
alpar@1
   108
33 22000 68877 12279 8685
alpar@1
   109
34 10000 29812 3332 8685
alpar@1
   110
35 16000 47686 2507 5420
alpar@1
   111
36 10000 33415 4738 7703
alpar@1
   112
37 9000 12359 4603 4665
alpar@1
   113
38 16439 23614 2989 6317
alpar@1
   114
39 14500 36069 1793 31839
alpar@1
   115
40 39000 76307 9539 15619
alpar@1
   116
41 24927 40706 12661 30213
alpar@1
   117
42 13858 39267 4609 34719
alpar@1
   118
43 33375 29509 11323 31839
alpar@1
   119
44 29044 44482 5542 34719
alpar@1
   120
45 32257 61365 20550 32366
alpar@1
   121
46 8800 49671 3306 43561
alpar@1
   122
47 47000 40425 10396 31263
alpar@1
   123
48 12000 33034 4915 31263
alpar@1
   124
49 28000 69163 4688 15173
alpar@1
   125
50 13300 28931 16735 73064
alpar@1
   126
51 13500 29758 4260 62309
alpar@1
   127
52 24000 40927 8285 23166
alpar@1
   128
53 16000 40403 2131 99836
alpar@1
   129
54 17000 38730 2539 60348
alpar@1
   130
55 25000 35978 2502 99836
alpar@1
   131
56 16000 37509 6278 99836
alpar@1
   132
57 20000 46950 10715 85925
alpar@1
   133
58 14000 35966 3144 85925
alpar@1
   134
59 22000 68318 8015 108987
alpar@1
   135
60 21879 69537 7778 108987
alpar@1
   136
61 15000 25425 2812 201404
alpar@1
   137
62 10000 19508 2454 201404
alpar@1
   138
63 20000 28191 3367 201404
alpar@1
   139
64 18000 37073 8624 108987
alpar@1
   140
65 19051 23763 3496 201404
alpar@1
   141
66 15000 28642 3366 201404
alpar@1
   142
67 10000 35919 3868 201404
alpar@1
   143
68 24000 54653 26494 108987
alpar@1
   144
69 1800 6276 3413 60348
alpar@1
   145
        ;
alpar@1
   146
alpar@1
   147
param output_data default 0.0 :
alpar@1
   148
alpar@1
   149
        PrescrVol kDollarValue :=
alpar@1
   150
alpar@1
   151
1 12293 61.00
alpar@1
   152
2 18400 92.00
alpar@1
   153
3 16789 92.65
alpar@1
   154
4 10700 45.00
alpar@1
   155
5 9800 50.00
alpar@1
   156
6 6500 29.00
alpar@1
   157
7 8200 56.00
alpar@1
   158
8 8680 45.00
alpar@1
   159
9 33800 183.00
alpar@1
   160
10 23710 156.00
alpar@1
   161
11 24000 120.00
alpar@1
   162
12 17500 75.00
alpar@1
   163
13 25000 130.00
alpar@1
   164
14 26000 122.00
alpar@1
   165
15 26830 178.513
alpar@1
   166
16 16600 106.00
alpar@1
   167
17 90000 450.00
alpar@1
   168
18 11140 73.624
alpar@1
   169
19 25868 136.00
alpar@1
   170
20 32700 191.295
alpar@1
   171
21 29117 152.864
alpar@1
   172
22 18000 100.00
alpar@1
   173
23 11100 60.00
alpar@1
   174
24 23030 137.778
alpar@1
   175
25 10656 58.00
alpar@1
   176
26 24682 152.095
alpar@1
   177
27 26908 120.00
alpar@1
   178
28 16464 80.00
alpar@1
   179
29 57000 321.00
alpar@1
   180
30 17532 94.747
alpar@1
   181
31 30035 168.00
alpar@1
   182
32 16000 100.00
alpar@1
   183
33 63700 277.00
alpar@1
   184
34 18000 90.00
alpar@1
   185
35 27339 139.134
alpar@1
   186
36 19500 116.00
alpar@1
   187
37 13000 80.00
alpar@1
   188
38 15370 102.00
alpar@1
   189
39 18446 90.00
alpar@1
   190
40 56000 260.00
alpar@1
   191
41 73845 364.951
alpar@1
   192
42 28600 145.00
alpar@1
   193
43 27000 243.00
alpar@1
   194
44 52423 279.816
alpar@1
   195
45 73759 363.388
alpar@1
   196
46 20500 80.00
alpar@1
   197
47 27100 115.00
alpar@1
   198
48 15000 110.00
alpar@1
   199
49 50895 277.852
alpar@1
   200
50 19707 128.00
alpar@1
   201
51 17994 78.80
alpar@1
   202
52 36135 167.222
alpar@1
   203
53 30000 153.00
alpar@1
   204
54 26195 125.00
alpar@1
   205
55 28000 216.00
alpar@1
   206
56 24658 152.551
alpar@1
   207
57 36850 190.00
alpar@1
   208
58 29250 183.69
alpar@1
   209
59 50000 250.00
alpar@1
   210
60 40078 265.443
alpar@1
   211
61 20200 110.00
alpar@1
   212
62 12500 75.00
alpar@1
   213
63 30890 195.00
alpar@1
   214
64 31000 175.00
alpar@1
   215
65 31277 192.992
alpar@1
   216
66 11500 75.00
alpar@1
   217
67 30000 175.668
alpar@1
   218
68 38383 190.00
alpar@1
   219
69 2075 8.650
alpar@1
   220
        ;
alpar@1
   221
alpar@1
   222
end;