[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference rusure::math

Title:Mathematics at DEC
Moderator:RUSURE::EDP
Created:Mon Feb 03 1986
Last Modified:Fri Jun 06 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:2083
Total number of notes:14613

1287.0. "multiple rate of return" by CSSE::NEILSEN (I used to be PULSAR::WALLY) Wed Aug 15 1990 13:49

A few notes in INVESTING have raised several questions which may be more 
likely to get good answers in this conference.  I will try to summarize 
the problem and the questions, but I have attached the previous discussion 
for reference.

Assume an investor makes deposits into and withdrawals from some investment
at irregular intervals, ending with a zero balance.  How should the return
on investment be calculated?

Is this the correct formula:

	0 = SUM ( Dk / ( 1 + i )^Tk ) 	for k = 1, 2, ... n

		Dk = deposit or withdrawal amount on day Tk, numbered
			from first deposit, with deposits given
			pistive sign and withdrawals negative


Does it correctly convert into a polynomial of degree Tn in (1+i)?

	0 = SUM ( Dk * ( 1 + i )^(Tn-Tk) ) for k = 1, 2, ... n

How many real, positive roots will this polynomial have?

How many real roots?

What is that relation between sign changes in a polynomial and number of 
real roots?

If there are multiple real roots, is there any way to choose the 'right' one?

Is there a better or another formula?  

		Hmm.  I may answer this myself in the next reply.

-------------------------------------------------

             <<< SUBWAY::DISK$D1:[NOTES$LIBRARY]INVESTING.NOTE;1 >>>
                          -< Investing and Computing >-
================================================================================
Note 1371.0             Need Help with ROI Calculation!!               6 replies
GIAMEM::ALAN                                         58 lines  23-MAR-1989 15:19
--------------------------------------------------------------------------------
    I need some help from some of you finance whiz's in calculating
    a rate of return year-to-date when more than one contribution
    (cash flow) has been made (on different dates of course).
    
    I've been reading all kinds of finance and quantitative analysis
    books trying to figure out how to do this but am just getting
    myself more confused by the minute. 
    
    A hypothetical example.
    
    Jan 1   Invest 1000 in a fund with a share price of $10.00. 
    	    Total shares - 100.
    
    Feb 9   Dividend paid of .50 a share, reinvestment price 10.10
            100 shares X .50  / 10.10 = 4.950 new shares
    	    Total shares 104.950
    
    Apr 1   Invest another 1000 same fund at a price of 10.20.
            New shares - 98.039
            Total shares - 202.989
    
    May 18  Cap Gain Dist. of .50 a share reinvestment price 10.30
            202.989 X .50  / 10.30 = 9.854 new shares
            Total shares - 212.843
    
    Jun 12  Today's price (NAV) is $10.40 and I want to calculate my
    	    return on investment year-to-date (not compounded annual
            return or annualized return)
    
    
    Using the basic return formula   P1 - P0 + D
                                     -----------
                                          P0
    
    I can calculate returns for the two investments seperately:
    
    Investment 1     10.40 - 10.00 + 1.00
                     -------------------- = 14.00%
                             10.00
    
    
    Investment 2     10.40 - 10.20 + .50
                     ------------------- = 6.86%
                             10.20

    
    Okay so far, but what do I do now to calculate an overall ROI 
    year-to-date figure. It's at this point that all the discussions
    of time-weighted vs. dollar-weighted returns seem to break down.
    They always assume periods of equal length, or no cash flows,
    or cash flows always at the exact beginning or end of a period etc,
    etc.. Perfect world scenarios in an imperfect world.
    
    If anyone can help me with the math on this I would greatly 
    appreciate it. Thanks!!
    
    -Rob
    T
================================================================================
Note 1371.1             Need Help with ROI Calculation!!                  1 of 6
GIAMEM::ALAN                                         21 lines  24-MAR-1989 13:41
                          -< On further reflection! >-
--------------------------------------------------------------------------------
    Come to think of it, aren't the hypothetical returns calculated
    in .0 artificially high because on the dates of the distributions
    the NAV would be reduced by the amounts of the distributions. So
    if P1 was not adjusted to reflect the distributions you would be
    using an ending value that was too high. So for an accurate ROI
    calculation wouldn't you have to use an adjusted ending NAV???
    
    It seems to me after more thought that in one sense you could
    consider the total ROI year-to-date to be simply the sum of the
    seperately calculated returns (14.00 + 6.86 = 20.86). But when
    you do this there is no basis to compare this return against.
    If you were to calculate an average investment per day you 
    would get an average of $1309.322 invested for each day Jan 1 -
    Jun 12. But if you take the actual profit realized ($208.60) and
    divide it by the average daily investment you get a return of
    15.93% which obviously doesn't agree with the 20.86%. So I am still
    looking for the correct way to calculate an accurate year-to-date
    return when more than one purchase has been made.
    
    Can anybody help!!!!
    
================================================================================
Note 1371.2             Need Help with ROI Calculation!!                  2 of 6
PBA::MARCHETTI "Mama said there'd be days like this" 38 lines  27-MAR-1989 10:52
                     -< Nobody said it was gonna be easy >-
--------------------------------------------------------------------------------
    Maybe this will help.
    
    Break the investment down into daily increments.  You invested $1000
    on day 0 (Jan 1), and another $1000 on day 88 (Apr 1). On day 160
    (Jun 12), you're investments are worth $2214.
    
    Now, find the daily internal rate of return (IRR).  Unfortunately,
    there is no simple formula for this type of problem.  However, if
    we use the definition of IRR as the discount rate at which the Net
    Present Value = 0, we can set up the following relation:
    
       -1000        1000           2214
       ------  -  --------   +  --------- = 0
      (1+i)^0     (1+i)^88      (1+i)^160     
    
    Setting this up in a spreadsheet will allow you to input various
    levels of i until you can make the above relationship = 0.  You
    will then have the daily internal rate of return.  Then calculating
    (1+i)^160 (the number of total days) will give you the return on
    investment for the investment period.  
           
    When I did this, I came up with 15.62%, which is quite close to
    your calculation using average daily balance.
                     
    I realize that this is pretty involved, but it's the only way to
    do it with non-uniform investment periods.
    
    One shortcoming of the above approach is that it is technically
    possible under some situations to have more that one value of i that
    can satisfy the NPV=0 relationship.  If you're selling the
    investment to someone else, use the higher one.  If you're buying,
    use the lower.  8-).  
    
    Bob
     
    
    
    
================================================================================
Note 1371.3             Need Help with ROI Calculation!!                  3 of 6
MQOU02::CHEVRIER "Hmmm.... The sun of a beach"       11 lines  13-AUG-1990 14:18
                         -< I get a different answer >-
--------------------------------------------------------------------------------
I tried the formula in .2 with Symphony and DECalc and both
times got something close of 0.00087039 for i instead of 0.1562
as it is said in the previous note.

The parentheses where placed as follows:

1000/((1+i)^88)

Did anybody else got that and are the parentheses well placed?

Michel 
================================================================================
Note 1371.4             Need Help with ROI Calculation!!                  4 of 6
HPSRAD::SUNDAR "Ganesh"                              34 lines  13-AUG-1990 21:53
                           -< interesting problem! >-
--------------------------------------------------------------------------------
    Curiosity got the better of me when I read .0 so I worked it out
    and arrived as the same "general" solution as Bob in .2. Of course
    I was too lazy to work the math for the particular case in .0, 
    the fun is in the derivation. ;-)
    
    The last bit that Bob mentions about there being multiple solutions
    for "i" interests me. From my college days I seem to recall that
    for an nth-order polynomial there are exactly n roots, some of which
    may be imaginary (i.e. numbers that involve sqrt(-1) and therefore
    one would believe largely irrelevant to this problem unless you're trying
    to sell someone a bridge). Intuition also tells me that exactly one
    of these "n" solutions will be meaningful as long as there are only
    "inflows" of cash (i.e. you don't sell any shares or collect any 
    dividends etc during the entire period). 
    
    For the case when there is more than one "real" solution, how does one
    pick the most reasonable answer for "i"? Since "i" represents
    some sort of hypothetical growth rate, presumably solutions for "i"
    may be compared with actual growth rates over various time periods 
    and the one that is "least disparate" may be chosen. I would imagine
    such real growth rates ought to be time-weighted for the purposes
    of comparison. Then there's the business of what "least disparate"
    means - do we use "least squares" or "least absolute difference"
    and so on. 
    
    This is beginning to sound a bit too heavy for the notesfile,
    I should probably take it to mail with those who're still 
    thinking about it..
    
    -- Ganesh.
    
    Re .3 - as I indicated via mail, you forgot the bit about 
    calculating (1 + i)^180 -- or (1 + i)^365 for the annual rate.
       
================================================================================
Note 1371.5             Need Help with ROI Calculation!!                  5 of 6
DECSIM::GROSS "The bug stops here"                   22 lines  14-AUG-1990 11:06
                                  -< Math... >-
--------------------------------------------------------------------------------
If you take the equation in .2

	 -1000	    1000       2214
	------- - -------- + --------- = 0
	(1+i)^0   (1+i)^88   (1+i)^160

and multiply through by -(1+i)^160, we get the equivalent equation
(ignoring the singularity at i=-1):

	1000*(1+i)^160 + 1000*(i+1)^72 - 2214 = 0

Since only even powers of (1+i) appear, a graph of this equation should be
symmetric vs i=-1. But you are, no doubt, interested only in positive rates
of return. In the region i>0, the derivitive of this equation is always
positive. I don't see how 2 real solutions can occur for which i>0.

I have a fuzzy recollection from way back when... that the number of possible
real roots to a polynomial equation depends on the number of sign alternations
in the coefficients. If that is so, this equation could have only one real
root anyway.

Dave
================================================================================
Note 1371.6             Need Help with ROI Calculation!!                  6 of 6
YUPPY::MOYES "Projects are fun"                       3 lines  15-AUG-1990 09:38
                                   -< IRR ? >-
--------------------------------------------------------------------------------
    Back to logic chaps ! ROI can only have one positive real root. Maybe
    you are confused with Internal Rate of Return calculations where
    multiplt solutions are possible ?
T.RTitleUserPersonal
Name
DateLines
1287.1an exponential formulaCSSE::NEILSENI used to be PULSAR::WALLYWed Aug 15 1990 14:0819
The folks in INVESTING came up with a polynomial formula by assuming daily
compounding.  For reasonable rates of interest, daily compounding and
continuous compounding amount to the almost the same thing, so let's assume
continuous compounding.

Then the growth alternates between intervals of exponential growth and the
points Tk where the amount changes by Dk, again positive for deposits and 
negative for withdrawals.  The formula I get is 

	0 = SUM ( Dk * exp [ i * ( Tn - Tk ) ]  )

plus or minus the usual algebraic errors ;-)

It looks like some approximation should derive this formula from the polynomial, 
but I can't quite find it.

Is this an equally good formula for calculating i?

What can be said about its real roots?  or positive roots?