Linear BVPsTo begin, consider the boundary value problem for a linear first-order ODE. This is the linear first-order ODE. In[365]:=  |
Notice that the general solution is a linear function of the arbitrary constant C[1]. In[366]:=  |
Out[366]=
|
This finds a particular solution for the initial condition . In[367]:=  |
Out[367]=
|
This verifies that the solution satisfies both the equation and the initial condition. In[368]:=  |
Out[368]=
|
In[369]:=  |
Out[369]=
|
Here is the solution to the same problem with the general initial condition . In[370]:=  |
Out[370]=
|
This plots several integral curves of the equation for different values of a. The plot shows that the solutions have an inflection point if the parameter a lies between -1 and 1, while a global maximum or minimum arises for other values of a. In[371]:=  |
Here is the solution to a linear second-order equation with initial values prescribed for and at . In[372]:=  |
In[373]:=  |
Out[373]=
|
In[374]:=  |
Out[374]=
|
This verifies that the solution satisfies the equation and the initial conditions. In[375]:=  |
Out[375]=
|
In[376]:=  |
Out[376]=
|
In[377]:=  |
Out[377]=
|
Here is a plot of the solution. In[378]:=  |
To get more information about the solutions for the problem, set . In[379]:=  |
Out[379]=
|
Here is a plot of the solutions for different initial directions. The solution approaches - or as t -> - according to whether the value of x0 is less than or greater than -2, which is the largest root of the auxiliary equation for the ODE. In[380]:=  |
Here is a BVP for an inhomogeneous linear second-order equation. In[381]:=  |
In[382]:=  |
Out[382]=
|
In[383]:=  |
Out[383]=
|
It should be noted that there are no general existence or uniqueness theorems when boundary values are prescribed, and there may be no solution in some cases. This problem has no solution because the term with C[2] in the general solution vanishes at both and . Hence there are two inconsistent conditions for the parameter C[1] and the solution is an empty set. In[384]:=  |
Out[384]=
|
The previous discussion of linear equations generalizes to the case of higher-order linear ODEs and linear systems of ODEs. Here is the solution to an IVP for a linear ODE of order four. In[385]:=  |
In[386]:=  |
Out[386]=
|
This verifies the solution and the initial conditions. In[387]:=  |
Out[387]=
|
Since this is a fourth-order ODE, four independent conditions must be specified to find a particular solution for an IVP. If there is an insufficient number of conditions, the solution returned by DSolve may contain some of the arbitrary parameters, as follows. In[388]:=  |
Out[388]=
|
Finally, here is the solution of an IVP for a linear system of ODEs. In[389]:=  |
In[390]:=  |
In[391]:=  |
In[392]:=  |
Out[392]=
|
This verifies that the solution satisfies the system and the initial conditions. In[393]:=  |
Out[393]=
|
The solutions , , and are parametrized by the variable and can be plotted separately in the plane or as a curve in space. In[394]:=  |
In[395]:=  |
|