When using trapezoidal sums, we can say: $$\int_{a}^{b} f(x) dx \approx T_{n} = \sum_{i=1}^{n} \dfrac{f(x_{i})+f(x_{i-1})}{2} \Delta x$$

If we let $I$ be the true value of the integral, then the error between the real solution and the trapezoidal sum is given by $\left| I - T_{n}\right|$. Through a long complicated process, we can also say the following is true:

$$\left| I - T_{n}\right| \leq \dfrac{D}{12} \dfrac{(b-a)^{3}}{n^{2}}$$ where $D$ is a bound on $f^{''}$ over $[a,b]$ and $n$ is the number of partitions used in the sum.

$$$$

For this problem specifically, we want $\left| I - T_{n} \right| < 0.0001$, meaning we want $\frac{D}{12} \frac{(2-0)^{3}}{n^{2}} < 0.0001$ In order to solve for $n$, we need to find a value for $D$. A quick glance at the graph above shows $2.5$ to be a fine choice for $D$. Armed with $D = 2.5$, we can say $$\left| I - T_{n}\right| \leq \dfrac{2.5}{12} \dfrac{(2-0)^{3}}{n^{2}} < 0.0001$$ which gives us $n >129$. So $n=130$ should give an estimate within the desired accuracy.

$$$$

Moving on to the sum, recall from earlier that $T_{n} = \sum_{i=1}^{n} \dfrac{f(x_{i})+f(x_{i-1})}{2} \Delta x$. Note $\Delta x = \frac{b-a}{n} = \frac{2}{130}$ and $x_{i} = a + i \Delta x = 0 + \frac{2i}{130}$. Thus,

$$\int_{0}^{2} e^{-x^{2}} dx \approx \sum_{i=1}^{130} \dfrac{e^{-\left(\frac{2i}{130}\right)^{2}}+e^{-\left(\frac{2(i-1)}{130}\right)^{2}}}{130}$$.

Let me know if anything seems wrong here. I was frustrated by the lack of a Latex preview while typing all that out and probably made numerous mistakes...