Next Article in Journal
Outer Topology Network Synchronization Using Chaotic Nodes with Hidden Attractors
Next Article in Special Issue
On Modified Interpolative Almost EType Contraction in Partial Modular bMetric Spaces
Previous Article in Journal
Multi-Strain Epidemic Models of Mutating Viruses with Airborne Transmission Based on Cellular Automata and Ordinary Differential Equations
Previous Article in Special Issue
A Fixed Point Theorem for Generalized Ćirić-Type Contraction in Kaleva–Seikkala’s Type Fuzzy b-Metric Spaces
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Communication

General Exact Schemes for Second-Order Linear Differential Equations Using the Concept of Local Green Functions

1
Department of Environmental Engineering, Faculty of Engineering and Information Technology, University of Pecs, Boszorkany str. 2, H-7624 Pecs, Hungary
2
Symbolic Methods in Material Analysis and Tomography Research Group, Faculty of Engineering and Information Technology, University of Pecs, Boszorkany str. 6, H-7624 Pecs, Hungary
3
Cellular Bioimpedance Research Group, Szentagothai Research Centre, University of Pecs, Ifjusag str. 20, H-7624 Pecs, Hungary
4
Department of Technical Informatics, Faculty of Engineering and Information Technology, University of Pecs, Boszorkany str. 6, H-7624 Pecs, Hungary
5
Institute of Information Technology, University of Dunaujvaros, Tancsics M. str. 1/A, H-2401 Dunaujvaros, Hungary
6
John von Neumann Faculty of Informatics, University of Obuda, Becsi str. 96/B, H-1034 Budapest, Hungary
*
Author to whom correspondence should be addressed.
Axioms 2023, 12(7), 633; https://doi.org/10.3390/axioms12070633
Submission received: 16 May 2023 / Revised: 24 June 2023 / Accepted: 25 June 2023 / Published: 27 June 2023
(This article belongs to the Special Issue Differential Equations and Related Topics)

Abstract

:
In this paper, we introduce a special system of linear equations with a symmetric, tridiagonal matrix, whose solution vector contains the values of the analytical solution of the original ordinary differential equation (ODE) in grid points. Further, we present the derivation of an exact scheme for an arbitrary mesh grid and prove that its application can completely avoid other errors in discretization and numerical methods. The presented method is constructed on the basis of special local green functions, whose special properties provide the possibility to invert the differential operator of the ODE. Thus, the newly obtained results provide a general, exact solution method for the second-order ODE, which is also effective for obtaining the arbitrary grid, Dirichlet, and/or Neumann boundary conditions. Both the results obtained and the short case study confirm that the use of the exact scheme is efficient and straightforward even for ODEs with discontinuity functions.

1. Introduction

Consider the linear second order inhomogeneous ordinary differential equation (ODE):
L u ( x ) = d d x κ ( x ) d d x u ( x ) + q ( x ) u ( x ) = f ( x ) ( 0 < x < )
where κ ( x ) κ 0 > 0 is a positive, arbitrary function, q ( x ) and f ( x ) are continuous functions and the function u ( x ) is the solution of ODE on the finite closed interval [ 0 , ] .
The use of boundary value problem (BVP) with Equation (1) for modeling physical phenomena is very rare in the relevant literature. A large part of the possible implicit application areas are the initial value problems (IVPs) prescribed by Equation (1) with constant coefficients. BVPs including the coefficients of the resistance (R), capacity (C) and inductance (L) can be used to model RLC circuits [1]. It is also well known that the IVP for Equation (1) is also used in harmonic analysis, where the coefficients are the spring constant, damping and mass [2]. Another group of applications consist of reaction diffusion equations, which, however, even in the simplest case, contain some nonlinear terms [3]. The third major field of science where equations such as Equation (1) can be found is the Sturm–Liouville theory [4]. In this case, although BVPs are solved for non-constant coefficient ODEs, equations can be interpreted as eigenvalue problems, and solutions are also known in special cases [4]. It follows that the BVPs defined by Equation (1) are a special group of ODEs. Perhaps the most well-known of these is the so-called Cauchy–Euler equation [5], where κ ( x ) = x , q ( x ) = 1 / x and f ( x ) = 0 .
Although the solutions of the mathematical problems mentioned above are well known, since several mathematical methods have been developed for their production, solutions for non-constant coefficient equations are known only in special cases (for example, the Cauchy–Euler equation [5]). Common methods for solving non-constant coefficient IVPs are the constant variation method, the method of undetermined coefficients, etc. [5].
The BVPs with Equation (1) are usually solved using well-known numerical methods, such as the finite difference method (FDM) [6], the finite volume method (FVM) [7] and the boundary element method (BEM) [8], by approximating the analytical solution of the ODE. Among the classical numerical methods for solving second-order differential equations, the finite element method (FEM) is presently the most widely used [9]. Nothing better illustrates the challenges of BVP defined by Equation (1) than the fact that, even in recent years, we can find publications where the authors researched methods for solving the non-constant coefficient problem [10,11,12].
This research is motivated by two main research directions. One of these directions is the study of symbolic approaches related to non-linear ODEs and systems, the so-called reaction–diffusion, cross-diffusion equations [13,14]. Further, the research group is ambitious in studying other types of non-linear ODEs, which are still intensively researched today [15,16,17]. The second research area is the inverse problems involving second-order differential equations, which are also non-linear mathematical problems [18]. Still, compared to the classical differential equation solvers, they require a completely different handling, since the functions to be determined are the coefficients of the differential equation [19,20,21]. All these research activities are supported by a solid foundation in exact schemes, which, as effective and robust mathematical methods, provide new perspectives for basic research.
Finding and then applying an analytical solution to solve the physical problems minimizes the additional errors induced by mathematical techniques. These efforts have already motivated many researchers who, as a result of their work, have presented some higher-order schemes for first- and second-order differential equations, as were presented in [22]. Other authors have published papers about using the beneficial properties of the Bessel equation [5] to solve homogenous equations with a second-order ODE in order to obtain the analytic solution [23]. In the case of singular secondary ODEs, solvability is still the subject of mathematical studies. Kiguradze et al. [24,25,26] published several related studies that thoroughly examine the difficulties of these mathematical problems to be solved.
This research also aims to develop a new analytical solving techniques to solve the BVPs in case of Equation (1). During our research work, we developed an exact solution technique that uses the inverse of the differential operator to solve the ODE. The methods we have deployed propose schemes that provide the values for the exact solution (We define the exact solution as the value of the analytical solution at any given location.) of Equation (1) at arbitrarily chosen grid points. The specific properties of the exact schemes are the main novelty of the presented research, with the introduced strength of their application compared to other alternative methods. In fact, there are two possible implementations. In the first case, without a mesh, we can use them to define symbolically the analytical solution itself. In the second case, using a mesh, we produce the values of the analytical solution in terms of grid points, without needing to determine the analytical solution itself [27]. The main advantage of this characteristic is its robustness and efficiency, which makes it irrelevant for the method how many grid points are chosen inside the domain, since the calculated values will always be the values of the analytical solution in grid points [27]. Compared with alternative solution methods, the use of exact schemes also leads to the solution of a linear system of equations with outstanding properties, still the matrix and the right-hand side of the system of equations are constructed with special functions, and the integration leads to the stability required to solve the linear system of equations. All these beneficial properties are guaranteed by the so-called local green functions, whose concept was presented by Vizvari et al. [27]. Local Green functions differ from global green functions in the following. While global green functions can be used to symbolically represent the analytical solution of the ODE, on the other hand, the local green functions are defined on the mesh intervals with the same properties as global green functions and they are used to form the system of linear equations that are generated with the exact scheme.
The application concept of the local Green functions [27] opens the possibility to develop a mathematical method deriving a recursive formula which allows us to compute the values of the analytic solution in grid points using simple linear algebraic methods. In the self-adjoint case, when q ( x ) = 0 for Equation (1), it has already been shown that integral functions of 1 κ ( x ) can be used to derive exact schemes using the apparatus of the FEM [27]. Using the electrical analogy, these local Green functions are integral functions of the material’s resistance, more precisely the resultant resistance of the material under investigation. In this paper, we also intend to use strictly positive test functions that generate the exact schemes based on the FEM apparatus for Equation (1) [9]. However, compared to the FEM, local green functions have the ability to invert the differential operator of the ODE as a result of performing the necessary partial integration. Based on the previous results [27], the local green functions have the same properties as the integrals of 1 κ ( x ) ; however, in this case, the local green functions are the results of solving a special initial value problem, since this guarantees the existence of the necessary and important properties that the exact scheme exploits. These facts complicate the results published in the previous work [27], since the solution of the initial value problem for a homogeneous equation can only be solved by using symbolic techniques, since here the goal is to generate functions. After all, the implementation of the exact scheme is possible even by fully numerical methods, since the use of local green functions and the necessary mathematical manipulations lead to discrete values of the analytical solution. The robustness and efficiency of the application of local green functions and exact schemes are best demonstrated by the solvability of ODEs with discontinuity functions and/or singular points, which will be presented in detail in the case studies.
Thus, the research of exact schemes is an important aspect in the domain of mathematical physics, and increasing the accuracy of such schemes is a continuous challenge for researchers. Furthermore, increasing the accuracy also increases the complexity and computational burden of the schemes, resulting in difficulties in applicability. However, our proposed schemes can overcome these limitations, as they provide the exact solution at an arbitrary location independent from the space discretization. Based on this fact, our research team have developed exact schemes for the symmetric, self-adjoint case ( q ( x ) = 0 ), that also work robustly for Dirichlet and mixed boundary conditions [27]. In this paper, as a continuation of our research work [27] and as a generalization of the self-adjoint case ( q ( x ) 0), we present our latest results in the field of exact schema research work. In the following sections, we will introduce the application of the exact scheme to Equation (1).
This paper is structured as follows. The first section is the introduction, and the second section presents the exact schemes developed for two cases. The first subsection introduces the concept of local green functions, the second subsection defines the exact scheme with the Dirichlet boundary condition [5] prescribed in both endpoints, and the third subsection shows the handling of mixed boundary conditions, where Dirichlet at one and Neumann boundary condition [5] at the other endpoint are prescribed. The third section introduces a brief case study with discontinuous function κ ( x ) . From these results, the fourth section draws the conclusions and establishes the future work.

2. The Exact Schemes

2.1. The Concept of Local Green Functions

As a first step in the concept of local green functions and by obtaining the solution of the initial value problems in Equations (3) and (4), we define ( 2 n ) non-negative functions on different subintervals. The exact scheme is generated based on a special symmetric system of the local Green functions. Now, let us consider an arbitrary discretization of the interval [ 0 , ] into ( n + 1 ) subintervals:
x 0 = 0 < x 1 < < x i 1 < x i < x i + 1 < < x n 1 < x n < x n + 1 =
where x i is the i t h grid point in interval [ 0 , ] ( i = 0 n + 1 ). Using these discretization, the local green functions are defined as the solutions of the initial value problems described in Equations (3) and (4):
{ (3a) L ψ i 1 ( x ) = 0 (3b) ψ i 1 ( x i 1 ) = 0 (3c) κ ( x i 1 ) d d x ψ i 1 ( x i 1 ) = 1
on interval x I i 1 = [ x i 1 , x i ] and
{ (4a) L φ i ( x ) = 0 (4b) φ i ( x i + 1 ) = 0 (4c) κ ( x i + 1 ) d d x φ i ( x i + 1 ) = 1
on interval x I i = [ x i , x i + 1 ] , where i = 1 , 2 , , n . Based on this, in order to produce the exact scheme, we need a positive monotonically increasing function ( ψ i 1 ( x ) ) and a positive, but monotonically decreasing function ( φ i ( x ) ), which we have defined as a solution to the initial value problem corresponding to a homogeneous equation and the appropriate initial conditions. From the derivatives listed in Equations (3) and (4), it is clear that the test functions ψ i increase monotonically and φ i decreases symmetrically on the interval of their domain [ x i , x i + 1 ] for all i = 1 , 2 , , n 1 . On the first interval [ x 0 , x 1 ] , only the test function ψ 0 is considered; and on the last interval [ x n , x n + 1 ] , we define only the test function φ n similar to the function in the FEM [9]. Based on the equalities in (3) and (4), these test functions can be considered as local green functions [27], which have the following useful property:
Theorem 1
(Symmetry of local green functions). Consider the [ x i , x i + 1 ] subinterval of the partition (2) of interval [ 0 , ] . Let ψ i ( x ) and φ i ( x ) be the test functions defined on subinterval [ x i , x i + 1 ] based on (3) and (4). The test functions ψ i ( x ) and φ i ( x ) are equal at the appropriate endpoints of the [ x i , x i + 1 ] interval, i.e.,:
ψ i ( x i + 1 ) = φ i ( x i ) = : 1 a i
where i = 1 , 2 , , ( n 1 ) and a i is the i t h coefficient of the constructed system of linear equations.
Proof 
To prove the Theorem 1, in the first step, multiply Equation (1) by ψ i ( x ) and in the second step by φ i ( x ) , subtract them from each other and integrate the difference on interval [ x i , x i + 1 ] with respect to x (using the properties presented in the Equations (3a) and (4a)):
0 = x i x i + 1 ψ i ( x ) L φ i ( x ) φ i ( x ) L ψ i ( x ) d x = x i x i + 1 ψ i ( x ) κ ( x ) φ i ( x ) d x + x i x i + 1 ψ i ( x ) q ( x ) φ i ( x ) d x + x i x i + 1 φ i ( x ) κ ( x ) ψ i ( x ) d x x i x i + 1 φ i ( x ) q ( x ) ψ i ( x ) d x
where the prime ( ) denotes the derivative with respect to x. After simplification and applying integration by parts on the right-hand side, the following form is obtained:
0 = ψ i ( x i + 1 ) κ ( x i + 1 ) φ i ( x i + 1 ) + ψ i ( x i ) κ ( x i ) φ i ( x i ) + φ i ( x i + 1 ) κ ( x i + 1 ) ψ i ( x i + 1 ) φ i ( x i ) κ ( x i ) ψ i ( x i )
Taking advantage of the special properties of the test functions (Equations (3b), (4b), (3c) and (4c)), the formula is simplified to:
0 = ψ i ( x i + 1 ) φ i ( x i ) ( i = 1 , 2 , , n )
This proves Theorem 1. □
Having introduced the symmetric concept of local green functions, the properties presented in Equations (3) and (4) and Theorem 1 allow us to construct the exact schemes as follows.

2.2. Dirichlet Boundaries

In the case of Dirichlet boundaries [5], the values of the solution at the endpoints are obtained as follows:
B D = u ( 0 ) = α , u ( ) = β
where B D is the set of Dirichlet boundary conditions [5].
The scheme that is used to obtain exact solutions to the Dirichlet problem in Equation (1) is described by the following theorem:
Theorem 2
(Exact Dirichlet scheme). If ψ i 1 ( x ) and φ i ( x ) are the test functions [9] satisfying the Equation (3), the Equation (4), respectively, and Theorem 1, the solution vector from following the exact scheme yields to the values of the analytical solution of Equation (1) at the grid points with boundary conditions in Equation (9). Equations (3) and (4) are special IVPs defined based on the homogeneous equation corresponding to the original ODE (Equation (1)).
Let us consider a system of n 3 linear equations:
b 1 u 1 a 1 u 2 = a 0 α + a 0 G 0 + a 1 H 1 a i 1 u i 1 + b i u i a i u i + 1 = a i 1 G i 1 + a i H i a n 1 u n 1 + b n u n = a n β + a n 1 G n 1 + a n H n
with indexes i = 2 , 3 , , ( n 1 ) . The solution vector of Equation (10) U = ( u 1 , u 2 , , u n ) T leads to the same values as the solution u ( x ) of the second-order ODE (1) with boundary conditions (9) at the interior grid points (2) without any error; that is, u ( x i ) = u i . The matrix of the system of linear equations constructed by recursion (Equation (10)) is a tridiagonal, symmetric, diagonally dominant (if q ( x ) 0 ), n × n matrix, whose inverse exists in all cases.
The coefficients in Equation (10) are defined as
a i 1 = 1 ψ i 1 ( x i ) = 1 φ i ( x i 1 )
b i = a i 1 1 + x i 1 x i q ( x ) ψ i 1 ( x ) d x + a i 1 + x i x i + 1 q ( x ) φ i ( x ) d x
G i 1 = x i 1 x i f ( t ) ψ i 1 ( t ) d t
H i = x i x i + 1 f ( t ) φ i ( t ) d t
where i = 1 , 2 , , n .
Proof 
In the first step, we multiply the ODE (1) by ψ i 1 ( x ) and integrate it over I i 1 :
x i 1 x i L u ( x ) ψ i 1 ( x ) d x = x i 1 x i f ( x ) ψ i 1 ( x ) d x = G i 1 .
After applying partial integration, the following expression is derived using the properties of ψ i 1 and multiplying with a i 1 (based on Equation (3)):
κ ( x i ) u ( x i ) + a i 1 ( u ( x i ) κ ( x i ) ψ i 1 ( x i ) u ( x i 1 ) ) = a i 1 G i 1 .
Similarly, we multiply ODE (1) by φ i ( x ) and integrate it over I i to obtain
x i x i + 1 L u ( x ) φ i ( x ) d x = x i x i + 1 f ( x ) φ i ( x ) d x = H i .
By applying partial integration, the following relation is obtained using the properties of φ i and multiplying with a i (based on Equation (4)):
κ ( x i ) u ( x i ) a i ( u ( x i + 1 ) + u ( x i ) κ ( x i ) φ i ( x i ) ) = a i · H i .
The fundamental recursive formula is obtained by adding Equation (16) and Equation (18), and using the equalities
κ ( x i ) ψ i 1 ( x i ) = 1 + x i 1 x i q ( x ) ψ i 1 ( x ) d x
and
κ ( x i ) φ i ( x i ) = 1 x i x i + 1 q ( x ) φ i ( x ) d x
obtaining from L ψ i 1 ( x ) = 0 and L φ i ( x ) = 0 , respectively, we obtain:
a i 1 u ( x i 1 ) + b i u ( x i ) a i u ( x i + 1 ) = a i 1 G i 1 + a i H i .
If we substitute i = 1 , 2 , 3 , , n and u ( 0 ) = α , u ( ) = β , we obtain Equation (10) in Theorem 2. It follows that:
u ( x i ) = u i ( i = 1 , 2 , . . . , n )
where u ( x i ) is the value of the analytical solution of the Equation (1) in the i t h mesh point and u i is the i t h element of the solution vector U. □

2.3. Exact Scheme for Dirichlet and Neumann Boundaries

In this case, we obtain the solution of the ODE (Equation (1)) using the following boundary conditions:
B D N = u ( 0 ) = α , κ ( ) u ( ) = δ .
Owing to the definition of the boundary conditions in Equation (23), the Dirichlet scheme cannot be used directly to obtain the values of the exact solution. However, the value of u ( ) can be calculated using β by defining the Neumann-to-Dirichlet transformation. Consider that the same manipulations lead to the identity (16), albeit on the entire interval [ 0 , ] . In this case, we obtain:
κ ( ) u ( ) + 1 ψ 0 ( ) u ( ) 1 + 0 q ( x ) ψ 0 ( x ) d x u ( 0 ) = 1 ψ 0 ( ) 0 f ( t ) ψ 0 ( t ) d t .
After the substitution κ ( ) u ( ) = δ , u ( 0 ) = α and isolating u ( ) from Equation (24), the Neumann boundary condition κ ( ) u ( ) = δ is transformed into the Dirichlet boundary value u ( ) , which can be substituted directly in the result presented in Theorem 2. The result of the isolation is
u ( ) = α + ψ 0 ( ) δ + 0 f ( t ) ψ 0 ( t ) d t 1 + 0 q ( x ) ψ 0 ( x ) d x .

3. Case Studies with Discontinuous κ ( x ) and Singular ODE

3.1. Implementation of the Exact Scheme to Solve Case Studies

In this section, we demonstrate the effectiveness and robustness of the proposed exact scheme in the case of a discontinuous κ ( x ) and a regular singular ODE, that appear in several physical and mathematical problems based on Equation (1). However, before solving the case studies, consider generally the application of the exact scheme in a step-wise sequence:
1.
After defining the ODE to be solved and the necessary boundary conditions (Dirichlet problem, mixed problem), based on Equation (2), we perform an arbitrary partition of the interval [ 0 , ] . The indexes of the nodes are: i = 0 , 1 , , n 1 , n , n + 1 , where 0 and n + 1 are the indices of the boundary points.
2.
Solving the initial value problems described with the Equations (3) and (4), we obtain the local Green functions ψ i 1 ( x ) and φ i ( x ) , respectively ( i = 1 , 2 , , n ).
3.
Based on Equations (11)–(14), we calculate all the coefficient values of the a i 1 , b i , G i 1 and H i , respectively ( i = 1 , 2 , , n ).
4.
Boundary conditions are also easily managed:
  • For Dirichlet boundary conditions, we use the substitution defined in Equation (9),
  • For mixed boundary conditions, we apply the Neumann to Dirichlet transformation based on the Equation (25) in order to calculate the potential value at the boundary point where the Neumann boundary condition is defined.
5.
Construct the linear system of equations defined in Equation (10), using the coefficient values and boundary conditions calculated before, and solve it by inverting the tridiagonal matrix.
6.
The elements of the vector obtained in this way are equal to the values of the analytic solution of the ODE defined in the first step taken in the grid points, according to the boundary conditions (according to Theorem 2).
The case studies presented in this work have been evaluated symbolically and numerically using the MAPLE software package in order to be able to show the local green functions in a symbolic way.

3.2. A Case Study for Discontinuous κ ( x ) with Increasing Mesh Resolution

First, we solve a Dirichlet and then a Dirichlet–Neumann problem using a mesh grid, wherein one of the grid points is provided at the breakpoint of the κ ( x ) function. Let the functions in Equation (1) be a q ( x ) = 2 constant,
κ ( x ) = ( x 2 ) 2 if x 1 2 if 1 < x
and
f ( x ) = 10 x 3 + 40 x 2 40 x + 6 if x 1 2 x 3 2 x 2 14 x + 6 if 1 < x
discontinuous functions. The solution of a problem prescribed in this manner is
u ( x ) = ( x 1 ) 2 ( x + 1 )
on the interval x [ 0 , 2 ] with
B D N = u ( 0 ) = 1 , u ( 2 ) = 3
boundary conditions.
In this case study, our goal is to show the efficiency and robustness of the exact scheme by solving an ODE with κ ( x ) , f ( x ) (presented in the Equations (26) and (27)) and constant q ( x ) functions for several mesh partitions with increasing resolution. Consider the mesh point coordinates in the interval [ 0 , 2 ] as follows:
x = [ 0 , 1 4 , 1 , 3 2 , 2 ]
The values of u ( x ) are determined using Theorem 2 in the grid points of the mesh. For the partitioning described in Equation (30), we divide the domain into 4 subintervals, i.e., n + 1 = 4 , hence we define the values of the analytic solution at n = 3 points. The point of interest is x 2 = 1 , which is exactly the breakpoint of κ ( x ) , where the analytic solution can also be determined using the exact scheme.
Consider first the mesh in Equation (30), which is defined based on instructions in Section 3.1 (point 1). According to point 2 in Section 3.1, Equations (3) and (4), the obtained local Green functions are defined in the Equation (31).
ψ 0 = 1 12 x x 2 6 x + 12 2 + x 2
ψ 1 = 1 588 4 x 1 16 x 2 92 x + 169 2 + x 2
ψ 2 = 1 4 e 1 + x e 1 x
ψ 3 = 1 4 e x + 3 / 2 e 3 / 2 + x
φ 1 = 1 588 4 x 1 16 x 2 92 x + 169 2 + x 2
φ 2 = 1 3 1 + x x 2 5 x + 7 2 + x 2
φ 3 = 1 4 e x + 3 / 2 e 3 / 2 + x
φ 4 = 1 4 e 2 + x + e x + 2
Figure 1 shows the functions in the Equation (31) on interval [ 0 , 2 ] .
Figure 1 illustrates the properties of the local green functions ψ i 1 and φ i . On each interval, ψ i 1 starts from zero and monotonically increases, according to the method used to generate it, and φ i starts from the maximum value and monotonically decreases until it reaches zero. In Figure 1, the symmetry property of the local green functions introduced in Theorem 1 is also evident. These properties of the local green functions, explained and exploited in Theorems 1 and 2, provide their physical meaning. To construct the exact schema defined in Theorem 2, the local green functions guarantee continuity boundary conditions in the connection of the subintervals. In fact, given the pair of test functions ψ i 1 ( x ) and φ i ( x ) with finite support on the interval [ x i 1 , x i + 1 ] , their zeros and special properties provide the flux elimination necessary to produce the recursive formula shown in Equation (10). Moreover, the continuity boundary conditions in the connection points of the subintervals, for the equality of the values of u ( x ) , arise from the special properties of the derivatives of the local green functions (Equations (3c) and (4c)), which will be exploited in the proof of Theorem 2.
Once the local green functions are determined, the coefficient values a i 1 , b i , G i 1 and H i can be calculated from Equations (11)–(14) to construct the linear system of equations described in Equation (10) ( i = 2 , 3 ). Based on the Theorem 2, the system in Equation (10) is expressed as follows:
268912 15717 196 93 0 196 93 4 93 109 e 16 e 1 4 e 1 / 2 e 1 0 4 e 1 / 2 e 1 4 ( e + 1 ) e 1 u 1 u 2 u 3 = 252105 20956 5 496 147 e + 248 e 1 / 2 147 e 1 5 2 e + 1 e 1 .
The values of the solution vector ( u 1 , u 2 , u 3 ) T = ( 45 / 64 , 0 , 5 / 8 ) T (obtained from Equation (32)) are equal to the values of u ( x ) that are obtained in points x 1 = 1 / 4 , x 2 = 1 and x 3 = 3 / 2 . The results of the case study are illustrated in Figure 2.
As it can be seen in Figure 2, the values of u i clearly coincide with the function u ( x ) . This illustrates, that the results obtained by applying the exact scheme described in Theorem 2 are equal to the values of the solution of ODE at the same grid points.
In the next step, we increase the resolution of the mesh by using the MAPLE random number generator to choose points within the interval [ 0 , 2 ] , under the condition that we retain x = 1 where is the discontinuity of κ ( x ) . Considering all this, by increasing the mesh generation resolution step by step, we solve the ODE defined (in terms of Equations (26) and (27) and q ( x ) = 2 ) under the boundary conditions in Equation (29) in three different cases:
1.
n + 1 = 16 subintervals and the analytic solution is calculated in n = 15 points,
2.
n + 1 = 51 subintervals and the analytic solution is calculated in n = 50 points,
3.
n + 1 = 101 subintervals and the analytic solution is calculated in n = 100 points.
In the next step, we solve the problem by using the considerations defined in Theorem 2. The solutions are shown in Figure 3.
Figure 3 clearly shows, that although the handling of the exact scheme is very similar to the classical numerical methods, the behavior of the solution is quite different. Comparing the graphs in Figure 3, it can be seen that the calculated potential values highlighted in red are visually identical to the grid point values of the analytical solution, i.e., the points highlighted in red coincide with the corresponding values of the function u ( x ) indicated in blue. Moreover, since the aforementioned facts can be observed in all three figures, we can conclude that the outstanding property proved in Theorem 2 is stable regardless of the mesh resolution.
In the last step, we can also solve the same example problem above with the functions κ ( x ) defined in the Equation (26), q ( x ) = 2 , f ( x ) defined in the Equation (27) and u ( 0 ) = 1 , and κ ( 2 ) u ( 2 ) = 14 mixed boundary conditions, since these can be defined by u ( x ) . Subsequently, using the Dirichlet-to-Neumann transformation (Equation (24)), we can easily verify that u ( 2 ) = 3 . During the application of the Equation (24), the continuity of the solution and flux must be ensured to determine ψ 0 ( x ) . Our statement can easily be verified by substituting into the formula of the Dirichlet-to-Neumann transformation and then isolating u ( 2 ) from the formula.

3.3. Case Study for a Singular ODE with a Piecewise Source Term

In this section, we demonstrate the effectiveness and robustness of the proposed exact scheme in the case of a regular singular ODE, which appears in several physical and mathematical problems based on Equation (1).
L u ( x ) = d d x x d d x u ( x ) + m 2 x u ( x ) = f ( x ) ( 0 < x < )
where κ ( x ) = x , q ( x ) = m 2 x , m R , m 0 and the source term is a noncontinuous function at x = 1 / 2 (in the Equation (34)).
f ( x ) = x , if x < 1 2 1 x , if 1 2 x
Equation (33) is a second order Cauchy–Euler type, singular-regular differential equation that has singularities at x = 0 and x . The aim of our case study is to show that the mathematical method presented in this paper is suitable for the effective treatment of singularities in addition to creating a solution for ODE Equation (33) with the boundary conditions defined in Equation (35). Furthermore, the exact scheme also handles the behavior of the source term robustly. In particular, the non-differentiable property of f ( x ) does not cause any problems for the implementation of the method. Although the function f ( x ) is non-differentiable, its integrals still exist; thus, the necessary calculations can be performed. We will examine how u ( x ) behaves at the singular points of ODE (Equation (33)). To perform this, we will add new mesh points a , b to exclude singularities and then obtain function u ( x ) on the new mesh by using the results presented in Theorem 2. Next, we will examine how the solution can be modified into a form in which the solution also exists at the singular points of the ODE by taking the limits a 0 + , b .
In order to obtain the solution ( u ( x ) ) to Equation (33), we choose the Dirichlet boundary conditions as follows:
B D = u ( a ) = α , u ( b ) = β .
where 0 < a 1 / 2 and 1 / 2 b < . The shape functions are
ψ 0 ( t ) = 1 2 m t m a m t m a m
and
φ 1 ( t ) = 1 2 m t m b m t m b m
Since functions ψ 0 ( t ) and φ 1 ( t ) are solutions to Equations (3) and (4), respectively, they have the following properties: ψ 0 ( a ) = 0 , φ 1 ( b ) = 0 and ψ 0 ( a ) = 1 a and φ 1 ( b ) = 1 b .
Figure 4 shows functions ψ 0 ( t ) and φ 1 ( t ) with substitutions a = 1 , b = 2 and m = 2 .
The local green functions in Figure 4 have the same properties as the functions in Figure 1, except that here the test function pair ψ 0 and φ 1 are the only pairs on the entire interval [ a , b ] . Obviously, this difference does not affect either the mathematical properties of the functions, or their physical properties according to the continuity boundary conditions.
After obtaining a 0 , a 1 , b 1 , G 0 and H 1 from ψ 0 ( t ) and φ 1 ( t ) using the Equations (11)–(14) in Theorem 2, the fundamental recursive formula (Equation (10)) for n = 1 inner point, and x 0 = x i 1 = a , x 1 = x , x i + 1 = x 2 = b is simplified in the form in the Equation (38).
a 0 α + b 1 u ( x ) a 1 β = a 0 G 0 + a 1 H 1 .
After isolating u ( x ) from the Equation (38) and a necessary simplification is carried out, the solution of the ODE (in Equation (33)) with the corresponding boundary conditions (in Equation (35)) is given by Equation (39).
u ( x ) = a m ( b 2 m x 2 m ) x m ( b 2 m a 2 m ) α + b m ( x 2 m a 2 m ) x m ( b 2 m a 2 m ) β + a b G ( x , t ) f ( t ) d t
where
G ( x , t ) = 1 2 m ( b 2 m a 2 m ) ( b 2 m x 2 m ) ( t 2 m a 2 m ) x m t m a t x b ( b 2 m t 2 m ) ( x 2 m a 2 m ) t m x m a x t b
In the next step, we examine how the solution function u ( x ) behaves at the singular points of the original ODE. The solution considers that the singular points are obtained by taking the limits a 0 + , b . We also consider the properties of the f ( x ) to evaluate improper integrals. If a 0 + , the limit of u ( x ) can be obtained from Equations (39) and (40) as follows when m > 0 :
lim a 0 + u ( x ) = x m b m β + 0 x f ( t ) ( b 2 m x 2 m ) t m 2 m x m b 2 m d t + x b f ( t ) ( t 2 m b 2 m ) x m 2 m t m b 2 m d t
Equation (41) is a significantly simplified form of Equation (39), which shows that the substitution has eliminated the u ( 0 ) = α Dirichlet boundary condition. Furthermore, it can be seen that at this point, when taking the limit b , the convergence of improper integrals is fulfilled only for certain functions f ( x ) . In our case study, we chose a source term that fulfills the following condition:
0 | f ( t ) | t m d t < ,
The equation for free space is obtained as:
u 0 ( x ) = lim b lim a 0 + u ( x ) = 0 x f ( t ) t x m d t + x f ( t ) x t m d t
Now, we can substitute f ( x ) (Equation (34)) into (43) and evaluate the integrals. Since f ( x ) is piecewise, the solution will be (if 0 < m 2 ).
u 0 ( x ) = x 2 m 2 4 2 m ( 8 3 m ) x m 8 ( m 2 ) m 2 0 x < 1 2 1 m 2 2 m ( 8 + 3 m ) x m 8 ( m + 2 ) m 2 1 2 x
It is easy to notice that u 0 ( x ) satisfies the original ODE (Equation (33)). It is interesting to note that in the case of m = 2 , the denominator of the solution (at interval 0 x < 1 2 ) becomes zero. It is also noticeable that the numerator of the same function also becomes zero for m = 2 . Therefore, instead of substitution, we can take the limit, which when evaluated with the L’Hospital rule, leads to the following result:
u 0 ( x ) = 1 16 x 2 ( 9 + 4 ln ( 2 x ) ) 0 x < 1 2 1 4 7 256 x 2 1 2 x
Function u 0 ( x ) is bounded in the singular points of ODE, because
u 0 ( 0 + ) = 0
and
lim x u 0 ( x ) = 1 m 2
is constant to any m. Figure 5 shows the graph of u 0 ( x ) for m = 1 , 2 , 3 , 4 .
As shown in Figure 5 and in Equations (44) and (45), function u 0 ( x ) is continuous and differentiable at x = 1 2 , even in the case of a discontinuous f ( x ) .

4. Conclusions

The application of the proposed scheme provides the opportunity to generate the values of the analytical solution that is obtained in grid points. This method can be easily implemented in different software environments (such as MATLAB, Maple, and Mathematica); thus, many physical problems can be modeled to avoid errors that are caused by the numerical approximations when using arbitrary grids. Currently, the most critical issue in the application of this scheme is to obtain the solution of a homogeneous equation, which may be challenging. Therefore, in future generalizations, we will consider the importance of providing a solution to this problem to complete the scope of the application areas. Furthermore, we generalize the concept presented in this paper by the application of the Sturm–Liouville theory, focusing on the symmetry of the local green functions and the gained advantageous properties.
The application of the exact scheme to Sturm–Liouville problems will represent a milestone in the research, that will complete the study of linear second-order ODEs. As a consequence, we will be able to concentrate our research activities on the symbolic treatment of nonlinear ODEs and inverse problems, as the main two motivating areas of the research group.

Author Contributions

Z.V. drafted the manuscript and conceived and performed the experiments. M.K., P.O. and Z.S. checked the test results and suggested the corrections. V.T. supervised the research and contributed to the organization of article. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

Not applicable.

Acknowledgments

The publication was granted by the Faculty of Engineering at University of Pécs, Hungary, within the framework of the ‘Call for Grant for Publication (2.0)’. The authors would like to thank the editors and the anonymous reviewers for their valuable comments that significantly improved the quality of this paper.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Regmi, R.P. Application of differential equation in L-R and C-R circuit analysis by classical method. Janapriya J. Interdiscip. Stud. 2017, 5, 114–123. [Google Scholar] [CrossRef] [Green Version]
  2. Tai-Ran, H. Applied Engineering Analysis; John Wiley and Sons Ltd.: Hoboken, NJ, USA, 2018; ISBN 1119071208. [Google Scholar]
  3. Simpson, M.J.; Lythe, G. (Eds.) Exact Solutions of Linear Reaction-Diffusion Processes on a Uniformly Growing Domain: Criteria for Successful Colonization. PLoS ONE 2015, 10, e0117949. [Google Scholar]
  4. Al-Gwaiz, M. Sturm-Liouville Theory and Its Applications; Springer: London, UK, 2008; ISBN 978-1-84628-972-9. [Google Scholar]
  5. Strang, G. Differential Equations and Linear Algebra; Wellesley-Cambridge Press: Cambridge, UK, 2015; ISBN 0980232791. [Google Scholar]
  6. LeVeque, R.J. Finite Difference Methods for Ordinary and Partial Differential Equations; Society for Industrial and Applied Mathematics: Philadelphia, PA, USA, 2007; ISBN 978-0-89871-629-0. [Google Scholar]
  7. Adison, H. Principles and Practice of Finite Volume Method; Clanrye International: New York, NY, USA, 2015; ISBN 978-1632404176. [Google Scholar]
  8. Sauter, S.; Schwab, C. Boundary Element Methods; Springer: Berlin/Heidelberg, Germany, 2010; ISBN 978-3-540-68093-2. [Google Scholar]
  9. Pepper, D.W.; Heinrich, J.C. The Finite Element Method; CRC Press: Boca Raton, FL, USA, 2017; ISBN 978-1498738606. [Google Scholar]
  10. Anulo, A.A. Numerical Solution of Linear Second Order Ordinary Differential Equations with Mixed Boundary Conditions by Galerkin Method. Math. Comput. Sci. 2017, 2, 66–78. [Google Scholar] [CrossRef] [Green Version]
  11. Cao, D. An Exponential Spline Difference Scheme for Solving a Class of Boundary Value Problems of Second-Order Ordinary Differential Equations. Discret. Dyn. Nat. Soc. 2020, 2020, 1–16. [Google Scholar] [CrossRef]
  12. Mamadu, J.E.; Njoseh, I.N. Tau-Collocation Approximation Approach for Solving First and Second Order Ordinary Differential Equations. J. Appl. Math. Phys. 2016, 4, 383–390. [Google Scholar] [CrossRef] [Green Version]
  13. Svantnerne Sebestyen, G.; Farago, I.; Horvath, R.; Kersner, R.; Klincsik, M. Stability of patterns and of constant steady states for a cross-diffusion system. J. Comput. Appl. Math. 2016, 293, 208–216. [Google Scholar] [CrossRef]
  14. Kersner, R.; Klincsik, M.; Zhanuzakova, D.T. A competition system with nonlinear cross-diffusion: Exact periodic patterns. Rev. Real Acad. Cienc. Exactas Fis. Nat. Ser. A. Mat. 2022, 116, 187. [Google Scholar] [CrossRef]
  15. Kaur, K.; Singh, G. An Efficient Non-Standard Numerical Scheme Coupled with a Compact Finite Difference Method to Solve the One-Dimensional Burgers’ Equation. Axioms 2023, 12, 593. [Google Scholar] [CrossRef]
  16. Vrabel, R. Lower and Upper Solution Method for Semilinear, Quasi-Linear and Quadratic Singularly Perturbed Neumann Boundary Value Problems. Axioms 2023, 12, 154. [Google Scholar] [CrossRef]
  17. Shukla, A.; Vedula, P. A hybrid classical-quantum algorithm for solution of nonlinear ordinary differential equations. Appl. Math. Comput. 2023, 442, 127708. [Google Scholar] [CrossRef]
  18. Sari, Z.; Klincsik, M.; Odry, P.; Tadic, V.; Toth, A.; Vizvari, Z. Lumped Element Method Based Conductivity Reconstruction Algorithm for Localization Using Symmetric Discrete Operators on Coarse Meshes. Symmetry 2023, 15, 1008. [Google Scholar] [CrossRef]
  19. Uhlmann, G. 30 Years of Calderón’s Problem, Seminaire Laurent Schwartz—EDP et Applications, Cellule MathDoc/CEDRAM, Séminaire Laurent Schwartz—EDP et Applications. 2012, pp. 1–25. Available online: http://eudml.org/doc/275764 (accessed on 24 June 2023).
  20. Bondarenko, N.P. Inverse Spectral Problems for Arbitrary-Order Differential Operators with Distribution Coefficients. Mathematics 2021, 9, 2989. [Google Scholar] [CrossRef]
  21. Argun, R.; Gorbachev, A.; Lukyanenko, D.; Shishlenin, M. On Some Features of the Numerical Solving of Coefficient Inverse Problems for an Equation of the Reaction-Diffusion-Advection-Type with Data on the Position of a Reaction Front. Mathematics 2021, 9, 2894. [Google Scholar] [CrossRef]
  22. Samarskii, A.A. The Theory of Difference Schemes; CRC Press: Boca Raton, FL, USA, 2001; ISBN 0-82470468-1. [Google Scholar]
  23. Delkhosh, M. The Conversion a Bessel’s Equation to a Self-Adjoint Equation and Applications. World Appl. Sci. J. 2011, 15, 1687–1691. [Google Scholar]
  24. Kiguradze, I.T.; Shekhter, B.L. Singular boundary-value problems for ordinary second-order differential equations. J. Sov. Math. 1988, 43, 2340–2417. [Google Scholar] [CrossRef]
  25. Kiguradze, T. On solvability and unique solvability of two-point singular boundary value problems. Nonlinear Anal. Theory Methods Appl. 2009, 71, 789–798. [Google Scholar] [CrossRef]
  26. Kiguradze, I.T.; Kiguradze, T.I. Conditions for the well-posedness of nonlocal problems for second-order linear differential equations. Differ. Equ. 2011, 47, 1414–1425. [Google Scholar] [CrossRef]
  27. Vizvari, Z.; Sari, Z.; Klincsik, M.; Odry, P. Exact schemes for second-order linear differential equations in self-adjoint cases. Adv. Differ. Equ. 2020, 2020, 497. [Google Scholar] [CrossRef]
Figure 1. Graphs of local green functions ψ 0 ( x ) , ψ 1 ( x ) , ψ 2 ( x ) , and ψ 3 ( x ) (with solid lines) and φ 1 ( x ) , φ 2 ( x ) , φ 3 ( x ) , and φ 4 ( x ) (with dotted lines) (defined in the Equation (31) using the partitioning in Equation (30)) on the interval [ 0 , 2 ] ( n = 3 ).
Figure 1. Graphs of local green functions ψ 0 ( x ) , ψ 1 ( x ) , ψ 2 ( x ) , and ψ 3 ( x ) (with solid lines) and φ 1 ( x ) , φ 2 ( x ) , φ 3 ( x ) , and φ 4 ( x ) (with dotted lines) (defined in the Equation (31) using the partitioning in Equation (30)) on the interval [ 0 , 2 ] ( n = 3 ).
Axioms 12 00633 g001
Figure 2. The results of the case study: u ( x ) is denoted with blue line, while u i , the result obtained in the i t h grid point, is denoted with black dots.
Figure 2. The results of the case study: u ( x ) is denoted with blue line, while u i , the result obtained in the i t h grid point, is denoted with black dots.
Axioms 12 00633 g002
Figure 3. Solving the case study with discontinuous κ ( x ) (in terms of Equations (26) and (27) and q ( x ) = 2 ) for different mesh resolutions ((a) n = 15 , (b) n = 50 , (c) n = 100 ).
Figure 3. Solving the case study with discontinuous κ ( x ) (in terms of Equations (26) and (27) and q ( x ) = 2 ) for different mesh resolutions ((a) n = 15 , (b) n = 50 , (c) n = 100 ).
Axioms 12 00633 g003
Figure 4. Graph of local green functions ψ 0 ( t ) and φ 1 ( t ) if a = 1 , b = 2 and m = 2 .
Figure 4. Graph of local green functions ψ 0 ( t ) and φ 1 ( t ) if a = 1 , b = 2 and m = 2 .
Axioms 12 00633 g004
Figure 5. The solution u 0 ( x ) (in Equation (44)) of the case study for a singular ODE with a piecewise source term ( m = 1 , 2 , 3 , 4 ).
Figure 5. The solution u 0 ( x ) (in Equation (44)) of the case study for a singular ODE with a piecewise source term ( m = 1 , 2 , 3 , 4 ).
Axioms 12 00633 g005
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Vizvari, Z.; Klincsik, M.; Odry, P.; Tadic, V.; Sari, Z. General Exact Schemes for Second-Order Linear Differential Equations Using the Concept of Local Green Functions. Axioms 2023, 12, 633. https://doi.org/10.3390/axioms12070633

AMA Style

Vizvari Z, Klincsik M, Odry P, Tadic V, Sari Z. General Exact Schemes for Second-Order Linear Differential Equations Using the Concept of Local Green Functions. Axioms. 2023; 12(7):633. https://doi.org/10.3390/axioms12070633

Chicago/Turabian Style

Vizvari, Zoltan, Mihaly Klincsik, Peter Odry, Vladimir Tadic, and Zoltan Sari. 2023. "General Exact Schemes for Second-Order Linear Differential Equations Using the Concept of Local Green Functions" Axioms 12, no. 7: 633. https://doi.org/10.3390/axioms12070633

APA Style

Vizvari, Z., Klincsik, M., Odry, P., Tadic, V., & Sari, Z. (2023). General Exact Schemes for Second-Order Linear Differential Equations Using the Concept of Local Green Functions. Axioms, 12(7), 633. https://doi.org/10.3390/axioms12070633

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop