7th Workshop on Numerical Methods in Applied
Science and Engineering (NMASE 08)
Vall de Núria, 9 a 11 de enero de 2008
LaCàN,
c www.lacan-upc.es
NUMERICAL INTEGRATION BY USING LOCAL–NODE
GAUSS–HERMITE CUBATURE
R. D. Millán, A. M. Rosolen and M. Arroyo∗
LaCàN, Universitat Politècnica de Catalunya,
C/Jordi Girona 1-3, Barcelona 08934, Spain.
e-mail: daniel.millan,adrian.rosolen,
[email protected] web: http://www-lacan.upc.es
Key words: meshfree methods, Gauss–Hermite cubature, numerical integration
Abstract. A local–node numerical integration scheme for meshless methods is presented
in this work. The distinguishing characteristic of the introduced scheme is that not sup-
port mesh or grid to perform numerical integration is needed, besides the fact that gauss
cubature points for each node are generated in a properly fashion and that the extension
of the methodology to high dimensions is straightforward. The numerical integration is
computed with the Gauss–Hermite cubature formulas, and the partition of unity is em-
ployed to introduce the Gaussian weight in a natural way. Selected numerical tests in
two-dimensions are used to illustrate the validity of the proposed methodology. Although
the obtained results are encouraging, the behavior of the integration error is not still well
understood when the dimensionless parameter which control the width of the Gaussian
kernel varies.
1 INTRODUCTION
Gaussian quadratures are used to approximate the integral of a function f (x) over
a specified domain Ω ∈ Rd by using a known weighting kernel ψ(x). The concept of
quadrature is similar to that of numerical integration, especially when they are referred
to one-dimensional integrals. Although the term quadrature is also applied for higher
dimensional integration, two- and higher-dimensional integration are actually called cu-
bature.
In one dimension, an n-point quadrature rule can exactly evaluate the integral of a
polynomial of order up to 2n − 1. Therefore, if the function f (x) is well approximated by
a polynomial of order m = 2n − 1, then a quadrature with n quadrature points or nodes
suffices for a good estimate of the integral, i.e.
Z n
X
I(f ) = f (x)ψ(x)dx ≈ wi f (xi ). (1)
Ω i=1
1
R. D. Millán, A. M. Rosolen and M. Arroyo
The nodes xi and weights wi are uniquely determined by the choice of the domain Ω
and the weighting kernel ψ(x). In fact, one may go as far as to say that the choice of
the domain and the kernel defines a quadrature. In particular, the location of the nodes
xi are given by the roots of the polynomial of order mRin the sequence of orthonormal
polynomials {πj } generated by the metric hπj , πk i := Ω πj (x)πk (x)ψ(x)dx = δjk , and
the weights wi can be computed from a linear system once the roots are known. The
mathematics of quadrature methods is well understood and described in most textbooks
on numerical analysis[8].
1.1 Contrasts Between One Variable and More Than One Variable. Ex-
tracted from [8]
The theory of integration formulas like Equation (1) for functions of one variable is well
developed. A great deal of this theory can be found in the books by Krylov[6], Davis and
Rabinowitz[3], and Stroud and Secrest[9]. Formulas for the Equation (1) are relatively
easy to construct and, unless f (x) is badly behaved. There is not difficulty in obtaining an
accurate approximation to the integral. The reason this is true is related to the following
two facts:
1. One-dimensional space is much simpler geometrically than two- or higher-dimensional
spaces. Since all finite line segments are equivalent under an affine transformation
there is essentially only one bounded connected region in E1 .
2. The theory of integration formulas is closely connected with the theory of orthogonal
polynomials. In one variable the theory of orthogonal polynomials is fairly simple
and fairly completely known and is of great use in the construction of formulas.
Here Ed denotes real d-dimensional Euclidean space.
Although quite a number of integration formulas for multiple integrals are known the
theory of such formulas is far from complete. This is due largely to the greater complexity
of Ed , which can be summarized in part as follows:
• For each d ≥ 2 there are infinitely many distinct, bounded connected regions in Ed .
In E2 , for example, the square, circle, and triangle are tree regions which are not
equivalent under an affine transformation. Integration formulas for any one of these
regions are different from formulas for the others.
• The theory of orthogonal polynomials is more complicated in more than one variable.
No formulas have seen constructed in d-dimensions, d ≥ 3, using the theory of
orthogonal polynomials in d variables.
1.2 Product Formulas and Stability
In most cases d one-dimensional formulas, each of degree m, are combined to give a
formula of degree m for Rd . These deterministic cubature rules commonly are cited as
2
R. D. Millán, A. M. Rosolen and M. Arroyo
the standard tensor product cubature formulas. Thus, in multiple dimensions the com-
putation of the above integral, Equation (1), if an n-point integration rule is used in each
dimension in a d-dimensional space, needs nd function evaluations. The computational
burden therefore increases significantly with dimension d. This is often referred as the
curse of dimensionality.
In order to avoid the so-called curse of dimensionality, specific cubature rules are made
to approximate the numerical integration by taking into account the particularities of the
domains and the weight functions. For the interested reader, we commend the paper of
Cools [2], a very nice survey on this matter.
Another important issue that arises when an integration rule is used concerns with its
stability factor. Generally speaking from the perspective of integration, a rule with all its
points inside the integration region and all its weights positive is more desirable and will
have a small error than a formula for which one or both of these properties is lacking [8].
Integration rules with both positive and negative weights are particularly undesirable if
the magnitude of the weights are large compared with I(1). The reason is that a large
amount of roundoff error is introduced if
n
X n
X
|wi | wi = I(1).
i=1 i=1
Therefore, a standard measure of the stability factor of an integration
Prule is the ratio
n
between the sum of the absolute values of the weights and I(1), C = i=1 |wi |/I(1) [4].
A completely stable rule has C = 1, but so far there is no known general method for
constructing stable but efficient rules. For example the product Gauss–Hermite rule do
have C = 1, but the number nd of the f values needed for a degree 2n − 1 product
Gauss–Hermite rule grows so rapidly with n that using this rules becomes infeasible for
practical calculations when d > 3 or 4.
1.3 Gauss-Hermite Cubature
In this work, we are interested in to analyse numerical schemes which contain Gaussian
weight factors. The Gauss-Hermite cubature rules are the most appropriate to take into
account such factors.
In the case of multiple integrals over infinite regions Rd , and with integration kernel
2
given by e−|x| , the associate cubature scheme is known commonly under the name of
Gauss-Hermite since in one-dimension the involved orthogonal polynomials turn out to
be Hermite polynomials. Also Gauss-Hermite cubature is of fundamental importance
in many areas of applied mathematics that uses statistical representations, i.e. applied
sciences, financial mathematics, statistics and actuarial sciences[4, 7]. For this cubature
rule we have I(1) = π d/2 [8].
Reliable routines for the calculation of the roots and weights are readily available and
most mathematical software packages provide means for one-dimensional Gauss-Hermite
3
R. D. Millán, A. M. Rosolen and M. Arroyo
quadrature calculations [10]. For higher dimensions, there are not any free software pack-
age available, and rules are tabulated only for specific cases [8, 4].
The structure of the paper is as follows. In Section 2, the methodology is described. In
Section 3, selected numerical examples are shown. Some concluding remarks and future
work are finally indicated in Section 4.
2 Methods
Let X = {x1 , x2 , ..., xN } ⊂ Rd be a set of points sampling a domain Ω embedded in Rd ,
and f (x) a scalar function defined in Ω. The goal is to compute the numerical integral of
f (x) in Ω.
A local neighborhood of x is defined in terms of a weighting function φ, following the
maximum entropy philosophy, we use a Gaussian weight[1]:
φ(|x − xa |) = exp(−β|x − xa |2 ).
In numerical applications, this weight behaves like a compactly supported weight. For
efficiency, we thus define the neighbor index set of x as
N x = {a ∈ {1, 2, ..., N } | φ(|x − xa |) > TOL}.
Although explicitly not noted, the parameter β may be a function of x. It sets the range
of these hat functions, which should be large enough to reach enough neighbors.
2.1 Partition Of Unity
The first step in the method is to define a partition of unity based on the point set.
For instance, consider Shepard’s shape functions based on Gaussian weights:
exp(−βa |x − xa |2 ) exp(−βa |x − xa |2 )
qa (x) = P 2
= , x ∈ Ω, (2)
b∈N x exp(−βb |x − xb | ) Z(x)
although any other non-negative and smooth weighting function could be used. The
parameter βa sets the range of these hat functions, and depends on the local point density.
Following, the partition of unity is applied to the integration of a scalar function f (x)
in a domain Ω:
4
R. D. Millán, A. M. Rosolen and M. Arroyo
Z Z
f (x)dx = 1 f (x)dx
Ω Ω
Z !
X
= qa (x) f (x)dx
Ω a∈N x
N Z
X (3)
= qa (x) f (x)dx
a=1 Ω
N Z
X f (x) βa |x−xa |2
= e dx,
a=1 Ω Z(x)
d/2
Substituting x = xa + ξ/βa , the Equation (3) becomes:
Z N Z
X f (ξ) 2
f (x)dx = d/2
e|ξ| dξ
Ω a=1 Ω βa Z(ξ)
N Xn
(4)
X w(xi )f (xi )
≈ d/2
.
a=1 i=1 βa Z(xi )
3 Results
The proposed methodology is examined in 5 test functions, which are shown in Equa-
tions (5)–(9).
∗ 2
f1 (x) = e−ζ|x−x | (5)
" d #
∗ 2
Y
f2 (x) = g(xi ) e−ζ|x−x | (6)
i=1
" d #
∗ 2
p Y
f3 (x) = ζ (1 − g(xi )) e−ζ|x−x | (7)
i=1
" d
#
∗ 2
Y
f4 (x) = (1 − 2g(xi )) e−ζ|x−x | (8)
i=1
∗ |2
f5 (x) = ζ|x − x∗ |2 e−ζ|x−x (9)
where g(xi ) = cos(5π(xi − x∗i )), such that i = 1, 2, . . . , d. These functions are shown when
d = 2 in Figure 1, where it can be seen that the parameter ζ is chosen such that the fi (x)
vanish on the boundary. This is done in order to avoid no desirable boundary effects.
The analytical integration of those functions was obtained by using Mathematica. It
is important to remark that this work is only focus on the case d = 2.
5
R. D. Millán, A. M. Rosolen and M. Arroyo
f1 (x) f 2 ( x)
f 3 ( x) f 4 ( x) f 5 ( x)
Figure 1: Test functions used to analyse the proposed numerical integration methodology with ζ = 100.
Note that the ζ parameter is chosen such that the fi (x) vanish on the boundary of Ω = [0, 1] × [0, 1].
Figure 2 shows the integration error as a function of the dimensionless parameter
γ = βh2 for a two-dimensional node set, n = 10 sample points (order m = 6) for each node
were used [5]. The value of h is a measurement of the nodal spacing, and βa = β = γ/h2 is
constant over the domain Ω = [0, 1] × [0, 1], a = 1, . . . , N . Therefore, the shape functions
locality degree is controlled by the parameter γ. Finally, also are presented the results for
computing Gauss-Legendre numerical integration rule with n = 12 gauss points for each
triangle (order m = 7).
The integration error as a function of the parameter γ is depicted in Figure 3 for the ex-
pressions f3 (x) and f4 (x), which respectively present the worst and the best performance
in the Figure 2. The illustrated results corresponds to three sets of two-dimensional nodes,
h = 1/16, 1/32, 1/64.
4 DISCUSSIONS AND CONCLUSIONS
In this paper, an efficient and novel d-dimensional numerical integration scheme based
on partition of unity and Gauss-Hermite cubature rule is presented. The aim of the
6
R. D. Millán, A. M. Rosolen and M. Arroyo
Numerical Integration Error (h=1/32)
−4
10
−6
10
f1(x,y)
f2(x,y)
Error
−8
10
f3(x,y)
f4(x,y)
−10
10 f5(x,y)
−12
10
−14
10
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5
γ
Figure 2: Numerical integration error for the Equations (5)–(9) when the parameter γ varies int the
range [0.1, 5]. The horizontal curves (without lines) correspond to the Gauss-Legendre cubature, while
the others are obtained by the approximation based on Gauss-Hermite cubature. It was used a structured
mesh of hexagonal elements with h = 1/32.
Numerical Integration Error: f3(x,y) Numerical Integration Error: f4(x,y)
−4 −4
10 10
−6 −6
10 10
Error
Error
−8 −8
10 10
−10 −10
10 10
−12 −12
10 10
−14
h=1/16 h=1/32 h=1/64 −14
h=1/16 h=1/32 h=1/64
10 10
0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5 0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5
γ γ
(a) (b)
Figure 3: Integration error for the functions that present the worst (a) and the best (b) performance in
Figure 2. Three sets of two-dimensional nodes (h = 1/16, 1/32, 1/64) were used.
proposed methodology is to deal with problems in which no support mesh or any other
structured relationship for the node set is prescribed. The main drawback in the formu-
lation is related with the treatment of the nodes closest to the boundary, because they
7
R. D. Millán, A. M. Rosolen and M. Arroyo
contribute with sample points outside of the domain. In particular, we noted that the
value of I(1) is not satisfied when a pruning to delete the sample points external to the
domain is performed. For this reason, 5 test functions which vanish close to the boundary
were analysed in order to assess the methodology. Regardless the encouraging results
obtained for some values of γ, disappoint the fact that the integration error behavior is
not still well understood when this dimensionless parameter which control the width of
the Gaussian kernel varies.
We believe that the main causes of the results behavior is related (1) with the partition
of unity or (2) with a possible conceptual error in the formulation. In summary, no
concluding assessment of the methodology can be done, and it is necessary to perform
more studies.
We are currently working on a mixed formulation by merging Gauss-Legendre and
Gauss-Hermite integration rules to avoid boundary effects. The idea is to apply the first
one to the closest boundary nodes while the second one is used for the rest.
Future lines of research involve the extension of the formulation for a non Euclidean
tensor metric, and the validation of the approach to solve PDE’s with numerical meshfree
schemes.
REFERENCES
[1] M. Arroyo and M. Ortiz. Local maximum-entropy approximation schemes: a seamless
bridge between finite elements and meshfree methods. Int. J. Numer. Meth. Engr.,
Vol. 65, 2167–2202(2006).
[2] R. Cools. Advances in multidimensional integration, J. Comp. Appl. Math., Vol. 149,
1–12, 2002.
[3] P. J. Davis, and I. Rabinowitz. Numerical Integration. Blaisdell, Waltham, Mass.,
(1967).
[4] A. Genz and B. D. Keister. Fully symmetric interpolatory rules for multiple integrals
over infinite regions with Gaussian weigth. J. Comp. Appl. Math., Vol. 71(2), 299–
309(1996).
2
[5] T. Jankewitz. Cubature Formulae for the Plane E2r .
http://www.mi.uni-erlangen.de/~schmid/kubatur/jankewitz/CubFormSpace.html,
(2007).
[6] V. I. Krylov. Approximate Calculation of Integrals. Macmillan, New York,(1962).
[7] J. Lu and D. L. Darmofal. Higher-dimensional integration with Gaussian weigth
for applications in probabilistic design. SIAM J. Sci. Comput., Vol. 26(2), 613–
624(2004).
8
R. D. Millán, A. M. Rosolen and M. Arroyo
[8] A. H. Stroud. Approximate Calculation of Multiple Integrals. Prentice-Hall, Engle-
wood Cliffs, NJ, (1971).
[9] A. H. Stroud, and D. Secrest. Gaussian Quadrature Formulas. Prentice-Hall, Engle-
wood Cliffs, NJ, (1966).
[10] J. Burkardt. Quadrule,
http://people.scs.fsu.edu/~burkardt/m_src/quadrule/quadrule.html.
Con el apoyo de Universitat Politènica de Catalunya y E.T.S. d’Enginyers de Camins, Canals i Ports de
Barcelona