**3.2 Construction of compact schemes of the convective-diffusion problem based on the finite volume method**

The finite volume method is one of the methods that can give a good approximate solution to the problem. Here we explore the application of the finite volume method to solve the convection-diffusion equation for constructing compact schemes.


**Table 1.** *The root-mean-square errors.*

The basic strategy of all finite volume methods is to write the differential equation in a conservative form, integrate it over small domains (called "cells" or "finite volumes"), and transform each such integral over the cell boundary.

Our goal is to construct a qualitative scheme for the problem (82)

$$\frac{d}{d\mathfrak{x}}(\rho u \Phi) = \frac{d}{d\mathfrak{x}}\left(\Gamma \frac{d\Phi}{d\mathfrak{x}}\right) + \mathcal{S}(\mathfrak{x}) \tag{82}$$

$$\Phi(\mathbf{0}) = \Phi\_0, \quad \Phi(\mathbf{1}) = \Phi\_1 \tag{83}$$

based on the control volume method. The procedure for obtaining a scheme is similar to that described in paragraph 3.1.

On [0,1] we introduce a non-uniform grid

$$\mathfrak{Q} = \{ \mathfrak{x}\_i, i = 0, 1, 2, \dots, N, 0 = \mathfrak{x}\_0 < \mathfrak{x}\_1 < \dots < \mathfrak{x}\_{i-1} < \mathfrak{x}\_i < \mathfrak{x}\_{i+1} < \dots < \mathfrak{x}\_N = 1 \}. $$

In the first chapter, with the help of moving nodes, an analytical solution to problem (82), (83) was constructed using the control volume method in the form.

$$\begin{aligned} \left[ \frac{(\mathbf{1} - \tau\_k) \boldsymbol{\theta}\_k^+}{\mathbf{1} - \tau\_k^{\mathbf{z}}} + \frac{(\mathbf{1} - \boldsymbol{\gamma}\_k) \boldsymbol{a}\_k^-}{\mathbf{1} - \boldsymbol{\gamma}\_k^{\mathbf{z}}} \right] \boldsymbol{U}^k &= \frac{(\mathbf{1} - \tau\_k) \boldsymbol{\theta}\_k^+}{\mathbf{1} - \tau\_k^{\mathbf{z}}} \boldsymbol{U}\_W^k + \frac{(\mathbf{1} - \boldsymbol{\gamma}\_k) \boldsymbol{a}\_k^-}{\mathbf{1} - \boldsymbol{\gamma}\_k^{\mathbf{z}}} \boldsymbol{U}\_E^k + \frac{\mathbf{E} - \mathbf{W}}{2^{k+1}} \cdot \mathbf{S}(\mathbf{x}) \\\\ &+ \frac{\mathbf{1} - \tau\_k}{\mathbf{1} - \tau\_k^{\mathbf{z}}} \cdot \frac{\mathbf{x} - \mathbf{W}}{2^k} \cdot \sum\_{j=1}^{2^k - 1} \sum\_{i=1}^j \boldsymbol{\gamma}\_k^{\mathbf{i}-1} \mathbf{S} \left( \mathbf{W} + j \frac{\mathbf{x} - \mathbf{W}}{2^k} \right) \\\\ &+ \frac{\mathbf{1} - \gamma\_k}{\mathbf{1} - \boldsymbol{\gamma}\_k^{\mathbf{z}}} \cdot \frac{\mathbf{E} - \mathbf{x}}{2^k} \cdot \sum\_{j=1}^{2^k - 1} \sum\_{i=1}^j \boldsymbol{\gamma}\_k^{\mathbf{i}-1} \mathbf{S} \left( \mathbf{x} + \left( \mathbf{2}^k - j \right) \frac{\mathbf{E} - \mathbf{x}}{2} \right). \end{aligned} \tag{84}$$

Here *<sup>τ</sup><sup>k</sup>* <sup>¼</sup> *<sup>β</sup>*� *k β*þ *k* , *<sup>γ</sup><sup>k</sup>* <sup>¼</sup> *<sup>α</sup>*<sup>þ</sup> *k α*� *k* , *β*� *<sup>k</sup>* <sup>¼</sup> <sup>2</sup>*kDW* <sup>þ</sup> *<sup>F</sup>*�, *<sup>β</sup>*<sup>þ</sup> *<sup>k</sup>* <sup>¼</sup> <sup>2</sup>*kDW* <sup>þ</sup> *<sup>F</sup>*þ, *<sup>α</sup>*� *<sup>k</sup>* <sup>¼</sup> <sup>2</sup>*kDE* <sup>þ</sup> *<sup>F</sup>*�, *<sup>α</sup>*<sup>þ</sup> *<sup>k</sup>* ¼ <sup>2</sup>*kDE* <sup>þ</sup> *<sup>F</sup>*þ, *<sup>F</sup>*� <sup>¼</sup> maxð Þ �*F*, 0 , *<sup>F</sup>*<sup>þ</sup> <sup>¼</sup> maxð Þ *<sup>F</sup>*, 0 , *DE* <sup>¼</sup> *<sup>Г</sup>=*ð Þ *<sup>E</sup>* � *<sup>x</sup>* , *DW* <sup>¼</sup> *<sup>Г</sup>=*ð Þ *<sup>x</sup>* � *<sup>W</sup>* . Now let us write Eq. (84) for an arbitrary internal node *xi*, which is connected with

neighboring nodes *xi*�1, *xi*þ1.

Then

$$
\left[\frac{(1-\tau\_k)\boldsymbol{\theta}\_k^+}{\mathbf{1}-\tau\_k^{\boldsymbol{\varphi}}}+\frac{(\mathbf{1}-\boldsymbol{\gamma}\_k)a\_k^-}{\mathbf{1}-\boldsymbol{\gamma}\_k^{\boldsymbol{\varphi}}}\right]U\_P^{\boldsymbol{k}} = \frac{(\mathbf{1}-\tau\_k)\boldsymbol{\theta}\_k^+}{\mathbf{1}-\tau\_k^{\boldsymbol{\varphi}}}U\_W^k + \frac{(\mathbf{1}-\boldsymbol{\gamma}\_k)a\_k^-}{\mathbf{1}-\boldsymbol{\gamma}\_k^{\boldsymbol{\varphi}}}U\_E^k + \frac{\mathbf{x}\_{i+1} - \mathbf{x}\_{i-1}}{2^{k+1}} \cdot S(\mathbf{x}\_i) + \frac{\mathbf{x}\_{i+1} - \mathbf{x}\_i}{\mathbf{1}-\boldsymbol{\gamma}\_k^{\boldsymbol{\varphi}}} \cdot U\_E^{\boldsymbol{k}}\tag{85}
$$

$$
\frac{\mathbf{1}-\tau\_k}{\mathbf{1}-\tau\_k^{\boldsymbol{\varphi}}} \cdot \frac{\mathbf{x}\_i - \mathbf{x}\_{i-1}}{2^k} \cdot \sum\_{j=1}^{\tilde{\mathbf{x}}-1} \sum\_{m=1}^j \tau\_k^{\mathbf{m}-1} S\left(\mathbf{x}\_{i-1} + j\frac{\mathbf{x}\_i - \mathbf{x}\_{i-1}}{2^k}\right) + \tag{85}
$$

$$
\frac{\mathbf{1}-\gamma\_k}{\mathbf{1}-\gamma\_k^{\tilde{\mathbf{x}}}} \cdot \frac{\mathbf{x}\_{i+1} - \mathbf{x}\_i}{2^k} \cdot \sum\_{j=1}^{\tilde{\mathbf{x}}-1} \sum\_{m=1}^j \gamma\_k^{\mathbf{m}-1} S\left(\mathbf{x}\_i + \left(2^k - j\right)\frac{\mathbf{x}\_{i+1} - \mathbf{x}\_i}{2}\right).
$$

What does it have to do with *DE* ¼ *Г=*ð Þ *xi*þ<sup>1</sup> � *xi* , *DW* ¼ *Г=*ð Þ *xi* � *xi*�<sup>1</sup> *:*
