Tectonic Stress Modelling with the Finite Element Method · 1.2 FEM for viscoelastic deformation...
Transcript of Tectonic Stress Modelling with the Finite Element Method · 1.2 FEM for viscoelastic deformation...
1
Numerical modelling with the finite element method: Some
principles and programs
Jason Zhao
2002
2
Contents
1. Finite element method and programs
2. Some tests
3. Mantle flow after crustal faulting
4. References
5. Appendix
3
1. Finite element method and programs
Although there are some commercial software packages on the market, most of them were not
designed for geodynamic modelling purposes. In addition, the vendors usually do not supply source
codes. In practice, it is quite common to modify the source codes of a program in order to develop
some new procedures for modelling some targeted problems. Moreover, most FEM programs cannot
be directly used for inverse modelling. Therefore, it is necessary to develop some new programs.
Three numerical models corresponding to elastic, viscoelastic, and viscous rheologies have been
constructed for stress analysis with FEM during 1999 - 2000 by assembling programs available in
published books and on the internet (e.g. Kirshnamoorthy, 1987; Zienkiewicz & Taylor, 1988; Smith
& Griffith, 1997). In the following, we present briefly the basic formulas associated with the FEM
models, and then introduce the main functions of the programs used in this study.
1.1 FEM for elastic deformation and stress analysis
Basic formulas (Zienkiewicz and Taylor, 1988):
ε = L u ………….. (strain → displacement) (1.1)
L1’ σ + p = 0 ………(in V) (1.2)
L2’ σ = q …………. (on S) (1.3)
σ = D ε …………….(stress → strain) (1.4)
where
LT = [b1 b2 b3],b1 = [∂/∂x 0 0 0 ∂/∂z ∂/∂y],b2 = [0 ∂/∂y 0 ∂/∂z 0 ∂/∂x],b3 = [0 0 ∂/∂z ∂/∂y ∂/∂x 0],
ε is the strain tensor, u is the displacement vector, L1 (relating to nodal stress to body forces) and L2
(relating nodal stress to traction) are the operators, σ is the stress tensor, p is the boundary force, q is
the surface traction, V is the volume of the 3D body, and S is the boundary surface of V. Elements
used in the FEM programs are shown in Figure 1.1. The advantage of using different types of
elements is that an object with complex geometry can be well approximated. The infinite element is
useful when investigating a local problem (Zienkiewicz and Taylor, 1988).
4
8-node-brick 6-node-prism 4-node-tetrahedron
infinite element fault-slip node
Fig. 1.1 Elements used in the FEM programs
Input/output:
Input: geometry, forces, material coefficients, displacements (strains), weak zones, fault
slip values, temperature changes and others;
Output: deformation and strain/stress.
12
1.2 FEM for viscoelastic deformation and stress analysis
The constitutive equations for a non-Newtonian viscoelastic material can be expressed as
(Melosh & Raefsky, 1980):
ε′ = f (σ0, σ′,σn-1, η) (1.5)
where σ′ and ε′ are the stress and strain rates, respectively, σ0 is the stress tensor, σ is the
fourth stress tensor, and η is the viscosity. For a linear Newtonian model used in this
study, n = 1, and the constitutive equations for a two-dimensional case are expressed as:
ε′xx = (1 + ν)/E [(1-ν) σ′xx - ν σ′yy] + σn-1 /(4η) [σxx - σyy] (1.6)
ε′yy = (1 + ν)/E [(1-ν) σ′yy - ν σ′xx] + σn-1 /(4η) [σyy - σxx] (1.7)
ε′xy = (1 + ν)/E σ′xy + σn-1 /(2η) σxy (1.8)
where E is the Young’s modulus, ν is the Poisson’s ratio, σ′xx, σ′xy, σ′yy and ε′xx, ε′xy,
ε′yy are the stress and strain rates, respectively, σxx, σxy, and σyy are the stress tensors.
Input/output:
Input: geometry, forces, material coefficients (e.g. viscosity values), velocities (strains),
weak zones, fault slip rates, and others;
Output: (flow) velocity field and strain/stress (rates).
1.3 FEM for viscous deformation and stress analysis
Basic formulas (Newtonian flow) (Bremaecker & Becker, 1978):
ε′ = L v ……(strain rate → velocity) (1.9)
∂vi/∂xi = 0 ..……………. (incompressible) (1.10)
∂τ ij/∂xi + pi = 0 ..………..(in V) (1.11)
τij nj = qi ………….…….. (on S) (1.12)
τij=τji ….………….. (Euler stress/symmetric) (1.13)
τij = - pδij + 2η vij ……….(Newtonian flow) (1.14)
13
Where
LT = [b1 b2 b3],b1 = [∂/∂x1 0 0 0 ∂/∂x3 ∂/∂x2],b2 = [0 ∂/∂x2 0 ∂/∂x3 0 ∂/∂x1],b3 = [0 0 ∂/∂x3 ∂/∂x2 ∂/∂x1 0],
τ is the stress tensor, v is the (flow) velocity field, η is the viscosity, ε′ is the strain rate, pi
is the body force, qi is the traction, p is the pressure, V is the volume of the 3D body, and
S is the boundary surface of V. The method used to solve the equations is given in
Appendix A.
Input/output:
Input: geometry, forces, viscosity values, velocities, fault slip (rate), and others;
Output: velocity (flow) and strain/stress rates.
1.4 FEM programs
In the following, we briefly introduce main functions of the numerical models used for
stress analysis.
Table 2.1 FEM models for stress analysis
Model Functions Language
VISKX 3D viscoelastic stress analysis FORTRAN
FLOW 3D viscous stress analysis FORTRAN
(1) VISKX - a 3D viscoelastic FEM program for simulating deformation and stress change
generated by fault interaction and any internal and external loads. Applications of the
program include: modelling deformation due to post-seismic relaxation processes,
simulating deformation due to post-glacial rebound, and investigating viscoelastic
responses of the earth to loading or unloading.
14
(2) FLOW - a 3D viscous FEM program for simulating crustal/lithospheric deformation
and stress evolution associated with plate motion and fault-slip on geological time scales.
The reactivation of a fault can be simulated by input of the strain rates of the fault points.
The programs are developed mainly based on a 3D code from the FEM book by
Krishnamoorthy (1987). The program structures and functions of most subroutines used
here have been described in the book, though some new routines have been added. It is
recommended to go through this book to fully understand the code structure.
2. Some tests
Test A:
A1. Model and data
A block contains 24 nodes and 5 brick elements.
The elastic modulus: E = 2.0 x 106
Poisson ratio = 0.00
15
Nodal forces: F6(z) = -4 x 104, and F17(z) = -4 x 104.
Nodes of 1, 7, 13 and 19 are fixed.
Nodal data:
1,01,01,01,01,1,1, 0.000, 0.000, 30.000, 0,0,0, 2,00,00,00,01,1,1, 0.000, 40.000, 30.000, 0,0,0, 3,00,00,00,01,1,1, 0.000, 80.000, 30.000, 0,0,0, 4,00,00,00,01,1,1, 0.000, 120.000, 30.000, 0,0,0, 5,00,00,00,01,1,1, 0.000, 160.000, 30.000, 0,0,0, 6,00,00,00,01,1,1, 0.000, 200.000, 30.000, 0,0,0, 7,01,01,01,01,1,1, 20.000, 0.000, 30.000, 0,0,0, 8,00,00,00,01,1,1, 20.000, 40.000, 30.000, 0,0,0, 9,00,00,00,01,1,1, 20.000, 80.000, 30.000, 0,0,0, 10,00,00,00,01,1,1, 20.000, 120.000, 30.000, 0,0,0, 11,00,00,00,01,1,1, 20.000, 160.000, 30.000, 0,0,0, 12,00,00,00,01,1,1, 20.000, 200.000, 30.000, 0,0,0, 13,01,01,01,01,1,1, 0.000, 0.000, 0.000, 0,0,0, 14,00,00,00,01,1,1, 0.000, 40.000, 0.000, 0,0,0, 15,00,00,00,01,1,1, 0.000, 80.000, 0.000, 0,0,0, 16,00,00,00,01,1,1, 0.000, 120.000, 0.000, 0,0,0, 17,00,00,00,01,1,1, 0.000, 160.000, 0.000, 0,0,0, 18,00,00,00,01,1,1, 0.000, 200.000, 0.000, 0,0,0, 19,01,01,01,01,1,1, 20.000, 0.000, 0.000, 0,0,0, 20,00,00,00,01,1,1, 20.000, 40.000, 0.000, 0,0,0, 21,00,00,00,01,1,1, 20.000, 80.000, 0.000, 0,0,0, 22,00,00,00,01,1,1, 20.000, 120.000, 0.000, 0,0,0, 23,00,00,00,01,1,1, 20.000, 160.000, 0.000, 0,0,0, 24,00,00,00,01,1,1, 20.000, 200.000, 0.000, 0,0,0,
Element data:
1 1 19 20 14 13 7 8 2 1 0 0 0 0 0 02 1 20 21 15 14 8 9 3 2 0 0 0 0 0 03 1 21 22 16 15 9 10 4 3 0 0 0 0 0 04 1 22 23 17 16 10 11 5 4 0 0 0 0 0 05 1 23 24 18 17 11 12 6 5 0 0 0 0 0 0
16
A2. Output
Nodal displacements (cm)
Node X-displacements Y-displacements Z-displacements
***** FROM T1= 0.000 yr. TO T2= 1.000 yr. ***** 1 0.0000000E+00 0.0000000E+00 0.0000000E+00 2 -0.2988061E-15 0.1270588E-01 -0.1827504E-01 3 0.1467739E-15 0.2258824E-01 -0.6666403E-01 4 0.1464052E-14 0.2964706E-01 -0.1376597E+00 5 0.3928661E-14 0.3388235E-01 -0.2236262E+00 6 0.6879913E-14 0.3529412E-01 -0.3175418E+00 7 0.0000000E+00 0.0000000E+00 0.0000000E+00 8 -0.2983724E-15 0.1270588E-01 -0.1827504E-01 9 0.1613835E-15 0.2258824E-01 -0.6666403E-01 10 0.1435592E-14 0.2964706E-01 -0.1376597E+00 11 0.3993333E-14 0.3388235E-01 -0.2236262E+00 12 0.6862566E-14 0.3529412E-01 -0.3175418E+00 13 0.0000000E+00 0.0000000E+00 0.0000000E+00 14 0.1044913E-14 -0.1270588E-01 -0.1827398E-01 15 0.2976528E-14 -0.2258824E-01 -0.6666930E-01 16 0.5986653E-14 -0.2964706E-01 -0.1376345E+00 17 0.9740520E-14 -0.3388235E-01 -0.2237464E+00 18 0.1413192E-13 -0.3529412E-01 -0.3169680E+00 19 0.0000000E+00 0.0000000E+00 0.0000000E+00 20 0.1042569E-14 -0.1270588E-01 -0.1827398E-01 21 0.2971364E-14 -0.2258824E-01 -0.6666930E-01 22 0.6013419E-14 -0.2964706E-01 -0.1376345E+00 23 0.9708814E-14 -0.3388235E-01 -0.2237464E+00 24 0.1412759E-13 -0.3529412E-01 -0.3169680E+00 -----------------------------------------
A3. Comparing with analytical results
Uz (cm)Distance fromthe end alongthe Y-axis (cm) Analytical FEM
0.00 (node 12) 0.29629 0.3175440.00 (node 11) 0.20859 0.2236280.00 (node 10) 0.12800 0.13766120.00 (node 9) 0.06163 0.06667160.00 (node 8) 0.01659 0.01828200.00 (node 7) 0.00000 0.00000
17
Test B
Prism elements
B1: Nodal data: Same as Test A.
Element Data
1 1 19 20 13 7 8 1 0 0 0 0 0 0 2 1 13 20 14 1 8 2 0 0 0 0 0 0 3 1 20 21 14 8 9 2 0 0 0 0 0 0 4 1 14 21 15 2 9 3 0 0 0 0 0 0 5 1 21 22 15 9 10 3 0 0 0 0 0 0 6 1 15 22 16 3 10 4 0 0 0 0 0 0 7 1 22 23 16 10 11 4 0 0 0 0 0 0 8 1 16 23 17 4 11 5 0 0 0 0 0 0 9 1 23 24 17 11 12 5 0 0 0 0 0 0 10 1 17 24 18 5 12 6 0 0 0 0 0 0
B2: Results:
Nodal displacements (cm)
Node X-displacements Y-displacements Z-displacements
***** FROM T1= 0.000 yr. TO T2= 1.000 yr. ***** 1 0.0000000E+00 0.0000000E+00 0.0000000E+00 2 -0.5927777E-02 0.1641801E-01 -0.2312350E-01 3 -0.9426253E-02 0.2874495E-01 -0.8415672E-01 4 -0.1181673E-01 0.3746523E-01 -0.1732706E+00 5 -0.1306780E-01 0.4259793E-01 -0.2806678E+00 6 -0.1347275E-01 0.4395588E-01 -0.3975436E+00 7 0.0000000E+00 0.0000000E+00 0.0000000E+00 8 -0.2001348E-02 0.1428098E-01 -0.1819162E-01 9 -0.5728269E-02 0.2697011E-01 -0.7387230E-01 10 -0.9437412E-02 0.3626300E-01 -0.1589458E+00 11 -0.1184736E-01 0.4193661E-01 -0.2640486E+00 12 -0.1289858E-01 0.4427209E-01 -0.3797556E+00 13 0.0000000E+00 0.0000000E+00 0.0000000E+00 14 0.5927777E-02 -0.1641801E-01 -0.2312402E-01 15 0.9426253E-02 -0.2874495E-01 -0.8415859E-01 16 0.1181673E-01 -0.3746523E-01 -0.1732411E+00 17 0.1306780E-01 -0.4259793E-01 -0.2808431E+00 18 0.1347275E-01 -0.4395588E-01 -0.3970097E+00 19 0.0000000E+00 0.0000000E+00 0.0000000E+00 20 0.2001348E-02 -0.1428098E-01 -0.1819192E-01 21 0.5728269E-02 -0.2697011E-01 -0.7386952E-01 22 0.9437412E-02 -0.3626300E-01 -0.1589574E+00 23 0.1184736E-01 -0.4193661E-01 -0.2640368E+00 24 0.1289858E-01 -0.4427209E-01 -0.3795231E+00 -----------------------------------------
18
B3. Comparing with analytical results
Uz (cm)Distance fromthe end alongthe Y-axis (cm) Analytical FEM
0.00 (node 12) 0.29629 0.3797640.00 (node 11) 0.20859 0.2640580.00 (node 10) 0.12800 0.15895120.00 (node 9) 0.06163 0.07387160.00 (node 8) 0.01659 0.01819200.00 (node 7) 0.00000 0.00000
19
3. Mantle flow after crustal faulting
Objectives:
1. mapping viscoelastic flow after a rupture;2. analyzing stress distribution associated with mantle flow;3. discussing implications for interaction of multi-faults
3.1 Model setup
The volume of the block is 160 x 160 x 75km (Fig.1). The crust is taken to be 30km thick,and it is divided into four layers: 7.5km, 7.5km, 7.5km, 7.5km. The mantle is taken to be45km, and it divided into two layers: 15km, and 30km. The fault is 30km long (alongstrike) and its down-dip length is 32km. The dip-angle is 68.2 (deg) and the thrust value is1.132m.
Fig. 3.1
0
50
100
1500
2040
6080
100120
140160
0
10
20
30
40
50
60
70
Y(km)X(km)
Z(k
m) upper crust
lower crust
mantle
20
Table 3.1 Rheological parameters
LayerElastic modulusE (Pa)
Poisson ratioν
Viscosityη (Pa s) notes
upper crust(0-15km)
3x1010 Pa 0.25 - elastic
lower crust(15-30km)
3x1010 Pa 0.25 1.0 x 1018 viscoelastic
mantle(30km-bottom)
5x1010 Pa 0.25 2.0x1020 viscoelastic
Boundary conditions: the bottom face is taken as fixed, and side faces are free-slip(only the vertical motion is allowed at the side points). Note that the two triangles in Fig. 1marked the profile along which the vertical deformation at four depth levels are shownbelow.
21
3.2 Horizontal deformation
Coseismic horizontal deformation at four depth levels
Fig. 3.2 Coseismic horizontal deformation
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
1.0m
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
1.0m
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
1.0m
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
0.2m
depth = 0km
Horizontal deformation (t=0 yr)
depth = 15km
depth = 30km depth = 45km
22
Postseismic velocity at t = 1yr (one year after the rupture)
Fig. 3.2 Postseismic horizontal deformation (t = 1yr)
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5cm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5cm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5mm
Horizontal deformation (t = 1yr)
depth = 0km depth = 15km
depth = 30km depth =45 km
23
Postseismic velocity at t = 2yr (two years after the rupture)
Fig. 3.4 Postseismic horizontal deformation (t = 2yr)
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
10mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
0.5mm
Horizontal deformation (t = 2yr)
depth = 0km depth = 15km
depth = 30km depth = 45km
24
Postseismic velocity at t = 3yr (three years after the rupture)
Fig. 3.5 Postseismic horizontal deformation (t = 3yr)
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
5mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
10mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
3mm
50 60 70 80 90 100 11050
60
70
80
90
100
110
120
X(km)
Y(k
m)
0.5mm
Horizontal deformation (t = 3yr)
depth = 0km depth = 15km
depth = 30km depth = 45km
25
3.3 Vertical deformation
Coseismic vertical displacements (t = 0 yr)
Fig. 3.6 Coseismic vertical displacement along a profile (marked triangle, see Fig.1)perpendicular to the fault strike at four depth levels.
0 50 100 150-50
0
50
dh(c
m)
0 50 100 150-50
0
50
dh(c
m)
0 50 100 150-50
0
50
dh(c
m)
0 50 100 150-50
0
50
dh(c
m)
Vertical deformation (t = 0yr)
depth = 0km depth = 15km
depth = 30km depth = 45km
Y(km)
Y(km)
Y(km)
Y(km)
26
Postseismic vertical velocity at t = 1yr (one year after the rupture)
Fig. 3.7 Postseismic vertical displacement along a profile perpendicular to the fault strikeat four depth levels (t =1yr).
0 50 100 150-15
-10
-5
0
5
10
15
dh(c
m)
0 50 100 150-15
-10
-5
0
5
10
15
dh(c
m)
0 50 100 150-15
-10
-5
0
5
10
15
dh(c
m)
0 50 100 150-15
-10
-5
0
5
10
15
dh(c
m)
Vertical deformation (t = 1yr)
depth = 0km depth = 15km
depth = 30km depth = 45km
Y(km)Y(km)
Y(km)Y(km)
27
Postseismic vertical velocity at t = 2yr (two year after the rupture)
Fig. 3.8 Postseismic vertical displacement along a profile perpendicular to the fault strikeat four depth levels (t = 2yr).
0 50 100 150-1
0
1
2
3
dh(c
m)
0 50 100 150-1
0
1
2
3
dh(c
m)
0 50 100 150-1
0
1
2
3
dh(c
m)
0 50 100 150-1
0
1
2
3
dh(c
m)
depth = 0km depth = 15km
depth = 30km depth = 45km
Y(km)Y(km)
Y(km)Y(km)
Vertical deformation (t = 2yr)
28
Postseismic vertical velocity at t = 3yr (three years after the rupture)
Fig. 3.9 Postseismic vertical displacement along a profile perpendicular to the fault strikeat four depth levels (t = 3yr).
0 50 100 150-1
-0.5
0
0.5
1
1.5
2
dh(c
m)
0 50 100 150-1
-0.5
0
0.5
1
1.5
2
dh(c
m)
0 50 100 150-1
-0.5
0
0.5
1
1.5
2
dh(c
m)
0 50 100 150-1
-0.5
0
0.5
1
1.5
2
dh(c
m)
depth = 0km depth = 15km
depth = 30km depth = 45km
Y(km)Y(km)
Y(km)Y(km)
Vertical deformation (t = 3yr)
29
4. References
Bremaecker J. C. and E.B. Becker, finite element models of folding, Tectonophysics, 50,349-367, 1978.
Chandrupatla, T.R. and A.D. Belegundu, Introduction to Finite Elements inEngineering, Prentice Hall, Englewood Cliffs, New Jersey, 414pp, 1991.
Cook, R.D., Concepts and Applications of Finite Element Analysis, John Wiley &Son, New York, 2nd ed. 537pp, 1981.
Krishnamoorthy, C.S., Finite Element Analysis: Theory and Programming, TataMcGraw-Hill Publishing Com. Limited, New Delhi, 551pp, 1987.
Melosh H.J. and A. Raefsky, The dynamical origin of subduction zone topography.
Melosh H.J. and Raefsky, A simple and efficient method for introducing faultsinto finite element computations, Bull. Seism. Soc. Am., 71, 1391-1400, 1981.
Smith I.M. and D.V. Griffiths, Programming the Finite Element Method, JohnWiley & Sons, Brisbane, 3rd ed., 534pp, 1997.
Zienkiewicz, O.C. and R.L. Taylor, The Finite Element Method, Vol.1, BasicFormulation and Linear Problems, McGraw-Hill Book Com., London, 4th ed., 648pp,1988.
Zienkiewicz O.C., C. Emson, and P. Bettess, A novel boundary infinite element,Int. J. Num. Meth. Engng., 19, 393-404, 1983.
30
5. Appendix A
Some considerations for solving large matrix equations associated with
viscous models
When the dimension of the linear equation system in the viscous stress modelling is large,
some measures have to be taken in order to save memory and storage in a computer. For a
viscous modelling problem, we usually have to solve the following matrix equations:
A X + B Y – R = 0 (A.1)
B1 X = 0 (A.2)
Where X is the nodal velocity vector, Y is the pressure vector, and, A, B, R, and B1 are
coefficient matrices. The rigorous solutions of the equation can be expressed as:
Y = (B1 A-1 B)-1 B1 A-1 R (A.3)
X = A-1 (R-BY) (A.4)
However, this requires to directly obtain the inverse of the matrix A. In practice, the
dimension of the matrix A is very high, so this method is seldom used. In practice, the
penalty function method is often used to solve the equation approximately (c.f.
Chandrupatla and Belegundu, 1991). By introducing a penalty factor ‘a’, the equations can
be transferred into
(A + a A1) X – R =0
where a is the penalty factor, and A1 is a matrix related to B. The downside of the penalty
function method is that (1) the selection of the penalty factor is somewhat arbitrary; (2)
iteration is required in the computation, which therefore takes a longer time to solve the
equations; and (3) the solutions obtained are approximate.
We consider the following steps to directly solve the equations:
31
(a) Since A is a symmetric matrix, we may store only its non-zero elements into a matrix
M. Usually, in such a way, more than 60% storage space can be saved
(Krishnamoorthy, 1987). The size of the matrix M is set to equal that of (B1 AB) so
that it can be used to store the elements of (B1 R2 B2) later, which has a dimension
equal to (B1 AB). Eliminate A from AX + B Y –R = 0 ( Note that A was stored in M),
we obtain:
X + B2 Y – R2 = 0 (now we no longer need A).
(b) Insert X into B1 X = 0, we have B1 (R2-B2 Y) = 0, and store B1 R2 B2 into the matrix
M.
(c) We now have M Y – B1 R2 = 0, and therefore can eliminate M to get Y.
(d) Get X from X + B2 Y – R2 = 0.
(e) Insert the solutions into the original equations to check the results which should meet:
‘0’ = ‘0’ or in a given error range.
This method requires a matrix M to store most of the elements, and the dimension of the
matrix is (np x np), where np is the total number of nodal points. So, the limit of a
machine/computer may be exceeded when np reaches a certain limit (it depends on the
type of computers).