# Operations20Research20by20HA20TAHA20Solution20Manual208th20Edition.1940021756

```Set 9.1d
7
1. Straightforward formulation:
Let xit = 1 if load i is assigned to trailer t, o otherwise
Li = linear feet of load i
ri = revenue from load i
10
M axim ize z =
2
∑∑rx
i
it
subject to
i =1 t =1
10
∑Lx
≤ 36, t = 1, 2
i
it
it
≤ 1, i = 1, ...,10, x it = (0,1), i = 1, 2, ...10
i =1
2
∑x
t =1
2. Formulation using if-then:
Let xit = feet in trailer t assigned to load i
yi = (0, 1), i = 1, 2, …, 10, wit = (0, 1), i = 1, 2, ..., 10, t = 1, 2
10
2
Maximize z = ∑∑ ri xit subject to
i =1 t =1
10
∑x
it
≤ 36, t = 1, 2
i =1
xi1 ≤ Li yi , xi 2 ≤ Li (1 − yi ), i = 1, 2,...,10
(above constraint is not as efficient as xi1 + xi 2 ≤ 1, i = 1, 2,...,10 in formulation 1)
(if xit &gt; 0 then xit = Li ) translates to
xit ≤ M (1 − wit ), Li − xit ≤ Mwit , − Li + xit ≤ Mwit , i = 1, 2,...,10, t = 1, 2
xit , wit , yi = (0,1), i = 1, 2,...,10, t = 1, 2
Solution: z = \$7929. Problem has several alternative optima. (See file ampl9.1d-7.txt.)
Solution 1
Solution 2
Trailer
Feet
Feet
1
1
5
1
5
5
7
2
11
6
9
6
9
8
14
9
10
Total
35 ft
Total
35 ft
2
2
11
4
15
4
15
5
7
9
10
8
14
Total
36 ft
Total
36 ft
9-14
```