- Research
- Open access
- Published:

# Hybrid cubic and hyperbolic b-spline collocation methods for solving fractional Painlevé and Bagley-Torvik equations in the Conformable, Caputo and Caputo-Fabrizio fractional derivatives

*Boundary Value Problems*
**volume 2024**, Article number: 27 (2024)

## Abstract

In this paper, we approximate the solution of fractional Painlevé and Bagley-Torvik equations in the Conformable (Co), Caputo (C), and Caputo-Fabrizio (CF) fractional derivatives using hybrid hyperbolic and cubic B-spline collocation methods, which is an extension of the third-degree B-spline function with more smoothness. The hybrid B-spline function is flexible and produces a system of band matrices that can be solved with little computational effort. In this method, three parameters *m*, *η*, and *λ* play an important role in producing accurate results. The proposed methods reduce to the system of linear or nonlinear algebraic equations. The stability and convergence analysis of the methods have been discussed. The numerical examples are presented to illustrate the applications of the methods and compare the computed results with those obtained using other methods.

## 1 Introduction

Studying fractional calculus is an old topic that goes back to Leibniz (1695) and Euler (1730) [1–3]. The analysis of noninteger derivatives and integrals offers an excellent method to explain the memory and inherited properties of complex systems. Several existing arbitrary-order derivatives in fractional calculus are typically classified into singular and nonsingular [4–8]. A new effective description of the nonsingular kernel was applied in [8–14].

In general, an analytical solution of the fractional differential equation is difficult. Consequently, the Painlevé and Bagley-Torvik equations do not always have solutions in closed forms that can be obtained by analytical approaches. Numerical methods to find an approximate solution and qualitative behaviors of the solution for fractional differential equation have been investigated in [15–33] and some references therein.

In recent years, the search for numerical methods for approximating the solution to fractional equations has become a topic of interest in applied sciences and engineering. Several mathematicians have recently developed numerical methods for approximating solutions to fractional differential equations involving Caputo-Fabrizio derivatives see [11, 13, 14], and [16].

The B-spline interpolator function is considered one of the most effective methods for interpolating smooth functions, especially compared to other techniques, such as finite element, finite volume, and finite difference methods [14, 34–37]. We also know that the non-polynomial spline function has certain advantages over the polynomial spline function due to its increased smoothness and parameter dependence, leading to improved approximation of solutions see [26, 33, 38–40], and the references therein.

If the solution of the differential equation is an exponential function, then the exponential B-spline interpolator function provides a better approximation compared to the polynomial B-spline function. The advantage of using the hybrid B-spline is that it has three free parameters, *λ*, *m*, and *κ*, that can be determined so that the numerical method produces results with better accuracy. The main reason for writing this article is to create a B-spline function that is a combination of third-order B-spline and hyperbolic B-spline function to approximate the solutions of Painlevé and Bagley-Torvik equations in the Conformable, Captuo, and Caputo-Fabrizio fractional derivative. It also studies of convergence and stability of the numerical method.

We consider the Bagley-Torvik equation in the following form:

where \(\alpha =1.5\), \(\beta =0.5\), and fractional Painlevé of the first type as:

and also Painlevé fractional differential equation of the second type as follows:

where, \(_{x}D_{0}^{\alpha}\) and \(_{x}D_{0}^{\beta}\) are one of the derivatives of Conformable or Caputo or Caputo-Fabrizio also \(x\in [0,1]\), \(\alpha \in (1,2]\), and \(\beta \in (0,1]\). The functions of \(\eta _{i}(x), {i=1,2,3,4,5}\), and \(f(x)\in C([0,1])\) are continuous, and the function \(u(x)\) is also the solution that must be approximated. The fractional Bagley-Torvik equation with derivatives of order 0.5 or 1.5 determines the movement of real physical structures, a plate immersed in gas in fluid together with a Newtonian fluid, simultaneously [18] and [41]. In mathematical physics, such as statistical mechanics, plasma physics, nonlinear waves, quantum gravity, quantum field theory, general relativity, nonlinear optics, and fiber optics, the Painlevé fractional differential equation appears in [19] and [20]. Some of the physical phenomena experienced by physical laboratories do not always have solutions in closed forms, e.g, the fractional Bagley-Torvik and Painleveé equations.

The cubic B-spline function for approximating the solution of Painlevé and Bagley-Torvik equations in the Captuo, Caputo-Fabrizio, and Conformable fractional sense concerning boundary set conditions has been studied in [14], but the convergence of the given numerical method has not been discussed. Several good papers [28, 29, 33] have used spline approximation methods to approximate the solution of fractional Bagley-Torvik equation.

In [21], the reproducing kernel space method for approximating the solution of Bagley-Trovick fractional differential equation is analyzed. A hybrid of block-pulse functions and Chebyshev polynomials based on operational matrices for approximating the solution of fractional differential equations has been studied and analyzed in [42].

The existence of positive and negative solutions of the Bagley-Torvik fractional differential equation and the derivative properties of these solutions have been studied in [22]. The Taylor matrix method for approximating the solution of Bagley-Trovick equation in fluid mechanics is developed in [31]. Cubic spline method for approximating the solution of fractional boundary value problems has been developed in [26]. The Chebyshev collocation method for approximating the solution of fractional Bagley-Torvik equation is introduced in [23].

In [24], the homotopy perturbation method was applied for approximating the solution of Bagley-Torvik equation as a prototype fractional differential equation with two derivatives. The exponential integrators method for numerical solution of the Bagley-Torvik equation was discussed in [30].

The Adomian decomposition method for solving initial value problem of Bagley-Torvik equation is also discussed in [32]. Fractional linear multistep method and a predictor-corrector method of the Adams type, which was based on finite difference methods for initial value problem of the Bagley-Torvik equation, are discussed in [27]. The Legendre operational matrix method for fractional differential equation is applied in [43], and the combination of collocation points and first-order Bessel functions, which is called the Bessel-collocation method for boundary value problem of Bagley-Torvik equation, is discussed in [25]. Recently, some numerical methods have been employed for approximating the solutions of the fractional two-point boundary value problems in both linear and nonlinear types, for example, the cubic B-spline interpolation method [34], the cubic B-spline method, the finite difference technique [35], the B-spline collocation method for solving conformable initial value problems of nonsingular and singular types [36], and well-posedness and numerical simulations employing Legendre-shifted spectral approach for Caputo-Fabrizio fractional stochastic integro differential equations [13]. The solvability of a nonlocal problem with integral transmitting condition for mixed type equation with the Caputo fractional derivative [44] and an extended Caputo fractional derivative operator with its applications [45] are also discussed. An approximate analytic view of physical and biological models in the setting of the Caputo operator via the Elzaki transform decomposition method is shown in [46].

In [15] and [16], iterative reproducing kernel and spline functions have been used to study and develop Bagley-Torvik and Painlevé equations with fractional order.

Many approaches have been developed for solving the fractional differential equations. These methods include: solutions of variable-order fractional differential equations by reproducing the kernel method [47], numerical solutions of fractional differential equations of the Lane-Emden type by reproducing the kernel Hilbert space [48], the reproducing kernel method for approximate solutions of fractional order boundary value problems [49], a collocation shooting method [50], implicit finite difference approximation for time-fractional diffusion equations [51], fractional model and numerical algorithms for predicting COVID-19 with isolation and quarantine strategies [52], Sinc approximation for the numerical solution of a nonlinear fractional pantograph equation [53], matrix approach to discrete fractional calculus [54], and the weighted and shifted Grünwald difference operators [55].

The main objective of this study is to utilize a hybrid of hyperbolic and cubic B-spline functions to solve equations (1)-(3), which results are more accurate compared with some other methods. The first aim of the present work is to explore the cubic hyperbolic B-spline interpolation with multiple parameters and produce the error of approximate hyperbolic spline. The second aim is to introduce a new approximate technique to find solutions of fractional boundary value problem and demonstrate the convergence analysis for this technique. Also, the main advantage of our algorithm is that it can be used directly without using assumption or transformation formulae. The solutions can be obtained with high accuracy compared with other numerical techniques. Also, the proposed method is easy to implement.

This paper consists of four sections. In Sect. 2, we describe basic definitions and the hybrid B-spline. The solutions of fractional Painlevé and Bagley-Torvik equations are approximated using the hybrid B-spline in Sect. 3. Stability and convergence analysis is proved in Sect. 4. In Sect. 5, the numerical examples are given to illustrate the applications of the method, and the computed results are also compared with another known method described in [14, 30, 54].

## 2 Basic definitions and description of the methods

In this section, we recall some definitions and properties of the fractional calculus theory used in this paper. There are several definitions of a fractional derivative of order \(\alpha >0\), such as Riemann-Liouville, Grünwald-Letnikove, Caputo, Conformable, and Caputo-Fabrizio fractional derivatives. In the present work, Caputo, Caputo-Fabrizio, and Conformable fractional derivatives are used for formulating the problem. All these details have been quoted in References [1–19] and [33–36].

The Sobolev space of one-order on (a, b) is defined as follows:

where the \(L^{2}(a,b)\) is the square-integrable functions on \((a, b) \).

Here, we give some required definitions and properties of the fractional derivative and the B-spline function.

### Definition 1

Let \(u(x)\) be a function defined on \((a,b)\), then the Riemann-Liouville fractional derivative has the following form

where \(\Gamma (\cdot)\) is the gamma function.

### Definition 2

The right and left Riemann-Liouville fractional integrals

### Definition 3

Let \(u(x)\) be a function defined on \((a,b)\), then the Caputo fractional derivative has the following form

### Definition 4

The Grünwald definition for the fractional derivative is defined in the following form:

where \(A^{\alpha}_{h,p} (u(x))=^{R}_{x}D_{a}^{\alpha }(u(x))+O(h) \), and \(g_{\alpha ,k}= \frac{\Gamma (k-\alpha )}{\Gamma (-\alpha )\Gamma (k+1)}\).

### Definition 5

The weighted and shifted Grünwald difference operator is as follows.

Let \(u(x)\in L^{1}(R), _{\infty}\!D^{ \alpha +2}_{x} (u(x))\), and its Fourier transform belongs to \(L^{1}(R)\),

where \(x\in R\), \(\vartheta \in [0,1] \), also *p*, and \(q, (p\neq q)\) are integers and symmetric.

### Definition 6

Let \(u(x)\in H^{1}(a,b)\), \(\alpha \in (m-1,m]\), \(m\in N\) and \(\alpha \geq 0\), then the Caputo-Fabrizio fractional derivative of order *α* is written as:

### Definition 7

If \(u(x)\) is *m*-differentiable for all \(x\geq a> 0\), then the Conformable fractional derivative with order *α* is

indeed,

and the Conformable fractional integral is the following

where \(0<\alpha \leq 1\), and \(\lceil \alpha \rceil \) is the smallest integer greater than or equal to *α*.

Let us consider a mesh with nodal points \(x_{i}\) on \([a,b]\) such that:

where \(h=\frac{b-a}{n}\), \(x_{i}=a+ih\), for \(i=0(1)n\). Suppose

is a sequence of knots on *R*. Zero-order B-splines are piecewise constants defined by:

and polynomial B-splines of order \(k\geq 1 \) are defined recursively in the following form:

The hyperbolic B-splines are defined by:

generally, for \(k\geq 1 \),

where, *m* and *η* are the positive real numbers, and a hybrid cubic B-spline basis function is also established using a linear combination of the cubic B-spline basis function and hyperbolic cubic B-spline basis as follows:

hither, the parameter \(\lambda \in R \) is a free parameter to control the global shape of curve. The hybrid B-spline basis function reduces to cubic hyperbolic B-spline and cubic B-spline function when \(\lambda =0 \) and 1, respectively. The finite difference approach yields the solution only at the selected points, but the spline function has the flexibility to get the approximation at any point in the domain with more accurate results compared to the usual finite difference method. The advantage of using hybrid B-spline is the free parameters that play an important role in the implementation of the method and also affect the results to be obtained up to a desired level of accuracy. An appropriate choice of the parameter rises the order of accuracy of the scheme. Suppose the estimate solution \(S(x)\) to the exact solution \(u(x)\) at point \(x_{i}\), respectively, is defined as:

here, \(T_{i}^{3}(x)\) are hybrid cubic B-spline basis functions, and \(C_{i}\) are unknown real coefficients. The values of \(T_{i}^{3}(x)\) and its derivatives \(T_{i}^{\prime \,3}(x)\), \(T_{i}^{\prime \prime \,3}(x) \) at the nodal points can be simplified as:

where

## 3 Hybrid B-spline solution for fractional Bagley-Torvik and Painlevé equations

### 3.1 Bagley-Torvik equation regarding Conformable fractional derivative approach

Now, we are ready to start the implementation of our method using the properties of Conformable fractional derivative and Hybrid cubic B-spline functions. Let \(u(x)\) be the analytical and \(\overline{u}(x)\) be the numerical solutions for Painlevé and Bagley-Torvik equations. The value of \(u''(x)\), \(^{Co}_{x}D_{0}^{\frac{3}{2}}u(x)\), \(u'(x)\), \(_{x}D_{0}^{ \frac{1}{2}}u(x)\), \(u(x)\), approximate at \(x=x_{i}\) where \(i=0,1,\ldots,n\), as follows

To obtain the approximate solution (1) with boundary conditions by putting (17) in (1), we use the following system for \(i=0,1,\ldots,n\),:

and the boundary conditions as:

this system can be written in the following matrix-vector form:

where,

also, since *A* is strictly diagonally dominant [37], to find the values of \(C_{-1}, C_{0}, \ldots, C_{n+1}\) in vector *X*, we can solve the system of equations (22) as follows:

The numerical solution can be calculated after substituting the values of *λ* and \(C_{i}, \text{for } i=-1,0,1,\ldots,n,n+1\), in equation (17).

### 3.2 Painlevé equations regarding Conformable fractional derivative approach

In this portion, we consider equations (2) and (3) regarding the Conformable approach. Substituting the values of (17) in equations (2) and (3) of Painlevé equations at \(x_{i}\), we get:

and

equations (25) and (26) construct nonlinear systems, which can be solved by Newton’s iteration method. We also used the software Mathematica 9.0 to obtain the numerical solutions.

## 4 Stability and convergence analysis

System (22) obtained using the hybrid cubic hyperbolic B-spline and cubic B-spline functions cannot be solved exactly. However, we can calculate the solutions that are close to the exact solution when small errors are introduced into the input functions. Specifically, we need to prove that the difference between these solutions always depends on the coefficients of the linear system; that means, the method is stable. Let *δA* and *δB* be small perturbations in *A* and *B*. Let *ϕ* be the solution to the system

also let *A* be nonsingular and \(\|\delta A\|<\frac{1}{2\|A^{-1}\|}\), then \(A+\delta A\) is nonsingular and

and we know that *A* is strictly diagonally dominant and also

It implies that

This shows the stability of the system (the norm used is infinite norm).

Let \(u(x)\) be the exact solution of (1)-(3) and \(S(x_{i})= S_{i}\) be an approximation to \(u_{i} = u(x_{i})\) obtained by the hybrid b-spline function \(S_{i}(x) \in C^{\infty}[a,b]\), by algebraic manipulation of relations (17) and (18), when \(\lambda =0\), we get the consistency relations between the spline approximation and its derivatives at the nodal points in the following form:

### Lemma 1

*The local truncation errors* \(x_{i}\) *associated with the equation* (34) *for* \(i=1,\ldots,n-1\). *are given by*

### Proof

See [40]. □

### 4.1 The hybrid B-spline method for fractional Painlevé and Bagley-Trovik equations in the Caputo fractional sense

Substitute the numerical point solution of Bagley-Trovik equation at \(x=x_{i}\), where \(i=0,1,\ldots,n\), is as follows

Considering each subinterval \([x_{j-1},x_{j}]\) of partition \([0,x_{i}]\), for \(t\in [x_{j-1},x_{j}]\) and using the properties of the Caputo fractional derivative and Hybrid cubic B-spline functions for \(1< \alpha <2\) gives

and for \(0< \beta <1\), we also get

Using equation (17) and Lemma 1, we obtain the following relation

since \((x_{i}-t)^{1-\alpha}\) does not change sign on \([(j-1)h, jh]\), using the weighted mean value theorem to establish an integral formula and applying to each integration of the last summation, we get

where \(\overline{\eta}\in [(j-1)h, jh]\). After simple calculations, equations (40) and (41) become

Following the same technique on \(0< \beta <1\), we get

To shorten a little the size of this section, we will omit truncation error here to approximate the Painlevé and Bagley-Trovik regarding the Caputo fractional sense. Anyhow, substituting (42) and (43) in (37) at \(i=0,1,2,\ldots,n\), where the attached linear or nonlinear systems are obtained as follows:

Hither, substituting (42) in fractional Painlevé of the (I) and (II), we have the following nonlinear systems

and

for \(i=0,1,2,\ldots,n\).

Relations (45) and (46) become nonlinear systems in the following form as:

Anyhow, in the general case, we have the following nonlinear systems

By the end of this subsection, we can obtain the approximate solutions by solving the linear system or nonlinear system (48), and also to solve it, we use the Newton method or the Mathematica command like (FindRoot).

### 4.2 Bagley-Torvik and Painlevé equations regarding Caputo-Fabrizio fractional derivative approach

Using the Caputo-Fabrizio fractional derivative for \(1< \alpha <2\) and considering each subinterval \([x_{j-1},x_{j}]\) of partition \([0,x_{i}]\), for \(t\in [x_{j-1},x_{j}]\), we get

and also for \(0< \beta <1\), we get

Finally, we approximate the exact solution (1)-(3) by the hybrid B-spline function as:

However, the above systems with boundary conditions (21) convert to the following nonlinear system with \(n+3\) equations and \(n+3\) unknowns

for \(i=0,1,2,\ldots,n\).

### 4.3 Convergence analysis

In this section, we discuss the convergence analysis of hybrid cubic and hyperbolic B-spline. Let \(u(x)\) be the exact solution of the problem and \(S(x)\in C^{\infty}[0,T]\) be the hybrid B-spline approximation to \(u(x)\) satisfying in \(S(x_{i})=u(x_{i})\), \(i=0,1,\ldots,n-1\). We should approximate the error \(\|u(x)-S(x)\|\). Let us assume that \(\hat{S}(x)\) is the computed hybrid B-spline approximation to \(S(x)\). To estimate \(\|u(x)-S(x)\|\), we will estimate \(\|u(x)-\hat{S}(x)\|\) and \(\|\hat{S}(x)-S(x)\|\) separately.

First, we consider the Painlevé equations with the Conformable derivative and then discretize it with the hybrid B-spline function as follows:

By discretizing the Bagley-Torvik equation with the Conformable derivative, the following linear system is obtained.

We investigate the convergence analysis for the conformable fractional derivative and also for Caputo and Caputo-Fabrizio fractional derivatives that are similar.

We also obtain a linear or nonlinear system of equations, the convergence of which we analyzed on the nonlinear system. In general, we have the following system:

By substituting (17) in (58) at \(x_{i}, i=0,1,2,\ldots,n\), the attached nonlinear system of order \((n+3)\) is obtained as:

Equations (59) construct a nonlinear system, which can be solved by Newton’s iteration method.

### Lemma 2

*Let* \(\hat{S}(x)\) *be the unique spline interpolation to* \(S(x)\), *and also suppose that partial derivatives of* *F* *exist and* \(|\frac{\partial F}{\partial u}|\leq k_{1}\), \(|\frac{\partial F}{\partial u'}|\leq k_{2}\), \(| \frac{\partial F}{\partial u''}|\leq k_{3}\), *for some constants* \(k_{1}\), \(k_{2}\) *and* \(k_{3}\). *Then for* \(0 \leq i \leq n\), *we have*:

### Proof

For \(0\leq i\leq n\), we get

Now using the mean value theorem for there parts of the above relation there exist \(\xi _{i}\), \(\varsigma _{i}\) and \(\nu _{i}\) such that

using Theorem 1 in [14], (42)-(43), and Lemma 1, one obtained:

the maximum truncation error for approximations is \(O(h^{2})\). From [56], we have \(|S(x_{i})-\hat{S}(x_{i})|\equiv O(h^{4})\), \(|S'(x_{i})-\hat{S}'(x_{i})| \equiv O(h^{3})\), \(|S''(x_{i})-\hat{S}''(x_{i})|\equiv O(h^{2})\), and taking the absolute value of the above relationship, we get

□

### Theorem 1

*Let* \(u(x)\in C^{\infty}[0,T]\) *be the exact solution* (1)-(3) *and* \(S(x)\) *be the hyperbolic B*-*spline approximation to* \(u(x)\), *then we have*

### Proof

Since \(\hat{S}(x)\) is an interpolation to \(u(x)\), there is a finite constant \(\varrho _{1}\) independent of *h* that we get

now using the triangular inequality and Lemma 1, we can obtain the following results

□

## 5 Numerical results

In this section, we have implemented our methods for solving some of the Bagley-Torvik and Painlevé fractional differential equations with different values of *λ*, *m*, *η*, *h*, and *α*. We have obtained linear or nonlinear algebraic systems, and to solve it, we can employ Mathematica command like “FindRoot”. The findroot command depends on the initial guess of the interval that contains the value of the unknowns, which can be obtained from boundary conditions or other methods such as a Bisection method. The maximum absolute errors in solutions of the methods are tabulated in tables, and one can compare them with the methods described in [14, 30, 54]. The convergence order (C.O.) is obtained by

where \(E(h)\) is the maximum absolute error. Numerical results derived by the proposed method and *MATHEMATICA 9* solver are seen in tables and graphs.

### Example 1

Consider the following Bagley-Torvik fractional boundary value problem in Caputo approach:

The exact solution is given by \(u(x)=x^{\gamma}\). The maximum absolute errors are compared with the methods described in [30] and [54]. To compare the numerical results with [30] and [54], we have taken \(n = 8,16,32,64,128,256,512\), \(\lambda =0,5,0.6,0.9\), and \(\gamma =3,4\) in Tables 1 and 2. The convergence order of Example 1 for \(n=10\), \(\lambda =0,5,0.6\), is compared with order 2 in Fig. 1.

### Example 2

Consider the Bagley-Torvik fractional equation in Caputo, Conformable, and Caputo-Fabrizio approaches:

The Bagley-Torvik equation in the Caputo approach:

The Bagley-Torvik equation in the Caputo-Fabrizio approach:

The Bagley-Torvik equation in the Conformable approach:

The exact solution is given by \(u(x)=x^{3}\). The absolute errors of \(x_{i}\) with \(h=\frac{1}{10}\) are compared with the methods from [14] in Table 3. The relative errors of our method for \(n = 10\), \(\lambda =0,5\), \(m=1\), and \(\eta =1\) with method in [14] are plotted in Fig. 2.

### Example 3

Consider the Painlevé fractional equation in Caputo, Conformable, and Caputo-Fabrizio approaches:

The exact solution is given by \(u(x)=\alpha \cos (\pi x)\). The absolute errors for \(h=\frac{1}{10}\), \(\lambda =0\), \(m=1\), \(\eta =1\), \(\alpha =1.5,1.6,1.7,1.8,1.9\) are compared with the methods from [14] in Tables 4 and 5. The convergence orders (C.O.) with \(n=4,8,16,32,64,128,256,512,1024\), and \(\alpha =1.1,1.6,1.9\) are displayed in Table 6. The graphs of numerical solutions regarding the Caputo-Fabrizio approach with different values of \(\alpha =1.2,1.4,1.6,1.8\), \(\lambda =0.5\), \(m=1\), and \(\eta =1\), are plotted in Fig. 3.

### Example 4

Consider the Painlevé fractional equation in Caputo, Conformable and Caputo-Fabrizio approaches:

The exact solution is given by \(u(x)=2x^{3}-3x^{2}+x+\alpha \). The absolute errors with different values \(\alpha =1.5,1.9\), \(\lambda =1\), \(\eta =1\), \(m=1\) and \(h=\frac{1}{10}\) are compared with the method [14] in Table 7.

The graphs of numerical solutions regarding Caputo approach with different value of \(\alpha =1.1,1.3,1.5,1.7,1.9\), \(\lambda =0.5\), \(m=1\), \(\eta =1\), and \(h=\frac{1}{20}\), are plotted in Fig. 4.

Here, the algorithm of the hybrid B-spline method for Example 2 is given with the Conformable derivative, and the algorithm is written similarly for other derivatives such as Caputo and Caputo-Fabrizio approaches.

### Algorithm 1

Approximate solutions of equation (66) with Conformable approach using the hybrid B-spline function.

ClearAll

In[1]: \(\omega _{1}=0;\omega _{2}=1;\eta _{1}(x)=1;\eta _{2}(x)=1;\eta _{3}(x)=1; \eta _{4}(x)=1;\eta _{5}(x)=1;\lambda =0.5;\eta =1;m=1\);

In[2]: \(u(x)=x^{3};f(x)=6x+6x^{\frac{3}{2}}+3x^{2}+x^{3}+3x^{\frac{5}{2}}\);

In[3]: Define the Conformable fractional derivative \(^{Co}_{x}D_{a}^{\alpha }(u(x))\) using equation (10).

In[4]: Define the hybrid cubic B-spline basis functions \(T_{i}^{3}(x)\). using equations (12)-(16).

In[5]: \(\overline{u}(x) =\sum_{i=-1}^{n+1}C_{i}T_{i}^{3}(x) \).

In[6]: \(\text{Do}[x_{i}=i*h; \text{equations}_{i} =\overline{u}''(x_{i})+^{Co}_{x}D_{0}^{ \frac{3}{2}}\overline{u}(x_{i})+\overline{u}'(x_{i}) +^{Co}_{x}D_{0}^{ \frac{1}{2}}\overline{u}(x_{i})+\overline{u}(x_{i})-f(x_{i})==0,\{i=0,n \}]\);

In[7]: \(\text{boundary1}=\sum_{i=-1}^{n+1}C_{i}T_{i}^{3'}(0)==0\);

Out[7]: \(-5C_{-1}+5C_{1}==0\);

In[8]: \(\text{boundary2}=\sum_{i=-1}^{n+1}C_{i}T_{i}^{3}(1)==1\);

Out[8]: \(\frac{1}{6}(C_{-1}+4C_{0}+C_{1})==1\);

(^{∗}Approximate solutions are obtained using the hybrid B-spline function by solving the system of 13 equations and 13 unknowns with the help of Mathematica version 9 software.^{∗})

In[9]: Solutions=Solve[\(\{\text{boundary1},\text{equations}_{0}, \text{equations}_{1},\ldots,\text{equations}_{10},\text{boundary2}\}\), \(\{C_{-1},C_{0},\ldots,C_{10},C_{11}\}\)];

Out[9]: \(-9.5894539103510313295\times 10^{-21}\), \(-9.6375615386799582263\times 10^{-21}\), \(-9.5894539103510313295\times 10^{-21}\), 0.0059999999999999999908, 0.023999999999999999991, 0.059999999999999999992, 0.11999999999999999999, 0.20999999999999999999, 0.33600000000000000000, 0.50400000000000000000, 0.72000000000000000000, 0.99000000000000000000.

(^{∗}Approximate solutions \(\overline{u}(x)\) are obtained^{∗})

End.

## 6 Conclusion

Computational methods for solving the fractional Bagley-Torvik and Painlevé equations were proposed with the conformable, Captuo, and Caputo-Fabrizio fractional sense concerning boundary set conditions. The fractional differential equation term in the fractional Painlevé and Bagley-Torvik equations were discretized using the hybrid B-spline function. The first aim of the paper is to illuminate that the hybrid B-spline is a solver for several appointed forms without using any transformation or limiting assumptions. This algorithm is implemented straightforwardly. Second, this method is a simple method to apply and includes some parameters, such as *m*, *η*, and *λ*, which increase the accuracy of the method. Third, it could be applied to other types of linear and nonlinear or singular and regular fractional problems. The novel approaches are applied to approximate the outcomes for fractional-order and integral-order problems. The obtained results show that the method used to approximate the solution of various problems of partial differential equations and integral equations in the light of fractional derivative is effective and appropriate. The feasibility of the numerical algorithm was illustrated with four examples, and the approximated results were compared with the methods in [14, 30, 54].

## Availability of data and materials

Not applicable.

## References

Oldham, K.B., Spanier, J.: The Fractional Calculus. Academic Press, New York (1974)

Podlubny, I.: Fractional Differential Equations. Academic Press, New York (1990)

Kilbas, A.A., Srivastava Hari, M., Trujillo, J.J.: Theory and Applications of Fractional Differential Equations, 1st edn. North-Holland Mathematics Studies, vol. 204. Elsevier (2006)

de Oliveira, E.C., Tenreiro Machado, J.A.: A review of definitions for fractional derivatives and integral. Math. Probl. Eng.

**2014**, e238459 (2014)Atangana, A.: On the new fractional derivative and application to nonlinear Fisher’s reaction-diffusion equation. Appl. Math. Comput.

**273**, 948–956 (2016)Chen, Z., Qiu, P., Yang, X.-J., Feng, Y., Liu, J.: A new fractional derivative model for the anomalous diffusion problem. Therm. Sci.

**23**, 1005–1011 (2019)Khalil, R., Al Horani, M., Yousef, A., Sababheh, M.: A new definition of fractional derivative. J. Comput. Appl. Math.

**264**, 65–70 (2014)Caputo, M., Fabrizio, M.: A new definition of fractional derivative without singular kernel. Prog. Fract. Differ. Appl.

**1**, 73–85 (2015)Losada, J., Nieto, J., Arabia, S.: Properties of a new fractional derivative without singular kernel. Prog. Fract. Differ. Appl.

**1**, 87–92 (2015)Atangana, A., Gómez-Aguilar, J.F.: A new derivative with normal distribution kernel: theory, methods and applications. Physica A

**476**, 1–14 (2017)Ali Dokuyucu, M., Celik, E., Bulut, H., Baskonus, H.M.: Cancer treatment model with the Caputo-Fabrizio fractional derivative. Eur. Phys. J. Plus

**133**, 92 (2018)Gómez-Aguilar, J., Yépez-Martínez, H., Torres-Jiménez, J., Córdova-Fraga, T., Escobar-Jiménez, R., Olivares-Peregrino, V., Homotopy perturbation transform method for nonlinear differential equations involving to fractional operator with exponential kernel. Adv. Differ. Equ. 2017, 68. https://doi.org/10.1186/s13662-017-1120-7

Badawi, H., Abu Arqub, O., Shawagfeh, N.: Well-posedness and numerical simulations employing Legendre-shifted spectral approach for Caputo-Fabrizio fractional stochastic integro differential equations. Int. J. Mod. Phys. C

**34**(6), 2350070 (2023)Shi, L., Tayebi, S., Arqub, O.A., Osman, M.S., Agarwal, P., Mahamoud, W., Abdel-Aty, M., Alhodaly, M.: The novel cubic B-spline method for fractional Painlevé and Bagley-Trovik equations in the Caputo, Caputo-Fabrizio, and conformable fractional sense. Alex. Eng. J.

**65**, 413–426 (2022)Abu Arqub, O., Maayah, B.: Solutions of Bagley-Torvik and Painlevé equations of fractional order using iterative reproducing kernel algorithm with error estimates. Neural Comput. Appl.

**29**, 1465–1479 (2018). https://doi.org/10.1007/s00521-016-2484-4Abu Arqub, O., Ben Rabah, A., Sh, M.: A spline construction scheme for numerically solving fractional Bagley-Torvik and Painlevé models correlating initial value problems concerning the Caputo Fabrizio derivative approach. Int. J. Mod. Phys. C

**34**, 2350115 (2023). https://doi.org/10.1142/S0129183123501152Bagley, R.L., Torvik, P.J.: Fractional calculus-a different approach to the analysis of viscoelastically damped structures. AIAA J.

**21**, 741–748 (1983)Abu Arqub, O., Maayah, B.: Solutions of Bagley-Torvik and Painlevé equations of fractional order using iterative reproducing kernel algorithm with error estimates. Neural Comput. Appl.

**29**, 1465–1479 (2018)Raja, M.A.Z., Shah, Z., Manzar, M., Iftikhar, A., Awais, M., Baleanu, D.: A new stochastic computing paradigm for nonlinear Painlevé II systems in applications of random matrix theory. Eur. Phys. J. Plus

**133**, 254 (2018)Iwaki, K., Marchal, O., Saenz, A.: Painlevé equations, topological type property and reconstruction by the topological recursion. J. Geom. Phys.

**124**, 16–54 (2018)Sakar, M.G., Saldir, O., Akgül, A.: A novel technique for fractional Bagley-Torvik equation. Proc. Natl. Acad. Sci. India Sect. A Phys. Sci.

**89**, 539–545 (2019). https://doi.org/10.1007/s40010-018-0488-4Staněk, S.: Two-point boundary value problems for the generalized Bagley-Torvik fractional differential equation. Cent. Eur. J. Math.

**11**(3), 574–593 (2013)Saw, V., Kumar, S.: Numerical scheme for solving two point fractional Bagley-Torvik equation using Chebyshev collocation method. WSEAS Trans. Syst.

**17**, 166–177 (2018)Sayevand, K., Mirzaee, F.: A unique continuous solution for the Bagley-Torvik equation. Casp. J. Math. Sci.

**1**(1), 47–51 (2012)Yüzbaş, Ş.: Numerical solution of the Bagley-Torvik equation by the Bessel collocation method. Math. Methods Appl. Sci.

**36**, 300–312 (2013)Zahra, W.K., Elkholy, S.M.: Cubic spline solution of fractional Bagley-Torvik equation. Electron. J. Math. Anal. Appl.

**1**(2), 230–241 (2013)Diethelm, K., Ford, J.: Numerical solution of the Bagley-Torvik equation. BIT Numer. Math.

**42**, 490–507 (2002)Ding, Q., Wong, P.J.Y.: A higher order numerical scheme for solving fractional Bagley-Torvik equation. Math. Methods Appl. Sci.

**45**(3), 1241–1258 (2022). https://doi.org/10.1002/mma.7849Ding, Q., Wong, P.J.Y.: Numerical method for fractional Bagley-Torvik equation. AIP Conf. Proc.

**2116**(1), 240007 (2019). https://doi.org/10.1063/1.5114238Esmaeili, S.: The numerical solution to the Bagley-Torvik equation by exponential integrators. Sci. Iran. B

**24**(6), 2941–2951 (2017)Gülsu, M., Öztürk, Y., Anapali, A.: Numerical solution of the fractional Bagley-Torvik equation arising in fluid mechanics. Int. J. Comput. Math.

**94**(1), 173–184 (2017)Ray, S.S., Bera, R.K.: Analytical solution of the Bagley Torvik equation by Adomian decomposition method. Appl. Math. Comput.

**168**, 398–410 (2005)Emadifar, H., Jalilian, R.: An exponential spline approximation for fractional Bagley-Torvik equation. Bound. Value Probl.

**2020**, 20 (2020). https://doi.org/10.1186/s13661-020-01327-2Tayebi, S., Sh, M., Abu Arqub, O.: The cubic B-spline interpolation method for numerical point solutions of conformable boundary value problems. Alex. Eng. J.

**61**, 1519–1528 (2022)Abu Arqub, O., Tayebi, S., Baleanu, D., Osman, M.S., Mahmoud, W., Alsulami, H.: A numerical combined algorithm in cubic B-spline method and finite difference technique for the time-fractional nonlinear diffusion wave equation with reaction and damping terms. Results Phys.

**41**, 105912 (2022)Ben Rabah, A., Sh, M., Abu Arqub, O.: The B-spline collocation method for solving conformable initial value problems of non-singular and singular types. Alex. Eng. J.

**61**, 963–974 (2022)Rao, S.C.S., Kumar, M.: B-spline collocation method for nonlinear singularly perturbed two-point boundary-value problems. J. Optim. Theory Appl.

**134**(1), 91–105 (2007). https://doi.org/10.1007/s10957-007-9200-6Akram, G., Tariq, H.: An exponential spline technique for solving fractional boundary value problem. Calcolo

**53**, 545–558 (2016)Ding, Q., Wong, P.J.Y.: Quintic non-polynomial spline for time-fractional nonlinear Schrödinger equation. Adv. Differ. Equ.

**1**, 1–27 (2020)Jalilian, R., Tahernezhad, T.: Exponential spline method for approximation solution of Fredholm integro-differential equation. Int. J. Comput. Math. https://doi.org/10.1080/00207160.2019.1586891

Bagley, R.L., Torvik, P.J.: On the appearance of the fractional derivative in the behavior of real materials. J. Appl. Mech.

**51**(2), 294–298 (1984)Maleknejad, K., Torkzadeh, L.: Hybrid functions approach for the fractional Riccati differential equation. Filomat

**30**(9), 2453–2463 (2016)Saadatmandi, A., Dehghan, M.: A new operational matrix for solving fractional-order differential equations. Comput. Math. Appl.

**59**, 1326–1336 (2010)Agarwal, P., Berdyshev, A., Karimov, E.: Solvability of a non-local problem with integral transmitting condition for mixed type equation with Caputo fractional derivative. Results Math.

**71**, 1235–1257 (2017). https://doi.org/10.1007/s00025-016-0620-1Agarwal, P., Jain, S., Mansour, T.: Further extended Caputo fractional derivative operator and its applications. Russ. J. Math. Phys.

**24**, 415–425 (2017). https://doi.org/10.1134/S106192081704001XRashid, S., Tul Kubra, K., Sultana, S., Agarwal, P., Osman, M.S.: An approximate analytical view of physical and biological models in the setting of Caputo operator via Elzaki transform decomposition method. Int. J. Comput. Appl. Math.

**413**, 114378 (2022)Akgül, A., Mustafa, I., Baleanuc, D.: On solutions of variable-order fractional differential equations. Int. J. Optim. Control

**7**(1), 112–116 (2017)Akgül, A., Inc, M., Karatas, E., Baleanu, D.: Numerical solutions of fractional differential equations of Lane-Emden type by an accurate technique. Adv. Differ. Equ.

**220**, 1–12 (2015)Akgül, A.: A new method for approximate solutions of fractional order boundary value problems. Neural Parallel Sci. Comput.

**22**(1–2), 223–237 (2014)Al-Mdallal, Q.M., Syam, M.I., Anwar, M.N.: A collocation shooting method for solving fractional boundary value problems. Commun. Nonlinear Sci. Numer. Simul.

**15**(12), 3814–3822 (2010)Diego Murio, A.: Implicit finite difference approximation for time fractional diffusion equations. Comput. Math. Appl.

**56**, 1138–1145 (2008)Hamou, A.A., Azroul, E., Alaoui, A.L.: Fractional model and numerical algorithms for predicting COVID-19 with isolation and quarantine strategies. Int. J. Appl. Comput. Math.

**7**, 142 (2021)Ghasemi, M., Jalilian, Y., Trujillo, J.J.: Existence and numerical simulation of solutions for nonlinear fractional pantograph equations. Int. J. Comput. Math.

**94**(10), 2041–2041 (2017)Podlubny, I.: Matrix approach to discrete fractional calculus. Fract. Calc. Appl. Anal.

**3**(4), 359–386 (2000)Tian, W., Zhou, H., Deng, W.: A class of second order difference approximations for solving space fractional diffusion equations. Math. Comput.

**84**, 1703–1727 (2015)Maleknejad, K., Rashidinia, J., Jalilian, H.: Nonpolynomial spline functions and quasilinearization. Filomat

**32**(11) (2018)

## Acknowledgements

The authors are grateful to the reviewers for their helpful, valuable comments and suggestions in the improvement of this manuscript.

## Funding

Not applicable.

## Author information

### Authors and Affiliations

### Contributions

Nahid Barzehkar, Reza Jalilian and Ali Barati wrote and reviewed this article.

### Corresponding author

## Ethics declarations

### Competing interests

The authors declare no competing interests.

## Additional information

### Abbreviations

Not applicable.

### Publisher’s Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

## Rights and permissions

**Open Access** This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article’s Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.

## About this article

### Cite this article

Barzehkar, N., Jalilian, R. & Barati, A. Hybrid cubic and hyperbolic b-spline collocation methods for solving fractional Painlevé and Bagley-Torvik equations in the Conformable, Caputo and Caputo-Fabrizio fractional derivatives.
*Bound Value Probl* **2024**, 27 (2024). https://doi.org/10.1186/s13661-024-01833-7

Received:

Accepted:

Published:

DOI: https://doi.org/10.1186/s13661-024-01833-7