Abstract
The Caputo fractional -derivative, , for non-smooth functions with regularity is calculated by numerical computation. Let I be an interval and be the set of all functions which satisfy , where and is a continuous function for each c. We first extend the trapezoidal method on the set and rewrite the integrand of the Caputo fractional integral as a product of two differentiable functions. In this approach, the non-smooth function and the singular kernel could have the same impact. The trapezoidal method using the Riemann–Stieltjes integral (TRSI) depends on the regularity of the two functions in the integrand. Numerical simulations demonstrated that the order of accuracy cannot be increased as the number of zones increases using the uniform discretization. However, for a fixed coarsest grid discretization, a refinable mesh approach was employed; the corresponding results show that the order of accuracy is , where k is a refinable scale. Meanwhile, the application of the product of two differentiable functions can also be applied to some Riemann–Liouville fractional differential equations. Finally, the stable numerical scheme is shown.
1. Introduction
Fractional calculus [1,2,3] has attracted increased interest over the last decade and has been applied in several fields including finance, control theory, electronic circuit theory, mechanics, physics, and signal processing [4,5,6,7,8,9,10,11]. There are two popular definitions of the fractional differentiation: the Riemann–Liouville derivative and the Caputo derivative. Let , n be a positive integer with , and .
- Riemann–Liouville derivative: The Riemann–Liouville derivative of a function starting at the point a is
- Caputo derivative: The Caputo derivative of a function starting at the point a is
The comparison of these two definitions can be found in [12] and the definitions of fractional derivatives are also revised in some studies [11,12,13,14].
The trapezoidal rule was used for integration or differential equations in the following papers [15,16,17]. However, the functions of the integrand are assumed to be regular. This paper is devoted to the computation of the Caputo fractional derivative on financial derivatives [18,19,20,21]. In some of them, the functions of the stock or option prices are only of Lipschitz continuity. Our goal is to calculate the Caputo fractional integral for non-smooth functions. This calculation will also encounter the difficulty induced by the singular kernel. In [18], an implicit numerical discretization is used for the Riemann–Liouville integral to calculate the chaotic behavior for financial models. In [22], the treatment for a singular kernel involves the linear expansion of the smooth functions and direct integration of the product of the linear polynomial and the singular kernel. In our approach, we consider the function non-smooth. The function could be also singular, and the impact of the function for the integral is similar to the kernel.
Let n be a positive integer and be an interval. Define and , where . To explore the niche of this research, let us explain the following examples. The set of represents the collection of all functions whose domain on and they are of a continuous k-th derivative. If , it is well known in the textbook of numerical analysis, and the approximation is
where is in . For the particular case, , the order of accuracy of the trapezoidal rule method is reduced because the function belongs exclusively to .
Definition 1.
Let I be an interval and the set
where is a continuous function for each .
For example, , , and . Then,
with
If , then and is continuous on for each . Hence, . Moreover, for a fixed x, the function may not be continuous on c since and for all .
This paper is organized as follows. The order of accuracy for the trapezoidal method on the set is derived in Section 2. The proposed method for calculation of Caputo fractional derivative is described in Section 3, using three examples. Smooth, regular and non-regular functions are used in numerical simulations in Section 4. Section 5 shows the analysis of the method to explain the obtained results and Section 6 demonstrates two applications of the proposed method. The conclusion is given in the last section.
2. Order of Accuracy for Trapezoidal Method on
In this section, we extend the analysis of the order of accuracy for the trapezoidal method on the set . Let us begin to consider the interpolation on the set .
Lemma 1.
Let . The linear interpolation of f on has the property
where is a continuous function and .
Proof.
Since
we obtain
Here, . □
Lemma 2.
Let and . Then,
where is a continuous function.
Proof.
This lemma holds. It is followed by Lemma 1 and
where in , and the second equality is followed by the weighted mean value theorem. □
Lemma 3.
Let and . Then,
Proof.
From the following,
and taking the subtraction of the above two equations, it yields
□
Moreover, for and . Since h is continuous and bounded by the extremum theorem of continuous functions on a closed interval, Lemma 2 can be re-estimated to be Theorem 1 below.
Theorem 1.
Let and . Then,
Remark.
If then , where between c and x, then .
Theorem 2.
Let and . If
and is uniformly bounded for all , then
3. Method
For the sake of simplicity and without loss generality, the case of is considered in the whole paper. Equation (1) is equal to
or
here, .
Let the interval and N be a positive integer. The interval I is divided into N-subintervals with the sample points , .
Since is monotonic whenever , the inverse of exists. Using the substitution rule, for fixed t, the integral
can be rewritten into
where and . The linear interpolation of on the interval I with the endpoints and is
The approximation in the last equation listed above represents the trapezoidal method but uses the Riemann–Stieltjes integral. The roles of f and g may be interchanged. Equation (9) is modified to
where is the Heaviside step function. We refer to the approach in (10) as the TRSI method. If the function f is smooth and is non-smooth, then TRSI in (10) may only use . On the other hand, the function is smooth and f is non-smooth, then TRSI in (10) may only use . For Caputo fractional derivatives, is described as the form and its derivative is singular at its origin. Therefore, if the function f is smooth, then only occurs at the singularity of .
The stability of the TRSI method to use Equation (6) is to estimate the following:
If is uniformly bounded for , and are bounded, , then
and it follows that TRSI is stable. The condition is uniformly bounded. It also indicates the existence of the Riemann–Stieltjes integral. It is identical to the existence of the Riemann–Stieltjes integral
requires the condition that the discontinuity of and cannot occur coincidentally, and vice versa. Therefore, the stability theorem of the TRSI method is stated in the following theorem.
Theorem 3.
The TRSI method is stable if the condition that the discontinuity of and φ cannot occur coincidentally is held.
4. Simulations
Let us consider the interval and there are N uniform cells; that is, each subinterval has the length with the sample points . We will vary from to . To probe the behavior of the TRSI method, let us define the 1-norm,2-norm and ∞-norm in vectors of numerical solutions by
Furthermore, the order of accuracy is defined as
where and is the error between the numerical and exact solutions at the size of zones . In the following subsection, we adopt three examples as model examples which represent the smooth, regular and non-smooth functions from Example 1 to Example 3 below, respectively.
4.1. Model Examples
Example 1.
Let us consider and . The polynomial is smooth because exists for any n, which is a non-negative integer. The Caputo fractional derivative of for is
The analytic solution is . The errors between the exact and numerical solutions are shown in Table 1, which demonstrates that the order of accuracy is near 1.5 for 1-norm, 2-norm and ∞-norm.
Table 1.
The errors between numerical and analytic solutions for and the order of accuracy. The order of accuracy is near 1.5 for 1-norm, 2-norm and ∞-norm.
Example 2.
Let us consider and . The power function only can take the first derivate because is singular at the origin. The Caputo fractional derivative of for is
The analytic solution is . The errors are shown in Table 2. The results demonstrate that the order of accuracy is near 1.5, 1.45 and 1 for 1-norm, 2-norm and ∞-norm, respectively.
Table 2.
The errors between numerical and analytic solutions for and the order of accuracy. The order of accuracy is near 0.52, 0.54 and 0.16 for 1-norm, 2-norm and ∞-norm, respectively.
Example 3.
Let us consider and . The power function f does not have the first derivative because does not exist. The Caputo fractional derivative of for is
The analytic solution is . The errors are shown in Table 3. The order of accuracy is near 0.52, 0.54 and 0.16 for 1-norm, 2-norm and ∞-norm, respectively. In Figure 1, the top-left panel shows the exact solution (red dot line) and the numerical solution (blue solid line). The errors between the numerical and exact solutions are shown in the top-right panel. The zoom-in profiles on are shown in the corresponding panels below.
Table 3.
The errors between numerical and analytic solutions for and the order of accuracy. It shows that the order of accuracy is near 0.52, 0.54 and 0.16 for 1-norm, 2-norm and ∞-norm, respectively.
Figure 1.
The profiles of the simulations of Example 3. The analytic () and the numerical solutions are shown in the top-left panel. The absolute value of the error is shown in the top-right panel. The zoom-in profiles on are shown in the corresponding panels below.
The approximation of the non-smooth or continuous function may improve the accuracy by refining the meshes. However, it is not equivalent to a finer mesh refinement in this case, as the kernel function is not only non-smooth, but it is singular for fixed . Therefore, we divide the subinterval by -zones again. More precisely,
where , , with . The results of fixed for , are shown in Table 4 and the corresponding profiles are shown in Figure 2. The errors were reduced from to ; see Table 3 and Table 4, respectively.
Table 4.
The errors between numerical and analytic solutions for and the order of accuracy using TRSI with refining mesh. The order of accuracy is near 1.76, 1.61 and 1.59 for 1-norm, 2-norm and ∞-norm, respectively.
Figure 2.
The profiles of the simulations of Example 3 with a refinable approach. The analytic () and the numerical solutions are in the top-left panel. The absolute value of the error is in the top-right panel. The zoom-in profiles on are shown in the corresponding panels below.
4.2. A Comparison Study
The modified trapezoidal rule (MTR) [22] uses the linear interpolation on rather than in the traditional sense for the following integral, and we rewrite it as shown below. The integral can be approximated by
where
The errors are shown in Table 5 and Table 6 for model example 1 and 2, respectively. However, Example 3 cannot be simulated by the MTR method because the derivative of the exact function does not exist at the origin.
Table 5.
The errors between numerical and analytic solutions for and the order of accuracy using the MTR method. It shows that the order of accuracy is 2.0 for 1-norm, 2-norm and ∞-norm.
Table 6.
The errors between numerical and analytic solutions for and the order of accuracy. It shows that the order of accuracy is near 1.49, 1.44 and 1.0 for 1-norm, 2-norm and ∞-norm, respectively.
5. Error Analysis
Let us start to observe the approximation of the function by the linear interpolation on ,
The error on has the maximum error
where . Let , ; the error for is This explains that the reason for Example 2 using the trapezoidal method is only of first-order accuracy.
Theorem 4.
Let the function be the linear interpolation of the function on each subinterval , and is uniformly bounded for . The modified trapezoidal rule for calculation
has the error bounded by and
Proof.
The error is given by
It follows that the error is less than
□
Theorem 4 can be applied to explain the results (Table 5 and Table 6) for Example 1 and Example 2 obtained using MTR. Next, we will analyze the TRSI method. Let us first recall the error analysis for smooth functions as Theorem 5 below for the trapezoidal method in comparison with the estimation of the errors for the functions in shown in Theorem 6 below.
Let
and . Then,
if has the third continuous derivative. Furthermore, if and are continuous whenever , then
It follows that
The above approximation leads to the theorem below.
Theorem 5.
If exists and is continuous and , then
for . Furthermore,
and for , the following approximation is reduced to
Furthermore, the term . On the other hand,
Theorem 6.
If and , then
for . Furthermore,
and for , the following approximation is reduced to
Let k be a positive integer and . If an integration scheme has the order of accuracy ,
where and for some numerical method, then the refinable approach using the mesh is read as
This implies that the order of accuracy is .
6. Applications
We are going to demonstrate the applications of the integrand in (10) rewritten as a product of two derivatives of functions on fractional differential equations with Caputo and Riemann–Liouville derivatives.
6.1. Fractional Differential Equation with Caputo Derivatives
We first solve the fractional differential equation to evaluate the TRSI method
The exact solution for (14) is .
The discretization approach at the zone is
If and for are given, then we have to solve and . There are two unknowns, and , in Equation (14) but only one equation. We further impose the condition
which means that the central difference at the midpoint of and approximation. It gives us
Coupling (14) and (15), the linear system for and is obtained
where , , ,
The errors between the analytic and numerical solutions for the IVP problem are shown in Table 7. It shows the order of accuracy is 1.49 for the 1-norm and 2-norm and 1.46 for the ∞-norm.
Table 7.
The errors between the analytic and numerical solutions for the IVP problem are shown in this table. The order of accuracy is 1.49 for 1-norm and 2-norm and 1.46 for ∞-norm.
6.2. Fractional Differential Equation with Riemann–Liouville Derivatives
In this subsection, we consider the fractional ordinary equation [23]:
The exact solution is the same as the previous case, . Taking the integration from to , we obtain
or
We use the traditional trapezoidal method for the second integral on the left-hand side as the same approach in [23]. Meanwhile, people can define the coefficients , , and
where , , , , , and are defined in the (Section 6.1). The numerical solution is obtained by solving the following linear system:
The errors between the exact and numerical solutions are shown in Table 8, which demonstrates that the order of accuracy is near 1.49 for 1-norm and 2-norm and 1.48 for ∞-norm.
Table 8.
The errors between the analytic and numerical solutions for the IVP2 problem are shown in this table. It shows the order of accuracy is 1.49 for 1-norm and 2-norm and 1.48 for ∞-norm.
7. Conclusions
The analysis of the trapezoidal method was extended from to and, for each , has the order of accuracy . The trapezoidal method using the Riemann–Stieltjes integral on Caputo fractional derivatives for non-smooth functions was proposed, and the approximation ability was also investigated using three models of examples of smoothness, regularity and non-smoothness. The product of the integrand reveals that, if and the integration is approximated by using the differential , then the trapezoidal method has the second order of accuracy compared to the traditional one. On the other hand, if the integration is approximated by using the differential , , then the order of accuracy for the trapezoidal method is of the fractional order of accuracy. The novelty of this method can be addressed to automatically choose the non-smooth functions or the singular kernel for linear interpolation.
The errors in Table 3 show that increasing the number of zones cannot significantly improve the accuracy, and the order of accuracy is 0.16 for ∞-norm. Therefore, a refining mesh shown in Table 4 demonstrated that the order of accuracy is 1.59 for the ∞-norm. To confirm this point, we further apply the refinable approach to MTR. The result for the MTR method using a refinable approach is shown in Table 9; the order of accuracy improves from 1.0 to 1.50 for the ∞-norm, see Table 6 and Table 9.
Table 9.
The errors between numerical and analytic solutions for and the order of accuracy using MTR with refining mesh. The order of accuracy is near 1.5 for 1-norm, 2-norm and ∞-norm.
Author Contributions
Conceptualization, G.K. and C.-C.Y.; methodology, C.-C.Y.; formal analysis, C.-C.Y.; investigation, G.K.; writing—original draft preparation, G.K.; writing—review and editing, C.-C.Y. All authors have read and agreed to the published version of the manuscript.
Funding
C.C. Yen acknowledges the grant support from the Ministry of Science and Technology (MoST) under 109-2115-M-030-004-MY2 and National Science and Technology Council (NSC) under 111-2115-M-030-002.
Informed Consent Statement
Not applicable.
Data Availability Statement
Not applicable.
Acknowledgments
We sincerely appreciate the reviewers for all valuable comments and suggestions that helped us to improve the quality and the better presentation of the results in the manuscript.
Conflicts of Interest
The authors declare no conflict of interest.
References
- Kilbas, A.A.; Srivastava, H.M.; Trujillo, J.J. Theory and Applications of Fractional Differential Equations; Series North-Holland Mathematics Studies; North-Holland: New York, NY, USA, 2006. [Google Scholar]
- Oldham, K.; Spanier, J. The Fractional Calculus, Theory and Applications of Differentiation and Integration of Arbitrary Order; Academic Press: Cambridge, MA, USA, 1974. [Google Scholar]
- Podlubny, I. Fractional Differential Equations; Academic Press: Cambridge, MA, USA, 1999. [Google Scholar]
- Burrage, K.; Hale, N.; Kay, D. An efficient implicit FEM scheme for fractional-in-space reaction-diffusion equations. SIAM J. Sci. Comput. 2012, 34, A2145–A2172. [Google Scholar] [CrossRef] [Scilit]
- Cafagna, D.; Grassi, G. Observe-based projective synchronization of fractional systems via a scalar signal: Application to hyperchaotic Rössler systems. Nonlinear Dyn. 2012, 68, 117–128. [Google Scholar] [CrossRef] [Scilit]
- Caponetto, R.; Maione, G.; Pisano, A.; Rapaić, M.M.R.; Usai, E. Analysis and shaping of the self-sustained oscillations in relay controlled fractional-order systems. Fract. Calc. Appl. Anal. 2013, 16, 93–108. [Google Scholar] [CrossRef] [Scilit]
- Diethelm, K. An investigation of some nonclassical methods for the numerical approximation of Caputo-type fractional Derivatives. Numer. Algorithms 2008, 47, 361–390. [Google Scholar] [CrossRef] [Scilit]
- Garrappa, R.; Poplizio, M. On accurate product integration rules for linear fractional differential equations. J. Comput. Appl. Math. 2011, 235, 1085–1097. [Google Scholar] [CrossRef] [Scilit]
- Miller, K.S. An Introduction to Fractional Calculus and Fractional Differential Equations; John Wiley and Sons: New York, NY, USA, 1993. [Google Scholar]
- Moret, I.; Novati, P. On the convergence of Krylov subspace methods for matrix Mittag-Leffler functions. SIAM. J. Numer. Anal. 2011, 49, 2144–2164. [Google Scholar] [CrossRef] [Scilit]
- Rahimy, M. Applications of fractional differential equations. Appl. Math. Sci. 2010, 4, 2453–2461. [Google Scholar]
- Khalil, R.; Horani, M.A.I.; Yousef, A.; Sabaheh, M. A new definition of fractional derivative. J. Comput. Appl. Math. 2014, 264, 65–70. [Google Scholar] [CrossRef] [Scilit]
- Garrappa, R. Trapezoidal methods for fractional differential equations: Theoretical and computational aspects. Math. Comput. Simul. 2015, 10, 96–112. [Google Scholar] [CrossRef] [Scilit]
- Pandiangan, N.; Johar, D.; Purwani, S. Fractional integral approximation and Caputo derivatives with modification of trapezoidal rule. World Sci. News 2021, 153, 169–180. [Google Scholar]
- Arashad, S.; Huang, J.; Khaliq, A.Q.M.; Tang, Y. Trapezoid scheme for time-space fractional diffusion equation with Riesz derivative. J. Comput. Phys. 2017, 350, 1–15. [Google Scholar] [CrossRef] [Scilit]
- Odibat, Z. Approximations of fractional integrals and Caputo fractional derivatives. Appl. Math. Comput. 2006, 178, 527–533. [Google Scholar] [CrossRef] [Scilit]
- Rapaić, M.R.; Pisano, A.; Jeličić, Z.D.J. Trapezoidal rule for numerical evaluation of fractional order integrals with applications to simulation and identification of fractional order system. In Proceedings of the 2012 IEEE International Conference on Control Applications (CCA), Part of 2012 IEEE Multi-Conference on Systems and Control, Dubrovnik, Croatia, 3–5 October 2012. [Google Scholar]
- Diouf, M.; Sene, N. Analysis of the financial chaotic model with the fractional derivative operator. Complexity 2020, 2020, 9845031. [Google Scholar] [CrossRef] [Scilit]
- Fall, A.N.; Ndiaye, S.N.; Sene, N. Black-Scholes option pricing equations described by the Caputo generalized fractional derivative. Chaos Solitons Fractals 2019, 125, 108–118. [Google Scholar] [CrossRef] [Scilit]
- Jumaric, G. New stochastic fractional models of the Malthusian growth the poissonian birth process and optimal management of population. Math. Comput. Model 2006, 44, 231–254. [Google Scholar] [CrossRef] [Scilit]
- Ma, S.; Xu, Y.; Yue, W. Numerical solutions of a variable-order fractional financial system. J. Appl. Math. 2012, 2012, 417942. [Google Scholar] [CrossRef] [Scilit]
- Jahanshahi, S.; Babolian, E.; Torres, D.F.M.; Vahidi, A. A fractional Gauss-Jacobi quadrature rule for approximating fractional integrals and derivatives. Chaos Solitons Fractals 2017, 102, 295–304. [Google Scholar] [CrossRef] [Scilit]
- Li, B.; Wang, T.; Xie, X. Analysis of the L1 scheme for fractional wave equations with nonsmooth data. Comput. Math. Appl. 2021, 90, 1–12. [Google Scholar] [CrossRef] [Scilit]
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. |
© 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).

