# L'Hôpital's Rule Note that for some limits $\lim_{ n \to 0} \frac{3^n - 1}{n}$that we cannot actually divide a number when both the numerator and denominator are 0. This is when we need to use L'Hôpital's Rule, rigidly defined as: %%format this line pls%% $\text{if} \ \lim_{ n \to{a}} f(x) = 0 \ \text{and} \lim_{ n \to a } g(x) = 0 \lim_{ n \to a } \frac{f(x)}{g(x)} = \lim_{ n \to a } \frac{f'(x)}{g'(x)}$ This means that we can use L'Hopital's rule to get the limits of a function where direct substitution does not yield anything. Therefore, the above equation becomes: $\lim_{ n \to 0 } \frac{3^n - 1}{n} = \lim_{ n \to 0 } \frac{e^{{\ln 3}^n} - 1}{n} = \lim_{ n \to 0 } {\ln 3 e^{{\ln 3}^n} - 1} = \ln 3$ >[!Abstract]- Proving L'Hopital's Rule >We can use the fundamental theorem of calculus for the limit specified - rewrite the limit so that instead of $n \to a$ we have a limit $n \to a+h$, where $h$ is a small change in the limit subtending to 0: >$\lim_{ h \to 0 } \frac{f(a+h)}{g(a+h)}$ >Notice how this is already very, very similar to [[Calculus Basics (Maths)|differentiation from first principles]]. Note that the expressions $f(a)$ and $g(a)$ are all equal to 0 - this is a prerequisite for L'Hopital's rule, after all. As a result, creating the following expression does not change its value: >$\lim_{ h \to 0 } \frac{f(a+h) - f(a)}{g(a+h) - g(a)}$ >$h$ is an infinitely small value. Dividing by it will yield the formula for differentiation by first principles: >$\lim_{ h \to 0 } \frac{\frac{f(a+h) - f(a)}{h}}{\frac{g(a+h) - g(a)}{h}}$ >This gives us: >$\lim_{ h \to 0 } \frac{f'(a)}{g'(a)}$ >Meaning that we can generalise this change into the original $n \to a$ limit: >$\lim_{ n \to a } \frac{f'(n)}{g'(n)}$ >[!Warning]- Why the $e^{\ln 3}$ substitution? (placeholder bc i don't even know) >Note that the example question above has us substitute