**6. Integral from the regression function**

Now, we consider the issue of calculation of an integral

$$\int\_{D} f(\mathbf{x}) \, d\mathbf{x},\tag{38}$$

where the function *f x*ð Þ has no an analytical expression. Suppose there exists a random variable *ξ*ð Þ *x*, *w* such that its expectation is equals to E*ξ*ð Þ¼ *x*, *w f x*ð Þ for some fixed *x*. The random variable *ξ*ð Þ *x*, *w* may be realized neither as result of the physical measurements or some calculations (e.g., using the modeling statistical method). In this case the optimal density is given by [6].

*Stability of Algorithms in Statistical Modeling DOI: http://dx.doi.org/10.5772/intechopen.106136*

$$p(\mathbf{x}) = \frac{f(\mathbf{x})}{\sqrt{d(\mathbf{x}) + \lambda}},\tag{39}$$

where *d x*ð Þ is the variance of the random variable *ξ*ð Þ *x*, *w* . Note that one should use the optimal density from [1] if complexity in calculations (experimental measurements) is much different from each other for any *x*. We determine the parameter *λ* from the condition Ð *D f x*ð Þ*<sup>=</sup>* ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi *d x*ð Þþ *<sup>λ</sup>* <sup>p</sup> *dx* <sup>¼</sup> <sup>1</sup>*:* Really in practice, we find a

priori or a posteriori approaches to both *f x*ð Þ and *d x*ð Þ. By *f x*ð Þ and *d x*ð Þ denote these approaches. Then the approach to the optimal *p x*ð Þ will look like

$$\overline{p}(\mathbf{x}) = \frac{\overline{f}(\mathbf{x})}{\sqrt{\overline{d}(\mathbf{x}) + \overline{\lambda}}} \text{ and } \int\_{D} \frac{\overline{f}(\mathbf{x})}{\sqrt{\overline{d}(\mathbf{x}) + \overline{\lambda}}} d\mathbf{x} = \mathbf{1}. \tag{40}$$

The parameter *λ* is often turned out to be find enough complicity [6]. If the domain *D* is the interval 0, ½ � *H* for small *H* then it is suppose to use the quasioptimal density *p x*ð Þ.

Example 3. We now consider the following issue: Suppose *f x*ð Þ¼ *x*, *d x*ð Þ¼ 1*=x*, *D* ¼ ½ � 0, *H* . The optimal density is given by

$$p(\mathbf{x}) = \frac{\mathbf{x}}{\sqrt{1/\mathbf{x} + \lambda}} = \frac{\mathbf{x}\sqrt{\mathbf{x}}}{\sqrt{\lambda\sqrt{\mathbf{x}} + \mathbf{1}}} \sim c \cdot \mathbf{x}^{3/2}.\tag{41}$$

We take the quasioptimal density in the form *p x*ð Þ¼ <sup>5</sup>*H*<sup>5</sup>*=*<sup>2</sup> *x*<sup>3</sup>*=*<sup>2</sup>*=*2*:* In this case, for *p x*ð Þ� 1 the estimation variance of the random value *η* ¼ *f x*ð Þ , *w =p x*ð Þ:

$$\mathbf{var}\,\eta = \int\_0^H d(\mathbf{x}) p(\mathbf{x}) \,d\mathbf{x} + \int\_0^1 \frac{f^2}{p(\mathbf{x})} d\mathbf{x} - I^2 \tag{42}$$

is equals to <sup>∞</sup>. Taking *p x*ð Þ¼ <sup>2</sup>*x=H*<sup>2</sup> we get **var***<sup>η</sup>* <sup>¼</sup> <sup>2</sup>*=H:* But if the function *f x*ð Þ was precisely known for the same density *p x*ð Þ then **var***η* ¼ 0*:* If we choose the quasioptimal density *p x*ð Þ¼ <sup>5</sup>*H*<sup>5</sup>*=*<sup>2</sup> *x*<sup>3</sup>*=*<sup>2</sup>*=*2 then the estimation variance of *η* is equals to <sup>17</sup>*H*<sup>4</sup>*=*<sup>12</sup> <sup>þ</sup> <sup>4</sup>*=*ð Þ <sup>15</sup>*<sup>H</sup>* . For *<sup>H</sup>* ! 0 the variance behaves approximately as 4*=*ð Þ <sup>15</sup>*<sup>H</sup>* . It is much the better than 2*=H*. For *H* ¼ 1 the estimation variance with the density *p x*ð Þ¼ <sup>2</sup>*x=H*<sup>2</sup> is equals to 2, and the estimation variance with the quasioptimal density *p x*ð Þ is equals to 101/60.

Suppose we practically realize calculation of the integral Eq. (38) with *d x*ð Þ¼ 1*=x*; then one should discard the interval 0, ½ � *<sup>δ</sup>* and to calculate <sup>Ð</sup> *<sup>H</sup> <sup>δ</sup> f x*ð Þ*dx* because of the values <sup>∣</sup>*ξ*ð Þ *<sup>x</sup>*, *<sup>w</sup>* <sup>∣</sup> can be the intolerably large. Also one should replace *f x*ð Þ by ^*f x*ð Þ:

$$\hat{f}(\mathbf{x}) = \begin{cases} \mathbf{0}, & \mathbf{0} \le \mathbf{x} \le \delta, \\ \mathbf{x}, & \delta < \mathbf{x} \le H. \end{cases} \tag{43}$$

The shift is Ð *δ* 0 *xdx* <sup>¼</sup> *<sup>δ</sup>*<sup>2</sup> *<sup>=</sup>*2 and choosing *<sup>δ</sup>* � <sup>1</sup>*<sup>=</sup>* ffiffiffiffi *N* <sup>p</sup><sup>4</sup> we get the total error *<sup>δ</sup>*<sup>2</sup> *=*2 þ 3*σ=* ffiffiffiffi *N* <sup>p</sup> of oder *<sup>O</sup>* <sup>1</sup>*<sup>=</sup>* ffiffiffiffi *<sup>N</sup>* � � <sup>p</sup> .

In applications the estimation variance for the integral functionals (e.g., field flow calculation neither across the arc or the surface) from the solutions of the

boundary-value problems for both the linear [1] or nonlinear [2] elliptic equations is of interest. For the above variance is *d x*ð Þ� *<sup>B</sup>=x*2, *f x*ð Þ≈*a*<sup>0</sup> <sup>þ</sup> *<sup>a</sup>*1*<sup>x</sup>* <sup>þ</sup> *<sup>a</sup>*2*x*<sup>2</sup> <sup>þ</sup> … , where *<sup>x</sup>* is the distance to the domain boundary. Suppose *f x*ð Þ≈*a*1*<sup>x</sup>* <sup>þ</sup> *<sup>a</sup>*2*x*<sup>2</sup> <sup>þ</sup> … ; then the optimal density is given by

$$p(\mathbf{x}) = \frac{a\_1 \mathbf{x} + a\_2 \mathbf{x}^2 + \dots}{\sqrt{B/\mathbf{x}^2 + \lambda}}.\tag{44}$$

The quasioptimal density has the form *p x*ð Þ¼ <sup>3</sup>*x*2*=H*<sup>3</sup> for small *<sup>H</sup>* in 0, ½ � *<sup>H</sup>* . In applications, this case is of our main interest. Taking *<sup>δ</sup>* <sup>¼</sup> <sup>1</sup>*<sup>=</sup>* ffiffiffiffi *N* <sup>p</sup><sup>4</sup> like in the Example 3 we get the asymptotics of decrease for the total error as *O* 1*=* ffiffiffiffi *<sup>N</sup>* � � <sup>p</sup> .

Suppose *d x*ð Þ� *<sup>B</sup>=x*2, *f x*ð Þ≈*a*<sup>0</sup> <sup>þ</sup> *<sup>a</sup>*1*<sup>x</sup>* <sup>þ</sup> *<sup>a</sup>*2*x*<sup>2</sup> <sup>þ</sup> … , and *<sup>a</sup>*<sup>0</sup> 6¼ 0 then there is no density kind of *p x*ð Þ¼ ð Þ *<sup>w</sup>* <sup>þ</sup> <sup>1</sup> *xw*, *<sup>x</sup>*∈½ � 0, *<sup>H</sup>* with the finite variance. The density *p x*ð Þ¼ <sup>∣</sup>*f x*ð Þ∣*<sup>=</sup>* ffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffiffi *d x*ð Þþ *<sup>λ</sup>* <sup>p</sup> will be give the estimation with the infinity variance. Instead of calculation of the integral Ð *H* 0 *f x*ð Þ*dx* we will be calculate the integral <sup>Ð</sup> *H δ f x*ð Þ*dx*. For this integral we already can choice the quasioptimal density with the finite variance of the estimation: *p x*ð Þ¼ <sup>2</sup>*x<sup>=</sup> <sup>H</sup>*<sup>2</sup> � *<sup>δ</sup>*<sup>2</sup> � �. For *<sup>δ</sup>* � *<sup>O</sup>* ln *<sup>N</sup><sup>=</sup>* ffiffiffiffi *<sup>N</sup>* � � <sup>p</sup> the total error will have the asymptotics *O* ln *N=* ffiffiffiffi *<sup>N</sup>* � � <sup>p</sup> .

Example 4. Suppose *d x*ð Þ¼ <sup>1</sup>*=x*2, *f x*ð Þ¼ 1, *<sup>H</sup>* <sup>¼</sup> 1; then the asymptotics of the variance with the quasioptimal density has kind of ð Þ �2, 5 � ln *δ* .

In conditions of Example 4, choice of the optimal density in the form

$$p(\mathbf{x}) = \frac{\mathbf{x}}{\sqrt{\mathbf{1} - \delta^2}\sqrt{\mathbf{1} - \mathbf{x}^2}}, \quad \mathbf{x} \in [\delta, \mathbf{1}] \tag{45}$$

yields the following result: the estimation variance will have asymptotics ð Þ �2 � ln *δ* for *δ* ! 0.

**Remark**. If we know that a value of *f x*ð Þ in the interval 0, ½ � *δ* close to the number *f* <sup>0</sup>, then in Eq. (43) to use

$$\hat{f}(\mathbf{x}) = \begin{cases} f\_0, & \mathbf{0} \le \mathbf{x} \le \delta, \\ \mathbf{x}, & \delta < \mathbf{x} \le H, \end{cases} \tag{46}$$

more efficiently and also to take Ð *H* 0 *f x*ð Þ*dx*≈*<sup>f</sup>* <sup>0</sup>*<sup>δ</sup>* <sup>þ</sup> <sup>Ð</sup> *H δ f x*ð Þ*dx:*
