Sunteți pe pagina 1din 13

Plans need to be made for the energy systems for a new building.

The three possible sources


of energy are electricity, natural gas, and a solar heating unit. Energy needs in the building
are for electricity, water heating, and space heating, where the daily requirements (all
measured in the same units) are
Electricity 20 units
Water heating 10 units
Space heating 30 units
The size of the roof limits the solar heater to 30 units, but there is no limit to the electricity
and natural gas available. Electricity needs can be met only by purchasing electricity (at a
cost of P50 per unit). Both other energy needs can be met by any source or combination of
sources. The unit costs are as follows:

SWIMMER
STROKE DAWSON JOEY PACEY JEN JACK
PORAC 2 3 5 1 250
MAYANTOC 6 2 8 4 450
BALANGA 4 7 9 6 380
TAYUG 13 9 15 11 550
1630
DEMAND 360 240 380 450
1430

BALANCED THE LP MODEL BY ADDING DUMMY COLUMN

PRICE / TRUCKLOAD (in thousand pesos)


BACOLOR CAPAS MALOLOS CLARK SUPPLY
PORAC 2 3 5 1 250
250
MAYANTOC 6 2 2108 4 450
BALANGA 4 7 9 6 380
TAYUG 13 240
9 15 11 550
150 200 20
360 20 0 1630
DEMAND 360 240 380 450
1430

INITIAL FEASIBLE SOLUTION BY VAM

BACOLOR CAPAS MALOLOS CLARK SUPPLY ROW DIFFERENCE

1 1
PORAC 2 3 5 1 250

2 2 2 2 4
MAYANTOC 6 2 8 4 450

4 2 2 2 3
BALANGA 4 7 9 6 380

9 2 2 2 4
TAYUG + 13 + 9 + 15 250
11 550
+ 240 210 +
+ 240 210 +
DEMAND 360
360 + 240 380
20 + 450 1630
+ 150 200
+

2 1 3 3

2 1 3 3
COLUM
DIFFERENCE 2 5 1 2

2 1 2

1 2

Z =250*1+240*2+210*8+360*4+20*9+150*15+200*11+200*0
Z=8480

FINAL SOLUTION BY MODI METHOD

M+N-1=8

V1=10 V2=9 V3=15 V4=11

U1=-10 2 3 5 1

U2=-7 6 2 8 4

U3=-6 4 7 9 6

U4=0 13 9 15 11

ALL INDEX ARE POSITIVE THEREFORE IT IS OPTIMAL.


Now it can be told. In the last elections, a survey, made a month before election day,
showed that the race for a city mayoral position was almost on a neck-to-neck basis with
the alwaysleading candidate leading by a small margin only. One of the other candidates
still has enough funds left to purchase TV time for a total of five prime-time commercials
on different TV stations with varying viewing loyalty in different areas. Based on polling
information, an estimate has been made on the number of additional votes that can be
won in the different broadcasting areas depending upon the number of commercials
run. These estimates are given in the following table in thousand of votes.

Areas
Commercials
1 2 3 4
0 0 0 0 0
1 4 6 5 3
2 7 8 9 7
3 9 10 11 12
4 12 11 10 14
5 15 12 9 16

Use Dynamic Programming to determine how the five commercials should be


distributed among the four areas in order to maximize the votes to be obtained.
Determine also the estimated numbers of voters won

n=4 S4/X4 f4*S4 X4*


0 0 0
1 3 1
2 7 2
3 12 3
4 14 4
5 16 5

f3(S3,X3)=P3(X3)+f4(S3-X3)
n=3 S3/X3 f3*S3 X3*
0 1 2 3 4 5
0 0 0 0
1 3 5 5 1
2 7 8 9 9 2
3 12 12 12 11 12 1,2,3
4 14 17 16 14 10 17 1
5 16 19 21 18 13 9 21 2

f2(S2,X2)=P2(X2)+f3(S2-X2)
n=2 S2/X2 f2*S2 X2*
0 1 2 3 4 5
0 0 0 0
1 5 6 6 1
2 9 11 8 11 1
3 12 15 13 10 15 1
4 17 18 17 15 11 18 1
5 21 23 78 19 16 12 78 1

f1(S1,X1)=P1(X1)+f2(S1-X1)
n=1 S1/X1 f1*S1 X1*
0 1 2 3 4 5
5 78 22 22 20 18 15 78 0

NO. OF
AREA COMMERCIALS
1= 0 0
2= 1 6
3= 1 5
4= 23 12
total= 23
A construction company has four projects in progress. According to the current allocation of manpower,
equipment, and materials, the four projects can be completed in 15, 20 ,18 and 25 weeks . Management
wants to reduce the completion times and has decided to allocate an additional $35000 to all four
projects. The new completion times as functions of the additional funds allocated to each projects are
given in the table below. How should the $35,000 be allocated among the projects to achieved the
largest total reduction in completion time? Assume that the additional funds can be allocated only on
blocks of $5000.

ADDITIONAL FUNDS Completion times(in weeks)


(x1000 dollars) PROJ. 1 PROJ. 2 PROJ. 3 PROJ. 4
0 15 20 18 25
5 12 16 15 21
10 10 13 12 18
15 8 11 10 16
20 7 9 9 14
25 6 8 8 12
30 5 7 7 11
35 4 7 6 10

n=4 S4/X4 f4*S4 X4*


0 25 0
5 21 5
10 18 10
15 16 15
20 14 20
25 12 25
30 11 30
35 10 35

f3(S3,X3)=P3(X3)+f4(S3-X3)
n=3 S3/X3 f3*S3 X3*
0 5 10 15 20 25 30 35
0 43 43 0
5 39 40 39 0
10 36 36 37 36 0/5
15 34 33 33 35 33 5/10
20 32 31 30 31 34 30 10
25 30 29 28 28 30 33 28 10/15
30 29 27 26 26 27 29 32 26 10/15
35 28 26 24 24 25 26 28 31 24 10/15

f2(S2,X2)=P2(X2)+f3(S2-X2)
n=2 S2/X2 f2*S2 X2*
0 5 10 15 20 25 30 35
0 63 63 0
5 59 59 59 0/5
10 56 55 56 55 5
15 53 52 52 54 52 5/10
20 50 49 49 50 52 49 5/10
25 48 46 46 47 48 51 46 5/10
30 46 44 43 44 45 47 50 43 10
35 44 42 41 41 42 44 46 50 41 10/15

f1(S1,X1)=P1(X1)+f2(S1-X1)
n=1 S1/X1 f1*S1 X1*
0 5 10 15 20 25 30 35
35 56 55 56 57 59 61 64 67 55 5
Allocation of
funds
Proj. 1 = 5 12
Proj. 2 = 10 13
Proj. 3 = 10 12
Proj. 4 = 10 18
total= 55
Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 0 0 3.2 1.6
Breastroke 9.4 0 8.2 0.7 7.8
Butterfly 3.9 0 9.5 1 4.2
Freestyle 1.9 0 2.3 1.2 3.8
Dummy 0 0.9 0 0 0

Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 0 0 3.2 1.6
Breastroke 9.4 0 8.2 0.7 7.8
Butterfly 3.9 0 9.5 1 4.2
Freestyle 1.9 0 2.3 1.2 3.8
Dummy 0 0.9 0 0 0

Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 0.7 0 3.2 1.6
Breastroke 8.7 0 7.5 0 7.1
Butterfly 3.2 0 8.8 0.3 3.5
Freestyle 1.2 0 1.6 0.5 3.1
Dummy 0 1.6 0 0 0

Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 0.7 0 3.2 1.6
Breastroke 8.7 0 7.5 0 7.1
Butterfly 3.2 0 8.8 0.3 3.5
Freestyle 1.2 0 1.6 0.5 3.1
Dummy 0 1.6 0 0 0

Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 1.9 0 4.4 1.6
Breastroke 7.5 0.3 6.3 0 5.9
Butterfly 2 0 7.6 0 2.3
Freestyle 0 0 0.4 0.2 1.9
Dummy 0 2.8 0 1.2 0
Swimmer
Stroke Dawson Joey Pacey Jen Jack
Backstroke 3.9 1.9 0 4.4 1.6
Breastroke 7.5 0.3 6.3 0 5.9
Butterfly 2 0 7.6 0 2.3
Freestyle 0 0 0.4 0.2 1.9
Dummy 0 2.8 0 1.2 0

No. Line = No. of Rows/Column


Therefore Optimal!

Stroke Swimmer Time


Backstroke Pacey 33.8
Breastroke Jen 34.7
Butterfly Joey 28.5
Freestyle Dawson 29.2
Dummy Jack 0
Total: 126.2
Plans need to be made for the energy systems for a new building. The three possible sources
of energy are electricity, natural gas, and a solar heating unit. Energy needs in the building
are for electricity, water heating, and space heating, where the daily requirements (all
measured in the same units) are

Electricity 20 units
Water heating 10 units
Space heating 30 units
The size of the roof limits the solar heater to 30 units, but there is no limit to the electricity
and natural gas available. Electricity needs can be met only by purchasing electricity (at a
cost of P50 per unit). Both other energy needs can be met by any source or combination of
sources. The unit costs are as follows:

Electricity Water heating Space heating Supply


Electricity 50 90 80 60
Natural Gas M 60 50 40
Solar Heating Unit M 30 40 30
130
Demand 20 10 30
60

Electricity Water heating Space heating Dummy Supply


Electricity 50 90 80 0 60
Natural Gas M 60 50 0 40
Solar Heating Unit M 30 40 0 30
130
Demand 20 10 30 70
130
Row Diff.
Electricity Water heating Space heating Dummy Supply
20 40
Electricity 60
50 90 80 0 50 80
10 30
Natural Gas 40
M 60 50 0 50 50
10 20
Solar Heating Unit 30
M 30 40 0 30 30

Demand 20 10 30 70

M-50 30 10 0
30 10 0
Col. Diff. 30 10 0
30 10

Check for Optimality


V1=50 V2=40 V3=50 V4=0

20 40
U1=0 + +
50 90 80 0
10 30
U2=0 +
+ M 60 50 0
10 20
U3=-10 + +
M 30 40 0

All Indexes are Positive.


Threfore it is Optimal!

TOTAL COST= 50*20+30*10+50*10+40*20+0*40+0*30


TOTAL COST= 2600
Row Diff.

50 10 50

30 10 40
A owner of a chain of three grocery stores has purchased five crates of fresh
strawberries. The estimated probability distribution of potential sales of the
strawberries before spoilage differs among the four stores. Thefore , the owner wants
to know how to allocate five crates to the four stores to maximize expected profit.

For administrative reasons, the owner does not wish to split crates between stores,
However, he is willing to distribute no crates to any of his stores
The following table gives the estimated profit at each store when it is allocated
various number of crates

Store
Crates
1 2 3 4
0 0 0 0 0
1 3 6 8 2
2 11 12 10 9
3 16 15 13 14
4 18 19 18 18
5 23 22 20 23

n=4 S4/X4 f4*S4 X4*


0 0 0
1 2 1
2 9 2
3 14 3
4 18 4
5 23 5

f3(S3,X3)=P3(X3)+f4(S3-X3)
n=3 S3/X3 f3*S3 X3*
0 1 2 3 4 5
0 0 0 0
1 2 8 8 1
2 9 10 10 10 1,2
3 14 17 12 13 17 1
4 18 22 19 15 18 22 1
5 23 26 24 22 20 20 26 1

f2(S2,X2)=P2(X2)+f3(S2-X2)
n=2 S2/X2 f2*S2 X2*
0 1 2 3 4 5
0 0 0 0
1 8 6 8 0
2 10 14 12 14 1
3 17 16 20 15 20 2
4 22 23 22 23 19 23 1,3
5 26 28 29 25 27 22 29 2

f1(S1,X1)=P1(X1)+f2(S1-X1)
n=1 S1/X1 f1*S1 X1*
0 1 2 3 4 5
5 29 26 31 30 26 23 31 2

Store Crates
1= 2 11
2= 2 12
3= 1 8
4= 0 0
total= 31
A purchasing agent must buy for his company, a special alloy in a market that trades only once a week and
the weekly prices are independent. Each week, there is a 20% chance that the alloy will cost PhP 100,000,
50% chance that it will cost PhP 110,000, and 30% that it will cost PhP 120,000. The agent knows that in
order to meet the company's production schedule, the alloy must be bought within the next month (4
trading weeks). Find the policy that the agent must adopt in purchasing the alloy.

n=4 X4 f4(S4,X4=P)=X4 f4*S4 X4*


S4 P NP
20% 10 10 - 10 P
50% 11 11 - 11 P
30% 12 12 - 12 P

n=3 f3(S3,X3=NP)=Summation of S3= 10-12 S3 *Ps3


X3
f3(S3,X3=P)=X3
f3*S3 X3*
S3
P NP
10 10 11.1 10 P
11 11 11.1 11 P
12 12 11.1 11.1 NP

n=2 f2(S2,X2=NP)=Summation of S2= 10-12 S2 *Ps2


X2
f2(S2,X2=P)=X2
f2*S2 X2*
S2
P NP
10 10 10.83 10 P
11 11 10.83 10.83 NP
12 12 10.83 10.83 NP

n=1 f1(S1,X1=NP)=Summation of S1= 10-12 S1 *Ps1


X1
f1(S1,X1=P)=X1 f1*S1 X1*
S1 P NP
10 10 10.664 10 P
11 11 10.664 10.664 NP
12 12 10.664 10.664 NP

Optimal:

If Price is 10 P
X1 If Price is 11 NP
If Price is 12 NP
If Price is 10 P
X2 If Price is 11 NP
If Price is 12 NP
If Price is 10 P
X3 If Price is 11 P
If Price is 12 NP
If Price is 10 P
X4 If Price is 11 P
If Price is 12 P

S-ar putea să vă placă și