 boundary conditions - Maple Help

pdsolve/boundaryconditions

find solutions for partial differential equations (PDEs) with boundary and/or initial conditions Calling Sequence pdsolve([PDE, conds], f, hint) Parameters

 PDE - a partial differential equation or system thereof conds - initial or boundary conditions f - indeterminate function or its name; or a set or list of them, required when there is more than one differentiated function hint - (optional): HINT = +, HINT = *, HINT = boundedseries, HINT = boundedseries(variable = value),       HINT = boundedseries(variable = [values]) method - (optional): method = method1, method = [method1, method2, ...], exclude = method1, exclude = [method1, method2, ...] option - (optional): degree = positive integer Description

 • Given one or more PDE with boundary and/or initial conditions, pdsolve works to find an analytical solution satisfying all of the given equations and conditions. There are no restrictions as to the type, differential order, or number of dependent or independent variables of the PDEs or PDE systems that pdsolve can try to solve, although the solving methods are limited in scope.
 • Several solution methods are used, depending on the order of the PDE, on whether they are linear, on the domain for the variables of the problem, and on whether the PDE or the boundary conditions, or both, are homogeneous.
 • Changes of variables in PDE and conditions are used as necessary in order to make problems solvable by pdsolve.
 • To see what method is being used to solve a given problem, you can assign the following (see infolevel):
 >
 • The solving methods can be indicated, either to be used for solving, as in , to be tried in the order indicated, or to be excluded, as in . The methods and sub-methods available are organized in a table, $\mathrm{pdsolve/BC/methods}:$
 > $\mathrm{indices}\left(\mathrm{pdsolve/BC/methods}\right)$
 $\left[{1}\right]{,}\left[{2}\right]{,}\left[{3}\right]{,}\left[{2}{,}{"Series"}\right]{,}\left[{2}{,}{"Wave"}\right]{,}\left[{"high_order"}\right]{,}\left[{"system"}\right]{,}\left[{2}{,}{"Heat"}\right]{,}\left[{2}{,}{"SpecializeArbitraryFunctions"}\right]$ (1)

So, for example, the methods for PDEs of first order and second order are, respectively,

 > $\mathrm{pdsolve/BC/methods}\left[1\right]$
 $\left[{"SpecializeArbitraryFunctions"}{,}{"Fourier"}{,}{"Laplace"}{,}{"Generic"}{,}{"PolynomialSolutions"}{,}{"LinearDifferentialOperator"}\right]$ (2)
 > $\mathrm{pdsolve/BC/methods}\left[2\right]$
 $\left[{"SpecializeArbitraryFunctions"}{,}{"SpecializeArbitraryConstants"}{,}{"Wave"}{,}{"Heat"}{,}{"Series"}{,}{"Laplace"}{,}{"Fourier"}{,}{"Generic"}{,}{"PolynomialSolutions"}{,}{"LinearDifferentialOperator"}{,}{"Superposition"}\right]$ (3)

Some methods have sub-methods:

 > $\mathrm{pdsolve/BC/methods}\left[2,"Series"\right]$
 $\left[{"TwoBC"}{,}{"ThreeBCsincos"}{,}{"FourBC"}{,}{"ThreeBC"}{,}{"ThreeBCPeriodic"}{,}{"WithSourceTerm"}{,}{"ThreeVariables"}\right]$ (4)
 > $\mathrm{pdsolve/BC/methods}\left[2,"Heat"\right]$
 $\left[{"SemiInfiniteDomain"}{,}{"WithSourceTerm"}\right]$ (5) • When the given PDE contains derivatives of more than one function, the function(s) which should be considered the indeterminate function(s), or its name, must be given as an extra argument.
 • The PDE (or system thereof) and boundary and/or initial conditions should all be given together as a list.
 • You can give a HINT indicating a method of solution or a form for the indeterminate function. When given, the hint is taken by pdsolve as the departure point in looking for the solution.
 • The following arguments can be used with the HINT option.
 HINT = +
 This option forces pdsolve to begin by trying to separate the variables by sum.
 HINT = *
 This option forces pdsolve to begin by trying to separate the variables by product.
 HINT = boundedseries
 This option tells pdsolve that the solution is bounded (pdsolve will choose an appropriate boundary).
 HINT = boundedseries(variable  = value), HINT = boundedseries(variable  = [values])
 This option tells pdsolve that the solution is bounded (using the given value(s) for the given variable).
 • You can specify one or more solving methods to be used or not used (excluded), from: Laplace, Fourier, Series, Generic, PolynomialSolutions, LinearDifferentialOperator, Wave, Heat, Superposition, SpecializeArbitraryFunctions, SpecializeArbitraryConstants.
 • When using the method PolynomialSolutions, a degree can be specified for the solution. Note that for linear PDE, the maximum degree used by pdsolve by default is 10; for nonlinear PDE, it is 4. You can override these default values by using the degree =... option. Conventions

 • Any arbitrary constants introduced during the solution process are represented as ${\mathrm{_C}}_{1}$, ${\mathrm{_C}}_{2}$,..., and are global.
 • Any functions introduced by pdsolve beginning with $\mathrm{_F}$ and followed by a number are assumed to be arbitrary, sufficiently differentiable functions of their arguments.
 • When pdsolve fails, it returns NULL. Examples

 The following illustrate some of the strategies and solution methods used by pdsolve to solve problems involving PDE with boundary conditions, initial conditions, or both. The HINT and method = ... options are illustrated in several different examples below. Click on the arrow to the left of each section name to view the examples for that section. Linear change of variables

PDE and BC problems often require that the boundary and initial conditions be given at certain evaluation points (usually in which one of the variables is equal to zero). With linear changes of variables, it is possible to change the evaluation points of the given conditions, obtaining the solution for the new variables, and then changing back to the original variables.

An example of a heat PDE & BC problem in a semi-infinite domain. Note the conditions are at $x=A$ and $t=B$.

 >
 $\mathrm{pde__1}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}\frac{\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)}{{4}}$ (6)
 > $\mathrm{conds__1}≔u\left(A,t\right)=0,u\left(x,B\right)=10:$

Note the assumptions placed below; depending on the problem, they may be required for it to be solvable. In this case, the assumptions are that x and t are, respectively, greater than the absolute value of the evaluation points of the conditions, in this case A and B.

 >
 ${u}{}\left({x}{,}{t}\right){=}{-}{10}{}{\mathrm{erf}}{}\left(\frac{{-}{x}{+}{A}}{\sqrt{{t}{-}{B}}}\right)$ (7)

A wave PDE with a source. Note that the conditions are at $t=1$.

 >
 $\mathrm{pde__2}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){-}{{c}}^{{2}}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)\right){=}{f}{}\left({x}{,}{t}\right)$ (8)
 > $\mathrm{conds__2}≔u\left(x,1\right)=g\left(x\right),{\mathrm{D}}_{2}\left(u\right)\left(x,1\right)=h\left(x\right):$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__2},\mathrm{conds__2}\right],u\left(x,t\right)\right)$
 ${u}{}\left({x}{,}{t}\right){=}\frac{{{\int }}_{{0}}^{{t}{-}{1}}{{\int }}_{\left({-}{t}{+}{\mathrm{\tau }}{+}{1}\right){}{c}{+}{x}}^{{x}{+}{c}{}\left({t}{-}{1}{-}{\mathrm{\tau }}\right)}\left(\left(\frac{{{ⅆ}}^{{2}}}{{ⅆ}{{\mathrm{ζ}}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{h}{}\left({\mathrm{ζ}}\right)\right){}{{c}}^{{2}}{}{\mathrm{\tau }}{+}\left(\frac{{{ⅆ}}^{{2}}}{{ⅆ}{{\mathrm{ζ}}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{g}{}\left({\mathrm{ζ}}\right)\right){}{{c}}^{{2}}{+}{f}{}\left({\mathrm{ζ}}{,}{\mathrm{\tau }}{+}{1}\right)\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{ζ}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\tau }}{+}\left({2}{}{t}{-}{2}\right){}{c}{}{h}{}\left({x}\right){+}{2}{}{g}{}\left({x}\right){}{c}}{{2}{}{c}}$ (9)

You can ask pdetest to test the solution against the original problem, if desired:

 > $\mathrm{pdetest}\left(,\left[\mathrm{pde__2},\mathrm{conds__2}\right]\right)$
 $\left[{0}{,}{0}{,}{0}\right]$ (10) Fourier Series method

This method, for single linear second-order PDEs in two or three independent variables, uses separation of variables by product to identify one or two Sturm-Liouville problems, depending on the number of variables. These problems are solved by finding eigenvalues with corresponding eigenfunctions, by using orthogonality properties of these eigenfunctions, and by then superimposing solutions (since the PDE is linear) to create an infinite series.

An example with the Schrodinger PDE with zero potential (Planck's constant, Z, is entered from the palettes):

 >
 $\mathrm{pde__3}{≔}{I}{}{\mathrm{\hslash }}{}\left(\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{f}{}\left({x}{,}{t}\right)\right){=}{-}\frac{{{\mathrm{\hslash }}}^{{2}}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{f}{}\left({x}{,}{t}\right)\right)}{{2}{}{m}}$ (11)
 >
 >
 ${f}{}\left({x}{,}{t}\right){=}{\sum }_{{n}{=}{1}}^{{\mathrm{\infty }}}{}{\mathrm{_C1}}{}\left({n}\right){}{\mathrm{sin}}{}\left(\frac{{n}{}{\mathrm{\pi }}{}{x}}{{L}}\right){}{{ⅇ}}^{\frac{{-}\frac{{I}}{{2}}{}{\mathrm{\hslash }}{}{{\mathrm{\pi }}}^{{2}}{}{{n}}^{{2}}{}{t}}{{m}{}{{L}}^{{2}}}}$ (12)

An example with the wave PDE:

 >
 $\mathrm{pde__4}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{{c}}^{{2}}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)\right)$ (13)
 >
 >
 ${u}{}\left({x}{,}{t}\right){=}{\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{{2}{}{\mathrm{sin}}{}\left(\frac{\left({1}{+}{2}{}{n}\right){}{\mathrm{\pi }}{}{x}}{{2}{}{L}}\right){}{\mathrm{cos}}{}\left(\frac{{c}{}\left({1}{+}{2}{}{n}\right){}{\mathrm{\pi }}{}{t}}{{2}{}{L}}\right){}\left({{\int }}_{{0}}^{{L}}{\mathrm{sin}}{}\left(\frac{\left({1}{+}{2}{}{n}\right){}{\mathrm{\pi }}{}{x}}{{2}{}{L}}\right){}{f}{}\left({x}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{x}\right)}{{L}}$ (14)

An example that represents the temperature distribution in a thin circular plate whose lateral surfaces are insulated:

 >
 $\mathrm{pde__5}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}{,}{t}\right){=}\frac{\frac{{\partial }}{{\partial }{r}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}{,}{t}\right){+}{r}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{r}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}{,}{t}\right)\right){+}\frac{\frac{{{\partial }}^{{2}}}{{\partial }{{\mathrm{\theta }}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}{,}{t}\right)}{{r}}}{{25}{}{r}}$ (15)
 > $\mathrm{conds__5}≔{\mathrm{D}}_{1}\left(u\right)\left(1,\mathrm{\theta },t\right)=0,u\left(r,0,t\right)=0,u\left(r,\mathrm{\pi },t\right)=0,u\left(r,\mathrm{\theta },0\right)=\left(r-\frac{1}{3}{r}^{3}\right)\mathrm{sin}\left(\mathrm{\theta }\right):$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__5},\mathrm{conds__5}\right]\right)$
 ${u}{}\left({r}{,}{\mathrm{θ}}{,}{t}\right){=}{\mathrm{casesplit/ans}}{}\left({\mathrm{Sum}}{}\left({-}\frac{{4}}{{3}}{}\frac{{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}{}{r}\right){}{\mathrm{sin}}{}\left({\mathrm{θ}}\right){}{\mathrm{exp}}{}\left({-}\frac{{1}}{{25}}{}{{\mathrm{λ}}}_{{n}}^{{2}}{}{t}\right){}\left({\mathrm{BesselJ}}{}\left({0}{,}{{\mathrm{λ}}}_{{n}}\right){}{{\mathrm{λ}}}_{{n}}^{{3}}{-}{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}\right){}{{\mathrm{λ}}}_{{n}}^{{2}}{+}{4}{}{{\mathrm{λ}}}_{{n}}{}{\mathrm{BesselJ}}{}\left({0}{,}{{\mathrm{λ}}}_{{n}}\right){-}{8}{}{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}\right)\right)}{{{\mathrm{λ}}}_{{n}}^{{3}}{}\left({{\mathrm{BesselJ}}{}\left({0}{,}{{\mathrm{λ}}}_{{n}}\right)}^{{2}}{}{{\mathrm{λ}}}_{{n}}{+}{{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}\right)}^{{2}}{}{{\mathrm{λ}}}_{{n}}{-}{2}{}{\mathrm{BesselJ}}{}\left({0}{,}{{\mathrm{λ}}}_{{n}}\right){}{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}\right)\right)}{,}{n}{=}{0}{..}{\mathrm{∞}}\right){,}\left\{{\mathrm{And}}{}\left({-}{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}\right){+}{\mathrm{BesselJ}}{}\left({2}{,}{{\mathrm{λ}}}_{{n}}\right){}{{\mathrm{λ}}}_{{n}}{=}{0}{,}{0}{<}{{\mathrm{λ}}}_{{n}}\right)\right\}\right)$ (16)

In the above we see that the eigenvalue $\mathrm{λ__n}$ satisfies $-{J}_{1}\left({\mathrm{\lambda }}_{n}\right)+{J}_{2}\left({\mathrm{\lambda }}_{n}\right){\mathrm{\lambda }}_{n}=0$. When $\mathrm{λ__n}$ is the root of one single BesselJ or BesselY function of integer order, the Maple functions BesselJZeros and BesselYZeros are used instead. That is the case, for instance, if we slightly modify this problem changing the first boundary condition to be $u\left(1,\mathrm{\theta },t\right)=0$ instead of ${\mathrm{D}}_{1}\left(u\right)\left(1,\mathrm{\theta },t\right)=0$

 > $\mathrm{conds__5.1}≔u\left(1,\mathrm{\theta },t\right)=0,u\left(r,0,t\right)=0,u\left(r,\mathrm{\pi },t\right)=0,u\left(r,\mathrm{\theta },0\right)=\left(r-\frac{1}{3}{r}^{3}\right)\mathrm{sin}\left(\mathrm{\theta }\right):$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__5},\mathrm{conds__5.1}\right]\right)$
 ${u}{}\left({r}{,}{\mathrm{θ}}{,}{t}\right){=}{\mathrm{casesplit/ans}}{}\left({\mathrm{Sum}}{}\left({-}\frac{{4}}{{3}}{}\frac{{\mathrm{BesselJ}}{}\left({1}{,}{{\mathrm{λ}}}_{{n}}{}{r}\right){}{\mathrm{sin}}{}\left({\mathrm{θ}}\right){}{\mathrm{exp}}{}\left({-}\frac{{1}}{{25}}{}{{\mathrm{λ}}}_{{n}}^{{2}}{}{t}\right){}\left({{\mathrm{λ}}}_{{n}}^{{2}}{+}{4}\right)}{{\mathrm{BesselJ}}{}\left({0}{,}{{\mathrm{λ}}}_{{n}}\right){}{{\mathrm{λ}}}_{{n}}^{{3}}}{,}{n}{=}{1}{..}{\mathrm{∞}}\right){,}\left\{{\mathrm{And}}{}\left({{\mathrm{λ}}}_{{n}}{=}{\mathrm{BesselJZeros}}{}\left({1}{,}{n}\right){,}{0}{<}{{\mathrm{λ}}}_{{n}}\right)\right\}\right)$ (17)

An example with the Laplace PDE, requesting a solution outside a disk of radius one via HINT = boundedseries(r = infinity):

 >
 $\mathrm{pde__6}{≔}\frac{\frac{{\partial }}{{\partial }{r}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}\right){+}{r}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{r}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}\right)\right)}{{r}}{+}\frac{\frac{{{\partial }}^{{2}}}{{\partial }{{\mathrm{\theta }}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}\right)}{{{r}}^{{2}}}{=}{0}$ (18)
 > $\mathrm{conds__6}≔u\left(1,\mathrm{\theta }\right)=f\left(\mathrm{\theta }\right),u\left(r,-\mathrm{\pi }\right)=u\left(r,\mathrm{\pi }\right),{\mathrm{D}}_{2}\left(u\right)\left(r,-\mathrm{\pi }\right)={\mathrm{D}}_{2}\left(u\right)\left(r,\mathrm{\pi }\right):$
 >
 ${u}{}\left({r}{,}{\mathrm{\theta }}\right){=}\frac{{2}{}\left({\sum }_{{n}{=}{1}}^{{\mathrm{\infty }}}{}\frac{\left(\left({{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right){}{\mathrm{sin}}{}\left({n}{}{\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}\right){}{\mathrm{sin}}{}\left({n}{}{\mathrm{\theta }}\right){+}\left({{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({n}{}{\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({n}{}{\mathrm{\theta }}\right)\right){}{{r}}^{{-}{n}}}{{\mathrm{\pi }}}\right){}{\mathrm{\pi }}{+}{{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}}{{2}{}{\mathrm{\pi }}}$ (19)

To obtain the solution inside the disk of radius one, we use HINT = boundedseries(r = 0):

 >
 ${u}{}\left({r}{,}{\mathrm{\theta }}\right){=}\frac{{2}{}\left({\sum }_{{n}{=}{1}}^{{\mathrm{\infty }}}{}\frac{{{r}}^{{n}}{}\left(\left({{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right){}{\mathrm{sin}}{}\left({n}{}{\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}\right){}{\mathrm{sin}}{}\left({n}{}{\mathrm{\theta }}\right){+}\left({{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({n}{}{\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}\right){}{\mathrm{cos}}{}\left({n}{}{\mathrm{\theta }}\right)\right)}{{\mathrm{\pi }}}\right){}{\mathrm{\pi }}{+}{{\int }}_{{-}{\mathrm{\pi }}}^{{\mathrm{\pi }}}{f}{}\left({\mathrm{\theta }}\right)\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{\theta }}}{{2}{}{\mathrm{\pi }}}$ (20) Generic method

Here, pdsolve first calculates the PDE's general solution, and then works to fit any initial or boundary conditions to it. Both examples below also illustrate that the method chosen can make a difference in the solution pdsolve returns:

 >
 $\mathrm{pde__7}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){+}\frac{{{\partial }}^{{2}}}{{\partial }{{y}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){=}{0}$ (21)
 > $\mathrm{conds__7}≔u\left(x,0\right)=\mathrm{Dirac}\left(x\right):$

When the Fourier method is specified, pdsolve returns:

 >
 ${u}{}\left({x}{,}{y}\right){=}{\mathrm{invfourier}}{}\left({{ⅇ}}^{{-}{s}{}{y}}{,}{s}{,}{x}\right)$ (22)

which we can convert to integral form:

 > $\mathrm{convert}\left(,\mathrm{Int}\right);$
 ${u}{}\left({x}{,}{y}\right){=}\frac{{{\int }}_{{-}{\mathrm{\infty }}}^{{\mathrm{\infty }}}{{ⅇ}}^{{-}{s}{}{y}{+}{I}{}{s}{}{x}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{s}}{{2}{}{\mathrm{\pi }}}$ (23)

When method = Generic is specified, pdsolve's solution includes an arbitrary function _F2:

 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__7},\mathrm{conds__7}\right],\mathrm{method}=\mathrm{Generic}\right)$
 ${u}{}\left({x}{,}{y}\right){=}{-}{\mathrm{_F2}}{}\left({-}{y}{+}{I}{}{x}\right){+}{\mathrm{\delta }}{}\left({x}{+}{I}{}{y}\right){+}{\mathrm{_F2}}{}\left({y}{+}{I}{}{x}\right)$ (24)

Here is another example in which the method that is chosen makes a difference in the solution obtained:

 >
 $\mathrm{pde__8}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{r}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}\right){+}\frac{{{\partial }}^{{2}}}{{\partial }{{\mathrm{\theta }}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({r}{,}{\mathrm{\theta }}\right){=}{0}$ (25)
 > $\mathrm{conds__8}≔u\left(2,\mathrm{\theta }\right)=3\mathrm{sin}\left(2\mathrm{\theta }\right)+1:$

With method = Generic, pdsolve returns:

 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__8},\mathrm{conds__8}\right],\mathrm{method}=\mathrm{Generic}\right)$
 ${u}{}\left({r}{,}{\mathrm{\theta }}\right){=}{1}{-}{\mathrm{_F2}}{}\left({\mathrm{\theta }}{-}{I}{}{r}{+}{4}{}{I}\right){-}{3}{}{\mathrm{sin}}{}\left({-}{2}{}{\mathrm{\theta }}{+}{2}{}{I}{}{r}{-}{4}{}{I}\right){+}{\mathrm{_F2}}{}\left({\mathrm{\theta }}{+}{I}{}{r}\right)$ (26)

With method = Fourier, pdsolve uses a Fourier transform to obtain:

 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__8},\mathrm{conds__8}\right],\mathrm{method}=\mathrm{Fourier}\right)$
 ${u}{}\left({r}{,}{\mathrm{\theta }}\right){=}\frac{{3}{}{I}{}{{ⅇ}}^{{2}{}{r}{-}{4}{-}{2}{}{I}{}{\mathrm{\theta }}}}{{2}}{-}\frac{{3}{}{I}{}{{ⅇ}}^{{-}{2}{}{r}{+}{4}{+}{2}{}{I}{}{\mathrm{\theta }}}}{{2}}{+}{1}$ (27) Integral Transforms (Laplace method, Fourier method)

Integral Transforms are used in infinite or semi-infinite spatial domain problems.

Laplace transforms act to change derivatives with respect to one of the independent variables of the domain into multiplication operations in the transformed domain. After applying a Laplace transform to the original problem, we can simplify the problem using the transformed BC, then solve the problem in the transformed domain, and finally apply the inverse Laplace transform to arrive at the final solution. It is important to remember to give pdsolve any necessary restrictions on the variables and constants of the problem, by means of the assuming command.

We can also tell pdsolve that the dependent variable is bounded, by means of the optional argument HINT = boundedseries.

Consider the problem of a falling cable lying on a table that is suddenly removed.

 >
 $\mathrm{pde__9}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{{c}}^{{2}}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)\right){-}{g}$ (28)
 >

To display special functions using textbook notation, enable the typesetting of mathematical functions:

 > $\mathrm{Typesetting}:-\mathrm{EnableTypesetRule}\left(\mathrm{Typesetting}:-\mathrm{SpecialFunctionRules}\right):$

If we ask pdsolve to solve this problem without the condition of boundedness of the solution, we obtain:

 >
 ${u}{}\left({x}{,}{t}\right){=}{-}\frac{{g}{}\left({-}{{x}}^{{2}}{+}\left(\left\{\begin{array}{cc}{2}{}{c}{}{t}{}{x}& {x}{<}{c}{}{t}\\ {{c}}^{{2}}{}{{t}}^{{2}}{+}{{x}}^{{2}}& {c}{}{t}{<}{x}\end{array}\right\\right)\right)}{{2}{}{{c}}^{{2}}}$ (29)

If we now ask for a bounded solution, by means of the option HINT = boundedseries, pdsolve simplifies the problem accordingly.

 >
 ${u}{}\left({x}{,}{t}\right){=}\frac{{g}{}\left({\mathrm{\theta }}{}\left({t}{-}\frac{{x}}{{c}}\right){}{\left({c}{}{t}{-}{x}\right)}^{{2}}{-}{{c}}^{{2}}{}{{t}}^{{2}}\right)}{{2}{}{{c}}^{{2}}}$ (30)

For Fourier transforms, the process is similar to that used in the Laplace transform method.

 >
 $\mathrm{pde__10}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){+}{m}$ (31)
 > $\mathrm{conds__10}≔u\left(x,0\right)=\mathrm{sin}\left(x\right):$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__10},\mathrm{conds__10}\right]\right)$
 ${u}{}\left({x}{,}{t}\right){=}{\mathrm{sin}}{}\left({x}\right){}{{ⅇ}}^{{-}{t}}{+}{m}{}{t}$ (32)

A third order PDE problem:

 >
 $\mathrm{pde__11}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{-}\frac{{{\partial }}^{{3}}}{{\partial }{{x}}^{{3}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)$ (33)
 > $\mathrm{conds__11}≔u\left(x,0\right)=f\left(x\right):$
 >
 ${u}{}\left({x}{,}{t}\right){=}\frac{{{\int }}_{{-}{\mathrm{\infty }}}^{{\mathrm{\infty }}}\frac{{4}{}{\mathrm{\pi }}{}{f}{}\left({-}{\mathrm{ζ}}\right){}\sqrt{{-}\frac{{x}{+}{\mathrm{ζ}}}{{\left({-}{t}\right)}^{{1}}{{3}}}}}{}{{K}}_{\frac{{1}}{{3}}}{}\left({-}\frac{{2}{}\sqrt{{3}}{}\left({x}{+}{\mathrm{ζ}}\right){}\sqrt{{-}\frac{{x}{+}{\mathrm{ζ}}}{{\left({-}{t}\right)}^{{1}}{{3}}}}}}{{9}{}{\left({-}{t}\right)}^{{1}}{{3}}}}\right)}{{3}{}{\left({-}{t}\right)}^{{1}}{{3}}}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{ⅆ}{\mathrm{ζ}}}{{4}{}{{\mathrm{\pi }}}^{{2}}}$ (34) Linear Differential Operator method

This method is for problems of the form

or

where M is an arbitrary linear differential operator of any order which only depends on the spatial variables $\left(\mathrm{x__i}\right)$.

 >
 $\mathrm{pde__12}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right){=}\frac{{{\partial }}^{{2}}}{{\partial }{\mathrm{x1}}{\partial }{\mathrm{x2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right){+}\frac{{{\partial }}^{{2}}}{{\partial }{\mathrm{x1}}{\partial }{\mathrm{x3}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right){+}\frac{{{\partial }}^{{2}}}{{\partial }{{\mathrm{x3}}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right){-}\frac{{{\partial }}^{{2}}}{{\partial }{\mathrm{x2}}{\partial }{\mathrm{x3}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right)$ (35)
 >
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__12},\mathrm{conds__12}\right]\right)$
 ${w}{}\left({\mathrm{x1}}{,}{\mathrm{x2}}{,}{\mathrm{x3}}{,}{t}\right){=}\frac{{{t}}^{{4}}{}{\mathrm{x1}}}{{2}}{+}{{t}}^{{2}}{}{{\mathrm{x1}}}^{{3}}{+}{3}{}{{t}}^{{2}}{}{{\mathrm{x1}}}^{{2}}{}{\mathrm{x3}}{+}{{\mathrm{x1}}}^{{3}}{}{{\mathrm{x3}}}^{{2}}{+}\frac{{{t}}^{{3}}}{{6}}{-}{\mathrm{x2}}{}{\mathrm{x3}}{}{t}{+}{\mathrm{cos}}{}\left({\mathrm{x1}}\right){}{t}{+}{\mathrm{sin}}{}\left({\mathrm{x1}}\right)$ (36) SpecializeArbitraryFunctions method

This method is for solving the Cauchy problem for hyperbolic PDE in unbounded domains, including cases where there are different types of sources as well as functions in the initial conditions.

 >
 $\mathrm{pde__13}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){-}{4}{}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{f}{}\left({a}\right)$ (37)
 >
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__13},\mathrm{conds__13}\right]\right);$
 ${u}{}\left({x}{,}{t}\right){=}\frac{{f}{}\left({a}\right){}{{t}}^{{2}}}{{2}}{+}\frac{{4}{}{{t}}^{{3}}}{{3}}{+}{t}{}{{x}}^{{2}}$ (38) Polynomial Solutions method

This method gives pdsolve better performance to find polynomial solutions to PDE & BC problems when they exist.

 >
 $\mathrm{pde__14}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){+}{y}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{y}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right)\right){=}{0}$ (39)
 > $\mathrm{conds__14}≔u\left(x,0\right)=0,{\mathrm{D}}_{2}\left(u\right)\left(x,0\right)={x}^{2}:$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__14},\mathrm{conds__14}\right],u\left(x,y\right)\right)$
 ${u}{}\left({x}{,}{y}\right){=}{y}{}\left({{x}}^{{2}}{-}{y}\right)$ (40)

An example with a system of PDE & BC for which pdsolve does not find a solution using the default maximum degree 10 for linear PDE.

 >
 $\mathrm{sys__15}{≔}\frac{{\partial }}{{\partial }{y}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){=}{-}\frac{{\partial }}{{\partial }{x}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{v}{}\left({x}{,}{y}\right){,}\frac{{\partial }}{{\partial }{x}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){=}\frac{{\partial }}{{\partial }{y}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{v}{}\left({x}{,}{y}\right)$ (41)
 > $\mathrm{conds__15}≔u\left(x,0\right)={x}^{11},v\left(x,0\right)=0:$
 > $\mathrm{pdsolve}\left(\left[\mathrm{sys__15},\mathrm{conds__15}\right],\mathrm{method}=\mathrm{PolynomialSolutions}\right)$

The degree seen in the initial conditions is given below to find a solution:

 >
 $\left\{{u}{}\left({x}{,}{y}\right){=}{{x}}^{{11}}{-}{55}{}{{y}}^{{2}}{}{{x}}^{{9}}{+}{330}{}{{y}}^{{4}}{}{{x}}^{{7}}{-}{462}{}{{y}}^{{6}}{}{{x}}^{{5}}{+}{165}{}{{y}}^{{8}}{}{{x}}^{{3}}{-}{11}{}{{y}}^{{10}}{}{x}{,}{v}{}\left({x}{,}{y}\right){=}{11}{}{y}{}{{x}}^{{10}}{-}{165}{}{{y}}^{{3}}{}{{x}}^{{8}}{+}{462}{}{{y}}^{{5}}{}{{x}}^{{6}}{-}{330}{}{{y}}^{{7}}{}{{x}}^{{4}}{+}{55}{}{{y}}^{{9}}{}{{x}}^{{2}}{-}{{y}}^{{11}}\right\}$ (42) Superposition method

This method is for linear homogeneous PDE problems with non-periodic initial and boundary conditions, more than one of which is non-homogeneous.

The superposition method works by taking advantage of the linearity of the problem and the fact that the solution to such a problem in which two or more of the BC are non-homogeneous can be given as

u = $\mathrm{u__1}+\mathrm{u__2}$ + ...,  where each $\mathrm{u__i}$ is a solution of the PDE with all but one of the BC homogenized.

A Laplace PDE with one homogeneous and three non-homogeneous conditions:

 >
 $\mathrm{pde__16}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){+}\frac{{{\partial }}^{{2}}}{{\partial }{{y}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{y}\right){=}{0}$ (43)
 > $\mathrm{conds__16}≔u\left(0,y\right)=0,u\left(\mathrm{\pi },y\right)=\mathrm{sinh}\left(\mathrm{\pi }\right)\mathrm{cos}\left(y\right),u\left(x,0\right)=\mathrm{sin}\left(x\right),u\left(x,\mathrm{\pi }\right)=-\mathrm{sinh}\left(x\right):$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__16},\mathrm{conds__16}\right]\right)$
 ${u}{}\left({x}{,}{y}\right){=}\frac{\left({{ⅇ}}^{{2}{}{\mathrm{\pi }}}{-}{1}\right){}\left({\sum }_{{n}{=}{1}}^{{\mathrm{\infty }}}{}\frac{{\left({-1}\right)}^{{n}}{}{n}{}\left({{ⅇ}}^{{2}{}{\mathrm{\pi }}}{-}{1}\right){}{{ⅇ}}^{{n}{}\left({\mathrm{\pi }}{-}{y}\right){-}{\mathrm{\pi }}}{}{\mathrm{sin}}{}\left({n}{}{x}\right){}\left({{ⅇ}}^{{2}{}{n}{}{y}}{-}{1}\right)}{{\mathrm{\pi }}{}\left({{n}}^{{2}}{+}{1}\right){}\left({{ⅇ}}^{{2}{}{\mathrm{\pi }}{}{n}}{-}{1}\right)}\right){+}\left({{ⅇ}}^{{2}{}{\mathrm{\pi }}}{-}{1}\right){}\left({\sum }_{{n}{=}{2}}^{{\mathrm{\infty }}}{}\frac{{2}{}{\mathrm{sin}}{}\left({n}{}{y}\right){}{{ⅇ}}^{{n}{}\left({\mathrm{\pi }}{-}{x}\right)}{}{\mathrm{sinh}}{}\left({\mathrm{\pi }}\right){}{n}{}\left({\left({-1}\right)}^{{n}}{+}{1}\right){}\left({{ⅇ}}^{{2}{}{n}{}{x}}{-}{1}\right)}{{\mathrm{\pi }}{}\left({{ⅇ}}^{{2}{}{\mathrm{\pi }}{}{n}}{-}{1}\right){}\left({{n}}^{{2}}{-}{1}\right)}\right){+}{\mathrm{sin}}{}\left({x}\right){}\left({-}{{ⅇ}}^{{y}}{+}{{ⅇ}}^{{-}{y}{+}{2}{}{\mathrm{\pi }}}\right)}{{{ⅇ}}^{{2}{}{\mathrm{\pi }}}{-}{1}}$ (44) Heat method

This method applies to heat PDE, with or without a source, in semi-infinite domains.

A heat PDE in a semi-bounded domain; note the conditions require a linear change of variables before the method can be applied.

 >
 $\mathrm{pde__17}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}\frac{\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)}{{4}}$ (45)
 > $\mathrm{conds__17}≔{\mathrm{D}}_{1}\left(u\right)\left(\mathrm{\alpha },t\right)=0,u\left(x,\mathrm{\beta }\right)=10\mathrm{exp}\left(-{x}^{2}\right):$
 >
 ${u}{}\left({x}{,}{t}\right){=}{-}\frac{{5}{}\left(\left({\mathrm{erf}}{}\left(\frac{\left({t}{-}{\mathrm{\beta }}{-}{1}\right){}{\mathrm{\alpha }}{+}{x}}{\sqrt{{t}{-}{\mathrm{\beta }}}{}\sqrt{{t}{-}{\mathrm{\beta }}{+}{1}}}\right){-}{1}\right){}{{ⅇ}}^{\frac{{4}{}{\mathrm{\alpha }}{}\left({-}{x}{+}{\mathrm{\alpha }}\right)}{{-}{t}{+}{\mathrm{\beta }}{-}{1}}}{+}{\mathrm{erf}}{}\left(\frac{\left({t}{-}{\mathrm{\beta }}{+}{1}\right){}{\mathrm{\alpha }}{-}{x}}{\sqrt{{t}{-}{\mathrm{\beta }}}{}\sqrt{{t}{-}{\mathrm{\beta }}{+}{1}}}\right){-}{1}\right){}{{ⅇ}}^{\frac{{{x}}^{{2}}}{{-}{t}{+}{\mathrm{\beta }}{-}{1}}}}{\sqrt{{t}{-}{\mathrm{\beta }}{+}{1}}}$ (46) Wave method

This method applies to wave PDE, with or without a source, in semi-infinite domains.

A wave PDE in a semi-bounded domain:

 >
 $\mathrm{pde__18}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){-}{9}{}\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{0}$ (47)
 > $\mathrm{conds__18}≔{\mathrm{D}}_{1}\left(u\right)\left(0,t\right)=0,u\left(x,0\right)=0,{\mathrm{D}}_{2}\left(u\right)\left(x,0\right)={x}^{3}:$
 >
 ${u}{}\left({x}{,}{t}\right){=}\frac{\left(\left\{\begin{array}{cc}{108}{}{{t}}^{{3}}{}{x}{+}{12}{}{t}{}{{x}}^{{3}}& {3}{}{t}{<}{x}\\ {81}{}{{t}}^{{4}}{+}{54}{}{{t}}^{{2}}{}{{x}}^{{2}}{+}{{x}}^{{4}}& {x}{<}{3}{}{t}\end{array}\right\\right)}{{12}}$ (48)

A wave PDE in a semi-bounded domain with non-homogeneous conditions:

 > $\mathrm{pde__19}≔\frac{{\partial }^{2}}{\partial {t}^{2}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}u\left(x,t\right)={c}^{2}\left(\frac{{\partial }^{2}}{\partial {x}^{2}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}u\left(x,t\right)\right)$
 $\mathrm{pde__19}{≔}\frac{{{\partial }}^{{2}}}{{\partial }{{t}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{{c}}^{{2}}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)\right)$ (49)
 > $\mathrm{conds__19}≔u\left(x,0\right)={\mathrm{sin}\left(x\right)}^{3},{\mathrm{D}}_{2}\left(u\right)\left(x,0\right)=1-{ⅇ}^{-\frac{1}{10}x},{\mathrm{D}}_{1}\left(u\right)\left(0,t\right)=1:$
 >
 ${u}{}\left({x}{,}{t}\right){=}\frac{\left\{\begin{array}{cc}{{\mathrm{sin}}{}\left({c}{}{t}{+}{x}\right)}^{{3}}{}{c}{-}{{\mathrm{sin}}{}\left({c}{}{t}{-}{x}\right)}^{{3}}{}{c}{+}{2}{}{c}{}{t}{-}{10}{}{{ⅇ}}^{\frac{{c}{}{t}}{{10}}{-}\frac{{x}}{{10}}}{+}{10}{}{{ⅇ}}^{{-}\frac{{c}{}{t}}{{10}}{-}\frac{{x}}{{10}}}& {c}{}{t}{<}{x}\\ {10}{}{{ⅇ}}^{{-}\frac{{c}{}{t}}{{10}}{-}\frac{{x}}{{10}}}{+}{10}{}{{ⅇ}}^{{-}\frac{{c}{}{t}}{{10}}{+}\frac{{x}}{{10}}}{+}{{\mathrm{sin}}{}\left({c}{}{t}{-}{x}\right)}^{{3}}{}{c}{+}{{\mathrm{sin}}{}\left({c}{}{t}{+}{x}\right)}^{{3}}{}{c}{-}{20}{-}{2}{}{{c}}^{{2}}{}{t}{+}\left({2}{}{t}{+}{2}{}{x}\right){}{c}& {x}{<}{c}{}{t}\end{array}\right\}{{2}{}{c}}$ (50) Sturm-Liouville problem with eigenvalues that are the roots of algebraic expressions which cannot be inverted

When using the Fourier Series method, explained above, there are times when the eigenvalue(s) are roots of an algebraic expression whose inversion cannot be expressed using known mathematical functions.

As an example, consider a problem representing the temperature distribution in a thin rod whose lateral surface is insulated over the interval $0, with the left end of the rod insulated and the right end experiencing a convection heat loss, as explained in Articolo's example 3.6.4 (see References below)

 >
 $\mathrm{pde__20}{≔}\frac{{\partial }}{{\partial }{t}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right){=}{k}{}\left(\frac{{{\partial }}^{{2}}}{{\partial }{{x}}^{{2}}}\phantom{\rule[-0.0ex]{0.4em}{0.0ex}}{u}{}\left({x}{,}{t}\right)\right)$ (51)
 > $\mathrm{conds__20}≔u\left(x,0\right)=1-\frac{1}{4}{x}^{3},{\mathrm{D}}_{1}\left(u\right)\left(0,t\right)=0,{\mathrm{D}}_{1}\left(u\right)\left(1,t\right)+u\left(1,t\right)=0:$
 > $\mathrm{pdsolve}\left(\left[\mathrm{pde__20},\mathrm{conds__20}\right]\right)$
 ${u}{}\left({x}{,}{t}\right){=}{\mathrm{casesplit/ans}}{}\left({\mathrm{Sum}}{}\left(\frac{{3}{}{\mathrm{exp}}{}\left({-}{k}{}{{\mathrm{λ}}}_{{n}}^{{2}}{}{t}\right){}\left(\left({-}{{\mathrm{λ}}}_{{n}}^{{2}}{+}{2}\right){}{\mathrm{cos}}{}\left({{\mathrm{λ}}}_{{n}}\right){-}{2}{+}\left({{\mathrm{λ}}}_{{n}}^{{3}}{+}{2}{}{{\mathrm{λ}}}_{{n}}\right){}{\mathrm{sin}}{}\left({{\mathrm{λ}}}_{{n}}\right)\right){}{\mathrm{cos}}{}\left({{\mathrm{λ}}}_{{n}}{}{x}\right)}{{{\mathrm{λ}}}_{{n}}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{λ}}}_{{n}}\right){+}{2}{}{{\mathrm{λ}}}_{{n}}\right)}{,}{n}{=}{0}{..}{\mathrm{∞}}\right){,}\left\{{\mathrm{And}}{}\left({\mathrm{tan}}{}\left({{\mathrm{λ}}}_{{n}}\right){}{{\mathrm{λ}}}_{{n}}{-}{1}{=}{0}{,}{0}{<}{{\mathrm{λ}}}_{{n}}\right)\right\}\right)$ (52)

 >
 ${\mathrm{solution}}{≔}{u}{}\left({x}{,}{t}\right){=}{\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{{3}{}{{ⅇ}}^{{-}{k}{}{{\mathrm{\lambda }}}_{{n}}^{{2}}{}{t}}{}\left(\left({-}{{\mathrm{\lambda }}}_{{n}}^{{2}}{+}{2}\right){}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){-}{2}{+}\left({{\mathrm{\lambda }}}_{{n}}^{{3}}{+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right){}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right)\right){}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}{}{x}\right)}{{{\mathrm{\lambda }}}_{{n}}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{\lambda }}}_{{n}}\right){+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right)}$ (53)
 > $\mathrm{op}\left(\left[2,2,1,1\right],\right)$
 ${\mathrm{tan}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{\mathrm{\lambda }}}_{{n}}{-}{1}{=}{0}$ (54)

By inspection, solution has $\mathrm{sin}\left({\mathrm{\lambda }}_{n}\right)$ and $\mathrm{cos}\left({\mathrm{\lambda }}_{n}\right)$, not $\mathrm{tan}\left({\mathrm{\lambda }}_{n}\right)$; we rewrite equation (54) and isolate $\mathrm{cos}\left({\mathrm{\lambda }}_{n}\right)$:

 >
 ${\mathrm{condition}}{≔}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){=}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{\mathrm{\lambda }}}_{{n}}$ (55)

Substitute now this condition in the solution and start by pdetesting

 >
 $\left[{0}{,}\left({\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{\left({12}{}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{\mathrm{\lambda }}}_{{n}}{-}{6}\right){}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}{}{x}\right)}{{{\mathrm{\lambda }}}_{{n}}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{\lambda }}}_{{n}}\right){+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right)}\right){-}{1}{+}\frac{{{x}}^{{3}}}{{4}}{,}{0}{,}\left({\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{\left({-}{12}{}{{\mathrm{\lambda }}}_{{n}}{}{{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right)}^{{2}}{+}{6}{}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right)\right){}{{ⅇ}}^{{-}{k}{}{{\mathrm{\lambda }}}_{{n}}^{{2}}{}{t}}}{{{\mathrm{\lambda }}}_{{n}}^{{2}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{\lambda }}}_{{n}}\right){+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right)}\right){+}\left({\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{\left({12}{}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{\mathrm{\lambda }}}_{{n}}{-}{6}\right){}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{ⅇ}}^{{-}{k}{}{{\mathrm{\lambda }}}_{{n}}^{{2}}{}{t}}}{{{\mathrm{\lambda }}}_{{n}}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{\lambda }}}_{{n}}\right){+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right)}\right)\right]$ (56)

A further manipulation, substituting condition and combining the sums, results in

 > $\mathrm{simplify}\left(\mathrm{combine}\left(\mathrm{subs}\left(\mathrm{condition},\right),\mathrm{Sum}\right)\right)$
 $\left[{0}{,}\left({\sum }_{{n}{=}{0}}^{{\mathrm{\infty }}}{}\frac{\left({12}{}{\mathrm{sin}}{}\left({{\mathrm{\lambda }}}_{{n}}\right){}{{\mathrm{\lambda }}}_{{n}}{-}{6}\right){}{\mathrm{cos}}{}\left({{\mathrm{\lambda }}}_{{n}}{}{x}\right)}{{{\mathrm{\lambda }}}_{{n}}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{{\mathrm{\lambda }}}_{{n}}\right){+}{2}{}{{\mathrm{\lambda }}}_{{n}}\right)}\right){-}{1}{+}\frac{{{x}}^{{3}}}{{4}}{,}{0}{,}{0}\right]$ (57)

So the PDE and two of the conditions are satisfied without having to specify who is $\mathrm{λ__n}$ - it sufficed to use $\mathrm{cos}\left({\mathrm{\lambda }}_{n}\right)=\mathrm{sin}\left({\mathrm{\lambda }}_{n}\right){\mathrm{\lambda }}_{n}$, and this is the case of most of the problems we analyzed: the exact closed form of $\mathrm{λ__n}$ is really not needed in these examples.

For the one expression which remains to be proved equal to zero, there is no clear way to perform the sum and show that it is equal to $\left(1-\frac{{x}^{3}}{4}\right)$ without further information on the value of $\mathrm{λ__n}$.  So this part must be tested using a plot.

Now, perform the summation using, say, the first 100 terms of the series; for that purpose, the first 100 positive values of are needed. These values can be obtained using fsolve. Increase Digits to get a better approximation:

 >
 >

For convenience, construct a procedure, as a function of n, that returns each of these values:

 >
 ${\mathrm{\Lambda }}{≔}{n}{↦}{\mathbf{if}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{n}{::}{'}{\mathrm{nonnegint}}{'}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{then}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{{L}}_{{n}{+}{1}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{else}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}'{\mathrm{\Lambda }}{}\left({\mathrm{args}}\right)'\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{end}}\phantom{\rule[-0.0ex]{0.3em}{0.0ex}}{\mathbf{if}}$ (58)

Replace $\mathrm{λ__n}$ by infinity by 99 and the expression to be plotted is

 >
 ${\mathrm{remain}}{≔}\left({\sum }_{{n}{=}{0}}^{{99}}{}\frac{\left({12}{}{\mathrm{sin}}{}\left({\mathrm{\Lambda }}{}\left({n}\right)\right){}{\mathrm{\Lambda }}{}\left({n}\right){-}{6}\right){}{\mathrm{cos}}{}\left({\mathrm{\Lambda }}{}\left({n}\right){}{x}\right)}{{{\mathrm{\Lambda }}{}\left({n}\right)}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{\mathrm{\Lambda }}{}\left({n}\right)\right){+}{2}{}{\mathrm{\Lambda }}{}\left({n}\right)\right)}\right){-}{1}{+}\frac{{{x}}^{{3}}}{{4}}$ (59)

Perform the sum and plot. The plotting range is the one present in the $\mathrm{conds__20}$, x from 0 to 1:

 >
 > $\mathrm{plot}\left(R,x=0..1\right)$ With the first 100 terms (constructed using the first 100 roots of $\mathrm{tan}\left({\mathrm{\lambda }}_{n}\right){\mathrm{\lambda }}_{n}-1=0$) we verified that the last of the four testing conditions is sufficiently close to zero, and this concludes the verification.

To plot the solution, the idea is the same: in solution, give a value to k, say k = 1/5, and then construct the sum of the first 100 terms as done in remain, but this time using solution instead of the pdetest result.

 >
 ${u}{}\left({x}{,}{t}\right){=}{\sum }_{{n}{=}{0}}^{{99}}{}\frac{{3}{}{{ⅇ}}^{{-}\frac{{{\mathrm{\Lambda }}{}\left({n}\right)}^{{2}}{}{t}}{{5}}}{}\left(\left({-}{{\mathrm{\Lambda }}{}\left({n}\right)}^{{2}}{+}{2}\right){}{\mathrm{cos}}{}\left({\mathrm{\Lambda }}{}\left({n}\right)\right){-}{2}{+}\left({{\mathrm{\Lambda }}{}\left({n}\right)}^{{3}}{+}{2}{}{\mathrm{\Lambda }}{}\left({n}\right)\right){}{\mathrm{sin}}{}\left({\mathrm{\Lambda }}{}\left({n}\right)\right)\right){}{\mathrm{cos}}{}\left({\mathrm{\Lambda }}{}\left({n}\right){}{x}\right)}{{{\mathrm{\Lambda }}{}\left({n}\right)}^{{3}}{}\left({\mathrm{sin}}{}\left({2}{}{\mathrm{\Lambda }}{}\left({n}\right)\right){+}{2}{}{\mathrm{\Lambda }}{}\left({n}\right)\right)}$ (60)
 >
 > Compare with the numerical solution one could obtain using pdsolve with the numeric option. Substitute $k=\frac{1}{5}$in $\mathrm{pde__20}$, and construct the corresponding plot:

 >
 ${\mathrm{numerical_solution}}{≔}{\mathbf{module}}\left({}\right)\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{...}\phantom{\rule[-0.0ex]{0.5em}{0.0ex}}{\mathbf{end}}$ (61)
 > $\mathrm{numerical_solution}:-\mathrm{plot3d}\left(t=0..1,x=0..1\right)$ > References

 • Articolo, George A. Partial Differential Equations and Boundary Value Problems with Maple. 2nd ed., Elsevier Academic Press, 2009.
 • Logan, David J. Applied Partial Differential Equations. 3rd ed., Springer, 2015.
 • Pinchover, Y. and Rubinstein, J.. An Introduction to Partial Differential Equations. Cambridge UP, 2005.
 • Polyanin, Andrei D. Handbook of Linear Partial Differential Equations for Engineers and Scientists. Chapman & Hall/CRC, 2002. Compatibility For more information on Maple 2019 changes, see Updates in Maple 2019.