ISNM International Series of Numerical Mathematics Volume 159 Managing Editors: K.-H. Hoffmann, München G. Leugering, Erlangen-Nürnberg Associate Editors: Z. Chen, Beijing R. H. W. Hoppe, Augsburg / Houston N. Kenmochi, Chiba V. Starovoitov, Novosibirsk
Honorary Editor: J. Todd, Pasadena †
Exact and Truncated Difference Schemes for Boundary Value ODEs Ivan P. Gavrilyuk Martin Hermann Volodymyr L. Makarov Myroslav V. Kutniv
Ivan P. Gavrilyuk Staatliche Studienakademie Thüringen Berufsakademie Eisenach (University of Cooperative Education) Am Wartenberg 2 99817 Eisenach Germany
[email protected]
Martin Hermann Friedrich Schiller University Institute of Applied Mathematics Ernst-Abbe-Platz 2 07743 Jena Germany
[email protected]
Volodymyr L. Makarov National Academy of Sciences of Ukraine Institute of Mathematics Tereshchenkivska 3 01601 Kiev-4 Ukraine
[email protected]
Myroslav V. Kutniv Lviv Polytechnical National University Institute of Applied Mathematics S. Bandery 12 79013 Lviv Ukraine
[email protected]
ISBN 978-3-0348-0106-5 e-ISBN 978-3-0348-0107-2 DOI 10.1007/978-3-0348-0107-2 Library of Congress Control Number: 2011930753 2010 Mathematics Subject Classification: 65L10, 65L12, 65L20, 65L50, 65L70 © Springer Basel AG 2011 This work is subject to copyright. All rights are reserved, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, re-use of illustrations, broadcasting, reproduction on microfilms or in other ways, and storage in data banks. For any kind of use whatsoever, permission from the copyright owner must be obtained. Cover design: deblik, Berlin Printed on acid-free paper Springer Basel AG is part of Springer Science+Business Media www.birkhauser-science.com
This book is dedicated to the memory of Aleksandr Andreevich Samarskii
vii
Contents Preface
ix
1 Introduction and a short historical overview
1
1.1
BVPs, Grids, Differences, Difference Schemes . . . . . . . . . . . .
2
1.2
Short history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
17
2 2-point difference schemes for systems of ODEs
41
2.1
Existence and uniqueness of the solution . . . . . . . . . . . . . . .
42
2.2
Existence of a two-point EDS . . . . . . . . . . . . . . . . . . . . .
52
2.3
Implementation of the 2-point EDS . . . . . . . . . . . . . . . . . .
58
2.4
A posteriori error estimation and automatic grid generation . . . .
76
3 3-point difference schemes for scalar monotone ODEs
83
3.1
Problem setting . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
83
3.2
Existence of a three-point EDS . . . . . . . . . . . . . . . . . . . .
87
3.3
Implementation of the three-point EDS . . . . . . . . . . . . . . . 100
3.4
Boundary conditions of 3rd kind . . . . . . . . . . . . . . . . . . . 112
3.5
Numerical examples . . . . . . . . . . . . . . . . . . . . . . . . . . 115
4 3-point difference schemes for systems of monotone ODEs
121
4.1
Problem setting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121
4.2
Existence of a three-point EDS . . . . . . . . . . . . . . . . . . . . 125
4.3
Implementation of the three-point EDS . . . . . . . . . . . . . . . 139
4.4
Numerical examples . . . . . . . . . . . . . . . . . . . . . . . . . . 153
viii
CONTENTS 5 Difference schemes for BVPs on the half-axis
157
5.1
Existence and uniqueness of the solution . . . . . . . . . . . . . . . 158
5.2
Existence of an EDS . . . . . . . . . . . . . . . . . . . . . . . . . . 164
5.3
Implementation of the three-point EDS . . . . . . . . . . . . . . . 174
5.4
Numerical examples . . . . . . . . . . . . . . . . . . . . . . . . . . 195
6 Exercises and solutions
203
6.1
Exercises
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203
6.2
Solutions
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 214
Index
239
Bibliography
241
ix
Preface Work is much more fun than fun. Noel Coward (1899–1973) In this book we present a first unified theory of finite difference methods for the solution of linear and nonlinear boundary value problems (BVPs) of ordinary differential equations (ODEs). The aim of the authors is to describe the state-ofthe-art in this important field of numerical analysis. New numerical algorithms for BVPs are developed and evaluated which have the same efficiency and accuracy as the well-known and contemporary methods for the solution of initial value problems (IVPs). Moreover, the tools from different areas of mathematics (e.g. theory of ODEs, functional analysis, theory of difference schemes, systems of nonlinear algebraic equations) are formalized and unified to construct and justify numerical methods of a high order of accuracy for BVPs. The basis of the present text is the theory of difference schemes established by the famous Russian mathematician Aleksandr Andreevich Samarskii. Some of the authors were Samarskii’s students. The new class of exact and truncated difference schemes treated in this book can be considered as further developments of the results presented in his highly respected books [71, 72, 75]. It is shown that the new Samarskii-like techniques open horizon for the numerical treatment of more complicated problems. The main focus of this text is the theory of numerical methods for BVPs that are based on the exact difference schemes (EDS) as well as on the well-studied and sophisticated solvers for IVPs. The EDS themselves are only of theoretical interest. However, they are used as a starting point for the construction of so-called truncated difference schemes (TDS) suitable for implementation on a computer. It is shown that the combination of the EDS with the modern IVP-solvers results in numerical TDS-algorithms which are highly efficient. The theory of the EDS and TDS permits the construction of a posteriori error estimators which in turn are the basis for adaptive algorithms. The EDS/TDS and the well-known multiple shooting methods (see e.g. [35, 39, 40, 79, 84]) are based on similar concepts. However, compared with the shooting methods, the advantage of the new EDS and TDS algorithms is their detailed
x
Preface theoretical analysis and the possibility of estimating the error of the approximated solution by suitable a priori and a posteriori estimators. The reason for that is the good conformity of the structure of the difference equations with the original differential equations. The book is addressed to graduate students of mathematics and physics, as well as to working scientists and engineers as a self-study tool and reference. Researchers dealing with BVPs will find appropriate and effective numerical algorithms for their needs. The book can be used as a textbook for a one- or two-semester course on numerical methods for ODEs. Advanced calculus, basic numerical analysis, some ordinary differential equations, and a smattering of nonlinear functional analysis are assumed. Mathematically experienced engineers and scientists who are only interested in the practical use of the algorithms on a computer can skip without loss of understanding, the proofs of the theorems and the more theoretical parts of the book. We now outline the contents of the book. The introductionary chapter is designed to acquaint the reader with some types of difference schemes that occur in the literature. This historical overview places the book in a proper perspective. Chapter 2 deals with BVPs for systems of first-order nonlinear ODEs on a finite interval. The existence of two-point EDS on an arbitrary non-equidistant grid is shown and its structure is described. These EDS are the basis for the construction of two-point TDS with an order of accuracy which can be given by the user. For the computation of the coefficients of these schemes (which represent systems of nonlinear equations) the well-known IVP-solvers (see e.g. [31, 8]) are used. Its accuracy defines the accuracy of the TDS. Two a posteriori error estimators (which are based on the Runge principle and on embedded IVP-solvers) are proposed along with appropriate grid generators. Some numerical examples confirming the theoretical results are given. Chapter 3 is devoted to BVPs for second-order nonlinear ODEs with a monotone operator. The appropriate EDS and TDS are constructed, theoretically analyzed and practically tested. In Chapter 4 the results of Chapter 3 are generalized to BVPs for systems of second-order nonlinear ODEs with monotone operators. The developed algorithms have been tested on a variety of numerical examples. The corresponding results indicate a good conformity with the theoretical predictions. Chapter 5 gives some results on EDS and TDS for BVPs on the half-axis. These techniques are a real alternative to those methods which are based on transformation of the original problems into a singular BVP on a finite interval, and the subsequent solution of this singular problem by various special approaches. The results of some numerical examples are presented. The knowledge gained with this book can be checked in Chapter 6 where 32 exercises and the corresponding solutions are given. Some Fortran codes of the numerical methods presented in this book can be obtained from the authors. Acknowledgment. The authors thank Dr. Dieter Kaiser for interesting comments and suggestions. Many thanks also to Ivo Hedtke for his assistence concerning
Preface the preparation in LATEX. We gratefully acknowledge the financial support provided by the German Research Foundation (DFG) for our joint research projects. Our thanks also go to all persons and institutions of the Friedrich Schiller University at Jena that have supported the stays of our colleagues from the Ukraine. We especially wish to thank our wives for tolerating the (many) years of effort that have gone into writing of this book. It has been a pleasure working with the Birkh¨auser Basel publication staff, in particular Dr. Barbara Hellriegel.
May 2011,
IPG, MH, MVK and MLM
xi
1
Chapter 1
Introduction and a short historical overview He who never starts, never finishes. William Shakespeare (1564–1616) One of the important fields of application for modern computers is the numerical solution of diverse problems arising in science, engineering, industry, etc. Here, mathematical models have to be solved which describe e.g. natural phenomena, industrial processes, nonlinear vibrations, nonlinear mechanical structures or phenomena in hydrodynamics and biophysics. A lot of such mathematical models can be formulated as initial value problems (IVPs) or boundary value problems (BVPs) for systems of nonlinear ordinary differential equations (ODEs). However, it is not possible in general to determine the solution of nonlinear problems in a closed form. Therefore the exact solution must be approximated by numerical techniques. Considerable progress has been made in developing the theory and numerical analysis of IVPs and there exist many effective IVP-solvers (see e.g. [8, 31, 32, 35]). On the other hand, there are no references in current literature providing a general approach that allows the construction of difference schemes and the associated algorithms of a prescribed order of accuracy for BVPs. The development and analysis of numerical methods for nonlinear BVPs that can be used to solve new classes of problems or that are better than the existing ones remains an actual problem of numerical analysis and scientific computing. In the last decade so-called compact difference schemes of a high order of accuracy were frequently used [41]. These schemes use a stencil consisting of k + 1 grid nodes for ODEs of the order k. An important property of compact difference schemes is their low complexity, i.e. the computational costs for their solution are low. On the other hand, if the order of accuracy is high enough these difference I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_1, © Springer Basel AG 2011
1
2
Chapter 1. Introduction and a short historical overview schemes produce very accurate approximations on relatively rough grids. Finally, it was shown in [41] that the compactness of a difference scheme implies its stability. The aim of this book is to provide an overview of the theoretical and numerical state of research on compact difference schemes of a high order of accuracy (prescribed by the user) for nonlinear BVPs on finite intervals and on the half axis. Since the given problems and the corresponding difference schemes are nonlinear, our analysis uses the linearization technique, the principle of contracting maps and the theory of monotone operators. All of our new algorithms are based on compact exact difference schemes (EDS). In order to determine the coefficients and the right-hand side of an EDS at an arbitrary node of the underlying grid, some auxiliary IVPs on a small interval around this node must be solved. The existence and uniqueness of the solutions of the EDS is proven. Effective implementations of the EDS which are based on so-called compact truncated difference schemes (TDS) and on the well-studied robust IVP-solvers are developed. The convergence of the associated iteration methods (fixed point iteration, Newton’s iteration) is shown. The effectiveness of the proposed approaches is illustrated by a series of numerical examples. Note that the theory of numerical methods for IVPs is already very advanced today. A variety of reliable and effective implementations of these methods is available. They can be used to solve non-stiff as well as stiff IVPs. In this monograph the authors will show how numerical algorithms for BVPs can be constructed which have the same accuracy and performance level as the modern IVP-solver. The idea is to use an IVP-solver of the order p to obtain a difference scheme for BVPs of the same order p.
1.1
BVPs, Grids, Differences, Difference Schemes
Without loss of generality, in the following we consider [0, 1] as the basic interval. To develop a difference scheme some grid points or nodes x0 , . . . , xN have to be chosen in [0, 1] which define a grid ωh . Definition 1.1. In this text the following grids are used: • the equidistant (uniform) grid on [0, 1]: def
ω ¯ h = {xj ∈ [0, 1],
xj = j h,
j = 0, 1, . . . , N } ,
(1.1)
where h = 1/N is the constant step-size. Moreover, we introduce the following sub-grids of ω ¯h: def
j = 1, 2, . . . , N − 1} ,
ωh+ = {xj = jh,
def
j = 1, 2, . . . , N } ,
def ωh− =
j = 0, 1, . . . , N − 1} ,
ωh = {xj = jh,
def
{xj = jh,
γh = {x0 = 0,
(1.2)
xN = 1} ;
1.1. BVPs, Grids, Differences, Difference Schemes • the non-equidistant (irregular) grid on [0, 1]: ˆ¯ h def ω = {xj ∈ [0, 1],
x0 = 0, xN = 1, xj = xj−1 + hj ,
where hj > 0 is the local step-size and h1 + h2 + · · · + hN def
j = 1, . . . , N }, (1.3) = 1. In the case of
T
a non-equidistant grid we set h = (h1 , h2 , . . . , hN ) and define def
h = khk∞ = max hj 1≤j≤N
1/2 N X def or h = khk2 = h2j . j=1
The corresponding sub-grids are def ˆ ω ˆ h = {xj ∈ ω ¯h,
j = 1, 2, . . . , N − 1},
def
j = 1, 2, . . . , N },
def
j = 0, 1, . . . , N − 1};
ˆ ω ˆ h+ = {xj ∈ ω ¯h, ˆ ω ˆ h− = {xj ∈ ω ¯h,
(1.4)
• the quasi-uniform grid (N) (N ) ˆ¯ def ω = {xj = ξ(tj ) ∈ (0, 1),
j = 0, 1, . . . , N },
(1.5)
where x = ξ(t) : t ∈ [0, 1] → x ∈ [0, 1] is a function such that ξ(t) ∈ C2 [0, 1], (N ) ξ 0 (t) ≥ ε > 0 and the grid consisting of the nodes tj = i/N is equidistant with the step-size τ = i/N . Under these assumptions we have for the (N ) (N ) (N ) step-size of the grid (1.5) hi = xi − xi−1 ≈ ξ 0 (ti )/N and it holds that (N)
hi − hi−1 ≈ ξ 00 (ti )/N 2 , i.e. the difference between two neighboring stepsizes is much smaller than the step-size itself so that they are almost equal. (N ) (N) On the other hand, the quotient of two remote steps hi /hj ≈ ξ 0 (ti )/ξ 0 (tj ) might be rather large. In order to densify a quasi-uniform grid one should choose a denser t-grid or, which is the same, N should be increased. For example, if for a given function less emphasis is placed near the center of the underlying interval (0, 1) and more emphasis when x is near the boundary points 0 and 1, one can choose x = eαt − 1 (eα − 1) . Obviously, for α > 0 the x-grid is denser on the left end and for α < 0 it is denser on the right end. The step-sizes build a geometric progression with def def the quotient q = hi /hi−1 = eα/N . The quotient q˜ = h1 /hN ≈ eα can be rather large for large values of α.
Since it is only possible to work with discrete values of a function u(x) on a computer we need the concept of the discretization of u(x).
3
4
Chapter 1. Introduction and a short historical overview Definition 1.2. The discretization of a function u(x), 0 ≤ x ≤ 1, is the projection ˆ of u(x) onto the underlying grid ω ¯ h . The result is a sequence {u(xj )}N j=0 , with ˆ¯ h . A function which is only defined on a grid is called a grid function. xj ∈ ω def
To simplify the representation we use the abbreviation uj = u(xj ). If u(x) denotes the exact solution of a BVP, the aim of each numerical method is to def def determine an approximated grid function yh = y = {yj }N j=0 , with yj ≈ uj . The set of grid functions forms a linear space Hh . If a grid contains only a finite number of nodes, then the corresponding space is finite-dimensional. Its dimension is equal to the number of grid points. The development of difference schemes for BVPs is based on the approximation of the derivatives by divided differences which are defined recursively. Definition 1.3. The (backward) divided difference of first order is def
def
ux¯,j = ux¯ (xj ) =
uj − uj−1 hj
(1.6)
and the (forward) divided difference of first order (using indices) is def
def
ux,j = ux (xj ) =
uj+1 − uj . hj+1
(1.7)
A further divided difference of first order is def
uxˆ,j =
uj+1 − uj , ~j
def
~j =
hj+1 + hj . 2
(1.8)
Without the use of indices these differences can also be written in the form def
def
def
def
def
def
ux¯ = ux¯ (x) = ux = ux (x) = uxˆ = ux¯ (x) =
u(x) − u(x − h− ) , h−
h− > 0,
u(x + h+ ) − u(x) , h+
h+ > 0,
u(x + h+ ) − u(x) , ~
~=
(1.9)
h− + h+ . 2
The differences (1.6) – (1.8) are based on the 2-point stencils (xj−1 , xj ) and (xj , xj+1 ). We have the relations ux,j = ux¯,j+1 ,
ux,j =
~j uxˆ,j hj+1
which result from (1.6) – (1.8). Using the divided differences of first order we now define divided differences of second order on a 3-point stencil (xj−1 , xj , xj+1 ): 1 uj+1 − uj uj − uj−1 def 1 . (1.10) (ux,j − ux¯,j ) = − ux¯xˆ,j = ~j ~j hj+1 hj
1.1. BVPs, Grids, Differences, Difference Schemes Note, that the equidistant grid (1.1) is a special case of the non-equidistant grid (1.3) with hj ≡ h. Thus, on the equidistant grid (1.1) the divided differences take the form uj − uj−1 uj+1 − uj , ux,j = , ux¯,j = h h (1.11) 1 uj+1 − 2uj + uj−1 ux¯x,j = (ux,j − ux¯,j ) = . h h2 The other divided differences of second and higher order can be generated in the same recursive way.
There are discrete analogues of the well-known formula (uv)0 = u0 v + uv 0 for the differentiation of a product of two functions (prove it!): (uv)x¯,i = ux¯,i vi + ui−1 vx¯,i = ux¯,i vi−1 + ui vx¯,i , (uv)x,i = ux,i vi + ui+1 vx,i = ux,i vi+1 + ui vx,i ,
(1.12)
(uv)xˆ,i = uxˆ,i vi + ui+1 vxˆ,i = uxˆ,i vi+1 + ui vxˆ,i . Using the formulas (1.12) one obtains easily the partial summation formulas N −1 X
ui vxˆ,i ~i = uN vN − u0 v1 −
i=1
N X
ux¯,i vi hi ,
i=1
(1.13) N−1 X
N −1 X
i=1
i=0
ui vx¯,i hi = uN vN −1 − u0 v0 −
uxˆ,i vi ~i ,
which are the discrete analogues of the integration by parts, Z
1
uv 0 dx = uv|10 −
0
Z
1
u0 v dx.
0
Introducing the following scalar products on the space of grid function Hh which ˆ¯ h , are defined on ω def
(u, v)ωˆ h =
N −1 X
ui vi ~i ,
i=1
def
(u, v)ωˆ + =
N X
h
ui vi hi ,
(1.14)
i=1
the formulas (1.13) can be written as (u, vxˆ )ωˆ h = uN vN − u0 v1 − (ux¯ , v)ωˆ + . h
(1.15)
5
6
Chapter 1. Introduction and a short historical overview Let us consider the linear BVP L u(x) = f (x),
x ∈ (0, 1), (1.16)
l u(x) = µ(x),
x ∈ γ = {0, 1},
where L denotes a linear differential operator and l is a linear boundary operator. Assume that (1.16) is approximated by a difference scheme Lh yh (x) = ϕh (x), lh yh (x) = χh (x),
x∈ω ˆh,
(1.17)
x ∈ γh = {0, 1}.
(1.18)
Here, Lh is an appropriate difference operator and lh is a boundary difference def ˆ operator which are defined on the grid ω ˆ h ∪ γh covering the interval [0, 1], ¯h = ω and yh , ϕh , χh are grid functions. The exact solution u(x) of the BVP (1.16) does not satisfy the difference scheme (1.17), (1.18). Let uh be the projection of ˆ h . Obviously, the error zh def the solution u(x) of (1.16) onto the grid ω = yh − uh satisfies the problem Lh zh (x) = ψh (x), x ∈ ω ˆh , (1.19) lh zh (x) = νh (x), x ∈ γh , where ψh is the so-called truncation error of the discretized ODE (1.17) and νh is the truncation error of the discretized boundary condition (1.18). In the next definition the concept of consistency is introduced. Consistency is the minimum requirement that a difference scheme should fulfill. Definition 1.4. The difference scheme (1.17), (1.18) is said to be consistent of the order p if p denotes the largest positive integer such that the truncation errors satisfy kψh kωˆ h = O(hp ), kνh kγh = O(hp ), h → 0, (1.20) where k · kωˆ h and k · kγh denote appropriate grid norms. Consistency normally means that the order p ≥ 1. Another important property of a difference scheme is its stability. Definition 1.5. The difference scheme (1.17), (1.18) is stable if there exists a h0 > 0 such that for all h ≤ h0 and for arbitrary grid functions ϕh and χh problem (1.17), (1.18) possesses a unique solution and kyh kωˆ¯ h ≤ c1 kϕh kωˆ h + c2 kχh kγh , where the constants c1 , c2 do not depend on h, nor on ϕh or χh .
(1.21)
A straightforward design of difference approximations for derivatives naturally leads to consistent approximations of the underlying ODEs. However, our real objective is convergence but not consistency.
1.1. BVPs, Grids, Differences, Difference Schemes Definition 1.6. We say that the exact solution yh of the difference scheme (1.17), (1.18) converges to the exact solution u(x) of the BVP (1.16) if kzh kωˆ¯ h → 0 as ˆ¯ h = ω h → 0, where k · kωˆ¯ h denotes some grid norm on ω ˆ h ∪ γh . The difference scheme (1.17), (1.18) has the order of accuracy p if there exists an h0 > 0 such that for all h ≤ h0 it holds that kzh kωˆ¯ h = O (hp ) or kzh kωˆ¯ h ≤ c hp , where c is a constant independent of h.
The order of accuracy is also called the degree of accuracy. In the following we use both notations. The main theorem of the linear theory of difference schemes says that in the case of a stable difference scheme the order of consistency coincides with the order of accuracy, i.e. we have kyh − uh kωˆ h = O(hp ). For nonlinear problems there does not exist such a general statement. However, it is often possible to show that a nonlinear scheme is consistent and convergent. As an example for the construction of difference schemes let us consider the following nonlinear second-order BVP u00 (x) = f (x, u(x)),
x ∈ (0, 1),
u(0) = µ1 ,
u(1) = µ2 .
(1.22)
N To obtain an approximation {yj }N j=0 of the grid function {uj }j=0 of the exact solution u(x) we consider the ODE at x = xj , where xj is a node of the equidistant grid (1.1). Then we replace the second derivative u00 (xj ) on the left-hand side by the divided difference (1.11). It results in the well-known 3-point difference scheme
yj+1 − 2yj + yj−1 = f (xj , yj ), h2 y0 = µ1 ,
j = 1, 2, . . . , N − 1, (1.23)
yN = µ2 .
If the function f is sufficiently smooth, the scheme (1.23) has an order of accuracy 2, i.e. it holds that ky − ukωh = max |yj − uj | = O h2 . 1≤j≤N −1
If the accuracy of the scheme (1.23) is not sufficient for a certain application the question arises, how one can obtain a difference scheme whose order is higher than 2. There are two main approaches to answer this question. The first one is to use a difference approximation on a stencil with more than 3 points. For example, the 5-point difference scheme for the BVP (1.22), −yj+2 + 16yj+1 − 30yj + 16yj−1 − yj−2 = f (xj , yj ), (12h)2 y0 = µ1 ,
yN = µ2 ,
(1.24)
j = 1, 2, . . . , N − 1,
possesses an order of accuracy 4. This approach can be used for the construction of difference approximations of an arbitrary order. However, to enhance the order of accuracy of a scheme, the number of points used in the corresponding stencils must be increased significantly.
7
8
Chapter 1. Introduction and a short historical overview The second approach is based on the following idea. Using the Taylor expansion of the second finite difference (1.11), ux¯x,j = u00 (xj ) +
h2 (4) h4 (6) u (xj ) + u (xj ) + O(h6 ), 12 360
(1.25)
and the relation u(4) = f 00 (x, u) (see formula (1.22)), we get the difference approximation h2 yx¯x,j = f (xj , yj ) + f 00 (xj , yj ), j = 1, 2, . . . , N − 1, 12 which possesses the order of accuracy 4. Replacing the second derivative of the function f on the right-hand side by the divided difference of second order f 00 (xj , yj ) ≈
1 (f (xj+1 , yj+1 ) − 2f (xj , yj ) + f (xj−1 , yj−1 )) , h2
we obtain the well-known difference scheme of Numerov yx¯x,j =
1 [f (xj+1 , yj+1 ) + 10f (xj , yj ) + f (xj−1 , yj−1 )] , 12
y0 = µ1 ,
yN = µ2 ,
(1.26)
j = 1, 2, . . . , N − 1.
Unfortunately, the idea of the second approach cannot be extended to the construction of difference approximations of an order of accuracy higher than 4. It is still possible to replace the derivative u(6) by f (4) in formula (1.25), but there does not exist a 3-point approximation for f (4) (xj , uj ) which uses only values of the function f . Since a difference scheme for nonlinear BVPs represents a nonlinear system of algebraic equations, an iteration method is typically used to approximate its solution. The method of choice is often Newton’s method which requires at each iteration step the solution of a system of linear algebraic equations. In case of the difference scheme (1.24) the coefficient matrix of the linear system is a 5-diagonal matrix and in the case of the difference scheme (1.26) it is a tridiagonal matrix. The solution of a system of linear equations with a tridiagonal coefficient matrix by an elimination method requires 8N + 1 flops, whereas the solution of a system with a 5-diagonal coefficient matrix requires 19N − 10 flops. Thus, for the 3-point difference scheme (1.26) the amount of work is significantly lower than for the 5-point scheme (1.24). This motivates us to introduce the following definition. Definition 1.7. A difference scheme for ODEs of the order k is called compact if it uses only k + 1 values of the grid function.
For example the schemes (1.23) and (1.26) are compact whereas the scheme (1.24) is not compact. Since the growth behavior of the solution of a BVP can be very different on various subintervals of [0, 1] the step-size should be controlled automatically. For
1.1. BVPs, Grids, Differences, Difference Schemes this, instead of the grid (1.1), the non-equidistant grid (1.3) or a quasi-uniform grid has to be used and the corresponding difference approximations must be constructed on this grid. It can be proved that the 3-point difference scheme on the grid (1.3) yx¯xˆ,j = f (xj , yj ),
j = 1, 2, . . . , N − 1,
y0 = µ1 ,
yN = µ2 ,
where yx¯xˆ,j is defined in (1.10), has only the order of accuracy 1. This simple example shows that the construction of difference approximations of a high order of accuracy on non-equidistant grids is more complicated than for equidistant ones. However, compact difference schemes on non-uniform grids are of great importance for many applications. In the past there were some attempts to develop difference schemes of a high order of accuracy for special classes of BVPs. For example, in [38] a 3-point difference scheme of the order of accuracy 4 has been developed for BVPs of the form d2 u du = f (x, u), a(x) > 0, x ∈ (0, 1), a(x) 2 + b(x) dx dx u(0) = µ1 ,
u(1) = µ2 .
However, the theoretical foundation of this difference scheme is only given for the case a(x) = const > 0 and b(x) = const. For the BVP (1.22) a 3-point difference scheme of the order of accuracy 6 has been presented in [53]. But the approaches used in [38] and [53] can not be extended to general BVPs. Moreover, a disadvantage of these schemes is the use of an equidistant grid. Real progress in the direction of difference schemes for rather general BVPs whose order of accuracy can be prescribed arbitrarily has been achieved with the papers [26, 27, 42, 43, 55, 58, 59]. Here, the concept of an exact difference scheme plays an important role. Definition 1.8. A difference scheme is called exact if its solution {yj }N j=0 coincides with the grid function of the exact solution u(x) of the given BVP, i.e., yj = uj = u(xj ).
Let us construct the exact difference scheme for the BVP u00 (x) = f (x),
x ∈ (0, 1), (1.27)
u(0) = µ1 ,
u(1) = µ2 .
ˆ¯ h . As can be easily For the discretization of (1.27) we use a non-equidistant grid ω seen, the solution of the BVP (1.27) coincides with the solution of the sequence of BVPs u00 (x) = f (x), x ∈ (xj−1 , xj+1 ), (1.28) u(xj−1 ) = uj−1 , u(xj+1 ) = uj+1 , j = 1, 2, . . . , N − 1.
9
10
Chapter 1. Introduction and a short historical overview The solution of (1.28) can be represented in the form Z xj+1 x − xj−1 xj+1 − x u(x) = − Gj (x, ξ)f (ξ)dξ + uj+1 + uj−1 , x − x x j+1 j−1 j+1 − xj−1 xj−1 (1.29) x ∈ [xj−1 , xj+1 ] , where
(x − xj−1 )(xj+1 − ξ) , xj+1 − xj−1 Gj (x, ξ) = (xj+1 − x)(ξ − xj−1 ) , xj+1 − xj−1
xj−1 ≤ x ≤ ξ, (1.30) ξ ≤ x ≤ xj+1 ,
is Green’s function for the BVP (1.28). Substituting x = xj into (1.29) we get the difference equation Z xj+1 Z hj hj+1 xj (xj+1 − ξ) f (ξ)dξ − (ξ − xj−1 ) f (ξ)dξ uj = − 2~j xj 2~j xj−1 (1.31) hj+1 hj uj+1 + uj−1 , j = 1, 2, . . . , N − 1. + 2~j 2~j If this equation is multiplied by the factor −2/(hj+1 hj ), the following difference scheme on the 3-point stencil (xj−1 , xj , xj+1 ) results: Z xj+1 Z xj 1 1 ux¯xˆ,j = − (xj+1 − ξ) f (ξ)dξ − (ξ − xj−1 ) f (ξ)dξ, ~j hj+1 xj ~j hj xj−1 j = 1, 2, . . . , N − 1. (1.32) Thus, the difference scheme Z xj+1 Z xj 1 1 yx¯xˆ,j = − (xj+1 − ξ) f (ξ)dξ − (ξ − xj−1 ) f (ξ)dξ, ~j hj+1 xj ~j hj xj−1 (1.33) y0 = µ1 , yN = µ2 , j = 1, 2, . . . , N − 1, is the exact difference scheme for the linear BVP (1.27). In the nonlinear case an exact difference scheme represents a system of nonlinear algebraic equations containing nonlinear expressions (functionals) of the problem data. In general, these expressions cannot be evaluated directly, but as we will see later, they can be defined by the solutions of some associated IVPs. Therefore, the exact difference schemes provide the basis for the development of so-called truncated difference schemes of an arbitrary (given by the user) order of accuracy. Definition 1.9. If in an exact difference scheme the parameters determined by nonlinear expressions (e.g., IVPs or nonlinear equations) are numerically approximated, a so-called truncated difference scheme results. The accuracy of a truncated difference scheme depends on how accurately these parameters are approximated.
1.1. BVPs, Grids, Differences, Difference Schemes To illustrate the idea of EDS and TDS let us consider the simple BVP d du k(x) − q(x)u(x) = −f (x, u), x ∈ (0, 1), dx dx (1.34) u(0) = µ1 ,
u(1) = µ2 .
ˆ h (see formula (1.3). On the interval [0, 1] we introduce a non-equidistant grid ω We look for a difference scheme on this grid which has a similar form as the BVP (1.34), namely ˆ h, a(x)yx xˆ − b(x)y(x) = −ϕ(x, y), x ∈ ω (1.35) y0 = µ1 , yN = µ2 , ˆ h the coefficients a(x), b(x) and ϕ(x, y) are some functionals where for each x ∈ ω of the input data of problem (1.34). The special form of (1.35) allows us to study the difference scheme with similar well-developed analytical techniques as for the BVP (1.34). Thus, the scheme (1.35) can be carefully analyzed. Our approach consists of three basic steps: • For the given BVP (1.34) determine the coefficients a(x), b(x) and ϕ(x, y), ˆ h , (in general, in closed form) and define the EDS; x∈ω • Approximate a, b and ϕ numerically and generate the corresponding TDS; • Solve the resulting TDS, i.e. solve the nonlinear system of algebraic equations (1.35). ˆ h the coefficients a(x), b(x) and ϕ(x, y) are determined We show that for each x ∈ ω by the solutions of some IVPs for the homogeneous and the inhomogeneous ODE (1.34) on small subintervals (xi−1 , xi+1 ). Therefore the coefficients of the TDS can be efficiently computed by an IVP-solver. Moreover, we show that the accuracy of the solution of (1.35) is determined by the accuracy of the corresponding IVP-solvers for the IVPs. Definition 1.10. To improve clarity of presentation, throughout the text we will use the following abbreviations: def
e¯jα = [xj−2+α , xj−1+α ], def
γ = j − 1 + α,
def
e¯j = [xj−1 , xj ],
def
e¯N 2 = [xN , ∞),
def
β = j + (−1)α .
The corresponding open intervals are denoted by ejα , ej and eN 2 , respectively. To become familiar with these abbreviations we will alert the reader at the corresponding passages of the text.
11
12
Chapter 1. Introduction and a short historical overview To construct and to analyze the compact difference schemes we use two main approaches: The theory of contractive mappings (Fixed Point Theorem) and the theory of monotone operators. In contrast to the first approach, the theory of monotone operators allows us to develop a strategy for the study of nonlinear problems with large Lipschitz constants. Let us give here a short outline of the theoretical results which will be used frequently in this book. Theorem 1.1 (Banach’s Fixed-Point Theorem) Let X be a Banach space, M a closed nonempty set in X and F : M ⊂ X → X. Suppose that: 1) M is mapped into itself by F , i.e., F : M ⊂ X → M , and 2) the operator F is q-contractive, i.e., kF (x) − F (y)k ≤ q kx − yk
(1.36)
for all x, y ∈ M and for a fixed q, 0 ≤ q < 1. Then we can conclude the following: • Existence and uniqueness: Equation x = F (x), x ∈ M , has exactly one solution x∗ , i.e., F has exactly one fixed point on M ; • Convergence of the iteration: For an arbitrary choice of the initial point x(0) ∈ M , the sequence {x(k) } constructed by x(k+1) = F (x(k) ),
k = 0, 1, . . . ,
(1.37)
converges to the unique solution x∗ of the equation x = F (x), x ∈ M ; • Error estimates: For all k = 0, 1, . . . we have the so-called a priori error estimate qn kx(1) − x(0) k, kx(k) − x∗ k ≤ 1−q and the so-called a posteriori error estimate kx(k+1) − x∗ k ≤
q kx(k+1) − x(k) k; 1−q
• Rate of convergence: For all k = 0, 1, . . . we have kx(k+1) − x∗ k ≤ q kx(k) − x∗ k.
Proof. See e.g. [86, p.17].
Banach’s Fixed Point Theorem can be modified as follows. Assume that the
1.1. BVPs, Grids, Differences, Difference Schemes nonlinear operator F maps a closed set M ⊂ X into itself. In that case, for each natural number n the n-th power of the operator F can be defined as follows. Let def us set F 2 (x) = F (F (x)) for all x ∈ M . Then, higher powers F n (x) are defined recursively by F n (x) = F (F n−1 (x)). We now have the following result. Theorem 1.2 Let X be a Banach space, M a closed nonempty set in X and F : M ⊂ X → X. Suppose that: 1) M is mapped into itself by F , i.e., F : M ⊂ X → M , and 2) for some natural number n the operator F n is q-contractive on M . Then, the sequence (1.37) converges to x∗ for each given x(0) ∈ M .
Proof. See e.g. [82, p.392–393].
It is well known that the theory of contractive operators provides a simple framework to prove the existence and uniqueness of solutions for IVPs and BVPs of ODEs as well as for systems of nonlinear difference equations. Another approach to prove the existence and uniqueness of (weak) solutions for BVPs of nonlinear ODEs is the theory of monotone operators. The central statement is formulated in the theorem of Browder and Minty. Theorem 1.3 (Browder-Minty Theorem) Let X be a reflexive Banach space and F an operator defined on X with values in the dual space X ∗ . Suppose that the following conditions are satisfied: 1) F is a bounded operator, i.e., the image of any bounded subset of X is a bounded subset of X ∗ ; 2) the operator F is demicontinuous, i.e., for arbitrary x∗ ∈ X and any sequence {xk }∞ k=1 of elements of the space X such that xk → x∗
in X
we have F (xk ) * F (x∗ )
in X ∗ ;
3) the operator is coercive, i.e., hF (x), xi = ∞; kxkX kxkX →∞ lim
13
14
Chapter 1. Introduction and a short historical overview 4) the operator F is monotone on X, i.e., for all x, y ∈ X we have hF (x) − F (y), x − yi ≥ 0.
(1.38)
Then the equation F (x) = f
(1.39) ∗
has at least one solution x ∈ X for every f ∈ X . If, moreover, inequality (1.38) is strict for all x, y ∈ X, x 6= y, then equation (1.39) has precisely one solution x ∈ X for every f ∈ X ∗ .
Proof. See e.g. [18].
Many statements about the existence of solutions are based on the assumption that the corresponding operator F is strongly monotone. Definition 1.11. An operator F : X → X ∗ where X is a Banach space is said to be strongly monotone if there exists a constant c > 0 such that hF (x) − F (y), x − yi ≥ ckx − yk2 .
If the operator F : X → X ∗ is strongly monotone, then F is coercive. In many applications the space Rn plays an important role. This particularly applies to the discretization of ODEs. Theorem 1.4 Let F : Rn → Rn be continuous everywhere in Rn . Suppose that (F (x) − F (y), x − y) ≥ ckx − yk2
for all x, y ∈ Rn .
Then the equation F (x) = 0 has a unique solution x∗ ∈ Rn . Proof. See e.g. [82, p.461–462].
The existence and uniqueness of solutions of IVPs for ODEs is often shown with the following three theorems. Theorem 1.5 ¨ f’s Theorem) (Picard-Lindelo Suppose that 1) f (x, u), u(x) ∈ Rn ; 2) f (x, u) is continuous on the parallelepiped def
S = {(x, u) ∈ R × Rn : x : 0 ≤ x ≤ x0 + a, ku − u0 k ≤ b} and uniformly Lipschitz-continuous w.r.t. u;
(1.40)
1.1. BVPs, Grids, Differences, Difference Schemes 3) kf (x, u)k ≤ M on S. Then, the IVP u0 (x) = f (x, u(x)),
u(x0 ) = u0
(1.41) def
has a unique solution on the interval [x0 , x0 + α], where α = min(a, b/M ).
Proof. See e.g. [10]. Theorem 1.6 (Peano’s Theorem) Suppose that 1) f (x, u), u(x) ∈ Rn ; 2) f (x, u) is continuous on S; 3) kf (x, u)k ≤ M on S. Then, the IVP (1.41) has a solution on the interval [x0 , x0 + α].
Proof. See e.g. [10]. Definition 1.12. (Carath´ eodory conditions; see e.g. [9]) def
Let G ⊂ Rn be an open set and J = [a, b] ⊂ R, where a < b. One says that f : J × G → Rm satisfies the Carath´eodory conditions on J × G, written as f ∈ Car(J × G), if 1) f (·, x) : J → Rm is measurable for every x ∈ G, 2) f (t, ·) : G → Rm is continuous for almost every t ∈ J, and 3) for each compact set K ⊂ G the function def
hK (t) = sup{kf (t, x)k : x ∈ K} is Lebesgue integrable on J, where k · k is the norm on Rm .
Definition 1.13. (Solution in the extended sense; see e.g. [10]) A function u(x) is called a solution in the extended sense of the IVP (1.41) if u is absolutely continuous, u satisfies the ODE almost everywhere and u satisfies the initial condition. The absolute continuity of u implies that its derivative exists almost everywhere.
15
16
Chapter 1. Introduction and a short historical overview Theorem 1.7 (Carath´ eodory’s Theorem) If the function f (x, u) satisfies the Carath´eodory conditions (see Definition 1.12), then the IVP (1.41) has a solution in the extended sense in a neighbourhood of the initial condition.
Proof. See e.g. [10]. We want to conclude this section with two important inequalities. Theorem 1.8 (Cauchy-Bunyakovsky-Schwarz inequality) Let E be an inner product space and x, y ∈ E. Then |(x, y)|2 ≤ (x, x) · (y, y)
(1.42)
where (·, ·) is the inner product. Equivalently, by taking the square root on both sides, and referring to the norms of the vectors, the inequality is written as |(x, y)| ≤ kxk · kyk.
(1.43)
If x1 , . . . , xn ∈ C and y1 , . . . , yn ∈ C are any complex numbers, the inequality may be restated as 2 n n n X X X 2 ≤ x y |x | |yk |2 . i i j i=1
j=1
k=1
Proof. See e.g. [76, p.10–11]. Theorem 1.9
(Minkowski’s inequality) For all 1 < p < ∞ and all functions f , g on an interval [a, b] for which the integrals Z b Z b Z b |f (x)|p dx and |g(x)|p dx exist, then the integral |f (x) + g(x)|p dx exists a
a
a
too, and the Minkowski’s integral inequality states that Z
b
|f (x) + g(x)|p dx
1/p
Z ≤
a
b
|f (x)|p dx
1/p
Z +
a
b
|g(x)|p dx
1/p . (1.44)
a
Similarly, if p > 1 and ak , bk > 0, then Minkowski’s sum inequality states that X n k=1
|ak + bk |p
1/p ≤
X n k=1
|ak |p
1/p +
X n
|bk |p
1/p .
k=1
Equality holds iff the sequences a1 , a2 , . . . and b1 , b2 , . . . are proportional.
(1.45)
1.2. Short history
Proof. See e.g. [15, p.11].
1.2
Short history
To gain a better understanding of the approach used in this book, we present in this section a short overview of the history of EDS and TDS. A first general approach to exact difference schemes for linear BVPs has been developed by A. N. Tikhonov and A. A. Samarskii in the early 1960s. In the papers [80, 81] dealing with linear second-order ODEs with piece-wise continuous coefficients they have developed a theory of the exact 3-point (compact) difference schemes. In [80] an exact 3-point difference scheme (EDS) is proposed for the BVP du def d L(k,q) u = k(x) − q(x)u = −f (x), 0 < x < 1, dx dx (1.46) u(0) = µ1 ,
u(1) = µ2 ,
where 0 < c1 ≤ k(x),
k(x), q(x), f (x) ∈ Q(0) [0, 1],
q(x) ≥ 0,
(1.47)
and Q(0) [0, 1] is the class of piece-wise continuous functions with a finite number of discontinuity points of first kind. Moreover, an algorithm is given that uses truncated 3-point difference schemes (TDS) of rank m for the implementation of the exact difference scheme. For an arbitrarily given m the resulting method has the same order of accuracy. These results have been generalized in [81] for a non-equidistant grid and boundary conditions of the third kind. The idea of this approach is the following: we use the non-equidistant grid (1.4,a) and assume that the set ρ of discontinuity points of k(x), q(x) and f (x) is a subset of this grid: ρ⊆ω ˆ h . The exact solution of the BVP (1.46) satisfies the following continuity conditions at these discontinuity points: du du = k(x) , xi ∈ ρ. (1.48) u(xi − 0) = u(xi + 0), k(x) dx x=xi −0 dx x=xi +0 We introduce the stencil functions vαj (x), α = 1, 2, as those solutions of the IVPs [81] L(k,q) vαj (x) = 0, vαj (xβ ) = 0,
xj−1 < x < xj+1 , dvj k(x) α = (−1)α+1 , dx x=xβ
α = 1, 2,
j = 1, 2, . . . , N − 1,
(1.49) which satisfy the continuity conditions (1.48), too. For the definition of the index β see Definition 1.10. These stencil functions possess the following properties:
17
18
Chapter 1. Introduction and a short historical overview 1) v1j (x) > 0 is monotonically increasing on (xj−1 , xj+1 ], and the function v2j (x) > 0 is monotonically decreasing on [xj−1 , xj+1 ); 2) it holds that v1j (xj+1 ) = v2j (xj−1 ),
v2j (xj ) = v1j+1 (xj+1 );
3) the relation v1j (xj+1 ) = v1j (xj ) + v2j (xj ) Z xj Z + v2j (xj ) v1j (x)q(x)dx + v1j (xj ) xj−1
xj+1
v2j (x)q(x)dx
(1.50)
xj
is satisfied. The solution of problem (1.46) can be represented in the form u(x) = Aj v1j (x) + Bj v2j (x) + v3j (x),
xj−1 ≤ x ≤ xj+1 ,
(1.51)
where Aj , Bj are constants and v3j (x) is a particular solution of (1.46) which satisfies L(k,q) v3j (x) = −f (x), xj−1 < x < xj+1 , (1.52) v3j (xj−1 ) = v3j (xj+1 ) = 0. Setting in (1.51) x = xj+1 as well as x = xj−1 , we find Aj =
u(xj+1 )
and Bj =
v1j (xj+1 )
u(xj−1 ) v2j (xj−1 )
,
(1.53)
respectively. The function v3j (x) can be written as v3j (x) =
Z
xj+1
G(x, ξ)f (ξ)dξ,
xj−1 ≤ x ≤ xj+1 ,
(1.54)
xj−1
where G(x, ξ) is Green’s function of problem (1.52) defined by G(x, ξ) =
(
1 v1j (xj+1 )
v1j (x)v2j (ξ),
xj−1 ≤ x ≤ ξ,
v1j (ξ)v2j (x),
ξ ≤ x ≤ xj+1 .
(1.55)
Substituting (1.55) into (1.54) and setting x = xj we obtain v3j (xj )
=
1 v1j (xj+1 )
" v2j (xj )
Z
xj
xj−1
v1j (ξ)f (ξ)dξ
+
v1j (xj )
Z
xj+1
# v2j (ξ)f (ξ)dξ
.
xj
(1.56)
1.2. Short history Using (1.53), (1.50) and (1.56) we obtain from (1.51) the EDS (a ux¯ )xˆ − b u = −ϕ(x),
x∈ω ˆh, (1.57)
u(0) = µ1 ,
u(1) = µ2 ,
where −1 1 j a(xj ) = v (xj ) , hj 1 h i−1 Z def Tˆ xj (w) = ~j v1j (xj ) def
def b(xj ) = Tˆxj (q), xj
def ϕ(xj ) = Tˆ xj (f ),
h i−1 Z v1j (ξ)w(ξ)dξ + ~j v2j (xj )
xj−1
xj+1
v2j (ξ)w(ξ)dξ.
xj
(1.58) This EDS cannot be used directly because we still need an algorithm to compute its coefficients. For this aim we introduce at the point x = xj a local coordinate system by choosing x = xj + ~j (s − ∆j ),
def
∆j =
hj − hj+1 hj − hj+1 = , hj+1 + hj 2~j
−1 ≤ s ≤ 1.
Thus x = x ¯j + ~j s, with x ¯j = xj − ~j ∆j . The interval [xj−1 , xj+1 ] is transformed into the reference interval −1 ≤ s ≤ 1, where the point x = xj corresponds to the value s = ∆j . We set def
v1j (x) = v1j (xj + ~j (s − ∆j )) = ~j αj (s, ~j ), (1.59) def
v2j (x) = v2j (xj + ~j (s − ∆j )) = ~j β j (s, ~j ),
−1 ≤ s ≤ 1.
The stencil functions αj (s, ~j ) and β j (s, ~j ) satisfy the equations dαj ¯ k(s) − ~2j q¯(s)αj = 0, −1 < s < 1, ds j ¯ dα = 1, αj (−1, ~j ) = 0, k(s) ds s=−1 d ¯ dβ j k(s) − ~2j q¯(s)β j = 0, −1 < s < 1, ds ds dβ j j ¯ = −1, β (1, ~j ) = 0, k(s) ds s=1 d ds
where def ¯ = k(xj + ~j (s − ∆j )), k(s)
def
q¯(s) = q(xj + ~j (s − ∆j )).
The coefficients a, b and ϕ used in the exact difference scheme (1.57) are now given
19
20
Chapter 1. Introduction and a short historical overview by
~j j a(xj ) = α (0, ~j ) hj 1 b(xj ) = j α (0, ~j )
Z
1 ϕ(xj ) = j α (0, ~j )
Z
−1 ,
∆j
−1 ∆j
1
1 α (s, ~j )¯ q (s)ds + j β (0, ~j )
Z
1 β j (0, ~j )
Z
j
α (s, ~j )f¯(s)ds + j
−1
β j (s, ~j )¯ q (s)ds,
(1.60)
∆j 1
β j (s, ~j )f¯(s)ds. ∆j
If q(x) 6= 0 the stencil functions (1.59) cannot be determined explicitly by integration. But due to the analyticity of αj (s, ~j ) and β j (s, ~j ) with respect to ~2j , we can represent these functions by the power series αj (s, ~j ) =
∞ X
αij (s)~2i j ,
β j (s, ~j ) =
i=0
∞ X
βij (s)~2i j ,
(1.61)
i=0
with αij (s) and βij (s) defined by the recurrence formulas αij (s) βij (s)
Z
s
Z
1 ¯ k(t)
Z
= −1
Z
1
= s
αj0 (s)
1 ¯ k(t)
Z
s
= −1
t −1
q¯(λ)αji−1 (λ)dλ
1 j q¯(λ)βi−1 (λ)dλ
dt,
i = 1, 2, . . . ,
dt,
i = 1, 2, . . . ,
t
1 dt, ¯ k(t)
β0j (s)
1
Z = s
1 dt. ¯ k(t)
Let def
α(m)j (s, ~j ) =
m X
αij (s)~2i j ,
def
β (m)j (s, ~j ) =
i=0
m X
βij (s)~2i j
i=0
be the truncated sums of the series (1.61). Replacing in formula (1.60) αj (s, ~j ) and β j (s, ~j ) by α(m)j (s, ~j ) and β (m)j (s, ~j ), respectively, we obtain coefficients a(m) , b(m) and ϕ(m) which are used in the following truncated difference scheme of rank m (abbreviated as m-TDS)
(m)
a(m) yx¯
− b(m) y (m) = −ϕ(m) (x),
x ˆ
y (m) (0) = µ1 ,
x∈ω ˆh, (1.62)
y (m) (1) = µ2 .
The next statement was proved in [81] and represents a convergence result for the above m-TDS.
1.2. Short history Theorem 1.10 Let k(x), q(x) and f (x) belong to the class Q(0) [0, 1] and assume that 0 < C1 ≤ Then, the m-TDS (1.62) has the
def
(m)
− u = max
y 0,∞,ˆ ωh
hj+1 ≤ C2 . hj
order of accuracy 2m + 2, i.e. it holds that (m) (1.63) yj − uj ≤ M h2m+2 , h ≤ h0 ,
1≤j≤N−1
where C1 , C2 , M and h0 are positive coefficients which do not depend on m and the grid. If we want to solve a BVP with boundary conditions of second or third kind we need the exact and truncated difference equations which correspond to these boundary conditions. Let us consider the following BVP with boundary conditions of third kind L(k,q) u = −f (x), 0 < x < 1, (1.64) du k(x) − σ1 u(0) = −µ1 , u(1) = µ2 . dx x=0 ˆ¯ h (see formula For the discretization of (1.64) we use the non-equidistant grid ω (1.3)). At first, let us find an algebraic boundary condition (in the following referred to as difference boundary condition) at x = 0 that any solution of problem (1.64) satisfies. According to the superposition principle the exact solution of the ODE (1.64,a) can be represented on an interval [0, x1 ] in the form u(x) =
v 0 (x) v20 (x) u0 + 01 u1 + v3∗ (x), 0 v2 (0) v1 (x1 )
where v10 (x), v20 (x) and v3∗ (x) are the solutions of the problems dv10 (k,q) 0 0 v1 (x) = 0, 0 < x < x1 , v1 (0) = 0, k(x) = 1, L dx x=0 dv20 (k,q) 0 0 v2 (x) = 0, 0 < x < x1 , v2 (x1 ) = 0, k(x) = −1, L dx x=x1 L(k,q) v3∗ (x) = −f (x),
0 < x < x1 ,
v3∗ (0) = v3∗ (x1 ) = 0.
(1.65)
(1.66)
(1.67) (1.68)
Let us demand that the function u(x) in (1.65) satisfies also the left boundary condition in (1.64,b), i.e., du k(x) − σ1 u(0) = −µ1 . (1.69) dx x=0
21
22
Chapter 1. Introduction and a short historical overview Substituting (1.65) into (1.69) and taking into account that v20 (0) = v10 (x1 ), we obtain the exact difference boundary condition ¯1 u0 = −¯ µ1 , a1 ux¯,1 − σ
(1.70)
with
def
a1 = a(x1 ) = Z
1 0 v (0) h1 2
−1 , (1.71)
x1
σ ¯1 = h1 a1
q(x)v20 (x)dx + σ1 ,
0
dv3∗ µ ¯1 = µ1 + k(x) . dx x=0
Therefore, the EDS for problem (1.64) takes the form (a ux¯ )xˆ − b u = −ϕ(x),
x∈ω ˆh, (1.72)
¯1 u0 = −¯ µ1 , a1 ux¯,1 − σ
uN = µ2 ,
where a(xj ), b(xj ), ϕ(xj ) are defined by formulas (1.58), and σ ¯1 , µ ¯1 by formula (1.71). To develop a TDS we introduce the local coordinate s = x/h1 at x = 0, i.e. we have x = sh1 , 0 ≤ s ≤ 1. We change the dependent variable by v20 (x) = v20 (sh1 ) = h1 β 0 (s, h1 ),
v3∗ (x) = v3∗ (sh1 ) = h1 γ 0 (s, h1 ).
The stencil functions β 0 (s, h1 ) and γ 0 (s, h1 ) satisfy the equations d ds
0
¯ dβ k(s) ds
β 0 (1, h1 ) = 0, d ds
0
¯ dγ k(s) ds
β 0 (1, h1 ) = 0,
− h21 q¯(s)β 0 = 0,
0 < s < 1,
0 ¯ dβ k(s) = −1, ds s=1 − h21 q¯(s)β 0 = h21 f (s),
0 < s < 1,
0 ¯ dβ (s, h1 ) k(s) = −1, ds s=−1
where def ¯ k(s) = k(sh1 ),
def
q¯(s) = q(sh1 ),
def f¯(s) = f (sh1 ).
The coefficients of the exact difference boundary condition of third kind take now the form −1 Z 1 0 1 0 ¯ dγ q¯(s)β 0 (s, h1 )ds, µ ¯1 = µ1 + h1 k(s) , a = v (0) . σ ¯ 1 = a1 1 ds s=0 h1 2 0
1.2. Short history Replacing the functions β 0 (s, h1 ) and γ 0 (s, h1 ) by the polynomials β (m)0 (s, h1 ) =
m X
βi0 (s)h2i 1 ,
γ (m)0 (s, h1 ) =
i=0
m X
γi0 (s)h2i 1 ,
i=0
we obtain the truncated boundary condition of rank m, (m) (m)
(m) (m) y0
¯1 a1 yx¯,1 − σ
(m)
= −¯ µ1 .
In [81] it is shown that the solution of the m-TDS (m) − b(m) y (m) = −ϕ(m) (x), a(m) yx¯ x ˆ
(m) (m) a1 yx¯,1
−
x∈ω ˆh, (1.73)
(m) (m) σ ¯ 1 y0
=
(m) −¯ µ1 ,
(m) yN
= µ2
possesses the order of accuracy 2m + 2. An analogous approach for the construction of EDS and TDS for the generalized BVP of third kind with minimal requirements on the smoothness of the coefficient was used in [23]. The papers [21, 22] deal with EDS and TDS for a class of variational inequalities as well as with the development of efficient algorithms for their implementation. The TDS enable the computation of approximations of the exact solution with an order of accuracy which can be prescribed by the user for arbitrary piece-wise continuous coefficients k(x), q(x) and f (x). The practical implementation of TDS of a higher order of accuracy obtained within this approach requires in the case of non-polynomial coefficients in the equation (1.46) the computation of multidimensional integrals. This can be done, for example, with Monte-Carlo methods but represents, in fact, a serious computational problem. In order to overcome this drawback another efficient algorithmic approach for the construction of TDS of an arbitrarily given order of accuracy for problem (1.46), (1.47) with piece-wise smooth coefficients k(x), q(x), f (x) was proposed in [60, 73]. The EDS from [80, 81] was the basis of this approach too. It was shown that at each node xj of a non-equidistant grid ω ˆ h the coefficients a(x), b(x) and the right-hand side ϕ(x) can be represented by the solutions of four auxiliary IVPs on the (small!) subinterval (xj−1 , xj+1 ). From (1.58) we obtain immediately the following representations for a(x) and b(x): a(xj ) =
1 j v (xj ) hj 1
−1 ,
b(xj ) = ~−1 j
2 X
[vαj (xj )]−1 [(−1)α+1 mjα (xj ) − 1], (1.74)
α=1
where
dvαj (x) , α = 1, 2. dx In order to obtain the representation for ϕ(x), two auxiliary functions wαj (x), α = 1, 2, were introduced as the solutions of the IVPs def
mjα (x) = k(x)
23
24
Chapter 1. Introduction and a short historical overview L(k,q) wαj (x) = −f (x), xj−2+α < x < xj−1+α , dwαj j wα (xj+(−1)α ) = = 0, α = 1, 2. dx x=xj+(−1)α
(1.75)
It was shown that the right-hand side ϕ(x) of the EDS can be represented in the following way: " # 2 X wαj (xj ) −1 α j j ϕ(xj ) = ~j (−1) lα (xj ) − mα (xj ) j , (1.76) vα (xj ) α=1 where
dwαj (x) , α = 1, 2. dx One can see from (1.74), (1.76) that, for the computation of the coefficients a(xj ), b(xj ) and the right-hand side ϕ(xj ) of the EDS, the four IVPs have to be solved for each xj ∈ ω ˆ h : (1.117), (1.75) with α = 1 on the subinterval [xj−1 , xj ] and (1.49), (1.75) with α = 2 on the subinterval [xj , xj+1 ]. These IVPs can be solved by executing only one step with an arbitrary one-step method, e.g. with the Taylor series method or a Runge-Kutta method of the order of accuracy m ¯ = 2[(m + 1)/2], where [·] denotes the entire part of the argument in these brackets. We label (m)j (m)j ¯ the thus calculated solutions with an additional index m: vα (xj ), mα (xj ), (m)j ¯ (m)j wα (xj ) and lα (xj ). Instead of the three-point EDS (1.57), (1.74), (1.76) we now have the three-point TDS lαj (x) = k(x)
(m)
(a(m) yx¯ )xˆ − b(m) y (m) = −ϕ(m) (x), y (m) (0) = µ1 ,
x∈ω ˆh, (1.77)
y (m) (1) = µ2 ,
where the coefficients are given by a(m) (xj ) =
1 (m)j v (xj ) hj 1
b(m) (xj ) = ~−1 j
2 X
−1 ,
¯ (−1)α+1 [vα(m)j (xj )]−1 [m(αm)j (xj ) + (−1)α ],
(1.78)
α=1
(m)
ϕ
(xj ) =
~−1 j
2 X α=1
" (−1)
α
(m)j lα (xj )
−
(m)j ¯ wα (xj ) ¯ m(αm)j (xj ) (m)j vα (xj )
# .
The next statement characterizes the order of accuracy of this scheme (see e.g. [73]). Theorem 1.11 Let k(x) ∈ Q(m+1) [0, 1], q(x), f(x) ∈ Q(m) [0, 1], and suppose that the homogeneous BVP (1.46), (1.47) and (1.117) possesses only the trivial solution. Then
1.2. Short history the error of TDS (1.77) satisfies (
∗
(m)
− u = max y (m) − u
y 1,∞,ˆ ωh
)
dy (m) du
≤ M hm , ,
k dx − k dx 0,∞,ˆ ωh 0,∞,ˆ ωh
where h is small enough, the constant M is independent of h and dy (m) (xj ) k(xj ) = dx #−1 2 " 2 X Xn (m)j ¯ α (m)j ¯ m(αm)j (−1) vα (xj )m3−α (xj ) (xj )y (m) (xj+(−1)α ) = α=1
α=1
h io (m)j ¯ (m)j ¯ (m)j (m)j ¯ ¯ (xj ) + m(αm)j (xj )v3−α (xj )l3−α (xj ) . +(−1)α+1 m1 (xj )m2 (xj )wα(m)j
The advantage of the scheme (1.77) compared with the schemes from [19] for piece-wise smooth k(x), q(x) and f (x) is that besides an approximation for the exact solution one obtains also a three-point approximation for k(x)du/dx of the same accuracy (measured in the Chebyshev norm) without additional computational costs (in [19] an estimate for an approximation of ux¯ is given). A new approach for the construction of 3-point EDS and the corresponding TDS of an arbitrarily given order of accuracy m for nonlinear problems of the form d du k(x) = −f (x, u), dx dx
x ∈ (0, 1),
u(0) = µ1 ,
u(1) = µ2 ,
(1.79)
was published in 1990 (see [59]). These results were generalized and further developed in [45, 49]. In [42] monotone ODEs were considered. Under the assumption that the following conditions are fulfilled, 0 < c1 ≤ k(x) for all x ∈ [0, 1] , def
fu (x) = f (x, u) ∈ Q0 [0, 1], |f (x, u) − f (x, v)| ≤ L |u − v| def
q = L/c1 < 1,
k(x) ∈ Q1 [0, 1],
|f (x, u)| ≤ K
(1.80)
for all x ∈ [0, 1], u ∈ Ω([0, 1], r), (1.81)
for all x ∈ [0, 1], u, v ∈ Ω([0, 1], r),
(1.82) (1.83)
a new implementation of the three-point EDS on an arbitrary non-equidistant grid ω ˆ h using a TDS of a desired order of accuracy was introduced in [46]. Here Qp [0, 1] denotes the class of functions which are piece-wise differentiable up to the order p and possess a finite number of discontinuity points of the first kind. Ω([0, 1], r) is
25
26
Chapter 1. Introduction and a short historical overview the set Ω([0, 1], r)
du def
1 ∈ C[0, 1], u − u(0) = u(x) : u(x) ∈ W∞ (0, 1), u(x), k(x) ≤r , dx 1,∞,(0,1) (1.84) where kuk0,∞,(0,1) )
du
, = max kuk0,∞,(0,1) , dx 0,∞,(0,1) (
def
= vrai max |u(x)| ,
kuk1,∞,(0,1)
x∈(0,1)
def
r =
K def , V1 (x) = c1
x
Z 0
def
Z
dt def , V2 (x) = k(t)
1
x
dt V1 (x) def V2 (x) , u(0) (x) = µ1 + µ2 . k(t) V1 (1) V1 (1)
The three-point EDS for (1.79) is (aux¯ )xˆ = −ϕ(xj , u) x ∈ ω ˆh,
u(0) = µ1 ,
u(1) = µ2 ,
(1.85)
where −1 1 j V1 (xj ) , hj " # 2 j X −1 α j α wα (xj , u) (−1) lα (xj , u) + (−1) . ϕ(xj , u) = ~j Vαj (xj ) α=1
a(xj ) =
The functions wαj (xj , u), lαj (xj , u), α = 1, 2, are the solutions of the following IVPs on small intervals (the interval length can be controlled): lj (x, u) d j wα (x, u) = α , dx k(x)
d j l (x, u) = −f x, Yαj (x, u) , dx α
wαj (xβ , u) = lαj (xβ , u) = 0,
x ∈ ejα ,
(1.86)
α = 1, 2,
where ejα and the index β are defined in Definition 1.10, and ˆ(x) + wαj (x, u) − Yαj (x, u) = u
Vαj (x) Vαj (xj )
wαj (xj , u),
x ∈ e¯jα ,
i h i−1 h , u ˆ(x) = u(xj )V1j (x) + u(xj−1 )V2j−1 (x) · V1j (xj ) V1j (x) =
Z
x
xj−1
dt , k(t)
V2j (x) =
Z
xj+1
x
α = 1, 2,
x ∈ e¯j ,
dt . k(t)
The practical realization of the EDS (1.85) for all xj ∈ ω ˆ h (i.e. the computation of the corresponding coefficients as input data) can be achieved by the integration
1.2. Short history of the two IVPs (1.86). The first one has to be integrated forward on the interval [xj−1 , xj ] with α = 1, whereas the second one must be integrated backward on the interval [xj , xj+1 ] with α = 2. For this integration one can use an appropriate one-step method, e.g. a Runge-Kutta method of the order of accuracy m. ¯ Note that the solutions wαj (x, u) and lαj (x, u), α = 1, 2, of the IVPs (1.86) def
depend on the parameters bjα (u) = wαj (xj , u), i.e., wαj (x, u) = wαj (x, u, bjα (u)) and lαj (x, u) = lαj (x, u, bjα (u)), α = 1, 2. Substituting the numerical solutions of the order m ¯ into the EDS (1.85) yields the TDS of the rank m, ¯ (m) ¯
¯ ¯ ¯ (a(m) yx¯ )xˆ = −ϕ(m) (x, y (m) ),
a
(m) ¯
1 (m)j ¯ (xj ) = V (xj ) hj 1
¯ (xj , u) = ~−1 ϕ(m) j
2 X
x∈ω ˆh,
¯ y (m) (0) = µ1 ,
¯ y (m) (1) = µ2 ,
−1 ,
(1.87)
"
(m)j ¯
(m)j (−1)α lα (xj , u) + (−1)α
α=1
wα
(xj , u) (m)j ¯ Vα (xj )
# .
Then, the parameters in (1.87) can be written in the form (s−1)j b(s−1) = wα (xj , u) α
=−
¯ wα(m)j (xj , u) = −
s−1 (s−2) h2γ fβ X [(−1)α+1 hγ ]p dp wαj (xβ , u, bα ) + , p 2 kβ p=3 p! dx
s = 3, 4, . . . , m, ¯
m ¯ (m−1) ¯ h2γ fβ X [(−1)α+1 hγ ]p dp wαj (xβ , u, bα ) + , 2 kβ p=3 p! dxp
(m)j lα (xj , u) = (−1)α hγ fβ +
m (m−1) ¯ X [(−1)α+1 hγ ]p dp lj (xβ , u, bα ) α
p=2
dxp
p!
.
In the next theorem (see also [46]) the accuracy of the above TDS is characterized. Theorem 1.12 Let the assumptions (1.80) – (1.83) be satisfied. Suppose that k(x) ∈ Qm+2 [0, 1],
f (x, u) ∈
N [
Cm+1 e¯j × Ω([0, 1], r + ∆) .
j=1
Then there exists h0 > 0 such that for h ≤ h0 the TDS (1.87) has a unique solution. Moreover, the following estimate of the accuracy holds: ) (
∗
(m) ¯
du dy
(m)
¯ ¯
≤ M hm = max y (m) − u , ,
y ¯ − u
k dx − k dx 1,∞,ˆ ωh 0,∞,ˆ ωh 0,∞,ˆ ωh
27
28
Chapter 1. Introduction and a short historical overview where (m) ¯
k(xj )
(m)j ¯
¯ ¯ hj yx¯,j − w1 (xj, y (m) ) (xj ) dy (m) (m)j ¯ = ), + l1 (xj, y (m) ( m)j ¯ dx V1 (xj )
and the constant M does not depend on h. In the paper [47] an EDS of the type (1.87) is introduced and justified under the conditions 0 < c1 ≤ k(x) ≤ c2
k(x) ∈ Q1 [0, 1],
for all x ∈ [0, 1],
def
for all u ∈ R,
def
for all x ∈ [0, 1],
fu (x) = f (x, u) ∈ Q0 [0, 1] fx (u) = f (x, u) ∈ C(R) |f (x, u)| ≤ g(x) + c |u|
for all x ∈ [0, 1], u ∈ R,
[f (x, u) − f (x, v)] (u − v) ≤ c3 |u − v|
2
c ≥ 0,
for all x ∈ [0, 1], u, v ∈ R,
0 ≤ c3 < π 2 c1 , where g(x) ∈ L2 (0, 1), and c, c1 , c2 , c3 are constants. A drawback of the TDS of a high order of accuracy is that derivatives of the functions wαj (x, u) and lαj (x, u), α = 1, 2, have to be computed. This can be done by an analytical differentiation of the equations in (1.86), e.g. by well-known computer algebra tools like Mathematica and Maple. EDS and TDS of an arbitrarily given order of accuracy for systems of linear second order equations du (K,Q) def d K(x) − Q(x)u(x) = −f (x) (1.88) u = L dx dx under the boundary conditions u(0) = u(1) = 0
(1.89)
were proposed in [57, 58]. The authors suppose that the matrices K(x) = m m [kij (x)]m i,j=1 , Q(x) = [qij (x)]i,j=1 and the vector f (x) = {fi (x)}i=1 satisfy the conditions 2
C1 kvk ≤ (K(x)v, v), kij (x) ∈ Qn+1 [0, 1],
C1 > 0,
for all v ∈ Rm ,
qij (x) ∈ Qn [0, 1],
for all x ∈ [0, 1],
fi (x) ∈ Qn [0, 1]
(1.90) (1.91)
and that at the discontinuity points of the coefficients xi the solution of problem (1.88)–(1.91) satisfies the conditions du du u(xi − 0) = u(xi + 0), K(x) = K(x) . dx x=xi −0 dx x=xi +0
1.2. Short history In that case the EDS can be derived from the integral corollary of differential equations in the following way. Let us introduce the matrices and vectors V1j (x), V2j (x), W j1 (x) and W j2 (x) as the solutions of the following problems (compare this with the scalar case): L(K,Q) Vαj (x) = 0, Vαj (xβ ) = 0,
x ∈ (xj−1 , xj+1 ), dVαj K(x) = (−1)α+1 E, dx x=xβ
(1.92)
L(K,Q) W jα (x) = −f (x), W jα (xβ ) = 0,
x ∈ (xj−1 , xj+1 ), dW jα K(x) = 0, α = 1, 2 dx x=xβ
(1.93)
as well as the vector-function W j (x) as the solution of the inhomogeneous BVP (on a small interval) L(K,Q) W j (x) = f (x),
x ∈ (xj−1 , xj+1 ),
W j (xj−1 ) = W j (xj+1 ) = 0. Let
dVαj (x) dW jα , Ljα (x) = K(x) , α = 1, 2, dx dx be the corresponding streams. We represent the Green’s function of problem (1.88), (1.89) in the form ( j V1 (x)V˜1j (ξ), x ≤ ξ, j ξ ∈ [xj−1 , xj+1 ], G (x, ξ) = V2j (x)V˜2j (ξ), x ≥ ξ, Mαj (x) = K(x)
where V˜αj (x), α = 1, 2, are the solutions of the IVPs " # dV˜1j (x) def d (K,Q) ˜ j ˜ K(x) − V˜1j (x)Q(x) = 0, L V1 (x) = dx dx V˜1j (xj+1 ) = 0,
dV˜1j K(x) dx
x ∈ (xj−1 , xj+1 ),
h i−1 = − V1j (xj+1 ) ,
x=xj+1
(1.94) ˜ (K,Q) V˜ j (x) = 0, L 2 V˜2j (xj−1 ) = 0,
x ∈ (xj−1 , xj+1 ), h i−1 dV˜2j K(x) = V2j (xj−1 ) . dx x=xj−1
(1.95)
29
30
Chapter 1. Introduction and a short historical overview The integral corollary of the equation (1.88) implies Z xj+1 Z xj+1 (K,Q) Gj (x, ξ)Lξ u(ξ)dξ = − Gj (x, ξ)f (ξ)dξ = −W j (x). xj−1
xj−1
By integration by parts of the left-hand side we obtain h i−1 h i−1 hj+1 V1j (xj ) V1j (xj+1 ) ux,j − hj V2j (xj ) V2j (xj−1 ) ux¯,j h i−1 h i−1 uj − E − V1j (xj ) V1j (xj+1 ) − V2j (xj ) V2j (xj−1 ) = −W j (xj ). Note that the following holds: Z xj+1 W j (xj ) = Gj (xj , ξ)f (ξ)dξ xj−1
=
V1j (xj )V˜1j (xj )
( h i−1 Z V˜2j (xj )
xj
V˜2j (ξ)f (ξ)dξ
xj−1 xj+1
i−1 Z h + V˜ j (xj ) 1
) V˜1j (ξ)f (ξ)dξ
,
xj
and
h i−1 h i−1 E − V1j (xj ) V1j (xj+1 ) − V2j (xj ) V2j (xj−1 ) =
V1j (xj )V˜1j (xj )
( h i−1 Z j ˜ V2 (xj )
xj
V˜2j (ξ)Q(ξ)dξ
xj−1
i−1 Z h + V˜1j (xj )
xj+1
) V˜1j (ξ)Q(ξ)dξ
.
xj
Thus, we arrive at the 3-point EDS (see [57]) j j ~−1 ¯,j ) − Dj u(xj ) = −Φj , j (A (xj )ux,j − B (xj )ux
xj ∈ ω ˆh, (1.96)
u0 = uN = 0, where h i−1 h i−1 V1j (xj+1 ) , Aj (xj ) = hj+1 V˜1j (xj ) h i−1 h i−1 V2j (xj−1 ) , B j (xj ) = hj+1 V˜2j (xj )
Dj = Tˆ j (Q),
Φj = Tˆj (f ),
i−1 Z xj i−1 Z xj+1 1 h˜j 1 h˜j Tˆj (w) = V2 (xj ) V1 (xj ) V˜2j (ξ)w(ξ)dξ + V˜1j (ξ)w(ξ)dξ. ~j ~j xj−1 xj
1.2. Short history The existence of EDS for problem (1.88)–(1.91) has been proven in [58], but the possibility of its transformation into the form (1.96) was only shown for self-adjoint K(x), Q(x) and under the assumption Q(x) ≥ 0. Besides, in [58] (see Lemma 4 and Theorem 2) it is shown that only the conditions K(x) = K ∗ (x),
Q(x) = Q∗ (x),
K(x)K(x1 ) = K(x1 )K(x)
for all x, x1 ∈ [xj−1 , xj+1 ]
provide the scheme (1.96) in the divergence form (Aux¯ )xˆ,j − Dj u(xj ) = −Φj ,
xj ∈ ω ˆh,
u0 = uN = 0,
def with Aj = hj+1 [V˜1j∗ (ξ)]−1 .
Let us introduce the matrix-valued functions def V¯2j (x) = V1j (xj+1 )V˜1j (x),
def V¯1j (x) = V2j−1 (xj−1 )V˜2j (x)
and the derivatives dV¯2j ¯ j (x) def K(x), = M 2 dx
dV¯1j ¯ j (x) def M K(x). = 1 dx
Then (1.94) and (1.95) imply that the functions V¯2j (x), V¯1j (x) satisfy the following IVPs on the interval [xj−1 , xj+1 ]: dV¯2j (x) j (K,Q) ¯ j ˜ ¯ K(x) L = −E, V2 (x) = 0, V2 (xj+1 ) = 0, dx x=xj+1
(1.97) ˜ (K,Q) V¯ j (x) L 1
= 0,
V¯1j (xj−1 )
dV¯1j (x) K(x) dx
= 0,
= E.
x=xj−1
The coefficients Aj (xj ), B j (xj ), Dj and Φj can be represented by the solutions of the IVPs (1.92), (1.93) and (1.97) in the form h i−1 h i−1 −1 ¯ j j ¯ j (xj ) , B (x ) = h (x ) , V V Aj (xj ) = h−1 j j 1 j+1 2 j h i ¯ j −1 1 ¯j d V 2 −E − V (xj ) Dj = ~j 2 dx
K(xj + 0)
x=xj
i−1 dV¯ j 1 h¯j 1 V (xj ) + ~j 1 dx
K(xj − 0) − E ,
x=xj
Φj =
2 X α=1
n o −1 j ¯ (xj )W j (xj ) . (−1)α Ljα (xj ) − V¯αj (xj ) M α α
31
32
Chapter 1. Introduction and a short historical overview Starting from the EDS we can now introduce in analogy to the scalar case the n-TDS (n)
(n)
(n)
(n)
(n)j ~−1 (xj )y x,j − B (n)j (xj )y x¯,j ) − Dj y j = −Φj , j (A (n)
y0
xj ∈ ω ˆh,
(n)
= y N = 0,
where h i−1 def ¯ (n)j (xj ) A(n)j (xj ) = h−1 , V 2 j+1 (n)
Dj
2 i−1 h i 1 X h ¯ (n)j ¯ (n)j (xj ) , Vα (xj ) −E − (−1)α M α ~j α=1
=
2 X
(n) def
Φj
h i−1 def ¯ (n)j (xj ) B (n)j (xj ) = h−1 , V 1 j
=
h i−1 (¯ n)j (n)j (¯ n)j ¯ ¯ (−1)α L(n)j (x ) − V (x ) (x )W (x ) , M j j j j α α α α
α=1 (n)j ¯ α(¯n)j (x), W (¯n)j (x), L(n)j (x), α = 1, 2, are approximations of the and V¯α (x), M α α solutions of the IVPs (1.92), (1.93) and (1.97) obtained e.g. by the Taylor series method of the order of accuracy n ¯.
An a priori estimate for the n-TDS gives the following theorem (see [58]). Theorem 1.13 Under the assumptions (1.90) and (1.91) the following error estimate holds: ) (
∗
du dy (n)
(n) (n)
−K ≤ M hn , = max u − y , K
u − y dx dx 0,∞,ˆ ωh 1,∞,ˆ ωh 0,∞,ˆ ωh
where (n)
dy j K(xj ) dx ×
2 X
α
(−1)
( =
2 X
)−1 (−1)
α+1
Mα(¯n)j (xj )Vα(n)j (xj )
α=1
L(n)j α (xj )
−
Mα(¯n)j (xj )
h i−1 (n)j (¯ n)j (n)j Vα (xj ) W α (xj ) + L2 (xj ),
α=1
(1.98) and h is small enough. EDS as well as their implementation in the form of TDS of an arbitrarily given order of accuracy for nonlinear second-order ODEs and Dirichlet boundary conditions du du d K(x) = −f x, u, , x ∈ (0, 1), u(0) = µ1 , u(1) = µ2 , dx dx dx (1.99)
1.2. Short history with given K(x) ∈ Rn×n , f (x, u, ξ), µ1 , µ2 ∈ Rn , and unknown u(x) ∈ Rn , were proposed and studied in [28, 29, 43, 44]. Two-point EDS and two-point TDS for systems of first-order ODEs with non-separated boundary conditions u0 (x) + A(x)u = f (x, u), A(x), B0 , B1 , ∈ Rd×d ,
x ∈ (0, 1),
B0 u(0) + B1 u(1) = d,
rank[B0 , B1 ] = d,
f (x, u), d, u(x) ∈ Rd
were introduced and analyzed in [24, 27, 55]. The next step in the development of EDS and TDS was the focus on BVPs on infinite intervals. There are some strategies to solve BVPs on an infinite interval by standard numerical techniques like finite difference methods, collocation methods or shooting methods. One possibility is to replace the boundary conditions formulated at infinity by conditions at a finite boundary point. However, it is difficult to find efficient a priori error estimates for the corresponding numerical solutions (see, e.g. [11],[17]). In some cases the BVP on an infinite interval can be replaced by a BVP on a finite interval with a free boundary (point) [16]. The next idea is to change the variables of the problem and to transform the BVP on the infinite interval into a singular BVP with an essential singularity on a finite interval [4, 5, 36]. It is shown experimentally in [4, 5] that the collocation method applied to the problem with the essential singularity provides satisfactory results. A somewhat different approach is to investigate the asymptotic behavior of the solution at infinity and to use this information to formulate asymptotic boundary conditions at a finite boundary point [37, 51, 61, 62, 63, 77]. In some cases this strategy can be useful to obtain a priori estimates (see, e.g.,[51]). A quite different approach proposed in [56] is based on the three-point EDS on a finite mesh. The idea is to add an exact difference boundary condition to these difference equations and to use the resulting system as the basis for the construction of a TDS of an arbitrarily given order of accuracy. More precisely, the paper [56] deals with the BVP L(k,q) u = −f (x),
0 < x < ∞, (1.100)
u(0) = µ1 ,
lim u(x) = 0,
x→∞
under the assumptions q(x) = q02 + q˜(x), k(x) ≥ c1 > 0,
q(x) ≥ c2 > 0,
p1 (x) p2 (x) pn (x) 1 = d2 + + + ··· + + ··· , k(x) x x2 xn q(x) = q02 +
(1.101)
q1 (x) q2 (x) qn (x) + + ··· + + ··· , 2 x x xn
(1.102) x → ∞, x→∞
(1.103)
33
34
Chapter 1. Introduction and a short historical overview |pi (x)| ≤ M,
|qi (x)| ≤ M,
i = 1, 2, . . . ,
(1.104)
and
d 1 , q˜(x) ∈ L2 (0, ∞), dx k(x) where q0 , d and M are positive constants. Here, the solution of problem (1.100) is understood as a generalized solution from the class W21 (0, ∞) satisfying the corresponding variational equation. For this problem the EDS as well as the TDS have been developed on the grid ω ˆ h , where the step-sizes hj must satisfy the conditions N+1 X def hj = xN+1 → ∞, h = max hj → 0. N →∞
j=1
1≤j≤N+1
N→∞
On each interval [xj−1 , xj ], j = 1, 2, . . . , N , the three-point EDS (1.57) of the form (aux¯ )xˆ,j − b(xj )uj = −ϕ(xj ), 0 < j < N + 1, (1.105) is used. The corresponding coefficients a, b and ϕ are given by −1 −1 , a(xj+1 ) = β j (0, hj+1 ) , a(xj ) = αj (0, hj ) hj b(xj ) = ~j αj (0, hj )
Z
(1.106)
0
αj (s, hj )q ∗ (s)ds
−1
Z 1 hj+1 β j (s, hj+1 )q ∗ (s)ds, ~j β j (0, hj+1 ) 0 Z 0 hj αj (s, hj )f ∗ (s)ds ϕ(xj ) = ~j αj (0, hj ) −1 Z 1 hj+1 + β j (s, hj+1 )f ∗ (s)ds, ~j β j (0, hj+1 ) 0 +
(1.107)
(1.108)
where ∗
def
q (s) =
s<0 q(xj + shj ), , q(xj + shj+1 ), s > 0
∗
def
f (s) =
s<0 f (xj + shj ), f (xj + shj+1 ), s > 0
and αj (s, hj ), β j (s, hj+1 ) are the solutions of the IVPs d dαj k ∗ (s) − h2j q ∗ (s)αj = 0, −1 < s < 0, ds ds dαj j ∗ = 1, α (−1, hj ) = 0, k (s) ds s=−1 d dβ j ∗ k (s) − h2j+1 q ∗ (s)β j = 0, 0 < s < 1, ds ds dβ j = −1, β j (1, hj+1 ) = 0, k ∗ (s) ds s=1
1.2. Short history with
( def
∗
k (s) =
k(xj + shj ),
s<0
k(xj + shj+1 ),
s>0
.
The stencil functions αj (s, hj ), β j (s, hj+1 ) can be represented by the series (compare that with formula (1.61)) αj (s, hj ) =
∞ X
αij (s)h2i j ,
β j (s, hj+1 ) =
i=0
∞ X
βij (s)h2i j+1 ,
(1.109)
i=0
where the coefficients αij (s), βij (s) are given by the recurrence formulas Z t Z s 1 j ∗ q (λ)α (λ)dλ dt, i = 1, 2, . . . , αji (s) = i−1 ∗ −1 k (t) −1 Z 1 Z 1 1 j ∗ βij (s) = q (λ)β (λ)dλ dt, i = 1, 2, . . . , i−1 ∗ s k (t) t Z s Z 1 1 1 j j dt, β0 (s) = dt. α0 (s) = ∗ (t) ∗ (t) k k −1 s To complete the system of linear algebraic equations (1.105) we still need the exact boundary conditions at the points x0 and xN +1 . For x0 = 0, formula (1.100) yields u0 = µ1 . The following equation for the right boundary xN +1 is derived in [56] uN +1 − σ2 uN = σ3 , with def
σ2 = v˜1 (xN+1 ), v˜1 (xN+1 ) σ3 = D def
Z
xN +1
[˜ v2 (t) − v˜1 (t)]f (t)dt xN
v˜2 (xN+1 ) − v˜1 (xN +1 ) + D
Z
(1.110)
∞
[˜ v2 (t) − v˜1 (t)]f (t)dt, xN +1
def
v1 (xN +1 )˜ v20 (xN +1 ) − v˜10 (xN+1 )˜ v2 (xN+1 )), D = k(xN+1 )(˜ where the stencil functions v˜1 (x) and v˜2 (x) are the solutions of the following problems: L(k,q) v˜1 = 0, xN < x < ∞, v˜1 (xN ) = 1, L(k,q) v˜2 = 0, v˜2 (xN ) = 1,
lim v˜1 (x) = 0,
x→∞
xN < x ≤ xN+1 , d˜ v2 = 0. dx x=xN
35
36
Chapter 1. Introduction and a short historical overview def
def
Let us set s = (x − xN )/xN and µ = 1/xN . Then, it can be shown that the def
function v˜1 (x) = v˜1 (xN + sxN ) = v¯1 (s) solves the problem d¯ v1 1 = w, ¯ ds k(s) v¯1 (0) = 1,
µ2
dw − q¯(s)¯ v1 = 0, ds
lim v¯1 (s) = 0,
s→∞
def
lim w(s) = 0,
s→∞
def
¯ where k(s) = k(xN + sxN ), q¯(s) = q(xN + sxN ) and µ is the small parameter. ¯ The assumption (1.103) implies that 1/k(s) and q¯(s) can be represented in the form 1 = d2 + µ¯ p1 (s) + µ2 p¯2 (s) + · · · + µn p¯n (s) + · · · , ¯ k(s) (1.111) q1 (s) + µ2 q¯2 (s) + · · · + µn q¯n (s) + · · · , q¯(s) = k02 + µ¯ where |¯ pi (s)| ≤ M,
|¯ qi (s)| ≤ M,
i = 1, 2, . . . .
(1.112)
Using the algorithm of the asymptotical representation with respect to µ (see [56]) for the stencil function v˜1 (x) and its derivative on the interval [xN , ∞] one obtains v˜1 (x) = exp(−κ(x − xN ))[1 + µA1 (x) + · · · + µn An (x) + · · · ], d˜ v1 (x) = exp(−κ(x − xN ))[H + µB1 (x) + · · · + µn Bn (x) + · · · ], dx def
def
where κ = q0 d, H = −q0 /d and Ai (x), Bi (x) are defined by the recurrence equations Π0 v˜1 (τ0 ) = exp(−κτ0 ), Πi v˜1 (τ 0 ) = δ1 (τ0 ),
Π−1 w(τ0 ) = H exp(−κτ0 ),
Πi−1 w(τ 0 ) = Hδ1 (τ0 ) + δ2 (τ0 ),
τ0 = sµ,
ϕi (τ0 ) exp(−κτ0 ) = p¯1 (τ0 )Πi−2 w(τ 0 ) + · · · + p¯i (τ0 )Π−1 w(τ 0 ), ψi (τ0 ) exp(−κτ0 ) = q¯1 (τ0 )Πi−2 v˜1 (τ 0 ) + · · · + q¯i (τ0 )Π−1 v˜1 (τ 0 ), Z ∞ δ2 (τ0 ) = [Hϕi (t) − ψi (t)] exp(−κ(2t − τ0 ))dt, τ0
Z
τ0
δ1 (τ0 ) =
[d2 δ2 (t) + ϕi (t) exp(−κt)] exp(−κ(τ0 − t))dt,
0
Πi v˜1 (τ0 ) = Ai (τ0 ) exp(−κτ0 ), Πi−1 w(τ 0 ) = Bi (τ0 ) exp(−κτ0 ), |Ai (τ0 )| ≤ c1 ,
|Bi (τ0 )| ≤ cn .
i = 1, 2,
1.2. Short history def
If we set s = (x − xN )/hN+1 the following problem can be derived whose def
solution is v˜2 (x) = v˜2 (xN + shN+1 ) = v¯2 (s): d ¯ d¯ v2 k(s) − h2N+1 q¯(s)¯ v2 (s) = 0, ds ds v2 ¯ d¯ v¯2 (0) = 1, k = 0, ds s=0 def
0 < s ≤ 1,
def
¯ where k(s) = k(xN +shN +1 ), q¯(s) = q(xN +shN +1 ). This implies for the function v¯2 (s) the representation ∞ X β¯ij (s)h2i v¯2 (s) = N+1 , i=0
where β¯0j (s) = 1,
β¯ij (s) =
s
Z 0
1 ¯ k(t)
Z
t
j q¯(λ)β¯i−1 (λ)dλ dt,
i > 0.
0
Now, in the case of problem (1.100) the equations (1.105) together with the exact boundary conditions at the points x = 0 and x = xN+1 lead to the following EDS (aux¯ )xˆj − b(xj )uj = −ϕ(xj ), 0 < j < N + 1, u0 = µ1 ,
uN +1 − σ2 uN = σ3 ,
where the coefficients a, b, ϕ are given by (1.106)–(1.108), and σ2 , σ3 are given by (1.110). In order to obtain a TDS for problem (1.100) we replace the stencil functions αj (s, hj ), β j (s, hj+1 ) (see formula (1.109)) by the finite sums def
α(m)j (s, hj ) =
m X
αij (s)h2i j ,
i=0
def
β (m)j (s, hj+1 ) =
m X
βij (s)h2i j+1 ,
(1.113)
i=0
and use in (1.110) the finite series (n)
def
(m)
(x) =
v˜1 (x) = exp(−κ(x − xN ))[1 + µA1 (x) + · · · + µn An (x)], v˜2
def
m X
(1.114) β¯ij (s)h2i N +1 ,
s = (x − xN )/hN +1 ,
i=0
instead of the functions v˜1 (x) and v˜2 (x). This procedure leads to the following TDS: (m) (m) (m) (m) (a(m) yx¯ )xˆ,i − bi yi = ϕi , i = 1, 2, . . . , N − 1, (1.115) (m) (m) (m) (m) (m) y0 = µ1 , yN+1 − σ2 yN = σ3 ,
37
38
Chapter 1. Introduction and a short historical overview (m)
(m,n)
where a(m) , b(m) , ϕ(m) , σ2 and σ3 are the truncated coefficients given in (1.106), (1.110), (1.113) and (1.114). This difference scheme is sometimes called TDS of rank (m, n). The following theorem characterizes the order of accuracy of the TDS (see [56]). Theorem 1.14 Let the assumptions (1.114), (1.115), (1.111), (1.112) and k(x) ∈ Q1 [0, ∞),
q(x), f (x) ∈ Q0 [0, ∞),
f ∈ Lt (0, ∞),
t ≥ 1,
ˆ¯ N has be satisfied. Then, the TDS (1.115) of rank (m, n) which is defined on ω the order of accuracy O(max{µn+1 , xN h2m+2 }), (1.116) def
where µ = 1/xN and m, n ≥ 0. In order to estimate the accuracy of a TDS as a function of the number of grid points, we consider the finite equidistant grid ω ¯ N = {x0 = 0, x1 , . . . , xN+1 }. If we choose h = N −ε , 0 < ε < 1, then it holds that xN = N h → ∞, N→∞
µ = 1/xN → 0. N→∞
Let us set
n+2 . 2m + n + 4 Then it can be easily shown that the two arguments of the maximum function in (1.116) are equal. Thus, if m is fixed and n satisfies n ≤ m, the order of accuracy of the TDS (1.115) is a maximum. For n = 2m we have h = N −1/2 and we obtain for the order of accuracy O(h2m+1 ). ε = ε(m, n) =
The representation of the coefficients of the TDS by truncated series in powers of the mesh-size has the same disadvantages as the techniques mentioned in the former publications on this topic discussed above. The EDS as well as an alternative TDS in which the coefficients are computed with IVP-solvers have been proposed and justified in [25, 26] for the nonlinear BVP on the half-axis d2 u − m2 u = −f (x, u) , dx2 u (0) = µ1 ,
x ∈ (0, ∞) ,
lim u (x) = 0.
x→∞
Under the assumption that the coefficients of the TDS are computed by an IVPsolver of the order n, it is shown that the implementation of the EDS by the TDS has the order of accuracy n ¯ = 2[(n + 1)/2], where n is a positive natural number and [·] denotes the entire part of the argument in these brackets. There are other techniques to construct EDS and the corresponding TDS of a high order of accuracy which cannot be classified with the general approach
1.2. Short history described above. Without claim of completeness let us mention here some of them. In [13, 52] for the problem (1.46), (1.47) an interesting approach has been proposed to develop 3-point TDS for sufficiently smooth input data k(x), q(x) and f (x). This approach was modified in [19] for piece-wise smooth input data with discontinuities at the grid nodes. Moreover, the former assumption q(x) ≥ 0 is replaced in this paper by |q(x)| ≤ c2 . (1.117) In order to construct the associated TDS (i.e. to calculate their coefficients) the solution of a system of linear algebraic equations is required, the order of which depends on the desired accuracy of the approximate solution (the same is valid for the schemes proposed in [13, 52]). The recent book [3] deals with the construction and investigation of difference schemes of an arbitrarily given order of accuracy for regular and singularly perturbed BVPs for ODEs of first and second order with operator coefficients from Banach spaces. Such equations can be considered as meta-models for linear systems of ODEs as well as for linear parabolic, elliptic or hyperbolic PDEs. The authors use an EDS which is defined on two-point or three-point stencils (for the first and the second order equations, respectively) as the basis for the construction of TDS of high accuracy. They approximate the function e−z (the principal part of the EDS) by Pad´e approximations and thus obtain difference schemes of an arbitrarily given order of accuracy p with explicit coefficients which become more and more complex with increasing p. As a second approach the authors use the so-called Taylor’s decompositions (with explicitly given coefficients) on two and three points. Unfortunately, there are no numerical examples testing and comparing the robustness of both types of difference schemes. For some time dependent PDEs, special techniques to construct EDS and the related algorithms were proposed and analysed in [50, 64, 65, 66, 69].
39
41
Chapter 2
Two-point difference schemes for systems of nonlinear BVPs No amount of experimentation can ever prove me right; a single experiment can prove me wrong. Albert Einstein (1879–1955)
This chapter deals with BVPs of the form u0 (x) + A(x)u = f (x, u),
x ∈ (0, 1),
B0 u(0) + B1 u(1) = β,
(2.1)
where A(x), B0 , B1 , ∈ Rd×d ,
rank[B0 , B1 ] = d,
f (x, u), β, u(x) ∈ Rd ,
and u is an unknown d-dimensional vector-function. On an arbitrary closed nonequidistant grid (1.3) there exists a unique 2-point EDS (see Definition 1.8) such ˆ¯ h , of the that its solution coincides with the grid function {u(xj )}N j=0 , xj ∈ ω exact solution u(x). Algorithmical realizations of the EDS are the TDS (see Definition 1.9). These schemes have an order of accuracy O(hm ), with respect to the maximal step size h, which can arbitrarily be prescribed by the user. Note that the EDS and TDS are very similar to the multiple shooting method [2, 35, 39, 40, 79]. Both techniques are based on the successive solution of IVPs on small subintervals and are theoretically supported by a posteriori error estimates. However, the advantage of our difference methods is that a unified theory of a priori estimates can be established. I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_2, © Springer Basel AG 2011
41
42
Chapter 2. 2-point difference schemes for systems of ODEs
2.1
Existence and uniqueness of the solution
Let us consider the BVP (2.1). By the linear part of the ODE in (2.1) a so-called fundamental matrix (or the evolution operator) U (x; ξ) is defined. Definition 2.1. For any ξ ∈ [0, 1] a fundamental matrix U (x; ξ) ∈ Rd×d is defined as a function satisfying the matrix IVP U 0 (x; ξ) + A(x)U (x; ξ) = 0,
0 < x < 1,
U (ξ; ξ) = I,
(2.2)
where I ∈ Rd×d denotes the identity matrix. In (2.2) the differentiation is with respect to x, and ξ is a parameter. def √ In what follows we denote by kuk = uT u the Euclidian norm of u ∈ Rd and we will use the subordinate matrix norm generated by this vector norm.
Let us make the following assumptions. Assumption 2.1. (i) The linear homogeneous problem corresponding to (2.1) possesses only the trivial solution. d
(ii) For the elements of A(x) = [aij (x)]i,j=1 it holds that aij (x) ∈ C[0, 1], i, j = 1, 2, . . . , d. The Assumption 2.1,(ii) implies the existence of a constant c1 such that kA(x)k ≤ c1
for all x ∈ [0, 1].
It can easily be shown that Assumption 2.1,(i) guarantees the nonsingularity of def
the matrix Q = B0 + B1 U (1; 0), i.e. the following auxiliary statement holds. Lemma 2.1 The matrix Q is nonsingular if and only if the linear homogeneous problem corresponding to (2.1) has only the trivial solution u(x) ≡ 0.
Proof. See e.g. [70], p.226, and [2], p.91.
Some sufficient conditions which guarantee that the linear homogeneous BVP corresponding to (2.1) has only the trivial solution are given in the following two lemmas. Lemma 2.2 Let A(x) ≥ 0 for all x ∈ [0, 1], i.e., A(x) is positive semidefinite. Moreover, we assume that one of the following conditions is satisfied:
2.1. Existence and uniqueness of the solution
def
(i) B0−1 exists and B0−1 B1 = α < 1; or (ii) B1−1 exists and kB0−1 B1 B1−1 B0 (iii) (B0 + B1 )
−1
T
k < 1; or
exists and k (B0 + B1 )
−1
B1 k < 1/2.
Then, problem (2.1) with f (x, u) ≡ 0 and β = 0 has only the trivial solution.
Proof. Here we show only the statement (iii). Assumption 2.1,(ii) guarantees the existence and uniqueness of the solution to the IVP (2.2). From the homogeneous ODE we derive u(x)T u0 (x) + u(x)T A(x)u(x) = 0. Now the assumptions postulated in the lemma imply 1 d 2 kuk ≤ 0. 2 dx
(2.3)
ku(1)k ≤ ku(0)k .
(2.4)
Thus The consequences of the homogeneous boundary conditions are u(0) = (B0 + B1 )
−1
Let us define
B1 [u(0) − u(1)] , def
P = (B0 + B1 )
−1
B1 ,
u(1) = (B0 + B1 )
−1
B0 [u(1) − u(0)] . (2.5)
def
v = u(1) − u(0).
Then u(0) = −P v, u(1) = v − P v and it follows from (2.4) that k(I − P ) vk ≤ kP vk . This implies kvk ≤ kv−P vk + kP vk ≤ 2 kP vk ≤ 2kP k kvk . From the last inequality and condition (iii) we get kvk = 0, i.e., u(0) = u(1), which together with (2.5) implies u(0) = u(1) = 0. Now using (2.3) the claim u(x) ≡ 0 is proved. Lemma 2.3 Let A ∈ Rd×d be a constant matrix such that the inverse [B0 + B1 e−A ]−1 exists and the estimate Z x
−xA
e max (B0 + B1 e−A )−1 B0 eξA (A − A(x)) dξ 0≤x≤1
0
Z
1
+ x
−xA
−A −1 −(1−ξ)A (B0 + B1 e ) B1 e (A − A(x)) dξ < 1
e
holds. Then, the matrix Q is nonsingular and the linear homogeneous BVP
43
44
Chapter 2. 2-point difference schemes for systems of ODEs corresponding to (2.1) possesses only the trivial solution.
Proof. Let us write the homogeneous equation corresponding to (2.1) in the equivalent form u0 (x) + Au = [A − A(x)]u, x ∈ (0, 1). We get u(x) = e
−Ax
x
Z
e−(1−ξ)A [A − A(ξ)]u(ξ)dξ.
u(0) +
(2.6)
0
Substituting this expression into the boundary condition we obtain B0 u(0) + B1 e
−A
Z
1
e−(1−ξ)A [A − A(ξ)]u(ξ)dξ = 0.
u(0) + B1 0
Thus, u(0) = −[B0 + B1 e−A ]−1 B1
Z
1
e−(1−ξ)A [A − A(ξ)]u(ξ)dξ.
0
Using this in (2.6) we see that the solution of problem (2.1) satisfies the integral equation Z x −(x−ξ)A −xA −A −1 −(1−ξ)A u(x) = e [A − A(ξ)]u(ξ)dξ −e [B0 + B1 e ] B1 e 0
Z
1
e−xA [B0 + B1 e−A ]−1 B1 e−(1−ξ)A [A − A(ξ)]u(ξ)dξ
− x
and we obtain the estimate Z x
−xA
e [I − (B0 + B1 e−A )−1 B1 e−A ]eξA [A − A(ξ)] dξ ku(x)k ≤ 0
Z
1
+ x
−xA
−A −1 −(1−ξ)A [B0 + B1 e ] B1 e [A − A(ξ)] dξ kuk∞
e
from which the assertion of the lemma follows.
Let us introduce the vector-function def
u(0) (x) = U (x; 0)Q−1 β, (which exists due to Assumption 2.1,(i) for all x ∈ [0, 1]) and the set def T Ω (D, β(x)) = v(x) = (v1 (x), . . . , vd (x)) , vj ∈ C[0, 1], j = 1, 2, . . . , d, (2.7)
v(x) − u(0) (x) ≤ β(x), x ∈ D ,
2.1. Existence and uniqueness of the solution where D ⊆ [0, 1] is a closed set. Due to Assumption 2.1,(i) the problem (2.1) is equivalent to the integral equation Z1 (2.8) u(x) = G(x, ξ) f (ξ, u(ξ))dξ + u(0) (x), x ∈ [0, 1], 0
where G(x, ξ) is the Green’s function of the corresponding linear differential operator (see, e.g. [2], p.226), which can be written in the form ( −U (x; 0)HU (1; ξ), 0 ≤ x ≤ ξ, def (2.9) G(x, ξ) = −U (x; 0)HU (1; ξ) + U (x; ξ), ξ ≤ x ≤ 1, def
where H = Q−1 B1 . Now we can formulate the next auxiliary statement. Lemma 2.4 Let Assumption 2.1 be satisfied. Then kU (x; ξ)k ≤ exp[c1 (x − ξ)], ( exp[c1 (1 + x − ξ)] kHk , 0 ≤ x ≤ ξ, kG(x, ξ)k ≤ exp[c1 (x − ξ)] [1 + kHk exp(c1 )] , ξ ≤ x ≤ 1.
(2.10) (2.11)
Proof. In order to prove (2.10) let us rewrite the IVP (2.2) in the equivalent form Zx U (x; ξ) = I −
A(η)U (η; ξ)dη. ξ
Then we have
Zx kA(η)k kU (η; ξ)k dη.
kU (x; ξ)k ≤ 1 + ξ
With Gronwall’s Lemma (see e.g. [33], p. 24) we get (2.10). The estimate (2.11) follows from (2.9) and (2.10). In addition to Assumption 2.1 we postulate d
Assumption 2.2. The vector-function f (x, u) = {fj (x, u)}j=1 satisfies the conditions (i) fj ∈ C([0, 1] × Ω ([0, 1], r(x))), kf (x, u)k ≤ K
for all u ∈ Ω ([0, 1], r(x)),
(ii) kf (x, u) − f (x, v)k ≤ L ku − vk for all x ∈ [0, 1] and u, v ∈ Ω ([0, 1], r(x)),
45
46
Chapter 2. 2-point difference schemes for systems of ODEs def
where r(x) = K exp(c1 x) [x + kHk exp(c1 )].
Now, we discuss sufficient conditions which guarantee the existence and uniqueness of a solution of problem (2.1). Later we will use these conditions to prove the existence of an EDS and the corresponding TDS. We begin with the following statement. Theorem 2.1 Let Assumptions 2.1 and 2.2 be satisfied. Suppose def
q = L exp(c1 ) [1 + kHk exp(c1 )] < 1.
(2.12)
Then there exists a unique solution u ∈ Ω ([0, 1], r(x)) of problem (2.1) which can be determined using the iteration procedure
u
(k)
Z1 (x) =
G(x, ξ)f (ξ, u(k−1) (ξ))dξ + u(0) (x),
x ∈ [0, 1].
(2.13)
0
The corresponding error estimate is
(k)
u − u
≤ 0,∞,[0,1]
qk r(1), 1−q
(2.14)
def
where kvk0,∞,[0,1] = maxx∈[0,1] kv(x)k.
Proof. Let us show that the operator
def
Z1
<(x, u(·)) =
G(x, ξ)f (ξ, u(ξ))dξ + u(0) (x),
x ∈ [0, 1]
0
transforms the set Ω([0, 1], r(x)) into itself. Taking into account the assumptions of the theorem and the estimate (2.11), for all v ∈ Ω([0, 1], r(x)) we get
<(x, v(·)) − u(0) (·)
0,∞,[0,1]
Zx
Z1
≤ K exp[c1 (1 + x) kHk]
exp(−c1 ξ)dξ + exp(c1 x) 0
≤ K exp(c1 x) [x + kHk exp(c1 )] = r(x).
exp(−c1 ξ)dξ
0
2.1. Existence and uniqueness of the solution Moreover, for all u, v ∈ Ω([0, 1], r(x)) we have k<(x, u(·)) − <(x, v(·))k0,∞,[0,1] Z1 ≤ exp(c1 ) [1 + kHk exp(c1 )]
kf (ξ, u(ξ)) − f (ξ, v(ξ))k dξ 0
≤ q ku − vk0,∞,[0,1] . Due to (2.12) it holds that q < 1. Thus, <(x, u(·)) is a contraction operator on the set Ω ([0, 1], r(x)). Consequently, the assumptions of Banach’s Fixed Point Theorem (see Theorem 1.1) are fulfilled and we can conclude that the equation (2.8) or the problem (2.1) has a unique solution which is the fixed point of the iteration procedure (2.13). Here, we omit the standard proof of (2.14) and refer, e.g., to [68], Theorem 5.1.3. In the case of scalar second-order ODEs it is possible to formulate the statement of Theorem 2.1 in a stronger version. More precisely, let us consider the problem d2 u(x) − q(x)u(x) = −f (x, u(x)), dx2
x ∈ (0, 1),
u(0) = µ1 , u(1) = µ2 , (2.15)
where q(x) is a given piece-wise continuous function and q(x) ≥ 0
for all x ∈ [0, 1].
(2.16)
Let us write problem (2.15) in the form (2.1): du + A(x)u = F (x, u), dx
B0 u(0) + B1 u(1) = β
(2.17)
with
u(x) 0 −1 0 u= , A(x) = , F (x, u) = , u0 (x) −q(x) 0 −f (x, u) 1 0 0 0 µ1 B0 = . , B1 = , β= 0 0 1 0 µ2 Note, that the often used Theorem 7.3.3.4 in [79] (for linear boundary conditions this statement was proved in [40]) cannot be applied to the problem (2.15) since the corresponding assumptions are violated. This theorem assumes that a boundary condition of the form r(u(0), u(1))) = 0 is given and that the matrix P (u, v) = Du r(u, v) + Dv r(u, v)
47
48
Chapter 2. 2-point difference schemes for systems of ODEs admits for all u, v ∈ Rd a representation P (u, v) = P0 (I + M (u, v)), with a constant nonsingular matrix P0 . In our case this matrix agrees with the matrix B0 which is singular. m11 m12 f1 (x) For a matrix M = and a vector-function f (x) = we f2 (x) m21 m22 define def
kM k = kM k1 = max
2 X
i=1,2
|mij |,
kf (x)k = kf (x)k1 = max{f1 (x), f2 (x)},
j=1
def
kf k∞ = max kf (x)k. x∈[0,1]
It is easy to check that 1 0 , −1 1 1 − x −ξ(1 − x) e−xA (B0 + B1 e−A )−1 B0 eξA = , −1 ξ x (1 − ξ)x −xA −A −1 −(1−ξ)A e (B0 + B1 e ) B1 e = . 1 1−ξ B0 + B1 e−A =
1 1
0 , 1
(B0 + B1 e−A )−1 =
0 −1 Choosing A = , we further get 0 0
−xA
e (B0 + B1 e−A )−1 B0 eξA [A − A(x)]
1 − x −ξ(1 − x)
0 0
= −ξ(1 − x)q(ξ) 0 ≤ kqk∞ ξ =
−1
ξ q(ξ) 0 ξq(ξ) 0 and
−xA
(B0 + B1 e−A )−1 B1 e−(1−ξ)A [A − A(x)]
e
x(1 − ξ)q(ξ) 0
≤ kqk∞ (1 − ξ). = (1 − ξ)q(ξ) 0
This yields x
Z
−xA
e (B0 + B1 e−A )−1 B0 eξA (A − A(x)) dξ
max
0≤x≤1
0
Z
1
+ x
−xA
−A −1 −(1−ξ)A (B0 + B1 e ) B1 e (A − A(x)) dξ
e x
Z ≤ kqk∞ max
x∈[0,1]
Z
1
0
(1 − ξ)dξ
ξdξ + x
= kqk∞ /2.
2.1. Existence and uniqueness of the solution The statement of Lemma 2.3 now implies that for a function q(x), with kqk∞ ≤ 2, there exists Q−1 . Due to formulae (2.8) and (2.9) we get Z 1 u(x) = G(x, ξ)F (ξ, u(ξ))dξ + u(0) (x) 0 ! (2.18) Z 1 (0) G12 (x, ξ) u1 (x) =− , f (ξ, u(ξ))dξ + (0) G22 (x, ξ) u2 (x) 0 where Gi,j (x, ξ), i, j = 1, 2 are the components of the Green’s function G(x, ξ). Thus, we obtain 1 1 U12 (1, 0) 0 0 0 0 0 , H= = 1 0 −U11 (1, 0) 1 1 0 U12 (1, 0) U12 (1, 0) where Uij (x, ξ), i, j = 1, 2 are the elements of the matrix U (x; ξ). It is not favorable to use the estimates (2.10) and (2.11) since the integral equation (2.18) contains only two components of the matrix G(x, ξ). Moreover, the component-wise representation of (2.18) is Z 1 (0) u(x) = − G12 (x, ξ)f (ξ, u(ξ))dξ + u1 (x), 0
u0 (x) = −
Z
1
(0)
G22 (x, ξ)f (ξ, u(ξ))dξ + u2 (x). 0
The first equation agrees with the equation Z1 G(x, ξ, q(·)) {f (ξ, u(ξ)) − q(ξ) [µ1 + ξ(µ2 − µ1 )]} dξ + µ1 + x(µ2 − µ1 ),
u(x) = 0
where G(x, ξ, q(·)) is the Green’s function corresponding to the homogeneous part of the ODE (2.15). Let us now investigate this equation. It is well known that ( x(1 − ξ), 0 ≤ x ≤ ξ, 0 ≤ G(x, ξ, q(·)) ≤ G(x, ξ, 0) and G(x, ξ, 0) = ξ(1 − x), ξ ≤ x ≤ 1. We introduce the set Ω [0, 1], p(x), r(x) def
=
(2.19) v ∈ C[0, 1] : p(x) ≤ v(x) − µ1 − x(µ2 − µ1 ) ≤ r(x) for all x ∈ [0, 1]
and formulate an appropriate condition with respect to the right-hand side of the ODE (2.15). Let for all u, v ∈ Ω ([0, 1], p(x), r(x)) and x ∈ [0, 1] the following inequalities be fulfilled: K1 (x) ≤ f (x, u(x)) ≤ K2 (x),
K1 (x) ≤ 0, (2.20)
|f (x, u(x)) − f (x, v(x))| ≤ L(x) |u(x) − v(x)| ,
49
50
Chapter 2. 2-point difference schemes for systems of ODEs where K1 , K2 , L ∈ C[0, 1] satisfy Z1 G(x, ξ, 0)L(ξ)dξ ≤ L1 < 1,
x ∈ [0, 1],
(2.21)
0
and
Z1
o n − dξ ≤ r(x), G(x, ξ, 0) K2 (ξ) − q(ξ) [µ1 + ξ(µ2 − µ1 )]
0
(2.22) Z1 p(x) ≤
n
+
G(x, ξ, 0) K1 (ξ) − q(ξ) [µ1 + ξ(µ2 − µ1 )]
o
dξ,
0 def
def
with [g(x)]+ = max{0, g(x)} and [g(x)]− = min{0, g(x)}.
We can now prove the following result. Theorem 2.2 Let the conditions (2.16), (2.20), (2.21) and (2.22) be satisfied. Then, the BVP (2.15) has a unique solution in the set Ω ([0, 1], p(x), r(x)) which is defined in (2.19). This solution can be determined with the fixed point iteration.
Proof. Under the assumptions formulated above the operator Z1 <(x, u(·)) =
G(x, ξ, q(·)) {f (ξ, u(ξ)) − q(ξ) [µ1 + ξ(µ2 − µ1 )]} dξ+µ1 +x(µ2 −µ1 ) 0
transforms the set Ω ([0, 1], p(x), r(x)) into itself and is contractive. Banach’s Fixed Point Theorem (see Theorem 1.1) yields the claim of the theorem. Let us illustrate this theorem by examples. Example 2.1. We consider the problem (see e.g. [79], p.169) d2 u(x) 3 = u2 (x), x ∈ (0, 1), dx2 2
u(0) = 4, u(1) = 1.
(2.23)
Here 3 q(x) ≡ 0, f (x, u(x)) = − u2 (x), p(x) ≡ 0, r(x) = 4 − 3x, µ1 = 4, µ2 = 1, 2 3 <(x, u(·)) = − 2
Z1 0
G(x, ξ, 0)u2 (ξ)dξ + 4 − 3x,
2.1. Existence and uniqueness of the solution 3 3 − (4 − 3x)2 ≤ f (x, u(x)) ≤ 0, K1 (x) = − (4 − 3x)2 , K2 (x) ≡ 0, 2 2 √ 3 4− 7 1 3 2 L(x) = 3(4 − 3x), L1 = 3 x . − 2xmax + xmax < 0.95, xmax = 2 max 2 3 This problem can be represented in the form (2.17), with 0 −1 1 x−ξ 0 0 A(x) = , U (x; ξ) = , H= , 0 0 0 1 1 0 x x(1 − ξ) − , x ≤ ξ, 1 1−ξ 4 − 3x (0) u (x) = , G(x, ξ) = −3 1 − x −ξ(1 − x) − , ξ < x. −1 ξ Note, the estimates (2.10) and (2.11) take here the form ( if x ≤ ξ, e1+x−ξ kU (x; ξ)k ≤ ex−ξ , kG(x, ξ)k ≤ . ex−ξ (1 + e) if ξ ≤ x Obviously, the bounds are not very sharp. Now Theorem 2.2 says that the operator <(x, u(·)) is a contractive mapping on the set Ω ([0, 1], 0, 4 − 3x) which transforms Ω into itself. Thus, problem (2.23) has a unique solution in Ω which can be determined by the fixed point iteration.
Example 2.2. The next example goes back to B. A. Troesch (see e.g. [83]) and represents a well-known test problem for numerical BVP-software, d2 u(x) = λ sinh(λ u(x)), dx2
x ∈ (0, 1),
λ > 0,
u(0) = 0, u(1) = 1.
(2.24)
Here q(x) ≡ 0, f (x, u(x)) = −λ sinh(λu(x)), p(x) ≡ 0, r(x) = x, µ1 = 0, µ2 = 1, Z1 <(x, u(·)) = −λ
G(x, ξ, 0) sinh(λu(ξ))dξ + x, 0
− λ sinh(λu(x)) ≤ f (x, u(x)) ≤ 0, K1 (x) = −λ sinh(λx), K2 (x) ≡ 0, Z1 λ G(x, ξ, 0) cosh(λξ)dξ ≤ L1 < 0.81 for λ ∈ (0, 1.9]. L(x) = 2λ sinh 2 0
51
52
Chapter 2. 2-point difference schemes for systems of ODEs We can formulate this problem in the form (2.17) with the same U (x; ξ), A(x), H and G(x, ξ) as given in Example 2.1 and with u(0) = (x, 1)T . Using Theorem 2.2 we see that the operator <(x, u(·)) is a contractive mapping on the set Ω ([0, 1], 0, x) which transforms Ω into itself. For λ ∈ (0, 1.9) problem (2.24) has a unique solution which can be determined by the fixed point iteration. Note that this restriction on λ is merely technical and is essentially the result of the actual choice of the set Ω ([0, 1], 0, x). A numerical test with values of λ up to λ = 62 is described in Example 2.4.
2.2
Existence of a two-point EDS
Let us consider the space of grid functions {uj }N j=0 defined on the grid (1.3) and equipped with the norm def
= max kuj k . kuk0,∞,b ωh 0≤j≤N Throughout this chapter M denotes a generic positive constant which does not dependent on h. Given {v j }N j=0 we define the IVPs (each of the dimension d) dY j (x; v j−1 ) + A(x)Y j (x; v j−1 ) = f (x, Y j (x; v j−1 )), dx j
Y (xj−1 ; v j−1 ) = v j−1 ,
x ∈ (xj−1 , xj ],
(2.25)
j = 1, 2, . . . , N.
The existence of a unique solution of (2.25) is postulated in the following lemma. Lemma 2.5 Let Assumptions 2.1 and 2.2 be satisfied. Suppose that the grid function {v j }N j=0 b b belongs to Ω ω h , r(·) , where Ω ω h , r(·) is defined in (2.7) Then the problem (2.25) has a unique solution.
Proof. The question about the existence and uniqueness of the solution of the IVPs in (2.25) is equivalent to the same question for the integral equation Y j (x; v j−1 ) = =(x, v j−1 , Y j ),
(2.26)
where j
def
Zx
=(x, v j−1 , Y ) = U (x; xj−1 )v j−1 + xj−1
U (x; ξ)f (ξ, Y j (ξ; v j−1 ))dξ,
x ∈ e¯j .
2.2. Existence of a two-point EDS We define the n-th power of the operator =(x, v j−1 , Y j ) by def
=n (x, v j−1 , Y j ) = =(x, v j−1 , =n−1 (x, v j−1 , Y j )), Let Y j (x; v j−1 ) ∈ Ω e¯j , r(·) for {v j }N j=0
n = 2, 3, . . . .
b h , r(·) . Then ∈Ω ω
=(x, v j−1 , Y j ) − u(0) (x) Zx
(0) ≤ kU (x; xj−1 )k v j−1 − u (xj−1 ) + kU (x; ξ)k f (ξ, Y j (ξ; v j−1 )) dξ xj−1
≤ K exp(c1 x) [xj−1 + kHk exp(c1 )] + K(x − xj−1 ) exp [c1 (x − xj−1 )] ≤ K exp(c1 x) [x + kHk exp(c1 )] = r(x),
x ∈ e¯j ,
b that is, for grid functions {v j }N ∈ Ω ω , r(·) the operator =(x, v j−1 , Y j ) h j=0 transforms the set Ω e¯j , r(·) into itself. j Moreover, for Y j (x; v j−1 ), Ye (x; v j−1 ) ∈ Ω e¯j , r(·) we have the estimate
j
=(x, v j−1 , Y j ) − =(x, v j−1 , Ye ) Zx ≤
j
kU (x; ξ)k f (ξ, Y j (ξ, v j−1 )) − f (ξ, Ye (ξ, v j−1 )) dξ
xj−1
Zx
j
j
≤ L exp(c1 hj )
Y (ξ, v j−1 ) − Ye (ξ, v j−1 ) dξ xj−1
j
≤ L exp(c1 hj )(x − xj−1 ) Y j − Ye
0,∞,¯ ej
.
Using this estimate we get
j
2
= (x, v j−1 , Y j ) − =2 (x, v j−1 , Ye ) Zx
j
≤ L exp(c1 hj )
=(x, v j−1 , Y j ) − =(x, v j−1 , Ye ) dξ xj−1
≤
j [L exp(c1 hj )(x − xj−1 )]2
j .
Y − Ye 2! 0,∞,¯ ej
If we continue to determine such estimates we get by induction
53
54
Chapter 2. 2-point difference schemes for systems of ODEs j
k=n (x, v j−1 , Y j ) − =n (x, v j−1 , Ye )k ≤
[L exp(c1 hj )(x − xj−1 )]n
j e j
Y − Y n! 0,∞,¯ ej
and it follows that j k=n (·, v j−1 , Y j ) − =n (·, v j−1 , Ye )k0,∞,[xj−1 ,xj ]
≤
j [L exp(c1 hj )hj ]n
j .
Y − Ye n! 0,∞,¯ ej
In view of the fact that [L exp(c1 hj )hj ]n → 0 for n → ∞, n! we can fix the number n large enough such that [L exp(c1 hj )hj ]n < 1, n! which yields that the operator =n (x, v j−1 , Y j ) is a contractive mapping of the j N b set Ω e¯ , r(·) into itself. Thus, for {v j }j=0 ∈ Ω ω h , r(x) problem (2.26) [or problem (2.25)] has a unique solution (see, e.g. [82], pp. 392–393). We are now in the position to prove the main result of this section. Theorem 2.3 Let the assumptions of Theorem 2.1 be satisfied. Then, there exists a 2-point EDS for problem (2.1). It is of the form uj = Y j (xj ; uj−1 ),
j = 1, 2, . . . N,
(2.27)
B0 u0 + B1 uN = β.
(2.28)
Proof. It is easy to see that d j Y (x; uj−1 ) + A(x)Y j (x; uj−1 ) = f (x, Y j (x; uj−1 )), dx Y j (xj−1 ; uj−1 ) = uj−1 ,
x ∈ (xj−1 , xj ],
j = 1, 2, . . . N.
Due to Lemma 2.5 the solvability of the last problem is equivalent to the solvability of the problem (2.1). Thus, the solution of the problem (2.1) can be represented by u(x) = Y j (x; uj−1 ),
x ∈ e¯j ,
j = 1, 2, . . . , N.
(2.29)
Substituting x = xj into (2.29) we get the 2-point EDS (2.27),(2.28). For further examination of the 2-point EDS we need the following lemma.
2.2. Existence of a two-point EDS Lemma 2.6 Let the assumptions of Lemma 2.5 be satisfied. Then, for two grid functions N b {uj }N j=0 , {v j }j=0 ∈ Ω ω h , r(·) the following inequality is satisfied:
j
Y (x; uj−1 ) − Y j (x; v j−1 ) − U (x; xj−1 ) (uj−1 − v j−1 ) Zx
≤ L(x − xj−1 ) exp c1 (x − xj−1 ) + L
exp [c1 (x − ξ)] dξ kuj−1 − v j−1 k .
xj−1
(2.30) j j Proof. When proving Lemma 2.5 it was shown that Y (x; uj−1 ) and Y (x; v j−1 ) j belong to Ω e¯ , r(·) . Therefore it follows from (2.25) that
j
Y (x; uj−1 ) − Y j (x; v j−1 ) − U (x; xj−1 ) (uj−1 − v j−1 )
Zx ≤L
exp [c1 (x − ξ)]
exp [c1 (ξ − xj−1 )] kuj−1 − v j−1 k
xj−1
+ Y j (ξ; uj−1 ) − Y j (ξ; v j−1 ) − U (ξ; xj−1 ) (uj−1 − v j−1 ) dξ = L exp [c1 (x − xj−1 )] (x − xj−1 ) kuj−1 − v j−1 k Zx +L
exp [c1 (x − ξ)] Y j (ξ; uj−1 ) − Y j (ξ; v j−1 )
xj−1
−U (ξ; xj−1 ) (uj−1 − v j−1 )k dξ.
Now, Gronwall’s Lemma implies (2.30).
We can now prove the uniqueness of the solution of the 2-point EDS (2.27), (2.28). Theorem 2.4 Let the assumptions of Theorem 2.1 be satisfied. Then there exists a h0 > 0 such that for h ≤ h0 the 2-point EDS (2.27), (2.28) has a unique solution def N b {uj }N j=0 = {u(xj )}j=0 ∈ Ω ω h , r(·)
which can be determined by the modified fixed point iteration (k)
uj
(k)
(k−1)
(k−1)
− U (xj ; xj−1 )uj−1 = Y j (xj ; uj−1 ) − U (xj ; xj−1 )uj−1 ,
(2.31)
(k)
(2.32)
(k)
B0 u0 + B1 uN = β,
j = 1, 2, . . . N,
k = 1, 2, . . . .
55
56
Chapter 2. 2-point difference schemes for systems of ODEs (0)
uj
= U (xj ; 0)Q−1 β,
j = 0, 1, . . . N.
(2.33)
The corresponding error estimate is
(k)
u − u
0,∞,b ωh
≤
q1k r(1), 1 − q1
(2.34)
def
where q1 = q exp[L h exp(c1 h)] < 1. Proof. Taking into account (2.4), we apply successively the formula (2.27) and get u1 = U (x1 ; 0)u0 + Y 1 (x1 ; u0 ) − U (x1 ; 0)u0 , u2 = U (x2 ; x1 )U (x1 ; 0)u0 + U (x2 ; x1 ) Y 1 (x1 ; u0 ) − U (x1 ; 0)u0 + Y 2 (x2 ; u1 ) − U (x2 ; x1 )u1 = U (x2 ; 0)u0 + U (x2 ; x1 ) Y 1 (x1 ; u0 ) − U (x1 ; 0)u0 + Y 2 (x2 ; u1 ) − U (x2 ; x1 )u1 , .. . uj = U (xj ; 0)u0 +
j X
U (xj ; xi ) Y i (xi ; ui−1 ) − U (xi ; xi−1 )ui−1 .
(2.35)
i=1
Substituting (2.35) into the boundary condition (2.28), we obtain [B0 + B1 U (1; 0)] u0 = Qu0 = −B1
N X
U (1; xi ) Y i (xi ; ui−1 ) − U (xi ; xi−1 )ui−1 + β.
i=1
Thus, uj = − U (xj ; 0)H
N X
U (1; xi ) Y i (xi ; ui−1 ) − U (xi ; xi−1 )ui−1
i=1
+
j X
U (xj ; xi ) Y i (xi ; ui−1 ) − U (xi ; xi−1 )ui−1 + U (xj ; 0)Q−1 β
i=1
or uj =
N X
Gh (xj , xi ) Y i (xi ; ui−1 ) − U (xi ; xi−1 )ui−1 + u(0) (xj ),
(2.36)
i=1
where the discrete Green’s function Gh (x, ξ) of problem (2.27), (2.28) is the b h , that projection of the Green’s function G(x, ξ) (see formula (2.9)) onto the grid ω is bh. G(x, ξ) = Gh (x, ξ) for all x, ξ ∈ ω
2.2. Existence of a two-point EDS Due to Zxi
i
Y (xi ; ui−1 ) − U (xi ; xi−1 )ui−1 =
U (xi ; ξ)f (ξ, Y i (ξ; ui−1 ))dξ,
xi−1
we have
=
N Zxi X i=1x
G(xj , ξ)f (ξ, Y i (ξ; ui−1 ))dξ + u(0) (xj ).
(2.37)
i−1
b h , r(·) into itself. Next we show that the operator (2.37) transforms the set Ω ω b Let {v j }N j=0 ∈ Ω ω h , r(·) , then we have (see the proof of Lemma 2.5) v(x) = Y j (x; v j−1 ) ∈ Ω e¯j , r(·) ,
j = 1, 2, . . . , N,
and
(0) ) − u (x )
N Zxi X
exp(−c1 ξ)dξ + exp(c1 xj )
i=1 x
Zxi j X
exp(−c1 ξ)dξ
i=1 x
i−1
i−1
j N X X exp(−c1 xi−1 )hi + exp[c1 (1 + xj )] kHk exp(−c1 xi−1 )hi ≤ K exp(c1 xj ) i=1
i=1
≤ K exp(c1 xj )[xj + kHk exp(c1 )] = r(xj ),
j = 0, 1, . . . , N.
b Moreover, the operator
N X
exp c1 (xj − xi ) 1 + kHk exp(c1 ) L(xi − xi−1 )
i=1
Zxi exp c1 (xi − ξ) dξ kuj−1 − v j−1 k × exp c1 (xj − xi−1 ) + L xi−1
57
58
Chapter 2. 2-point difference schemes for systems of ODEs ≤ exp(c1 xj ) 1 + kHk exp(c1 ) L exp L h exp(c1 h) ku − vk0,∞,b ω
h
≤ q exp L h exp(c1 h) ku − vk0,∞,b = q1 ku − vk0,∞,b . ω ω h
h
Since (2.12) implies q < 1, we have q1 < 1 for h0 small enough and the operator N N b
2.3
Implementation of the 2-point EDS
In order to get an implementable compact 2-point difference scheme from the 2-point EDS we replace (2.27), (2.28) by the so-called truncated difference scheme of rank m (m-TDS) (m)
yj
(m)
= Y (m)j (xj ; y j−1 ),
(m)
B0 y 0
(m)
+ B1 y N
j = 1, 2, . . . N,
(2.38)
= β.
(2.39) (m)
Here, m is a positive integer and Y (m)j (xj ; y j−1 ) denotes the numerical solution of the IVP (2.25) on the interval e¯j which has been obtained by some one-step method of the order m (e.g. by the Taylor series method or a Runge-Kutta method) (m)
(m)
(m)
Y (m)j (xj ; y j−1 ) = y j−1 + hj Φ(xj−1 , y j−1 ; hj ). It holds that
(2.40)
(m)j
(xj ; uj−1 ) − Y j (xj ; uj−1 ) ≤ M hm+1
Y j
and the increment function (see e.g. [31]) Φ(x, u, h) satisfies the consistency condition Φ(x, u; 0) = f (x, u) − A(x)u. For example, in the case of the Taylor expansion method we have (m)
(m)
(m)
Φ(xj−1 , y j−1 ; hj ) = f (xj−1 , y j−1 ) − A(xj−1 )y j−1 (m) m j X hj p−1 dp Y (x; y j−1 ) + p! dxp p=2
,
x=xj−1
and in the case of an explicit Runge-Kutta method we have (m)
Φ(xj−1 , y j−1 ; hj ) =
s X
bi k i ,
i=1
ki = g(xj−1 +
(m) ci hj , y j−1
+ hj
s X l=1
(2.41) ail kl ),
i = 1, . . . , s,
2.3. Implementation of the 2-point EDS def
where g(x, u) = f (x, u) − A(x) u and aij = 0 for i ≤ j. Example 2.3. Let us consider the BVP du(x) = −u(x)2 , dx
0 < x < 1,
The corresponding exact solution is u(x) =
u(0) =
1 u(1). 2
(2.42)
1 . x−2
ˆ h . Due to Theorem 2.3 there On the interval [0, 1] we use the nonuniform grid ω exists the following EDS for problem (2.42): uj = Y j (xj ; uj−1 ),
j = 1, 2, . . . N,
u0 =
1 uN , 2
where Y j (x, uj−1 ) is the solution of the IVP 2 dY j (x; uj−1 ) = − Y j (x; uj−1 ) , dx Y j (xj−1 ; uj−1 ) = uj−1 ,
x ∈ (xj−1 , xj ],
j = 1, 2, . . . N.
Since the function Y j (x; uj−1 ) =
x − xj−1 +
1 uj−1
−1 ,
j = 1, 2, . . . N,
is the exact solution of the IVP, the EDS takes the form uj =
uj−1 , 1 + hj uj−1
j = 1, 2, . . . N,
u0 =
1 uN . 2
Let us now construct the TDS of rank two (2-TDS) (2)
yj (2)
(2)
= Y (2)j (xj ; yj−1 ),
j = 1, 2, . . . N,
(2)
y0 =
1 (2) y , 2 N
(2)
where yj ≈ uj and Y (2)j (xj ; yj−1 ) is the approximate solution of the IVP obtained by a one-step method of order 2. Using the Taylor series method as the numerical integration technique we obtain 2 3 (2) (2) (2) (2) Y (2)j (xj ; yj−1 ) = yj−1 − hj yj−1 + h2j yj−1 . Therefore, the 2-TDS for which we are looking is 2 3 (2) (2) (2) (2) yj = yj−1 − hj yj−1 + h2j yj−1 j = 1, 2, . . . N,
(2)
y0 =
1 (2) y . 2 N
In order to prove the existence and uniqueness of a solution of the m-TDS (2.38), (2.39) and to investigate its accuracy the following statement is required.
59
60
Chapter 2. 2-point difference schemes for systems of ODEs Lemma 2.7 Let the method (2.40) be of the order of accuracy m. Assume that the increment function Φ(x, u; h) is sufficiently smooth, the entries aps (x) of the matrix A(x) belong to Cm [0, 1] and there exists a real number ∆ > 0 such that the components fp (x, u) of the vector function f (x, u) belong to Ck,m−k ([0, 1]×Ω([0, 1], r(·)+∆)), with k = 0, 1, . . . , m − 1. Let the matrix U (1) (xj ; xj−1 ) be defined by def
U (1) (xj ; xj−1 ) = I − hj A(xj−1 ). Then
(1)
U (xj ; xj−1 ) − U (xj ; xj−1 ) ≤ M h2j ,
(2.43)
(2.44)
1
(m)j (1)
(xj ; v j−1 ) − U (xj ; xj−1 )v j−1
hj Y
≤ K + M hj ,
(2.45)
1
(m)j (m)j (1)
Y (x ; u ) − Y (x ; v ) − U (x ; x )(u − v ) j j−1 j j−1 j j−1 j−1 j−1
hj
≤ (L + M hj )kuj−1 − v j−1 k,
(2.46)
N b where {uj }N j=0 , {v j }j=0 ∈ Ω ω h , r(·) + ∆ .
Proof. Inserting x = xj into the Taylor expansion of the function U (x; xj−1 ) at the point xj−1 gives
U (xj ; xj−1 ) = U
(1)
Zxj (xj − t)
(xj , xj−1 ) +
d2 U (t; xj−1 ) dt. dt2
xj−1
From this equation the inequality (2.44) follows immediately. It is easy to verify the following identities: 1 (m)j (1) Y (xj ; v j−1 ) − U (xj ; xj−1 )v j−1 hj = Φ(xj−1 , v j−1 ; hj ) + A(xj−1 )v j−1 = Φ(xj−1 , v j−1 ; 0) + hj = f (xj−1 , v j−1 ) + hj
¯ ∂Φ(xj−1 , v j−1 ; h) + A(xj−1 )v j−1 ∂h
¯ ∂Φ(xj−1 , v j−1 ; h) , ∂h
1 Y (m)j (xj ; uj−1 ) − Y (m)j (xj ; v j−1 ) − U (1) (xj ; xj−1 )(uj−1 − v j−1 ) hj
2.3. Implementation of the 2-point EDS = Φ(xj−1 , uj−1 ; hj ) − Φ(xj−1 , v j−1 ; hj ) + A(xj−1 )(uj−1 − v j−1 ) ¯ ¯ ∂Φ(xj−1 , uj−1 ; h) ∂Φ(xj−1 , v j−1 ; h) − = f (xj−1 , uj−1 ) − f (xj−1 , v j−1 ) + hj ∂h ∂h = f (xj−1 , uj−1 ) − f (xj−1 , v j−1 ) Z
¯ ∂ 2 Φ(xj−1 , θuj−1 + (1 − θ)v j−1 ; h) dθ (uj−1 − v j−1 ), ∂h∂u
1
+ hj 0
¯ ∈ (0, h). These equalities imply the formulas (2.45), (2.46) and thus the where h proof is complete. Now we are in a position to prove the main result of this section. Theorem 2.5 Let the assumptions of Theorem 2.1 and Lemma 2.7 be satisfied. Then, there exists a real number h0 > 0 such that for h ≤ h0 the m-TDS (2.38), (2.39) has a unique solution which can be determined by the modified fixed point iteration (m,n)
yj
(m,n)
− U (1) (xj ; xj−1 )y j−1
(m,n)
B0 y 0
(m,0) yj
=
(m,n)
+ B1 y N j Y
(m,n)
U
(xj−k+1 ; xj−k ) B0 + B1
k=1
j = 1, 2, . . . N,
,
= β, "
(1)
(m,n−1)
= Y (m)j (xj ; y j−1 ) − U (1) (xj ; xj−1 )y j−1
N Y
#−1 U
(1)
(xN−k+1 ; xN−k )
β,
k=1
n = 1, 2, . . . , (2.47)
The corresponding error estimate is
(m,n)
− u
y
0,∞,b ωh
≤ M (q2n + hm ) ,
(2.48)
def
where q2 = q + M h < 1. Proof. From the equations (2.38) we deduce successively (m)
= U (1) (x1 ; x0 )y 0
(m)
= U (1) (x2 ; x1 ) U (1) (x1 ; x0 )y 0 + U (1) (x2 ; x1 ) (m) (m) (m) × Y (m)1 (x1 ; y 0 ) − U (1) (x1 ; x0 )y 0 + Y (m)2 (x2 ; y 1 )
y1 y2
(m)
(m)
(m)
(m)
− U (1) (x2 ; x1 )y 1 .. .
(m)
+ Y (m)1 (x1 ; y 0 ) − U (1) (x1 ; x0 )y 0 ,
61
62
Chapter 2. 2-point difference schemes for systems of ODEs Thus (m) yj
j Y
=
(m)
U (1) (xj−k+1 ; xj−k )y 0
k=1
+
j j−i X Y
(m) (m) U (1) (xj−k+1 ; xj−k ) Y (m)i (xi ; y i−1 ) − U (1) (xi ; xi−1 )y i−1 .
i=1 k=1
(2.49) Substituting
(m) yN
N Y
B0 + B1
U
(1)
into the boundary conditions (2.39) we get (m) (xN−k+1 ; xN−k ) y 0
k=1
= −B1
−i N N X Y
(m) (m) U (1) (xN −k+1 ; xN −k ) Y (m)i (xi ; y i−1 ) − U (1) (xi ; xi−1 )y i−1 + β.
i=1 k=1
(2.50) Let us show that the matrix in square brackets on the left-hand side of (2.50) is regular. Here and in the following we use the inequality
(1)
U (xj ; xj−1 ) ≤ kU (xj ; xj−1 )k + U (1) (xj ; xj−1 ) − U (xj ; xj−1 )
(2.51)
≤ exp(c1 hj ) + M h2j which can be easily derived using the estimate (2.44). We have N Y
B0 + B1 U (1) (xN −k+1 ; xN −k ) − B0 + B1 U (1; 0) k=1 N N Y Y
= B1 U (1) (xN−k+1 ; xN−k ) − U (xN −k+1 ; xN −k ) k=1
k=1
N
X = B1 U (xN ; xN −j+1 ) U (1) (xN−j+1 ; xN −j ) − U (xN −j+1 ; xN −j ) j=1
×
N Y
U (1) (xN−i+1 ; xN−i )
i=j+1
≤ kB1 k
N X j=1
≤ M h,
N Y exp (1 − xN−j+1 )c1 M h2N −j+1 exp (c1 hN −i+1 ) + M h2N −i+1 i=j+1
(2.52)
2.3. Implementation of the 2-point EDS that is N Y
B0 + B1 U (1) (xN −k+1 ; xN −k ) − B0 + B1 U (1; 0) < 1
(2.53)
k=1
for h0 small enough. Here we have used the inequality N Y
exp[(c1 hN −i+1 ) + M h2N −i+1 ] ≤ exp(c1 ) 1 + M h2
N −j
i=j+1
≤ exp(c1 ) exp[M (N − j)h2 ] ≤ exp(c1 ) exp[M1 h] ≤ exp(c1 ) + M h. def
Since Q = B0 + B1 U (1; 0) is nonsingular, it follows from (2.53) that the inverse " B0 + B1
N Y
#−1 U (m) (xN−k+1 ; xN−k )
k=1
exists and due to (2.52) the following estimate holds: N Y
−1
B0 + B1 U (1) (xN −k+1 ; xN −k ) B1 k=1 N Y
−1 ≤ B0 + B1 U (1) (xN−k+1 ; xN−k )
(2.54)
k=1
− B0 + B1
N Y
U (xN −k+1 ; xN −k )
−1 −1
B1 + Q B1
k=1
≤ M h + kHk . Moreover, from (2.49) and (2.50) we have (m)
yj
=−
j Y
−1 N Y U (1) (xj−k+1 ; xj−k ) B0 + B1 U (1) (xN−k+1 ; xN−k )
k=1
× B1
k=1 −i N N X Y
(m) (m) U (1) (xN−k+1 ; xN−k ) Y (m)i (xi , y i−1 ) − U (1) (xi ; xi−1 )y i−1
i=1 k=1
+
j j−i X Y
(m) (m) U (1) (xj−k+1 ; xj−k ) Y (m)i (xi ; y i−1 ) − U (1) (xi ; xi−1 )y i−1
i=1 k=1
+
j Y k=1
U
(1)
(xj−k+1 ; xj−k ) B0 + B1
N Y k=1
!−1 U
(1)
(xN −k+1 ; xN−k )
β,
63
64
Chapter 2. 2-point difference schemes for systems of ODEs or (m)
yj
(m)
N =
where (m)
N
=
N X
(1) (m) (m) (m,0) Gh (xj , xi ) Y (m)i (xi ; y i−1 ) − U (1) (xi ; xi−1 )y i−1 + y j ,
i=1 (1)
and Gh (x, ξ) is the Green’s function of the problem (2.38), (2.39) given by (1) Gh (xj , xi )
=−
j Y
" U (1) (xj−k+1 ; xj−k ) B0 + B1
k=1
N Y
#−1 U (1) (xN −k+1 ; xN −k )
k=1
0, (1) j−i × B1 U (xN −k+1 ; xN −k ) + Q (1) U (xj−k+1 ; xj−k ), k=1 N −i Y
i ≥ j, i<j.
k=1
The estimates (2.51) and (2.54) imply (
(1)
G (xj , xi ) ≤ h
exp c1 (1 + xj − xi ) H + M h,
exp c1 (xj − xi ) 1 + H exp (c1 ) + M h,
i ≥ j, (2.55) i<j.
Now we use Banach’s Fixed Point Theorem (see Theorem 1.1). First of all we show (m) b that the operator
(m)
(0) ) − u (x )
j k=0 ≤ (K + M h)
N X hi exp (−c1 xi−1 ) exp c1 (1 + xj ) kHk i=1
+ exp (c1 xj )
j X
hi exp (−c1 xi−1 ) + M h + M h
i=1
≤ K + M h exp (c1 xj ) xj + kHk exp (c1 ) + M h + M h ≤ r(xj ) + M h ≤ r(xj ) + ∆. (m)
It remains to be shown that
2.3. Implementation of the 2-point EDS
(m)
< (xj , {us }N ) − <(m) (xj , {v s }N ) s=0 s=0 0,∞,b h h ω
h
≤ exp (c1 ) 1 + kHk exp (c1 ) + M h
1 × max Y (m)j (xj ; uj−1 ) − Y (m)j (xj ; v j−1 ) 1≤j≤N hj
−U (1) (xj ; xj−1 )(uj−1 − v j−1 )
≤ exp (c1 ) 1 + kHk exp (c1 ) + M h (q + M h) ku − vk0,∞,b ω
h
≤ q2 ku − vk0,∞,b , ω h
def
N b where {uk }N k=0 , {v k }k=0 ∈ Ω(ω h , r(·) + ∆) and q2 = [q + M h] < 1 provided that (m) h0 is small enough. This means that
(m,n)
y − y (m)
(m) def
(m)
zj
(m)
= yj
The error z j
0,∞,b ωh
≤
q2n (r(1) + ∆). 1 − q2
(2.56)
− uj of the solution of the scheme (2.38), (2.39) satisfies (m)
(m)
− U (1) (xj ; xj−1 )z j−1 = ψ (m) (xj ; y j−1 ),
j = 1, 2, . . . , N, (2.57)
(m) B0 z 0
+
(m) B1 z N
= 0, (m)
where the residuum (the approximation error) ψ (m) (xj ; y j−1 ) is given by (m)
ψ (m) (xj ; y j−1 ) = Y (m)j (xj ; u(xj−1 )) − Y j (xj ; u(xj−1 )) (m) (m) + Y (m)j (xj ; y j−1 ) − Y (m)j (xj ; u(xj−1 )) − U (1) (xj ; xj−1 )(y j−1 − u(xj−1 )) . We reformulate problem (2.57) in the equivalent form
(m)
zj
=
N X i=1
(1)
(m)
Gh (xj , xi )ψ (m) (xi ; y i−1 ).
65
66
Chapter 2. 2-point difference schemes for systems of ODEs Then (2.55) and Lemma 2.7 imply N
(m)
X
(m)
ψ (xi ; y (m) )
z j ≤ exp (c1 ) 1 + kHk exp (c1 ) + M h i−1 i=1
≤ exp (c1 ) 1 + kHk exp (c1 ) + M h
N X
(m) hi (L + hi M ) z i−1 × M hm + i=1
≤ q2 z (m)
+ M hm . 0,∞,b ωh
The last inequality yields
(m)
z ≤ M hm . 0,∞,b ωh
(2.58)
Now, from (2.56) and (2.58) we get the error estimate for the method (2.48):
(m,n)
y − u 0,∞,b ≤ y (m,n) − y (m) 0,∞,b + y (m) − u 0,∞,b ≤ M (q2n + hm ) ω ω ω h
h
h
which completes the proof.
Remark 2.1. Using the matrix U (1) (see formula (2.43)) instead of the fundamental matrix U in (2.47) preserves the order of accuracy but reduces the computational costs significantly.
Above we have shown that the system of nonlinear equations which represents the TDS can be solved by the modified fixed point iteration. In practice, however, Newton’s method is used due to its higher convergence rate. Newton’s method applied to the system (2.38), (2.39) has the form (m,n−1)
5
(m,n) yj
∂Y (m)j (xj ; y j−1 − ∂u
(m,n)
B0 5 y 0 (m,n)
yj
(m,n−1)
= yj
(m,n)
+ B1 5 y N
(m,n)
5 y j−1
(m,n−1)
= Y (m)j (xj ; y j−1
(m,n−1)
) − y j−1
,
= 0,
(m,n)
+ 5y j
)
,
j = 0, 1, . . . , N,
n = 1, 2, . . . , (2.59)
where (m)
(m)
∂Φ(xj−1 , y j−1 ; hj ) ∂Y (m)j (xj ; y j−1 ) = I + hj ∂u ∂u " # (m) ∂f (xj−1 , y j−1 ) − A(xj−1 ) + O h2j = I + hj ∂u
2.3. Implementation of the 2-point EDS (m)
and ∂f (xj−1 , y j−1 )/∂u is the Jacobian of the vector function f (x, u) at the point (m) (xj−1 , y j−1 ).
Setting (m,n−1)
∂Y (m)j (xj ; y j−1 ) , ∂u the system (2.59) can be written in the equivalent form def
Sj =
(m,n)
(B0 + B1 S) 5 y 0
(m,n)
= −B1 ϕ,
y0
(m,n−1)
= y0
(m,n)
+ 5y 0
,
(2.60)
where def
def
S = SN SN −1 · · · S1 ,
ϕ = ϕN , (m,n−1)
ϕj = Sj ϕj−1 + Y (m)j (xj ; y j−1
ϕ0 = 0, (m,n−1)
) − y j−1
,
j = 1, 2, . . . , N.
The coefficient matrix of the system (2.60) has the dimension d × d. It can be solved by the Gaussian elimination with O(N ) flops since the dimension d is small in comparison with N . After that the solution of the system (2.59) is computed recursively by (m,n)
5 yj
(m,n)
yj
(m,n)
= Sj Sj−1 · · · S1 5 y 0 (m,n−1)
= yj
(m,n)
+ 5y j
,
+ ϕj ,
j = 1, 2, . . . , N.
When using Newton’s method or a quasi-Newton method, the problem of (m,0) , j = 1, 2, . . . , N , arises. If the choosing an appropriate initial approach y j original problem contains a natural parameter, say λ, and for some values of this parameter the solution is known or can be easily obtained, one can try to continue the solution along this parameter (see, e.g., [2], pp. 344–353). Thus, let us suppose that our problem can be written in the generic form u0 (x) + A(x)u = h(x, u; λ),
x ∈ (0, 1),
B0 u(0) + B1 u(1) = β.
(2.61)
We assume that for each λ ∈ [λ0 , λk ] an isolated solution u(x; λ) exists and depends smoothly on λ. Moreover, let us suppose that for λ = λ0 a solution of (2.61) is known or can easily be determined. If the problem (2.61) does not contain a natural parameter, then we can introduce such a parameter λ artificially by forming the homotopy function def
h(x, u; λ) = λf (x, u) + (1 − λ)f 1 (x), where f 1 (x) is a given function for which the problem (2.61) has a (known) unique solution. Obviously, for λ = 0 we have the linear BVP u0 (x) + A(x)u = f 1 (x),
x ∈ (0, 1),
B0 u(0) + B1 u(1) = β,
67
68
Chapter 2. 2-point difference schemes for systems of ODEs with the known solution, and for λ = 1 we obtain our original nonlinear problem (2.61). The m-TDS for the problem (2.61) is of the form (m)
yj
(m)
(λ) = Y (m)j (xj ; y j−1 ; λ),
(m)
j = 1, 2, . . . , N,
(m)
B0 y 0 (λ) + B1 y N (λ) = β. The differentiation with respect to λ leads to the BVP (m)
(m)
(m)
(m)
∂Y (m)j (xj ; y j−1 ; λ) ∂Y (m)j (xj ; y j−1 ; λ) dy j (λ) dy j (λ) = + , dλ ∂λ ∂u dλ j = 1, 2, . . . , N, (m)
(m)
B0
dy (λ) dy 0 (λ) + B1 N = 0, dλ dλ
which can be further reduced to the following system of linear algebraic equations def (m) (m) for the unknown function v 0 (λ) = dy 0 (λ)/dλ: ˜ v (m) (λ) = −B1 ϕ, ˜ [B0 + B1 S] 0 where (m)
def S˜ = S˜N S˜N −1 · · · S˜1 ,
def S˜j =
∂Y (m)j (xj ; y j−1 ; λ) , ∂u
j = 1, 2, . . . , N, (m)
def
˜ = ϕ ˜N, ϕ
˜ 0 = 0, ϕ (m)
Moreover, for v j (m)
vj
˜ j−1 + ˜ j = S˜j ϕ ϕ (m)
(λ) = dy j
∂Y (m)j (xj ; y j−1 ; λ) , ∂λ
j = 1, 2, . . . , N.
(λ)/dλ we have the formulas (m)
(λ) = S˜j S˜j−1 · · · S˜1 v 0
˜ j, +ϕ
j = 1, 2, . . . , N.
The initial approach for Newton’s methods can now be obtained by (m,0)
yj
(m)
(λ + 4λ) = y j
(m)
(λ) + 4λv j
(λ),
j = 0, 1, . . . , N.
(2.62)
The following three examples illustrate the behaviour of our m-TDS. Example 2.4. Let us apply the m-TDS to Troesch’s test problem (2.24). It takes the generic form (2.61) with ! ! ! 0 −1 0 u1 , , A= , h(x, u; λ) = u= u2 0 0 λ sinh(λu1 )
2.3. Implementation of the 2-point EDS B0 =
1
! 0
0
0
,
B1 =
0
0
1
0
!
0 ,
β=
1
! .
The corresponding m-TDS is (m)
(m)
= Y (m)j (xj ; y j−1 ),
yj
(m)
(m)
B0 y 0
+ B1 y N
j = 1, 2, . . . N,
= β,
where the following Taylor series IVP-solver has been used: Y
(m)j
(m) (xj ; y j−1 )
=
(m) y j−1
+
(m) hj g(xj−1 , y j−1 )
(m) m X hpj dp Y j (x; y j−1 ) + p! dxp p=2
,
x=xj−1
(m) yj
(m) y1,j , = (m) y2,j
g(x, u) = −Au + f (x, u) =
!
−u2 λ sinh(λu1 )
We now show how an algorithm for the computation of Y developed which is based on the formula in (2.63). Setting (m) p j def 1 d Y1 (x, y j−1 ) Y1,p = , p! dxp
(m)j
.
(m) (xj ; y j−1 )
(2.63) can be
x=xj−1
we get (m) j 1 dp Y (x; y j−1 ) p! dxp
=
x=xj−1
!
Y1,p (p + 1)Y1,p+1
(m) j 1 dp Y (x; y j−1 ) and it can be seen that in order to compute the vectors p! dxp
x=xj−1 (m)
it is sufficient to find Y1,p as the Taylor coefficients of the function Y1j (x; y j−1 ) at the point x = xj−1 . This function satisfies the IVP (m)
d2 Y1j (x; y j−1 ) (m) j = λ sinh λ Y (x; y ) , 1 j−1 dx2 (m)
(m)
Y1j (xj−1 ; y j−1 ) = y1,j−1 , Let
(m) dY1j (xj−1 ; y j−1 )
dx
(2.64) (m)
= y2,j−1 .
∞ X def (m) r˜(x) = sinh λ Y1j (x; y j−1 ) = (x − xj−1 )i Ri . i=0
Substituting this series into the ODE (2.64) we get Y1,i+2 =
λRi . (i + 1)(i + 2)
69
70
Chapter 2. 2-point difference schemes for systems of ODEs Setting def
(m)
p˜(x) = λ Y1j (x; y j−1 ) =
∞ X
(x − xj−1 )i Pi ,
i=0
we have def
p(x)) = s˜(x) = cosh (˜
r˜(x) = sinh (˜ p(x)) ,
∞ X
(x − xj−1 )i Si .
i=0
Performing the simple transformations p) p˜0 = p˜0 s˜, r˜0 = cosh(˜
s˜0 = sinh(˜ p) p˜0 = p˜0 r˜
and applying formula (8.20b) from [31], we obtain the recurrence equations i−1
Ri =
i−1
1X (i − k)Sk Pi−k , i
1X (i − k)Rk Pi−k , i
Si =
k=0
Pi = λY1,i ,
i = 1, 2, . . . ,
k=0
i = 2, 3, . . . .
The corresponding initial conditions are (m)
P0 = λ y1,j−1 ,
(m)
(m)
P1 = λ y2,j−1 ,
(m)
R0 = sinh (λ y1,j−1 ),
S0 = cosh (λ y1,j−1 ).
The Jacobian is given by (m) 0 1 ∂Y (m)j (xj ; y j−1 ) = I + hj (m) ∂u λ2 cosh(λ y1,j−1 ) 0 +
m X hpj p=2
p!
Y1,p,u1
Y1,p,u2
(p + 1)Y1,p+1,u1
(p + 1)Y1,p+1,u2
! ,
with u=
u1 , u2
(m)
def
Y1,p,ul =
∂Y1,p (xj ; y j−1 ) , ∂ul
l = 1, 2.
(m)
Since the functions Y1,ul (x; y j−1 ) =
∂Y1 (x; y j−1 ) satisfy the ODEs ∂ul
d2 Y1,u1 = λ2 cosh(˜ p(x))(1 + Y1,u1 ), dx2
d2 Y1,u2 = λ2 cosh(˜ p(x))((x − xj−1 ) + Y1,u2 ), dx2
(m)
def
2.3. Implementation of the 2-point EDS we get the following recursive algorithm for the computation of Y1,p,ul : Y1,i+2,u1
" # i X λ2 Si + = Y1,k,u1 Si−k , (i + 1)(i + 2)
i = 2, 3, . . . ,
k=2
Y1,2,u1 = Y1,i+2,u2
λ2 S0 , 2
Y1,3,u1 =
λ2 S1 , 6
" # i X λ2 Si−1 + = Y1,k,u2 Si−k , (i + 1)(i + 2)
i = 2, 3, . . . ,
k=2
Y1,2,u2 = 0,
Y1,3,u2 =
λ2 S0 . 6
(m)
For the vector ∂Y (m)j (xj ; y j−1 ; λ)/∂λ we have the formula (m)
∂Y (m)j (xj ; y j−1 ; λ) ∂λ !
0 = hj
(m)
(m)
+
(m)
sinh(λ y1,j−1 ) + λ y1,j−1 cosh(λ y1,j−1 )
m X hpj p=2
p!
!
Y1,p,λ (p + 1)Y1,p+1,λ
,
where (m)
def
Y1,p,λ =
∂Y1,p (xj ; y j−1 ; λ) . ∂λ (m)
def
(m)
j Taking into account that Y1,λ (xj ; y j−1 ; λ) = ∂Y1j (xj ; y j−1 ; λ)/∂λ satisfies the ODE j d2 Y1,λ j = λ2 cosh(˜ p(x))Y1,λ + sinh(˜ p(x)) + p˜(x) cos(˜ p(x)), dx2 we obtain for Y1,p,λ the recurrence relation
Y1,i+2,λ
" # i i X X 1 2 λ = Y1,k,λ Si−k + Ri + Pk Si−k , (i + 1)(i + 2) k=2
Y1,2,λ =
1 (R0 + P0 S0 ) , 2
Y1,3,λ =
i = 2, 3, . . . ,
k=0
1 (R1 + P0 S1 + P1 S0 ) . 6
Considering the behavior of the solution, we choose the grid b h = xj = exp(jα/N ) − 1 , j = 0, 1, 2, . . . , N , α < 0, ω exp(α) − 1
(2.65)
which becomes dense for x → 1 . The step sizes of this grid are given by h1 = x1 and hj+1 = hj exp(α/N ), j = 1, 2, . . . , N − 1. Note that the use of the formula
71
72
Chapter 2. 2-point difference schemes for systems of ODEs hj = xj − xj−1 , j = 1, 2, . . . , N , for j → N and |α| large enough, leads to a large absolute roundoff error since some xj , xj−1 lie very close together. The a posteriori Runge estimator was used to arrive at the right boundary with a given tolerance ε. Thus, the tolerance was assumed to be achieved if the following inequality is fulfilled:
(m) (m)
dy2N dyN
(m) (m)
−
yN − y2N
dx dx
! ≤ (2m −1) ε. max , (m)
dy (m)
max y , 10−5
ˆ 2N 0,∞,ω ¯ h max 2N , 10−5
dx ˆ 0,∞,ω ¯h
(m)
Otherwise a doubling of the number of the grid points has been made. Here, yN denotes the solution of the difference scheme of the order of accuracy m on the (m) grid {x0 , . . . , xN }, and y2N denotes the solution of the same scheme on the finer grid {x0 , . . . , x2N }. The difference scheme (represented by a system of nonlinear algebraic equations) was solved by Newton’s method with the stopping criterion
(m,n) (m,n−1)
dy
dy
y (m,n) − y (m,n−1)
−
dx dx max ≤ 0.5 ε, ,
dy (m,n)
max y (m,n) , 10−5
−5 ˆ
0,∞,ω ¯ h max dx , 10
ˆ 0,∞,ω ¯h where n denotes the number of iterations. Setting the unknown value of the first derivative of the exact solution of (2.24) at the left boundary x = 0 equal to s, this solution can be written in the form (see, for example [79]) s · sn(λx, k) s2 2 , k2 = 1 − , (2.66) u(x; s) = arcsinh λ 2 · cn(λx, k) 4 where sn(λx, k) and cn(λx, k) denote the elliptic Jacobi functions. The parameter s is the solution of the equation s · sn(λ, k) 2 arcsinh = 1. λ 2 · cn(λ, k) For example, for λ = 5 one gets s = 0.457504614063 · 10−1 , and for λ = 10 one gets s = 0.35833778463 · 10−3 . Using the continuation method (2.62) we have computed numerical solutions of Troesch’s problem (2.24) for λ ∈ [1, 62] using different step sizes 4λ. The numerical results for λ = 10, 20, 30, 40, 45, 50 and 61 computed with the difference scheme of order of accuracy 7 on the grid (2.65) with α = −26 are given in Table 2.1. Here, CPU denotes the time required by the processor to solve the sequence of Troesch’s problems beginning with λ = 1 and using the step size ∆λ until the parameter λ reaches the value given in the table.
2.3. Implementation of the 2-point EDS λ
ε
N
u0 (0)
u(1)
CPU (sec)
10
10−7
512
3.5833778 · 10−4
1
0.02
20
10−7
512
1.6487734 · 10−8
1
0.04
30
10
−7
512
−13
7.4861194 · 10
1
0.07
40
10−7
512
3.3987988 · 10−17
1
0.10
45
10
−7
512
−19
1
0.11
50
10
−7
−21
1.5430022 · 10
1
0.15
61
10−7
2.5770722 · 10−26
1
6.10
2.2902091 · 10
1024 262144
Table 2.1: Numerical results for the 7-TDS and 4λ = 4
The numerical results for λ = 61 and 62 computed on the same grid as before with the difference scheme of order of accuracy 10 are given in Table 2.2. λ
ε
N
Error
CPU (sec)
61
10−6
65536
0.860 · 10−5
3.50
61
10−8
131072
0.319 · 10−7
7.17
62
−6
10
262144
0.232 · 10
−5
8.01
62
10−8
262144
0.675 · 10−8
15.32
Table 2.2: Numerical results for the 10-TDS and 4λ = 2
The real deviation from the exact solution is measured by
(m) dy
du
− (m) y −u def
dx dx , . Error = max
dy (m)
max |y (m) |, 10−5
ˆ , 10−5 0,∞,ω ¯ h max dx
ˆ 0,∞,ω ¯h The numerical experiments were carried out with double precision in Fortran. To calculate the Jacobi functions sn(x, k) and cn(x, k) for large |x| the computer algebra tool Maple VII with Digits=80 was used. Then, the exact ˆ h and two approximations for the parameter s, namely solution on the grid ω s = 0.2577072228793720338185 · 10−25 satisfying |u(1, s) − 1| < 0.17 · 10−10 , and s = 0.948051891387119532089349753 · 10−26 satisfying |u(1, s) − 1| < 0.315 · 10−15 were calculated.
73
74
Chapter 2. 2-point difference schemes for systems of ODEs To compare the results we have solved problem (2.24) with the multiple shooting code RWPM (see e.g. [34] or [84]). For the parameter values λ = 10, 20, 30, 40 the numerical IVP-solver used was the code RKEX78, an implementation of the Dormand-Prince embedded Runge-Kutta method 7(8), whereas for λ = 45 we have used the code BGSEXP, an implementaton of the well-known Bulirsch-StoerGragg extrapolation method. In Table 2.3 we denote by m the number of the automatically determined shooting points, NFUN is the number of ODE calls, it the number of iterations and CPU the CPU time used. λ
m
it
NFUN
u0 (0)
u(1)
CPU (sec)
10
11
9
12641
3.5833779 · 10−4
1.0000000
0.01
20
11
13
34425
1.6487732 · 10−8
0.9999997
0.02
−13
1.0000008
0.05
30
14
16
78798
7.4860938 · 10
40
15
24
172505
3.3986834 · 10−17
0.9999996
0.14
530085
−19
1.0000003
0.30
45
12
31
2.2900149 · 10
Table 2.3: Numerical results for the code RWPM
One can see that the accuracy characteristics of our m-TDS method is better than that of the code RWPM. Besides, RWPM fails for values λ ≥ 50. Example 2.5. As a next example let us consider the following BVP for a system of stiff ODEs (see [78]) u01 = λ u03 =
(u3 − u1 )u1 , u2
u02 = −λ(u3 − u1 ),
0.9 − 103 (u3 − u5 ) − λ(u3 − u1 )u3 , u4
u04 = λ(u3 − u1 ),
u05 = −100(u5 − u3 ),
u1 (0) = u2 (0) = u3 (0) = 1,
u4 (0) = −10,
(2.67) 0 < x < 1, u3 (1) = u5 (1).
To solve this problem numerically we have applied the 6-TDS given by (6)
yj
(6)
= Y (6)j (xj ; y j−1 ),
j = 1, 2, . . . N, (2.68)
(6)
(6)
B0 y 0 + B1 y N = β, (6)
where Y (6)j (xj ; y j−1 ) is the numerical solution of the IVP (2.25) computed by a 7-stage explicit Runge-Kutta method (2.41) of order m = 6. The corresponding parameters are given in Table 2.4 (see also [7]).
2.3. Implementation of the 2-point EDS
c
A bT
⇐⇒
0
0
1 2 2 3 1 3 5 6 1 6
1 2 2 9 7 36 35 − 144 1 − 360 41 − 260
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
4 9 2 9 55 − 36 11 − 36 22 13
13 200
0
1 12 35 48 1 − 8 43 156
15 8 1 2 118 − 39
1 10 32 195
0
0
80 39
0
11 40
11 40
4 25
4 25
13 200
−
Table 2.4: Butcher matrix for the RK method used in Example 2.5 (6)
In Newton’s method (2.59) we have approximated the matrix ∂Y (6)j (xj , y j−1 )/∂u in the following way: (6)
(6)
∂g(xj−1 , y j−1 ) ∂Y (6)j (xj ; y j−1 ) ≈ I + hj . ∂u ∂u
(2.69)
Numerical results on the equidistant grid (1.1) obtained by the 6-TDS are given in Table 2.5. ε
NFUN
CPU (sec)
10−4
24500
0.01
10−6
41440
0.02
−8
77140
0.04
10
Table 2.5: Numerical results for the TDS with m = 6 (λ = 100)
We have also solved problem (2.67) by the multiple shooting code RWPM so that a comparison can be made. As an IVP-solver we used the semi-implicit extrapolation method SIMPR. A start trajectory was generated by solving the problem with
75
76
Chapter 2. 2-point difference schemes for systems of ODEs λ = 0. The numerical results are given in Table 2.6, where CP U ∗ denotes the cumulated time for the solution of the linear problem (λ = 0) and the solution of (2.67) with λ = 100. ε
NFUN
CPU∗
10−4
15498
0.02
−6
10
31446
0.04
10−8
52374
0.06
Table 2.6: Numerical results for the code RWPM (λ = 100)
Example 2.6. Our third and final example is the periodic BVP (see [70]) u00 = − 0.05u0 − 0.02u2 sin x + 0.00005 sin x cos2 x − 0.05 cos x − 0.0025 sin x, x ∈ (0, 2π), u(0) = u(2π),
0
(2.70)
0
u (0) = u (2π).
It has the exact solution u(x) = 0.05 cos x. Numerical results on the equidistant grid (1.1) obtained by the 6-TDS (2.68)– (2.69) with ! ! ! (6) y 1 0 −1 0 0 1,j (6) , B0 = yj = , B1 = , β= , (6) 0 1 0 −1 0 y2,j g(x, u) =
−u2 −0.05(u2 + cos x) + sin x(0.00005 cos2 x − 0.02u21 − 0.0025)
are given in Table 2.7.
2.4
!
A posteriori error estimation and automatic grid generation
There are various strategies to construct an algorithm which automatically generates a grid for which the norm of the error of the approximate solution is smaller than a
2.4. A posteriori error estimation and automatic grid generation ε
N
NFUN
Error
10−4
64
5712
0.453 · 10−8
10−6
64
5712
0.453 · 10−8
10−8
128
12432
0.267 · 10−11
Table 2.7: Numerical results for the TDS with m = 6
given tolerance ε. We will shortly discuss only the following two possibilities based on the theory developed in the previous sections. The first possibility is the classical technique which has been proposed by Carl Runge. The estimate (2.48) via standard considerations leads to the following a posteriori h-h/2-strategy to generate an approximation with an error whose norm (m) is smaller than a given tolerance ε (for a fixed m). Let y N be the solution of the (m) difference scheme of order of accuracy m on the grid {x0 , . . . , xN }, and y 2N the solution of this scheme on the grid {x0 , . . . , x2N }. Then, the inequality
(m) (m) ≤ (2m − 1)ε (2.71)
y N − y 2N 0,∞,b ωh (m)
(m)
implies ky 2N − {u(xj )}2N ≤ ε. The approximation y N j=0 k0,∞,b ωh improved by applying the Richardson extrapolation formula (m)
(m)
(m)
b N (xj ) = y 2N (x2j ) + y
can be further
(m)
y 2N (x2j ) − y N (xj ) , 2m − 1
j = 0, 1, . . . , N.
(2.72)
The main drawback of this strategy is that the grid for the difference scheme (2.38), (2.39) can be equidistant or quasi-uniform only. The second approach to automatic grid generation is based on the following simple idea. Due to (2.48) the difference scheme (2.38), (2.39) has order of accuracy m which is an integer number. In order to obtain TDS of the orders m and m + 1 by our method one should solve the IVPs (2.25) by one-step methods (2.40) of the corresponding orders. A reasonable and practical way to do that is to use two representatives of orders m and m + 1 from a family of embedded RungeKutta methods (e. g. Runge-Kutta-Fehlberg, Runge-Kutta Verner or Runge-Kutta Dormand-Prince family; see [8]). An a posteriori error estimate for the difference scheme (2.38), (2.39) can be determined by computing an approximation y (m) with the Runge-Kutta method of order m and an approximation y (m+1) with the Runge-Kutta method of order m + 1. The requested a posteriori error estimate is
now y (m) − y (m+1) 0,∞,ˆω since it holds that h
(m)
− y (m+1)
y
0,∞,b ωh
= y (m) − u
+ O hm+1 . 0,∞,b ωh
(2.73)
77
78
Chapter 2. 2-point difference schemes for systems of ODEs
Hence, provided that y (m) − y (m+1) 0,∞,b < ε, we can compute an approxiωh mate solution of problem (2.1) by the difference scheme (2.38), (2.39) whose error is bounded by a prescribed tolerance ε. ˆ¯ h and computes an The following algorithm generates a non-equidistant grid ω approximate solution of the IVPs (2.25) on this grid. The estimate (2.48) and the usual relation for an IVP-solver of order of accuracy m, Y j (xj , y j−1 ) − Y (m)j (xj , y j−1 ) = ψ j (xj , y j−1 )hm+1 + O(hm+2 ), j j
(2.74)
guarantee that the error of the approximate solution of the BVP (2.1) is within a given tolerance ε, provided that for each j ∈ {0, . . . , N } the solutions of the IVPs (2.25) are given with tolerance hj ε. Using the well-known idea of step-size control by embedded Runge-Kutta methods we can then construct a non-equidistant grid ˆ¯ h such that the IVPs (2.25) are solved with tolerance hj ε. Having in mind the ω IVPs (2.25), the error of a Runge-Kutta method of order m is is given by (2.74) too, i.e., for the embedded Runge-Kutta methods of orders m and m + 1 we have the following a posteriori estimate (neglecting the terms of order O(hm+1 )) j Y (m+1)j (xj , y j−1 ) − Y (m)j (xj , y j−1 ) ≈ ψ j (xj , y j−1 )hm+1 . j
(2.75)
Thus if the condition Y (m)j (xj , y j−1 ) − Y (m+1)j (xj , y j−1 ) < hj ε is satisfied, then the solutions of the IVPs can be determined on the interval [xj−1 , xj ] within the prescribed tolerance. If this is not the case the actual step-size is halved. A doubling of the step-size hj changes the essential term of the error as follows: 2m+1 ψ j (xj , y j−1 )hm+1 . j
(2.76)
If the approximate solutions could be determined on the previous subinterval with the prescribed error tolerance, then it would be possible to double the step-size of the next subinterval. In that case the formula (2.76) should be applied. A detailed description of the step-size control by embedded Runge-Kutta methods can be found in the book [35]. To simplify the presentation, the Runge-Kutta code which is based on a pair of Runge-Kutta methods of orders l and l + 1 and controls the step-size by the embedding principle is denoted by RK(l)(l + 1).
2.4. A posteriori error estimation and automatic grid generation ˆ¯ N ,TOL,m,h1 ,RK(l)(l+1), A(x),f ,u) Algorithm AG (ω Input: An error tolerance TOL, the order of accuracy m of the TDS, an initial step-size h1 , a Runge-Kutta code RK(l)(l + 1), the problem data A(x), f as well as the initial values y j−1 for the IVPs (2.25). ˆ Output: A non-equidistant grid ω ¯ N on which the numerical solution of (2.25), (l)
Y (l)j (xj , y j−1 ) l = m, m + 1,
ˆ¯ N , xj ∈ ω
j = 1, . . . , N,
is determined with the given tolerance hj TOL. 1) Set j := 0, x0 := 0. 2) Set j := j + 1. 3) Solve the IVPs (2.25) on the interval [xj−1 , xj ] using RK(m)(m + 1) and compute
e := Y (m)j (xj , y j−1 ) − Y (m+1)j (xj , y j−1 ) . 4) if e > hj TOL then begin hj := hj /2; go to Step 3 end. 5) Set xj := xj−1 + hj . 6) if xj < 1 then begin if 2m+1 e ≤ hj TOL then hj+1 := 2hj else hj+1 := hj ; go to Step 2 end. 7) Set N := j. 8) if xN > 1 then begin hN := 1 − xN −1 ; xN := 1; Solve the IVPs (2.25) on the interval [xN −1 , xN ] using RK(m)(m + 1) end. 9) Stop. The estimation (2.48) is the basis of the following algorithm. Given the grid (m+1) ˆ , j = 1, . . . , N , of the BVP (2.1) by the ω ¯ N , it computes an approximation y j m-TDS (2.38), (2.39).
79
80
Chapter 2. 2-point difference schemes for systems of ODEs ˆ Algorithm A(y (m+1) ,ω ¯ N ,TOL,m,h1 , RK(l)(l + 1),A(x),f ) ˆ¯ N , an error tolerance TOL, the order of accuracy m of the Input: The grid ω TDS, an initial step-size h1 , a family of embedded Runge-Kutta codes RK(l)(l +1) as well as the problem data A(x) and f of problem (2.1). ˆ Output: The solution y (m+1) (xj ), xj ∈ ω ¯ N , of the BVP (2.1) with an error smaller than the given tolerance TOL. 1) Set εit := 0.25 TOL. 2) Determine the starting values u(0) (x). ˆ 3) Compute the grid ω ¯ N and the numerical solution of (2.25) using the algorithm ˆ¯ N ,TOL,m,h1 ,RK(m)(m + 1),A(x),f , u(0) ). AG(ω Set n := 0,
l := m.
4) Set n := n + 1,
m := l.
(l,n)
5) Determine y 0 by solving the system of linear algebraic equations (2.60) (l,n) and compute y j , j = 1, . . . , N , by the second formula in (2.60). (l)
6) Compute Y (l)j (xj , y j−1 ), j = 1, . . . , N , by the Runge-Kutta code RK(l)(l+ 1).
7) If y (l,n) − y (l,n−1) 0,∞,ˆω > εit then go to Step 4. h
8) If l = m then begin n := 0, l := m + 1, go to Step 4 end.
9) If y (m+1) − y (m) 0,∞,ˆω > TOL then begin h
(m+1)
Find new starting values by interpolating the values y i , i = 0, . . . , N , using the formula h i 1 (m+1) (m+1) yi (x − xi−1 ) + y i−1 (xi − x) , u(0) (x) = xi − xi−1 xj−1 ≤ x ≤ xj ,
i = 1, . . . , N,
go to Step 3 end. 10) Stop. At the end of this section we will present the results of some experiments with the above algorithms. Let us consider again Troesch’s test problem (see Examples 2.2 and 2.4). We have varied the value of the input variable TOL and considered the question of how a reduction of TOL influences the grid and the accuracy of the numerical solution. The corresponding results for Troesch’s problem with
2.4. A posteriori error estimation and automatic grid generation λ = 10 are given in Table 2.8, where TOL is the prescribed tolerance, N is the number of grid points, NFUN denotes the number of calls of the function f (x, u) and Error is the difference between the numerical and the exact solution (2.66) with s = 0.35833778463 · 10−3 . TOL −4
10 10−6
N
NFUN
Error
72 124
11323 19435
0.143 · 10−5 0.538 · 10−7
Table 2.8: Numerical results for the TDS using a RK7(8)
Similar results have been obtained for the periodic BVP (2.70) (see Example 2.6) and are given in Table 2.9. TOL −6
10 10−8
N
NFUN
Error
19 19
4940 6422
0.163 · 10−7 0.420 · 10−9
Table 2.9: Numerical results for the TDS using a RK7(8)
81
83
Chapter 3
Three-point difference schemes for monotone second-order ODEs Our greatest weakness lies in giving up. The most certain way to succeed is always to try just one more time. Thomas Alva Edison (1847–1931) In this chapter we consider nonlinear monotone ODEs with Dirichlet boundary conditions. Using a non-equidistant grid we construct an EDS on a three-point stencil and prove the existence and uniqueness of its solution. Moreover, on the basis of the EDS we develop an algorithm for the construction of a three-point TDS of rank m ¯ = 2 [(m + 1)/2], where m ∈ N is a given natural number and [·] denotes the entire part of the argument in brackets. We prove the existence and uniqueness of the solution of the TDS and determine the order of accuracy. Numerical examples are given which confirm the theoretical results.
3.1
Existence and uniqueness of a solution
Let us consider the BVP du du d k(x) = −f x, u, , dx dx dx
x ∈ (0, 1),
u(0) = µ1 ,
u(1) = µ2 ,
(3.1)
where k(x), f (x, u, ξ) are given functions and µ1 µ2 are given numbers. I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_3, © Springer Basel AG 2011
83
84
Chapter 3. 3-point difference schemes for scalar ODEs Note that problem (3.1) can be transformed into a system of first-order ODEs but this system is no longer monotone. The EDS for systems of first-order ODEs with a small Lipschitz constant has been constructed and analyzed in [27, 55]. In this section we develop and justify an EDS and the corresponding TDS of an arbitrary given order of accuracy for BVPs with an arbitrary Lipschitz constant. We say that a function u(x) ∈ W21 (0, 1) is a weak solution of problem (3.1), if ◦ u(x) − ϕ(x) ∈ W21 (0, 1) = v(x) v(x) ∈ W21 (0, 1), v(0) = v(1) = 0 ◦
and for all v(x) ∈ W21 (0, 1) the identity Z1
du dv dx = k(x) dx dx
0
Z1
du v(x)dx f x, u, dx
0
holds, where ϕ(x) is a function from W21 (0, 1) which satisfies the boundary conditions. Sufficient conditions for the existence of a weak solution of problem (3.1) are given in the next theorem. Theorem 3.1 Let the following assumptions be satisfied: 0 < c1 ≤ k(x) ≤ c2
for all x ∈ [0, 1], k(x) ∈ Q1 [0, 1],
def
fuξ (x) = f (x, u, ξ) ∈ Q0 [0, 1] for all u, ξ ∈ R, def
fx (u, ξ) = f (x, u, ξ) ∈ C(R2 ) for all x ∈ [0, 1],
(3.2) (3.3) (3.4)
(3.5) |f (x, u, ξ) − f0 (x)| ≤ c(|u|)[g(x) + |ξ|] for all x ∈ [0, 1], u, ξ ∈ R, 2 2 [f (x, u, ξ) − f (x, v, η)] (u − v) ≤ c3 |u − v| + |ξ − η| for all x ∈ [0, 1], u, v, ξ, η ∈ R, 0 ≤ c3 <
π2 c1 . +1
π2
(3.6) (3.7)
Then, the boundary value problem (3.1) has a unique solution u(x) ∈ W21 (0, 1), du ∈ C[0, 1]. with u(x), k(x) dx Here c(t) is a continuous function, f0 (x) ∈ L2 (0, 1), g(x) ∈ L1 (0, 1), Qp [0, 1] is the class of functions having p piece-wise continuous derivatives and a finite number of discontinuity points of first kind, and c1 , c2 , c3 are some real constants. Proof. Due to (3.3) and (3.5) the function f (x, u, ξ) satisfies the Carath´eodory conditions (see Definition 1.12 and belongs to the class L1 (0, 1) (see e.g. [18, p.113]).
3.1. Problem setting ◦
For all u(x) ∈ W21 (0, 1) and v(x) ∈ W21 (0, 1) we can now define the operator def
Z1
(A (x, u) , v) =
du dv dx − k(x) dx dx
Z1
0
du ˜ v(x)dx, f x, u, dx
0
where def f˜(x, u, ξ) = f (x, u, ξ) − f0 (x).
Note that the function u(x) ∈ W21 (0, 1) is absolutely continuous on [0, 1], and its du generalized derivative is equal to the classical derivative almost everywhere on dx du ∈ L2 (0, 1). [0, 1] (see e.g. [18, p.74]). Thus, u(x) ∈ C[0, 1] and dx Let us show that the operator A (x, u) is bounded. Actually, taking into account the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8), the conditions (3.2) and (3.5), the inequality c(|u|) ≤ C2 for all x ∈ [0, 1] as well as kvkC[0,1] ≤ C1 kvk1,2,(0,1) for all v(x) ∈ W21 (0, 1) (see e.g. [18, p.112]) we obtain A (x, u) , v 1 2 1/2 Z1 2 1/2 Z1 Z du du dv dx k(x) dx dx + kvkC[0,1] f˜ x, u, ≤ dx dx dx 0
0
0
h i
≤ c2 kuk1,2,(0,1) + C1 f˜ 0,1,(0,1) kvk1,2,(0,1) i h ≤ (c2 + C1 C2 ) kuk1,2,(0,1) + C1 C2 kgk0,1,(0,1) kvk1,2,(0,1) , where def
kukC[0,1] = max |u(x)|, x∈[0,1]
def
Z1
kuk0,1,(0,1) =
|u(x)|dx, 0
def
Z1
kuk0,2,(0,1) =
1/2 2
(u(x)) dx
,
0
def
Z1
kuk1,2,(0,1) =
2
Z1
(u(x)) dx+ 0
du dx
2
1/2 dx
.
0
If un tends to u0 in W21 (0, 1), then (see [18, p.113]): dun du0 → f˜ x, u0 , , f˜ x, un , dx dx
k(x)
dun du0 → k(x) dx dx
in L1 (0, 1).
85
86
Chapter 3. 3-point difference schemes for scalar ODEs ◦
Thus, for all v(x) ∈ W21 (0, 1) we have 1 Z Z1 dv du du n n dx − f˜ x, un , v(x)dx lim (A (x, un ) , v) = lim k(x) n→∞ n→∞ dx dx dx 0
Z1 k(x)
=
0
du0 dv dx − dx dx
0
Z1
du0 v(x)dx = (A (x, u0 ) , v) , f˜ x, u0 , dx
0
i.e. the operator A (x, u) is semi-continuous. Let us show that the operator A (x, u) is strongly monotone. Due to the conditions (3.2), (3.6) and the inequality
◦
dv π
≥ √ kvk1,2,(0,1) for all v(x) ∈ W21 (0, 1),
dx 1 + π2 0,2,(0,1) we obtain (A (x, u) − A (x, v) , u − v) Z1 =
du dv − k(x) dx dx
2 dx
0
−
Z1 dv du − f˜ x, v(x), [u(x) − v(x)] dx f˜ x, u(x), dx dx 0
du dv 2 2
− − c3 ku − vk1,2,(0,1) ≥ c1 dx dx 0,2,(0,1) ≥
π2 2 2 ku − vk1,2,(0,1) = c4 ku − vk1,2,(0,1) , c − c 1 3 1 + π2
◦ π2 1 c −c > 0, and u−v ∈ W 1 3 2 (0, 1). 1 + π2 From the strong monotonicity follows the coerciveness of A (x, u).
where in accordance with (3.7) we have c4 =
Thus, the Browder-Minty Theorem (see Theorem 1.3) guaranties the existence of a unique solution u ∈ W21 (0, 1) of problem (3.1). Since du = k(x) dx
Zx du dt + C f t, u, dt 0
du is the dx undefined Lebesgue integral, this expression is absolutely continuous on [0,1] and du ∈ C[0, 1] is shown. the claim k(x) dx almost everywhere on [0,1] (see, e.g. [18, p.134]), i.e. the flux k(x)
3.2. Existence of a three-point EDS
3.2
Existence of a three-point EDS
Let us cover the interval (0, 1) by a non-equidistant grid ω ˆ h which includes the discontinuity points (with respect to x) of the functions k(x) and f (x, u, ξ). We denote the set of discontinuity points by ρ and choose N so that ρ ⊆ ω ˆ h . At the discontinuity points the solution of problem (3.1) should satisfy the continuity conditions du du = k(x) for all xi ∈ ρ. u(xi − 0) = u(xi + 0), k(x) dx x=xi −0 dx x=xi +0 We introduce the following BVPs on (small) subintervals: dYαj (x, u) dYαj (x, u) d j k(x) = −f x, Yα (x, u), , dx dx dx Yαj (xj−2+α , u) = u(xj−2+α ),
x ∈ ejα , (3.8)
Yαj (xj−1+α , u) = u(xj−1+α ),
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2.
Now the following auxiliary result can be proved. Lemma 3.1 Let the assumptions of Theorem 3.1 be satisfied. Then each of the problems (3.8) has a unique solution Yαj (x, u) ∈ W21 (ejα ) with Yαj (x, u), k(x)
dYαj (x, u) ∈ C(¯ ejα ) dx
and for the solution u(x) of problem (3.1) it holds that u(x) = Yαj (x, u),
x ∈ e¯jα ,
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2. (3.9)
Proof. We introduce the nonlinear operator Ajα x, Yαj by the equation Ajα x, Yαj , v xj−1+α Z
dY j (x, u) dv(x) − k(x) α dx dx
= xj−2+α
where
xj−1+α Z
dY j (x, u) v(x)dx, f˜ x, Yαj (x, u), α dx
xj−2+α
def f˜(x, u, ξ) = f (x, u, ξ) − f0 (x). ◦
This definition makes sense for all Yαj (x, u) ∈ W21 (ejα ) and v(x) ∈ W21 (ejα ), where ◦
def
W21 (ejα ) =
v(x) v(x) ∈ W21 (ejα ), v(xj−2+α ) = 0, v(xj−1+α ) = 0, α = 1, 2 .
87
88
Chapter 3. 3-point difference schemes for scalar ODEs A function Yαj (x, u) is a weak solution of (3.8) if ◦
◦
Yαj (x, u) − ϕjα (x) ∈ W21 (ejα ),
Ajα x, Yαj , v = (f0 , v)
for all v(x) ∈ W21 (ejα ),
where ϕjα (x) is a given function from W21 (ejα ) which satisfies the boundary conditions. Let us show that the operator Ajα x, Yαj is bounded. Using (1.12), formulas (3.2) and (3.5), as well as the estimates c(|Yαj (x, u)|) ≤ C2
for all x ∈ e¯jα
and for all v(x) ∈ W21 (ejα ),
kvkC[xj−2+α ,xj−1+α ] ≤ C1 kvk1,2,eα we obtain
Ajα
1/2 1/2 xj−1+α xj−1+α 2 Z Z 2 j dY (x, u) dv k(x) α x, Yαj ≤ dx dx dx dx xj−2+α
xj−2+α
xj−1+α Z
j
f˜ x, Y j (x, u), dYα (x, u) dx α
dx
+ kvkC(¯ejα ) xj−2+α
h i
≤ c2 Yαj 1,2,ej + C1 f˜ 0,1,ej k v k1,2,ejα α
α
i h
≤ (c2 + C1 C2 ) Yαj 1,2,ej + C1 C2 k g k0,1,ejα k v k1,2,ejα . α
The semi-continuity of Ajα x, Yαj follows from (3.5). More precisely, in [18, j j p.113]) it is shown that Yαn (x, u) → Yα0 (x, u) in W21 (ejα ) implies dY j (x, u) j f˜ x, Yαn (x, u), αn dx
−→
f˜
j dYαn (x, u) dx
−→
k(x)
k(x)
j x, Yα0 (x, u),
j dYα0 (x, u) dx
j (x, u) dYα0 dx
◦
in the space L1 (ejα ). Thus, for all v(x) ∈ W21 (ejα ) it holds that
! ,
3.2. Existence of a three-point EDS
j lim Ajα x, Yαn ,v
n→∞
xZ j−1+α dY j (x, u) dv(x) dx k(x) αn = lim n→∞ dx dx xj−2+α
j dY (x, u) j v(x)dx (x), αn f˜ x, Yαn dx
xj−1+α Z
− xj−2+α xj−1+α Z
dY j (x, u) dv(x) dx − k(x) α0 dx dx
= xj−2+α
xj−1+α Z
j (x, u), x, Yα0
f˜
j (x, u) dYα0 dx
! v(x)dx
xj−2+α
j = Ajα x, Yα0 ,v , i.e. the operator Ajα x, Yαj is semi-continuous. Let us show that the operator Ajα x, Yαj (x, u) is also strongly monotone. Due to (3.2), (3.6) and to the inequality
◦
dv π 1 j
√ j for all v(x) ∈ W (e ), ≥ kvk 2 α 1,2,eα
dx 1 + π2 0,2,ejα we have Ajα x, Yαj (x, u) − Ajα x, Y˜αj (x, u) , Yαj (x, u) − Y˜αj (x, u) xj−1+α Z
k(x)
= xj−2+α
−f
2 dYαj (x, u) dY˜αj (x, u) − dx − dx dx
xj−1+α Z
f
x, Yαj (x, u),
dYαj (x, u) dx
xj−2+α
dY˜ j (x, u) j Yα (x, u) − Y˜αj (x, u) dx x, Y˜αj (x, u), α dx
2
dYαj
2 dY˜αj
− − c3 Yαj − Y˜αj 1,2,ej ≥ c1
dx α dx 0,2,ejα
j
π2
Yα − Y˜αj 2 j ≥ c − c 1 3 2 1,2,eα 1+π
2 = c4 Yαj − Y˜αj 1,2,ej . α Now, the strong monotonicity of Ajα x, Yαj (x, u) follows from its coerciveness. Thus due to the Browder-Minty Theorem (see Theorem 1.3) there exist a unique solution of each of the problems (3.8).
89
90
Chapter 3. 3-point difference schemes for scalar ODEs We have xj−1+α Z
dY j (x, u) k(x) α = dx
f
dY j (t, u) dt + C, t, Yαj (t, u), α dt
xj−2+α
dYαj (x, u) ∈ C(¯ ejα ). dx Since Yαj (x, u) is the solution of (3.8), this function is also the solution of problem (3.1) which is unique due to the assumptions of our lemma. which means that k(x)
Now we are in a position to prove the next statement. Theorem 3.2 Let the assumptions of Theorem 3.1 be satisfied. Then there exists the following three-point EDS for problem (3.1): du x ˆ , x∈ω ˆ h , u(0) = µ1 , u(1) = µ2 . (3.10) (aux¯ )xˆ = −T f ξ, u(ξ), dξ This EDS has a unique solution u(x) for all x ∈ ω ˆ h which coincides with the solution of problem (3.1) at the points of the grid ω ˆ h . Here the divided differences ux¯,j and uxˆ,j are defined as in Definition 1.3, and def
a(xj ) =
1 j V (xj ) hj 1
−1 ,
def V1j (x) =
Zx
dx , k(x)
xj−1
−1 def Tˆxj (w(ξ)) = ~j V1j (xj )
Zxj
xj−1
V1j (ξ)w(ξ)dξ
def V2j (x) =
xZj+1
dx , k(x)
x
+
−1 ~j V2j (xj )
xZj+1
V2j (ξ)w(ξ)dξ.
xj
(3.11) The function u(x) on the right-hand side of (3.10) is defined by (3.9) and depends only on u(xj ), j = 0, 1, . . . , N .
Proof. Applying the operator Tˆ xj to both sides of equation (3.1) we obtain Tˆxj
d dξ
du du k(ξ) = −Tˆ xj f ξ, u(ξ), , dξ dξ
3.2. Existence of a three-point EDS where Tˆ xj
d dξ
du k(ξ) dξ
x h i−1 Z j du d j j k(ξ) dξ = ~j V1 (xj ) V1 (ξ) dξ dξ xj−1 x h i−1 Zj+1 du d j j k(ξ) dξ. + ~j V2 (xj ) V2 (ξ) dξ dξ xj
The integration by parts implies du d k(ξ) = (aux¯ )xˆ,j , Tˆ xj dξ dξ which together with (3.9) proves existence of the EDS (3.10). In order to show uniqueness of the solution of (3.10) we consider the operator du def Ah (x, u) = −(aux¯ )xˆ − Tˆ x f ξ, u(ξ), dξ which is defined in the finite-dimensional space L2 (ˆ ωh ) equipped with the scalar products X X def def def ~(ξ)u(ξ)v(ξ), (u, v)ωˆ + = h(ξ)u(ξ)v(ξ), ω ˆ h+ = ω ˆ h ∪ xN , (u, v)ωˆ h = h
+ ξ∈ˆ ωh
ξ∈ˆ ωh
and the norms def
def
1/2
1/2
kuk0,2,ωˆ h = (u, u)ωˆ h , kuk0,2,ˆω+ = (u, u)ωˆ + , h h 1/2 def 2 2 . kuk1,2,ωˆ h = kuk0,2,ˆωh + kux¯ k0,2,ˆω+ h
Due to condition (3.5) the operator Ah (x, u) is continuous. Let us show that the operator Ah (x, u) is strongly monotone. Taking into account the equality X
ˆξ
~(ξ)T (w(η))g(ξ) =
Z1 gˆ(η)w(η)dη =
j=1x j−1
ξ∈ω ˆh
where def
gˆ(η) = g(xj ) we have
x N Zj X
V1j (η) V1j (xj )
+ g(xj−1 )
gˆ(η)w(η)dη, 0
V2j−1 (η) V1j (xj )
,
xj−1 ≤ η ≤ xj ,
91
92
Chapter 3. 3-point difference schemes for scalar ODEs
Tˆ x f (η, u(η), uη (η)) − f (η, v(η), vη (η)) , u − v
ω ˆh
X
=
~(ξ)Tˆ ξ f (η, u(η), uη (η)) − f (η, v(η), vη (η))
u(ξ) − v(ξ)
ξ∈ω ˆh
Z1 =
u ˆ(η) − vˆ(η) f (η, u(η), uη (η)) − f (η, v(η), vη (η)) dη,
0 def
where the functions u(x) and v(x) are defined by (3.9) and zη (η) = Then using (3.6), we have Tˆ x f (η, u(η), uη (η)) − f (η, v(η), vη (η)) , u − v Z1
dz(η) . dη
ω ˆh
u(η) − v(η) f (η, u(η), uη (η)) − f (η, v(η), vη (η)) dη
= 0
Z1
u ˆ(η) − vˆ(η) − u(η) + v(η) (f (η, u(η), uη (η)) − f (η, v(η), vη (η))) dη
+ 0
Z1 ≤−
d dη
d u(η) − v(η) dη
u ˆ(η) − vˆ(η)
k(η)
d u(η) − v(η) dη dη
0
Z1 +
d k(η) u(η) − v(η) dη + c3 ku − vk21,2,(0,1) dη
0
=−
Zxj N X
u ˆ(η) − vˆ(η)
j=1 x j−1
Z1 −
k(η)
d dη
k(η)
d u(η) − v(η) dη dη
2 d u(η) − v(η) dη + c3 ku − vk21,2,(0,1) . dη
0
Since Zxj N X
u ˆ(η) − vˆ(η)
j=1 x j−1
=−
Zxj N X j=1 x j−1
d dη
k(η)
d u(η) − v(η) dη dη
k(η) (ˆ uη − vˆη ) (uη − vη ) dη = − a(ux¯ − vx¯ ), ux¯ − vx¯
+ ω ˆh
,
3.2. Existence of a three-point EDS we have Tˆx f (η, u, uη ) − f (η, v, vη ) , u − v
ω ˆh
≤ a(ux¯ − vx¯ ), ux¯ − vx¯ )ωˆ + h
(3.12)
du dv 2 2
− − c1 + c3 ku − vk1,2,(0,1) . dx dx 0,2,(0,1)
◦
dv π
Due to the inequality ≤√ kvk1,2,(0,1) with v(x) ∈ W21 (0, 1), as
dx 1 + π2 0,2,(0,1) well as the condition (3.7), we have (Ah (x, u) − Ah (x, v) , u − v)ωˆ h = a(ux¯ − vx¯ ), ux¯ − vx¯ ωˆ + − Tˆx (f (η, u, uη ) − f (η, v, vη )) , u − v
ω ˆh
h
du dv 2
− ≥ c1 − c3 ku − vk21,2,(0,1)
dx dx 0,2,(0,1)
2
du dv 1 + π2
− ≥ c4 , π 2 dx dx 0,2,(0,1) def
where c4 =
π2 c1 − c3 > 0. The inequality 1 + π2
Z1
k(η)
d u ˆ(η) − vˆ(η) − u(η) + v(η) dη
2 dη
0
=−
N X
2
Z1
hj a(xj )(ux¯,j − vx¯,j ) +
j=1
k(η)
d u(η) − v(η) dη
2 dη
0
= − a(ux¯ − vx¯ , ux¯ − vx¯ ωˆ + h
du dv du dv − , − + k ≥ 0, dx dx dx dx ωˆ h
implies
du dv 2 1
≥ (a(ux¯ − vx¯ ), ux¯ − vx¯ )ωˆ + .
dx − dx h c 2 0,2,(0,1) Thus (Ah (x, u) − Ah (x, v), u − v)ωˆ h ≥
1 + π 2 c4 1 + π 2 c4 c1 kux¯ − vx¯ k2ωˆ + a(ux¯ − vx¯ ), ux¯ − vx¯ ωˆ + ≥ 2 h h π c2 π2 c2
≥8
1 + π 2 c4 c1 ku − vk20,2,ˆωh , π2 c2
(3.13)
93
94
Chapter 3. 3-point difference schemes for scalar ODEs i.e. the operator Ah (x, u) is strongly monotone. This yields (see e.g. [82, p.461]) the uniqueness of the solution of the equation Ah (x, u) = 0. Lemma 3.2 Let the assumptions of Theorem 3.1 be satisfied and |f (x, u, ξ)−f (x, v, η)| ≤ L { |u − v| + |ξ − η| } for all x ∈ (0, 1), u, v, ξ, η ∈ R. Then the iteration method Bh
u(n) − u(n−1) + Ah x, u(n−1) = 0, τ
u(n) (0) = µ1 , u(0) (x) =
u(n) (1) = µ2 ,
n = 1, 2, . . . ,
def
def
Ah (x, u) = Bh u − Tˆx (f (ξ, u(ξ), uξ (ξ))) ,
1 + π 2 c4 τ = τ0 = π 2 c2 def
L 1+ c1
1 c22 + 2 c21
1/2
converges in the space HBh and the error estimate
(n)
u − u ≤ q n u(0) − u Bh
holds with
s def
q =
c4 =
(3.14)
V2 (x) V1 (x) µ1 + µ2 , V1 (1) V1 (1)
Bh u = −(aux¯ )xˆ ,
where
x∈ω ˆh,
1−
√ !−2 2L 1+ c4
(3.15) Bh
1 + π 2 c4 τ0 , π 2 c2
π2 c1 − c3 > 0 and 1 + π2
1/2
kukBh = (Bh u, u)ωˆ h .
Proof. It follows from (3.13) that (Ah (x, u) − Ah (x, v) , u − v)ωˆ h ≥
1 + π 2 c4 2 ku − vkBh . π 2 c2
(3.16)
We have Ah (x, u) − Ah (x, v), z
= (Bh u − Bh v, z)ωˆ h −
ω ˆh
X ξ∈ωh
~(ξ)T ξ (f (η, u(η), uη (η)) − f (η, v(η), vη (η))) z(ξ)
3.2. Existence of a three-point EDS Z1 = (Bh u − Bh v, z)ωˆ h −
(f (η, u(η), uη (η)) − f (η, v(η), vη (η))) zˆ(η)dη. 0
Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) we can now deduce (Ah (x, u) − Ah (x, v), z)ωˆ h ≤ ku − vkBh kzkBh Z1
1/2 Z1
2
(f (η, u(η), uη (η)) − f (η, v(η), vη (η))) dη
+
2
1/2
(ˆ z (η)) dη
0
0
≤ ku − vkBh kzkBh +
√ 2Lku − vk1,2,(0,1) kˆ z k0,2,(0,1) .
Since V1j (x) ≤ V1j (xj ), V2j−1 (x) ≤ V1j (xj ) for all x ∈ [xj−1 , xj ], we have 2 kˆ z k0,2,(0,1)
#2 Zxj " N X V1j (x) V2j−1 (x) zj j = dx + zj−1 j V1 (xj ) V1 (xj ) j=1 xj−1
≤2
Zxj N X j=1 x j−1
" zj2
V1j (x)
#2
V1j (xj )
" 2 + zj−1
V2j−1 (x) V1j (xj )
#2
2
dx ≤ 4 kzk0,2,ˆωh
(3.17)
and #2
2 Zxj " N X
dˆ
z 1 1
≤ (zj − zj−1 ) dx
dx k(x) V1j (xj ) 0,2,(0,1) j=1 xj−1
≤
N c22 X hj zx2¯,j c21 j=1
(3.18) =
c22 c21
2
kzx¯ k0,2,ˆω+ . h
Let us now show that ku − vk1,2,(0,1) ≤
1 c22 + 2 c21
√ 1/2 2L 1+ kux¯ − vx¯ k0,2,ωˆ + . h c4
We write u(x) = u ˜(x) + u ˆ(x), x ∈ e¯jα , and reduce the problem d du du k(x) = −f x, u(x), , dx dx dx u(xj−2+α ) = uj−2+α ,
x ∈ ejα ,
u(xj−1+α ) = uj−1+α ,
α = 1, 2,
(3.19)
95
96
Chapter 3. 3-point difference schemes for scalar ODEs to d˜ u d˜ u dˆ u d k(x) = −f x, u ˜(x) + u ˆ(x), + , dx dx dx dx u ˜(xj−2+α ) = 0,
u ˜(xj−1+α ) = 0,
x ∈ ejα ,
α = 1, 2. ◦
Considering (3.2), (3.6) and using a Lipschitz condition for all u ˜(x), v˜(x) ∈ W21 (ejα ), we get
2
d˜ u d˜ π2 v 2
− k˜ u − v ˜ k ≤ c ≤ c1 1 1,2,ejα 1 + π2 dx dx 0,2,ejα xj−1+α Z
f
=
x, u ˜(x) + u ˆ(x),
u d˜ u dˆ + dx dx
xj−1+α Z
k(x)
v d˜ u d˜ − dx dx
2 dx
xj−2+α
xj−2+α
dˆ v d˜ v + (˜ u(x) − v˜(x)) dx − f x, v˜(x) + vˆ(x), dx dx xj−1+α Z
=
f
u d˜ u dˆ + x, u ˜(x) + u ˆ(x), dx dx
−f
dˆ u d˜ v + (˜ u(x) − v˜(x))dx x, v˜(x) + u ˆ(x), dx dx
xj−2+α
xj−1+α Z
f
+
x, v˜(x) + u ˆ(x),
dˆ u d˜ v + dx dx
xj−2+α
−f
≤ c3 k˜ u−
dˆ v d˜ v + (˜ u(x) − v˜(x))dx x, v˜(x) + vˆ(x), dx dx
v˜k21,2,ej α
xj−1+α Z
f
+
dˆ u d˜ v + x, v˜(x) + u ˆ(x), dx dx
xj−2+α
2 1/2 dˆ v d˜ v + − f x, v˜(x) + vˆ(x), dx dx dx
xj−1+α Z
(˜ u(x) − v˜(x))2 dx
xj−2+α
√ ≤ 2Lkˆ u − vˆk1,2,ejα k˜ u − v˜k1,2,ejα + c3 k˜ u − v˜k21,2,ej
α
which implies
√ k˜ u − v˜k1,2,ejα ≤
2L kˆ u − vˆk1,2,ejα . c4
1/2
3.2. Existence of a three-point EDS 1 kux¯ k20,2,ˆω+ it follows that h 8 √ 2L kˆ u − vˆk1,2,(0,1) ≤ 1+ c4
From the inequalities (3.17), (3.18) and kuk20,2,ˆωh ≤ u − v˜k1,2,(0,1) + kˆ u − vˆk1,2,(0,1) ku − vk1,2,(0,1) ≤ k˜
√ 1/2 2L c22 2 2 4ku − vk0,2,ˆωh + 2 kux¯ − vx¯ k0,2,ˆω+ ≤ 1+ h c4 c1 ≤
1 c22 + 2 c21
1/2
√ 2L 1+ kux¯ − vx¯ k0,2,ˆω+ . h c4
With (3.17), (3.19) we have (Ah (x, u) − Ah (x, v) , z)ωˆ h √ ≤ ku − vkBh kzkBh + 2 2L ≤ ku − vkBh kzkBh + L ≤
L 1+ c1
1 c22 + 2 c21
1 c22 + 2 c21
1 c22 + 2 c21
√ 1/2 2L 1+ kux¯ − vx¯ k0,2,ωˆ + kzk0,2,ˆωh h c4 √ 2L 1+ kux¯ − vx¯ k0,2,ˆω+ kzx¯ k0,2,ˆω+ h h c4 !
1/2
√ 1/2 2L 1+ c4
ku − vkBh kzkBh .
def
Setting z = Bh−1 (Ah (x, u) − Ah (x, v)), we obtain √ ! 1/2 2L L 1 c22 −1 + 1+ ku − vkBh kBh (Ah (x, u) − Ah (x, v))kBh ≤ 1 + c1 2 c21 c4 (3.20) and further due to formulas (3.20), (3.16) we have Ah (x, u) − Ah (x, v) , Bh−1 (Ah (x, u) − Ah (x, v)) ωˆ h
≤
1+
L c1
π 2 c2 ≤ 1 + π 2 c4
1 c22 + 2 c21
√ 1/2 2L 1+ c4
L 1+ c1
1 c22 + 2 c21
!2
2
ku − vkBh
√ !2 1/2 2L 1+ c4
× (Ah (x, u) − Ah (x, v) , u − v)ωˆ h . The results in [74, p.502] imply the convergence of the iteration process (3.14) in HBh as well as the estimate (3.15). ◦
Note that the norms of the spaces HBh and W21 (ˆ ωh ) are equivalent, i.e., γ1 kuk1,2,ˆωh ≤ kukBh ≤ γ2 kuk1,2,ˆωh ,
97
98
Chapter 3. 3-point difference schemes for scalar ODEs and we can now prove the following statement. Lemma 3.3 Let the assumptions of Lemma 3.2 be satisfied. Then the iteration process (3.14) converges and in addition to (3.15) the following estimate holds:
du(n) du
(n)
k
− k ≤ M − u ≤ M qn ,
u
dx dx 0,2,ωˆ¯ h 1,2,ˆ ωh where def
kuk0,2,ωˆ¯ h =
N−1 X
j=1
1/2 1/2 N 1 X 1 1 ~j u2j + h1 u20 + hN u2N = hj (u2j + u2j−1 ) . 2 2 2 j=1
Proof. Using the relations Zxj du du 1 d j k(ξ) dξ k = a u + V (ξ) j x ¯,j 1 dx x=xj dξ dξ V1j (xj ) xj−1
= aj ux¯,j −
1 V1j (xj )
Zxj
V1j (ξ)f
du dξ, ξ, u(ξ), dξ
xj−1
Zxj du du 1 d j−1 k(ξ) dξ k = a u − V (ξ) j x ¯,j 2 dx x=xj−1 dξ dξ V2j−1 (xj−1 ) xj−1
= aj ux¯,j +
1 V1j (xj )
Zxj
V2j−1 (ξ)f
du dξ, ξ, u(ξ), dξ
xj−1
the inequality (a + b)2 ≤ 2(a2 + b2 ), as well as the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) and a Lipschitz condition we obtain
du(n) du
k
− k
dx dx 0,2,ωˆ¯ h ( =
N 1X (n) hj aj ux¯,j − aj ux¯,j 2 j=1 −
1 V1j (xj )
Zxj xj−1
2 du du(n) − f ξ, u(ξ), dξ V1j (ξ) f ξ, u(n) (ξ), dξ dξ
3.2. Existence of a three-point EDS N 1X (n) + hj aj ux¯,j − aj ux¯,j 2 j=1 +
V1j (xj )
( ≤
Zxj
1
2
N X
V2j−1 (ξ)
2 )1/2 du du(n) (n) − f ξ, u(ξ), dξ f ξ, u (ξ), dξ dξ
xj−1
2 (n) hj aj ux¯,j − aj ux¯,j
j=1
+
N X
−2 hj V1j (xj )
j=1
Zxj
du(n) V1j (ξ) f ξ, u(n) (ξ), dξ
xj−1
2 X N −2 du dξ + −f ξ, u(ξ), hj V1j (xj ) dξ j=1 Zxj ×
V2j−1 (ξ)
2 )1/2 du du(n) (n) − f ξ, u(ξ), dξ f ξ, u (ξ), dξ dξ
xj−1
( ≤
2
N X
(n) hj aj ux¯,j
− aj ux¯,j
j=1
2
+
N X j=1
Zxj hj xj−1
2 2 V1j (ξ) + V2j−1 (ξ) j 2 dξ V1 (ξ) + V2j−1 (ξ)
2 )1/2 Zxj (n) du du − f ξ, u(ξ), f ξ, u(n) (ξ), dξ × dξ dξ xj−1
( ≤
2
N X
(n) 2 hj a2j ux¯,j − ux¯,j
j=1
+L
2
N X j=1
2 )1/2 Zxj du(n) du (n) − hj dξ u (ξ) − u(ξ) + dξ dξ xj−1
√
(n)
≤ 2c2 ux¯ − ux¯
+ 0,2,ˆ ωh
+
√
2L u(n) − u
. 1,2,(0,1)
99
100
Chapter 3. 3-point difference schemes for scalar ODEs Now, the inequality (3.19) and Lemma 3.1 imply
du(n) du
k
dx − k dx ˆ 0,2,ω ¯h √ 1/2
√ √ 2L 1 c22
(n)
+ 2 1+ 2 c2 + 2L
u − u 2 c1 c4 1,2,ω ˆh
= M1 u(n) − u ≤ M qn . ≤
1,2,ˆ ωh
3.3
Implementation of the three-point EDS
First let us note that the following relation holds: α+1
Zxj
(−1)
Vαj (ξ)f
du dξ = (−1)α Vαj (xj )Zjα (xj , u) + Yαj (xj , u) − uβ , ξ, u(ξ), dξ
xβ
where we have again used the abbreviation def
β = j + (−1)α ,
(3.21)
and Yαj (x, u) and Zαj (x, u), α = 1, 2, are the solutions of the IVPs dYαj (x, u) Zαj (x, u) dZαj (x, u) Zαj (x, u) j = , = −f x, Yα (x, u), , dx k(x) dx k(x) du Yαj (xβ , u) = uβ , Zαj (xβ , u) = k(x) , dx x=xβ j = 2 − α, 3 − α, . . . , N + 1 − α,
x ∈ ejα ,
α = 1, 2, (3.22)
and V¯αj (x) = (−1)α+1 Vαj (x) is the solution of the IVP 1 dV¯αj (x) = , dx k(x) V¯αj (xβ ) = 0,
x ∈ ejα ,
j = 2 − α, 3 − α, . . . , N + 1 − α,
(3.23) α = 1, 2.
Obviously, the right-hand side of the three-point EDS can be represented by ϕ(xj , u) = Tˆ xj (f (ξ, u(ξ), uξ (ξ))) " # 2 j X −1 α j α Yα (xj , u) − uβ . (−1) Zα (xj , u) + (−1) = ~j Vαj (xj ) α=1
(3.24)
3.3. Implementation of the three-point EDS Therefore, there are two possibilities for computing the coefficients of the EDS (3.10) for all xj ∈ ω ˆ h . The first one is based on the solution of the BVPs (3.8), whereas the second exploits the relation (3.24) by integrating the IVPs (3.22), (3.23). These integrations can be realized by the following one-step methods: ¯ (xj , u) = uβ + (−1)α+1 hγ Φ1 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ), Yα(m)j
(3.25)
Zα(m)j (xj , u) = (ku0 )β + (−1)α+1 hγ Φ2 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ),
(3.26)
¯ V¯α(m)j (xj ) = (−1)α+1 hγ Φ3 (xβ , 0, (−1)α+1 hγ ),
(3.27)
where as before
def
γ = j − 1 + α,
(3.28)
Φ1 (x, u, v, h), Φ2 (x, u, v, h) and Φ3 (x, u, h) are the corresponding increment functions and du 0 . (ku )β = k(x) dx x=xβ (m)j ¯
(m)j
Let us assume Zα (xj , u) approximates Zαj (xj , u) with order m and Yα (xj , u), (m)j ¯ ¯ = 2[(m + 1)/2]. V¯α (xj ) approximate Y j (xj , u), V¯ j (xj ), resp., with order m α
α
If k(x) and the right-hand side f (x, u, ξ) are sufficiently smooth, we have ¯ ¯ ¯ Yαj (xj , u) = Yα(m)j (xj , u) + [(−1)α+1 hγ ]m+1 ψαj (xβ , u) + O(hm+2 ), γ
(3.29)
Zαj (xj , u) = Zα(m)j (xj , u) + [(−1)α+1 hγ ]m+1 ψ˜αj (xβ , u) + O(hm+2 ), γ
(3.30)
¯ ¯ ¯ (xj ) + [(−1)α+1 hγ ]m+1 ). ψ¯αj (xβ ) + O(hm+2 V¯αj (xj ) = V¯α(m)j γ
(3.31)
For example, for the Taylor series method we have Φ1 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ) =
u0β
m ¯ (−1)α+1 hγ f (xβ , uβ , u0β ) X [(−1)α+1 hγ ]p−1 dp Yαj (xβ , u) − + , 2 kβ p! dxp p=3
Φ2 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ) m X [(−1)α+1 hγ ]p−1 dp Zαj (xβ , u) = −f xβ , uβ , u0β + , p! dxp p=2 m ¯
Φ3 (xβ , 0, (−1)α+1 hγ ) =
X [(−1)α+1 hγ ]p−1 1 + kβ p=2 p!
dp−1 dxp−1
1 k(x)
and for explicit Runge-Kutta methods we have Φ1 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ) = b1 g1 + b2 g2 + · · · + bs gs ,
x=xβ
,
101
102
Chapter 3. 3-point difference schemes for scalar ODEs Φ2 (xβ , uβ , (ku0 )β , (−1)α+1 hγ ) = b1 g¯1 + b2 g¯2 + · · · + bs g¯s , Φ3 (xβ , 0, (−1)α+1 hγ ) = b1 g˜1 + b2 g˜2 + · · · + bs g˜s , where 1 , k(xβ + ci (−1)α+1 hγ ) # " i−1 X def 0 α+1 gi = (ku )β + (−1) hγ aip g¯p g˜i , def
g˜i =
p=1
def
g¯i = −f
xβ + ci (−1)α+1 hγ , uβ + (−1)α+1 hγ
i−1 X
! aip gp , gi
,
i = 1, 2, . . . , s.
p=1
The following lemma shows the order of the error when the exact solutions of the IVPs are replaced by their numerical approximations. Lemma 3.4 Let 0 < c1 ≤ k(x) ≤ c2 for all x ∈ [0, 1], k(x) ∈ Qm+1 [0, 1], and N f (x, u, ξ) ∈ ∪ Cm [xj−1 , xj ] × R2 . j=1
Suppose that for the numerical one-step methods (3.25)–(3.27) the expansions (3.29)–(3.31) hold. Then ¯ ¯ ¯ Yαj (xj , u) = Yα(m)j (xj , u) + (−1)α+1 hm+1 ψ1γ (xβ , u) + O(hm+2 ), γ γ
Zαj (xj , u) = Zα(m)j (xj , u) + (−1)α+1 hγ
m+1
), ψ˜1γ (xβ , u) + O(hm+2 γ
(3.32) (3.33)
¯ ¯ ¯ Vαj (xj ) = Vα(m)j (xj ) + hm+1 ), ψ¯1γ (xβ ) + O(hm+2 γ γ
(3.34)
j = 2 − α, 3 − α, . . . , N + 1 − α,
(3.35)
α = 1, 2.
Proof. The expansions (3.29), (3.30) imply (m)j ¯
Y1j (xj , u) − Y1
(xj , u)
= Y1j (xj , u) − u(xj − hj ) − hj Φ1 (xj − hj , u(xj − hj ), ku0 |x=xj −hj , hj )
(3.36)
¯ ¯ ψ1j (xj − hj , u) + O(hm+2 ), = hm+1 j j (m)j
Z1j (xj , u) − Z1
(xj , u)
= Z1j (xj , u) − ku0 |x=xj −hj − hj Φ2 (xj − hj , u(xj − hj ), ku0 |x=xj −hj , hj ) (3.37)
3.3. Implementation of the three-point EDS = hm+1 ). ψ˜1j (xj − hj , u) + O(hm+2 j j Moreover, we have (m)j ¯
Y2j (xj , u) − Y2
(xj , u)
= Y2j (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , (ku0 )j+1 , −hj+1 ), (m)j
Z2j (xj , u) − Z2
(xj , u)
= Z2j (xj , u) − (ku0 )j+1 + hj+1 Φ2 (xj+1 , uj+1 , (ku0 )j+1 , −hj+1 ). If we replace hj by −hj+1 in (3.36) and (3.37), and take into account the fact that Y1j (xj , u) = Y2j (xj , u) and Z1j (xj , u) = Z2j (xj , u), we obtain Y2j (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , (ku0 )j+1 , −hj+1 ) j+1 ¯ ¯ = −hm+1 (xj+1 , u) + O(hm+2 j+1 ψ1 j+1 ),
Z2j (xj , u) − (ku0 )j+1 + hj+1 Φ2 (xj+1 , uj+1 , (ku0 )j+1 , −hj+1 ) ˜j+1 (xj+1 , u) + O(hm+2 ). = (−1)m+1 hm+1 j+1 ψ1 j+1 From this the relations (3.32) and (3.33) follow. Analogously to (3.32) one can prove the relation ¯ ¯ ¯ V¯αj (xj ) = V¯α(m)j (xj ) + (−1)α+1 hm+1 ) ψ¯1γ (xβ ) + O(hm+2 γ γ
which due to V¯αj (x) = (−1)α+1 Vαj (x) implies (3.34).
If in the EDS (3.10), (3.11), (3.21) the exact solutions of the corresponding IVPs are approximated by numerical integration methods, the following truncated difference scheme of rank m ¯ (hereinafter referred to as m-TDS) ¯ is obtained: (m) ¯
¯ ¯ ¯ yx¯ )xˆ,j = −ϕ(m) (xj , y (m) ), (a(m)
j = 1, 2, . . . N − 1, (3.38)
(m) ¯
y0
(m) ¯
= µ1 ,
yN
= µ2 ,
where a
(m) ¯
(xj ) =
(m) ¯
ϕ
def
def
(xj , u) =
1 (m) ¯ V (xj ) hj 1 ~−1 j
2 X
−1 ,
α
(−1)
α=1
Zα(m)j (xj , u)
+
(m)j ¯ Yα (xj , u) − (−1)α (m)j ¯ Vα (xj )
uβ
! .
The following statement establishes the accuracy of the approximation of the input data of this difference scheme.
103
104
Chapter 3. 3-point difference schemes for scalar ODEs Lemma 3.5 Under the hypotheses of Lemma 3.4 the following three conditions are satisfied: (m) ¯ a ¯ (xj ) − a(xj ) ≤ M hm , (3.39) ¯ (xj , u) − ϕ(xj , u) ϕ(m) (
hm+1 j
=
+O
ψ1j (x, u)
k(x)
hm+2 j
+ ~j
−
du ψ¯1j (x)k(x)
−
dx
ψ˜1j (x, u)
)
(3.40) x=xj +0
x ˆ
!
hm+2 j+1
for m odd, and ¯ (xj , u) − ϕ(xj , u) ϕ(m) (
=
hm j
+O
k(x)
ψ1j (x, u)
+ hm+1 hm+1 j j+1 ~j
du − ψ¯1j (x)k(x) dx
)
(3.41) x=xj +0
x ˆ
!
for m even. Proof. The estimate (3.39) follows from (3.34) since (m)j ¯
¯ a(m) (xj ) − a(xj ) =
hj [V1j (xj ) − V1
(xj )]
(m)j ¯ V1j (xj )V1 (xj )
¯ = O(hm j ).
In order to prove (3.40), (3.41) we first want to point out that ¯ (xj , u) − ϕ(xj , u) ϕ(m) ( 2 X −1 α (−1) Zα(m)j (xj , u) − Zαj (xj , u) = ~j
(3.42)
α=1 (m)j ¯
+ (−1)α
Yα
(xj , u) − uβ (m)j ¯
Vα
(xj )
−
Yαj (xj , u) − uβ Vαj (xj )
!) ,
Lemma 3.4 and the relations Vαj (xj )
hγ = + O(h2γ ), kβ
Yαj (xj , u)
− uβ = (−1)
α+1
du hγ + O(h2γ ) dx x=xβ
3.3. Implementation of the three-point EDS imply Zα(m)j (xj , u) − Zαj (xj , u) = − (−1)α+1 hγ
m+1
) ψ˜1γ (xβ , u) + O(hm+2 γ
and (m)j ¯
Yα
(xj , u) − (m)j ¯ Vα (xj )
uβ
−
Yαj (xj , u) − uβ Vαj (xj )
γ ¯ ¯ ¯γ (x)k(x) du = −(−1)α+1 hm k(x) ψ (x, u) − ψ + O(hm+1 ). γ γ 1 1 dx x=xβ Now the equation (3.42) takes the form ¯ ϕ(m) (xj , u) − ϕ(xj , u) ( 1 du j+1 j+1 j+1 m+1 ˜ ¯ − ψ1 (x, u) = hj+1 k(x) ψ1 (x, u) − ψ1 (x)k(x) ~j dx x=xj+1
) du j j j − ψ˜1 (x, u) k(x) ψ1 (x, u) − ψ¯1 (x)k(x) − hm+1 j dx x=xj−1 +O
hm+2 + hm+2 j j+1 ~j
(3.43)
! ,
provided that m is odd, and ¯ ϕ(m) (xj , u) − ϕ(xj , u) ( 1 du j+1 j+1 m ¯ = hj+1 k(x) ψ1 (x, u) − ψ1 (x)k(x) ~j dx x=xj+1
−
hm j
) du j j ¯ +O k(x) ψ1 (x, u) − ψ1 (x)k(x) dx x=xj−1
hm+1 + hm+1 j j+1 ~j
(3.44) ! ,
provided that m is even. Due to du j j ¯ k(x) ψ1 (x, u) − ψ1 (x)k(x) dx x=xj−1 du j j ¯ = k(x) ψ1 (x, u) − ψ1 (x)k(x) + O(hj ), dx x=xj ψ˜1j (xj−1 , u) = ψ˜1j (xj , u) + O(hj ), the estimates (3.40), (3.41) follow from (3.43), (3.44).
We can now prove the following statement about the accuracy of the m-TDS. ¯
105
106
Chapter 3. 3-point difference schemes for scalar ODEs Theorem 3.3 Let the assumptions of Theorem 3.1 and Lemma 3.4 be satisfied. Then there def N exists an h0 > 0 such that for all {hj }j=1 with h = max hj ≤ h0 the m-TDS ¯ 1≤j≤N
¯ (3.38) has a unique solution y (m) . Moreover, the error of this solution can be estimated as #1/2 "
2
∗
2 ¯
dy (m) du def (m)
(m)
¯ ¯ ¯
−k − u = y − u + k ≤ M hm ,
y dx dx 1,2,ˆ ωh 0,2,ω ˆh ˆ 0,2,ω ¯h
where ¯ (m) ¯ Y (m)0 ¯ ¯ x0 , y (m) − y0 dy (m) (m)0 2 (m) ¯ x + = Z , y k(x) , 0 2 (m)1 ¯ dx x=x0 V1 (x1 ) ¯ (m)j ¯ ¯ y (m) ¯ xj , y (m) − Y1 dy (m) j (m)j (m) ¯ xj , y + = Z1 , j = 1, 2, . . . , N, k(x) (m)j ¯ dx x=xj V1 (xj ) and the constant M is independent of h.
Proof. Let us consider the operator (m) ¯
def
(m) ¯
Ah (x, u) = Bh
¯ − ϕ(m) (x, u)),
(m) ¯ def
where we have used the abbreviation Bh (3.41) yield (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), u − v
¯ = −(a(m) ux¯ )xˆ . The equations (3.40),
ω ˆh
¯ = a(m) (ux¯ − vx¯ ) , ux¯ − vx¯
¯ ¯ − ϕ(m) (x, u) − ϕ(m) (x, v), u − v ω ˆh
= (Ah (x, u) − Ah (x, v), u − v)ωˆ h
ω ˆh
¯ . + O hm N
Due to (3.13) there exists a h0 > 0 such that for all {hj }j=1 with h ≤ h0 the following estimation holds: (m) ¯ (m) ¯ 2 2 Ah (x, u) − Ah (x, v), u − v ≥ c ku − vkB(m) ≥ 8c˜ c1 ku − vk0,2,ˆωh , ¯ ω ˆh
h
(3.45) ¯ where 0 < c < 1 and 0 < c˜1 ≤ a(m) (x) are constants. (m) ¯
Therefore the operator Ah (x, u) is strongly monotone and for h ≤ h0 the ¯ m-TDS ¯ (3.38) has a unique solution y (m) (x), x ∈ ω ˆ h (see [82, p.461]). def
¯ The error z(x) = y (m) (x) − u(x),
x ∈ ω ˆ h , of the difference scheme (3.38)
3.3. Implementation of the three-point EDS satisfies the problem h i ¯ ¯ ¯ ¯ a(m) (x)zx¯ (x) + ϕ(m) (x, y(m) ) − ϕ(m) (x, u) x ˆ
¯ = ϕ(x, u) − ϕ(m) (x, u) +
h
i ¯ a(x) − a(m) (x) ux¯ (x) ,
(3.46)
x ˆ
z(0) = z(1) = 0. Using (3.46) we obtain
(m) ¯
(m) ¯
¯ Ah (x, u) − Ah (x, y (m) ), z
¯ = ϕ(x, u) − ϕ(m) (x, u), z
ω ˆh
+ ω ˆh
¯ a(m) − a ux¯ , zx¯
(3.47) , +
ω ˆh
which together with (3.45) implies the estimation (m) ¯ (m) ¯ ¯ Ah (x, u) − Ah (x, y(m) ), z
2
ω ˆh
≥ c kzkB (m) ¯ .
(3.48)
h
Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) we obtain from (3.40) and (3.41) the following estimates for the summands on the right-hand side of (3.47): a
(m) ¯
− a ux¯ , zx¯ + ω ˆh
¯
≤ a(m) − a
0,2,ˆ ωh
≤
¯ kux¯ k0,2,ˆω+ kzx¯ k0,2,ˆω+ ≤ M hm kzx¯ k0,2,ˆω+ h
h
(3.49)
h
¯ M hm kzkB (m) ¯ , h c˜1
and ¯ ϕ(x, u) − ϕ(m) (x, u), z
ω ˆh
≤ M hm+1 kzx¯ k0,2,ˆω+ ≤ h
M hm+1 kzkB(m) ¯ h c˜1
(3.50)
M hm kzkB (m) ¯ h c˜1
(3.51)
if m is odd, and ¯ (x, u), z ϕ(x, u) − ϕ(m)
ω ˆh
≤ M hm kzx¯ k0,2,ˆω+ ≤ h
if m is even. ¯ The estimates (3.48)–(3.51) yield kzkB(m) ≤ M hm . Furthermore due to the ¯ h
¯ equivalence of the norms k·k1,2,ˆωh and k·kB(m) we obtain kzk1,2,ωˆ h ≤ M hm . ¯ h
107
108
Chapter 3. 3-point difference schemes for scalar ODEs (m) ¯
(m) ¯
¯ ¯ Since y0 = Y20 (x0 , y (m) ), yj = Y1j (xj , y (m) ) and the relations (3.32)–(3.34) hold, we have dz (m)0 ¯ ¯ ¯ ) − Z20 (x0 , y (m) ) + Z20 (x0 , y (m) ) − Z20 (x0 , u) ≤ Z2 (x0 , y(m) k dx x=x0 1 ¯ (m) ¯ 0 (m) ¯ Y2(m)0 (x , y ) − Y (x , y ) + 0 0 2 (m)0 ¯ (x0 ) V2 ∂ ¯ ¯ ≤M1 hm + Z20 (x0 , u) kzk0,2,ˆωh ≤ M2 hm , ∂u u=˜ u dz (m)j ¯ ¯ ¯ ) − Z1j (xj , y(m) ) + Z1j (xj , y (m) ) − Z1j (xj , u) k ≤ Z1 (xj , y(m) dx x=xj 1 (m)j ¯ ¯ (m) ¯ Y1j (xj , y (m) ) − Y (x , y ) + j 1 (m)j ¯ (xj ) V1 ∂ j m ¯ ¯ ≤M3 h + Z1 (xj , u) kzk0,2,ˆωh ≤ M4 hm , j = 1, 2, . . . , N, ∂u u=˜ u
dz
dz ¯
k k ≤ max . ≤ M hm
dx j=0,1,...,N dx ˆ 0,2,ω ¯h x=xj ∗
¯ Now, using (3.39)–(3.41), we get the claim kzk1,2,ˆωh ≤ M hm .
In order to solve the nonlinear equations of the m-TDS ¯ (3.38), we use an iteration method which is characterized in the next theorem. Theorem 3.4 Let the assumptions of Theorem 3.3 be satisfied. Then (m) ˜ ¯ (x, v) ≤ L |u − v| , ϕ ¯ (x, u) − ϕ(m) N
and there exists a h0 > 0 such that for all {hj }j=1 with h ≤ h0 the following two relations are satisfied: ¯ a(m) (x) ≥ c˜1 > 0, c˜1 ∈ R, (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), u − v
ω ˆh
≥ cku − vk2B (m) ¯ ,
0 < c < 1.
h
Moreover, the iteration method (m) ¯
Bh
¯ ¯ y (m,n) − y (m,n−1) (m) ¯ ¯ + Ah (x, y (m,n−1) ) = 0, τ
¯ (0) = µ1 , y (m,n) ¯ y (m,0) (x) =
¯ y (m,n) (1) = µ2 ,
V2 (x) V1 (x) µ1 + µ2 V1 (1) V1 (1)
n = 1, 2, . . . ,
x∈ω ˆh, (3.52)
3.3. Implementation of the three-point EDS converges and for the corresponding error we have
∗
(m,n)
¯ − u ≤ M (hm + q n ),
y
(3.53)
1,2,ˆ ωh
where ˜ −2 L , τ = τ0 = c 1 + 8˜ c1 def
def
q =
√
1 − cτ0 ,
¯ (m,n) ¯ Y (m)0 ¯ ¯ x0 , y (m,n) − y0 dy (m,n) (m)0 2 (m,n) ¯ x + = Z , y k(x) , 0 2 (m)1 ¯ dx x=x0 V1 (x1 ) ¯ (m)j ¯ ¯ y (m,n) ¯ − Y1 xj , y (m,n) dy (m,n) j (m)j (m,n) ¯ xj , y + = Z1 , k(x) (m)j ¯ dx x=xj V1 (xj ) and the constant M does not depend on h, m and n.
Proof. Theorem 3.3 implies
∗
(m,n)
− u
y
1,2,ˆ ωh
∗
≤ y (m) − u
1,2,ˆ ωh
∗
¯ ¯ + y (m,n) − y (m)
1,2,ˆ ωh
∗
¯ ¯ ¯ ≤ M hm + y (m,n) − y (m)
.
1,2,ˆ ωh
N
¯ ([xj−1 , xi ] × R2 ), we have Since f (x, u, ξ) ∈ ∪ Cm j=1
˜ (m) ¯ (x, v) ≤ L|u − v|. ϕ ¯ (x, u) − ϕ(m) By using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8), (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), w ωˆ h
(m)
¯ ¯ ≤ ku − vkB (m) (x, u) − ϕ(m) (x, v) ¯ kwk (m) ¯ + ϕ B h
0,2,ˆ ωh
h
˜ ≤ ku − vkB (m) ¯ kwk (m) ¯ + L ku − vk0,2,ˆ ωh kwk0,2,ˆ ωh B h
h
≤ ku − vkB (m) ¯ kwk (m) ¯ + B h
h
˜ L kux¯ − vx¯ k0,2,ˆω+ kwx¯ k0,2,ˆω+ h h 8
˜ L ku − vkB(m) ≤ 1+ ¯ kwk (m) ¯ . Bh h 8˜ c1
kwk0,2,ˆωh
(3.54)
109
110
Chapter 3. 3-point difference schemes for scalar ODEs def
Setting w =
−1 (m) ¯ (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v) , we obtain Bh
−1
(m) (m) ¯ (m) ¯
B ¯ Ah (x, u) − Ah (x, v)
h
(m) ¯
Bh
˜ L ku − vkB(m) ≤ 1+ ¯ . h 8˜ c1
(3.55)
It follows from (3.46), (3.55) that −1 (m) ¯ (m) ¯ (m) ¯ (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), Bh Ah (x, u) − Ah (x, v) ω ˆh
˜ 2 (m) ˜ 2 1 L L ¯ (m) ¯ 2 1+ Ah (x, u) − Ah (x, v), u − v ≤ 1+ ku − vkB (m) ≤ . ¯ 8˜ c1 c 8˜ c1 ω ˆh h Using the results of [74, p.502] we conclude that the iteration method (3.52) converges in the space HB (m) ¯ . Its norm is equivalent to the norm of the space h
◦
W21 (ˆ ωh ), and so we get
(m,n) ¯
y ¯ − y (m)
1,2,ˆ ωh
≤ M1 q n .
Besides we have dy (m,n) ¯ ¯ dy (m) − k k dx dx x=x0 x=x0 (m)0 (m)0 ¯ ¯ ≤ Z2 (x0 , y (m,n) ) − Z2 (x0 , y (m) ) 1 ¯ (m)0 ¯ (m,n) ¯ (m) ¯ Y2(m)0 (x , y ) − Y (x , y ) + 0 0 2 (m)0 ¯ (x0 ) V2
∂ (m)0 (m,n) ¯ (m) ¯ Y2 ¯ (x0 , u) + −y
y (m)0 ¯ 0,2,ˆ ωh u=˜ y V2 u=¯ y (x0 ) ∂u
∂ (m)0 ≤ Z2 (x0 , u) ∂u
¯ ¯ ≤ M1 y (m,n) − y (m)
1
, 0,2,ˆ ωh
dy (m,n) ¯ ¯ dy (m) − k k dx dx x=xj x=xj (m)j (m)j ¯ ¯ ≤ Z1 (xj , y (m,n) ) − Z1 (xj , y (m) ) 1 ¯ (m)j ¯ (m,n) ¯ (m) ¯ Y1(m)j (x , y ) − Y (x , y ) + j j 1 (m)j ¯ (xj ) V1
3.3. Implementation of the three-point EDS
∂ 1
(m,n) ¯ ¯ (m) ¯ Y1(m)j + (x , u) −y
y j (m)j ¯ 0,2,ˆ ωh u=˜ y V1 u=¯ y (xj ) ∂u
∂ (m)j ≤ Z1 (xj , u) ∂u
¯ ¯ ≤ M2 y (m,n) − y (m)
,
j = 1, 2, . . . , N,
0,2,ˆ ωh
¯ ¯
dy (m,n) dy (m)
k
−k
dx dx
ˆ 0,2,ω ¯h
dy (m,n) ¯ ¯ dy (m) ≤ max k − k j=0,1,...,N dx dx x=xj x=xj
¯ ¯ ≤ M y (m,n) − y (m)
, 1,2,ˆ ωh
from which we obtain
∗
(m,n) ¯
y ¯ − y (m)
≤ M qn .
(3.56)
The inequalities (3.54), (3.56) yield the estimate (3.53).
1,2,ˆ ωh
It is preferable to compute the solution of (3.38) by a slightly modified version of the well-known Newton’s method which was justified in [44]. It is ¯ (xj , u) = ~−1 ϕ(m) j
2 X
α
(−1)
(ku0 )β + (−1)α+1 hγ Φ2 xβ , uβ , (ku0 )β , (−1)α+1 hγ
α=1
−
Φ1 xβ , uβ , (ku0 )β , (−1)α+1 hγ Φ3 (xβ , 0, (−1)α+1 hγ )
,
where we have used as before the abbreviations def
β = j + (−1)α ,
def
γ = j − 1 + α.
From (3.25)–(3.27) we have the relations Φ1 (x, u, ξ, 0) =
ξ , k(x)
∂Φ1 (x, u, ξ, 0) f (x, u, ξ) =− , ∂h 2k(x)
Φ2 (x, u, ξ, 0) = −f (x, u, ξ) ,
Φ3 (x, u, 0) =
1 . k(x)
Thus we can write (m) ¯
ϕ
(xj , y
(m) ¯
2 ¯ hγ dy (m) (m) ¯ +O , ) = f xj , yj , dx x=xj ~j
111
112
Chapter 3. 3-point difference schemes for scalar ODEs 2 ¯ hγ dy (m) (m) ¯ . = y + O x ¯,j dx x=xj ~j The modified Newton’s method now reads: (m,0) ¯
Provide starting values ∇yj
, j = 0, 1, . . . , N ;
For n = 1, 2, . . . (m,n) ¯
1) compute the Newton correction ∇yj linear equations
(m,n) ¯
¯ a(m) ∇yx¯
x ˆ,j
+
, j = 0, 1, . . . , N , from the system of
¯ dy (m,n−1) (m,n−1) ¯ ∂f xj , yj , dx x=xj ∂u
+
(m,n) ¯
∇yj
¯ dy (m,n−1) (m,n−1) ¯ ∂f xj , yj , dx x=xj ∂ξ
(m,n) ¯
∇yx¯,j
¯ ¯ ¯ ¯ (m,n−1) = −ϕ(m) yx¯ , xj , y (m,n−1) − a(m) x ˆ,j (m,n) ¯
∇y0
= 0,
(m,n) ¯
∇yN
= 0,
j = 1, 2, . . . , N − 1,
2) compute the new iterate (m,n) ¯
yj
3.4
(m,n−1) ¯
= yj
(m,n) ¯
+ ∇yj
,
j = 0, 1, . . . , N.
Boundary conditions of 3rd kind
Let us now consider the BVP d du du k(x) = −f x, u, , dx dx dx k(0)
du(0) − β1 u(0) = −µ1 , dx
k(1)
x ∈ (0, 1),
(3.57)
du(1) + β2 u(1) = µ2 dx
(3.58)
and derive an exact difference boundary condition at x = 0 which is satisfied by the exact solution of problem (3.57), (3.58). To achieve this, we represent the solution of problem (3.57), (3.58) on the interval [x0 , x1 ] in the form u(x) = Y20 (x, u),
(3.59)
3.4. Boundary conditions of 3rd kind where the function Y20 (x, u) is the solution of the IVP dY20 (x, u) Z 0 (x, u) dZ20 (x, u) Z 0 (x, u) = 2 , = −f x, Y20 (x, u), 2 , dx k(x) dx k(x) du 0 0 Y2 (x1 , u) = u1 , Z2 (x1 , u) = k(x) , 0 = x0 < x < x1 . dx x=x1
(3.60)
We require that this function satisfies the condition k(0)
du(0) − β1 u(0) = −µ1 . dx
(3.61)
Substituting (3.59) into (3.61) we obtain a1 ux,0 − β1 u0 = −µ1 − h1 ϕ(x0 , u),
(3.62)
where def
a1 = a(x1 ) =
1 0 V (x0 ) h1 2
−1
def
,
ϕ(x0 , u) =
1 Y 0 (x0 , u) − u1 . Z20 (x0 , u) + 2 0 h1 V2 (x0 )
The function V20 (x) is the solution of the IVP dV20 (x) 1 = , dx k(x)
x0 < x < x1 ,
V20 (x1 ) = 0,
and can be represented explicitly in the form Z x1 1 V20 (x) = dξ. k(ξ) 0
(3.63)
(3.64)
Analogously the boundary condition k(1)
du(1) + β2 u(1) = µ2 dx
corresponds to the exact difference condition aN ux¯,N + β2 uN = µ2 + hN ϕ(xN , u), where −1 1 N V1 (xN ) , hN Y1N (xN , u) − uN −1 def 1 N . Z1 (xN , u) − ϕ(xN , u) = hN V1N (xN ) def
aN = a(xN ) =
The functions Y1N (x, u) and Z1N (x, u) are the solutions of the IVPs dY1N (x, u) Z N (x, u) dZ1N (x, u) Z N (x, u) = 1 , = −f x, Y1N (x, u), 1 , dx k(x) dx k(x)
(3.65)
113
114
Chapter 3. 3-point difference schemes for scalar ODEs Y1N (xN −1 , u)
= uN −1 ,
Z1N (xN −1 , u)
du = k(x) , dx x=xN −1
xN−1 < x < xN ,
and the function V1N (x) is the solution of the IVP 1 dV1N (x) = , dx k(x)
xN −1 < x < xN ,
V1N (xN −1 ) = 0.
Let us construct an approximation of the exact boundary condition (3.62). To determine numerically the solution of the IVPs (3.60), (3.63) we use the one-step method (m)0 ¯
(x0 , u) = u1 − h1 Φ1 (x1 , u1 , (ku0 )1 , −h1 ),
(m)0
(x0 , u) = (ku0 )1 − h1 Φ2 (x1 , u1 , (ku0 )1 , −h1 ),
(m)0 ¯
(x0 ) = h1 Φ3 (x1 , 0, −h1 ).
Y2
Z2 V2
Instead of (3.62) one can use a difference rank-m-approximation ¯ of the boundary condition (3.61): (m) ¯ (m) ¯
(m) ¯
a1 yx,0 − β1 y0
¯ ¯ = −µ1 − h1 ϕ(m) (x0 , y(m) ),
(m) ¯
yN
= µ2 ,
where −1 1 (m)0 ¯ a (x1 ) = V (x0 ) , h1 2 # " (m)0 ¯ (m) ¯ ¯ (x0 , y (m) ) − y1 Y2 def 1 (m)0 (m) ¯ (m) ¯ (m) ¯ . Z2 (x0 , y ) + ϕ (x0 , y ) = (m)0 ¯ h1 V (x0 )
(m) ¯ def a1 =
(m) ¯
2
Note that the relation V20 (x0 ) =
h1 + O(h21 ) and Lemma 3.4 imply k1
¯ (x1 ) − a(x1 ) a(m) (m)0 ¯
=
h1 [V20 (x0 ) − V2
(x0 )]
(m)0 ¯ V20 (x0 )V2 (x0 )
¯ = O(hm 1 ),
¯ (x0 , u) − ϕ(x0 , u) ϕ(m) ) ( (m)0 ¯ 1 Y2 Y20 (x0 , u) − u1 (x0 , u) − u1 (m)0 0 = Z2 (x0 , u) − Z2 (x0 , u) + − (m)0 ¯ h1 V20 (x0 ) V (x0 ) 2
=
¯ O(hm 1 ).
3.5. Numerical examples This means that the difference scheme (m) ¯
¯ ¯ ¯ (a(m) yx¯ )xˆ,j = −ϕ(m) (xj , y (m) ),
j = 1, 2, . . . N − 1, (3.66)
(m) ¯ (m) ¯
(m) ¯
a1 yx,0 − β1 y0
(m) ¯
¯ ¯ = −µ1 − h1 ϕ(m) (x0 , y(m) ),
yN
= µ2
approximates problem (3.57), (3.58) with order of accuracy m. ¯ Analogously, the approximation of the boundary condition (3.65) is of the form −1 1 (m)N (m) ¯ (m) ¯ (m) ¯ ¯ ¯ aN yx¯,N + β2 yN = µ2 + hN ϕ(m) (xN , u), aN = V1 (xN ) , hN # " (m)N ¯ (m) ¯ (m) ¯ Y (x , y ) − y 1 N (m)N 1 N −1 ¯ ¯ ¯ . Z1 (xN , y(m) )= (xN , y (m) )− ϕ(m) (m)N ¯ hN V (xN ) 1
3.5
Numerical examples
Example 3.1. Let us consider the BVP u00 = exp(u),
u(0) = 0,
with the exact solution u(x) = − ln cos2
√ u(1) = − ln cos2 1/ 2 , √ x/ 2 .
(3.67)
Let f (x, u, ξ) = − exp(u), f0 (x) ≡ 0, then the condition (3.5) is fulfilled if we use c(t) = exp(t), g(x) ≡ 1. Besides we have [f (x, u, ξ) − f (x, v, η)] (u − v) = − exp(θu + (1 − θ)v)(u − v)2 ≤ 0,
0 < θ < 1.
Thus, due to Theorem 3.1 the problem has a unique solution. In order to solve (3.67) numerically we use the following 6-TDS: (6) (6) (6) yx¯xˆ,j = −ϕ(6) xj , y(6) , j = 1, 2, . . . , N − 1, y0 = µ1 , yN = µ2 , (3.68) where ϕ(6) (xj , u) = ~−1 j µ1 = 0, (6)j
and Yα
2 X
(−1)α (6)j (−1)α Zα(6)j (xj , u) + Yα (xj , u) − uβ , hγ α=1
√ µ2 = − ln cos2 1/ 2 , (6)j
(x, u), Zα (x, u) are the numerical solutions of the IVPs
dYαj (x, u) = Zαj (x, u), dx Yαj (xβ , u) = uβ ,
dZαj (x, u) = −f x, Yαj (x, u) , Zαj (x, u) , dx du j Zα (xβ , u) = , dx x=xβ
x ∈ ejα , (3.69)
115
116
Chapter 3. 3-point difference schemes for scalar ODEs j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2.
We have solved the IVPs (3.69) with the explicit 7-stage Runge-Kutta method of order 6 which is characterized by the Butcher tableau given in Table 2.4. To determine the solution of the difference scheme (3.68) the following fixed point iteration can be used: • starting values (6,0)
yj
= (1 − xj )µ1 + xj µ2 ,
• iteration procedure (n = 1, 2, . . .) (6,n) yx¯xˆ,j = −ϕ(6) xj , y (6,n−1) ,
j = 0, 1, . . . , N ;
j = 1, 2, . . . , N − 1, (3.70)
(6,n)
y0
= µ1 ,
(6,n) yN
= µ2 .
The equations (3.70) represent a system of linear algebraic equations for the unknowns y (6,n) (x), x ∈ ω ˆ h . We solved this system with a special Gaussian elimination technique for linear systems with a tridiagonal matrix (see e.g. [30]). Numerical results for the equidistant grid ωh are given in Table 3.1. Here, we have used the formulas
(6) ∗
z
∗
def (6) ∗ def
(6)
1,2,ωh er = z = y − u and p = log2 (3.71)
z (6) ∗ 1,2,ωh 1,2,ωh 1,2,ω h/2
to measure the error and the order of convergence, respectively. Obviously, p has been determined by the well-known Runge technique. This and the next two examples should elucidate that the theoretical order of accuracy is actually achieved.
N 8 16 32
er 0.1987 E − 8 0.3168 E − 10 0.4894 E − 12
p 6.0 6.0
Table 3.1: Numerical results for problem (3.67)
Example 3.2. Let us consider the problem 1 d2 u du 1 5 2 = cos , u(0) = 0, u(1) = arctan − ln dx2 2 dx 2 4
(3.72)
3.5. Numerical examples with the exact solution u(x) = x arctan
1 2 1 x − ln 1 + x . 2 4
1 Here we have f (x, u, ξ) = − cos2 ξ and further 2 1 [f (x, u, ξ) − f (x, v, η)] (u − v) = − cos2 (θξ + (1 − θ)η) (ξ − η) (u − v) 2 1 1 1 1 2 2 2 2 2 ≤ cos (θξ + (1 − θ)η) (u − v) + (ξ − η) ≤ |u − v| + |ξ − η| , 2 2 2 4 which means that the BVP (3.72) is monotone. The numerical results for the method with order of accuracy 6 (m = 6) on the equidistant grid ωh are given in Table 3.2. N 4 8 16
er 0.6972 E − 8 0.1099 E − 9 0.1723 E − 11
p 6.0 6.0
Table 3.2: Numerical results for problem (3.72)
Example 3.3. Let us consider the BVP d2 u du =u , dx2 dx
du(0) = −0.5/ cosh2 (1/4) , dx
u(1) = − tanh (1/4) .
(3.73)
The exact solution is u(x) = tanh ((1 − 2x)/4). The numerical results which have been obtained for the difference scheme (3.63) of order of accuracy 6 (m = 6) on the equidistant grid ωh are given in Table 3.3. N 4 8 16 32
er 0.2241 E − 7 0.3148 E − 9 0.4787 E − 11 0.7677 E − 13
p 6.2 6.0 6.0
Table 3.3: Numerical results for problem (3.73)
In the following three examples the implementation of the TDS uses the h-h/2a posteriori estimation to achieve a given accuracy EPS. The comparison with the true error Error shows that this accuracy is actually achieved.
117
118
Chapter 3. 3-point difference schemes for scalar ODEs Example 3.4. The next example d2 u du = Au , dx2 dx
A u(0) = tanh , 4
A u(1) = − tanh , 4
(3.74)
A(1 − 2x) . Table 3.4 presents the numerical 4 results for the parameter value A = 7.
has the exact solution u(x) = tanh
EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8
N
Error
16 256 2048
0.937 E − 4 0.234 E − 6 0.242 E − 8
Table 3.4: Numerical results for problem (3.74)
Example 3.5. The BVP d2 u 3 = u2 , dx2 2
u(0) = 4,
u(1) = 1
(3.75)
4 . The numerical results on the equidistant (1 + x)2
has the exact solution u(x) = grid ωh are given in Table 3.5.
EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8
N
Error
32 64 512
0.879 E − 5 0.847 E − 7 0.777 E − 9
Table 3.5: Numerical results for problem (3.75)
Example 3.6. Let us consider the BVP d2 u = dx2
du dx
2 ,
u(0) = 1,
u(1) = 0,
(3.76)
with the exact solution u(x) = − ln x + e−1 (1 − x) . Numerical results on an equidistant grid ωh are presented in Table 3.6.
3.5. Numerical examples EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8
N
Error
128 1024 8192
0.4899 E − 5 0.8035 E − 7 0.1047 E − 8
Table 3.6: Numerical results for problem (3.76)
The conclusion of this section is that the numerical results which have been obtained for the examples 3.1 – 3.6 confirm our theoretical statements on the order of accuracy of the proposed difference schemes.
119
121
Chapter 4
Three-point difference schemes for systems of monotone second-order ODEs What do I like most about your system? It is as hard to understand as the world. Franz Grillparzer (1791–1872) This chapter deals with a generalization of the results from the previous chapter to the case of systems of second-order ODEs with a monotone operator. For such systems with Dirichlet boundary conditions an exact 3-point EDS on an irregular grid is constructed, and the existence and uniqueness of its solution is shown. The EDS forms the basis for the associated TDS on a 3-point stencil that can be constructed such that it has a required order of accuracy m. ¯ Considering the nonlinearity of the ODE we use the method of monotone operators (see, e.g. [18]) as the standard tool for our theoretical investigations .
4.1
Problem setting
Let us consider the following nonlinear BVP for a system of second-order ODEs du du d K(x) = −f x, u, , x ∈ (0, 1), u(0) = µ1 , u(1) = µ2 , (4.1) dx dx dx I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_4, © Springer Basel AG 2011
121
122
Chapter 4. 3-point difference schemes for systems of ODEs where K(x) ∈ Rn×n and f (x, u, ξ), µ1 , µ2 ∈ Rn are given, and u(x) ∈ Rn is the unknown vector. def
Let (u, v) be a scalar product in Rn , kuk = (u, u)1/2 be the associated norm, and Qp [0, 1] be the space of functions having piece-wise continuous derivatives up to order p with a finite number of discontinuity points of first kind. Moreover, let Cr be a non-negative, continuous function, f0r (x) ∈ L2 (0, 1), gr (x) ∈ L1 (0, 1), and c1 , c2 , c3 be some constants. The following theorem states sufficient conditions for the existence and uniqueness of a solution of problem (4.1). Theorem 4.1 def
Let the matrix K(x) = [krs (x)]nr,s=1 and the function def
n
f (x, u, ξ) = {fr (x, u, ξ)}r=1 satisfy the conditions K(x) = K ∗ (x),
krs (x) ∈ Q1 [0, 1],
c1 kuk2 ≤ (K(x)u, u) ≤ c2 kuk2
for all x ∈ [0, 1], u ∈ Rn ,
c1 > 0,
(4.2)
def
fruξ (x) = fr (x, u, ξ) ∈ Q0 [0, 1] for all u, ξ ∈ Rn , def
frx (u, ξ) = fr (x, u, ξ) ∈ C(R2n ) for all x ∈ [0, 1], (4.3) ! n X |fr (x, u, ξ)| ≤ Cr |up | (gr (x) + |ξr |) for all x ∈ [0, 1], u, ξ ∈ Rn , p=1
(4.4) f (x, u, ξ) − f (x, v, η) , u − v 2 2 for all x ∈ [0, 1], u, v, ξ, η ∈ Rn , ≤ c3 ku − vk + kξ − ηk 0 ≤ c3 <
π2 c1 . π2 + 1
(4.5) (4.6)
n
Then problem (4.1) has a unique solution u(x) = {ur (x)}r=1 , ur (x) ∈ W21 (0, 1), n P dus ∈ C[0, 1], r = 1, 2, . . . , n. with ur (x), krs (x) dx s=1
Proof. Due to (4.3) the components fr (x, u, ξ), r = 1, 2, . . . , n, of the vector-valued function f (x, u, ξ) have the Carath´eodory property (see Definition 1.12) and belong to L1 [0, 1]. Therefore we can define the operator A(x, u) by the variational equality Z1 Z1 du dv du ˜ dx − , v(x) dx, K(x) , f x, u(x), (A(x, u), v) = dx dx dx 0
0
4.1. Problem setting where du def du f˜ x, u(x), − f 0 (x), = f x, u(x), dx dx
n
f 0 (x) = {f0r (x)}r=1 , ◦
which holds for all u(x), ur (x) ∈ W21 (0, 1), and for all v(x), vr (x) ∈ W21 (0, 1). Here we have used ◦
def
W21 (0, 1) = {vr (x) : vr (x) ∈ W21 (0, 1),
vr (0) = vr (1) = 0},
r = 1, . . . , n.
A function u(x) is a weak solution of (4.1), if ◦
ur (x) − ϕr (x) ∈ W21 (0, 1),
r = 1, 2, . . . , n, ◦
(A(x, u), v) = (f 0 (x), v) for all v(x) with vr (x) ∈ W21 (0, 1),
r = 1, 2, . . . , n,
where ϕ(x) is a vector-valued function with components from W21 (0, 1), which satisfies the boundary conditions of problem (4.1). Since ur (x) ∈ W21 (0, 1), r = 1, 2, . . . , n, we can deduce ur (x) ∈ C[0, 1] and the dur ∈ L2 (0, 1), r = 1, 2, . . . , n. derivative dx Let us show that the operator A(x, u) is bounded. Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) and taking into account the conditions (4.2) and (4.4) with X n Cr |up | ≤ C˜2 p=1
as well as the inequality (see, e.g. [18], p.112) kvkC[0,1] ≤ C˜1 kvk1,2,(0,1)
for all v(x) with vr (x) ∈ W21 (0, 1),
we obtain 1/2 1 1/2 1
2 Z Z 2
dv du
dx |(A(x, u), v)| ≤
K(x) dx dx
dx 0
0
1 1/2 2 Z
du ˜
+ kvkC[0,1]
f x, u(x), dx dx 0
f 0,1,(0,1) kvk1,2,(0,1) ≤ c2 kuk1,2,(0,1) + C˜1 ˜
≤ (c2 + C˜1 C˜2 ) kuk1,2,(0,1) + C˜1 C˜2 kgk0,1,(0,1) kvk1,2,(0,1) , where def
kukC[0,1] = max ku(x)k, x∈[0,1]
def
Z1
kuk0,1,(0,1) =
ku(x)kdx, 0
123
124
Chapter 4. 3-point difference schemes for systems of ODEs
kuk0,2,(0,1)
1 1/2 Z def = ku(x)k2 dx , 0
#1/2
2
du
kuk20,2,(0,1) + .
dx 0,2,(0,1)
" def
kuk0,2,(0,1) =
The semi-continuity of the operator A(x, u) follows from (4.3). Actually, if un → u0 component-wise in the space W21 (0, 1), then dun du0 dun du0 −→ f x, u0 , , K(x) −→ K(x) f x, un , dx dx dx dx component-wise in the space L2 (0, 1). ◦
Therefore, for all v(x), vr (x) ∈ W21 (0, 1), r = 1, 2, .., n, it holds that lim (A(x, un ), v)
n→∞
Z1 Z1 dv du du n n , dx − , v(x) dx K(x) f x, un (x), = lim n→∞ dx dx dx
0
0
Z1 Z1 du0 dv du0 , dx − , v(x) dx K(x) f x, u0 (x), = dx dx dx 0
0
= (A(x, u0 ), v) , i.e the operator A(x, u) is semi-continuous. The operator A(x, u) is strongly monotone, since (4.2), (4.5) and the inequality
◦
dv π
≥√ kvk1,2,(0,1) for all v(x) with vr (x) ∈ W21 (0, 1),
dx 1 + π2 0,2,(0,1) r = 1, . . . , n, imply (A(x, u) − A(x, v), u − v) Z1 du dv du dv = − , − dx K(x) dx dx dx dx 0
Z1 dv du − − f x, v(x), , u(x) − v(x) dx f x, u(x), dx dx 0
4.2. Existence of a three-point EDS
du dv 2 2
≥ c1 − − c3 ku − vk1,2,(0,1)
dx dx 0,2,(0,1) 2
≥ c4 ku − vk1,2,(0,1) , where in accordance with (4.6) we have c4 = ◦
π2 c1 −c3 > 0, and the components π2 + 1
of the vector u − v belong to the space W21 (0, 1). The strong monotonicity implies the coercivity of the operator A(x, u). Now, The Browder-Minty Theorem (see Theorem 1.3) yields the existence and uniqueness of a solution of (4.1). Due to du = K(x) dx
Zx f
du dξ + C, ξ, u(ξ), dξ
0
the vector K(x)
du is the indefinite Lebesgue integral which yields that dx n X s=1
4.2
krs (x)
dus ∈ C[0, 1], dx
r = 1, 2, . . . , n.
Existence of a three-point EDS
We choose the irregular grid ω ˆ h (see (1.4,a)) so that the set ρ of the discontinuity points of the matrix K(x) and of the vector-valued function f (x, u, ξ) is part of ω ˆh, i.e. the number N is large enough to assure ρ ⊆ ω ˆ h . For the solution of problem (4.1) at each point xi ∈ ρ we demand that the following continuity conditions hold: du du u(xi − 0) = u(xi + 0), K(x) = K(x) for all xi ∈ ρ. dx x=xi −0 dx x=xi +0 Let us consider the following BVPs on small intervals: d dx
dY jα (x, u) dY jα (x, u) K(x) = −f x, Y jα (x, u), , dx dx
Y jα (xj−2+α , u) = u(xj−2+α ),
x ∈ ejα ,
Y jα (xj−1+α , u) = u(xj−1+α ),
j = 2 − α, 3 − α, . . . , N + 1 − α,
(4.7)
α = 1, 2.
The relationship between the solutions of the BVPs (4.1) and (4.7) is shown in the next lemma.
125
126
Chapter 4. 3-point difference schemes for systems of ODEs Lemma 4.1 Let the assumptions of Theorem 4.1 be satisfied. Then, each of the problems j (4.7) has a unique solution Y jα (x, u), Yα,r (x, u) ∈ W21 (ejα ), where j (x, u), Yα,r
n X
krs (x)
s=1
j dYα,s ∈ C(¯ ejα ), dx
r = 1, 2, . . . , n.
These solutions are associated with the solution of problem (4.1) by the equations u(x) = Y jα (x, u),
x ∈ e¯jα ,
(4.8)
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2.
Proof. Since the function f (x, u, ξ) possesses the Carath´eodory property (see Definition 1.12) and belongs to the space L2 [0, 1], we can introduce the nonlinear operator Ajα x, Y jα by the relation Ajα
x, Y
j α
xj−1+α Z
K(x)
,v =
dY jα (x, u) dv(x) , dx dx
dx
xj−2+α xj−1+α Z
−
dY jα (x, u) , v(x) dx, f˜ x, Y jα (x, u), dx
xj−2+α
where dY jα (x, u) def dY jα (x, u) j j ˜ − f 0 (x), f x, Y α (x, u), = f x, Y α (x, u), dx dx def
n
f 0 (x) = {f0r (x)}r=1 . j This relation is valid for all Y jα (x, u) with Yαr ∈ W21 (eα ), and all functions v(x) ◦
with vr (x) ∈ W21 (eα ), r = 1, 2, . . . , n. Here we have used the notation ◦
def
W21 (eα ) =
v(x) : v(x) ∈ W21 (eα ), v(xj−2+α ) = v(xj−1+α ) = 0 ,
α = 1, 2.
The functions Y jα (x, u), α = 1, 2, are the weak solutions of problem (4.7), provided that ◦
Ajα x, Y jα , v = 0,
for all v(x) with vr (x) ∈ W21 (eα ), ◦
j Yαr (x, u) − ϕαr (x) ∈ W21 (eα ),
r = 1, 2, . . . , n,
r = 1, 2, . . . , n,
4.2. Existence of a three-point EDS where ϕα (x) is a given function from W21 (eα ) satisfying the boundary conditions (4.7). The operator Ajα x, Y jα is bounded since the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8), Minkowski’s inequality (see Theorem 1.9) and the formulas (4.2), (4.4) imply
j Aα x, Y jα , v ≤
xj−1+α Z
1/2 j
2
K(x) dY α dx
dx
xj−2+α
xj−1+α Z
1/2
dv 2
dx
dx
xj−2+α
xj−1+α Z
f
+ kvkC(¯ejα )
2 1/2 dY jα
dx x, Y jα , dx
xj−2+α
≤
h
i c2 + C˜1 C˜2 Y jα 1,2,e + C˜1 C˜2 kgk0,1,eα kvk1,2,eα α
Due to (4.4) the operator Ajα (x, Y jα ) is also semi-continuous. Actually, if Y jαn (x, u) → Y jα0 (x, u) component-wise in W21 (0, 1), then f x, Y
j αn ,
dY jαn dx
j α0 ,
−→ f x, Y
in L2 (0, 1) (see, [18], p.113).
dY jα0 , dx
K(x)
dY jαn dY jα0 −→ K(x) dx dx
◦
Therefore, for all v with vr (x) ∈ W21 (eα ), r = 1, 2, . . . , n, it holds that lim Ajα (x, Y jαn ), v
n→∞
1 Z Z1 j j dY αn dv dY αn , dx − , v(x) dx K(x) f x, Y jαn , = lim n→∞ dx dx dx 0
Z1 =
dY jα0 dv , K(x) dx dx
0
0
Z1
! dx −
f
x, Y
j α0 ,
0
= Ajα (x, Y jα0 ), v , i.e. the operator Ajα x, Y jα is semi-continuous.
dY jα0 dx
!
! , v(x) dx
127
128
Chapter 4. 3-point difference schemes for systems of ODEs Let us show that Ajα x, Y jα is strongly monotone. We have
j Ajα x, Y jα − Ajα x, Y˜ α , Z jα (x, u) xj−1+α Z
dZ jα (x, u) dZ jα (x, u) , dx K(x) dx dx
= xj−2+α
xj−1+α Z
−
f x, Y
j α (x, u),
dY jα dx
j dY˜ α j j ˜ − f x, Y α (x, u), , Z α (x, u) dx. dx
xj−2+α
Due to (4.3), (4.5), and to the inequality
◦
dv π
≥√ kvk1,2,eα for all v(x) with vr (x) ∈ W21 (0, 1),
dx 1 + π2 0,2,eα r = 1, . . . , n, it follows that j Ajα x, Y jα − Ajα x, Y˜ α , Z jα (x, u) xj−1+α Z
≥ c1
dZ jα 2
dx dx − c3
xj−2+α
xj−1+α Z
j 2 dZ jα 2
Z + α
dx dx
xj−2+α
j 2
dZ α
2
− c3 Z jα 1,2,e ≥ c1
dx α 0,2,eα
2 ≥ c4 Z jα 1,2,e , α
where j def Z jα (x, u) = Y jα (x, u) − Y˜ α (x, u),
def
c4 =
π2 c1 − c3 > 0, 1 + π2 ◦
and the components of the vector Z jα (x, u) belong to W21 (eα ). The strong monotonicity yields the coercivity of Ajα (x, Y jα ). The Browder-Minty Theorem (see Theorem 1.3) implies the existence of a unique solution of (4.7). Since Y jα (x, u) is the solution of (4.7), this function is also the solution of problem (4.1), which in accordance with the assumptions of the lemma is unique. Lemma 4.1 is the basis for the next theorem which guarantees the existence of the following EDS.
4.2. Existence of a three-point EDS Theorem 4.2 Let the assumptions of Theorem 4.1 be satisfied. Then there exists the EDS du xj ˆ , x∈ω ˆ h , u(0) = µ1 , u(1) = µ2 , f ξ, u(ξ), (Aux¯ )xˆ = −T dξ (4.9) where h i−1 def A(xj ) = hj V1j (xj ) , ˆ xj
T
1 j (w(ξ)) = [V (xj )]−1 ~j 1 def
Zxj
V1j (ξ)w(ξ) dξ
xj−1
def V1j (x) =
Zx K
−1
(t) dt,
def V2j (x) =
xj−1
1 + [V2j (xj )]−1 ~j
xZj+1
V2j (ξ)w(ξ) dξ,
xj
xZj+1
K −1 (t) dt.
x
The EDS (4.9) has a unique solution u(x), x ∈ ω ˆ h , which coincides with the solution of problem (4.1) at the nodes of ω ˆ h . The function u(x) in the right-hand side of (4.9) is defined by (4.8) and depends only on the values u(xj ), j = 0, 1, . . . , N .
Proof. The application of the operator Tˆ xj to equation (4.1) gives Tˆ xj
d dξ
du K(ξ) dξ
= −Tˆ xj
du , f ξ, u(ξ), dξ
where ˆxj
T
d dξ
du K(ξ) dξ
x i−1 Z j 1 h j du d = K(ξ) dξ V1 (xj ) V1j (ξ) ~j dξ dξ xj−1
x i−1 Zj+1 du 1 h j d K(ξ) dξ + V2 (xj ) V2j (ξ) ~j dξ dξ xj
Zxj −1 j 1 j du du dξ V1 (xj ) K(x) = V1 (xj ) − ~j dξ ξ=xj dξ xj−1
xZj+1 −1 1 j du du j dξ − V2 (xj ) K(ξ) + V2 (xj ) + ~j dξ ξ=xj dξ xj
129
130
Chapter 4. 3-point difference schemes for systems of ODEs =
i−1 i−1 hj+1 h j+1 hj h j V1 (xj+1 ) V1 (xj ) ux,j − ux¯,j ~j ~j
= (Aux¯ )xˆ,j . This together with (4.8) implies the existence of the two-point EDS (4.9). Let us note that the difference scheme (4.9) is self-adjoint (see, e.g. [58]). In order to prove the uniqueness of the solution of the EDS (4.9) we introduce the operator du def xj ˆ , f ξ, u(ξ), Ah (x, u) = −(Aux¯ )xˆ,j − T dξ of which the components are defined on the grid spaces Hh accompanied with the scalar products X X def def ~(ξ)(u(ξ), v(ξ)), (u, v)ωˆ + = h(ξ)(u(ξ), v(ξ)) (u, v)ωˆ h = h
+ ξ∈ω ˆh
ξ∈ω ˆh
and the norms def
1/2
kuk0,2,ˆωh = (u, u)ωˆ h ,
def
1/2
kuk0,2,ωˆ + = (u, u)ωˆ + , h
h
def
kuk1,2,ˆωh = kuk20,2,ωˆ h + kux¯ k20,2,ˆω+
1/2
.
h
Due to (4.4) the operator Ah (x, u) is continuous. Let us show that Ah (x, u) is strongly monotone. Taking into account the relation x Z1 N Zj X ξ ˆ ~(ξ) T (w(η)), g(ξ) = (w(η), gˆ(η))dη = (w(η), gˆ(η)) dη,
X
j=1x j−1
ξ∈ˆ ωh
0
where h i−1 h i−1 def g(xj ) + V2j−1 (η) V1j (xj ) g(xj−1 ), gˆ(η) = V1j (η) V1j (xj )
xj−1 ≤ η ≤ xj ,
we have
dv du x ˆ − f η, v(η), ,u − v f η, u(η), T dη dη ω ˆh X dv du − f η, v(η), , u(ξ) − v(ξ) = ~(ξ) Tˆξ f η, u(η), dη dη ξ∈ˆ ωh
Z1 dv du ˆ (η) − v ˆ (η), f η, u(η), − f η, v(η), dη. u = dη dη 0
4.2. Existence of a three-point EDS The functions u(x) and v(x) are defined by formulas of the form (4.8). Now, using (4.5), we obtain
dv du Tˆ x f η, u(η), − f η, v(η), ,u − v dη dη ω ˆh
Z1 dv du − f η, v(η), dη u(η) − v(η), f η, u(η), = dη dη 0
Z1 dv du ˆ (η) − v ˆ (η) − u(η) + v(η), f η, u(η), + − f η, v(η), dη u dη dη 0
≤ c3 ku −
2 vk1,2,(0,1)
Z1 −
d ˆ (η) − v ˆ (η), u dη
du dv K(η) − dη dη
0
Z1 d du dv + K(η) − dη u(η) − v(η), dη dη dη 0 x N Zj X d du dv ˆ (η) − v ˆ (η), =− K(η) − dη u dη dη dη j=1 xj−1
Z1 du dv du dv 2 − , − dη + c3 ku − vk1,2,(0,1) . − K(η) dη dη dη dη 0
Since Zxj N X d du dv ˆ (η) − v ˆ (η), K(η) − dη u dη dη dη j=1 xj−1
x N Zj X v du dv dˆ u dˆ − , − dη K(η) =− dη dη dη dη j=1 xj−1
= − (A (ux¯ − v x¯ ) , ux¯ − v x¯ )ωˆ + . h
it follows that
dη
131
132
Chapter 4. 3-point difference schemes for systems of ODEs du dv x ˆ T − f η, v(η), ,u−v f η, u(η), dη dη ω ˆh
du dv 2 2
− ≤ (A (ux¯ − v x¯ ) , ux¯ − v x¯ )ωˆ + − c1 + c3 ku − vk1,2,(0,1) .
dx h dx 0,2,(0,1) (4.10) Taking into account (4.3) and the inequality
◦
dv π 1
√ ≤ kvk , v (x) ∈ W r 2 (0, 1), 1,2,(0,1)
dx 2 1 + π 0,2,(0,1) we obtain (Ah (x, u) − Ah (x, v) , u − v)ωˆ h = (A(ux¯ − v x¯ ), ux¯ − v x¯ )ωˆ + h du dv x ˆ − f η, v(η), ,u − v f η, u(η), − T dη dη ω ˆh
du dv 2 2
− ≥ c1 − c3 ku − vk1,2,(0,1)
dx dx 0,2,(0,1)
2
du dv 1 + π2
− ≥ c4 , π 2 dx dx 0,2,(0,1) def
where c4 =
π2 c1 − c3 > 0. Since 1 + π2
Z1 v du dv dˆ u dˆ v du dv dˆ u dˆ − − + , − − + dη K(η) dη dη dη dη dη dη dη dη 0
=−
N X
hj (A(xj ) (ux¯,j − vx¯,j ) , ux¯,j − vx¯,j )
j=1 x N Zj X du dv du dv + − , − dη K(η) dη dη dη dη j=1x j−1
Z1 = − (A (ux¯ − v x¯ ) , ux¯ − v x¯ )ωˆ + + h
du dv du dv − , − dη ≥ 0, K(η) dη dη dη dη
0
we get
du dv 2 1
≥ (A (ux¯ − v x¯ ) , ux¯ − v x¯ )ωˆ + .
dx − dx h c 2 0,2,(0,1)
4.2. Existence of a three-point EDS Thus, 1 + π 2 c4 (A (ux¯ − v x¯ ) , ux¯ − v x¯ )ωˆ + h π 2 c2 (4.11) 2 2 1 + π c4 c1 1 + π c4 c1 2 2 ≥ kux¯ − v x¯ k0,2,ωˆ + ≥ 8 ku − vk0,2,ˆωh , h π2 c2 π2 c2
(Ah (x, u) − Ah (x, v) , u − v)ωˆ h ≥
i.e. the operator Ah (x, u) is strongly monotone. This implies (see, e.g. [82], p.461) that the equation Ah (x, u) = 0 possesses a unique solution. The EDS represents a nonlinear operator equation which can be iteratively solved as stated in the following lemma. Lemma 4.2 Let the assumptions of Theorem 4.1 be satisfied. Suppose that kf (x, u, ξ)−f (x, v, η)k ≤ L{ku−vk+kξ−ηk} for all x ∈ (0, 1), u, v, ξ, η ∈ Rn . Then the stationary iteration method Bh
u(n) − u(n−1) + Ah x, u(n−1) = 0, τ
u(n) (0) = µ1 ,
u(n) (1) = µ2 ,
x∈ω ˆh,
n = 1, 2, . . . ,
u(0) (x) = V2 (x)[V1 (1)]−1 µ1 + V1 (x)[V1 (1)]−1 µ2 , (4.12) du def def , Bh u = −(Aux¯ )xˆ , Ah (x, u) = Bh u − Tˆx f ξ, u(ξ), dξ " r √ #−2 3 c22 2L 1 + π 2 c4 def τ = τ0 = L 1+ 1+ , π 2 c2 2 c31 c4 converges in the space HBh . Moreover, the following error estimation holds:
(n)
u − u ≤ q n u(0) − u , (4.13) B B h
h
with s def
q =
1−
1 + π 2 c4 τ0 , π 2 c2
def
c4 =
π2 c1 − c3 > 0, 1 + π2
def
1/2
kukBh = (Bh u, u)ωˆ h .
Proof. The inequality (4.11) implies Ah (x, u) − Ah (x, v), u − v
ω ˆh
≥
1 + π 2 c4 ku − vk2Bh . π 2 c2
(4.14)
133
134
Chapter 4. 3-point difference schemes for systems of ODEs Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) we obtain Ah (x, u) − Ah (x, v), z ωˆ h
= Bh u − Bh v, z ωˆ h X dv du ξ ˆ − f η, v(η), , z(ξ) ~(ξ) T f η, u(η), − dη dη
(4.15)
ξ∈ˆ ωh
= Bh u − Bh v, z
Z1 dv du ˆ (η) dη − f η, v(η), ,z f η, u(η), − dη dη
ω ˆh
0
≤ ku − vkBh kzkBh 12 1 12 1 2 Z Z
dv du kˆ z (η)k2 dη +
f η, u, dη − f η, v, dη dη 0
(4.16)
0
≤ ku − vkBh kzkBh
√ + 2Lku − vk1,2,(0,1) kˆ z k0,2,(0,1) .
(4.17)
Formula (4.2) implies h i∗ V1j (xj ) = V1j (xj ),
Zxj hj 2 j K −1 (t)u, u dt ≥ V1 (xj )u, u = kuk , c2 xj−1
and further
h i−1
j
V (xj )
≤ c2 ,
1
hj
−1
K (t) ≤ 1 . c1
Using the last estimate as well as the inequality
j
V (x) ≤ (−1)α+1 α
Zx
−1
K (t) dt ≤ hj−1+α , x ∈ e¯j , α c1
α = 1, 2,
xj+(−1)α
we obtain 2 kˆ z k0,2,(0,1)
2 Z1 h i−1 h i−1
j
j j−1 j
= V1 (x) V1 (xj ) z j + V2 (x) V1 (xj ) z j−1
dx 0 x " 2 N Z j
h i−1 X
j
j
kz j k ≤2
V1 (x) V1 (xj )
j=1x j−1
2 #
h i−1
4c2
j−1 2 j
kz j−1 k dx = 22 kzk0,2,ˆωh , + V2 (x)
V1 (xj )
c1 (4.18)
4.2. Existence of a three-point EDS and
2
2 Z1 h i−1
dˆ
−1
z
K (x) V j (xj )
= (z − z ) j j−1 dx 1
dx
0,2,(0,1) 0
x
2 N Zj i−1 X
−1 h j
K (x) V1 (xj ) ≤
hj kz x¯,j k
(4.19)
j=1x j−1
≤
c22 2 kz x¯ k0,2,ˆω+ . h c21
Let us prove the estimate r ku − vk1,2,(0,1) ≤
3 c2 2 c1
√ 2L 1+ kux¯ − v x¯ k0,2,ˆω+ . h c4
(4.20)
˜ (x) + u ˆ (x), xj−1 ≤ x ≤ xj+1 , and reduce the To achieve this we write u(x) = u problem d du du K(x) = −f x, u, , x ∈ ejα , dx dx dx u(xj−2+α ) = uj−2+α ,
u(xj−1+α ) = uj−1+α ,
α = 1, 2.
to the problem d˜ u d˜ u dˆ u d ˜ (x) + u ˆ (x), K(x) = −f x, u + , dx dx dx dx ˜ (xj−2+α ) = 0, u
˜ (xj−1+α ) = 0, u
x ∈ ejα ,
α = 1, 2.
˜ (x), v ˜ (x) with Using (4.3), (4.5) and a Lipschitz condition for all vectors u ◦
u ˜r (x), v˜r (x) ∈ W21 (e), r = 1, . . . , n, we have π2 ˜ k21,2,eα k˜ u−v 1 + π2
2
d˜ v u d˜
− ≤ c1 dx dx 0,2,eα
c1
xj−1+α Z
≤
K(x)
v d˜ u d˜ − dx dx
,
v d˜ u d˜ − dx dx
dx
xj−2+α xj−1+α Z
f
= xj−2+α
u d˜ v dˆ v d˜ u dˆ ˜ +v ˆ, ˜ (x) − v ˜ (x) dx ˜ +u ˆ, + − f x, v + ,u x, u dx dx dx dx
135
136
Chapter 4. 3-point difference schemes for systems of ODEs xj−1+α Z
f
=
u d˜ v dˆ u d˜ u dˆ ˜ +u ˆ, ˜ (x) − v ˜ (x) dx ˜ +u ˆ, + − f x, v + ,u x, u dx dx dx dx
xj−2+α xj−1+α Z
f
+
˜+u ˆ, x, v
u d˜ v dˆ + dx dx
−f
d˜ v dˆ v ˜+v ˆ, ˜ (x) − v ˜ (x) dx x, v + ,u dx dx
xj−2+α
1/2 2
u d˜ v dˆ v d˜ v dˆ
dx
f x, v ˜+v ˆ, ˜+u ˆ, + − f x, v +
dx dx dx dx
xj−1+α Z
≤ xj−2+α
1/2
xj−1+α Z
×
˜ (x)k2 dx k˜ u(x) − v
2
˜ k1,2,eα + c3 k˜ u−v
xj−2+α
√ ˆ k1,2,eα k˜ ˜ k1,2,eα + c3 k˜ ˜ k21,2,eα , ≤ 2L kˆ u−v u−v u−v which yields √ π2 ˜ k1,2,eα ≤ 2Lkˆ ˆ k1,2,eα , k˜ u−v − c u−v 3 2 1+π √ 2L ˆ k1,2,eα . ˜ k1,2,eα ≤ kˆ u−v k˜ u−v c4 c1
The formulas (4.18), (4.19) and the inequality kuk20,2,ˆωh ≤
1 kux¯ k20,2,ˆω+ imply h 8
ku − vk1,2,(0,1) ˜ k1,2,(0,1) + kˆ ˆ k1,2,(0,1) ≤ k˜ u−v u−v r √ √ 2L 3 c2 2L ˆ k1,2,(0,1) ≤ kˆ u−v 1+ kux − v x¯ k0,2,ˆω+ . ≤ 1+ h c4 2 c1 c4 Taking into account (4.18), (4.20) we obtain, with an arbitrary vector z, (Ah (x, u) − Ah (x, v), z)ωˆ h √ √ c22 2L kux¯ − v x¯ k0,2,ˆω+ kzk0,2,ˆωh ≤ ku − vkBh kzkBh + 2 3L 2 1 + h c1 c4 r √ 3 c22 2L L 2 1+ kux¯ − v x¯ k0,2,ˆω+ kz x¯ k0,2,ˆω+ ≤ ku − vkBh kzkBh + h h 2 c1 c4 # " r √ 3 c22 2L L 1+ ku − vkBh kzkBh . ≤ 1+ 2 c31 c4
4.2. Existence of a three-point EDS def
Setting here z = Bh−1 (Ah (x, u) − Ah (x, v)) we get "
r
kBh−1 (Ah (x, u) − Ah (x, v))kBh ≤ 1 +
3 c22 L 2 c31
√ # 2L 1+ ku − vkBh . (4.21) c4
Now the estimates (4.21), (4.14) imply Ah (x, u) − Ah (x, v) , Bh−1 (Ah (x, u) − Ah (x, v)) "
r
≤ 1+
3 c22 L 2 c31
√ 2L 1+ c4
#2
ω ˆh
ku − vk2Bh
" r √ #2 3 c22 2L π 2 c2 L 3 1+ 1+ ≤ (Ah (x, u) − Ah (x, v), u − v)ωˆ h 2 1 + π c4 2 c1 c4 and due to the results from [74], p.502, the iteration method (4.12) converges in HBh and the error estimate (4.13) holds. ◦
Let us remember that the space HBh is equivalent to the space W21 (ˆ ωh ) , i.e. the corresponding norms satisfy γ1 kuk1,2,ˆωh ≤ kukBh ≤ γ2 kuk1,2,ˆωh . We can now formulate the following lemma. Lemma 4.3 Let the assumptions of Lemma 4.2 be satisfied. Then, the iteration method (4.12) converges and together with the estimate (4.13) the following relation holds:
du(n) du
(n)
K
− K ≤ M − u ≤ M qn,
u
dx dx 0,2,ωˆ¯ h 1,2,ˆ ωh where kuk0,2,ωˆ¯ h =
−1 NX
=
j=1
1/2 1 1 ~j kuj k2 + h1 ku0 k2 + hN kuN k2 2 2
N 1 X 2
j=1
hj
1/2 kuj k2 + kuj−1 k2 .
137
138
Chapter 4. 3-point difference schemes for systems of ODEs Proof. Using the relations Zxj j −1 du du d j K(ξ) dξ K = A u + V (x ) V (ξ) j x ¯,j j 1 1 dx x=xj dξ dξ xj−1
= Aj ux¯,j −
−1 V1j (xj )
Zxj
V1j (ξ)f
ξ, u(ξ),
du dξ
dξ,
xj−1
Zxj j−1 −1 du du d j−1 K(ξ) dξ K = A u − V (x ) V (ξ) j x ¯,j j−1 2 2 dx x=xj−1 dξ dξ xj−1
= Aj ux¯,j +
−1 V1j (xj )
Zxj
V2j−1 (ξ)f
ξ, u(ξ),
du dξ
dξ,
xj−1
together with (a + b)2 ≤ 2(a2 + b2 ), the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) as well as a Lipschitz condition, we deduce
du(n) du
K − K
dx dx 0,2,ωˆ¯ h ( =
N 1X (n) hj
Aj ux¯,j − Aj ux¯,j 2 j=1
−1 − V1j (xj )
Zxj
2
du du(n) − f ξ, u(ξ), dξ V1j (ξ) f ξ, u(n) (ξ),
dξ dξ
xj−1
N 1X (n) + hj Aj ux¯,j − Aj ux¯,j 2 j=1 −1 + V1j (xj )
Zxj
V2j−1 (ξ)
2 )1/2
du du (n) − f ξ, u(ξ), dξ f ξ, u (ξ),
dξ dξ
xj−1
( ≤
2
N X
N
2 X
−1
2 (n) hj Aj ux¯,j − Aj ux¯,j + hj V1j (xj )
j=1
" Zxj
j ×
V1 (ξ) xj−1
j=1
#2 (n)
du du (n)
f ξ, u (ξ),
dξ − f ξ, u(ξ),
dξ dξ
4.3. Implementation of the three-point EDS
+
N X
−1
2 hj V1j (xj )
j=1
" Zxj
j−1 ×
V2 (ξ)
#2 )1/2 (n)
du
f ξ, u(n) (ξ), du
dξ − f ξ, u(ξ),
dξ dξ
xj−1
( ≤
2
N X
N
2 X
−1
2 (n) hj Aj ux¯,j − Aj ux¯,j + hj V1j (xj )
j=1
j=1
Zxj
j 2 j−1 2 ×
V1 (ξ) + V2 (ξ) dξ xj−1
2 )1/2 Zxj (n)
du du (n)
dξ
f ξ, u (ξ), − f ξ, u(ξ), ×
dξ dξ xj−1
( ≤
2
N X
2
(n) hj Aj ux¯,j − Aj ux¯,j
j=1 N
X 2c2 + 22 L2 hj c1 j=1
≤
2 )1/2 Zxj
(n)
du du
(n)
u (ξ) − u(ξ) +
dξ − dξ dξ xj−1
√
(n)
2c2 ux¯ − ux¯
+ 0,2,ˆ ωh
+2
c2
L u(n) − u . c1 1,2,(0,1)
Now, inequality (4.20) and Lemma 4.2 imply √
√ √
du(n) du c22 2L
(n)
K
− K 1 + ≤ 2 c + 3 L
u − u 2 2
dx dx 0,2,ωˆ¯ h c1 c4 1,2,ˆ ωh
= M1 u(n) − u ≤ M qn , 1,2,ˆ ωh
which proves the claim.
4.3
Implementation of the three-point EDS
To simplify the structure of the formulas let us again use the abbreviations def
β = j + (−1)α ,
def
γ = j − 1 + α,
as we have already done in previous sections.
139
140
Chapter 4. 3-point difference schemes for systems of ODEs We begin our discussion with the following formula:
(−1)
Zxj
α+1
Vαj (ξ)f
du ξ, u(ξ), dξ
dξ (4.22)
xj+(−1)α
= (−1)α Vαj (xj )Z jα (xj , u) + Y jα (xj , u) − uβ , where Y jα (x, u), Z jα (x, u), α = 1, 2, are the solutions of the IVPs dY jα (x, u) = K −1 (x)Z jα (x, u), dx dZ jα (x, u) = −f x, Y jα (x, u), K −1 (x)Z jα (x, u) , dx du , Y jα (xβ , u) = uβ , Z jα (xβ , u) = K(x) dx x=xβ j = 2 − α, 3 − α, . . . , N + 1 − α,
x ∈ ejα , (4.23)
α = 1, 2,
def and the matrix functions V¯αj (x) = (−1)α+1 Vαj (x), α = 1, 2, are the solutions of the IVPs
dV¯αj (x) = K −1 (x), dx V¯αj (xβ ) = 0,
x ∈ ejα ,
j = 2 − α, 3 − α, . . . , N + 1 − α,
(4.24) α = 1, 2.
Using (4.22) the right-hand side of the EDS (4.9) can be represented in the form du def ˆ xj f ξ, u(ξ), ϕ(xj , u) = T dξ = ~−1 j
2 X
−1 j Y α (xj , u) − uβ . (−1)α Z jα (xj , u) + (−1)α Vαj (xj )
α=1
(4.25) ˆ¯ h Thus, in order to compute the input data of the EDS (4.9), (4.25) for all xj ∈ ω the four IVPs (4.23), (4.24) with smooth right-hand sides should be solved on intervals whose lengths are proportional to the maximum step size. The IVPs (4.23), (4.24) can be solved by a one-step method: ¯ Y (αm)j (xj , u) = uβ + (−1)α+1 hγ Φ1 xβ , uβ , (Ku0 )β , (−1)α+1 hγ , Z (m)j (xj , u) = (Ku0 )β + (−1)α+1 hγ Φ2 xβ , uβ , (Ku0 )β , (−1)α+1 hγ , α ¯ V¯α(m)j (xj ) = (−1)α+1 hγ Φ3 xβ , 0, (−1)α+1 hγ ,
(4.26)
4.3. Implementation of the three-point EDS where Φ1 (x, u, ξ, h), Φ2 (x, u, ξ, h), Φ3 (x, u, h) are the corresponding increment functions and du 0 . (Ku )β = K(x) dx x=xβ
Z jα (xj , u)
¯ Assume that approximates with order m, and Y (αm)j (xj , u), (m)j ¯ j j Vα (xj ) approximate Y α (xj , u), Vα (xj ), respectively, with order m. ¯
Z (m)j (xj , u) α
If K(x) and the right-hand side f (x, u, ξ) are sufficiently smooth then there exist the expansions ¯ ¯ ¯ Y jα (xj , u) = Y (αm)j (xj , u) + [(−1)α+1 hγ ]m+1 ψ jα (xβ , u) + O(hm+2 ), β j
˜ (xβ , u) + O(hm+2 ), Z jα (xj , u) = Z (m)j (xj , u) + [(−1)α+1 hγ ]m+1 ψ γ α α
(4.27)
¯ ¯ ¯ ψ¯αj (xβ ) + O(hm+2 (xj ) + [(−1)α+1 hγ ]m+1 ). V¯αj (xj ) = V¯α(m)j γ
In the case where the Taylor series method is used we have Φ1 xβ , uβ , (Ku0 )β , (−1)α+1 hγ = u0β −
m ¯ X (−1)α+1 hγ −1 [(−1)α+1 hγ ]p−1 dp Y jα (xβ , u) Kβ f (xβ , uβ , u0β ) + , 2 p! dxp p=3
Φ2 xβ , uβ , (Ku0 )β , (−1)α+1 hγ
m X [(−1)α+1 hγ ]p−1 dp Z jα (xβ , u) = −f xβ , uβ , u0β + , p! dxp p=2
Φ3 xβ , 0, (−1)α+1 hγ = K −1 (xβ ) +
m ¯ X [(−1)α+1 hγ ]p−1 dp−1 −1 K (x) . p! dxp−1 x=xj+(−1)α p=2
If an explicit Runge-Kutta method is used the increment functions are α+1 h γ = b1 g 1 + b2 g 2 + · · · + bs g s , Φ1 xβ , uβ , (Ku0 )α β , (−1) ¯ 1 + b2 g ¯ 2 + · · · + bs g ¯s, Φ2 xβ , uβ , (Ku0 )β , (−1)α+1 hγ = b1 g Φ3 xβ , 0, (−1)α+1 hγ = b1 g˜1 + b2 g˜2 + · · · + bs g˜s , where g˜i = K −1 xβ + ci (−1)α+1 hγ , i−1 X ¯p , aip g g i = g˜i (Ku0 )β + (−1)α+1 hγ p=1
141
142
Chapter 4. 3-point difference schemes for systems of ODEs i−1 X α+1 α+1 ¯ i = −f xβ + ci (−1) g hγ , uβ + (−1) hγ aip g p , g i ,
i = 1, 2, . . . , s.
p=1 ¯ In the next lemma the differences between Y jα (xj , u), Z jα (xj , u) and Y (αm)j (xj , u), (m)j Z α (xj , u), respectively, are studied.
Lemma 4.4 Suppose that 2
c1 kuk ≤ (K(x)u, u) ≤ c2 kuk
2
for all u ∈ Rn ,
krs (x) ∈ Qm+1 [0, 1],
N fr (x, u, ξ) ∈ ∪ Cm+1 [xj−1 , xj ] × R2n . j=1
If for the one-step method (4.26) the expansions (4.27) exist, then ¯ ¯ ¯ (xj , u) + (−1)α+1 hm+1 ψ γ1 (xβ , u) + O(hm+2 ), Y jα (xj , u) = Y (αm)j γ γ γ
˜ (xβ , u) + O(hm+2 ), (xj , u) + [(−1)α+1 hγ ]m+1 ψ Z jα (xj , u) = Z (m)j γ 1 α
(4.28)
¯ ¯ ¯ ψ¯1γ (xβ ) + O(hm+2 (xj ) + hm+1 ), Vαj (xj ) = Vα(m)j γ γ
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2.
Proof. Since the method (4.26) has order of accuracy m ¯ and the expansions (4.27) exist we have (m)j ¯
Y j1 (xj , u) − Y 1
(xj , u)
= Y j1 (xj , u) − u(xj − hj ) − hj Φ1 xj − hj , u(xj − hj ), Ku0 |x=xj −hj , hj ¯ ¯ ψ j1 (xj − hj , u) + O(hm+2 ), = hm+1 j j
(4.29) and (m)j
Z j1 (xj , u) − Z 1
(xj , u)
= Z j1 (xj , u) − Ku0 |x=xj −hj − hj Φ2 xj − hj , u(xj − hj ), Ku0 |x=xj −hj , hj j
˜ (xj − hj , u) + O(hm+2 ). = hm+1 ψ 1 j j (4.30) Note that (m)j ¯
Y j2 (xj , u) − Y 2
(xj , u)
= Y j2 (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , (Ku0 )j+1 , −hj+1 ) ,
4.3. Implementation of the three-point EDS (m)j
Z j2 (xj , u) − Z 2
(xj , u)
= Z j2 (xj , u) − (Ku0 )j+1 + hj+1 Φ2 (xj+1 , uj+1 , (Ku0 )j+1 , −hj+1 ) . Substituting −hj+1 instead of hj into (4.29), (4.30) and taking into account that Y j1 (xj , u) = Y j2 (xj , u),
Z j1 (xj , u) = Z j2 (xj , u),
we obtain Y j2 (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , (Ku0 )j+1 , −hj+1 ) j+1 ¯ m+2 ¯ = −hm+1 j+1 ψ 1 (xj+1 , u) + O(hj+1 ),
Z j2 (xj , u) − (Ku0 )j+1 + hj+1 Φ2 (xj+1 , uj+1 , (Ku0 )j+1 , −hj+1 ) j+1
˜ = (−1)m+1 hm+1 j+1 ψ 1
(xj+1 , u) + O(hm+2 j+1 ).
We have thus shown the first two relations in (4.28). Analogously one can prove the equality ¯ ¯ ¯ V¯αj (xj ) = V¯α(m)j (xj ) + (−1)α+1 hm+1 ), ψ¯1j−1+α (xβ ) + O(hm+2 γ γ
which together with V¯αj (x) = (−1)α+1 Vαj (x) gives the third relation in (4.28).
Based on the EDS (4.9), (4.25), we can now define the following TDS of the rank m ¯ (abbreviated to m-TDS ¯ hereafter): (m) ¯
¯ ¯ ¯ y x¯ )xˆ = −ϕ(m) (x, y (m) ), (A(m) ¯ y (m) (0) = µ1 ,
x∈ω ˆh, (4.31)
¯ y (m) (1) = µ2 ,
where h i−1 def (m)j ¯ ¯ A(m) (xj ) = hj V1 (xj ) , ¯ ϕ(m) (xj , u)
def
=
~−1 j
2 X
α
(−1)
Z (m)j (xj , u) α
+ (−1)
α
¯ Vα(m)j (xj )
−1 Y
(m)j ¯ (xj , u) α
− uβ .
α=1
In order to prove the order of accuracy of the m-TDS ¯ (4.31) we need the following auxiliary statement.
143
144
Chapter 4. 3-point difference schemes for systems of ODEs Lemma 4.5 Let the assumptions of Lemma 4.4 be fulfilled. Then the following estimates hold:
(m)
¯
A ¯ (xj ) − A(xj ) ≤ M hm , (4.32) and ¯ (xj , u) − ϕ(xj , u) ϕ(m) du j j j m+1 ˜ ¯ − ψ 1 (x, u) = hj K(x) ψ 1 (x, u) − ψ1 (x)K(x) dx x=xj +0 x ˆ
(4.33)
! m+2
+O
hm+2 + hj+1 j ~j
,
provided that m is odd, and ¯ ϕ(m) (xj , u) − ϕ(xj , u) du j j m ¯ = hj K(x) ψ 1 (x, u) − ψ1 (x)K(x) dx x=xj +0 x ˆ
+O
(4.34)
! hm+1 + hm+1 j j+1 , ~j
provided that m is even.
Proof. The inequality (4.32) follows from (4.27) due to h i−1 h ih i−1 (m)j ¯ (m)j ¯ ¯ ¯ V1j (xj ) − V1 (xj )−A(xj ) = hj V1j (xj ) (xj ) V1 (xj ) = O(hm A(m) j ). In order to prove (4.33), (4.34) we first want to note that ¯ (xj , u) − ϕ(xj , u) ϕ(m)
= ~−1 j
2 X
−1 j α ¯ Vα(m)j (−1)α Z (m)j (x , u) − Z (x , u) + (−1) (xj ) j j α α
α=1
−1 ¯ Y jα (xj , u) − uβ × Y (αm)j (xj , u) − uβ − Vαj (xj )
.
Lemma 3.4 and the equalities Y jα (xj , u) − uβ = (−1)α+1 hγ
du + O(h2γ ), dx x=xβ
i h i−1 h −1 j ¯ ¯ Y (αm)j Vα(m)j Y α (xj , u) − uβ (xj ) (xj , u) − uβ − Vαj (xj )
(4.35)
4.3. Implementation of the three-point EDS i −1 h (m)j Y α¯ (xj , u) − Y jα (xj , u) = Vαj (xj ) i ih i−1 h −1 h j ¯ ¯ ¯ Vα (xj ) − Vα(m)j Y (αm)j (xj ) Vα(m)j (xj ) (xj , u) − uβ , + Vαj (xj )
Vαj (xj )
−1
= h−1 γ Kβ + O(1),
h i−1 ¯ Vα(m)j (xj ) = h−1 γ Kβ + O(1)
imply m+1 γ ˜ (xβ , u) + O(hm+2 ), (xj , u) − Z jα (xj , u) = − (−1)α+1 hγ ψ Z (m)j α γ 1 and h i i−1 h −1 j ¯ ¯ Vα(m)j Y (αm)j Y α (xj , u) − uβ (xj ) (xj , u) − uβ − Vαj (xj ) (4.36) γ ¯ m+1 ¯ ¯γ (x)K(x) du = −(−1)α+1 hm K(x) ψ (x, u) − ψ + O(h ). γ γ 1 1 dx x=xβ Taking into account (4.36) we obtain from (4.35) ¯ (xj , u) − ϕ(xj , u) ϕ(m) 1 du j+1 j+1 j+1 m+1 ˜ ¯ − ψ 1 (x, u) = hj+1 K(x) ψ 1 (x, u) − ψ1 (x)K(x) ~j dx x=xj+1
−
hm+1 j
+O
du j j j ˜ ¯ − ψ 1 (x, u) K(x) ψ 1 (x, u) − ψ1 (x)K(x) dx x=xj−1
+ hm+2 hm+2 j j+1 ~j
!
(4.37) provided that m is odd, and ¯ ϕ(m) (xj , u) − ϕ(xj , u) 1 j+1 ¯j+1 (x)K(x) du = hm K(x) ψ (x, u) − ψ j+1 1 1 ~j dx x=xj+1
−
hm j
du K(x) ψ j1 (x, u) − ψ¯1j (x)K(x) +O dx x=xj−1
! hm+1 + hm+1 j j+1 ~j (4.38)
145
146
Chapter 4. 3-point difference schemes for systems of ODEs provided that m is even. Due to du K(x) ψ j1 (x, u) − ψ¯1j (x)K(x) dx x=xj−1 du j j ¯ = K(x) ψ 1 (x, u) − ψ1 (x)K(x) + O(hj ), dx x=xj ˜ j (xj , u) + O(hj ), ˜ j (xj−1 , u) = ψ ψ 1 1
the estimates (4.37), (4.38) yield (4.33), (4.34). We are now in a position to prove the following claim. Theorem 4.3
Let the assumptions of Theorem 4.1 and Lemma 4.4 be fulfilled. Then there def N exists an h0 > 0 such that for all {hj }j=1 , h = max hj ≤ h0 , the m-TDS ¯ 1≤j≤N
(4.31) has a unique solution for which the following error estimate holds:
∗
(m)
y ¯ − u
1,2,ˆ ωh
2
(m)
¯
= y − u
0,2,ˆ ωh
2
1/2 ¯
dy (m) du ¯
− K + K ≤ M hm , dx dx 0,2,ˆωh
where −1 ¯ dy (m) (m)0 (m)0 ¯ (m)0 ¯ (m) ¯ (m) ¯ (m) ¯ Y 2 (x0 , y ) − y 0 , K = Z 2 (x0 , y ) + V2 (x0 ) dx x=x0 −1 ¯ dy (m) (m)j (m)j ¯ (m) ¯ (m)j ¯ (m) ¯ (m) ¯ y j − Y 1 (xj , y ) , = Z 1 (xj , y ) + V1 (xj ) K dx x=xj j = 1, 2, . . . , N, and the constant M is independent of h.
Proof. Let us consider the operator (m) ¯
def
(m) ¯
¯ (x, u), Ah (x, u) = Bh u − ϕ(m)
From (4.32) – (4.34) we have (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), u − v
¯ = A(m) (ux¯ − v x¯ ) , ux¯ − v x¯
(m) ¯
def
¯ with Bh u = −(Am ux¯ )xˆ .
ω ˆh
¯ ¯ − ϕ(m) (x, u) − ϕ(m) (x, v), u − v
ω ˆh
ω ˆh m ¯
= (Ah (x, u) − Ah (x, v), u − v)ωˆ h + O h
4.3. Implementation of the three-point EDS and formula (4.11) shows that there exists a h0 > 0 such that for all {hj }N j=1 , with h ≤ h0 , it holds that 2 ¯ u, u , 0 < c˜1 kuk0,2,ˆωh ≤ A(m) ω ˆh
(m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), u − v
2
2
≥ c ku − vkB(m) ≥ 8c˜ c1 ku − vk0,2,ˆωh , ¯
ω ˆh
h
(4.39) (m) ¯ Ah (x, u)
where 0 < c < 1. Therefore, under the assumption h ≤ h0 the operator is strongly monotone, i.e. for h ≤ h0 the m-TDS ¯ (4.31) has a unique solution ¯ y (m) (x), x ∈ ω ˆ h (see, e.g. [82], p.461). def
¯ The error function z(x) = y (m) (x) − u(x), x ∈ ω ˆ h , is the solution of the problem h i ¯ ¯ ¯ ¯ A(m) (x)z x¯ (x) + ϕ(m) (x, y (m) ) − ϕ(m) (x, u) x ˆ
¯ = ϕ(x, u) − ϕ(m) (x, u) +
h
i ¯ A(x) − A(m) (x) ux¯ (x) ,
(4.40)
x ˆ
z(0) = z(1) = 0. From (4.40) we obtain (m) ¯ (m) ¯ ¯ Ah (x, u) − Ah (x, y (m) ), z ω ˆh
=
(m) ¯
ϕ(x, u) − ϕ
(x, u), z
+
(m) ¯
− A ux¯ , z x¯
A
(4.41)
. + ω ˆh
ω ˆh
Due to (4.39) we have (m) ¯ (m) ¯ ¯ Ah (x, u) − Ah (x, y (m) ), z
2
≥ c kzkB(m) ¯ .
ω ˆh
(4.42)
h
Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) and (4.32) – (4.34), we deduce for the right-hand side of (4.41)
¯
(m) ¯ A − A ux¯ , z x¯ ≤ A(m) − A kux¯ k0,2,ˆω+ kz x¯ k0,2,ˆω+
h
¯ ϕ(x, u) − ϕ(m) (x, u), z
h
(4.43) ¯ ≤ M hm kz x¯ k0,2,ˆω+
h
0,2,ˆ ωh
ω ˆh
¯ M hm ≤ kzkB (m) ¯ , h c˜1
≤ M hm+1 kz x¯ k0,2,ˆω+ ≤ ω ˆh
provided that m is odd, and ¯ ϕ(x, u) − ϕ(m) (x, u), z ω ˆh
h
≤ M hm kz x¯ k0,2,ˆω+ ≤ h
M hm+1 kzkB(m) (4.44) ¯ , h c˜1
M hm kzkB (m) ¯ , h c˜1
(4.45)
147
148
Chapter 4. 3-point difference schemes for systems of ODEs ¯ provided that m is even. The estimates (4.42) – (4.45) yield kzkB (m) ≤ M hm . ¯ h
Taking into account the equivalence of the norms k·k1,2,ωˆ h and k·kB (m) ¯ , we obtain h
¯ kzk1,2,ωˆ h ≤ M hm . (m) ¯
(m) ¯
¯ ¯ = Y 02 (x0 , y (m) ) and y j = Y j1 (xj , y (m) ), the formulas (4.28) imply
dz
(m)0
¯ ¯ ¯ ) − Z 02 (x0 , y (m) ) + Z 02 (x0 , y (m) ) − Z 02 (x0 , u)
K
≤ Z 2 (x0 , y (m)
dx x=x0
Since y 0
h
i−1
(m)0
¯ (m)0 ¯ 0 (m) ¯ (m) ¯
+ V2 (x0 ) (x , y ) − Y (x , y )
Y
0 0 2 2
∂ 0 ¯ m ¯
kzk ≤ M1 hm Z + (x , u) 0,2,ˆ ωh ≤ M2 h ,
∂u 2 0 ˜ u=u
dz
(m)j
¯ ¯ ¯ ) − Z j1 (xj , y (m) ) + Z j1 (xj , y (m) ) − Z j1 (xj , u)
K
≤ Z 1 (xj , y (m)
dx x=xj
h
i−1
(m)j
¯ (m)j ¯ j (m) ¯ (m) ¯
+ V1 (xj ) (x , y ) − Y (x , y )
Y
j j 1 1
∂ j
≤ M3 h + Z 1 (xj , u) ∂u m ¯
˜ u=u
m ¯
kzk 0,2,ˆ ωh ≤ M4 h ,
j = 1, 2, . . . , N,
dz dz
¯
K K ≤ max ,
≤ M hm
dx j=0,1,...,N
dx ˆ 0,2,ω ¯h x=xj ∗
¯ and we obtain kzk1,2,ˆωh ≤ M hm . This completes the proof.
The nonlinear m-TDS ¯ (4.31) can be solved by an iteration method which is given in the following theorem. Theorem 4.4 Let the assumptions of Theorem 4.3 be fulfilled. Then: ¯ • the function ϕ(m) satisfies the Lipschitz condition
(m)
¯ ˜ ku − vk (x, v) ≤L
ϕ ¯ (x, u) − ϕ(m) 0,2,ˆ ωh , 0,2,ˆ ωh
• there exists a h0 > 0 such that for all {hj }N j=1 , with h ≤ h0 , it holds that ¯ u, u , 0 < c˜1 kuk20,2,ˆωh ≤ A(m) 0,2,ˆ ωh
(m) ¯
(m) ¯
Ah (x, u) − Ah (x, v), u − v
ω ˆh
2
≥ c ku − vkB (m) ¯ , h
0 < c < 1,
4.3. Implementation of the three-point EDS • the following iteration method converges: ¯ y (m,0) (x) = V2 (x) [V1 (1)] (m) ¯
Bh
−1
µ1 + V1 (x) [V1 (1)]
−1
µ2 ,
¯ ¯ y (m,n) − y (m,n−1) (m) ¯ ¯ + Ah (x, y (m,n−1) ) = 0, τ
¯ (0) = µ1 , y (m,n)
¯ y (m,n) (1) = µ2 ,
x∈ω ˆh,
(4.46)
n = 1, 2, . . . ,
where def
(m) ¯
¯ Bh y = −(A(m) y x¯ )xˆ ,
(m) ¯
def
(m) ¯
¯ Ah (x, y) = Bh y − ϕ(m) (x, y),
˜ −2 L τ = τ0 = c 1 + . 8˜ c1
def
• the corresponding error can be estimated by
∗
def √
(m,n) ¯ ≤ M (hm + q n ), q = 1 − cτ0 ,
y ¯ − u
(4.47)
1,2,ω ˆh
where ¯ dy (m,n) K dx x=x0 (m)0
= Z2 K
i h i−1 h (m)0 ¯ (m)0 ¯ (m,n) ¯ ¯ ¯ Y 2 (x0 , y (m,n) , (x0 , y (m,n) ) + V2 (x0 ) ) − y0
¯ dy (m,n) dx (m)j
= Z1
x=xj
h i−1 h i (m)j ¯ (m,n) ¯ (m)j ¯ ¯ ¯ yj (xj , y (m,n) ) + V1 (xj ) − Y 1 (xj , y (m,n) ) ,
j = 1, 2, . . . , N, (4.48) and the constant M does not depend on h, m and n.
Proof. Due to Theorem 4.3 we have
∗
(m,n)
y ¯ − u
1,2,ˆ ωh
∗
¯
≤ y (m) − u
1,2,ˆ ωh
∗
¯ ¯ + y (m,n) − y (m)
1,2,ˆ ωh
∗
¯ ¯ ¯ ≤ M hm + y (m,n) − y (m)
1,2,ω ˆh
.
(4.49)
149
150
Chapter 4. 3-point difference schemes for systems of ODEs N The assumption fr (x, u, ξ) ∈ ∪ Cm [xj−1 , xj ] × R2n yields j=1
(m) ˜ ¯ (x, v) ≤ L |u − v| . ϕ ¯ (x, u) − ϕ(m) Using the Cauchy-Bunyakovsky-Schwarz inequality (see Theorem 1.8) we obtain (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v), w ω ˆh
≤ ku − vkB (m) ¯ kwk (m) ¯ B h
h
¯
¯ + ϕ(m) (x, u) − ϕ(m) (x, v)
0,2,ˆ ωh
kwk0,2,ˆωh
˜ ≤ ku − vkB (m) ¯ kwk (m) ¯ + L ku − vk 0,2,ˆ ωh kwk0,2,ˆ ωh B h
h
≤ ku − vkB (m) ¯ kwk (m) ¯ + B h
h
˜ L kux¯ − v x¯ k0,2,ˆω+ kw x¯ k0,2,ˆω+ h h 8
˜ L ku − vkB(m) ≤ 1+ ¯ kwk (m) ¯ . Bh h 8˜ c1 def
(m) ¯ −1
With w = Bh
(m) ¯ (m) ¯ Ah (x, u) − Ah (x, v) , this yields
−1
(m)
(m) ¯ (m) ¯
B ¯
A (x, u) − A (x, v) h h
h
≤ (m) ¯
Bh
˜ L ku − vkB (m) 1+ (4.50) ¯ . h 8˜ c1
From the relations (4.40) and (4.50) we have −1 (m) ¯ (m) ¯ (m) ¯ (m) ¯ (m) ¯ Ah (x, u) − Ah (x, v) Ah (x, u) − Ah (x, v), Bh ω ˆh
≤
˜ 2 L 1+ ku − vk2B (m) ¯ 8˜ c1 h
1 ≤ c
˜ 2 (m) L ¯ (m) ¯ 1+ Ah (x, u) − Ah (x, v), u − v . 8˜ c1 ω ˆh
Therefore, (see, e.g. [74], p.502) the iteration method (4.46) converges in the space ◦ 1 HB (m) ωh ), and the following estimate holds: ¯ , which is equivalent to the space W2 (ˆ h
(m,n) ¯
y ¯ − y (m)
1,2,ˆ ωh
Moreover, we have
¯ ¯ dy (m,n) dy (m)
− K
K
dx dx x=x0 x=x0
≤ M1 q n .
4.3. Implementation of the three-point EDS
(m)0 (m)0 ¯ ¯ ) − Z 2 (x0 , y (m) ) ≤ Z 2 (x0 , y (m,n)
h
i−1
(m)0 ¯ (m)0 ¯ (m)0 ¯ (m,n) ¯ (m) ¯
+ V2 (x0 ) (x , y ) − Y (x , y )
Y
0 0 2 2
"
∂
h i−1
(m)0 (m)0 ¯
≤ Z (x0 , u) (x0 )
+ V2
∂u 2
u=˜ y
#
∂
(m)0 ¯ Y 2 (x0 , u)
∂u
u=¯ y
¯ ¯ × y (m,n) − y (m)
0,2,ˆ ωh
¯ ¯ ≤ M1 y (m,n) − y (m)
, 1,2,ˆ ωh
¯ ¯ dy (m,n) dy (m)
− K
K
dx dx x=xj x=xj
(m)j (m)j ¯ ¯ ≤ Z 1 (xj , y (m,n) ) − Z 1 (xj , y (m) )
h
i−1
(m)j
(m)j ¯ ¯ (m)j ¯ (m,n) ¯ (m) ¯
+ V (x ) (x , y ) − Y (x , y )
Y
j j j 1 1
1
"
∂
h i−1
(m)j (m)j ¯
≤ Z 1 (xj , u) + V (x )
1 j
∂u
u=˜ y
#
∂
(m)j ¯ Y 1 (xj , u)
∂u
u=¯ y
¯ ¯ × y (m,n) − y (m)
0,2,ω ˆh
¯ ¯ ≤ M2 y (m,n) − y (m)
,
j = 1, 2, . . . , N,
0,2,ˆ ωh
¯ (m) ¯ (m,n) ¯ (m) ¯
dy (m,n) dy dy dy
K
K − K ≤ max − K
j=0,1,...,N
dx dx 0,2,ωˆ¯ h dx dx x=xj x=xj
¯ ¯ ≤ M y (m,n) − y (m)
which yields
∗
(m,n) ¯
y ¯ − y (m)
, 1,2,ˆ ωh
≤ M qn .
(4.51)
1,2,ˆ ωh
The estimates (4.49) and (4.51) imply (4.47).
A derivative-free variant of Newton’s method is usually used to numerically solve the m-TDS ¯ (4.31). It can be realized as follows. Substituting the approximate solutions (4.26) into the right-hand side of the difference scheme (4.31), we obtain ¯ ϕ(m) (xj , u)
151
152
Chapter 4. 3-point difference schemes for systems of ODEs = ~−1 j
2 X
(−1)α {(Ku0 )β + (−1)α+1 hγ Φ2 (xβ , uβ , (Ku0 )β , (−1)α+1 hγ )
α=1
− [Φ3 (xβ , 0, (−1)α+1 hγ )]−1 Φ1 (xβ , uβ , (Ku0 )β , (−1)α+1 hγ )}. From (4.27) we get 1 ∂Φ1 (x, u, ξ, 0) = − K −1 (x)f (x, u, ξ), ∂h 2
Φ1 (x, u, ξ, 0) = K −1 (x)ξ,
Φ3 (x, 0, 0) = K −1 (x),
Φ2 (x, u, ξ, 0) = −f (x, u, ξ), and therefore
(m) ¯ xj , y j ,
¯ ¯ (xj , y (m) )=f ϕ(m)
! ¯ dy (m) +O dx x=xj
h2γ ~j
¯ dy (m) (m) ¯ = y x¯,j + O dx x=xj
h2γ ~j
! ,
! .
The discrete Newton’s method now reads (m,n) ¯
∇y 0
= 0,
(m,n) ¯
¯ A(m) ∇y x¯
(m,n) ¯
∇y N
= 0, (m,n−1) ¯ (m,n−1) ¯ ∂f xj , y j , y˙ j
+
(m,n−1) ¯ (m,n−1) ¯ ∂f xj , y j , y˙ j +
(m,n) ¯
∇y j
∂u
x ˆ,j
(4.52)
(m,n) ¯
∇y x¯,j
∂ξ
(m,n−1) ¯ ¯ ¯ ¯ xj , y (m,n−1) − A(m) = −ϕ(m) y x¯
j = 1, 2, . . . , N − 1,
, x ˆ,j
(m,n) ¯
yj
(m,n−1) ¯
= yj
(m,n) ¯
+ ∇y j
,
j = 0, 1, . . . , N,
n = 1, 2, . . . ,
where the derivatives def (m,n−1) ¯ = y˙ j
¯ dy (m,n−1) dx
x=xj
can be computed by formula (4.48). Note that the convergence of Newton’s method for systems of ODEs with a monotone operator has been investigated in [48].
4.4. Numerical examples
4.4
Numerical examples
Example 4.1. Let us consider the BVP [43] d2 u1 = u1 + 3 exp(u2 ), dx2 u1 (0) = 0,
d2 u2 = u1 − exp(u2 ) + exp(−x), dx2
u1 (1) = exp(−2) − exp(−1),
u2 (0) = 0,
(4.53)
u2 (1) = −2
with the exact solution u1 (x) = exp(−2x) − exp(−x),
u2 (x) = −2x.
In order to solve problem (4.53) numerically on the equidistant grid ωh we used the following 6-TDS: (6)
y x¯x = −ϕ(6) (x, y (6) ),
y (6) (0) = µ1 ,
x ∈ ωh ,
y (6) (1) = µ2 ,
(4.54)
where ϕ(6) (xj , u) = h−1
2 X
i (−1)α h (6)j , Y (−1)α Z (6)j (x , u) + (x , u) − u j j β α α h α=1
(6)j and Y (6)j α (xj , u), Z α (xj , u) are the numerical solutions of the IVPs
dY jα (x, u) = Zαj (x, u), dx Y jα (xβ , u) = uβ ,
dZ jα (x, u) = −f (x, Y jα (x, u), Z jα (x, u)), dx
x ∈ ejα ,
Z jα (xβ , u) = u0β ,
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2, (4.55)
with f (x, Y
def j j α (x, u), Z α (x, u)) =
−
j j Yα,1 + 3 exp(Yα,2 ) j j Yα,1 − exp(Yα,2 ) + exp(−x)
! .
We have solved the IVP (4.55) with the explicit 7-stage Runge-Kutta method of order 6 which is characterized by the Butcher matrix given in Table 2.4. For the numerical solution of the TDS (4.54) we used the Newton method (4.52). Table 4.1 contains the numerical results obtained by this TDS. Here, we have used the formulas
(6) ∗
z
∗ def (6) ∗ def
(6)
1,2,ωh er = z = y − u and p = log2
z (6) ∗ 1,2,ωh 1,2,ωh 1,2,ω h/2
to measure the error and the order of convergence, respectively. One can see that the numerical results are in a good agreement with our theory.
153
154
Chapter 4. 3-point difference schemes for systems of ODEs N
er
p
4 8 16 32
0.2848 E − 5 0.4400 E − 7 0.6907 E − 9 0.1081 E − 10
6.0 6.0 6.0
Table 4.1: Numerical results for problem (4.53)
Example 4.2. Let us consider the problem d2 u1 = u2 , dx2 u1 (0) = 0,
d2 u2 12 = 6 exp(−4u1 ) − , 2 dx (1 + x)4 u(1) = ln(2),
u2 (0) = −1,
0 < x < 1, (4.56)
u2 (1) = −0.25,
with the exact solution u1 (x) = ln(1 + x),
u2 (x) = −
1 . (1 + x)2
This BVP was solved by the above mentioned 6-TDS on the equidistant grid ωh using the same IVP-solver as in the previous examples. In order to gain the prescribed order of accuracy EP S, Runge’s h − h/2-strategy was used. Table 4.2 contains numerical results which are in complete agreement with our theory. EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8 1.0 E − 10
N
Error
4 4 16 32
0.1365 E − 5 0.2634 E − 6 0.2341 E − 9 0.2398 E − 11
Table 4.2: Numerical results for problem (4.56)
Example 4.3. The next example is the BVP (see [29]) d2 u1 = λ2 u1 + u2 + x + (1 − λ2 ) exp(−x), dx2 d2 u2 = −u1 + exp(u2 ) + exp(−λx), dx2 u1 (0) = 2,
u1 (1) = exp(−λ) + exp(−1),
u2 (0) = 0,
u2 (1) = −1,
(4.57)
4.4. Numerical examples with the exact solution u1 (x) = exp(−λx) + exp(−x),
u2 (x) = −x.
The BVP (4.57) is monotone since (f (x, u, ξ) − f (x, v, η), u − v) = −λ2 (u1 − v1 )2 − exp(θu2 + (1 − θ)v2 )(u2 − v2 )2 ≤ 0. Note that the Lipschitz constant of the right-hand side of the ODE (4.57) in a √ neighborhood of the exact solution is L = λ4 + 3 > 1. Table 4.3 and Table 4.4 contain the numerical results obtained by the 6-TDS (4.54) for the BVP (4.57) with λ = 500 and λ = 1000, respectively. EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8
N
Error
1000 2000 4000
0.4406 E − 5 0.1315 E − 6 0.1380 E − 9
Table 4.3: Numerical results for problem (4.57) with λ = 500
EPS 1.0 E − 4 1.0 E − 6 1.0 E − 8
N
Error
2000 4000 8000
0.4411 E − 5 0.1316 E − 7 0.2239 E − 9
Table 4.4: Numerical results for problem (4.57) with λ = 1000 Example 4.4. Finally, let us consider the following singularly perturbed BVP (see [85]): du1 d2 u1 + u1 + 0.5 exp(−u2 ) + f1 (x), ε 2 = dx dx ε
du2 d2 u2 =2 + 0.5u1 + exp(u2 ) + f2 (x), dx2 dx
u1 (0) = exp(−1/ε) + 1,
u1 (1) = 1,
u2 (0) = exp(−2/ε + 1) + 1, with the exact solution u1 (x) = exp (x − 1)/ε + cos(0.5πx),
(4.58)
u2 (1) = 0,
u2 (x) = − exp 2(x − 1)/ε + 1 + exp(x).
155
156
Chapter 4. 3-point difference schemes for systems of ODEs The numerical results obtained by the 6-TDS (4.54) are given in Table 4.5. ε 1.0 E1 1.0 E1 1.0 E − 1 1.0 E − 1
EPS 1.0 E − 3 1.0 E − 5 1.0 E − 3 1.0 E − 5
N
Error
100 400 6400 25600
0.3731 E − 3 0.3701 E − 5 0.2684 E − 4 0.5148 E − 5
Table 4.5: Numerical results for problem (4.58)
157
Chapter 5
Difference schemes for nonlinear BVPs on the half-axis One thing I have learned in a long life: that all our science, measured against reality, is primitive and childlike - and yet it is the most precious thing we have. Albert Einstein (1879–1955)
In this chapter we generalize the idea of the exact difference schemes to BVPs which are defined on the half axis. Let us consider the following scalar nonlinear BVP on the infinite interval [0, ∞), d2 u − m2 u = −f (x, u), dx2 u(0) = µ1 ,
x ∈ (0, ∞),
u(x) ∈ R, (5.1)
lim u(x) = 0,
x→∞
where m 6= 0 is a real constant. We will develop three-point EDS which are defined on non-uniform grids under the assumption that the function f (x, u) in (5.1) is sufficiently smooth between a finite number of discontinuity points with respect to the first variable. Moreover, the practical implementation of the EDS by n-TDS of order of accuracy n ¯ = 2[(n + 1)/2] is proposed. As before the freely selectable natural number n is called the rank of the TDS.
I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_5, © Springer Basel AG 2011
157
158
Chapter 5. Difference schemes for BVPs on the half-axis
5.1
Existence and uniqueness of the solution
In [1, p. 83] sufficient conditions for the existence of a solution of the (vector-) problem d2 u − m2 u = −f (x, u), dx2 u(0) = µ1 ,
u(x) ∈ Rn ,
x ∈ (0, ∞),
lim u(x) = 0,
x→∞
are given. Below, we use Banach’s Fixed Point Theorem (see Theorem 1.1) to find more constructive conditions guaranteeing not only the existence but also the uniqueness of solutions of the BVP (5.1). Let us introduce the function def
u(0) (x) = µ1 exp(−m x),
(5.2)
the set def
Ω(D, β) =
u(x) : u ∈ C [0, ∞), u − u(0)
1
≤ β, D ⊆ [0, ∞) ,
1,D
)
(
kuk1,D
du
= max kuk0,D ,
dx
def
,
def
kuk0,D = max |u(x)|, x∈D
0,D
and the class Q(0) [0, ∞) of piecewise continuous functions with a finite number of discontinuity points of first kind. The next theorem gives sufficient conditions under which the problem (5.1) has a unique solution in the sphere Ω(D, r). Theorem 5.1 Suppose the following hypotheses are satisfied: def
• for all x ∈ [0, ∞) and for all u ∈ Ω([0, ∞), r), r = K1 max{1/m2 , 1/m}, it holds that def
fu (x) = f (x, u) ∈ Q0 [0, ∞),
|f (x, u)| ≤ K(x) ≤ K1 ,
(5.3)
• it is lim e
−mx
Zx
mξ
e
x→∞
0
mx
Z∞
K(ξ)dξ = lim e x→∞
e−mξ K(ξ)dξ = 0,
(5.4)
x
• for all x ∈ [0, ∞) and for all u, v ∈ Ω([0, ∞), r) it holds that |f (x, u) − f (x, v)| ≤ L1 |u − v|,
(5.5)
5.1. Existence and uniqueness of the solution • and
def
q = L1 max{1/m2 , 1/m} < 1.
(5.6)
Under these hypotheses the BVP (5.1) has a unique solution u(x) ∈ Ω([0, ∞), r) which is the limit of the sequence {u(k) (x)}∞ k=0 defined by the starting function (5.2) and the fixed point iteration d2 u(k) − m2 u(k) = −f x, u(k−1) , 2 dx (k)
u
(k)
(0) = µ1 ,
lim u
x→∞
(x) = 0,
x ∈ (0, ∞), (5.7)
k = 1, 2, . . . .
Moreover, the error estimate
(k)
u − u
≤
1,[0,∞)
qk r 1−q
(5.8)
holds. Proof. We transform problem (5.1) into the equivalent integral form Z∞ u(x) = <(x, u(·)) =
G(x, ξ)f (ξ, u(ξ))dξ + u(0) (x),
x ≥ 0,
(5.9)
0
where
sinh (mx) exp (−mξ) , 0 ≤ x ≤ ξ, m G (x, ξ) = exp (−mx) sinh (mξ) , x ≥ ξ m is the Green’s function of the linear, homogeneous part of problem (5.1).
(5.10)
Let us show that the operator (5.9) transforms the set Ω ([0, ∞) , r) into itself. Taking into account the equalities Z∞
1 − exp(−mx) G(x, ξ)dξ = , m2
0
Z∞
∂G(x, ξ) exp(−mx) dξ = , ∂x m
0
we get, for all v ∈ Ω([0, ∞), r),
<(x, v(·)) − u(0)
1,[0,∞)
∞
Z
≤ K1 G(x, ξ)dξ
0
≤ r.
1,[0,∞)
Moreover, the operator <(x, u(·)) is contractive on the set Ω([0, ∞), r), since for all u, v ∈ Ω([0, ∞), r) we have k<(x, u(·)) − <(x, v(·))k1,[0,∞) ≤ q ku − vk1,[0,∞) ,
159
160
Chapter 5. Difference schemes for BVPs on the half-axis def
provided that q = L1 max{1/m2 , 1/m} < 1. Thus, <(x, u(·)) satisfies all the conditions of Banach’s Fixed Point Theorem (see Theorem 1.1) with q < 1. This implies that the equation (5.9) possesses a unique solution which is the fixed point of the sequence (5.7) with the error estimate (5.8). By standard arguments it is easy to show that the solution of (5.9) satisfies the ODE and the boundary condition u(0) = µ1 , and as a result of (5.3) it also satisfies the boundary condition at infinity. Example 5.1. Let us consider the BVP d2 u − m2 u = −f (x, u), dx2 u(0) = µ1 ,
(5.11)
lim u(x) = 0,
x→∞
with def
f (x, u) =
u2 1 + x2
(5.12)
and m > 4µ1 ,
µ1 > 0,
m > 1.
(5.13)
In that case the set Ω([0, ∞), r) is the ball of all u(x) satisfying |u(x) − µ1 e−mx | ≤ r, i.e., |u(x)| ≤ µ1 e−mx + r ≤ µ1 + r.
(5.14)
This implies the inequality (µ1 + r)2 def def = K(x) ≤ (µ1 + r)2 = K1 1 + x2
|f (x, u)| ≤
(5.15)
which together with the condition r = K1 max
1 1 , m2 m
=
K1 m
determines the value of r in dependence of the input data µ1 and m. Thus we have r=
(µ1 + r)2 m
which implies r
r1,2
m ± = −µ1 + 2
r
m
µ2 r1 > 0. m m + − µ −µ1 + m 1 2 4
m
m 4
− µ1 .
We choose the root m − r = −µ1 + 2
m
4
− µ1 =
5.1. Existence and uniqueness of the solution From the inequality |f (x, u) − f (x, v)| ≤
|(u − v)(u + v)| ≤ 2(µ1 + r) |u − v| 1 + x2 def
we obtain the Lipschitz constant L1 = 2(µ1 + r). The inequality (5.6) now reads r r 2(µ1 + r) 2 m m 4µ1 def L1 = = − m − µ1 q = =1− 1− m m m 2 4 m and due to (5.13) we have q < 1, i.e. the condition (5.6) is fulfilled. It remains to check the conditions (5.4). Using (5.4) and L’Hospital’s rule we obtain lim e−mx
x→∞
lim emx
x→∞
x
Z 0
e (µ1 + r)2 emξ dξ = lim x→∞ 1 + ξ2
∞
Z
2
(µ1 + r) dξ = lim x→∞ 1 + ξ2
e−mξ x
+ r)2 1 + x2 = 0, memx
mx (µ1
(µ1 + r)2 1 + x2 = 0. me−mx
e−mx
Thus, the assumptions of Theorem 5.1 are satisfied and problem (5.11), under the assumptions (5.13), possesses a unique solution in Ω([0, ∞), r) which can be determined by the fixed point iteration. In many cases the determination of variable bounds on the solution is of great interest. In order to develop such bounds we introduce the tubular set def
Ω([0, ∞), p(x), r(x)) = {u(x) ∈ C[0, ∞) : p(x) ≤ u(x) ≤ r(x)} and postulate the following conditions on the function f (x, u) in (5.1): • Let for all u(x), v(x) ∈ Ω([0, ∞), p(x), r(x)) and x ∈ [0, ∞) exist functions p(x), r(x) and L(x) such that Z∞ p(x) ≤
G(x, ξ)f (ξ, u(ξ))dξ + u(0) (x) ≤ r(x),
(5.16)
0
and |f (x, u) − f (x, v)| ≤ L(x) |u − v|,
(5.17)
where G(x, ξ) is Green’s function given in (5.10). • Assume that the function L(x) satisfies Z∞ G(x, ξ) L(ξ)dξ ≤ L1 < 1, for all x ∈ [0, ∞). 0
(5.18)
161
162
Chapter 5. Difference schemes for BVPs on the half-axis In the following theorem sufficient conditions for the unique solvability of problem (5.1) in Ω([0, ∞), p(x), r(x)) are given. Theorem 5.2 Suppose that for all x ∈ [0, ∞) and for all u ∈ Ω([0, ∞), p(x), r(x)) it holds that def
fu (x) = f (x, u) ∈ Q0 [0, ∞),
|f (x, u)| ≤ K(x).
Moreover, let the conditions (5.4), (5.16)–(5.18) be satisfied. Then problem (5.1) has a unique solution u(x) ∈ Ω([0, ∞), p(x), r(x)) which can be determined by the fixed point iteration.
Proof. Under the assumptions formulated above the operator Z∞ <(x, u(·)) =
G(x, ξ)f (ξ, u(ξ))dξ + u(0) (x),
x ≥ 0,
0
transforms the set Ω([0, ∞), p(x), r(x)) into itself and is contractive. Banach’s Fixed Point Theorem (see Theorem 1.1) yields the claim of the theorem. The next example illustrates Theorem 5.2. Example 5.2. We consider again the BVP (5.11) for µ1 > 0 and 2µ1 /m2 < 1, with the objective of finding functions p(x) and r(x) which serve as estimates for the exact solution at each local point x. Since G(x, ξ) and the function f (x, u) are positive we can choose p(x) ≡ 0 in (5.16). The second inequality in (5.16) implies the following condition on the function r(x): x
Z 0
u2 (ξ) G(x, ξ) dξ + µ1 e−mx ≤ 1 + ξ2
x
Z
G(x, ξ)r2 (ξ)dξ + µ1 e−mx ≤ r(x). 0
We look for a solution of the second inequality and use the ansatz r(x) = c e−mx , where c is an unknown constant. Substituting this ansatz into the inequality we obtain Z x
G(x, ξ)e−2mξ dξ + µ1 e−mx ≤ ce−mx .
c2
0
Obviously, to calculate the integral it is sufficient to solve the BVP d2 u − m2 u = −e−2mx , dx2
u(0) = 0, u(∞) = 0.
Thus, c2 e−mx − e−2mx + µ1 e−mx ≤ ce−mx . 2 2m
(5.19)
5.1. Existence and uniqueness of the solution It follows that
c2 1 − e−mx + µ1 − c ≤ 0, 2 2m which in particular holds true for c satisfying c2 − c + µ1 = 0. 2m2 We choose
r 1− c=
1−
2µ1 m2
1 m2
2µ r 1
=
1−
1+
and obtain
2µ r 1
r(x) = 1+
1−
2µ1 m2
e−mx .
2µ1 m2
The estimate |u − v| |u + v| 2r(x) ≤ |u − v| 1 + x2 1 + x2
|f (x, u) − f (x, v)| ≤ and formula (5.17) imply L(x) =
2r(x) e−mx = 2c . 1 + x2 1 + x2
It can easily be seen that |f (x, u)| ≤ K(x) with
r 2 (x) . 1 + x2 The conditions (5.4) can be checked in the same way as in Example 5.1. Condition (5.18) is fulfilled since Z ∞ Z ∞ Z ∞ e−mξ G(x, ξ)L(ξ)dξ = 2c G(x, ξ) dξ ≤ 2c G(x, ξ)e−mξ dξ 2 1 + ξ 0 0 0 K(x) =
=
=
c 1 −1 1 2c −mx xe e = 2 ≤ 2m m m m e α 1 √ <1 e 1+ 1−α
for α =
2µ1 r 1+
1−
2µ1 m2
2µ1 < 1. m2
Now, Theorem 5.2 states that 2µ r 1
0 ≤ u(x) ≤ 1+
2µ1 1− 2 m
e−mx
for all x ∈ [0, ∞).
163
164
Chapter 5. Difference schemes for BVPs on the half-axis
5.2
Existence of a three-point EDS
ˆ¯ h and the corresponding On the interval [0, ∞) we use the non-uniform closed grid ω open grid ω ˆ h such that the discontinuity points (with respect to the first argument) of the function f (x, u) coincide with grid points. This means that N has to be chosen such that ρ ⊆ ω ˆ h , where ρ denotes the set of all discontinuity points. def
Let h = hmax and hmin denote the maximum and minimum step size, respecˆ¯ h satisfy tively. We assume that the step sizes hj and the corresponding grid ω c1 ≤
hmax ≤ c2 , hmin
(5.20)
where c1 and c2 are real constants. In order to obtain maximum order of convergence of our EDS (see Theorem 5.4), we postulate 1 hmax
≤ xN ≤
1 hmin
.
(5.21)
The inequality hmin N ≤ xN = h1 + h2 + · · · + hN ≤ hmax N together with (5.21) imply 1 1 1 1 ≤ , ≤ ≤ hmax . hmin ≤ xN N hmin N hmax xN Due to (5.20) we further obtain 1 hmax ≤ hmin ≤ √ , c2 N
1 c2 hmin ≥ hmax ≥ √ , N
which yields c2 1 hmax ≤ √ , hmin ≥ √ , N c2 N √ √ N ≤ hmin N ≤ xN ≤ hmax N ≤ c2 N . c2 Thus, we have hmax → 0 and xN → ∞ as N → ∞.
(5.22)
We now introduce the set of grid functions n o ˆ¯ h , β) def ˆ Ω(ω = v(x), x ∈ ω ¯ h : kv − u(0) k1,ˆω+ ≤ β , h
where o n def kyk1,ˆω+ = max kyk0,ˆω+ , kyx¯ k0,ˆω+ , h
h
def
kyk0,ωˆ¯ h = max |yj | , 0≤j≤N
h
def
kyk0,ˆω+ = max |yj | , 1≤j≤N
h
def
def
ω ˆ h+ = ω ˆ h ∪ xN .
yx¯,j = (yj − yj−1 )/hj ,
Moreover, in the following we use again the abbreviations def
e¯jα = [xj−2+α , xj−1+α ],
def
e¯j = [xj−1 , xj ],
def
e¯N 2 = [xN , ∞);
ejα , ej , and eN 2 are the corresponding open intervals, resp.
(5.23)
5.2. Existence of an EDS Let the BVPs d2 Yαj (x, v) − m2 Yαj (x, v) = −f x, Yαj (x, v) , dx2 Yαj (xj−2+α , v) = v(xj−2+α ), j = 2 − α, . . . , N + 1 − α,
x ∈ ejα , (5.24)
Yαj (xj−1+α , v) = v(xj−1+α ), α = 1, 2,
on subintervals of the length O(h) and the problem d2 Y2N (x, v) − m2 Y2N (x, v) = −f x, Y2N (x, v) , dx2 Y2N (xN , v)
= v(xN ),
lim
x→∞
Y2N (x, v)
x ∈ eN 2 , (5.25)
= 0,
on the interval [xN , ∞) be given. The following lemma shows that the exact solution of problem (5.1) can be expressed on each subinterval by the solutions of (5.24) and (5.25). Lemma 5.1 ˆ¯ h , r) be Suppose that the hypotheses of Theorem 5.1 are satisfied. Let v(x) ∈ Ω(ω an arbitrary grid function. Then problems (5.24) and (5.25) have unique solutions Yαj (x, v) ∈ Ω(¯ ejα , r), j = 2 − α, . . . , N + 1 − α, α = 1, 2 and Y2N (x, v) ∈ Ω(¯ eN 2 , r). Furthermore, the solution of problem (5.1) can be represented in the form ( j Yα (x, u), x ∈ e¯jα , j = 2 − α(1)N + 1 − α, α = 1, 2, u(x) = (5.26) Y2N (x, u), x ∈ e¯N 2 , provided that condition (5.6) is satisfied.
Proof. Problems (5.24) and (5.25) are equivalent to the operator equations Uαj (x)
=
def <jα (x, v, Uαj ) =
xj−1+α Z
Gj−1+α (x, ξ)f ξ, Uαj (ξ) dξ + vˆ(x),
x ∈ ejα ,
xj−2+α
j = 2 − α, . . . , N + 1 − α, def
vˆ(x) =
α = 1, 2,
v(xj ) sinh(m(x − xj−1 )) + v(xj−1 ) sinh(m(xj − x)) , sinh(mhj )
x ∈ [xj−1 , xj ],
j = 1, . . . , N, U2N (x)
=
N def
Z∞ xN
x ∈ eN 2 ,
G∞ (x, ξ)f ξ, U2N (ξ) dξ + v(xN )e−m(x−xN ) ,
165
166
Chapter 5. Difference schemes for BVPs on the half-axis where Gj−1+α (x, ξ) sinh(m(x − xj−2+α )) sinh(m(xj−1+α − ξ)) , m sinh(mhj−1+α ) def = sinh(m(xj−1+α − x)) sinh(m(ξ − xj−2+α )) , m sinh(mhj−1+α ) G∞ (x, ξ) sinh(m(x − xN )) exp(−m(ξ − xN )) , m def = exp(−m(x − xN )) sinh(m(ξ − xN )) , m
xj−2+α ≤ x ≤ ξ, ξ ≤ x ≤ xj−1+α ,
xN ≤ x ≤ ξ, x ≥ ξ.
Note that u(0) (x) = µ1 exp(−mx) =
u(0) (xj ) sinh(m(x − xj−1 )) + u(0) (xj−1 ) sinh(m(xj − x)) sinh(mhj )
=u ˆ(0) (x). We now study the properties of the operators <jα (x, v, Uαj ), α = 1, 2, j = 2 − α, . . . , N + 1 − α,
N and
Let Uαj (x) ∈ Ω(ejα , r) and U2N (x) ∈ Ω(eN 2 , r), then the equalities xj−1+α Z
Gj−1+α (x, ξ)dξ
xj−2+α
= Z∞
1 sinh(m(x − xj−2+α )) + sinh(m(xj−1+α − x)) , 1 − m2 sinh(mhj−1+α ) G∞ (x, ξ)dξ =
1 − exp(−m(x − xN )) , m2
xN
imply
j
<α (x, v, Uαj ) − u(0)
1,ejα
≤
(0)
v − u
j−1+α j−1+α sinh(m(x − xj−2+α ))
sinh(mhj−1+α )
5.2. Existence of an EDS
+
(0) vj−2+α − uj−2+α sinh(m(xj−1+α − x)) sinh(mhj−1+α )
j−1+α G (x, ξ) dξ
xj−1+α Z
+ K1 xj−2+α
≤r
1,ejα
ˆ¯ h , r), for all v ∈ Ω(ω
N
<2 (x, v, U2N ) − u(0)
1,eN 2
Z∞
(0) ∞
≤ vN − u (xN ) exp(−m(x − xN )) + K1 G (x, ξ)dξ
xN
≤r
1,eN 2
ˆ for all v ∈ Ω(ω ¯ h , r).
ˆ h , r) the operators <jα (x, v, Uαj ), j = 2 − α, . . . , N + 1 − α, Thus, for all v ∈ Ω(ω ¯ N α = 1, 2, and <2 (x, v, U2N ) transform the sets Ω(ejα , r) and Ω(eN 2 , r), respectively, into themselves. ˜ j (x) ∈ Ω(ej , r) we have the estimates Moreover, for all U j (x), U α
α
α
j ˜j j
<α x, v, Uαj − <jα x, v, U α 1,e
α
L1 sinh(m(x − xj−2+α )) + sinh(m(xj−1+α − x))
U j − U ˜j j ≤ 1 − α α 1,eα
2 sinh(mhj−1+α ) 1,ejα m
˜j j , ≤ q Uαj − U α 1,e α
˜ N (x) ∈ Ω(eN , r) it holds that and for all U2N (x), U 2 2
N N
< x, v, U ˜N N −
L1 ˜N N k1 − exp(−m(x − xN ))k1,eN U2N − U 2 1,e 2 2 2 m
N ˜2N N . ≤ q U2 − U 1,e ≤
2
We see that the operators <jα x, v, Uαj , j = 2 − α, . .. , N + 1 − α, α = 1, 2, are N contractive on Ω(ejα , r), and the operator
j = 1, . . . , N − 1,
(5.27)
167
168
Chapter 5. Difference schemes for BVPs on the half-axis −a(xN )ux¯,N = β2 uN − µ2 (xN , u),
u0 = µ1 ,
(5.28)
where mhj exp(mhN ) − 1 def , j = 1, . . . , N, β2 = m , sinh(mhj ) sinh(mhN ) cosh(mhj ) − 1 cosh(mhj+1 ) − 1 def m + , j = 1, . . . , N − 1, d(xj ) = ~j sinh(mhj ) sinh(mhj+1 (5.29) def
a(xj ) =
ϕ(xj , u) = Tˆ xj (f (ξ, u(ξ))),
j = 1, . . . , N − 1,
µ2 (xN , u) = Tˆ˜ xN (f (ξ, u(ξ))),
(5.30)
with def Tˆxj (f (ξ, u(ξ))) =
1 ~j sinh(mhj )
Zxj sinh(m(ξ − xj−1 ))f (ξ, u(ξ))dξ xj−1
1 + ~j sinh(mhj+1 )
xZj+1
sinh(m(xj+1 − ξ))f (ξ, u(ξ))dξ, xj
j = 1, . . . , N − 1, def Tˆ˜ xN (f (ξ, u(ξ))) =
1 sinh(mhN )
ZxN sinh(m(ξ − xN−1 ))f (ξ, u(ξ))dξ xN −1
Z∞ exp(−m(ξ − xN ))f (ξ, u(ξ))dξ.
+ xN
The function u(ξ) on the right-hand side of (5.27) is given by (5.26) and depends only on u0 , u1 , . . . , uN . Proof. It can easily be seen that Tˆ xj (u00 − m2 u) = (aux¯ )xˆ,j − d(xj )uj ,
j = 1, . . . , N − 1,
Tˆ˜xN (u00 − m2 u) = −a(xN )ux¯,N − β2 uN . Applying the operators Tˆxj , j = 1, . . . , N − 1, and Tˆ˜ xN to the ODE u00 − m2 u = −f (x, u), we obtain the three-point EDS (5.27). The following lemma claims the uniqueness of the solution of the EDS (5.27).
5.2. Existence of an EDS Lemma 5.2 Suppose that the assumptions of Theorem 5.3 are satisfied. Then there exists ˆ¯ h , r) the an h0 > 0 such that for all h ≤ h0 and all grid functions u(x) ∈ Ω(ω (k) EDS (5.27) has a unique solution which is the limit of the sequence {u (x)}∞ k=0 defined by
(k)
aux¯
(k)
x ˆ,j
− d(xj )uj
( u
j = 1, . . . , N − 1,
(k) (k) ˜ xN f ξ, u(k−1) (ξ) , −a(xN )ux¯,N = β2 uN − Tˆ
(k)
u0 = µ1 , (k)
= −Tˆ xj f ξ, u(k−1) (ξ) ,
(x) =
Yαj x, u(k) , x ∈ e¯jα , Y2N x, u(k) , x ∈ e¯N 2
(5.31)
j = 2 − α, . . . , N + 1 − α,
α = 1, 2,
u(0) (x) = µ1 exp(−mx). Moreover, the following error estimate holds: ) (
(k)
∗
du du
(k)
(k)
− ≤ M q1k ,
u − u + = max u − u + , dx dx 0,ωˆ + 1,ˆ ωh 0,ˆ ωh
(5.32)
h
def
where q1 = q + M1 h < 1 and M , M1 are some constants. Proof. For the proof we use Banach’s Fixed Point Theorem (see Theorem 1.1). We represent the solution of the auxiliary problem (a˜ ux¯ )xˆ − d(x)˜ u = −Tˆx (˜ u00 − m2 u ˜), u ˜(0) = µ1 ,
x∈ω ˆ h+ ,
(5.33)
u ˜(xN +1 ) = 0
as u ˜(x) =
N X i=1
sinh(m(xN+1 − x)) ˜ h (x, xi )Tˆ xi (f (η, u µ1 , ~i G ˜(η))) + sinh(mxN +1 )
x∈ω ˆ h+ , (5.34)
˜ h (x, ξ) is Green’s function of problem (5.33), i.e., where G sinh(m x) sinh(m(xN +1 − ξ)) , 0 ≤ x ≤ ξ, m sinh(m xN+1 ) h ˜ G (x, ξ) = sinh(m(xN+1 − x)) sinh(m ξ) , ξ ≤ x ≤ xN+1 . m sinh(m xN+1 ) Considering the equation (5.34) for xN +1 → ∞, we get the solution of problem (5.27)
169
170
Chapter 5. Difference schemes for BVPs on the half-axis u(x) =
=
N X
~i G(x, xi )Tˆxi (f (η, u(η))) + G(x, xN )Tˆ˜ xN (f (η, u(η))) + u(0) (x),
i=1
ω ˆ h+ .
for all x ∈ Here G(x, ξ) is Green’s function of the linear homogeneous part of problem (5.1). Let us study the operator
˜ xN (w(η))Q(xN ) ~i Tˆ xi (w(η))Q(xi ) + Tˆ
i=1 N X
1 Q(xi ) = sinh(m hi ) i=1
+
N −1 X i=1
Zxi sinh(m(η − xi−1 ))w(η)dη xi−1
1 Q(xi ) sinh(m hi+1 )
x Zi+1
sinh(m(xi+1 − η))w(η)dη xi
Z∞ exp(−m(η − xN ))w(η)dη
+ Q(xN )
(5.35)
xN
N Zxi X sinh(m(η − xi−1 )) sinh(m(xi − η)) + Q(xi−1 ) w(η)dη Q(xi ) = sinh(m hi ) sinh(m hi ) i=1 x
i−1
Z∞ + Q(xN )
exp(−m(η − xN ))w(η)dη.
xN
Due to (5.35), we have
i−1
× f (η, u(η))dη sinh(m x) exp(−m xN ) + m
Z∞ xN
exp(−m(η − xN ))f (η, u(η))dη + u(0) (x)
(5.36)
5.2. Existence of an EDS
=
N Zxi X
Z∞ G(x, η)f (η, u(η))dη +
i=1 x
=
(5.37)
xN
i−1
Z∞
G(x, η)f (η, u(η))dη + u(0) (x)
G(x, η)f (η, u(η))dη + u(0) (x),
x∈ω ˆ h+ ,
0
where u(η) = Y1i (η, u),
η ∈ e¯i ,
u ˆ(η) = Y2N (η, u),
i = 1, . . . , N,
η ∈ e¯N 2 .
ˆ ˆ¯ h , r), then The operator (5.37) transforms the set Ω(ω ¯ h , r) into itself. Let v ∈ Ω(ω v(x) = Y1i (x, v) ∈ Ω(¯ ej , r),
vˆ(x) = Y2N (x, v) ∈ Ω(¯ eN 2 , r)
(see the proof of Lemma 5.1). Since Z∞ G(x, η)dη =
1 − exp(−m x) , m2
0
Z∞
Zx
1 Gx¯ (x, η)dη = m h(x)
0
exp(−m η)dη ≤
exp(−m(x − h(x))) , m
x−h(x)
ˆ we have, for all v ∈ Ω(ω ¯ h , r),
+ 1,ˆ ωh
∞
Z
≤ K1 G(x, η)dη
0
≤ r.
+ 1,ˆ ωh
ˆ Furthermore we have, for all u, v ∈ Ω(ω ¯ h , r), k
Let us now show that ku − vk0,[0,∞) ≤ (1 + M h)ku − vk0,ˆω+ . h
Using the splitting u(x) = u ˆ(x) + u ˘(x), where def
u ˆ(x) =
u(xj ) sinh(m(x − xj−1 )) − u(xj−1 ) sinh(m(xj − x)) , sinh(mhj )
(5.38)
171
172
Chapter 5. Difference schemes for BVPs on the half-axis def
ˆ(x) for x ∈ e¯j , u ˘(x) = Y1j (x, u) − u
j = 1, . . . , N,
and def
u ˆ(x) = u(xN ) exp(−m(x − xN )),
def
u ˘(x) = Y2N (x, u) − u ˆ(x) for x ∈ e¯N 2 ,
we transform the problems d2 u − m2 u = −f (x, u), dx2
x ∈ ej ,
d2 u − m2 u = −f (x, u), dx2
x ∈ eN 2 ,
u(xj−1 ) = uj−1 , u(xN ) = uN ,
u(xj ) = uj ,
j = 1, . . . , N,
lim u(x) = 0
x→∞
into the form d2 u ˘ − m2 u ˘ = −f (x, u ˆ(x) + u ˘(x)), dx2
x ∈ ej , u ˘(xj−1 ) = u ˘(xj ) = 0, j = 1, . . . , N,
d2 u ˘ − m2 u ˘ = −f (x, u ˆ(x) + u ˘(x)), dx2
x ∈ eN 2 ,
u ˘(xN ) = 0,
lim u ˘(x) = 0.
x→∞
Then Zxj
Gj (x, ξ)f (ξ, u ˆ(ξ) + u ˘(ξ))dξ,
x ∈ ej ,
G∞ (x, ξ)f (ξ, u ˆ(ξ) + u ˘(ξ))dξ,
x ∈ eN 2 ,
u ˘(x) =
j = 1, . . . , N,
xj−1
Z∞ u ˘(x) = xN
where sinh(m(x − xj−1 )) sinh(m(xj − ξ)) , m sinh(m hj ) Gj (x, ξ) = sinh(m(xj − x)) sinh(m(ξ − xj−1 )) , m sinh(m hj )
xj−1 ≤ x ≤ ξ, ξ ≤ x ≤ xj ,
sinh(m(x − xN )) exp(−m(ξ − xN )) , m G∞ (x, ξ) = exp(−m(x − xN )) sinh(m(ξ − xN )) , m The Lipschitz condition yields k˘ u − v˘k1,¯ej h i u − vˆk0,¯ej + k˘ ≤ L1 kˆ u − v˘k0,¯ej
Zxj
j
G (x, ξ)dξ
xj−1
1,¯ ej
xN ≤ x ≤ ξ, x ≥ ξ.
5.2. Existence of an EDS
1 − cosh(m(xj + xj−1 )/2 − x) kˆ u − vˆk0,¯ej + k˘ u − v˘k0,¯ej
cosh(m hj /2) 1,¯ ej ≤ h q ku − vk0,ˆω+ + k˘ u − v˘k1,¯ej , j = 1, . . . , N, L1 = 2 m
h
k˘ u − v˘k1,¯eN 2 ≤ L1
h
Z∞ i
∞
|u(xN ) − v(xN )| + k˘ u − v˘k0,¯eN G (x, ξ)dξ
2
1,¯ eN 2
xN
. ≤ h q ku − vk0,ωˆ + + k˘ u − v˘k1,¯eN 2 h
This implies k˘ u − v˘k1,¯ej ≤
hq ku − vk0,ωˆ + ≤ h M2 ku − vk0,ˆω+ , h h 1 −hq (5.39)
k˘ u − v˘k1,¯eN 2
hq ku − vk0,ωˆ + ≤ h M3 ku − vk0,ˆω+ . ≤ h h 1 −hq
Now, the inequalities ku − vk0,¯ej ≤ kˆ u − vˆk0,¯ej + k˘ u − v˘k0,¯ej ≤ ku − vk0,ˆω+ + h M2 ku − vk0,ˆω+ , h
h
≤ ku − vk0,ˆω+ + h M3 ku − vk0,ˆω+ ku − vk0,¯eN 2 h
h
yield the estimate (5.38). Taking into account the inequality (5.38), we get k
h
h
def
Due to (5.6) it holds that q < 1. If h0 is small enough we have q1 = q +M1 h < 1, ˆ¯ h , r). Thus, due to and the operator (5.37) is a contraction for all u, v ∈ Ω(ω Banach’s Fixed Point Theorem (see Theorem 1.1), for h0 small enough the EDS (5.27) has a unique solution which is the fixed point of the sequence (5.31) with the error estimate
q1k
(k)
r. (5.40)
u − u + ≤ 1 − q1 1,ˆ ωh
173
174
Chapter 5. Difference schemes for BVPs on the half-axis Moreover, due to (5.39), (5.40) we have
(k)
du du
dx − dx + 0,ˆ ω h
(k)
(k)
dˆ
d˘ dˆ u u u
u − d˘ − ≤ +
dx dx 0,ˆω+ dx dx 0,ˆω+ h
(k)
≤ M4 ux¯ − ux¯
h
+ 0,ˆ ωh
≤ M6 u(k) − u
+ 1,ˆ ωh
+ M5 u(k) − u
+ 0,ˆ ωh
(k)
+ h max{M2 , M3 } ˘ u −u ˘
≤ M q1k , (5.41)
which proves the estimate (5.32).
5.3
1,¯ eN 2
Implementation of the three-point EDS
First we want to remember that the right-hand side of the EDS is given by ϕ(xj , u) = Tˆxj (f (ξ, u(ξ))) " 1 m(cosh(m hj )Y1j (xj , u) − uj−1 ) = Z2j (xj , u) − Z1j (xj , u) + ~j sinh(m hj ) # m(cosh(m hj+1 )Y2j (xj , u) − uj+1 ) , + sinh(m hj+1 )
j = 1, . . . , N − 1,
where def
Zαj (x, u) =
dYαj (x, u) , dx
α = 1, 2.
The right-hand side of the difference equation at xN is given by ˜ xN (f (ξ, u(ξ)), µ2 (xN , u) = Tˆ with
5.3. Implementation of the three-point EDS Tˆ˜ xN (f (ξ, u(ξ)) = Z2N (xN , u) + m Y2N (xN , u) − Z1N (xN , u) +
m(cosh(m hN )Y1N (xN , u) − uN −1 ) . sinh(m hN )
In order to evaluate the EDS (5.27) for all xj ∈ ω ˆ h it is necessary to solve the problems (5.24) and (5.25) with vj = uj , j = 0, . . . , N . It is algorithmically more preferable (because of the well-developed theory and software) to deal with IVPs instead of BVPs. Therefore, we transform (5.24) and (5.25) into the following IVPs on subintervals of the length O(h): dYαj (x, u) = Zαj (x, u), dx
dZαj (x, u) − m2 Yαj (x, u) = −f x, Yαj (x, u) , x ∈ ejα , dx du Yαj (xβ , u) = u(xβ ), Zαj (xβ , u) = , j = 2 − α, . . . , N + 1 − α, α = 1, 2, dx x=xβ (5.42) and dZ2N (x, u) dY2N (x, u) = Z2N (x, u), − m2 Y2N (x, u) = −f (x, Y2N (x, u)), dx dx Y2N (xN , u) = u(xN ),
x ∈ eN 2 ,
lim Y2N (x, u) = 0.
x→∞
(5.43) For the solution of problems (5.42) (which are equivalent to (5.24)) we use a one-step method (e.g., the Taylor series method or a Runge-Kutta method) of order n with the corresponding increment function Φ = (Φ1 , Φ2 )T : Yα(¯n)j (xj , u) = uβ + (−1)α+1 hγ Φ1 (xβ , uβ , u0β , (−1)α+1 hγ ), (5.44) Zα(n)j (xj , u) = u0β + (−1)α+1 hγ Φ2 (xβ , uβ , u0β , (−1)α+1 hγ ). (n)j
Thus, the value Zα
(xj , u) approximates Zαj (xj , u) at least with order of accuracy
(¯ n)j Yα (xj , u)
def
n and approximates Yαj (xj , u) with order of accuracy n ¯ = 2[(n + 1)/2]. If the function f (x, u) is sufficiently smooth then there exist expansions n¯ +1 Yαj (xj , u) = Yα(¯n)j (xj , u) + ψαj (xβ , u) (−1)α+1 hγ + O(hnγ¯ +2 ) (5.45) and n+1 + O(hn+2 ). Zαj (xj , u) = Zα(n)j (xj , u) + ψ˜αj (xβ , u) (−1)α+1 hγ γ For the Taylor series method we have Φ1 xβ , uβ , u0β , (−1)α+1 hγ =
u0β
p−1 n ¯ X (−1)α+1 hγ dp Yαj (xβ , u) (−1)α+1 hγ 2 m uβ − fβ + + , 2 p! dxp p=3
(5.46)
175
176
Chapter 5. Difference schemes for BVPs on the half-axis Φ2 xβ , uβ , u0β , (−1)α+1 hγ
p−1 n X (−1)α+1 hγ dp Zαj (xβ , u) = m uβ − fβ + , p! dxp p=2 2
and for an explicit Runge-Kutta-Nystrom method it holds that Φ1 xβ , uβ , u0β , (−1)α+1 hγ = u0β + (−1)α+1 hγ (¯b1 k1 + ¯b2 k2 + · · · + ¯bs ks ), Φ2 xβ , uβ , u0β , (−1)α+1 hγ = b1 k1 + b2 k2 + · · · + bs ks , k1 = f˜(xβ , uβ ), k2 = f˜(xβ + c2 (−1)α+1 hγ , uβ + c2 (−1)α+1 hγ u0β + h2γ a21 k1 ), .. . ks = f˜(xβ + cs (−1)α+1 hγ , uβ + cs (−1)α+1 hγ u0β + h2γ (as1 k1 + as2 k2 + · · · + as,s−1 ks−1 )). f˜(x, u) = m2 u − f (x, u). Let us now find an approximation of the solution of problem (5.43) which is equivalent to (5.25). The following assumptions on the function f (x, u) will be significant for our subsequent considerations. Assumption 5.1. (a) f (x, u) is analytic in a neighborhood of the point (∞, 0), and (b) lim fu0 (x, 0) = 0.
x→∞
We represent the exact solution of problem (5.43) in the form Y2N (x, u) =
∞ X Ai i=1
xi
+ r(x),
Z2N (x, u) = −
∞ X iAi + r 0 (x), i+1 x i=1
(5.47)
where r(x) ∈ C∞ [xN , ∞) and lim xn r(x) = 0 for all n ∈ N0 . x→∞
Inserting
Y2N (x, u) def
F (x, {A}) =
into (5.43), we obtain
∞ X i(i + 1)Ai i=1
xi+2
− m2
∞ X Ai i=1
xi
+f
x,
∞ X Ai i=1
xi
! + r(x)
+ r00 (x) − m2 r(x) = 0, def
where {A} = A1 , A2 , . . . .
5.3. Implementation of the three-point EDS def We change the variables by t = 1/x and write F˜ (t, {A}) = F (1/t, {A}). Taking into account Assumption 5.1, we get for the coefficients Ai , i = 1, 2, . . ., the recurrent system of equations dk F˜ (t, {A}) = 0, k = 1, 2, . . . . (5.48) dtk t=0
Note, if the ODE in (5.1) is autonomous, then system (5.48) possesses only the trivial solution. A look at formula (5.47) suggests the use of the following ansatz for the approximate solution of problem (5.43): (¯ n−1)N
Y2
(x, u) =
(¯ n−1)N Z2 (x, u)
A2 A1 An¯ −1 + 2 + · · · + n¯ −1 , x x x
(5.49)
A1 2A2 (¯ n − 2)An¯ −2 = − 2 − 3 − ··· − . x x xn¯ −1
The unknown coefficients A1 , A2 , . . . , An¯ −1 can successively be determined from (5.48), whereby two cases are possible. In the first case all the coefficients A1 , A2 , . . . , An¯ −1 are equal to zero. Then (¯ n−1)N
Y2
(x, u) ≡ 0,
(¯ n−1)N
Z2
(x, u) ≡ 0.
In the second case at least one of the coefficients A1 , A2 , . . . , An¯ −1 is not equal to zero. This situation arises if ∞ X fi f (x, 0) = , i x i=1
∞ X
|fi |2 6= 0
i=1
and the solution is represented by (5.49). The method just described can be realized with a computer algebra system, like Maple or Mathematica. However, the coefficients Ai are often known from the given problem. It is also possible to compute the coefficients numerically. For instance, in the paper [67] a numerical algorithm is proposed by which the coefficients can be computed automatically. (¯ n)j
The following lemma compares the approximate values Yα exact values Yαj , Zαj , respectively.
(¯ n)j
, Zα
with the
Lemma 5.3 Suppose that N
ej × Ω([0, ∞), r + ∆)) ∪ Cn+1 (¯ eN f (x, u) ∈ ∪ Cn+1 (¯ 2 × Ω([0, ∞), r + ∆)), j=1
Assumption 5.1 is satisfied, and there exist the expansions (5.45), (5.46) for the
177
178
Chapter 5. Difference schemes for BVPs on the half-axis numerical method (5.44). Then Yαj (xj , u) = Yα(¯n)j (xj , u) + (−1)α+1 ψ1γ (xβ , u)hnγ¯ +1 + O(hnγ¯ +2 ),
(5.50)
n+1 + O(hn+2 ), Zαj (xj , u) = Zα(n)j (xj , u) + ψ˜1γ (xβ , u) (−1)α+1 hγ γ
(5.51)
Y2N Z2N
(xN , u) =
(¯ n−1)N Y2
(xN , u) =
(¯ n−1)N Z2
(xN , u) + O (xN , u) + O
1 xN
n¯
1 xN
n¯
,
(5.52)
.
(5.53)
Proof. Due to (5.45), (5.46) we have (¯ n)j
Y1j (xj , u) − Y1
(xj , u)
= Y1j (xj , u) − u(xj − hj ) − hj Φ1 (xj − hj , u(xj − hj ), u0 (xj − hj ), hj ) = ψ1j (xj − hj , u)hnj¯ +1 + O hnj¯ +2 , (5.54) Z1j (xj , u)
−
(n)j Z1 (xj , u)
= Z1j (xj , u) − u0 (xj − hj ) − hj Φ2 (xj − hj , u(xj − hj ), u0 (xj − hj ), hj ) = ψ˜1j (xj − hj , u)hn+1 . + O hn+2 j j We note that (¯ n)j
Y2j (xj , u) − Y2
(n)j
Z2j (xj , u) − Z2
(xj , u) = Y2j (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , u0j+1 , −hj+1 ),
(xj , u) = Z2j (xj , u) − u0j+1 + hj+1 Φ2 (xj+1 , uj+1 , u0j+1 , −hj+1 ).
Let us substitute −hj+1 instead of hj into (5.54) and take into account that Y1j (xj , u) = Y2j (xj , u), Z1j (xj , u) = Z2j (xj , u) holds. We obtain Y2j (xj , u) − uj+1 + hj+1 Φ1 (xj+1 , uj+1 , u0j+1 , −hj+1 ) ¯ +1 + O hnj¯ +2 , = −ψ1j+1 (xj+1 , u)hnj+1 Z2j (xj , u) − u0j+1 + hj+1 Φ2 (xj+1 , uj+1 , u0j+1 , −hj+1 ) n+2 , = (−1)n+1 ψ˜1j+1 (xj+1 , u)hn+1 j+1 + O hj which yields (5.50), (5.51). The relations (5.52), (5.53) are true due to the expansions (5.47) and the equalities (5.49). Thus, the proof is complete.
5.3. Implementation of the three-point EDS Now, instead of the EDS (5.27) we can use the n-TDS (¯ n) (¯ n) ayx¯ − d(xj )yj = −ϕ(¯n) xj , y (¯n) , j = 1, . . . , N − 1, x ˆ,j
(¯ n)
y0
= µ1 ,
(5.55) (¯ n)
(¯ n)
(¯ n)
−a(xN )yx¯,N = β2 yN − µ2
xN , y (¯n) ,
where ϕ(¯n) (xj , u) (¯ n)j m cosh(m hj )Y1 (xj , u) − uj−1 1 (n)j (n)j Z = (xj , u) − Z1 (xj , u) + (5.56) ~j 2 sinh(m hj ) (¯ n)j m cosh(m hj+1 )Y2 (xj , u) − uj+1 . + sinh(m hj+1 ) If at least one of the coefficients A1 , A2 , . . . , An¯ −1 is not equal to zero, we have (¯ n)
µ2 (xN , u) (¯ n−1)N
(¯ n−1)N
(xN , u) + mY2 (xN , u) (¯ n)N m cosh(m hN )Y1 (xN , u) − uN −1 (n)N − Z1 (xN , u) + sinh(m hN )
= Z2
=
(5.57)
mA2 − A1 mAn¯ −1 − (¯ mA1 n − 2)An¯ −2 + + ··· + n ¯ −1 xN x2N xN (¯ n)N m cosh(m hN )Y1 (xN , u) − uN −1 (n)N . − Z1 (xN , u) + sinh(m hN )
Otherwise it holds that (¯ n)
(n)N
µ2 (xN , u) = −Z1
(xN , u) +
(¯ n)N m cosh(m hN )Y1 (xN , u) − uN −1 sinh(m hN )
. (5.58)
In order to obtain an error estimate for the n-TDS (5.55) we need the following lemma. Lemma 5.4 Suppose that the assumptions of Lemma 5.3 are satisfied. Then ϕ(¯n) (xj , u) − ϕ(xj , u) ( #) cosh(m h ) m h j j j j ψ1 (x, u) = hn+1 − ψ˜1 (x, u) j sinh(m hj ) x=xj +0 x=xj +0
x ˆ
+O
! hn+2 + hn+2 j j+1 ~j
(5.59)
179
180
Chapter 5. Difference schemes for BVPs on the half-axis if n is odd, and ϕ(¯n) (xj , u) − ϕ(xj , u) =
cosh(m hj ) j ψ1 (x, u) +O sinh(m hj ) x=xj +0 x ˆ
m hj hnj
hn+1 + hn+1 j j+1 ~j
!
(5.60)
if n is even. Furthermore, (¯n) µ2 (xN , u) − µ2 (xN , u) ≤ M
( n ¯
max h ,
1 xN
n¯ )! ,
N → ∞,
(¯n) ˆ ¯ h , r + ∆), ϕ (xj , u) ≤ K1 + M h for all u ∈ Ω(ω
(5.61)
(5.62)
(¯n) ϕ (xj , u) − ϕ(¯n) (xj , v) ≤ (L1 + M h)ku − vk0,ˆωh ˆ for all u, v ∈ Ω(ω ¯ h , r + ∆),
(5.63)
1 (¯n) µ2 (xN , u) ≤ K1 + M max h, xN ˆ¯ h , r + ∆), for all u ∈ Ω(ω
N → ∞,
(5.64)
1 (¯n) (¯ n) ku − vk0,ˆω+ , µ2 (xN , u) − µ2 (xN , v) ≤ L1 + M max h, h xN ˆ for all u, v ∈ Ω(ω ¯ h , r + ∆),
N → ∞,
(5.65)
where the constant M is independent of h and 1/xN . Proof. We begin with the proof of (5.59)–(5.61). We note that ϕ(¯n) (xj , u) − ϕ(xj , u) = ~−1 j
2 X
(−1)α Zα(n)j (xj , u) − Zαj (xj , u)
(5.66)
α=1
+ (−1)α
(¯ n)j m cosh(m hγ ) Yα (xj , u) − Yαj (xj , u) sinh(m hγ )
,
(¯ n)
µ2 (xN , u) − µ2 (xN , u) (¯ n−1)N
= Z2
(n)N
− Z1
(¯ n−1)N (xN , u) − Z2N (xN , u) + m Y2 (xN , u) − Y2N (xN , u) (xN , u)
(5.67)
5.3. Implementation of the three-point EDS
+ Z1N (xN , u) +
h i (¯ n)N m cosh(m hN ) Y1 (xN , u) − Y1N (xN , u) sinh(m hN )
.
(5.68)
The relations (5.66) for n odd imply ϕ(¯n) (xj , u) − ϕ(xj , u) m cosh(m hj ) j 1 n+2 m cosh(m hj+1 ) j+1 ψ (xj+1 , u) − hn+2 ψ (xj−1 , u) = h j ~j j+1 sinh(m hj+1 ) 1 sinh(m hj ) 1 ! n+2 n+2 h + h j j+1 j+1 j ˜ (xj+1 , u) + hn+1 ψ˜ (xj−1 , u) + O (5.69) − hn+1 1 j+1 ψ1 j ~j and for n even imply ϕ(¯n) (xj , u) − ϕ(xj , u) 1 n+1 m cosh(m hj+1 ) j+1 n+1 m cosh(m hj ) j ψ (xj+1 , u) − hj ψ (xj−1 , u) = h ~j j+1 sinh(m hj+1 ) 1 sinh(m hj ) 1 ! + hn+1 hn+1 j j+1 . (5.70) +O ~j Taking into account ψ1j (xj−1 , u) = ψ1j (xj , u) + O(hj ),
ψ˜1j (xj−1 , u) = ψ˜1j (xj , u) + O(hj ),
the equalities (5.69) and(5.70) yield (5.59), (5.60). The inequality (5.61) is true due to (5.68) and because of the estimates (5.50) – (5.53). Let us now prove the inequalities (5.62) – (5.65). The conditions (5.45), (5.46) imply Φ1 (x, u, u0 , 0) = u0 ,
1 ∂Φ1 (x, u, u0 , 0) = (m2 u − f (x, u)), ∂h 2
Φ2 (x, u, u0 , 0) = m2 u − f (x, u). Thus, the following equations hold true: Yα(¯n)j (xj , u) = uβ + (−1)α+1 hγ Φ1 (v) + h2γ = uβ + (−1)α+1 hγ u0β +
∂Φ1 (v) (−1)α+1 h3γ ∂ 2 Φ1 (w) + ∂h 2 ∂h2
h2γ 2 (−1)α+1 h3γ ∂ 2 Φ1 (w) [m uβ − f (xβ , uβ )] + , 2 2 ∂h2
181
182
Chapter 5. Difference schemes for BVPs on the half-axis Zα(n)j (xj , u) = u0β + (−1)α+1 hγ Φ2 (v) + h2γ
∂Φ2 (w) ∂h
= u0β + (−1)α+1 hγ [m2 uβ − f (xβ , uβ )] + h2γ
∂Φ2 (w) , ∂h
where we have set def
v = (xβ , uβ , u0β , 0),
def
¯ w = (xβ , uβ , u0β , h).
Since ϕ(¯n) (xj , u) =
~−1 j
2 X
(
α=1
m hγ cosh(m hγ ) 0 uβ (−1) 1 − sinh(m hγ ) α
m hγ cosh(m hγ ) hγ f (xβ , uβ ) + 1− 2 sinh(m hγ ) m2 h2γ − 1 − m hγ sinh(m hγ ) m cosh(m hγ ) 1 + 2 uβ + sinh(m hγ ) ) m h3γ cosh(m hγ ) ∂ 2 Φ1 (w) 2 ∂Φ2 (w) + + hγ ∂h 2 sinh(m hγ ) ∂h2 2 1 X hγ f (xβ , uβ ) + O = ~j α=1 2
h2j + h2j+1 ~j
! ,
and (¯ n) µ2 (xN , u)
= hN
m hN cosh(m hN ) 1 fN −1 + O max hN , 1− , 2 sinh(m hN ) xN
we have (¯n) ϕ (xj , u) ≤ K1 + M h,
1 (¯n) . µ2 (xN , u) ≤ K1 + M max hN , xN
Let us prove the estimate (5.63). Since (¯n) ϕ (xj , u) − ϕ(¯n) (xj , v) 2 1 X ≤ ~j α=1
(
| sinh(m hγ ) − m hγ cosh(m hγ )| hγ |f (xβ , uβ ) − f (xβ , vβ )| 1 + 2 sinh(m hγ )
5.3. Implementation of the three-point EDS m hjγ cosh(m hγ ) 0 0 uβ − vβ + 1 − sinh(m hγ ) m2 h2γ − 1 − m hγ sinh(m hγ ) m cosh(m hγ ) 1 + 2 |uβ − vβ | + sinh(m hγ ) +
˜ ∂Φ2 (xβ , uβ , u0β , h)
h2γ
∂h
˜ ∂Φ2 (xβ , vβ , vβ0 , h) − ∂h
) ¯ ¯ ∂ 2 Φ1 (xβ , vβ , vβ0 , h) m h3γ cosh(m hγ ) ∂ 2 Φ1 (xβ , uβ , u0β , h) , + − 2 sinh(m hγ ) ∂h2 ∂h2 the Mean Value Theorem guarantees that there exist u ¯, u ¯0 , u ˜ and u ˜0 such that (¯n) ϕ (xj , u) − ϕ(¯n) (xj , v) ≤ (L1 + M h) ku − vk0,ωˆ + h
( 2 ˜ ∂ Φ2 (xβ , u ¯, u0β , h) + M2 h 1 + ∂h∂u
3 2 ¯ ˜ ∂ Φ1 (xβ , u ˜, u0β , h) ¯0 , h) ku − vk + + 1 + ∂ Φ2 (xβ , uβ , u + 0,ω ˆh ∂h2 ∂u ∂h∂u0 ) 3 0 ¯ ∂ Φ1 (xβ , uβ , u ˜ , h) ku − vk + . + 0,ω ˆh ∂h2 ∂u This together with the inequality (5.41) yields the estimates (5.63). Estimate (5.65) follows from (¯n) (¯ n) µ2 (xN , u) − µ2 (xN , v) hN 1 |f (xN −1 , uN −1 − f (xN−1 , vN−1 )| + M1 max h2N , ku − vk0,ˆω+ h 2 xN 1 ku − vk0,ˆω+ . ≤ L1 + M max hN , h xN ≤
The auxiliary results above provide the following second main result of this chapter.
183
184
Chapter 5. Difference schemes for BVPs on the half-axis Theorem 5.4 Under the hypotheses of Theorem 5.1 and Lemma 5.3, there exists a constant N0 > 0 such that for all N ≥ N0 the n-TDS (5.55) – (5.58), (5.44) possesses a unique solution. Moreover, if the grid satisfies the conditions (5.20) – (5.22), i.e., 1 ≤ h ≤ c2 N −1/2 , then the following error estimate holds: xN ) (
(¯n)
∗
dy du
(¯n)
(¯n)
−
y − u + = max y − u + , dx dx 0,ωˆ¯ h 1,ˆ ωh 0,ˆ ωh ( n ¯
≤ M max h ,
1 xN
n¯ )
≤ M hn¯ ≤ M N −¯n/2 , where dy
(¯ n)
(x0 ) (n)0 = Z2 x0 , y(¯n) + dx
(¯ n)0 (¯ n) m cosh(m h1 ) Y2 (x0 , y (¯n) ) − y0
dy (¯n) (xj ) (n)j = Z1 xj , y (¯n) + dx
sinh(m h1 ) (¯ n) (¯ n)j m cosh(m hj ) yj − Y1 (xj , y (¯n) ) sinh(m hj )
,
,
j = 1, . . . , N. and the constant M is independent of h and 1/xN .
(¯ n)
Proof. To show that the n-TDS (5.55) has the unique solution yi , i = 1, . . . , N , we use Banach’s Fixed Point Theorem (see Theorem 1.1). For this we consider the operator equation (¯ n) ˜ h (xi , y (¯n) ), y =< i
where ˜ h (xi , y(¯n) ) def < =
N −1 X
~j G(xi , xj )ϕ(¯n) (xj , y (¯n) ) + µ(¯n) (xN , y (¯n) )G(xi , xN ) + u(0) (xi ),
j=1
i = 1, . . . , N, and G(x, ξ) is Green’s function (5.10). Majorizing Riemann’s sums by integrals we get N −1 X j=1
~j G(xi , xj ) + G(xi , xN )
5.3. Implementation of the three-point EDS =
i
i
j=1
j=1
exp(−mxi ) X exp(−mxi ) X hj sinh(mxj ) + hj+1 sinh(mxj ) 2m 2m
+
N −1 N −1 sinh(mxi ) X sinh(mxi ) X hj exp(−mxj ) + hj+1 exp(−mxj ) 2m 2m j=i+1 j=i+1
+
sinh(mxi ) exp(−mxN ) m
exp(−mxi ) ≤ 2m
Zxi
exp(−mxi ) sinh(mη + h)dη + 2m
0
sinh(mxi ) + 2m sinh(mxi ) 2m
sinh(mη)dη 0
ZxN
exp(−mxi ) exp(−mη)dη + 2m
xi
+
Zxi
ZxN exp(−m(η − h))dη xi
Z∞ exp(−mη)dη xN
Z∞
ZxN ≤
G(xi , ξ)dξ + M1 h + xN
0
Z∞ ≤
G(xi , ξ)dξ
G(xi , ξ)dξ + M1 h =
1 − exp(−mxi ) + M1 h, m2
0
and N −1 X
Z∞ ~j Gx¯ (xi , xj ) + Gx¯ (xi , xN ) ≤
j=1
Gx¯ (xi , ξ)dξ + M1 h ≤
exp(−mxi ) + M1 h. m
0
Now, due to (5.62), we get
+ 1,ˆ ωh
NX
−1 1
≤ K1 + M max h, ~j G(x, xj ) + G(x, xN )
xN
j=1
+ 1,ˆ ωh
1 ≤ r + M2 max h, xN ˆ ≤ r + ∆ for all v ∈ Ω(ω ¯ h , r + ∆),
185
186
Chapter 5. Difference schemes for BVPs on the half-axis ˆ i.e. the operator
≤
N−1
X
1
ku − vk1,ˆω+ L1 + M max h, ~ G(x, x ) + G(x, x ) j j N
h xN 1,ˆ ω+ j=1
h
ˆ for all u, v ∈ Ω(ω ¯ h , r).
≤ q2 ku − vk1,ωˆ¯ + h
If we choose N0 such that 1 1 1 def , 2 L1 + M max h, < 1, q2 = max m m xN then the mapping
(¯ n)
The error zi = yi
− u(xi ), i = 0, . . . , N , satisfies the problem
(azx¯ )xˆ,i − d(xi )zi = ϕ(xi , u) − ϕ(¯n) (xi , y (¯n) ),
i = 1, . . . , N − 1, (5.71) (¯ n)
−a(xN )zx¯,N = β2 zN + µ2 (xN , u) − µ2 (xN , y (¯n) ).
z0 = 0,
Using Green’s function the solution of this problem and its first difference can be represented by zi =
N −1 X
~j G(xi , xj ) ϕ(xj , u) − ϕ(¯n) (xj , y(¯n) )
j=1
(¯ n) + G(xi , xN ) µ2 (xN , u) − µ2 (xN , y (¯n) ) , zx¯,i =
N −1 X
i = 1, . . . , N,
(5.72)
~j Gx¯ (xi , xj ) ϕ(xj , u) − ϕ(¯n) (xj , y(¯n) )
j=1
(¯ n) + Gx¯ (xi , xN ) µ2 (xN , u) − µ2 (xN , y(¯n) ) ,
i = 1, . . . , N.
For n odd, due to (5.59), we get from (5.72), (5.73): N X m hj cosh(m hj ) j ψ hj Gξ¯(xi , xj ) hn+1 (x, u) zi = − 1 j sinh(m h ) x=xj0 j j=1 − ψ˜1j (x, u)
x=xj0
+
N−1 X j=1
~j G(xi , xj ) ϕ(¯n) (xj , u) − ϕ(¯n) (xj , y (¯n) ) + O hn+1
(5.73)
5.3. Implementation of the three-point EDS (¯ n) + G(xi , xN ) µ2 (xN , u) − µ2 (xN , u) (¯n) (¯ n) + G(xi , xN ) µ2 (xN , u) − µ2 (xN , y (¯n) ) ,
zx¯,i
N X
n+1 mhj cosh (mhj ) ψ1j (x, u) =− hj Gx¯ξ¯ (xi , xj ) hj sinh (mhj ) x=xj0 j=1
− ψ˜1j (x, u)
x=xj0
mhi cosh (mhi ) i hn+1 i ψ1 (x, u) x=x − ψ˜1i (x, u) x=x i i a (xi ) sinh (mhi )
+
+
N−1 X
h i ~j Gx¯ (xi , xj ) ϕ(¯n) (xj , u) − ϕ(¯n) xj , y (¯n) + O hn+1
j=1
h i (¯ n) + Gx¯ (xi , xN ) µ2 (xN , u) − µ2 (xN , u) i h (¯ n) (¯ n) + Gx¯ (xi , xN ) µ2 (xN , u) − µ2 xN , y (¯n) , def
where we have set xj0 = xj + 0. Now, taking into account N X
hj Gξ¯ (xi , xj ) =
j=1
sinh (mxi ) exp (−mxN ) ≤ M3 , m Zxi
N X
exp (−mxN ) hj Gx¯ξ¯ (xi , xj ) = hi j=1
cosh (mη) dη −
sinh (mhi ) ≤ M4 mhi
xi−1
we get the estimates ( n+1
|zi | ≤ M max h
,
1 xN
( n+1
|zx¯,i | ≤ M1 max h
,
n+1 )
1 xN
+ q2 kzk1,ˆω+ , N
n+1 ) + q2 kzk1,ˆω+ . N
For n even, due to (5.60), equality (5.73) can be written as zi = −
N X
hj Gξ¯ (xi , xj )
j=1
+
N −1 X j=1
cosh (mhj ) j ψ1 (x, u) sinh (mhj ) x=xj0
mhj hnj
h i ~j G (xi , xj ) ϕ(¯n) (xj , u) − ϕ(¯n) xj , y (¯n) + O (hn )
187
188
Chapter 5. Difference schemes for BVPs on the half-axis h i (¯ n) + G (xi , xN ) µ2 (xN , u) − µ2 (xN , u) i h (¯ n) (¯ n) + G (xi , xN ) µ2 (xN , u) − µ2 xN , y(¯n) ,
zx¯,i = −
N X j=1
+
+
mhj cosh (mhj ) j ψ1 (x, u) hj Gx¯ξ¯ (xi , xj ) hnj sinh (mhj ) x=xj0
hni mhi cosh (mhi ) i ψ1 (x, u) x=x i a (xi ) sinh (mhi ) N−1 X
h i ~j Gx¯ (xi , xj ) ϕ(¯n) (xj , u) − ϕ(¯n) xj , y (¯n) + O (hn )
j=1
h i (¯ n) + Gx¯ (xi , xN ) µ2 (xN , u) − µ2 (xN , u) i h (¯ n) (¯ n) + Gx¯ (xi , xN ) µ2 (xN , u) − µ2 xN , y (¯n) . This implies n 1 |zi | ≤ M max h , + q2 kzk1,ˆω+ , N xN n 1 + q2 kzk1,ˆω+ . |zx¯,i | ≤ M max hn , N xN
n
Thus, we get the estimate ( n ¯
M max h , kzk1,ˆω+ ≤ N
1 xN
n¯ )
1 xN
n¯ )
,
1 − q2
which due to q2 < 1 yields ( n ¯
kzk1,ωˆ + ≤ M1 max h , N
(¯ n)
Since y0
.
(¯n) = Y20 x0 , y (¯n) , yj = Y1j xj , y (¯n) , we have
dz (x0 ) (n)0 0 (¯ n) 0 (¯ n) (¯ n) 0 ≤ Z x − Z x + x − Z , y , y , y (x , u) Z 0 0 0 0 2 2 2 2 dx +
m cosh(mh1 ) 0 (¯ n)0 x0 , y (¯n) Y2 x0 , y (¯n) − Y2 sinh(mh1 )
5.3. Implementation of the three-point EDS ∂ 0 ≤ M1 h + Z2 (x0 , u) ∂u n ¯
kzk0,ˆω+
N
u=˜ u
≤ M hn¯ , dz (xj ) (n)j j j j (¯ n) (¯ n) (¯ n) ≤ Z x − Z x + x − Z , y , y , y (x , u) Z j j j j 1 1 1 1 dx m cosh(mhj ) j (¯ n)j xj , y (¯n) Y1 xj , y (¯n) − Y1 sinh(mhj ) ∂ j n ¯ ≤ M1 h + Z1 (xj , u) kzk0,ˆω+ N ∂u u=˜ u +
≤ M hn¯ , and we get
∗ kzk1,ˆω+ N
j = 1, . . . , N, ( n ¯
≤ M max h ,
1 xN
n¯ ) , which proves the theorem.
The solution of the nonlinear n-TDS (5.55)–(5.58), (5.44) of order of accuracy n ¯ can be found by fixed point iteration. The following third main result of this chapter gives conditions for convergence of the iteration process and shows the rate of convergence. Theorem 5.5 Let the assumptions of Theorem 5.4 be satisfied. Then the solution of problem (5.55)-(5.58), (5.44) can be determined by the fixed point iteration (¯ n,k) (¯ n,k) − d (xj ) yj = −ϕ(¯n) xj , y (¯n,k−1) , j = 1, . . . , N − 1, ayx¯ x ˆ,j
(¯ n,k)
y0
= µ1 ,
(¯ n,k)
(¯ n,k)
−a (xN ) yx¯,N = β2 yN
y (¯n,0) (xj ) = µ1 exp (−mxj ) ,
(¯ n)
− µ2
xN , y (¯n,k−1) ,
(5.74)
dy (¯n,0) (xj ) = −mµ1 exp (−mxj ) , dx
j = 0, . . . , N. Moreover, the error estimate
∗
(¯n,k)
− u
y
+ 1,ˆ ωN
≤ M hn¯ + q2k
holds, where for k = 1, 2, . . . we have dy (¯n,k) (x0 ) dx m cosh (mh1 ) Y2(¯n)0 x0 , y (¯n,k) − y0(¯n,k) (n)0 , x0 , y (¯n,k) + = Z2 sinh (mh1 )
(5.75)
189
190
Chapter 5. Difference schemes for BVPs on the half-axis dy (¯n,k) (xj ) dx (n)j
= Z1
(5.76)
xj , y(¯n,k) +
(¯ n,k) (¯ n)j m cosh (mhj ) yj xj , y (¯n,k) − Y1 sinh (mhj )
,
j = 1, . . . , N. def
The constant M does not depend on h, n, k, and q2 = q + M h < 1. Proof. Theorem 5.4 yields
∗
(¯n,k)
− u
y
+ 1,ˆ ωN
∗
≤ y (¯n) − u
+ 1,ω ˆN
∗
+ y (¯n,k) − y (¯n)
+ 1,ˆ ωN
∗
≤ M hn¯ + y (¯n,k) − y (¯n)
+ 1,ˆ ωN
(5.77)
.
Moreover, the sequence of iterates y (¯n,k) (x) =
+ x∈ω ˆN ,
k = 1, 2, . . . ,
converges (see the proof of Theorem 5.4 ) with the rate given by
(¯n,k) − y (¯n)
y
+ 1,ˆ ωN
≤
q2k (r + ∆) . 1 − q2
Thus, taking into account (5.63) we get (¯n,k) dy (x0 ) dy (¯n) (x0 ) − dx dx (n)0 (n)0 ≤ Z2 x0 , y(¯n,k) − Z2 x0 , y(¯n) +
m cosh (mh1 ) (¯n)0 (¯ n)0 x0 , y (¯n,k) − Y2 x0 , y (¯n) Y2 sinh (mh1 )
"
#
∂ (n)0 m cosh (mh1 ) ∂ (¯n)0
(¯n,k) (¯ n) ≤ Y Z (x , u) + (x , u) − y
y
+ 0 0 2 sinh (mh1 ) ∂u 2 0,ˆ ωN u=¯ y ∂u u=˜ y
≤ M y (¯n,k) − y (¯n)
+ 1,ˆ ωN
,
(¯n,k) dy (xj ) dy (¯n) (xj ) − dx dx (n)j (n)j ≤ Z1 xj , y (¯n,k) − Z1 xj , y (¯n)
5.3. Implementation of the three-point EDS m cosh (mhj ) (¯n)j (¯ n)j xj , y (¯n,k) − Y1 xj , y (¯n) Y1 sinh (mhj )
+ "
#
∂ (n)j m cosh (mhj ) ∂ (¯n)j
(¯n,k) (¯ n) ≤ Y Z (x , u) + (x , u) − y
y
+ j j 1 sinh (mhj ) ∂u 1 0,ˆ ωN u=¯ y ∂u u=˜ y
≤ M y (¯n,k) − y (¯n)
+ 1,ˆ ωN
This implies
,
j = 1, . . . , N.
∗
(¯n,k)
− y (¯n)
y
+ 1,ˆ ωN
≤ M q2k .
(5.78)
The inequalities (5.77) and (5.78) yield the estimate (5.75). Thus, the proof is complete. In order to construct an algorithm which automatically generates a grid providing a given tolerance ε of the approximate solution, one can use various strategies. We discuss briefly only the following two possibilities based on the theory developed above. The first possibility is the classical technique which was proposed by Runge. The estimate (5.75) via standard considerations implies the following a posteriori h-h/2-strategy to arrive with a given tolerance ε (for a fixed n ¯ ). The tolerance ε is achieved if
∗
(¯n) (¯ n)
yN − y4N + ≤ (2n¯ − 1)ε, 1,ωN
where
(¯ n) yN
is the solution of the n-TDS on the uniform grid √ def ω ¯ N = {xj , j = 0, 1, . . . , N, h = 1/ N }
(¯ n)
and y4N is the solution on the grid ω ¯ 4N . The main drawback of this strategy is that the grid for the difference scheme (5.55) can be uniform or quasiuniform only. The second approach to the automatic grid generation is based on the following simple idea. Due to Theorem 5.4 the difference scheme (5.55)–(5.58) possesses order of accuracy n ¯ , which is an even integer number. In order to obtain TDS of the orders n ¯ and n ¯ + 2 by our method one should solve the IVPs (5.51) by one-step methods (5.44) of the corresponding orders. Here we use the embedded Runge-Kutta-Nystrom methods [14, 31] of orders n ¯ and n ¯ + 2 (RKN(¯ n + 2)(¯ n)). An a posteriori error estimate for the difference scheme (5.55) is then given by
(¯n)
y − y (¯n+2) ∗ + , and we have 1,ˆ ω N
∗
(¯n)
y − y (¯n+2)
+ 1,ω ˆN
∗
= y (¯n) − u
+ 1,ˆ ωN
+ O hn¯ +2 .
Thus, we can compute the approximate solution of problem (5.1) by the difference
∗ scheme (5.55) with a given tolerance ε provided that y (¯n) − y (¯n+2) 1,ˆω+ < ε. N
191
192
Chapter 5. Difference schemes for BVPs on the half-axis ˆ¯ N and computes an The following algorithm generates a non-uniform grid ω approximate solution of the problems (5.42). The relations (5.45), (5.46) and Theorem 5.4 guarantee that the error of the approximate solution of the BVP (5.1) is within a given tolerance ε, provided that for each j = 2 − α, . . . , N + 1 − α and α = 1, 2 the solutions of the IVPs (5.42) are given with tolerance hγ ε. Using the well-known idea of embedded Runge-Kutta methods we can then construct a ˆ¯ N such that the IVPs (5.42) are solved with tolerance hγ ε and non-uniform grid ω that the conditions (5.20), (5.21) are fulfilled. Having in mind the IVPs (5.42), the error of the Runge-Kutta-Nystrom method of order n ¯ is n¯ +1 + O(hnγ¯ +2 ), Yαj (xj , u) − Yα(¯n)j (xj , u) = ψαj (xβ , u) (−1)α+1 hγ n¯ +1 + O(hnγ¯ +2 ), Zαj (xj , u) − Zα(¯n)j (xj , u) = ψ˜αj (xβ , u) (−1)α+1 hγ i.e., for the embedded Runge-Kutta-Nystrom methods of orders n ¯ and n ¯ + 2 we have the following a posteriori estimates (neglecting the terms of order O(hnγ¯ +2 ) ) n¯ +1 Yα(¯n+2)j (xj , u) − Yα(¯n)j (xj , u) ≈ ψαj (xβ , u) (−1)α+1 hγ , n¯ +1 . Zα(¯n+2)j (xj , u) − Zα(¯n)j (xj , u) ≈ ψ˜αj (xβ , u) (−1)α+1 hγ In Step 4 of the algorithm it is checked whether the solutions of the “left” and the “right” IVPs could be determined on the interval [xj−1 , xj ] within the prescribed tolerance. If this is not the case the previous step-size is divided by two. A doubling of the step-size hγ changes the main terms of the error as follows: n¯ +1 2n¯ +1 ψαj (xβ , u) (−1)α+1 hγ ,
n¯ +1 2n¯ +1 ψ˜αj (xβ , u) (−1)α+1 hγ .
This fact is used in Step 6 for a possible increase of the next step-size provided that on the previous subinterval these terms satisfy the prescribed tolerance. In Steps 8–10 values for N , hN and xN are provided which satisfy the inequalities (5.21). More precisely, if the condition in Step 7 is not fulfilled, then N (see Step 8), hN and xN (see Step 5) are chosen such that the left part of (5.21) is satisfied. Now, the following two cases are possible: 1) We have xN ≤ 1/hmin . Then both inequalities in (5.21) are satisfied. 2) We have xN > 1/hmin . Then the inequalities in (5.21) are not satisfied and the values hN and xN must be decreased. This is realized in Step 9.
5.3. Implementation of the three-point EDS ˆ¯ N , ε, n Algorithm AG(ω ¯ , h1 , RKN(¯ n + 2)(¯ n), m, f , u, u0 ) Input: An error tolerance ε, the order of accuracy n ¯ of the TDS (an even natural number), an initial step-size h1 , an embedded Runge-Kutta-Nystrom IVP-solver RKN(¯ n + 2)(¯ n), the problem data m and f as well as the initial values u, u0 for the IVPs (5.42). ˆ Output: A non-uniform grid ω ¯ N on which the numerical solution of (5.42), Yα(l)j (xj , u), ˆ xj ∈ ω ¯N ,
Zα(l)j (xj , u),
l=n ¯, n ¯ + 2,
j = 2 − α, . . . , N + 1 − α,
α = 1, 2,
is determined within the given tolerance. 1) Set j := 0,
x0 := 0,
n := n ¯.
2) Set j := j + 1. 3) Solve the “left” and the “right” IVPs (5.42) on the interval [xj−1 , xj ] using RKN(¯ n + 2)(¯ n) and compute (¯n)j−1 (¯ n+2)j−1 (¯ n) (¯ n) Y2 (x , y ) − Y (x , y ) j−1 j−1 2 def o n , e2 = max (¯ n+2)j−1 max Y2 (xj−1 , y (¯n) ) , 1 (¯n)j−1 (¯ n+2)j−1 (xj−1 , y (¯n) ) − Z2 (xj−1 , y(¯n) ) Z2 o n , (¯n+2)j−1 max Z2 (xj−1 , y (¯n) ) , 1 (¯n)j Y1 (xj , y (¯n) ) − Y1(¯n+2)j (xj , y (¯n) ) def o n , e1 = max (¯n+2)j max Y1 (xj , y (¯n) ) , 1 (¯n)j (¯ n+2)j (xj , y(¯n) ) Z1 (xj , y (¯n) ) − Z1 o n . (¯n+2)j max Z1 (xj , y (¯n) ) , 1 4) if max{e1 , e2 } > hj ε then begin hj := hj /2; go to Step 3 end. 5) Set xj := xj−1 + hj . 6) if 2n¯ +1 max{e1 , e2 } ≤ hj ε then begin hj+1 := 2hj end else hj+1 := hj . 7) if xj <
1 max1≤i≤j hi
8) Set N := j;
then go to Step 2.
hmin := min1≤i≤N hi .
193
194
Chapter 5. Difference schemes for BVPs on the half-axis
9) if xN >
1
then begin hmin 1 − xN−1 ; xN :=
1 ; hmin hmin Solve the IVPs (5.42) on the interval [xN−1 , xN ] using RKN(¯ n + 2)(¯ n) end.
hN :=
10) Stop. Theorem 5.4 is the basis of the following algorithm which computes for the BVP (¯ n+2) (5.1) the corresponding solution yj , j = 1, . . . , N , of the TDS (5.55) of order ˆ of accuracy n ¯ + 2 on a given grid ω ¯N . ˆ Algorithm A(y (¯n+2) , ω ¯ N , ε, n ¯ , h1 , A, RKN(¯ n + 2)(¯ n), µ1 , m, f ) Input: The grid ω ¯ˆ N , an error tolerance ε, the order of accuracy n ¯ of the TDS def (an even natural number), an initial step-size h1 , the vector A = (A1 , . . . , An¯ −1 ) of coefficients which are defined in (5.49), an embedded Runge-Kutta-Nystrom method RKN(¯ n + 2)(¯ n), as well as the problem data µ1 , m , f of problem (5.1). ˆ Output: The solution y (¯n+2) (xj ), xj ∈ ω ¯ N , of the BVP (5.1) with an error smaller than the given tolerance ε. 1) Set εit := 0.25ε. 2) Determine the starting values u(0) (x) = µ1 e−mx ,
du(0) = −mµ1 e−mx . dx
ˆ 3) Compute the grid ω ¯ N using the algorithm ˆ¯ N ,ε,¯ n,h1 ,RKN(¯ n + 2)(¯ n), m, f , u(0) , AG(ω Set k := 0;
du(0) ). dx
l := n ¯.
4) Set k := k + 1;
n := l.
5) Compute ϕ(l) (xj , y(l,k−1) ) in accordance with (5.56) for all j = 1, . . . , N −1 (l) and µ2 (xN , y (l,k−1) ) by (5.57) provided that at least one of the coefficients Ai 6= 0 or by (5.58) otherwise. (l,k)
6) Find yj , j = 1, . . . , N , by solving the system of linear algebraic equations (5.74) with a tridiagonal system matrix.
5.4. Numerical examples
7) Find Yα(l)j (xj , y (l,k) ),
Zα(l)j (xj , y (l,k) ),
j = 2 − α, . . . , N + 1 − α,
ˆ¯ N , xj ∈ ω
α = 1, 2,
by an embedded Runge-Kutta-Nystrom method RKN(l + 2)(l) and compute dy (l,k) (xj ) , j = 0, . . . , N , by (5.76). dx
y (l,k) − y (l,k−1) ∗
8) if > εit then go to Step 4.
max y (l,k) , 1 + 1,ˆ ωN
9) if l = n ¯ then begin k := 0; l := n ¯ + 2; go to Step 4 end.
∗
y (¯n+2) − y (¯n)
> ε then begin 10) if
max y (¯n+2) , 1 + 1,ω ˆN
Find new starting values by interpolating the values (¯ n+2)
yi
,
dy (¯n+2) (xi ) , dx
i = 0, . . . , N,
using the formulas h i 1 (¯ n+2) (¯ n+2) yi (x − xi−1 ) + yi−1 (xi − x) , xi − xi−1 (¯n+2) du(0) (xi ) 1 dy dy (¯n+2) (xi−1 ) = (x − xi−1 ) + (xi − x) , dx xi − xi−1 dx dx
u(0) (x) =
xi−1 ≤ x ≤ xi , (¯ n+2)
u(0) (x) = yN
i = 1, . . . , N, exp (−m (x − xN )) ,
dy (¯n+2) (xN ) du(0) = exp (m (x − xN )) , dx dx
x ∈ [xN , ∞) ;
go to Step 3 end. 11) Stop.
5.4
Numerical examples
In this section we give two numerical examples confirming the theory above. For each example we have done three experiments.
195
196
Chapter 5. Difference schemes for BVPs on the half-axis Example 5.3. The BVP d2 u − 4u = 2u3 + 6u2 , dx2 u(0) = −1,
x ∈ (0, ∞) , (5.79)
lim u(x) = 0,
x→∞
possesses the exact solution u(x) = tanh(x) − 1 which decays exponentially as x → ∞. Let us illustrate Theorem 5.2 by the BVP (5.79). Here we have f (x, u) = −2u3 − 6u2 ,
m = 2,
L(x) = 6[1 − (exp(−2x) − 1)2 ],
p(x) = −1 + tanh(x) ≤ − exp(−2x) = r(x), Z∞ G (x, ξ) L(ξ)dξ =
1 (exp(−4x) − exp(−2x)) + 3x exp(−2x) < 1. 2
0
Therefore, we can conclude that this problem has a unique solution which can be determined by a fixed point iteration. The function f (x, u) = −2u3 − 6u2 is analytic in a neighbourhood of the point (∞, 0) and fu0 (x, 0) = 0. Moreover, the ODE is autonomous, which implies Ai = 0, i ∈ N, and we can use a difference scheme of type (5.55), (5.56), (5.58). We apply the difference scheme of order of accuracy 4 on the uniform grid def
ω ¯ N = {xj ,
j = 0, 1, . . . , N,
√ h = 1/ N }.
The numerical solution of the IVPs (5.42) was obtained by a fourth-order Runge(¯ n) Kutta-Nystrom method (see [31], Table 14.2). The solution yj , j = 1, . . . , N , of the difference scheme (5.55) has been determined by the fixed point iteration (5.74). (¯ n,k) , j = 1, . . . , N , of the system of linear algebraic equations (5.74) The solution yj with a three-diagonal matrix was computed by the Thomas algorithm (double sweep algorithm, see e.g. [12]). To estimate experimentally the rate of convergence we have determined the computed error er and the computed order of accuracy p by the formulas
∗ def
er = kzk∗1,ˆω+ = y (4) − u N
+ 1,ˆ ωN
∗
,
def
p = log2
kzk1,ˆω+ ∗
N
kzk1,ˆω+
.
(5.80)
4N
The corresponding numerical results are presented in Table 5.1. They show excellent agreement with our theoretical considerations. In Table 5.2 we give the difference Error between the approximate and the exact solution and the number of ODE calls NFUN for a given tolerance EPS using the difference scheme (5.55) – (5.57) and the h-h/2-strategy.
5.4. Numerical examples N
er 0.2135 E − 4 0.1270 E − 5 0.7848 E − 7 0.4727 E − 8 0.2522 E − 9 0.1440 E − 10
32 128 512 2048 8192 32768
p 4.1 4.0 4.1 4.2 4.1
Table 5.1: Numerical results for Example 5.3
EPS 1.0 E − 3 1.0 E − 5 1.0 E − 7 1.0 E − 9
N
NFUN
32 32 128 2048
6144 13056 71040 1276800
Error 0.286 E − 3 0.285 E − 5 0.164 E − 7 0.234 E − 9
Table 5.2: Numerical results for problem (5.3): Runge strategy
Finally, Table 5.3 presents the results obtained with Algorithm A(·) using the embedded Runge-Kutta-Nystrom method RKN6(4)(see [14], Table 5). The grid has been generated automatically with Algorithm AG(·). For example, the generated grid for EPS=10−5 is ˆ¯ N = {0, 0.125, 0.25, 0.375, 0.5, 0.75, 1, 1.25, 1.5, 1.75, 2, 2.25, 2.5, 2.75, 3.25, ω 3.75, 4.25, 5.25, 6.25, 8}.
EPS 1.0 E − 3 1.0 E − 5 1.0 E − 7 1.0 E − 9
N
NFUN
Error
4 19 75 417
1320 5280 46164 225948
0.552 E − 3 0.704 E − 6 0.352 E − 8 0.398 E − 10
Table 5.3: Numerical results for problem (5.3): Algorithm A(·)
197
198
Chapter 5. Difference schemes for BVPs on the half-axis Example 5.4. The problem 4 7 d2 u − 4u = − + − u2 , 2 2 dx (1 + x) (1 + x)4 u(0) = 1,
x ∈ (0, ∞) , (5.81)
lim u(x) = 0,
x→∞
possesses the exact solution u(x) =
1 . (1 + x)2
Here we have f (x, u) =
4 7 − + u2 , (1 + x)2 (1 + x)4
f (x, 0) =
7 4 − , (1 + x)2 (1 + x)4
m = 2,
fu0 (x, 0) = 0.
We represent the solution of this problem in the form Z∞ u(x) =
G (x, ξ) u2 (ξ)dξ + u(0) (x),
0
where u
(0)
1 (x) = − (1 + x)2
Z∞
G (x, ξ) dξ. (1 + ξ)4
0
Let us now introduce the operator def
Z∞
<(x, u(·)) =
G (x, ξ) u2 (ξ)dξ + u(0) (x),
0
and show that this operator transforms the set
def
Ω ([0, ∞), 1) = u(x) ∈ C[0, ∞) : u − u(0)
≤1
0,[0,∞)
into itself. Since 0 ≤ u(0) (x) ≤ 1, it holds that v(x) + u(0) (x) ≤ 3 for all x ∈ Ω ([0, ∞), 1). Thus, we have <(x, u(·)) − u(0) (x) Z∞ = 0
Z∞ h i2 h i2 2 (0) dξ + G (x, ξ) u(0) (ξ) dξ G (x, ξ) v (ξ) − u (ξ) 0
5.4. Numerical examples Z∞ G (x, ξ) dξ = 1 − exp(−2x) ≤ 1.
≤4 0
We see that the operator <(x, v(·)) transforms Ω ([0, ∞), 1) into itself and is contractive, since |<(x, u(·)) − <(x, v(·))| Z∞ ≤
G (x, ξ) u2 (ξ) − v 2 (ξ) dξ ≤ 3
0
Z∞
G (x, ξ) dξ u − u(0)
0,[0,∞)
0
≤ q u − u(0)
, 0,[0,∞)
3 (1 − exp(−2x)) < 1. We have solved this problem by the difference 4 scheme (5.55) – (5.57) with µ1 = 1 and def
where q =
(4)
µ2 (xN , u) =
mA1 mA2 − A1 mA3 − A2 + + xN x2N x3N (4)N m cosh (mhN ) Y1 (xN , u) − uN −1 (4)N . − Z1 (xN , u) + sinh (mhN )
(4)j
(4)j
The functions Zα (xj , u), Yα (xj , u), j = 2 − α, . . . , N + 1 − α, α = 1, 2, are the numerical solutions of (5.42) which were solved by a Runge-Kutta-Nystrom method of order of accuracy 4 (see [31],Table 14.2). For this example we have 0 = F˜ (t, {A}) "∞ #2 X 4t2 7t4 1 i = [(i − 2)(i − 1)Ai−2 − 4Ai ] t + − + Ai t + r 2 4 (1 + t) (1 + t) t i=1 i=1 ∞ X
+ r00
i
1 1 − 4r . t t
Solving systems (5.48) exactly, we get A1 = 0, A2 = 1, A3 = −2. In Tables 5.4 – 5.6 we present the results for the BVP (5.81) which have been obtained with the same three experiments described in Example 5.3. Here, the automatically generated grid for EPS = 10−3 is ˆ¯ N = {0, 0.05, 0.15, 0.35, 0.55, 0.95, 1.35, 2.15, 2.95, 3.75, 4.55, 5.35, 6.15, 6.95, ω 7.75, 8.55, 9.35, 10.15, 10.95, 11.75, 12.55, 13.35, 14.15, 14.95, 16.55, 18.15, 19.75, 20}.
199
200
Chapter 5. Difference schemes for BVPs on the half-axis N
er
p
0.5757 E − 1 0.4486 E − 2 0.3184 E − 3 0.2130 E − 4 0.1379 E − 5 0.8779 E − 7 0.5537 E − 8
8 32 128 512 2048 8192 32768
3.7 3.8 3.9 3.9 4.0 4.0
Table 5.4: Numerical results for Example 5.4
EPS 1.0 E − 3 1.0 E − 5 1.0 E − 7
N
NFUN
512 512 2048
56544 84480 410256
Error 0.485 E − 4 0.142 E − 5 0.920 E − 7
Table 5.5: Numerical results for problem (5.4): Runge strategy
Remark 5.1. For an often used test problem (see e.g. [37], [4]) d2 u − m2 u = 0, dx2 u (0) = µ1 ,
x ∈ (0, ∞) , (5.82) lim u (x) = 0
x→∞
our numerical scheme (5.55) provides the exact solution, i.e., ˆ¯ N . y (¯n) (xj ) = µ1 exp (−mxj ) , xj ∈ ω Indeed, it is easy to see from (5.56) – (5.58) that in the linear case (where f (x, u) ≡ 0) (¯ n) we have ϕ(¯n) (xj , u) = 0, j = 1, . . . , N − 1, µ2 (xN , u) = 0, i.e. the scheme (5.55) has the form (¯ n) (¯ n) ayx¯ − d (xj ) yj = 0, j = 1, . . . , N − 1, x ˆ,j (5.83) (¯ n)
y0
= µ1 ,
(¯ n)
(¯ n)
−a (xN ) yx¯,N = β2 yN ,
with coefficients which can be computed by the explicit formulas (5.29). Due to ϕ(xj , u) = 0, j = 1, . . . , N − 1, µ2 (xN , u) = 0 (see (5.30)), the EDS (5.27) coincides with (5.83) for the BVP (5.82).
5.4. Numerical examples EPS 1.0 E − 3 1.0 E − 5 1.0 E − 7
N
NFUN
27 117 573
2604 14052 82524
Error 0.380 E − 5 0.940 E − 7 0.985 E − 9
Table 5.6: Numerical results for problem (5.4): Algorithm A(·)
Remark 5.2. Analogous to the discussions above one can construct an EDS and an n-TDS for BVPs on the whole axis (−∞, ∞).
Remark 5.3. The solution of the system of nonlinear equations representing the n-TDS can also be determined by other iterative methods, for example, by Newton’s method.
201
203
Chapter 6
Exercises and solutions You never solve a problem by putting it on ice. Winston Spencer Churchill (1974–1965)
In this last chapter we present a variety of mathematical exercises and the corresponding sample solutions by which the reader can test and deepen the knowledge acquired in the previous chapters of this book.
6.1
Exercises
Exercise 6.1. Check that the vector-function ! ln (ax + b) u1 (x) = u(x) = a u2 (x) ax + b
(6.1)
is the solution of the following BVP for a system of two first-order ODEs u0 (x) = f (u), (6.2) B0 u(0) + B1 u(1) = β, with f (u) =
B0 =
! f1 (u1 , u2 )
u2
!
= , −u22 f2 (u1 , u2 ) ! ! 1 0 0 0 , B1 = , 0 0 1 0
(6.3) ln b β=
ln (a + b)
! .
I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2_6, © Springer Basel AG 2011
203
204
Chapter 6. Exercises and solutions Prove that on the uniform grid ω h the difference scheme ux,i = f h (ui−1 ),
i = 0, 1, 2, . . . , N, (6.4)
B0 u(0) + B1 u(1) = β, is exact, where def
f h (u) =
def
ux,i = h−1 (ui − ui−1 ), −1 ! h ln (1 + hu2,i−1 ) f1,h (u1 , u2 ) def = . u2 (xi−1 ) f2,h (u1 , u2 ) − 2 1 + hu2,i−1
ui = u(xi ),
(6.5)
ˆ h following Exercise 6.2. Construct the EDS for the BVP (6.2) on an arbitrary grid ω the theory of Chapter 2. ˆ h following Exercise 6.3. Construct a 4-TDS for the BVP (6.2) on an arbitrary grid ω the theory of Chapter 2 and using an explicit 4-stage Runge-Kutta method of order 4. Exercise 6.4. Check that the ODE u0 − axn (u2 + 1) = 0,
n 6= −1
(6.6)
a n+1 x +C , n+1
(6.7)
has the general solution u(x) = tan where C is an arbitrary real constant. Find a first-order difference equation (which represents the EDS) whose solution def
coincides on an arbitrary grid ωh , h =
def
max hi , hi = xi − xi−1 , with the exact
i=1,2,...,N
solution of the BVP defined by the ODE (6.6) and the periodic boundary condition u(0) = −u(1).
(6.8)
Exercise 6.5. Develop an EDS for the BVP (6.6) using the algorithm of Section 2.4. Exercise 6.6. Using the EDS from the previous exercise construct TDS of orders of accuracy 2 and 3. Exercise 6.7. Check that the following ODE of the mass interaction u0 = (Au − a)(Bu − b),
(6.9)
def
with ∆ = aB − bA 6= 0, possesses the general solution u(x) =
C1 be∆x − C2 a , C1 Be∆x − C2 A
(6.10)
6.1. Exercises where C12 + C22 > 0. def
Find the EDS on an arbitrary grid ωh , h =
def
max hi , hi = xi − xi−1 , for the
i=1,2,...,N
BVP defined by the ODE (6.9) and the periodic boundary condition (6.8). Exercise 6.8. Construct an EDS for the BVP (6.9), (6.8) following the theory of Chapter 2. Exercise 6.9. Construct a 3-TDS for the BVP (6.9), (6.8) following the theory of Chapter 2. Exercise 6.10. Show that on a uniform grid with step-size h and with respect to the ODE (6.11) u00 = eu , x ∈ (0, 1), the difference equations and yxx −
yxx = ey
(6.12)
h2 y [e ]xx = ey 12
(6.13)
possess truncation errors of order O(h2 ) provided that u ∈ C4 [0, 1], and O(h4 ) provided that u ∈ C6 [0, 1], respectively. Exercise 6.11. Develop an algorithm of order 4 with the input data L, c1 , c2 and f (x) for the BVP u00 = eu − e−u + f (x),
x ∈ (0, L),
u(0) = c1 ,
u(L) = c2 ,
L > 0.
(6.14)
Note, such problems often arise in the modelling of semiconductor devices. Exercise 6.12. Check that the function x u(x) = − ln cos2 √ 2
(6.15)
is the solution of the BVP 00
u
u (x) = e ,
x ∈ (0, 1),
u(0) = 0,
2 1 u(1) = − ln cos √ . 2
1) Show that the difference scheme h2 y h2 y 2 y yxx − e (y ◦ ) 1 − e + e x 12 3 xx 4 2 2h4 ey y ◦ + 11e2y y ◦ + 4e3y y ◦ = ey − x x x 6! has a truncation error O(h6 ).
(6.16)
(6.17)
205
206
Chapter 6. Exercises and solutions 2) Solve this BVP with the TDS of order 2 and compare the result with the exact solution. 3) Solve this BVP with the TDS of order 4 and compare the result with the exact solution. 4) Find experimentally the a posteriori error by the Runge principle. Exercise 6.13. Check that the function u(x) = c sinh (ax + b),
(6.18)
where c is an arbitrary and a, b are positive constants, satisfies the BVP u00 (x) = 2 sinh u + f (x),
x ∈ (0, L), (6.19)
u(0) = c sinh (b),
u(L) = c sinh (aL + b),
L > 0.
def
Here, f (x) = c(2 − a2 ) sinh (ax + b). Develop a three-point EDS on 1) a uniform and 2) a non-equidistant grid. Exercise 6.14. Check that the function u(x) =
1 1+x
(6.20)
is the exact solution of the BVP u00 (x) = 2 u3 (x),
x ∈ (0, 1),
u(0) = 1,
u(1) = 0.5.
(6.21)
On the basis of the facts uxx (x) − u00 (x) = 2
∞ (2k) X u (x) k=2
(2k)!
h2k−2
(6.22)
on the equidistant grid ωh and u(2k) (x) = (−1)k (2k)!u2k+1 (x) find the EDS and a TDS of order 2n for an arbitrary n. Exercise 6.15. Check that the BVP u00 (x) + ω 2 u + u2 (x) = u(0) = A sin ϕ,
A2 (1 − cos (2ωx + 2ϕ)) , 2
(6.23)
u(1) = A sin (ω + ϕ),
where A, ω and ϕ are arbitrary constants, has the exact solution u(x) = A sin (ωx + ϕ).
(6.24)
Find on the uniform grid ωh a second-order difference equation (EDS) and a TDS of order 2n for an arbitrary n.
6.1. Exercises Exercise 6.16. Check that the BVP u00 (x) − b
u ln u = 0, x
u(1) = eb ,
u(2) = e2b ,
(6.25)
where b is an arbitrary constant, has the exact solution u(x) = ebx .
(6.26)
Find the 3-point EDS for this BVP on uniform grid with step-size h = 1/N and a TDS of order 2n for an arbitrary n. Exercise 6.17. Check that the BVP u00 (x) = −
2a u u0 , c
c u(0) = , b
u(1) =
c , a+b
(6.27)
where a, b and c are arbitrary real constants, has the exact solution u(x) =
c . ax + b
(6.28)
Find the 3-point EDS for this BVP on the uniform grid ωh and a TDS of order 2n for an arbitrary n. Exercise 6.18. Check that the BVP u00 (x) =
a2 m(m + 1) m+2 √ u m , m 2 c
u(0) =
c , bm
u(1) =
c , (a + b)m
(6.29)
where a, b, c are arbitrary positive real constants and m is a natural number, has the exact solution c u(x) = . (6.30) (ax + b)m Find the 3-point EDS for this BVP on the uniform grid ωh and a TDS of order 2n for an arbitrary n. Exercise 6.19. Check that the function u(x) =
1 , ax + b
(6.31)
where a and b are arbitrary positive constants, is the solution of the BVP u00 (x) = 2a2 u3 (x), u(0) =
1 , b
u(1) =
x ∈ (0, 1), 1 . a+b
(6.32)
ˆ i.e. determine its 1) Find the 3-point EDS on an arbitrary non-uniform grid ω, coefficients explicitly. 2) Derive the 3-TDS of order n for an arbitrary n ∈ N with explicitly given coefficients and solve the BVP by this 3-TDS with n = 4.
207
208
Chapter 6. Exercises and solutions 3) Solve the BVP (6.32) by the algorithm presented in Section 3.3 using the implicitly defined TDS of order 4 and compare the results with 2). Exercise 6.20. Check that the function u(x) = ln (ax + b),
(6.33)
where a and b are arbitrary positive constants, is the solution of the BVP 2
u00 (x) = − (u0 ) (x),
x ∈ (0, 1), (6.34)
u(0) = ln b,
u(1) = ln (a + b).
1) Find the three-point EDS on a uniform grid ω, i.e. determine its coefficients explicitly. 2) Derive the TDS of the order 2n for an arbitrary n ∈ N with explicitly given coefficients and solve the BVP with n = 4. 3) Solve the BVP by the algorithm presented in Section 3.3 using the implicitly defined TDS of order 4 and compare the results with 2). Exercise 6.21. Prove that the difference scheme uxx (x)
(ax + b)2 − a2 h2 (ax + b)2
= −u2◦ (x) +
1 ln h2
u(0) = ln b,
u(1) = ln (a + b)
x
+
1 ln2 4h2
ax + b + ah ax + b − ah
,
x ∈ ωh ,
(6.35) is exact for the BVP 2
u00 (x) = − (u0 ) (x),
x ∈ (0, 1),
u(0) = ln b,
u(1) = ln (a + b).
(6.36)
Exercise 6.22. Prove that for the right-hand side of the EDS from the previous exercise it holds that 1 (ax + b)2 − a2 h2 ln h2 (ax + b)2 (6.37) a4 ax + b + ah 8a6 1 2 2 4 = h + h + ··· . + 2 ln 4h ax + b − ah 6(ax + b)4 45(ax + b)6 Exercise 6.23. Let us consider the BVP du d2 u = − f (x, u) , 2 dx dx
x ∈ (0, 1),
u(0) = γ0 ,
u(1) = γ1 ,
(6.38)
and suppose that its solution possesses the property u(k) (x) = ϕk (x)u(x),
k = 1, 2, . . . .
(6.39)
6.1. Exercises Show that the difference scheme ux,x (x) = −u ◦ f (x, u) + 2
∞ X ϕ2k (x)
x
k=2
u(0) = γ0 ,
(2k)!
∞ X ϕ2k (x)
h2k−2 + 2f (x, u)
k=2
(2k)!
h2k−2 uk (x),
(6.40)
u(1) = γ1 ,
is exact (provided that the series converges). What is the TDS of order O(h2n+1 ) for an arbitrary n ∈ N? Exercise 6.24. Check that the function u(x) = cxn
(6.41)
is the solution of the BVP u0 (x) , u00 (x) = c2 (n − 1) p n u2 (x) n
u(a) = ca ,
n
u(b) = cb ,
c > 0, (6.42) b > a > 0,
and find an EDS and TDS for this BVP. Exercise 6.25. Develop an EDS for the BVP d2 u 1 = 3, 2 dx u
0 < x < 1,
u(0) = u(1) = 1,
(6.43)
whose exact solution is u(x) = (2x2 − 2x + 1)−3/2 . Exercise 6.26. Construct a 6-TDS for BVP (6.43). Exercise 6.27. Construct an EDS for the problem u00 (x) = sinh u,
x ∈ (0, L), (6.44)
u(0) = ln cosh b,
u(L) = ln cosh (aL + b),
where a, b and L are positive real constants (mathematical problems of this type arise in the modelling of semiconductor devices). def
Exercise 6.28. Check that in the domain Ω = {(x, y) : 0 ≤ x, y ≤ 1} the function a , a, b, c, d ∈ R, (6.45) u(x, y) = bx + cy + d is the solution of the following BVP for the nonlinear partial differential equation ∂ 2 u(x, y) ∂ 2 u(x, y) 2(b2 + c2 ) 3 + = u (x, y), ∂x2 ∂y 2 a2 u(0, y) =
a , cy + d
u(1, y) =
a , b + cy + d
u(x, 0) =
a , bx + d
u(x, 1) =
a . bx + c + d
(x, y) ∈ Ω, (6.46)
209
210
Chapter 6. Exercises and solutions Propose an EDS for this BVP on the rectangular grid def
ωh1 ,h2 = {(xi , yj ) : xi = ih1 , i = 0, 1, . . . , N1 , h1 = 1/N1 ; yj = jh2 , j = 0, 1, . . . , N2 , h2 = 1/N2 }. Is this EDS uniquely determined? Exercise 6.29. Check that in the domain Ω the function u(x, y) = a sin (bx + cy + d),
a, b, c, d ∈ R,
(6.47)
is the solution of the following BVP for the nonlinear partial differential equation ∂ 2 u(x, y) ∂ 2 u(x, y) + + 2xyu2 (x, y) + a(b2 + c2 )u ∂x2 ∂y2 = 2a2 xy sin2 (bx + cy + d),
(x, y) ∈ Ω,
u(0, y) = c sin (by + d),
u(1, y) = c sin (a + by + d),
u(x, 0) = c sin (ax + d),
u(x, 1) = c sin (ax + b + d).
(6.48)
Propose an EDS for this BVP on the rectangular grid ωh1 ,h2 . Exercise 6.30. An ODE of the form u0 (x) = f (u) is called autonomous. Suppose that an algorithm to calculate Fk (u) = f (k) (u) for all k = 1, 2, . . ., is given. Construct an EDS for the IVP u0 (x) = f (u),
u(0) = u0 ,
on an arbitrary non-uniform grid with N nodes. What is the algorithm for a TDS of order O(hn ), where h = maxi hi , hi = xi − xi−1 ? Exercise 6.31. Suppose that an algorithm to calculate Fk (u) = f (k) (u) for all k = 1, 2, . . ., is given. Construct an EDS for the BVP u00 (x) = f (u),
u(0) = u0 ,
u(1) = u1 ,
on the equidistant grid with the step-size h = 1/N . What is the algorithm for a TDS of order O(hn )? Exercise 6.32. The BVP u00 (x) + λ u(x) = 0,
x ∈ (0, 1), (6.49)
u(0) = 0,
u(1) = 0
has the exact solution un (x) = sin (nπx),
λn = (nπ)2 ,
n = 1, 2, . . . .
(6.50)
6.1. Exercises Show that on the grid def
ω h = ωh ∪ {x0 = 0, xN+1 = 0},
def
ωh = {xi =
i , N +1
i = 1, . . . , N } (6.51)
the eigenvalues of the difference scheme (in non-indexed form) √ 2 sin ( λh/2) √ uxx (x) + λ u(x) = 0, x ∈ ωh , ( λh/2) u(0) = 0,
(6.52)
u(1) = 0
or (in indexed form) √ 2 1 sin ( λh/2) √ [u(x ) − 2u(x ) + u(x )] + λ u(xi ) = 0, i+1 i i−1 h2 ( λh/2) u(x0 ) = 0,
u(xN +1 ) = 0,
(6.53)
i = 1, . . . , N,
coincide with the first N exact eigenvalues and the eigenfunctions (eigenvectors) are the projections of the first N exact eigenfunctions onto the grid . Exercise 6.33. Show that • the eigenvalues λhk of the difference eigenvalue problem yxx (x) + λh y(x) = 0,
x ∈ ω, (6.54)
y(0) = 0,
y(1) = 0
approximate the exact eigenvalues λk of (6.49) (k fixed and independent of N ) with second order of accuracy O(h2 ), and • the eigenfunctions yk (x) are the projections of the first N exact eigenfunctions uk (x) onto the grid. Exercise 6.34. For the Sturm-Liouville BVP u00 (x) + [λ − q(x)]u(x) = 0,
x ∈ (0, 1), (6.55)
u(0) = 0,
u(1) = 0,
with def
q(x) =
0,
0≤x≤
1 , 2
1 <x≤1, 2 construct the EDS on the equidistant grid def ω h = xi = ih, i = 0, 1, . . . , 2N + 2, h = 1,
1 . 2(N + 1)
211
212
Chapter 6. Exercises and solutions Exercise 6.35. (See [20, 54]) Let the eigenvalue problem Lu(x) + λ u(x) = 0,
x ∈ (a, b), (6.56)
|u(a)| 6= ∞,
|u(b)| 6= ∞,
be given, where def
def
Lu(x) = A(x)u00 (x) + B(x)u0 (x),
A(x) = a2 (x − a)(x − b),
def
B(x) = b1 x + b0 .
Determine an equidistant grid ωh with 2N + 1 nodes and specify conditions under which the eigenvalues of the following difference scheme x ∈ ωh ,
Lh y(x) + λh y(x) = 0,
(6.57) u(x−N ) 6= ∞,
u(xN ) 6= ∞,
where def
Lh y(x) = A(x)yxx + B(x)y ◦ , x
coincide with the first 2N + 1 eigenvalues of the exact problem (6.56). Which is the approximation order of the corresponding eigenfunctions with respect to h? Hint: If we substitute x=
1 [(b − a)t + a + b] 2
(6.58)
1 def into (6.56) and define y(t) = u( [(b − a)t + a + b]) then problem (6.56) reads 2 1 1 1 λ b1 (b − a)t + b1 (b + a) + b0 y 0 (t) − y(t) = 0, (1 − t2 )y 00 (t) − a2 2 2 a2 (6.59) |y(−1)| = 6 ∞,
|y(1)| = 6 ∞,
t ∈ (−1, 1).
The solution of (6.59) is a polynomial of degree n iff λ = −a2 n(n +
b1 (b − a) − 1). 2a2
2x − a − b (α,β) ), where Pn (z) are b−a b1 (b − a) b0 b0 the Jacobi polynomials with β = − − 1 and α = −1 + + (see e.g. 2a2 2a2 2a2 [6]). (α,β)
This solution is given by u(x) = Pn (x) = Pn
(
Exercise 6.36. (See [20, 54]) After the change of variables U = r−1/2 (sin θ)m V,
x = ln r,
y=
1 + cos θ 2
6.1. Exercises the Dirichlet problem for the Poisson equation in spherical coordinates (m = 0 is the case of axial symmetry) LU = Lr U + Lθ U = 0 < r1 < r < r2 ,
1 ∂ ∂U m2 U ∂ 2 ∂U r + sin θ − = f (r, cos θ), ∂r ∂r sin θ ∂θ ∂θ sin θ
0 < θ < π,
U (r1 , θ) = ϕ1 (θ),
m = 0, 1, 2, . . . ,
U (r2 , θ) = ϕ2 (θ)
is transformed into the problem LV = (Lx + Ly )V = F (x, y), V (xi , y) = Φi (y),
(x, y) ∈ G,
i = 1, 2,
where ∂2V 1 2 ∂ 2V ∂V , + m + V, L V = y(1 − y) − (m + 1)(2y − 1) y 2 2 ∂x 2 ∂y ∂y −m/2 x/2 F (x, y) = e 4y(1 − y) f (ex , 2y − 1).
Lx V =
Approximate the operator Ly by a difference operator with an exact spectrum similar to Exercise 6.35. Exercise 6.37. Given the Sturm-Liouville problem Lu(x) + λu(x) = [(1 − x2 )u0 (x)]0 + λu(x) = 0,
x ∈ (−1, 1), (6.60)
|u(−1)| = 6 ∞,
|u(1)| 6= ∞,
and let Pn (x) be the Legendre polynomials. To construct the 3-point difference scheme which has the exact spectrum of (6.60) λn = n(n + 1),
un (x; λn ) = Pn (x),
x ∈ (−1, 1),
n = 0, 1, . . . ,
(6.61)
use the stencil functions v1i and v2i which on an arbitrary grid ωh = {−1 < x−N < x−N +1 < · · · xN < 1}
(6.62)
satisfies the equations Lvαi (x) + λvαi (x) = 0,
x ∈ (xi−1 , xi+1 ),
v1i (xi−1 ) = 0,
dv1i (xi−1 ) = 1, dx
v2i (xi+1 ) = 0,
dv2i (xi+1 ) = −1. dx
α = 1, 2, (6.63)
213
214
Chapter 6. Exercises and solutions Exercise 6.38. The Sturm-Liouville problem u00 (x) − 2xu(x) + λu(x) = 0, Z ∞ 2 e−x u2 (x)dx < ∞
x ∈ (−∞, ∞), (6.64)
−∞
possesses the exact solution λn = 2n,
un (x) = un (x; λn ) = Hn (x),
x ∈ (−∞, ∞),
n = 0, 1, . . . ,
where Hn (x) are the Hermite polynomials [6]. Show that on the finite grid √ ωh = {xi = ih : i = −N, . . . , N, h = 1/ N } the difference scheme yx,x (x) − 2xy ◦ (x) + λh y(x) = 0,
x ∈ ωh ,
x
y(x−N −1 ) 6= ∞,
(6.65) y(xN+1 ) 6= ∞
has the exact eigenvalues of the given problem (6.64), i.e. the eigenvalues λhn = 2n,
6.2
n = 0, 1, . . . , 2N + 1.
Solutions
Solution 6.1. Check that the exact solution satisfies the EDS. ˆ h can be written in the form Solution 6.2. The EDS on the grid ω uj = Y j (xj , uj−1 ),
j = 1, 2, . . . , N,
where Y j (x, uj−1 ) =
B0 u0 + B1 uN = β,
Y1j (x, uj−1 )
!
Y2j (x, uj−1
is the solution of the IVP dY1j (x, uj−1 ) = Y2j (x, uj−1 ), dx h i2 dY2j (x, uj−1 ) = − Y2j (x, uj−1 ) , dx
x ∈ (xj−1 , xj ],
Y1j (xj−1 , uj−1 ) = u1,j−1 , Y2j (xj−1 , uj−1 ) = u2,j−1 ,
j = 1, 2, . . . , N.
(6.66)
6.2. Solutions The general solution of the ODE is Y1j (x, uj−1 ) = ln |x + C1 | + C2 ,
Y2j (x, uj−1 ) =
1 . x + C1
The relations Y j (xj−1 , uj−1 ) = ln |xj−1 + C1 | + C2 = u1,j−1 , Y2j (x, uj−1 ) =
1 = u2,j−1 , xj−1 + C1
yield C1 =
1 u2,j−1
− xj−1 ,
C2 = u1,j−1 − ln
1 |u2,j−1 |
.
Thus, the solution of the IVP (6.66) is the function ln |1 + (x − xj−1 ) u2,j−1 | + u1,j−1 , Y j (x, uj−1 ) = u2,j−1 1 + (x − xj−1 )u2,j−1 and we obtain the two-point EDS ln |1 + hj u2,j−1 | + u1,j−1 . uj = u2,j−1 1 + hj u2,j−1 Solution 6.3. In accordance with our theory we obtain the following 4-EDS: (4) (4) (4) (4) (6.67) y j = Y (4)j xj , y j−1 , j = 1, 2, . . . , N, B0 y 0 + B1 yN = β, where by the classical Runge-Kutta method of order 4 we have hj (4) (4) (k1 + 2k2 + 2k3 + k4 ) , Y (4)j xj , y j−1 = y j−1 + 6 hj (4) hj k1 (4) k1 = f xj−1 , y j−1 , k2 = f xj−1 + , y j−1 + , 2 2 hj (4) hj k 2 (4) k3 = f xj−1 + , y j−1 + , k4 = f xj−1 + hj , y j−1 + hj k3 , 2 2 ! u2 . f (x, u) ≡ −u22 (4)
yj
≈ uj ,
Solution 6.4. We have from (6.7) u(xi−1 ) = tan
a xn+1 + C . n + 1 i−1
(6.68)
215
216
Chapter 6. Exercises and solutions Furthermore, by evident transformations we obtain successively a xn+1 , C = arctan (u(xi−1 )) − n + 1 i−1 a a n+1 n+1 x x + arctan (u(xi−1 )) − u(xi ) = tan n+1 i n + 1 i−1 a (xi − xi−1 ) + u(xi−1 ) tan n+1 , = a (xi − xi−1 ) 1 − (xi − xi−1 ) tan n+1 (6.69) a tan (x − x ) + u(x ) i i−1 i−1 u(xi ) − u(xi−1 ) 1 n+1 − u(xi−1 ) = a hi hi (xi − xi−1 ) 1 − u(xi−1 ) tan n+1 a a tan (xi − xi−1 ) + u2 (xi−1 ) tan (xi − xi−1 ) n+1 n+1 = , a (xi − xi−1 ) hi 1 − u(xi−1 ) tan n+1 and therefore the two-point EDS is a (xi − xi−1 ) tan n+1 uxi = hi
1 + u2 (xi−1 ) , a (xi − xi−1 ) 1 − u(xi−1 ) tan n+1
(6.70)
u(x0 ) = −u(xN ). ˆ h can be written in the form Solution 6.5. The EDS on the grid ω uj = Y j (xj , uj−1 ),
j = 1, 2, . . . , N,
u0 = −uN ,
j
where Y (x, uj−1 ) is the solution of the IVP dY j (x, uj−1 ) = axn Y j (x, uj−1 ) + 1 , dx j
Y (xj−1 , uj−1 ) = uj−1 ,
x ∈ (xj−1 , xj ],
j = 1, 2, . . . , N.
The general solution of the ODE in (6.71) is a j n+1 Y (x, uj−1 ) = tan x +C . n+1 Thus we have Y j (xj−1 , uj−1 ) = tan
a xn+1 + C n + 1 j−1
= uj−1 ,
(6.71)
6.2. Solutions C = arctan uj−1 −
a xn+1 , n + 1 j−1
and the solution of the IVP (6.71) is a n+1 j n+1 x Y (x, uj−1 ) = tan − xj−1 + arctan uj−1 . n+1 Now the two-point EDS can be represented in the form a n+1 n+1 x − xj−1 + arctan uj−1 , uj = tan n+1
j = 1, 2, . . . N,
u0 = −uN . Solution 6.6. In accordance with our theory we obtain the 2-TDS (2) (2) (2) (2) yj = Y (2)j xj , yj−1 , j = 1, 2, . . . , N, y0 = −yN ,
(6.72)
where by the two-stage Runge-Kutta method of order 2 (the so-called modified polygon method or Heun’s method) we have (2) (2) (2) yj ≈ uj , Y (2)j xj , yj−1 = yj−1 + hj k2 , (2) k1 = f xj−1 , yj−1 ,
k2 = f
xj−1 +
hj (2) h j k1 , yj−1 + 2 2
,
f (x, u) ≡ axn (u2 + 1). Here one can use any Runge-Kutta method of order 2. The EDS (6.72) is a nonlinear system of algebraic equations. Analogously one can develop the 3-TDS (3) (3) yj = Y (3)j xj , yj−1 , j = 1, 2, . . . , N,
(3)
(3)
y0 = −yN ,
where e.g. the following three-stage Runge-Kutta formulas of order 3 (see e.g. [35], p. 29) is used hj (3) (3) (k1 + 4k2 + k3 ) , Y (3)j xj , yj−1 = yj−1 + 6 hj (3) h j k1 (3) k1 = f xj−1 , yj−1 , k2 = f xj−1 + , yj−1 + , 2 2 (3) k3 = f xj−1 + hj , yj−1 − hj k1 + 2hj k2 . Solution 6.7. We have from (6.10) u(xi−1 ) =
b e∆xi−1 − Ca , B e∆xi−1 − CA
def
C =
C2 , C1
C1 6= 0.
(6.73)
217
218
Chapter 6. Exercises and solutions Furthermore, by evident transformations we obtain successively C[a − Aui−1 ] = −e∆xi−1 [Bui−1 − b], C = e∆xi−1
ui−1 = u(xi−1 ),
b − Bui−1 , a − Aui−1 b − Bui−1 a − Aui−1 , b − Bui−1 − A e∆xi−1 a − Aui−1
b e∆xi − a e∆xi−1 ui = B e∆xi
(6.74)
ui − ui−1 e∆xi − e∆xi−1 = hi hi ×
B
a e∆xi
(b − Bui−1 )(a − Aui−1 ) . − A b e∆xi−1 + A Bui−1 (e∆xi − e∆xi−1 )
Now the EDS reads uxi =
e∆xi − e∆xi−1 hi ×
(b − Bui−1 )(a − Aui−1 ) , B a e∆xi − A b e∆xi−1 + A B ui−1 (e∆xi − e∆xi−1 )
(6.75)
u0 = uN . ˆ h can be written in the form Solution 6.8. The EDS on the grid ω uj = Y j (xj , uj−1 ),
j = 1, 2, . . . , N,
u0 = uN ,
where Y j (x, uj−1 ) is the solution of the IVP dY j (x, uj−1 ) = (AY j (x, uj−1 ) − a)(BY j (x, uj−1 ) − b), dx j
Y (xj−1 , uj−1 ) = uj−1 ,
x ∈ (xj−1 , xj ],
j = 1, 2, . . . , N.
The general solution of the ODE in (6.76) is Y j (x, uj−1 ) =
b exp(∆x) − Ca . B exp(∆x) − CA
Thus we have Y j (xj−1 , uj−1 ) = C=
b exp(∆xj−1 ) − Ca = uj−1 , B exp(∆xj−1 ) − CA
(b − uj−1 B) exp(∆xj−1 ) . a − uj−1 A
(6.76)
6.2. Solutions The solution of the IVP (6.76) is the function Y j (x, uj−1 ) =
b(a − uj−1 A) exp(∆x) − a(b − uj−1 B) exp(∆xj−1 ) , B(a − uj−1 A) exp(∆x) − A(b − uj−1 B) exp(∆xj−1 )
and we obtain the two-point EDS in the form uj =
b(a − uj−1 A) exp(∆xj ) − a(b − uj−1 B) exp(∆xj−1 ) , B(a − uj−1 A) exp(∆xj ) − A(b − uj−1 B) exp(∆xj−1 )
u0 = uN .
Solution 6.9. In accordance with our theory we obtain the 3-EDS (3) (3) (3) (3) yj = Y (3)j xj , yj−1 , j = 1, 2, . . . , N, y0 = yN , where the Runge-Kutta method of order 3 which we presented in Solution 6.6 is again used. Solution 6.10. For u ∈ C4 [0, 1] it holds that ∞ 2k (2k+2) i h X h u (x) 1 (4) = u (˜ x), uxx (x) − eu(x) − u00 (x) − eu(x) = 2 (2k + 2)! 12
(6.77)
k=1
with some x ˜ ∈ (x − h, x + h). For u ∈ C6 [0, 1] we have uxx (x) −
i h h2 h u(x) i e − eu(x) − u00 (x) − eu(x) 12 xx
h2 00 [u (x)]xx − eu(x) 12 h2 (4) 2 4 (6) h2 (4) h2 (6) ˜ u (x) + h u (˜ u (x) + u (x = x) − ˜) 12 6! 12 12
= uxx (x) − u00 (x) −
(6.78)
= O(h6 ), ˜˜ ∈ (x − h, x + h). with some x Solution 6.11. Analogously to Solution 6.10. Solution 6.12. Analogously to Solution 6.10. Solution 6.13. Use the fact that u(k) (x) = ak u(x). Solution 6.14. We have uxx (x) − 2u3 (x) − u00 (x) − 2u3 (x) ∞ (2k) ∞ X X u (x) 2k−2 h =2 = 2 u2k+1 (x)h2k−2 . (2k)! k=2
k=2
(6.79)
219
220
Chapter 6. Exercises and solutions Therefore the difference scheme uxx (x) − 2u3 (x) = 2
∞ X
u2k+1 (x)h2k−2 ,
x ∈ ωh , (6.80)
k=2
u(0) = 1,
u(1) = 0.5,
or, which is the same, uxx (x) − 2u3 (x) = 2h2 u(0) = 1,
u5 (x) , 1 − (hu(x))2
x ∈ ωh , (6.81)
u(1) = 0.5,
is exact and the difference scheme yxx (x) − 2y 3 (x) − 2
n X
y 2k+1 (x)h2k−2 = 0,
x ∈ ωh , (6.82)
k=2
y(0) = 1,
y(1) = 0.5
possesses a truncation error of order O(h2n ). Solution 6.15. We have uxx (x) + ω 2 u + u2 (x) −
A2 (1 − cos (2ωx + ϕ)) 2
A2 00 2 2 (1 − cos (2ωx + ϕ)) − u (x) + ω u + u (x) − 2 =2
∞ (2k)(x) X u k=2
(2k)!
h2k−2 = 2
∞ X
(6.83)
(−1)k ω 2k u(x)h2k−2 .
k=2
Therefore the difference scheme " uxx (x) + ω 2 u + u2 (x) − 2
∞ X
# (−1)k ω 2k h2k−2 u(x)
k=2
=
A2 (1 − cos (2ωx + ϕ)) , 2
u(0) = A sin (ϕ),
(6.84) x ∈ ωh ,
u(1) = A sin (ω + ϕ),
or, which is the same, uxx (x) + ω 2 u + u2 (x) − 2h2 =
A2 (1 − cos (2ωx + ϕ)) , 2
u(0) = A sin (ϕ),
ω4 u(x) 1 + (ωh)2 x ∈ ωh ,
u(1) = A sin (ω + ϕ),
(6.85)
6.2. Solutions is exact and the difference scheme " 2
2
yxx (x) + ω y + y (x) − 2
n X
# k
2k 2k−2
(−1) ω h
y(x)
k=2
=
(6.86)
A2 (1 − cos (2ωx + ϕ)) , 2
y(0) = A sin (ϕ),
x ∈ ωh ,
y(1) = A sin (ω + ϕ),
has a truncation error of order O(h2n ). Solution 6.16. We have u(k) (x) = bk ebx ,
k = 1, 2, . . . .
(6.87)
Thus, ∞ (2k)(x) X u u ln u u ln u 00 − u (x) − b =2 h2k−2 uxx (x) − b x x (2k)! k=2
∞ X = 2 b2k u(x)h2k−2 = b4 h2 k=2
(6.88) 1 u(x). 1 − (bh)2
The three-point difference scheme ∞
uxx (x) − b
X u ln u − 2 b2k u(x)h2k−2 = 0, x
x ∈ ωh , (6.89)
k=2
u(1) = eb ,
u(2) = e2b ,
or, which is the same (provided that |bh| < 1), uxx (x) − b b
u(1) = e ,
2b4 h2 u ln u − u(x) = 0, x 1 − (bh)2
x ∈ ωh , (6.90)
2b
u(2) = e ,
is exact. The difference scheme n
yxx (x) − b
X y ln y − 2y(x) b2k h2k−2 = 0, x
x ∈ ωh , (6.91)
k=2
y(1) = eb , or yxx (x) − b b
y(1) = e ,
y(1) = e2b ,
1 − (bh)2n−3 y ln y − 2b4 h2 y(x) = 0, x 1 − (bh)2 2b
y(1) = e ,
possesses a truncation error of order O(h2n ).
x ∈ ωh , (6.92)
221
222
Chapter 6. Exercises and solutions Solution 6.17. It can be easily seen that u(k) (x) = (−1)k k!c ak
a k 1 k = (−1) k! uk+1 (x), (ax + b)k+1 c
k = 1, 2, . . . .
Furthermore, we have (provided that h is sufficiently small) 2a 2a 0 00 uxx (x) + u u ◦ − u (x) + u u x c c i 2a h = [uxx (x) − u00 (x)] + u u00 (x) − u ◦ x c ∞ (2k) ∞ X u (x) 2k−2 2au X u(2k+1) (x) 2k h h =2 + (2k)! c (2k + 1)! k=2
k=1
(6.93)
∞ ∞ X 2au X a 2k+1 2k 2k+2 a 2k 2k−2 2k+1 =2 h u (x) − h u (x) c c c k=2
k=1
4 2
=
2a h c4
5
4 2
2a h u (x) u5 (x) 2 − 2 = 0. c4 ahu(x) ahu(x) 1− 1− c c
Thus the three-point difference scheme 2a u(x) u ◦ (x) = 0, x c c c , u(0) = , u(1) = b a+b uxx (x) +
x ∈ ωh , (6.94)
is exact. It is interesting to note that this difference scheme is exact on the exact solution but in general it has only a truncation error of second order if u belongs to the class C4 [0, 1]. On the other hand we have 2a 2a uxx (x) + u ux − u00 (x) + u u0 c c = [uxx (x) − u00 (x)] + =2
∞ (2k) X u (x) k=2
(2k)!
2a u [ux − u0 (x)] c
h2k−2
∞
+
2au X u(k) (x) k−1 h c k! k=2
(6.95)
6.2. Solutions =2
∞ X a 2k
c
k=2
=
2a4 h2 c4
∞
h2k−2 u2k+1 (x) +
a k 2au X (−1)k hk−1 uk+1 (x) c c k=2
2a3 h u5 (x) u3 (x) . 2 + 3 a hu(x) c a hu(x) 1 + 1− c c
Therefore the three-point difference scheme uxx (x) +
2a4 h2 2a u(x) ux (x) − 4 c c
x ∈ ωh ,
c u(0) = , b
u(1) =
2a3 h u5 (x) u3 (x) = 0, 2 + 3 a hu(x) c a hu(x) 1 + 1− c c
c a+b (6.96)
is exact, too. The difference scheme n
yxx (x) +
X a 2k 2a y(x) yx (x) − 2 h2k−2 y 2k+1 (x) c c k=2
+
2au c
n X k=2
c y(0) = , b or
(−1)k
a k c
y(1) =
hk−1 uk+1 (x) = 0,
x ∈ ωh ,
c , a+b
1 − (ah)2n−2 a y(x) yxx (x) + y yx − 2a4 h2 c 1 − (ah)2 n+1 a hu(x) 1 − − 2a3 hu3 (x) c − = 0, x ∈ ωh , c3 1 − (a h)2 c y(0) = , b
y(1) =
(6.97)
c , a+b
possesses a truncation error of order O(hn+1 ). Solution 6.18. It can easily be seen that u(k) (x) = (−1)k cak m(m + 1) · · · (m + k − 1) = (−1)k cak m(m + 1) · · · (m + k − 1)
1 (ax + b)k+m 1 u(x) (ax + b)k
(6.98)
223
224
Chapter 6. Exercises and solutions = (−1)k cak (m)k
1 u(x), (ax + b)k
def
where (m)k = m(m + 1) · · · (m + k − 1) is Pochhammer’s symbol. Further we have m+2 m+2 2 a m(m + 1) a m(m + 1) √ √ uxx (x) + u m (x) − u00 (x) + u m (x) m 2 m 2 c c 2
00
= [uxx (x) − u (x)] = 2
∞ (2k) X u (x) k=2
= 2c
∞ X
a2k
k=2
(2k)!
h2k−2
(6.99)
(m)2k 2k−2 1 h u(x). (2k)! (ax + b)2k
Thus the three-point difference scheme m+2 ∞ X a2 m(m + 1) (m)2k 2k−2 1 √ uxx (x) = h u m (x) + 2c a2k u(x), m 2 (2k)! (ax + b)2k c k=2 x ∈ ωh ,
u(0) =
c , bm
u(1) =
c , (a + b)m (6.100)
is exact and the difference scheme
a2 m(m + 1) √ y yxx (x) = m 2 c x ∈ ωh ,
y(0) =
c , bm
" n # m+2 X (m)2k 1 2k 2k−2 m (x) + 2c y(x), a h (2k)! (ax + b)2k k=2
y(1) =
c , (a + b)m (6.101)
has a truncation error of order O(h2n ). Solution 6.19. It can easily be seen that the exact solution satisfies
u(k) (x) =
(−1)k k!ak = (−1)k k!ak uk+1 (x). (ax + b)k+1
(6.102)
Using Taylor’s expansion and the formula for the sum of the infinite geometric progression we obtain
6.2. Solutions (k) ∞ k−1 (k) ∞ i X h X hj+1 uj (−1)k hk−1 uj j (2) − uxˆx,j − 2a2 u3j − uj − 2a2 u3j = k! k! k=3
=
∞ X
k+1 (−1)k hk−1 − j+1 uj
k=3
=
∞ X
k=3
hk−1 uk+1 j j
k=3
−h2j+1 a3 u4j (1
(6.103)
− hj+1 auj + (hj+1 auj )2 + · · · )
− h2j a3 u4j (1 + hj auj + (hj+1 auj )2 + · · · ) =−
h2j a3 u4j h2j+1 a3 u4j − , 1 + hj+1 auj 1 − hj auj def
def
ˆ , and hj = xj − xj−1 . where uj = u(xj ), xj ∈ ω Thus the three-point difference scheme uxˆx,j = 2a2 u3j − 1 u0 = , b
uN
h2j+1 a3 u4j h2j a3 u4j − , 1 + hj+1 auj 1 − hj auj
j = 1, 2, . . . , N − 1, (6.104)
1 , = a+b
is exact and the TDS yxˆx,j = 2a2 yj3 +
n X
k+1 (−1)k hk−1 − j+1 yj
k=3
y0 =
1 , b
yN =
n X
hk−1 yjk+1 , j
j = 1, 2, . . . , N − 1,
k=3
1 , a+b (6.105)
or yxˆx,j = 2a2 yj3 − − y0 =
h2j+1 a3 u4j (1 + (hj+1 auj )n+1 ) 1 + hj+1 auj
h2j a3 u4j (1 − (hj auj )n+1 ) , 1 − hj auj 1 , b
yN =
j = 1, 2, . . . , N − 1,
(6.106)
1 , a+b def
possesses a truncation error of order O(hn ), with h = maxj=1,...,N hj . Solution 6.20. Since u(k) = we have
(−1)k−1 (k − 1)!ak−1 0 u (x) ( ax + b)k−1
(6.107)
225
226
Chapter 6. Exercises and solutions uxx (x) + u2◦ (x) − u00 (x) + (u0 (x))2 x
h ih i = [uxx (x) − u00 (x)] + u ◦ (x) − u0 (x) u ◦ (x) + u0 (x) x
=2
∞ (2k) X u (x)
(2k)!
k=2
= −2
∞ X k=2
2k−2
h
k=1
" + (u (x))
2
∞ X
k=1
=−
k=2
" +
(2k + 1)!
#" 2k
h
∞ (2k+1) X u (x) k=1
(2k + 1)!
# 2k
h
0
+ 2u (x)
a2k h2k−2 u0 (x) (2k)(ax + b)2k
0
∞ X
+
x
"∞ X u(2k+1) (x)
a2k h2k (2k + 1)(ax + b)2k
#"
∞ X k=1
# a2k 2k h +2 (2k + 1)(ax + b)2k
a2k h2k−2 k(ax + b)2k
∞ X
k=1
a2k+1 h2k (2k + 1)(ax + b)2k+1
#"
∞ X k=1
# a2k+1 2a . h2k + (2k + 1)(ax + b)2k+1 ax + b
Thus the difference scheme uxx (x) = −u2◦ (x) − x
" +
∞ X
k=1
∞ X k=2
a2k h2k−2 k(ax + b)2k
a2k+1 h2k (2k + 1)(ax + b)2k+1
u(0) = ln b,
u(1) = ln (a + b),
#"
∞ X k=1
# a2k+1 2a 2k , h + (2k + 1)(ax + b)2k+1 ax + b
x ∈ ωh , (6.108)
is exact and the difference scheme yxx (x) = −y 2◦ (x) − x
" +
n X
k=1
n X k=2
a2k h2k−2 k(ax + b)2k
a2k+1 h2k (2k + 1)(ax + b)2k+1
y(0) = ln b,
y(1) = ln ((a + b)),
#"
n X k=1
# 2a a2k+1 2k , h + (2k + 1)(ax + b)2k+1 ax + b
x ∈ ωh , (6.109)
possesses a truncation error of order O(h2n ). In order to be able to write these schemes more compactly let us consider the series ∞ X def F 0 (q) = q 2k (6.110) k=1
6.2. Solutions and def
F (q) =
∞ X q 2k+1 , (2k + 1)
(6.111)
k=1 def
with q =
ah q2 . It can easily be seen that F 0 (q) = . Therefore ax + b 1 − q2
Z Z Z 1 q2 1 1 dq 1 1 dq + dq = − dq + F (q) = 2 2 0 1−q 2 0 1+q 0 1−q 0 1 1+q ah 1 ax + b + ah =− + ln . = −q + ln 2 1−q ax + b 2 ax + b − ah Z
1
(6.112)
Analogously we obtain F1 (q) =
∞ 2k X q k=2
2k
Z = 0
q
∞ X
! q
2k−1
=−
0
k=2
2
q
Z dq =
q 3 dq 1 − q2
2 2
1 a h q 1 − ln 1 − q 2 = − − ln 2 2 2(ax + b)2 2
(6.113)
2
2 2
(ax + b) − a h . (ax + b)2
Now, using the formulas (6.111) and (6.113) we can reformulate the EDS (6.108) in the compact form (ax + b)2 − a2 h2 ax + b + ah 1 1 ln , + uxx (x) = −u2◦ (x) + ln x 2 (ax + b)2 2 ax + b − ah (6.114) u(0) = ln b,
u(1) = ln (a + b),
x ∈ ωh .
Solution 6.21. Use the Taylor expansion. Solution 6.22. Using Solution 6.9 check that the difference scheme a uxx (x) + u(x)u ◦ (x) = 0, x c
x ∈ ω,
ca2 h a = 0, ux (0) + u(0) − 2 b b (ah + b)
u(1) =
c , a+b
(6.115)
is exact. The left boundary condition can be written in the form ca2 h a ux (0) + u(0) − 2 b b (ah + b) k ∞ ca2 h X ah a − = 0. = ux (0) + u(0) − 3 b b b k=0
(6.116)
227
228
Chapter 6. Exercises and solutions The TDS a yxx (x) + y(x)y ◦ (x) = 0, x c
x ∈ ω,
k n ca2 h X ah a yx (0) + y(0) − 3 − = 0, b b b
y(1) =
k=0
or
a yxx (x) + y(x)y ◦ (x) = 0, x c
c a+b
(6.117)
x ∈ ω,
n+1 ah 1 − − ca2 h a b = 0, yx (0) + y(0) − 3 ah b b 1+ b
(6.118) c y(1) = a+b
has a truncation error of order O(hn+2 ). Solution 6.23. We have ux,x (x) − u00 + f (x, u) [u ◦ (x) − u0 (x)] x
∞ (2k) X
u
=2
k=2
=2
∞
X u(2k+1) (x) (x) 2k−2 h h2k + 2f (x, u) (2k)! (2k + 1)!
∞ X ϕ2k (x)
k=2
(6.119)
k=1
(2k)!
h2k−2 u(x) + 2f (x, u)
∞ X ϕ(2k+1) (x) k=1
(2k + 1)!
h2k u(x).
Thus the three-point difference scheme ux,x (x) = −u ◦ f (x, u) x
" + 2
∞ X k=2
# ∞ X ϕ(2k+1) (x) 2k ϕ2k (x) 2k−2 h h u(x), + 2f (x, u) (2k)! (2k + 1)!
x ∈ ω,
(6.120)
k=1
u(0) = γ0 ,
u(1) = γ1 ,
is exact. The truncation error of the following TDS is of order O(h2n+1 ) for an arbitrary n: yx,x (x) = −y ◦ f (x, y(x)) x
" + 2
n X ϕ2k (x) k=2
(2k)!
y(0) = γ0 ,
h
2k−2
+ 2f (x, u)
y(1) = γ1 .
n X ϕ(2k+1) (x) k=1
(2k + 1)!
# 2k
h
u(x),
x ∈ ω,
(6.121)
6.2. Solutions Solution 6.24. Use the fact that u(k) (x) = ϕk (x)u(x) with ( n(n − 1) · · · (n − k + 1)x−k , if k ≤ n, ϕk (x) = 0, if k > n and the results of the previous exercise. ˆ Solution 6.25. Let the grid ω ¯ h be given. There exists the EDS " # 2 j X Y (x , u) − u j β ux¯xˆ,j = −~−1 (−1)α Zαj (xj , u) + (−1)α α j , j Vα (xj ) α=1 u0 = µ1 ,
j = 1, 2, . . . , N − 1,
uN = µ2 ,
where Yαj (x, u), Zαj (x, u), α = 1, 2, are the solutions of the IVPs dYαj (x, u) = Zαj (x, u), dx
Yαj (xβ , u)
1 dZαj (x, u) =h i3 , dx Yαj (x, u)
Zαj (xβ , u)
= uβ ,
x ∈ ejα , (6.122)
du = k(x) , dx x=xβ
j = 2 − α, 3 − α, . . . , N + 1 − α,
α = 1, 2.
These IVPs possess the exact solutions s s (C1 x + C2 )2 + 1 C1 j j Yα (x, u) = , , Zα (x, u) = (C1 x + C2 ) C1 (C1 x + C2 )2 + 1
du C1 = dx
2 x=xβ
1 + 2, uβ
C2 = uβ
du dx
− xβ C1 . x=xβ
Therefore the EDS is of the form ux¯xˆ,j =
−~−1 j
2 X
" α
(−1)
(C1 xj + C2 )
α=1
s
C1 (C1 xj + C2 )2 + 1
s (−1)α (C1 xj + C2 )2 + 1 + − uβ , hγ C1 u0 = µ1 ,
uN = µ2 ,
j = 1, 2, . . . , N − 1,
Solution 6.26. In accordance with our theory we obtain the 6-EDS (6)
yx¯x,j = −ϕ(6) (xj , y (6) ), (6)
ϕ
−1
(xj , u) = h
2 X α=1
j = 1, 2, . . . , N − 1, "
(−1)α
(6)
y0 = µ1 ,
(6)
yN = µ2 , # (6.123) (6)j (xj , u) − uβ (6)j α Yα , Zα (xj , u) + (−1) h
229
230
Chapter 6. Exercises and solutions (6)j
(6)j
where Yα (xj , u), Zα (xj , u) is the numerical solution of the IVP (6.122), obtained by the Runge-Kutta-Nystrom method of order 6 (see [14, 31])
Yα(6)j (xj , u)
α+1
= uβ + (−1)
hu0β
2
+h
151 5 385 k1 + k2 + k3 2142 116 1368
55 6250 k4 − k5 , 168 28101 151 25 275 275 (6)j 0 α+1 Zα (xj , u) = uβ + (−1) k1 + k2 + k3 + k4 h 2142 522 684 252 78125 1 k5 + k6 , − 112404 12 k1 = −f xβ , uβ , k2 = −f xβ + 0.1 (−1)α+1 h, uβ + 0.1 (−1)α+1 hu0β + 0.005h2 k1 , +
k3 = −f xβ + 0.3 (−1)α+1 h, uβ + 0.3 (−1)α+1 hu0β −
1 2 1 h k1 + h2 k2 , 2200 22
k4 = −f xβ + 0.7 (−1)α+1 h, uβ + 0.7 (−1)α+1 hu0β +
637 2 h k1 6600
−
7 2 7 h k2 + h 2 k3 , 110 33
17 17 225437 2 30073 2 (−1)α+1 h, uβ + (−1)α+1 hu0β + h k1 − h k2 25 25 1968750 281250 65569 2 9367 2 h k3 − h k4 , + 281250 984375
k5 = −f xβ +
k6 = −f xβ + (−1)α+1 h, uβ + (−1)α+1 hu0β + +
151 2 5 2 385 2 h k1 + h k2 + h k3 2142 116 1368
55 2 6250 2 h k4 − h k5 , 168 28101
f (x, u) = −
1 , u3
µ1 = 0,
µ2 = − ln cos2
1 √ 2
.
Solution 6.27. We have
uxk =
(−1)k k!abk (−1)k k!bk k+1 = u , (bx + cy + d)k+1 ak (6.124)
uyk
(−1)k k!ack (−1)k k!ck k+1 = = u , k+1 (bx + cy + d) ak
k = 1, 2, . . . ,
6.2. Solutions and for (x, y) ∈ ωh1 ,h2 it holds that ux,x (x, y) =
u(x + h1 , y) − 2u(x, y) + u(x − h1 , y) h21 ∞
=
X 1 ∂ 2k u(x, y) ∂ 2 u(x, y) +2 h2k−2 1 2 ∂x (2k)! ∂x2k k=2
2k ∞ X ∂ 2 u(x, y) 2k−2 b = + 2 h1 u2k+1 ∂x2 a k=2
4 1 ∂ 2 u(x, y) 2 b = + 2h1 u5 , ∂x2 a 1 − h21 (b/a)2 u2
(6.125)
u(x, y + h2 ) − 2u(x, y) + u(x, y − h2 ) uy,y (x, y) = h22 ∞
=
X 1 ∂ 2k u(x, y) ∂ 2 u(x, y) + 2 h2k−2 2 ∂y 2 (2k)! ∂y 2k k=2
2k ∞ X ∂ 2 u(x, y) 2k−2 c = + 2 h2 u2k+1 ∂y 2 a k=2
4 1 ∂ 2 u(x, y) 2 c = + 2h2 u5 . ∂y 2 a 1 − h22 (c/a)2 u2 Thus the difference scheme ux,x (x, y) + uy,y (x, y) 4 4 1 1 b 2 c u5 (x, y) = 2 h21 + h 2 a 1 − h21 (b/a)2 u2 a 1 − h22 (c/a)2 u2 b2 + c2 3 u (x, y), (x, y) ∈ ωh1 ,h2 , a2 a a , u(1, y) = , u(0, y) = cy + d b + cy + d +2
u(x, 0) =
a , bx + d
u(x, 1) =
a bx + c + d
is exact. The TDS ux,x (x, y) + uy,y (x, y) = 2
Nx X k=2
2
+2
h2k−2 1
2k 2k Ny X b 2k−2 c 2k+1 u + 2 h2 u2k+1 a a
2
b +c 3 u (x, y), a2
(x, y) ∈ ωh1 ,h2 ,
k=2
231
232
Chapter 6. Exercises and solutions u(0, y) =
a , cy + d
u(1, y) =
a , b + cy + d
u(x, 0) =
a , bx + d
u(x, 1) =
a , bx + c + d
or ux,x (x, y) + uy,y (x, y) = 2h21 (b/a)4 u5 (x, y) + 2h22 (c/a)4 u5 (x, y)
1 − (hbu/a)2Nx −3 1 − (h1 bu/a)2
1 − (hcu/a)2Ny −3 1 − (h2 cu/a)2
b2 + c 2 3 u (x, y), (x, y) ∈ ωh1 ,h2 , a2 a a , u(1, y) = , u(0, y) = cy + d b + cy + d +2
u(x, 0) =
a , bx + d
u(x, 1) =
a , bx + c + d 2Ny −1
has a truncation error of order O(h12Nx −1 + h2
).
Solution 6.28. This problem can be solved analogously to the solution of the previous exercise. Solution 6.29. Use the Taylor expansion for the finite difference and the fact that u(k) (x) = Fk (u(x)),
k = 1, 2, . . . ,
where e.g., F0 (u) = f (u),
F1 (u) = f 0 (u) f (u),
etc.
Solution 6.30. Use the finite difference uxx to approximate the second derivative and the fact that the Taylor expansion of uxx − u00 contains only derivatives of even order which can be expressed through the derivatives of the right-hand side f (u). Solution 6.31. This problem can be solved analogously to the solution of the previous exercise. Solution 6.32. We transform problem (6.53) into √ u(xi+1 ) − 2 cos (h λ)u(xi ) + u(xi−1 ) = 0, u(0) = 0,
u(1) = 0,
(6.126)
i = 1, . . . , N.
This is the well-known recurrence formula for the orthogonal Chebyshev polynomials of first and second kind, Ti (z) = cos (i arccos (z)),
Ui (z) =
sin ((i + 1) arccos z) √ , 1 − z2
6.2. Solutions √ def where z = cos (h λ). The left boundary condition in (6.126) yields √ √ sin (ih λ) √ , u(xi ) = a Ui (h λ) = a sin (h λ) where a is an arbitrary constant. We choose this constant subject to the condition a √ =1 sin (h λ) and obtain
√ u(xi ) = sin (ih λ),
i = 0, 1, . . . , N + 1.
The right boundary condition is satisfied provided that λ satisfies √ u(1) = u(xN+1 ) = sin ( λ) = 0, i.e., λ = λn = (nπ)2 ,
un (xi ) = sin (nπxi ) = sin (inπ/(N + 1)),
i = 0, . . . , N + 1,
n = 1, . . . , N.
Solution 6.33. The difference equation (6.54) in indexed form reads yi+1 − (2 − h2 λh )yi + yi−1 yi = 0,
i = 0, 1, . . . , N + 1,
(6.127)
and the solution satisfying the left boundary condition is (compare with the previous exercise) λh h2 , i = 0, 1, . . . , N + 1. y(xi ) = sin i arccos 1 − 2 The right boundary condition is fulfilled provided that λh satisfies y(1) = y(xN +1 ) = sin (N + 1) arccos 1 −
λh h2 = 0. 2
This implies arccos 1 −
λh h2 kπ = , 2 N +1
k = 1, . . . , N
or 1−
λh h2 = cos 2
kπ . N +1
Thus, we have 2 kπ sin 2(N + 1) kπ (kπ)2 . λhk = 2 1 − cos (N + 1)2 = kπ N +1 2(N + 1)
233
234
Chapter 6. Exercises and solutions For a fixed k independent of N we have from the Taylor expansion kπ 2 sin 1 kπ 2(N + 1) λhk = + ··· (kπ)2 = (kπ)2 1 − kπ 3! N + 1 2(N + 1) = (kπ)2 + O(h2 ). Note that the first eigenfunction y1 (x) = sin (πx), x ∈ ω coincides with the projection of the first exact eigenfunction u1 (x) = sin (πx) onto the grid. Solution 6.34. The EDS for (6.55) is √ i λn 2(N + 1) √ u(xi ) = 0, i = 1, 2, . . . , N, uxx (xi ) + λn i λn 2(N + 1) √ i λn − 1 sin 2(N + 1) √ u(xi ) = 0, i = N + 2, . . . , 2N + 1, uxx (xi ) + λn i λn − 1 2(N + 1) p p u(1/2) = A sin ( λn h) + u(1/2 − h) cos ( λn h), sin
(6.128)
where p
p p p (λn − 1)λn A = − u(1/2 − h) λn − 1 cos (h λn ) cos (h λn − 1) ∆h p p p p − λn − 1 sin (h λn ) sin ( λn − 1h) − u(1/2 + h) λn − 1 , def
(6.129) def
∆h =
p
+
p p λn (λn − 1) sin (h λn ) cos (h λn − 1)
p
p p λn (λn − 1) cos (h λn ) sin (h λn − 1)
and λn is the n-th root of the equation √ √ √ √ λ λ−1 √ λ λ−1 def √ cos + λ cos sin = 0, f (λ) = λ − 1 sin 2 2 2 2
(6.130)
where the roots are ordered as follows: 0 < λ1 < λ2 < · · · λn < · · · .
(6.131)
6.2. Solutions The exact solution of (6.55) is √ sin ( λn x), √ un (x) = p sin ( λn − 1(1 − x)) √ sin ( λn /2), sin ( λn − 1/2)
0≤x≤
1 , 2
1 < x ≤ 1, 2
(6.132)
where λn is the n-th root of equation (6.130). This can be easily proved by the substitution of (6.132) into equation (6.55) for x ∈ (0, 1/2) and x ∈ (1/2, 1) (compare with Exercise 6.32) and into the continuity conditions [un (x)]x=1/2 = un (1/2 + 0) − un (1/2 − 0) = 0, [u0n (x)]x=1/2 = u0n (1/2 + 0) − u0n (1/2 − 0) = 0.
(6.133)
That fact that (6.132) satisfies the equation (6.128) can be checked by substitution of (6.132) into (6.128), elementary transformations and taking into account that λn is a root of equation (6.130). Note that the first eigenvalues are λ1 = 10.36327300443007 . . . , λ2 = 39.98316575543942 . . . ,
(6.134)
λ3 = 89.32573613877946 . . . . Solution 6.35. We consider problem (6.59) on a grid ωh = {xi = ih : i = −N, . . . , N },
(6.135)
where h must be determined. The truncation error of the difference operator for functions v ∈ C ∞ (a, b) is Ψ(x) = Lh v(x) − Lv(x) = 2
∞ X
h2k L(k) v,
k=1
where L(k) v =
A(x) B(x)(k + 1) (2k+1) v (2k+2) + v . (2k + 2)! (2k + 2)!
We look for the solution of the eigenvalue problem (6.57) as the projection of the function ∞ X v(x, h) = h2k vk (x) k=0
on the grid (6.135). Substituting this expression into (6.57) and comparing the coefficients in front of the powers of h, we obtain the following system of equations for vk (x): k X Lvk + λh vk = −2 L(l) vk−l , k = 0, 1, . . . . (6.136) l=1
235
236
Chapter 6. Exercises and solutions Note, the right-hand side is equal to zero for k = 0. The solution of (6.136) with k = 0 is a polynomial v0 (x) = Pn (x) of degree n. For v1 (x) we have Lv1 (x) + λh v1 (x) = −2L(1) v0 (x), (6.137) 6 ∞, |v1 (−1)| =
|v1 (1)| = 6 ∞,
where the parameter λh is the same as for v0 (x) = Pn (x), namely λh = λ = −a2 n(n +
b1 (b − a) − 1). 2a2
Since v0 (x) is a polynomial of degree n, the right-hand side of (6.137) is a polynomial of degree n − 3. This inhomogeneous problem is solvable iff the right-hand side is orthogonal to the solution Pn (x) of the homogeneous equation. Here, the orthogonality is defined with a weight function, as is usual for the Jacobi polynomials. This condition is fulfilled since Pn (x) is orthogonal to all polynomials of degree less than or equal to n − 1. Therefore this problem has a polynomial v1 (x) = Pn−3 (x) of degree n − 3 as a particular solution which is orthogonal to Pn (x). If we continue this process, then there exists a j0 such that vj (x) = 0 for all j > j0 . More precisely, the equation (in fact it is a system of 2N − 1 equations for the 2N + 1 unknowns yN , y−N +1 , . . . , yN ) Lh y(x) + λh y(x) = 0, x ∈ ωh (6.138) possesses a solution of the form y(x) = v(x, h) = v0 (x) + h2 v1 (x) + · · · + h2j0 vj0 (x),
x ∈ ωh .
To bring the number of equations of the system of linear algebraic equations (6.138) into agreement with the number of unknowns, we demand that the coefficients in front of y−N and yN vanish, i.e., 1 1 1 1 − (N − 1)2 h2 b b + (b − a)(N − 1)h + (b + a) + b 1 1 0 = 0, h2 2a2 h 2 2 1 − (N − 1)2 h2 1 1 1 b1 (b − a)[−(N − 1)h] + b1 (b + a) + b0 = 0. − h2 2a2 h 2 2 1 One can easily see that these equations coincide provided that b1 (b + a) + b0 = 0 2 and we have s 4a2 . (6.139) h= 2 4a2 (N − 1) + b1 (b − a)(N − 1) Thus, we have constructed the finite difference scheme (6.57) on the equidistant grid (6.135) with mesh size (6.139) and we have shown that its eigenvalues coincide with the first 2N − 1 exact eigenvalues λhn = λ = −a2 n(n +
b1 (b − a) − 1), 2a2
n = 0, 1, . . . , 2N − 2.
The difference eigenfunctions approximate the exact ones with accuracy O(h2 ).
6.2. Solutions Solution 6.36. After the change of variables y = (z + 1)/2 the operator Ly will be transformed into the Legendre differential operator which analogously as above can be approximated by a differencep operator with the exact spectrum on an equidistant grid with the mesh size h = 1/ N (N + 1). Solution 6.37. r Using the Legendre functions Pν (x) and Qν (x) with the parameter 1 1 + λ we can write ν=− + 2 4 v1i (x) = v1i (x; λ) = (1 − x2i−1 )[−Pν (x)Qν (xi−1 ) + Qν (x)Pν (xi−1 )], v2i (x) = v2i (x; λ) = (1 − x2i+1 )[−Pν (x)Qν (xi+1 ) + Qν (x)Pν (xi+1 )]. The exact 3-point relation for the solution of the spectral problem (without the boundary conditions) is u(xi ) =
v1i (xi ; λ) v2i (xi ; λ) u(x u(xi−1 ), ) + i+1 v1i (xi+1 ; λ) v2i (xi−1 ; λ)
(6.140)
i = −N + 1, . . . , N − 1. Next, in order to obtain the exact boundary conditions and to add two more equations to the system (6.140), let us determine the solution of the differential equation (6.60) on the interval [xN −1 , 1). Taking into account the second boundary condition in (6.60) we get u(x) =
Pν (x) u(xN −1 ), Pν (xN −1 )
from which we obtain the exact boundary condition Pν (xN ) u(xN −1 ). Pν (xN −1 )
u(xN ) =
(6.141)
Analogously we obtain the other exact boundary condition u(x−N ) =
Pν (x−N ) u(x−N +1 ). Pν (x−N +1 )
(6.142)
The exact spectral 3-point difference eigenvalue problem (6.140), (6.141) and (6.142) possesses the exact spectrum λn = n(n + 1),
un (x; λn ) = Pn (x),
x ∈ ωh ,
n = 0, 1, . . . , 2N + 1,
where Pn (x) are the Legendre polynomials. Solution 6.38. Difference equation (6.65) can be rewritten in the equivalent indexed form (N − i)yi+1 − 2N yi + (N + i)yi−1 + λh yi = 0, y−N −1 6= ∞,
yN+1 6= ∞.
i = −N, . . . , N,
237
238
Chapter 6. Exercises and solutions Comparing this equation with the difference equation for Kravchuk’s polynomials with p = 1/2, q = 1/2 (see e.g. [6]) and with the explicit representation (−1)n x!(2N − x)! n 1 , x = 0, . . . , 2N, kn (x) = ∆ n!2n (x − n)!(2N − x)! n = 0, 1, . . . ,
∆f (x) = f (x + 1) − f (x)
for all f (x),
one can see that the exact difference eigenfunctions are yi = yn (xi ) = kn (i + N),
i = −N, . . . , N.
On the relationship between Kravchuk’s polynomials and Hermite polynomials see e.g. [6]. The solution is completely analogous to the solution of Exercise 6.35.
Index Algorithm A, 80 Algorithm AG, 79 approximation error, 65 automatic grid generation, 77 a posteriori estimate, 77 h-h/2, 117 Banach’s Fixed Point Theorem, 13 modified, 13 BGSEXP, 74 boundary conditions 3rd kind, 112 boundary value problem, 41 monotone, 117 periodic, 76 Browder-Minty Theorem, 13 Bulirsch-Stoer-Gragg extrapolation, 74 Butcher tableau, 75, 116 BVP, see boundary value problem Carath´eodory conditions, 16 Carath´eodory’s Theorem, 16 Cauchy-Bunyakovsky-Schwarz inequality, 16 continuity conditions, 87, 125 difference boundary condition, 21, 22, 33 difference scheme compact, 58 consistent, 6 convergent, 7 self-adjoint, 130 stable, 6 truncated, 11 difference scheme of Numerov, 8 Dirichlet boundary condition, 83
discontinuity points, 87 first kind, 122 discretization, 4 divided difference, 4 Dormand-Prince method, 74 EDS, see exact difference scheme exact difference scheme, 19, 59, 129 2-point, 41, 54 3-point, 17, 30, 90 extrapolation method semi-implicit, 75 5-point difference scheme, 8 fixed point iteration, 50, 116 modified, 55, 61 flux, 86 Fortran, 73 fundamental matrix, 42 Gaussian elimination, 67, 116 Green’s function, 18, 29, 45, 64 discrete, 56 grid, 2 dense, 71 equidistant, 2 non-equidistant, 3 quasi-uniform, 3 uniform, 2 grid function, 4 grid point, 2 Gronwall’s Lemma, 45 increment function, 58 iteration method, 94, 108, 133 Maple, 28, 73 Mathematica, 28
I.P. Gavrilyuk et al., Exact and Truncated Differences Schemes for Boundary Value ODEs, International Series of Numerical Mathematics 159, DOI 10.1007/978-3-0348-0107-2, © Springer Basel AG 2011
239
240
Index matrix tridiagonal, 116 matrix norm subordinate, 42 Minkowski’s inequality, 16 m-TDS, ¯ 103 m-TDS, 20, 58, 69 multiple shooting method, 41 Newton’s method, 66 modified, 112 node, 2 n-TDS, 32 ODE, see ordinary differential equation ODE calls, 74 one-step method, 101, 114 operator contractive, 64 semi-continuous, 89, 124, 127 strongly monotone, 124, 128 order of accuracy, 7 order of convergence, 7 ordinary differential equation monotone, 83 stiff, 74 parameter natural, 67 parameter continuation, 67 path-following, 67 Peano’s Theorem, 15 Picard-Lindel¨of’s Theorem, 15 quasi-Newton method, 67 Richardson extrapolation, 77 RKEX78, 74 roundoff error, 72 Runge estimator, 72 Runge technique, 77, 116 Runge-Kutta method, 58, 101 7-stage, 74, 116 embedded, 77 RWPM, 74, 75
shooting points, 74 SIMPR, 75 6-TDS, 74, 115 solution weak, 88, 123, 126 solution in the extended sense, 16 stencil three-point, 83 stencil function, 17 step-size, 2 sub-grid, 2 superposition principle, 21 Taylor series method, 58, 101 TDS, see truncated difference scheme 3-point difference scheme, 9 Troesch’s test problem, 51, 68, 80 truncated difference scheme, 20, 103, 115 truncation error, 6 vector norm Euclidian, 42 weak solution, 84
241
Bibliography [1] R. P. Agarwal and D. O’Regan. Infinite Interval Problems for Differential, Difference and Integral Equations. Kluwer Academic Publishers, 2001. [2] U. M. Ascher, R. M. M. Mattheij, and R. D. Russell. Numerical Solution of Boundary Value Problems for Ordinary Differential Equations. Prentice-Hall Series in Computational Mathematics. Prentice-Hall, Englewood Cliffs, 1988. [3] A. Ashyralyev and P.E. Sobolevskii. New Difference Schemes for Partial Differential Equations. Birkhauser Verlag, Basel-Boston-Berlin, 2006. uller. Numerical solution [4] W. Auzinger, O. Koch, J. Petrickovic, and E. Weinm¨ of boundary value problems with an essential singularity. Technical Report 3/03, TU Wien, Institute for Applied Mathematics, 2003. uller. New aposteriori [5] W. Auzinger, O. Koch, D. Praetorius, and E. Weinm¨ error estimates for singular boundary value problems. Numerical Algorithms, 40:79–100, 2005. [6] G. Bateman and A. Erday. Higher Transcendental Functions [Russian translation], volume Vol. 2. Nauka, Moscow, 1974. [7] J. C. Butcher. On Runge-Kutta processes of high order. Journal Austral. Math. Soc., 4:179–194, 1964. [8] J. C. Butcher. Numerical Methods for Ordinary Differential Equations. John Wiley & Sons, Ltd., Chichester, West Sussex, 2003. [9] C. Carath´eodory. Vorlesungen u ¨ber reelle Funktionen. Dover (reprint), 1948. [10] E. A. Coddington and N. Levinson. Theory of Ordinary Differential Equations. McGraw-Hill, New York, 1955. [11] L. Collatz. The Numerical Treatment of Differential Equations. Springer Verlag, Berlin, 1960. [12] S. D. Conte and C. deBoor. Elementary Numerical Analysis. McGraw-Hill, New York, 1972.
242
BIBLIOGRAPHY [13] E. J. Doedel. The constructions to ordinary differential equations. SIAM J. Numer. Analysis, 15:450–465, 1978. [14] J. R. Dormand, E. A. El-Mikkawy, and P. J. Prince. Families of Runge-KuttaNystrom formulae. IMA J. of Numer. Analysis, 7:235–250, 1987. [15] Yu. Eidelman, V. Milman, and A. Tsolomitis. Functional Analysis - An Introduction. American Mathematical Society, Providence, Rhode Island, 2004. [16] R. Fazio. A novel approach to the numerical solution of boundary value problems on infinite intervals. SIAM J. Numer. Anal., 33:1473–1483, 1996. [17] L. Fox. Numerical Solution of Two-Point Boundary Value Problems in Ordinary Differential Equations. Clarendon Press, Oxford, 1957. [18] S. Fuˇcik and A. Kufner. Nonlinear Differential Equations. Elsevier, Amsterdam, Oxford, New York, 1980. [19] E. C. Jr. Gartland. Strong stability of compact discrete boundary value problems via exact discretizations. SIAM J. Numer. Analysis, 25:111–123, 1988. [20] I. P. Gavrilyuk. Grid schemes with exact and explicit spectra (in Russian). PhD thesis, Taras Shevchenko National University of Kiev, 1977. [21] I. P. Gavrilyuk. Algorithm for solving a class of one-dimensional variational inequalities. J. Sov. Math., 66:2250–2255, 1993. [22] I. P. Gavrilyuk. A class of one-dimensional variational inequalities in difference schemes of arbitrary given degree of accuracy. Z. Anal. Anwend., 12:751–758, 1993. [23] I. P. Gavrilyuk. Exact difference schemes and difference schemes of arbitrary given degree of accuracy for generalized one-dimensional third boundary value problems. Z. Anal. Anwend., 12:549–566, 1993. [24] I. P. Gavrilyuk, M. Hermann, M. Kutniv, and I. L. Makarov. Two-point difference schemes of an arbitrary given order of accuracy for nonlinear BVPs. Applied Mathematics Letters, 23(5):585–590, 2010. [25] I. P. Gavrilyuk, M. Hermann, M. V. Kutniv, and V.L. Makarov. New methods for nonlinear BVPs on the half-axis using Runge-Kutta IVP-solvers. Technical Report 05-18, Friedrich Schiller University Jena, Department of Mathematics and Computer Science, 2005. [26] I. P. Gavrilyuk, M. Hermann, M. V. Kutniv, and V.L. Makarov. Difference schemes for nonlinear BVPs on the semiaxis. Comput. Methods Appl. Math., 7:25–47, 2007.
BIBLIOGRAPHY [27] I. P. Gavrilyuk, M. Hermann, M.V. Kutniv, and V.L. Makarov. Difference schemes for nonlinear BVPs using Runge-Kutta IVP-solvers. Advances in Difference Equations, 2006:1–29, 2006. Article ID 12167. [28] L. B. Gnativ and M. V. Kutniv. Modified three-point difference schemes of high-order accuracy for systems of the second-order ordinary differential equations with monotone operator(in Ukrainian). Mathematical Methods and Physicomechanical Fields, 47:32–42, 2004. [29] L. B. Gnativ, M. V. Kutniv, and V. L. Makarov. Generalized three-point difference schemes of high-order accuracy for systems of second order nonlinear ordinary differential equations. Differential Equations, 45(7):998–1019, 2009. [30] G. H. Golub and C. F. Van Loan. Matrix Computations. The John Hopkins University Press, Baltimore and London, 1996. [31] E. Hairer, S. P. Nørsett, and G. Wanner. Solving Ordinary Differential Equations I, Nonstiff Problems. Springer Verlag, Berlin, Heidelberg, New York, 1993. [32] E. Hairer and G. Wanner. Solving Ordinary Differential Equations II, Stiff and Differential-Algebraic Problems. Springer Verlag, Berlin, Heidelberg, New York, 1996. [33] Ph. Hartman. Ordinary Differential Equations. Birkh¨auser Verlag, Boston, Basel, Stuttgart, 1982. [34] M. Hermann and D. Kaiser. Shooting methods for two-point BVPs with partially separated endconditions. ZAMM, 75:651–668, 1995. ohnlicher Differentialgleichungen, Anfangs[35] Martin Hermann. Numerik gew¨ und Randwertprobleme. Oldenbourg Verlag, M¨ unchen, Wien, 2004. [36] F. R. de Hoog and R. Weiss. The numerical solution of boundary value problems with an essential singularity. SIAM J. Numer. Anal., 16:637–669, 1979. [37] F. R. de Hoog and R. Weiss. An approximation theory for boundary value problems on infinite intervals. Computing, 24:227–239, 1980. [38] S. R. K. Iyengar and A. C. R. Pillai. Difference schemes of polynomial and exponential orders. Applied Mathematical Modelling, 13:58–62, 1989. [39] H. B. Keller. Numerical Methods for Two-Point Boundary-Value Problems. Blaisdell Publishing Company, Waltham, Massachusetts, Toronto, London, 1968. [40] H. B. Keller. Numerical Solution of Two-Point Boundary Value Problems. SIAM, Philadelphia, 1976.
243
244
BIBLIOGRAPHY [41] H. B. Keller and Jr. White, A. B. Difference methods for boundary value problems in ordinary differential equations. SIAM J. Numer. Anal., (12):791– 802, 1975. [42] M. V. Kutniv. Accurate three-point difference schemes for second-order monotone ordinary differential equations and their implementation. Comput. Math. Math. Phys., 40:368–382, 2000. [43] M. V. Kutniv. Three-point difference schemes of high accuracy order for systems of nonlinear ordinary differential equations of second order. Comput. Math. Math. Phys., 41:860–873, 2001. [44] M. V. Kutniv. High-order accurate three-point difference schemes for systems of second-order ordinary differential equations with a monotone operator. Comput. Math. Math. Phys., 42(5):724–738, 2002. [45] M. V. Kutniv. Three-point difference schemes of high accuracy order for second order nonlinear ordinary differential equations with the boundary conditions of the third type (in Ukrainian). Visnyk of Lviv University. Series Applied Mathematics and Computer Science, (4):61–66, 2002. [46] M. V. Kutniv. Modified three-point difference schemes of high-accuracy order for second order nonlinear ordinary differential equations. Comput. Methods Appl. Math., 3:287–312, 2003. [47] M. V. Kutniv. Modified three-point difference schemes of high accuracy order for the second-order monotone ordinary differential equations (in Ukrainian). Mathematical Methods and Physicomechanical Fields, 46:120–129, 2003. [48] M. V. Kutniv. Numerical solution of three-point difference schemes (in Ukrainian). Visnyk of Lviv University. Series Applied Mathematics and Computer Science, (6):68–73, 2003. [49] M. V. Kutniv, V. L. Makarov, and A. A. Samarskii. Accurate three-point difference schemes for second-order nonlinear ordinary differential equations and their implementation. Comput. Math. Math. Phys., 39:45–60, 1999. [50] M. Laspinska-Chrzczonowicz and P. Matus. Exact difference schemes for parabolic equations. Int. J. Numer. Anal. Mod., 5(2):303–319, 2008. [51] M. Lentini and H. B. Keller. Boundary value problems on semi-infinite intervals and their numerical solutions. SIAM J. Numer. Anal., 17:577–604, 1980. [52] R.E. Lynch and J.R. Rice. A high-order difference method for differential equations. Math. of Comp., 34:333–372, 1980. [53] Chawla M. M. A sixth order tri-diagonal finite difference method for general non-linear two point boundary value problems. J. Inst. Math. Appl., 24:35–42, 1979.
BIBLIOGRAPHY [54] V. L. Makarov. Orthogonal polynomials and difference schemes with exact and explicit spectrum (in Russian). PhD thesis, Taras Shevchenko National University of Kiev, 1974. [55] V. L. Makarov, I. P. Gavrilyuk, M. V. Kutniv, and M. Hermann. A two-point difference scheme of arbitrary given accuracy order for BVPs for systems of first order nonlinear ODEs. Comput. Methods Appl. Math., 4:464–493, 2004. [56] V. L. Makarov and S. G. Gocheva. Finite difference schemes of arbitrary accuracy for second-order differential equations on a half-line. Differ. Equ., 17:367–377, 1981. [57] V. L. Makarov and V. V. Guminskii. A three-point difference scheme of a high order of accuracy for a system of second-order ordinary differential equations (the nonselfadjoint case). Differ. Equ., 30:457–465, 1994. [58] V. L. Makarov, I. L. Makarov, and V. G. Prikazchikov. Exact difference schemes and schemes of any order of accuracy for systems of second-order differential equations (in Russian). Differ. Uravn., 15:1194–1205, 1979. [59] V. L. Makarov and A. A. Samarskii. Exact three-point difference schemes for second-order nonlinear ordinary differential equations and their implementation. Soviet Math. Dokl., 41:495–500, 1991. [60] V. L. Makarov and A. A. Samarskii. Realization of exact three-point difference schemes for second-order ordinary differential equations with piecewise smooth coefficients. Soviet Math. Dokl., 41:463–467, 1991. [61] P. A. Markowich. A theory for the approximation of solution of boundary value problems on infinite intervals. SIAM J. Math. Anal., 13:484–513, 1982. [62] P. A. Markowich. Analysis of boundary value problems on infinite intervals. SIAM J. Math. Anal., 14:11–37, 1983. [63] P. A. Markowich and C. A. Ringhofer. Collocation methods for boundary value problems on ”long” intervals. Math. Comp., 40:123–150, 1983. [64] P. Matus, U. Irkhin, and M. Lapinska-Chrzczonowicz. Exact difference schemes for time-dependent problems. Computational Methods in Applied Mathematics, 5:422–448, 2005. [65] P. Matus and A. Kolodynska. Exact difference schemes for hyperbolic equations. Comput. Meth. Appl. Math., 7(4):341–364, 2007. [66] P. P. Matus, U. Irkhin, M. Lapinska-Chrzczonowicz, and Lemeshevsky S. V. About exact difference schemes for hyperbolic and parabolic equations (in russian). Differ. Uravn., 43(7):978–986, 2006. [67] N. S. Nedialkov and J. D. Pryce. Solving differential-algebraic equations by Taylor series (i): Computing Taylor coefficients. BIT Numerical Mathematics, 45:561–591, 2005.
245
246
BIBLIOGRAPHY [68] J. M. Ortega and W. C. Rheinboldt. Iterative Solution of Nonlinear Equations in Several Variables. Academic Press, New York, London, 1970. [69] A. Paradzinska and P. Matus. High accuracy difference schemes for nonlinear transfer equation ∂u + u ∂u = f (u). Math. Model. Anal., 12(4):469–482, 2007. ∂t ∂x [70] M. Ronto and A. M. Samoilenko. Numerical-Analytic Methods in the Theory of Boundary-Value Problems. Word Scientific, Singapore, 2000. [71] A. A. Samarskii. Introduction to the Theory of Finite Difference Schemes. Nauka, Moscow, 1972. [72] A. A. Samarskii. The Theory of Difference Schemes. Marcel Dekker Inc., New York and Basel, 2001. [73] A. A. Samarskii and V. L. Makarov. Realization of exact three-point difference schemes for second-order ordinary differential equations with piecewise-smooth coefficients. Differ. Equ., 26:922–930, 1991. [74] A. A. Samarskii and B.S. Nikolaev. Solution Methods for Grid Equations(in Russian). Nauka, Moscow, 1978. [75] A. A. Samarskii and E. S. Nikolaev. Numerical Methods for Grid Equations, Vol.1. Birkh¨auser Verlag, Basel, 1989. [76] M. Schechter. Principles of Functional Analysis. Second edition. American Mathematical Society, Providence, Rhode Island, 2002. [77] C. Schmeiser. Approximate solution of boundary value problems on infinite intervals by collocation methods. Math. Comp., 46:479–490, 1986. [78] M. R. Scott and H. A. Watts. A systemalized collection of codes for solving twopoint boundary value problems. In A. K. Aziz, editor, Numerical Methods for Differential Systems, pages 197 – 227, New York and London, 1976. Academic Press. [79] J. Stoer and R. Bulirsch. Introduction to Numerical Analysis. Springer Verlag, New York, Berlin, Heidelberg, 2002. [80] A. N. Tihonov and A. A. Samarskii. Homogeneous difference schemes (in Russian). Zh. Vychisl. Mat. i Mat. Fiz., 1:5–63, 1961. [81] A. N. Tihonov and A. A. Samarskii. Homogeneous difference schemes of a high order of accuracy on non-uniform nets (in Russian). Zh. Vychisl. Mat. i Mat. Fiz., 1:425–440, 1961. [82] V.A. Trenogin. Functional Analysis(in Russian). Nauka, Moscow, 1980. [83] B. A. Troesch. A simple approach to a sensitive two-point boundary value problem. J. Comput. Phys., 21:279–290, 1976.
BIBLIOGRAPHY [84] W. Wallisch and M. Hermann. Schießverfahren zur L¨ osung von Rand- und Eigenwertaufgaben. Teubner-Texte zur Mathematik, Bd. 75. Teubner Verlag, Leipzig, 1985. [85] A. I. Zadorin. Numerical solution of a boundary value problem for a system of equations with a small parameter. Comput. Math. Math. Phys., 38(8):1201– 1211, 1998. [86] E. Zeidler. Nonlinear Functional Analysis and its Applications, volume I. Springer-Verlag, New York et al., 1986.
247