Skip to main content

On solving initial value problems for partial differential equations in maple

Abstract

Objectives

In this paper, we present and employ symbolic Maple software algorithm for solving initial value problems (IVPs) of partial differential equations (PDEs). From the literature, the proposed algorithm exhibited a great significant in solving partial differential equation arises in applied sciences and engineering.

Results

The implementation include computing partial differential operator (PartialDiffOperator), Greens function (GreensFunction) and exact solution (ExactSolution) of the given IVP. We also present syntax, ApplyPartialDiffOp, to apply the partial differential operator to verify the solution of the given IVP obtained from ExactSolution. Sample computations are presented to illustrate the maple implementation.

Introduction

In the scientific area, symbolic computation is one of the significant subjects, and it is playing dominant role in solving many mathematical equations, particularly the applications related to differential equations. In the symbolic computation research, the biggest success is the developing several substantial software systems. Several symbolic algorithms/methods have been created by various scientists, researchers and engineers; see, for example,  [1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]. Most of these algorithms have been implemented in various mathematical software. Hence, in this paper, we focus on the implementation of the efficient algorithm presented in [13]. For more understanding and application on Maple software commands on how to obtain numerical solutions and the plots see [27,28,29,30,31].

In this paper, we mainly focused on the Maple implementation of the initial value problems (IVPs) for solving partial differential equations (PDEs) with constant coefficients. The proposed algorithm/method was introduced by S. Thota and S. D. Kumar in 2020, see [13] for more details. In [13], they presented a new symbolic method/algorithm to find the Green’s function for a given IVP of linear second order PDEs with constant coefficients. In this method, they focused on computing the Green’s function using the integro-differential algebras [1, 3, 9, 25]. They have discussed several numerical examples to illustrate the symbolic algorithm. They also briefly discussed about the implementation in Maple. The rest of paper is planned as follows. In Sect.  1.1, we briefly state the symbolic algorithm of IVP for PDEs, Sect.  2 presents the Maple implementation of the algorithm with pseudo-code and Maple programming and Sect.  3 focused on sample computations to illustrate the implementation.

Symbolic method/algorithm

In this section, we recall the symbolic method/algorithm for IVPs for second order PDEs, see [13], for more details about the algorithm.

The general form of the IVP for a second order PDE with inhomogeneous initial conditions over \(\mathcal {F} = C^\infty (\mathbb {R}^2)\) is as follows.

$$\begin{aligned}&a \frac{\partial ^2 u(x,y)}{\partial x^2} + b \frac{\partial ^2 u(x,y)}{\partial x \partial y} + c \frac{\partial ^2 u(x,y)}{\partial y^2} = f(x,y), \\&u(0,y)=\alpha _1(y),\frac{\partial u(0,y)}{\partial x}=\alpha _2(y), \end{aligned}$$
(1)

where \(u(x,y) \in \mathcal {F}\) is unknown function which is going to be determined, called solution of (1), using forcing function \(f(x,y) \in \mathcal {F}\) and the initial data \(\alpha _1(y),\alpha _2(y) \in \mathcal {F}\). The proposed algorithm solves the IVP (1) not only for static values of f(x, y), \(\alpha _1(y),\alpha _2(y)\) but give a standard formula of the solution of IVP (1). The operators notation of the IVP (1) is

$$\begin{aligned}&\texttt {D}u = f, \\&\tilde{\texttt {E}} u = \alpha _1,\tilde{\texttt {E}} \partial _x u = \alpha _2, \end{aligned}$$
(2)

where \(\texttt {D}= a\partial _{xx} + b\partial _{xy} + c\partial _{yy}\) is differential operator; \(\tilde{\texttt {E}} u = u(0,y), \tilde{\texttt {E}} \partial _x u = \left( \frac{\partial u}{\partial x} \right) _{x=0}\) are initial evaluation operators; and \(\alpha _1, \alpha _2\) are initial data of the given IVP. One can factor the second order differential operator into linear operator [13] and then the given IVP for PDE (2) can be expressed as follows

$$\begin{aligned} &a \left( \partial _x + \left( \frac{b}{2a} + \frac{\sqrt{b^2-4ac}}{2a} \right) \partial _y \right) \left( \partial _x + \left( \frac{b}{2a} - \frac{\sqrt{b^2-4ac}}{2a} \right) \partial _y \right) u = f, \\&\tilde{\texttt {E}} u = \alpha _1,\tilde{\texttt {E}} \partial _x u = \alpha _2. \end{aligned}$$

Now we present main theorem of algorithm for computing the Green?s function of IVP (2) over integro-differential algebras.

Theorem 1

Let \((\mathcal {F},\texttt {D},\texttt {A})\) be an integro-differential algebra. Suppose \(\texttt {D}= a\partial _{xx} + b\partial _{xy} + c\partial _{yy}\) is a linear partial differential operator of second order. Then the IVP (2) has the unique solution as follows, for \(m_1 \ne m_2\),

$$\begin{aligned} u =&~ \frac{1}{a}\int _0^x \int _0^t f(\xi , y + m_1(t-x) - m_2(t-\xi )) \ d\xi \ dt \\&~ + \left( \frac{m_2}{m_2 - m_1} \right) \alpha _1(y-m_1x) + \left( \frac{m_1}{m_1-m_2} \right) \alpha _1(y-m_2x) \\&~ + \left( \frac{1}{m_1-m_2} \right) \int _{y-m_1x}^{y-m_2x} \alpha _2(s) \ ds \in \mathcal {F}, \end{aligned}$$

for \(m_1 = m_2\),

$$\begin{aligned} u =&~ \frac{1}{a}\int _0^x \int _0^t f(\xi , y - m_1(x-\xi )) \ d\xi \ dt \\&~ + \alpha _1(y-m_1x) + x \alpha _2(y-m_1x) + m_1 x \partial _y \alpha _1(y-m_1x) \in \mathcal {F}, \end{aligned}$$

here \(m_1 = \frac{b}{2a} + \frac{\sqrt{b^2-4ac}}{2a}, m_2 = \frac{b}{2a} - \frac{\sqrt{b^2-4ac}}{2a}\), and \(a \ne 0,b,c \in \mathbb {R}\).

Proof

See [13, Theorem 5].\(\square\)

Main text

This section discusses about the Maple implementation of IVPs for PDEs, IVPforPDE package and its pseudo-code. In this implementation, various data types are created to compute the Green’s function, namely PartialDiffOperator(a1,a2,a3), where a1,a2,a3 are the coefficients of the differential operator as given in Eq. (1); and GreensFunction(ParDiffOp), where ParDiffOp is the partial differential operator as given Eq. (2). Now finally, we have ExactSolution(ParDiffOp, forcefun, alpha, beta), where forcefun is the forcing function, alpha, beta are the initial data. We also created ApplyPartialDiffOp(ParDiffOp,sol) to verify the solution sol. This Maple package is available with example worksheet at http://www.sinivasaraothota.webs.com/research.

Pseudo-Code

The following pseudo-code gives the exact solution of a given IVP for PDEs of second order.

figure a

The following pseudo-code shows how to compute the Green?s function of a given IVP for PDEs of second order of the type in Eq.  (1).

figure b

Maple implementation

The following procedure gives partial differential operator of the given IVP.

figure c

The following procedure produces the Green’s function

figure d

Using the following data type, one can obtain the exact solution of the given IVP.

figure e

One can also verify the solution using the following procedure.

figure f

Results

In this section, we show sample computations using the implementation of IVP. Recall couple of examples from [13] to verify the package. However, there are several example available in [32,33,34] to verify the Maple implementation.

Example 1

Consider second order IVP of the form [13] to demonstrate the Maple implementation.

$$\begin{aligned} &\frac{\partial ^2 u(x,y)}{\partial x^2} + \frac{\partial ^2 u(x,y)}{\partial x \partial y} - 6 \frac{\partial ^2 u(x,y)}{\partial y^2} = y \cos x, \\&u(0,y) = y-1,\frac{\partial u(0,y)}{\partial x} = y^2. \end{aligned}$$
(3)

From Eq. (3), we have \(a_1=1, a_2=1, a_3=-6, f(x,y)=y \cos x, \alpha =y-1, \beta = y^2\) Using Maple,

> PDO := PartialDiffOperator(1, 1, -6);

$$\begin{aligned} PDO := \partial (xx)+\partial (xy)-6\partial (yy). \end{aligned}$$

> G := GreensFunction(PDO)

$$\begin{aligned} G =& \int _0^x \int _{0}^{t} f(s, y-2(t-x) +3(s-t)) \ ds \ dt + \frac{3}{5} \alpha _1(y+2x) \\ & + \frac{2}{5} \alpha _1(y-3x) - \frac{1}{5} \int _{y+2x}^{y-3x} \alpha _2(s) \ ds. \end{aligned}$$

> Sol := ExactSolution(PDO, y*cos(x), y-1, y\(\wedge\)2);

$$\begin{aligned} Sol:= 2y-x-y\cos x+\sin x-1 + \frac{1}{15} (y+2x)^3-\frac{1}{15} (y-3x)^3. \end{aligned}$$

> ApplyPartialDiffOp(PDO, G);

$$\begin{aligned} f(x,y),~a1(y),~a2(y). \end{aligned}$$

> ApplyPartialDiffOp(PDO, Sol);

$$\begin{aligned} y\cos (x),~y-1,~y^2. \end{aligned}$$

Example 2

Consider second order IVP of the form [13]

$$\begin{aligned} &4\frac{\partial ^2 u(x,y)}{\partial x^2} - 4 \frac{\partial ^2 u(x,y)}{\partial x \partial y} + \frac{\partial ^2 u(x,y)}{\partial y^2} = 16 \log (x+2y), \\ & u(0,y)=0, \ \frac{\partial u(0,y)}{\partial x}=0. \end{aligned}$$
(4)

The exact solution of IVP (4) as

$$\begin{aligned} u(x,y) =&~ 2x^2 \log (x + 2y). \end{aligned}$$

Using the Maple implementation, we have:

> PDO:=ParialDiffOperator(4,-4,1);

$$\begin{aligned} PDO := 4 \partial (xx) - 4 \partial (xy) + \partial (yy). \end{aligned}$$

> g:=GreensFunction(PDO);

$$\begin{aligned} g:=&~ \frac{1}{4} \int _{0}^{x} \int _{0}^{t} f(s, y+\frac{1}{2}x - \frac{1}{2} s) \ ds \ dt \\&~ + a1(y+\frac{1}{2} x)+xa2(y+\frac{1}{2} x) - \frac{1}{2} x D(a1) (y+\frac{1}{2} x). \end{aligned}$$

> u:=ExactSolution(PDO,16*log(x+2*y),0,0);

$$\begin{aligned} u:=&~ 2 ln(x+2y) x^2. \end{aligned}$$

> ApplyPartialDiffOp(PDO,u);

$$\begin{aligned} 16 ln(x+2y),0,0. \end{aligned}$$

> ApplyPartialDiffOp(PDOp,g);

$$\begin{aligned} f(x,y),a1(y),a2(y). \end{aligned}$$

Limitations

The algorithm in [13] is focused on the IVP for regular linear PDEs, hence the implemented maple package, IVPforPDE, presented in this paper is valid for the regular linear PDEs with initial conditions. We have also presented a syntax to check the validity of solution of a given problem.

Availability of data and materials

The datasets generated and analyzed during the current study are presented in this manuscript.

Abbreviations

IVP:

Initial value problem

PDE:

Partial differential equation

References

  1. Thota S, Kumar SD. Solving system of higher-order linear differential equations on the level of operators. Int J Pure Appl Math. 2016;106(1):11–21.

    Article  Google Scholar 

  2. Thota S, Kumar SD. On a mixed interpolation with integral conditions at arbitrary nodes. Cogent Math. 2016;3(1):1151613.

    Article  Google Scholar 

  3. Thota S, Kumar SD. Symbolic algorithm for a system of differential-algebraic equations. Kyungpook Math J. 2016;56(4):1141–60.

    Article  Google Scholar 

  4. Thota S, Kumar SD. Maple implementation of symbolic methods for initial value problems. In: Research for resurgence, vol. 1, no. 1; 2018. pp. 21–39. ISBN: 978-93-83861-12-5.

  5. Thota S. On a new symbolic method for initial value problems for systems of higher-order linear differential equations. Int J Math Models Methods Appl Sci. 2018;12:194–202.

    Google Scholar 

  6. Thota S. A symbolic algorithm for polynomial interpolation with integral conditions. Appl Math Inform Sci. 2018;12(5):995–1000.

    Article  Google Scholar 

  7. Thota S. Initial value problems for system of differential-algebraic equations in Maple. BMC Res Notes. 2018;11:651.

    Article  Google Scholar 

  8. Thota S. On a symbolic method for error estimation of a mixed interpolation. Kyungpook Math J. 2018;58(3):453–62.

    Google Scholar 

  9. Thota S. On a symbolic method for fully inhomogeneous boundary value problems. Kyungpook Math J. 2019;59(1):13–22.

    Google Scholar 

  10. Thota S. A symbolic algorithm for polynomial interpolation with stieltjes conditions in maple. Proc Inst Appl Math. 2019;8(2):112–20.

    Google Scholar 

  11. Thota S. On a new symbolic method for solving two-point boundary value problems with variable coefficients. Int J Math Comput Simul. 2019;13:160–4.

    Google Scholar 

  12. Thota S, Shanmugasundaram P. On a symbolic method for neutral functional-differential equations with proportional delays. Cogent Math Stat. 2020;7(1):1813961.

    Article  Google Scholar 

  13. Thota S, Kumar SD. Symbolic algorithm to solve initial value problems for partial differential equations. Bull Comput Appl Math. 2020;8(1):1–24.

    Google Scholar 

  14. Thota S. On solving system of linear differential-algebraic equations using reduction algorithm. Int J Math Math Sci. 2020;10. ArticleID 6671926.

  15. Thota S, Kumar SD. A new reduction algorithm for differential-algebraic systems with power series coefficients. Inform Sci Lett. 2021;10(1):59–66.

    Article  Google Scholar 

  16. Thota S. maple implementation of a symbolic method for fully inhomogeneous boundary value problems. Int J Appl Math Comput Sci Syst Eng. 2021;3:1–5.

    Google Scholar 

  17. Thota S. Maple implementation for reducing differential-algebraic systems, conference on mathematics for the advancement of science, technology and education, March 5–6, at Ethiopian Mathematics Professionals Association (EMPA). Department of Mathematics: College of Natural and Computational Sciences, Addis Ababa University, Ethiopia; 2021.

  18. Thota S. Maple implementation of a symbolic method for fully inhomogeneous boundary value problems. 2021 International Conference on Mathematics and Computers in Science and Engineering (MACISE 2021), January 18–20, 2021, Madrid, Spain.

  19. Thota S, Kumar SD. Maple implementation of a reduction algorithm for differential-algebraic systems with variable coefficients. In: International Conference on Recent Trends in Engineering & Technology and Quest for Sustainable Development, May 13–14. Institute of Technology. Ethiopia: Ambo University; 2019.

  20. Thota S. A new symbolic method for solving two-point boundary value problems, The Hawassa Math&Stat Conference 2019 (February), pp. 11–15, . Hawassa University. Ethiopia: Hawassa; 2019.

  21. Thota S, Kumar SD. Maple Package of Initial Value Problem for System of Differential-Algebraic Equations. National Seminar on Applications of Scientific and Statistical Software in Research, 30–31 March. The School of Sciences. Allahabad, India: Uttar Pradesh Rajarshi Tandon Open University; 2017.

  22. Thota S, Kumar SD. A new method for general solution of system of higher-order linear differential equations. International Conference on Inter Disciplinary Research in Engineering and Technology, April 29–30, 2015, New Delhi, India.

  23. Thota S, Kumar SD. Symbolic method for polynomial interpolation with Stieltjes conditions. International Conference on Frontiers in Mathematics, March 26–28. Guwahati University. India: Guwahati; 2015.

  24. Thota S, Kumar SD. A new reduction algorithm for systems of linear differential-algebraic equations. In: National Conference on Applications of Mathematics in Engineering and Sciences, November 29–30, . Motilal Nehru National Institute of Technology. India: Allahabad; 2014.

  25. Thota S, Rosenkranz M, Kumar SD. Solving systems of linear differential equations over integro-differential algebras. In: International Conference on Applications of Computer Algebra, June 24–29, 2012, Sofia, Bulgaria.

  26. Thota S, Kumar SD. On a new symbolic method for solving linear boundary problems via non-commutative Groebner bases. International Conference on Recent Advances in Electronics & Computer Engineering, December 17–18. Eternal University. India: Himachal Pradesh; 2011.

  27. Aleksandar D. Analytical solutions of PDEs using PDE tools in Maple (2007).

  28. Falade KI. Introduction to computational algorithm, Numerical and computational research laboratory KUST. 2021. https://doi.org/10.13140/RG.2.2.36674.09920.

  29. George A. Articolo: partial differential equations and boundary value problems with maple. 2nd Edn. 2009. Academic Press is an imprint of Elsevier.

  30. Monagan MB, Geddes KO, Heal KM, Labahn G, Vorkoetter SM, McCarron J, DeMarco P. Maple 9 Advanced Programming Guide. 2003.

  31. Mark S. Gockenbach. Maple tutorial on partial differential equations: analytical and numerical methods (SIAM, 2010), 2nd edition.

  32. Jain RK, Iyengar SRK. Advanced engineering mathematics. 3rd ed. India: Narosa Publishing House; 2008.

    Google Scholar 

  33. Grigoryan V. Partial differential equations. Department of Mathematics: University of California, USA; 2010.

  34. Pinchover Y, Rubinstein J. An introduction to partial differential equations. Cambridge: Cambridge University Press; 2015.

    Google Scholar 

Download references

Acknowledgements

The author is thankful to the reviewer and editor for providing valuable inputs to improve the quality and present format of manuscript.

Authors’ information

Dr. Srinivasarao Thota completed his M.Sc. in Mathematics from Indian Institute of Technology (IIT) Madras, India and Ph.D. in Mathematics from Motilal Nehru National institute of Technology (NIT) Allahabad, India. Srinivasarao Thota’s area of research interests are Computer Algebra (symbolic methods for differential equations), Numerical Analysis (root finding algorithms), Mathematical Modeling (ecology). He has published more than 40 research papers in various international journals and presented his research work at several international conferences as oral presenter and invited/keynote/guest speaker in different countries. Presently working at department of applied mathematics, Adama Science and Technology University, Ethiopia.

Funding

Not applicable.

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Srinivasarao Thota.

Ethics declarations

Ethics approval and consent to participate

Not applicable.

Consent for publications

Not applicable.

Competing interests

The authors declare that they have no competing interests.

Additional information

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/. The Creative Commons Public Domain Dedication waiver (http://creativecommons.org/publicdomain/zero/1.0/) applies to the data made available in this article, unless otherwise stated in a credit line to the data.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Thota, S. On solving initial value problems for partial differential equations in maple. BMC Res Notes 14, 307 (2021). https://doi.org/10.1186/s13104-021-05715-4

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: https://doi.org/10.1186/s13104-021-05715-4

Keywords

JEL Classification