DEtools[polysols] - find polynomial solutions of a linear ODE
|
Calling Sequence
|
|
polysols(ODE, v, opts)
polysols(coeff_list, g, x, output=solution)
|
|
Parameters
|
|
ODE
|
-
|
ordinary differential equation - linear or not - or a set or list of them
|
v
|
-
|
optional - the unknown function of the ODE, or a set or list of them in the case of an ODE system
|
coeff_list
|
-
|
list of coefficients of a Linear ODE, or list of lists in the case of a Linear ODE system
|
g
|
-
|
right-hand side of a Linear ODE or a list of them in the case of a Linear ODE system
|
x
|
-
|
independent variable of a Linear ODE or system of them
|
output = solution
|
-
|
optional, for Linear ODEs, the output is returned as a solution expression, as dsolve does
|
opts
|
-
|
optional, for Non-Linear ODEs and systems of them, could be any of the optional arguments accepted by casesplit
|
|
|
|
|
Description
|
|
•
|
The polysols command returns polynomial solutions of an ODE or a system of them with rational function coefficients.
|
•
|
The first calling sequence has an ODE or a system of them as the first argument, and, optionally, a variable, set or list of them indicating who are the unknown functions as the second argument - say v. If v is not given, all differentiated functions found in ODE are taken as the unknown functions of the problem. In the case of Non-Linear ODE systems, v can also be a solving ranking as described in casesplit and any of the optional arguments accepted by the casesplit command are valid for polysols.
|
•
|
The second calling sequence is valid only for Linear ODEs and is described as follows.
|
|
Case of a single Linear ODE
|
|
- The first argument is the list of coefficients
|
|
entering the ODE, say, in y(x),
|
|
- The second argument is the right-hand side of such an equation, g(x), so-called non-homogeneous term;
|
|
- The third argument is the independent variable of the ODE, say x.
|
•
|
The output is a list of independent polynomial solutions representing a solution basis. If the ODE admits as many polynomial solutions as the differential order, the basis returned is complete. In the nonhomogeneous case, the returned value is a two-element list, with the first element a basis for the homogeneous case and the second element a particular polynomial solution (if it exists). When the optional argument output=solution is given, the output is an explicit closed form solution as the ones returned by dsolve.
|
|
Case of a system of Linear ODEs
|
|
- The first argument is a list of list(s) where each inner list corresponds to one equation in the system; in turn this list contains list(s) of the coefficients corresponding to each function and its derivatives in the linear ODE system, as explained in the previous paragraph for a single Linear ODE. For example, suppose a system with unknowns , this shows the correspondence between the list and function representations in typical cases (see also the examples at the end)
|
|
- The second argument is a list containing the right-hand sides of each equation of the system
|
|
- The third argument is the independent variable of the Linear ODE system
|
•
|
The output consists of a list of solution basis corresponding to each function. When no polynomial solutions exist for one function, the corresponding list is empty. In the nonhomogeneous case, the output consists of a two-element list, with the first element a list of lists of solution basis for the homogeneous case and the second element a particular polynomial solution (if it exists). When the optional argument output=solution is given, the output is an explicit closed form solution as the ones returned by dsolve, enclosed into a list.
|
•
|
The polysols command is implemented as a module and provides direct access to each of its subroutines. These subroutines are of use as programmer entry points by shortcutting the identification of the type of problem and testing of arguments for correctness, e.g., when you know a priori what the type of problem is, and are sure that test for correctness of arguments is not necessary. For each type of problem you can use the corresponding subroutine as follows.
|
|
- Problem: an ODE system, Linear or not, represented by standard equations. Subroutine: `DEtools/polysols`:-ODESystem
|
|
- Problem: a Linear ODE system represented by a list of lists of lists. Subroutine: `DEtools/polysols`:-ODESystemList
|
|
- Problem: a single ODE, Linear or not, represented by an equation or algebraic expression: `DEtools/polysols`:-ODE
|
|
- Problem: switch the output from a list consisting of a solution basis to the standard solution form used by dsolve. Subroutine: `DEtools/polysols`:-FormatOutput
|
•
|
In order to find solutions:
|
|
- In the single Linear ODE case, polysols uses its own optimized code;
|
|
- In the case of a Non-Linear ODE or a system of them, polysols uses the libraries for computing traveling wave solutions for autonomous PDE systems.
|
|
|
Examples
|
|
>
|
|
|
Linear ODEs
|
|
>
|
|
| (1) |
>
|
|
| (2) |
|
The same result can be obtained using the programmer's entry point, `DEtools/polysols`:-ODE(ode, z(t)), which shortcuts the identification of the type of problem and avoids spending time testing the arguments for correctness.
|
|
Same problem but using the optional argument output = solution
|
>
|
|
| (3) |
|
Adding a non-homogeneous term
|
>
|
|
| (4) |
>
|
|
| (5) |
|
The same Linear ODE but given as a list of coefficients (see DEtools[convertAlg]), with the right-hand-side (non-homogeneous term) passed as second argument to polysols
|
>
|
|
| (6) |
>
|
|
| (7) |
|
When giving a Linear ODE system, the number of equations and unknowns must be the same. The default format for the output is a list of polynomial solution basis for each function
|
>
|
|
| (8) |
>
|
|
| (9) |
>
|
|
| (10) |
|
The same result can be obtained using the corresponding programmer's entry point, `DEtools/polysols`:-ODESystem(sys, vars).
|
|
The equivalent closed form solution using the output = solution option
|
>
|
|
| (11) |
|
The same Linear ODE system given as a list of lists of lists
|
>
|
|
| (12) |
>
|
|
| (13) |
|
Using polysols to reduce the order of an ODE: combining the functionality of various DEtools commands
|
|
Consider the list of four infinitesimals for symmetry generators of the form (see symgen)
|
>
|
|
| (14) |
>
|
|
| (15) |
|
For the purpose of using polysols in this example, we remove here the arbitrary non-homogeneous and non-rational term
|
>
|
|
| (16) |
|
Compute the polynomial solutions
|
>
|
|
| (17) |
|
Since this ODE is of fourth order and there are only three polynomial solutions, the above is not sufficient to construct the most general solution for ode. However, each ODE solution leads to a reduction of order (see DEtools[reduce_order]), so using the polynomial solutions above we can reduce the order by three
|
>
|
|
| (18) |
|
In above we see an ODESolStructure where the solving of the original fourth order ODE problem is reduced to the solving of one first order linear ODE in
|
>
|
|
| (19) |
|
You can also request to reduce_order to automatically attempt integrating that remaining ODE using the option output = solution
|
>
|
|
| (20) |
>
|
|
| (21) |
|
In the solution above we see the four solutions used to construct the problem, three of which are polynomial and were used to reduce the problem from a fourth order ODE to a first order one.
|
|
|
Non-Linear ODEs
|
|
|
A nonlinear fourth order equation, a constant and two linear solutions for it
|
>
|
|
| (22) |
>
|
|
| (23) |
|
Solutions can be tested as usual with odetest
|
>
|
|
| (24) |
|
Using the optional argument singsol=false, the singular cases (in this example: the constant solution) are not computed
|
>
|
|
| (25) |
|
A nonlinear seventh order equation depending on three parameters and polynomial solutions for it taking these parameters as solving variables:
|
>
|
|
| (26) |
>
|
|
| (27) |
>
|
|
| (28) |
>
|
|
| (29) |
>
|
|
| (30) |
>
|
|
|
Set the infolevel to 1 to see basic information on the computation of a non-singular polynomial solutions for it
|
>
|
|
| (31) |
>
|
|
* Power series solution [1]: {u(t) = A[1,0]+A[1,1]*t+A[1,2]*t^2, v(t) = A[2,0]+A[2,1]*t, w(t) = A[3,0]+A[3,1]*t+A[3,2]*t^2+A[3,3]*t^3+A[3,4]*t^4}, splitting into cases with respect to the parameters {a, b}
* Power series solution [2]: {u(t) = A[1,0]+A[1,1]*t+A[1,2]*t^2, v(t) = A[2,0]+A[2,1]*t+A[2,2]*t^2, w(t) = A[3,0]+A[3,1]*t}, splitting into cases with respect to the parameters {a, b}
| |
| (32) |
|
To see the whole set of solutions including the singular ones try the input above without singsol=false.
|
|
|
|