! Keywords: Accounting / Financial / Forecasting / Banking / Downside Risk / Portfolio;
MAX     Z   ! Max worth at end of final period;  
SUBJECT TO
     ! Uses - sources = supply of cash in each period;    
 2)    3000 F + 2000 M + 2000 D - B1 + L1 =     2000
 3)    1000 F + 500 M + 2000 D + 1.035 B1 - 1.03 L1 - B2 + L2
     =    500
 4)    1800 F - 1500 M + 1800 D + 1.035 B2 - 1.03 L2 - B3 + L3
     =    400
 5)  - 400 F - 1500 M - 1000 D + 1.035 B3 - 1.03 L3 - B4 + L4
     =    380
 6)  - 1800 F - 1500 M - 1000 D + 1.035 B4 - 1.03 L4 - B5 + L5
     =    360
 7)  - 1800 F - 200 M - 1000 D + 1.035 B5 - 1.03 L5 - B6 + L6
     =    340

 8)    Z - 5500 F + 1000 M - 6000 D + 1.035 B6 - 1.03 L6 =  300
     ! Borrowing limits;
 9)    B1 <=   2000
10)    B2 <=   2000
11)    B3 <=   2000
12)    B4 <=   2000
13)    B5 <=   2000
14)    B6 <=   2000
     ! We can invest at most 100% in a project;
15)     F <=   1
16)     M <=   1
17)     D <=   1
  END