Find $\lim\limits_{n \to \infty} \left ( n - \sum\limits_{k = 1} ^ n e ^{\frac{k}{n^2}} \right)$. I have to find the limit:
$$\lim\limits_{n \to \infty} \bigg ( n - \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}} \bigg)$$
This is what I managed to do:
$$ e^{\frac{1}{n^2}} + e^{\frac{1}{n^2}} + ... + e^{\frac{1}{n^2}}
\le e^{\frac{1}{n^2}} + e^{\frac{2}{n^2}} + ...e^{\frac{n}{n^2}} \le
e^{\frac{n}{n^2}} + e^{\frac{n}{n^2}} + ... e^{\frac{n}{n^2}}$$
$$ n e^{\frac{1}{n^2}}
\le \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}} \le
ne^{\frac{1}{n}}$$
$$ -n e^{\frac{1}{n}}
\le - \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}} \le
- n e^{\frac{1}{n^2}}$$
$$ n - n e^{\frac{1}{n}}
\le n - \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}} \le
n - n e^{\frac{1}{n^2}}$$
Here I found that the limit of the left-hand side is equal to $-1$, while the limit of the right-hand side is $0$. So I got that:
$$-1 \le n - \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}} \le 0$$
And I cannot draw a conclusion about the exact limit. What should I do?
 A: Hint: $$a+a^2+...+a^n=\frac{a(a^n-1)}{a-1}$$
A: Using $e^x=1+x+O(x^2)$ along with $\sum_{k=1}^nk=\frac{n(n+1)}{2}$ and $\sum_{k=1}^n k^2=O\left(n^3\right)$ , we assert that
$$\begin{align}
\sum_{k=1}^ne^{k/n^2}&=\sum_{k=1}^n\left(1+\frac{k}{n^2}\right)+O\left(\frac{1}{n}\right)\\\\
&=n+\frac{n(n+1)}{2n^2}+O\left(\frac1n\right)\\\\
&=n+\frac12+O\left(\frac1n\right)
\end{align}$$
Hence, we see that 
$$\lim_{n\to\infty}\left(n-\sum_{k=1}^ne^{k/n^2}\right)=-\frac12$$
A: As @Andrei already answered, you face a geometric sum, that is to say that
$$\sum_{k = 1} ^ n e ^{\frac{k}{n^2}}=\sum_{k = 1} ^ n \left(e ^{\frac{1}{n^2}}\right)^k=\frac{e^{\frac{1}{n^2}} \left(e^{\frac{1}{n}}-1\right)}{e^{\frac{1}{n^2}}-1}$$ Now, expanding the exponentials as Taylor series, multiplying for the numerator and then long division, you should get
$$\sum_{k = 1} ^ n e ^{\frac{k}{n^2}}=n+\frac{1}{2}+\frac{2}{3 n}+O\left(\frac{1}{n^2}\right)$$
$$ n - \displaystyle\sum_{k = 1} ^ n e ^{\frac{k}{n^2}}=-\frac{1}{2}-\frac{2}{3 n}+O\left(\frac{1}{n^2}\right) $$ which shows the limit and also how it is approached.
Edit
In comments, @marty cohen made a good point.
If we consider
$$n-\sum_{k = 1} ^ {n^a} e ^{\frac{k}{n^2}}=n-\frac{e^{\frac{1}{n^2}} \left(e^{n^{a-2}}-1\right)}{e^{\frac{1}{n^2}}-1}$$ it will not converge for any $a \neq 1$ since it will be
$(n-n^a+\cdots)$
