Abstract

The main aim of this research article is to develop two new algorithms for handling linear and nonlinear third-order boundary value problems. For this purpose, a novel operational matrix of derivatives of certain nonsymmetric generalized Jacobi polynomials is established. The suggested algorithms are built on utilizing the Galerkin and collocation spectral methods. Moreover, the principle idea behind these algorithms is based on converting the boundary value problems governed by their boundary conditions into systems of linear or nonlinear algebraic equations which can be efficiently solved by suitable solvers. We support our algorithms by a careful investigation of the convergence analysis of the suggested nonsymmetric generalized Jacobi expansion. Some illustrative examples are given for the sake of indicating the high accuracy and efficiency of the two proposed algorithms.

1. Introduction

Spectral methods play prominent roles in various fields of applied science such as fluid dynamics. The main idea behind spectral methods is to approximate solutions of differential equations by means of truncated series of orthogonal polynomials, say, . The three popular techniques employed to determine the expansion coefficients are the collocation, tau, and Galerkin methods (see, e.g., [13]). The collocation approach requires the differential equation to be satisfied exactly at the selected collocation points. The tau method is a synonym for expanding the residual function as a series of orthogonal polynomials and then applying the boundary conditions as constraints. The Galerkin approach depends on combining the original basis functions into a new set in which all the functions satisfy the boundary conditions and then enforcing the residual to be orthogonal with the basis functions. The employment of Galerkin techniques is successfully applied on linear problems. For example, in the two papers [4, 5], the authors obtained numerical algorithms for solving high even- and high odd-order boundary value problems (BVPs) by applying the Galerkin and Petrov-Galerkin methods. Precisely, they constructed combinations of orthogonal polynomials satisfying the underlying boundary conditions on the given BVP, then applying the Galerkin method on even-order BVPs and a Petrov-Galerkin method on odd-order BVPs for the sake of converting each equation with its boundary conditions to a system of algebraic equations. The suggested algorithms in these articles are suitable for handling linear high-order BVPs. The application of Galerkin and Petrov-Galerkin methods on linear problems has a great advantage that their applications enable one to investigate carefully the resulting systems, especially their complexities and condition numbers.

Many practical problems in various fields of applied science are described by linear or nonlinear boundary value problems. The nonlinear BVPs arise frequently in many areas of science and engineering. Due to the great importance of high-order BVPs, there is an extensive work in literature in the numerical solutions of these problems. In particular, third-order BVPs are important in the area of physics and engineering. For example, some draining or coating fluid flow problems, in which surface tension forces are important, can be described by third-order BVPs. There are old and recent studies in third-order BVPs; for example, Huang and Sloan in [6] applied a pseudospectral for treating them, and Ma and Sun in [7] applied Chebyshev collocation method for handling these equations. Shen in [8] suggested some algorithms for third- and higher odd-order differential equations. Tirmizi et al. in [9] developed nonpolynomial splines solutions for special nonlinear third-order boundary-value problems. Bhrawy and Abd-Elhameed in [10] have suggested some numerical solutions of nonlinear third-order differential equations based on using Jacobi-Gauss collocation method. Moreover, Khan and Sultana in [11] used a parametric quintic spline solution for third-order BVPs. There are some other recent studies on high odd-order BVPs. For example, Abd-Elhameed et al. in [12] presented and implemented some algorithms for numerically solving the integrated forms of third- and fifth-order differential equations based on employing a dual Petrov-Galerkin method using two new families of general parameters generalized Jacobi polynomials. More recently, Abd-Elhameed et al. in [13] suggested two Legendre-dual-Petrov-Galerkin algorithms for solving the integrated forms of high odd-order BVPs, while Doha et al. in [14] have developed some algorithms for handling third- and fifth-order linear two point boundary value problems based on nonsymmetric generalized Jacobi Petrov-Galerkin method. We point out here that the algorithms in the two papers [13, 14] are capable of handling liner odd-order BVPs with constant coefficients.

It is well-known that the approach of employing operational matrices of differentiation and integration is considered as an important technique for solving many engineering and physical problems. This approach is characterized by its simplicity in application and its capability of handling both linear and nonlinear differential equations. There is a large number of articles in literature in this direction. To the best of our knowledge, all the used operational matrices for handling various types of differential equations are of tau type. For example, the authors in [15] employed the tau operational matrices of derivatives of Chebyshev polynomials of the second kind for handling the singular Lane-Emden type equations. Some other studies in [1618] employ tau operational matrices of derivatives for solving the same type of equations. Other kinds of differential equations were handled by the same technique (see, e.g., [1922]).

The main objective of this paper is to introduce a novel Galerkin operational matrix of derivatives of certain nonsymmetric generalized Jacobi polynomials and then employing it for solving both linear and nonlinear third-order BVPs based on the application of Galerkin and collocation methods.

The contents of the paper are organized as follows. Section 2 is devoted to presenting some preliminaries and relations which will be used throughout the paper. Section 3 is concerned with establishing a Galerkin operational matrix of derivatives of certain generalized Jacobi polynomials. Section 4 is concerned with implementing and presenting two new algorithms for solving linear and nonlinear third-order BVPs based on employing the two numerical methods, namely, generalized Jacobi-Galerkin operational matrix method (GJGOMM) for linear problems and the generalized Jacobi collocation operational matrix method (GJCOMM) for nonlinear problems. Also, in this section, the convergence analysis of the used nonsymmetric generalized Jacobi expansion is carefully investigated. Some numerical experiments including some discussions and comparisons are given in Section 5 aiming to illustrate the applicability and efficiency of the suggested algorithms. Finally, some conclusions are reported in Section 6.

2. Preliminaries

This section is concerned with presenting some definitions, properties, and relations which will be useful throughout this paper.

2.1. Shifted Legendre Polynomials

The shifted Legendre polynomials are a sequence of orthogonal polynomials defined on bywhere are the classical Legendre polynomials. They may be constructed by using the recurrence relationwith the initial values , , and they satisfy the following orthogonality relation on :

The polynomials are eigenfunctions of the following singular Sturm-Liouville equation:where . The following theorem is useful in the sequel.

Theorem 1 (see [13]). If the times repeated integration of is denoted by then and is a polynomial in of degree at most .

2.2. Shifted Nonsymmetric Generalized Jacobi Polynomials

First, we recall that the Jacobi polynomials , , and (see, for instance, Abramowitz and Stegun [23] and Andrews et al. [24]) are a sequence of polynomials satisfying the following orthogonality relation:and .

The shifted Jacobi polynomials on are defined by These polynomials are orthogonal on with respect to the weight function , in the sense thatLet . We denote by the weighted space with inner product:and the associated norm . Now, we extend the definition of shifted Jacobi polynomials to include the cases in which and/or . Explicitly, if we let (the set of all integers), then we defineIt should be noted here that this definition coincides with the definition introduced by Guo et al. [25] (for the case ). Moreover, an important property of the shifted generalized Jacobi polynomials (SGJPs) is that, for ,

3. Generalized Jacobi Galerkin Operational Matrix of Derivatives

In this section, a novel Galerkin operational matrix of derivatives will be established. For this purpose, we choose the following set of basis functions:It is easy to see that the set of polynomials is a linearly independent set. Moreover, these polynomials are orthogonal on with respect to the weight function , in the sense thatIt is not difficult to show that the polynomials can be expressed in terms of the shifted Legendre polynomials asNow, we define the space where is the sobolev space defined in [25].

Let be the space of all polynomials of degree less than or equal to , and set .

We observe that Now, if we assume , then it has the following expansion in terms of the polynomials aswhere The function in (18) can be approximated by the first terms aswhere Now, we are going to state and prove the main theorem of this paper, from which a novel Galerkin operational matrix will be introduced.

Theorem 2. If the polynomials are selected as in (13), then, for all , one haswhere is given by

Proof. To prove relation (22), it is sufficient to show that the following relation holds up to a constant:where Indeed, and the application of Theorem 1 (for ) on relation (15) enables one to write in the form and accordingly, the substitution of relation (27) into relation (26) leads to the relationwhere is given by Relation (28) can be written alternatively in the equivalent form whereAfter performing some straightforward but lengthy manipulations on the right hand side of relation (30), relation (24) can be obtained.

Now, and with the aid of Theorem 2, the first derivative of the vector defined in (21) can be expressed in the matrix form: where , and is an matrix whose nonzero elements can be given explicitly from relation (22) asFor example, for , the operational matrix is the following matrix:

Corollary 3. The second- and third-order derivatives of the vector are given, respectively, by

4. Solution of Third-Order Two-Point BVPs with Convergence Analysis

In this section, we are interested in developing two new algorithms for solving both linear and nonlinear third-order two-point BVPs. The introduced Galerkin operational matrix of derivatives is employed for this purpose. The linear equations are handled by the application of GJGOMM, while the nonlinear equations are handled by the application of GJCOMM.

4.1. Handling Linear Third-Order BVPs

Consider the linear third-order boundary value problemsubject to the homogenous boundary conditions Assume that is approximated as then with the aid of relations (32) and (35), the derivatives , , and can be approximated asIf we substitute the relations (38) and (39) into (36), then one can write the residual of this equation as The application of Galerkin method (see [26]) yields the following linear equations in the unknown expansion coefficients, , namely,and accordingly, a set of linear equations is generated. These equations can be solved for the unknown components of the vector , and hence the approximate spectral solution given in (38) can be obtained.

Remark 4. It should be noted that problem (36), governed by the nonhomogeneous boundary conditions can be easily transformed to a problem similar to (36) and (37) (see, [14]).

4.2. Handling Nonlinear Third-Order BVPs

Consider the following nonlinear third-order boundary value problem: governed by the homogenous boundary conditions If , , are approximated as in (38) and (39), then the following nonlinear equations in the unknown vector can be obtained:If the typical collocation method is applied on (45) by selecting the collocation points to be, for example, the roots of the nonsymmetric Jacobi polynomial , then a set of nonlinear equations can be generated in the expansion coefficients, . The solution of this system can be found by a suitable solver such as the well-known Newton’s iterative method, and hence the approximate solution can be obtained.

4.3. Convergence Analysis

In this section, we investigate the convergence analysis of the suggested expansion. Indeed, in the following, we state and prove a theorem in which the expansion in (18) of a function (the space defined in (16)) converges uniformly to , under the assumption that the second derivative of the function is bounded.

Theorem 5. A function , , with , can be expanded as an infinite sum of the basis given in (18). This series converges uniformly to . Moreover, the coefficients in (18) satisfy the inequality

Proof. If we start with (19), then one can writeand in virtue of (15), the coefficients may be written in the equivalent formIf the integrand in the last relation is integrated by parts twice, and making use of Theorem 1, (in case of ), then, for all , we have where is given bywhich can be written asand therefore the coefficients take the form Now, the substitution converts (52) into the form Taking into consideration the assumption , then we get With the aid of Bernstein type inequality (see [27]), it is easy to see thatand hence (54), with the application of the last inequality, leads to the estimationFinally, it is not difficult to show that, for all , the following inequality holds:and this completes the proof of the theorem.

5. Numerical Results and Discussions

In this section, the two presented algorithms in Section 4 are applied to solve both linear and nonlinear third-order boundary value problems. As expected, the accuracy increases as the number of terms of the basis expansion increases.

Example 1. Consider the following singulary perturbed linear third-order boundary value problem (see [28]):subject to the boundary conditions with the analytic solution .

In Table 1, the maximum absolute error is listed when GJGOMM is applied for various values of and . Moreover, Table 2 presents a comparison between the best absolute errors obtained by the application of GJGOMM in case of , with the best absolute errors obtained by using the method developed in [28]. This table shows that our algorithm is more accurate than the method developed in [28].

Example 2. Consider the following linear third-order boundary value problem (see [11, 29, 30]):subject to the boundary conditions with the analytic solution .

In Table 3, the maximum absolute errors resulting from the application of GJGOMM for various values of are displayed, while Table 4 displays a comparison between the best errors obtained by the application of GJGOMM with the best errors resulting from the application of the following methods:(i)sixth-order method (6OM) applied in [11];(ii)fourth-order methods (4OMs) applied in [11];(iii)second-order methods (2OMs) applied in [11];(iv)fourth degree B-spline functions applied in [29];(v)quintic splines method applied in [30].

Example 3. Consider the following nonlinear third-order boundary value problem (see [11, 29, 30]):subject to the boundary conditions with the analytic solution .

In Table 5, we list the maximum absolute errors using GJCOMM for various values of . In this table, we denote , and by the maximum absolute errors if the selected collocation points are, respectively, the zeros of the shifted Legnedre polynomial , the shifted Chebyshev polynomials of the first and second kinds and , and the shifted nonsymmetirc Jacobi polynomial . Moreover, Table 6 displays a comparison between the best errors obtained by the application of GJCOMM with the best errors resulting from the application of the methods mentioned in Example 2.

Remark 6. The numerical results displayed in Tables 4 and 6 clarify that the results obtained from the application of our two algorithms are more accurate than those obtained by all the previously mentioned algorithms.

6. Conclusions

This paper presents a novel operational matrix of derivatives of certain generalized Jacobi polynomials. Two algorithms based on employing the introduced operational matrix together with the application of the two spectral methods, namely, Galerkin and collocation methods, are analyzed for solving linear and nonlinear third-order boundary value problems. To the best of our knowledge, this is the first time a Galerkin operational matrix of derivatives is utilized for handling boundary value problems. The suggested algorithms in this paper are applicable and easy in implementation. Moreover, high accurate solutions are obtained by making use of the two proposed algorithms. The numerical results are convincing and the resulting approximate solutions are very close to the exact ones.

Conflict of Interests

The author declares that there is no conflict of interests regarding the publication of this paper.

Acknowledgments

This work was funded by the Deanship of Scientific Research (DSR), King Abdulaziz University, Jeddah, under Grant no. 130-268-D1435. The author, therefore, acknowledges with thanks DSR technical and financial support.