# Inflation Adjusted Decisions¶

## Example 11.1 Page 148¶

In [7]:
#initiation of variable
print "Few steps are as follows : ";
print "Step 1 : The estimated future requirementt per year in terms of todays rupees from his age 61 through 70 is Rs. 24000.";
print "Step 2 : The formula which is given below is used to get future equivalent of Rs. 24000 with the inflation of 9% per year.";
print "Formula : P*(1+IR)^n";
P=24000.0;#in Rs.
IR=9.0;#in % per year
Age=61.0;#in years
for n in range(21,31) :
IV=P*(1+IR/100)**n;#in Rs
print "Age in years : ",Age,". ""Inflated value of Rs. 24000 at end of year : ",n," in Rs. ",round(IV);
Age=Age+1;#in Years

PW=0;#For initialising
n=21.0;#in years
for m in range(10) :
A=P*(1+IR/100)**n;#in Rs
n=n+1;
i=15.0;#in % per year
PW=PW+A/(1+i/100)**(m+1);

#result
print "Present equivalent of withdrawls in Rs. : ",round(PW,3);

#The annual equivalent amount :
i=15.0;#in % per year
n=20.0;#in years
#Formula : (A/F,i,n) : (i/100)/(((1+i/100)^n)-1)
A=PW*(i/100)/(((1+i/100)**n)-1);#in Rs.
print "The annual equivalent amount in Rs. : ",round(A,3);
print"RECOMMENDATION : The person has to invest an amount of Rs. ",round(A,3)," at the end of every year starting from his age 41 through 60 which will enable him to make a withdrawl at the end of every year starting from his age 61 through 70.";

Few steps are as follows :
Step 1 : The estimated future requirementt per year in terms of todays rupees from his age 61 through 70 is Rs. 24000.
Step 2 : The formula which is given below is used to get future equivalent of Rs. 24000 with the inflation of 9% per year.
Formula : P*(1+IR)^n
Age in years :  61.0 . Inflated value of Rs. 24000 at end of year :  21  in Rs.  146611.0
Age in years :  62.0 . Inflated value of Rs. 24000 at end of year :  22  in Rs.  159806.0
Age in years :  63.0 . Inflated value of Rs. 24000 at end of year :  23  in Rs.  174189.0
Age in years :  64.0 . Inflated value of Rs. 24000 at end of year :  24  in Rs.  189866.0
Age in years :  65.0 . Inflated value of Rs. 24000 at end of year :  25  in Rs.  206954.0
Age in years :  66.0 . Inflated value of Rs. 24000 at end of year :  26  in Rs.  225580.0
Age in years :  67.0 . Inflated value of Rs. 24000 at end of year :  27  in Rs.  245882.0
Age in years :  68.0 . Inflated value of Rs. 24000 at end of year :  28  in Rs.  268011.0
Age in years :  69.0 . Inflated value of Rs. 24000 at end of year :  29  in Rs.  292132.0
Age in years :  70.0 . Inflated value of Rs. 24000 at end of year :  30  in Rs.  318424.0
Present equivalent of withdrawls in Rs. :  1013631.794
The annual equivalent amount in Rs. :  9894.537
RECOMMENDATION : The person has to invest an amount of Rs.  9894.537  at the end of every year starting from his age 41 through 60 which will enable him to make a withdrawl at the end of every year starting from his age 61 through 70.


## Example 11.2 Page 150¶

In [9]:
#initiation of variable
print"The method of finding the economic life of the machine witha discounting factor of 20% at zero inflation rate is summarized in table below. From the table it is clear that total annual cost is minimum if the machine is used for 14 years. Hence the economic life of the machine is 14 years.";
print"End of year     Op_cost     Main_cost    Op+Main     P/F,i,n     PW     Cummulative     Salvage     PW_S    TPW     A/P,i,n     AEM";
i=20.0;#in  per year
Cum=0.0;#initialising
Op_cost=40000.0;#in RS.
Main_cost=60000.0;#in Rs.
OpMain=Op_cost+Main_cost;#in Rs.
S=400000.0;#in Rs.
for n in range (1,16) :
PF=1/((1+i/100)**n);
PW=OpMain*PF;#in Rs.
Cum=Cum+PW
PW_S=PF*S;#in RS.
TPW=500000.0+Cum-PW_S;#in Rs.
AP=((i/100)*(1+i/100)**n)/(((1+i/100)**n)-1);
AEM=TPW*AP;#in RS
print "       ",n,"        ",Op_cost,"        ",Main_cost,"        ",OpMain,"    ",PF,"     ",PW,"        ",Cum,"        ",S,"        ",PW_S,"        ",TPW,"        ",AP,"        ",AEM;
Op_cost=Op_cost+5000.0;#in Rs.
Main_cost=Main_cost+6000.0;#in Rs.
S=S-50000.0;#in Rs.

The method of finding the economic life of the machine witha discounting factor of 20% at zero inflation rate is summarized in table below. From the table it is clear that total annual cost is minimum if the machine is used for 14 years. Hence the economic life of the machine is 14 years.
End of year     Op_cost     Main_cost    Op+Main     P/F,i,n     PW     Cummulative     Salvage     PW_S    TPW     A/P,i,n     AEM
1          40000.0          60000.0          100000.0      0.833333333333       83333.3333333          83333.3333333          400000.0          333333.333333          250000.0          1.2          300000.0
2          45000.0          66000.0          100000.0      0.694444444444       69444.4444444          152777.777778          350000.0          243055.555556          409722.222222          0.654545454545          268181.818182
3          50000.0          72000.0          100000.0      0.578703703704       57870.3703704          210648.148148          300000.0          173611.111111          537037.037037          0.474725274725          254945.054945
4          55000.0          78000.0          100000.0      0.48225308642       48225.308642          258873.45679          250000.0          120563.271605          638310.185185          0.386289120715          246572.280179
5          60000.0          84000.0          100000.0      0.401877572016       40187.7572016          299061.213992          200000.0          80375.5144033          718685.699588          0.33437970329          240313.910987
6          65000.0          90000.0          100000.0      0.33489797668       33489.797668          332551.01166          150000.0          50234.6965021          782316.315158          0.300705745867          235247.011053
7          70000.0          96000.0          100000.0      0.279081647234       27908.1647234          360459.176383          100000.0          27908.1647234          832551.01166          0.277423926347          230969.570539
8          75000.0          102000.0          100000.0      0.232568039361       23256.8039361          383715.980319          50000.0          11628.4019681          872087.578351          0.260609422409          227274.240084
9          80000.0          108000.0          100000.0      0.193806699468       19380.6699468          403096.650266          0.0          0.0          903096.650266          0.248079461672          224039.730836
10          85000.0          114000.0          100000.0      0.16150558289       16150.558289          419247.208555          -50000.0          -8075.27914449          927322.4877          0.238522756883          221187.516286
11          90000.0          120000.0          100000.0      0.134587985742       13458.7985742          432706.007129          -100000.0          -13458.7985742          946164.805703          0.231103794152          218662.276491
12          95000.0          126000.0          100000.0      0.112156654785       11215.6654785          443921.672608          -150000.0          -16823.4982177          960745.170825          0.225264964904          216422.227187
13          100000.0          132000.0          100000.0      0.0934638789872       9346.38789872          453268.060506          -200000.0          -18692.7757974          971960.836304          0.220620001083          214434.000758
14          105000.0          138000.0          100000.0      0.0778865658226       7788.65658226          461056.717089          -250000.0          -19471.6414557          980528.358544          0.216893055222          212669.791417
15          110000.0          144000.0          100000.0      0.0649054715189       6490.54715189          467547.264241          -300000.0          -19471.6414557          987018.905696          0.213882119838          211105.69587


## Example 11.3 Page 152¶

In [12]:
#initiation of variable
IR=5.0;#in % per year
i=15.0;#in % per year
#Machine X :
Ppx=1500000.0;#in Rs.
n=7.0;#in years
S=200000.0;#in Rs.
AMC=300000.0;#in Rs.
print "End of year     AMC     InflationFactor     InflatedAmount     P/F     PW";
Pw=0;#For initialising
for n in range (1,8) :
FP=(1+IR/100)**n
IA=AMC*FP;#in Rs.
PF=1/((1+i/100)**n);
PW=IA*PF;#in Rs.
Pw=Pw+PW;#in Rs.
print"     ",n,"        ",AMC,"         ",FP,"           ",IA,"          ",PF,"      ",PW;

print "Present worth of inflated annual operating and maintenance cost in Rs. : ",round(Pw,3);
PWX=Ppx+Pw-S*1/((1+i/100)**n);
print "Present worth of machine X in Rs. : ",round(PWX,3);

#Machine Y

Ppy=2000000.0;#in Rs.
n=7.0;#in years
S=300000.0;#in Rs.
AMC=250000.0;#in Rs.
print "End of year     AMC     InflationFactor     InflatedAmount     P/F     PW";
Pw=0;#For initialising
for n in range (1,8) :
FP=(1+IR/100)**n
IA=AMC*FP;#in Rs.
PF=1/((1+i/100)**n);
PW=IA*PF;#in Rs.
Pw=Pw+PW;#in Rs.
print "     ",n,"        ",AMC,"         ",FP,"           ",IA,"          ",PF,"      ",PW;

PWY=Ppy+Pw-S*1/((1+i/100)**n);

#result
print "Present worth of inflated annual operating and maintenance cost in Rs. : ",round(Pw,3);
print "Present worth of machine Y in Rs. : ",round(PWY,3);
print "Since the present worth of Machine X is less than Machine Y, select Machine X"
print " Calculations are not accurate in the book"

End of year     AMC     InflationFactor     InflatedAmount     P/F     PW
1          300000.0           1.05             315000.0            0.869565217391        273913.043478
2          300000.0           1.1025             330750.0            0.756143667297        250094.517958
3          300000.0           1.157625             347287.5            0.657516232432        228347.168571
4          300000.0           1.21550625             364651.875            0.571753245593        208490.893043
5          300000.0           1.2762815625             382884.46875            0.497176735298        190361.25017
6          300000.0           1.34009564063             402028.692188            0.432327595912        173808.097981
7          300000.0           1.40710042266             422130.126797            0.375937039923        158694.35033
Present worth of inflated annual operating and maintenance cost in Rs. :  1483709.322
Present worth of machine X in Rs. :  2908521.914
End of year     AMC     InflationFactor     InflatedAmount     P/F     PW
1          250000.0           1.05             262500.0            0.869565217391        228260.869565
2          250000.0           1.1025             275625.0            0.756143667297        208412.098299
3          250000.0           1.157625             289406.25            0.657516232432        190289.307142
4          250000.0           1.21550625             303876.5625            0.571753245593        173742.410869
5          250000.0           1.2762815625             319070.390625            0.497176735298        158634.375141
6          250000.0           1.34009564063             335023.910156            0.432327595912        144840.081651
7          250000.0           1.40710042266             351775.105664            0.375937039923        132245.291942
Present worth of inflated annual operating and maintenance cost in Rs. :  1236424.435
Present worth of machine Y in Rs. :  3123643.323
Since the present worth of Machine X is less than Machine Y, select Machine X
Calculations are not accurate in the book


## Example 11.4 Page 156¶

In [19]:
#initiation of variable
IR=6.0;#in % per year
i=18.0;#in % per year
AFR=5000000.0;#in Rs.
n=7.0;#in years
AI=500000.0;#in Rs.
print"End of year            AFR         InflationFactor     InflatedAmount  P/F           PW";
TPW=0;#Initialising

for n in range (1,6) :
IF=(1+IR/100)**n;
IA=IF*AFR;#in Rs.
PF=1/((1+i/100)**n);
PW=PF*IA;#in Rs.
TPW=PW+TPW;#in Rs.
print"       ",round(n),"        ",round(AFR,3),"        ",round(IF,3),"        ",round(IA,3),"    ",round(PF,3),"     ",round(PW,3);
AFR=AFR+AI;#in Rs.

#result
print "The value of the single deposit to be made now to recieve the specified series for the next five years is Rs. : ",round(TPW,3)

End of year            AFR         InflationFactor     InflatedAmount  P/F           PW
1.0          5000000.0          1.06          5300000.0      0.847       4491525.424
2.0          5500000.0          1.124          6179800.0      0.718       4438236.139
3.0          6000000.0          1.191          7146096.0      0.609       4349334.645
4.0          6500000.0          1.262          8206100.24      0.516       4232615.212
5.0          7000000.0          1.338          9367579.043      0.437       4094655.134
The value of the single deposit to be made now to recieve the specified series for the next five years is Rs. :  21606366.553