WOLFRAM|DEMONSTRATIONS PROJECT

Series Solution of a Cauchy-Euler Equation

​
number of terms in each series
2
maximum for range of independent variable x
10
DSolve
:0.000204286 cannot be used as a variable.
ReplaceAll
:DSolve1.0002y[0.000204286]-0.000204286
′
y
[0.000204286]+8.34653×
-8
10
′′
y
[0.000204286]0,
′
y
[1]0,y[1]1,{
′
y
[0.000204286],y[0.000204286]},0.000204286 is neither a list of replacement rules nor a valid dispatch table, and so cannot be used for replacing.
DSolve
:0.000204286 cannot be used as a variable.
ReplaceAll
:DSolve1.0002y[0.000204286]-0.000204286
′
y
[0.000204286]+8.34653×
-8
10
′′
y
[0.000204286]0.,
′
y
[1.]0.,y[1.]1.,{
′
y
[0.000204286],y[0.000204286]},0.000204286 is neither a list of replacement rules nor a valid dispatch table, and so cannot be used for replacing.
DSolve
:0.204286 cannot be used as a variable.
General
:Further output of DSolve::dsvar will be suppressed during this calculation.
ReplaceAll
:{DSolve[{1.20429y[0.204286]-0.204286
′
y
[0.204286]+0.0834655
′′
y
[0.204286]0,
′
y
[1]0,y[1]1},{
′
y
[0.204286],y[0.204286]},0.204286]} is neither a list of replacement rules nor a valid dispatch table, and so cannot be used for replacing.
General
:Further output of ReplaceAll::reps will be suppressed during this calculation.
This Demonstration shows the solution to the Cauchy–Euler equation
2
2
x
y''(x)-xy'(x)+(1+x)y(x)=0
with initial conditions
y(1)=1
and
y'(1)=0
and approximations to it using truncated series.
Assume solutions have the form
y=
r
x

a
0
+
a
1
x+
a
2
2
x
+…=
r
x
∞
∑
n=0
a
n
n
x
.
Take the first and second derivatives of this equation and substitute back into the original equation. If the equation is to be satisfied for all
x
, the coefficient of each power of
x
must be zero. This gives a quadratic equation in
r
with roots
r=1
and
r=1/2
. Then the coefficients
a
0
,
a
1
,
a
2
, … can be determined. The two solutions for
x>0
are:
y
1
(x)=x1+
∞
∑
n=1
n
(-1)
n
2
(2n+1)!
n
x
,
y
2
(x)=
1/2
x
1+
∞
∑
n=1
n
(-1)
n
2
(2n)!
n
x
.
The final solution (plotted in blue) has the form
y=
c
1
y
1
(x)+
c
2
y
2
(x)
, where
c
1
and
c
2
are determined by the initial conditions. With not too many terms it serves as a good approximation to the exact solution (plotted in red).