- Split input into 4 regimes
if i < -1.7376765862312233e-07
Initial program 30.0
\[100 \cdot \frac{{\left(1 + \frac{i}{n}\right)}^{n} - 1}{\frac{i}{n}}\]
- Using strategy
rm Applied add-exp-log30.0
\[\leadsto 100 \cdot \frac{{\color{blue}{\left(e^{\log \left(1 + \frac{i}{n}\right)}\right)}}^{n} - 1}{\frac{i}{n}}\]
Applied pow-exp30.0
\[\leadsto 100 \cdot \frac{\color{blue}{e^{\log \left(1 + \frac{i}{n}\right) \cdot n}} - 1}{\frac{i}{n}}\]
Applied simplify5.9
\[\leadsto 100 \cdot \frac{e^{\color{blue}{n \cdot \log_* (1 + \frac{i}{n})}} - 1}{\frac{i}{n}}\]
if -1.7376765862312233e-07 < i < 6.511266593892657e-22
Initial program 57.6
\[100 \cdot \frac{{\left(1 + \frac{i}{n}\right)}^{n} - 1}{\frac{i}{n}}\]
Taylor expanded around 0 57.4
\[\leadsto 100 \cdot \frac{\color{blue}{\left(\frac{1}{2} \cdot {i}^{2} + \left(1 + i\right)\right)} - 1}{\frac{i}{n}}\]
Applied simplify25.5
\[\leadsto \color{blue}{\frac{(i \cdot \left(i \cdot \frac{1}{2}\right) + i)_*}{\frac{i}{100 \cdot n}}}\]
- Using strategy
rm Applied associate-/r/9.0
\[\leadsto \color{blue}{\frac{(i \cdot \left(i \cdot \frac{1}{2}\right) + i)_*}{i} \cdot \left(100 \cdot n\right)}\]
if 6.511266593892657e-22 < i < 1.900905414541678e+126
Initial program 39.1
\[100 \cdot \frac{{\left(1 + \frac{i}{n}\right)}^{n} - 1}{\frac{i}{n}}\]
if 1.900905414541678e+126 < i
Initial program 31.8
\[100 \cdot \frac{{\left(1 + \frac{i}{n}\right)}^{n} - 1}{\frac{i}{n}}\]
Taylor expanded around -inf 62.8
\[\leadsto 100 \cdot \frac{\color{blue}{e^{n \cdot \left(\log \left(\frac{-1}{n}\right) - \log \left(\frac{-1}{i}\right)\right)} - 1}}{\frac{i}{n}}\]
Applied simplify24.8
\[\leadsto \color{blue}{\frac{n \cdot 100}{i} \cdot (e^{n \cdot \left(\left(0 + \log i\right) - \log n\right)} - 1)^*}\]
- Recombined 4 regimes into one program.
Applied simplify11.6
\[\leadsto \color{blue}{\begin{array}{l}
\mathbf{if}\;i \le -1.7376765862312233 \cdot 10^{-07}:\\
\;\;\;\;100 \cdot \frac{e^{n \cdot \log_* (1 + \frac{i}{n})} - 1}{\frac{i}{n}}\\
\mathbf{if}\;i \le 6.511266593892657 \cdot 10^{-22}:\\
\;\;\;\;\frac{(i \cdot \left(\frac{1}{2} \cdot i\right) + i)_*}{i} \cdot \left(100 \cdot n\right)\\
\mathbf{if}\;i \le 1.900905414541678 \cdot 10^{+126}:\\
\;\;\;\;\frac{{\left(1 + \frac{i}{n}\right)}^{n} - 1}{\frac{i}{n}} \cdot 100\\
\mathbf{else}:\\
\;\;\;\;\frac{100 \cdot n}{i} \cdot (e^{\left(\log i - \log n\right) \cdot n} - 1)^*\\
\end{array}}\]