1
$\begingroup$

So this is a pension framework. I am trying to code a system and I don't want to have to brute force this answer, but I can't figure out a clean solution.

$$Fund = \sum_{i=1}^t [\cfrac{I\cdot e^{\frac{\pi i}{12K}}}{12K} \cdot C \cdot e^{\frac{Ri}{12K}}]$$

$I = $, annual income, $K = $ pay periods per month, $C =$ Contribution Rate (%), $R =$ expected annualized return (continuous), $\pi =$ expected annual income growth (continuous)

Solving for the derivatives:

$$ \cfrac{dFund}{dC} = \sum_{i=1}^t [\cfrac{I\cdot e^{\frac{\pi i}{12K}}}{12K} \ \cdot e^{\frac{Ri}{12K}}]$$

$$\cfrac{dFund}{dR} = \sum_{i=1}^t [\cfrac{I\cdot e^{\frac{\pi i}{12K}}}{12K} \cdot C \cdot e^{\frac{Ri}{12K}} \cdot \frac{i}{12K}]$$

If $\Delta C = 0.01$, $\Delta Fund_{C} = \Delta C \cdot \cfrac{dFund}{dC}$

How do I solve for $\Delta R$ if I want $\Delta R \cdot \cfrac{dFund}{dR} = \Delta Fund_{C} = \Delta C \cdot \cfrac{dFund}{dC}$?

Basically, is there a way to extract the value of the $\cfrac{i}{12K}$ term within the summation so that it can be expressed outside the summation?

Edit:

The goal is that by doing so, the problem would easily simplify to $\Delta R \cdot C \cdot \Sigma \frac{i}{12K} \cdot \frac{dFund}{dC} = \Delta Fund_C$, such that I could just solve for $\Delta R = (C \cdot \Sigma \frac{i}{12K})^{-1}$. Currently I using my code to calculate $\Delta Fund_R$ for a large sequence of $\Delta R$ values and then matching the closest $\Delta Fund_R$ to $\Delta Fund_C$. Incredibly inefficient from a resource standpoint.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.