I have two questions:
How can I calculate compound interest when I want to reinvest a percentage of the sum of my principal and interest periodically?
To make it clearer,
Usually I use this formula for calculating compound interest: $M = P( 1 + i )^n$.
This time I want to compound only a percentage of the sum of the principal and interest
EDIT
This is what I am looking at:
I invest $1000$ for a month, at the end of the month I get $1100$ (principal plus interest), and I want to re-invest $60%$ of the total amount for $n$ periods.
I want to compound the interest on the principal daily till the investment matures, i.e. if am investing for one year, I want the daily interest to be compounded to the principal.
For 2, you just regard each day as a separate term. So the interest rate is the rate per day and you have 365 (or 366 or 360!?) terms. For 365, if the interest rate were 10%/year, it would be 10/365$\approx $0.0274%/day, and the final value would be $1.000274^{365}$ times the original value, or about 1.105 times the original value.
For 1, what do you want to calculate? The final balance after N terms when at the end of each term the principal is reduced? The amount of interest received under those conditions? Probably it is easiest to make a spreadsheet for what you want.