Example 4. Calculate with an accuracy of $10^{-3}$ the value of the definite integral $\int_{0}^{1} \frac{e^{-x^{2}}-1}{x} d x$.
Solution. The given integral, as well as integrals of the form $\int_{a}^{b} \frac{\sin x}{x} d x$, $\int_{a}^{b} \frac{\cos x}{x} d x$, and some others, cannot be evaluated using the Newton-Leibniz formula. The reason is that the antiderivatives of such functions cannot be expressed in terms of elementary functions. The exact value of the definite integral is represented as a series, i.e., using an infinite set of arithmetic operations.

To expand the integrand into a power series, we use the standard expansion obtained above: in the expansion for $e^{x}$ (see point 2), replace $x$ with $x^{2}$, subtract 1 from the resulting expression, and divide the result by $x$.

$$
\begin{aligned}
\frac{e^{x^{2}}-1}{x}=\frac{1}{x}\left(1+x^{2}+\frac{x^{4}}{2!}+\frac{x^{6}}{3!}+\ldots+\frac{x^{2 n}}{n!}+\ldots\right. & -1)= \\
& =x+\frac{x^{3}}{2!}+\frac{x^{5}}{3!}+\frac{x^{7}}{4!}+\ldots
\end{aligned}
$$

After integration, we get

$$
\begin{aligned}
& \int_{0}^{1} \frac{e^{x^{2}}-1}{x} d x=\left.\left(\frac{x^{2}}{2}+\frac{x^{4}}{2!\cdot 4}+\frac{x^{6}}{3!\cdot 6}+\frac{x^{8}}{4!\cdot 8}+\ldots\right)\right|_{0} ^{1}= \\
& \quad=\frac{1}{2}+\frac{1}{8}+\frac{1}{36}+\frac{1}{192}+\frac{1}{1200}+\ldots
\end{aligned}
$$

To estimate the remainder term, note that

$$
\begin{aligned}
r_{5}=\frac{1}{6!\cdot 12}+\frac{1}{7!\cdot 14}+\frac{1}{8!\cdot 16}+\ldots<\frac{1}{6!12}\left(1+\frac{1}{7}+\frac{1}{7^{2}}\right. & +\ldots)< \\
& <\frac{1}{8640} \cdot 2<10^{-3}
\end{aligned}
$$

Thus, with the required accuracy, we have

$$
\int_{0}^{1} \frac{e^{x^{2}}-1}{x} d x=0.5+0.125+0.0278+0.0052+0.0008 \approx 0.659 \pm 10^{-3}
$$

Answer: 0.659.