$\lim_{x\rightarrow\infty}\frac{f(x)}{e^x}$ for analytic functions For some analytic function $f(x)=\lim_{n\rightarrow\infty}\sum^n_{r=0}c_rx^r$,
$$\lim_{x\rightarrow\infty}\frac{f(x)}{e^x}=\lim_{x\rightarrow\infty}\frac{\lim_{n\rightarrow\infty}\sum^n_{r=0}c_rx^r}{e^x}=\lim_{n\rightarrow\infty}\sum^n_{r=0}c_r\lim_{x\rightarrow\infty}\frac{x^r}{e^x}=\lim_{n\rightarrow\infty}\sum^n_{r=0}c_r(0)=\lim_{n\rightarrow\infty}0=0$$
But obviously this cannot be true? For say, $f(x)=e^x$ we would have $$\lim_{x\rightarrow\infty}\frac{e^x}{e^x}=1$$ and $$\lim_{x\rightarrow\infty}\frac{e^x}{e^x}=0$$
which would imply$$0=1$$
UPDATE:
An answer has suggested that the two limits cannot be inverted. Is this true and why is this so? I would like a more complete explanation if this is the case.
Also if this were the case, couldn't this modification to the question avoid that pitfall completely?
$f(x)=\sum^\infty_{r=0}c_rx^r$,
$$\lim_{x\rightarrow\infty}\frac{f(x)}{e^x}=\lim_{x\rightarrow\infty}\frac{\sum^\infty_{r=0}c_rx^r}{e^x}=\sum^\infty_{r=0}c_r\lim_{x\rightarrow\infty}\frac{x^r}{e^x}=\sum^\infty_{r=0}c_r(0)==0$$
Thanks in advance. Any other thoughts or comments welcome.
 A: Hint: This is a perfect example of why you can't always switch limits!
A: 
An answer has suggested that the two limits cannot be inverted. Is this true and why is this so?



*

*"Is this true?"  Yes, and your example shows why it is true.  The switching of limits leads to $0=1$, and therefore it is wrong.

*"Why is this so?"  Because the results of the limits in different orders is often different.  You have given one example of this.  

*"Also if this were the case, couldn't this modification to the question avoid that pitfall completely?...."  No, that actually is not a modification, just a more concise notation with the exact same meaning.  The value of an infinite series is, by definition, the limit of the sequence of partial sums.  That is, $\sum\limits_{r=0}^\infty a_r$ means the same thing as $\lim\limits_{n\to\infty}\sum\limits_{r=0}^n a_r$, provided the latter exists.  Thus, passing a limit through an infinite summation is a case of switching limits, and as your example shows, it is not always correct.
