2.4.52 Problem 49

Maple
Mathematica
Sympy

Internal problem ID [8941]
Book : Own collection of miscellaneous problems
Section : section 4.0
Problem number : 49
Date solved : Sunday, March 30, 2025 at 01:55:57 PM
CAS classification : [[_2nd_order, _with_linear_symmetries], [_2nd_order, _linear, `_with_symmetry_[0,F(x)]`]]

Solve

x2y+(x2+6x)y+xy=0

Using series expansion around x=0

The type of the expansion point is first determined. This is done on the homogeneous part of the ODE.

x2y+(x2+6x)y+xy=0

The following is summary of singularities for the above ode. Writing the ode as

y+p(x)y+q(x)y=0

Where

p(x)=x+6xq(x)=1x
Table 2.104: Table p(x),q(x) singularites.
p(x)=x+6x
singularity type
x=0 “regular”
q(x)=1x
singularity type
x=0 “regular”

Combining everything together gives the following summary of singularities for the ode as

Regular singular points : [0]

Irregular singular points : []

Since x=0 is regular singular point, then Frobenius power series is used. The ode is normalized to be

x2y+(x2+6x)y+xy=0

Let the solution be represented as Frobenius power series of the form

y=n=0anxn+r

Then

y=n=0(n+r)anxn+r1y=n=0(n+r)(n+r1)anxn+r2

Substituting the above back into the ode gives

(1)x2(n=0(n+r)(n+r1)anxn+r2)+(x2+6x)(n=0(n+r)anxn+r1)+x(n=0anxn+r)=0

Which simplifies to

(2A)(n=0xn+ran(n+r)(n+r1))+(n=0x1+n+ran(n+r))+(n=06xn+ran(n+r))+(n=0x1+n+ran)=0

The next step is to make all powers of x be n+r in each summation term. Going over each summation term above with power of x in it which is not already xn+r and adjusting the power and the corresponding index gives

n=0x1+n+ran(n+r)=n=1an1(n+r1)xn+rn=0x1+n+ran=n=1an1xn+r

Substituting all the above in Eq (2A) gives the following equation where now all powers of x are the same and equal to n+r.

(2B)(n=0xn+ran(n+r)(n+r1))+(n=1an1(n+r1)xn+r)+(n=06xn+ran(n+r))+(n=1an1xn+r)=0

The indicial equation is obtained from n=0. From Eq (2B) this gives

xn+ran(n+r)(n+r1)+6xn+ran(n+r)=0

When n=0 the above becomes

xra0r(1+r)+6xra0r=0

Or

(xrr(1+r)+6xrr)a0=0

Since a00 then the above simplifies to

xrr(5+r)=0

Since the above is true for all x then the indicial equation becomes

r(5+r)=0

Solving for r gives the roots of the indicial equation as

r1=0r2=5

Since a00 then the indicial equation becomes

xrr(5+r)=0

Solving for r gives the roots of the indicial equation as [0,5].

Since r1r2=5 is an integer, then we can construct two linearly independent solutions

y1(x)=xr1(n=0anxn)y2(x)=Cy1(x)ln(x)+xr2(n=0bnxn)

Or

y1(x)=n=0anxny2(x)=Cy1(x)ln(x)+n=0bnxnx5

Or

y1(x)=n=0anxny2(x)=Cy1(x)ln(x)+(n=0bnxn5)

Where C above can be zero. We start by finding y1. Eq (2B) derived above is now used to find all an coefficients. The case n=0 is skipped since it was used to find the roots of the indicial equation. a0 is arbitrary and taken as a0=1. For 1n the recursive equation is

(3)an(n+r)(n+r1)+an1(n+r1)+6an(n+r)+an1=0

Solving for an from recursive equation (4) gives

(4)an=an1n+5+r

Which for the root r=0 becomes

(5)an=an1n+5

At this point, it is a good idea to keep track of an in a table both before substituting r=0 and after as more terms are found using the above recursive equation.

n an,r an
a0 1 1

For n=1, using the above recursive equation gives

a1=16+r

Which for the root r=0 becomes

a1=16

And the table now becomes

n an,r an
a0 1 1
a1 16+r 16

For n=2, using the above recursive equation gives

a2=1(6+r)(7+r)

Which for the root r=0 becomes

a2=142

And the table now becomes

n an,r an
a0 1 1
a1 16+r 16
a2 1(6+r)(7+r) 142

For n=3, using the above recursive equation gives

a3=1(6+r)(7+r)(8+r)

Which for the root r=0 becomes

a3=1336

And the table now becomes

n an,r an
a0 1 1
a1 16+r 16
a2 1(6+r)(7+r) 142
a3 1(6+r)(7+r)(8+r) 1336

For n=4, using the above recursive equation gives

a4=1(6+r)(7+r)(8+r)(9+r)

Which for the root r=0 becomes

a4=13024

And the table now becomes

n an,r an
a0 1 1
a1 16+r 16
a2 1(6+r)(7+r) 142
a3 1(6+r)(7+r)(8+r) 1336
a4 1(6+r)(7+r)(8+r)(9+r) 13024

For n=5, using the above recursive equation gives

a5=1(6+r)(7+r)(8+r)(9+r)(10+r)

Which for the root r=0 becomes

a5=130240

And the table now becomes

n an,r an
a0 1 1
a1 16+r 16
a2 1(6+r)(7+r) 142
a3 1(6+r)(7+r)(8+r) 1336
a4 1(6+r)(7+r)(8+r)(9+r) 13024
a5 1(6+r)(7+r)(8+r)(9+r)(10+r) 130240

Using the above table, then the solution y1(x) is

y1(x)=a0+a1x+a2x2+a3x3+a4x4+a5x5+a6x6=1x6+x242x3336+x43024x530240+O(x6)

Now the second solution y2(x) is found. Let

r1r2=N

Where N is positive integer which is the difference between the two roots. r1 is taken as the larger root. Hence for this problem we have N=5. Now we need to determine if C is zero or not. This is done by finding limrr2a5(r). If this limit exists, then C=0, else we need to keep the log term and C0. The above table shows that

aN=a5=1(6+r)(7+r)(8+r)(9+r)(10+r)

Therefore

limrr21(6+r)(7+r)(8+r)(9+r)(10+r)=limr51(6+r)(7+r)(8+r)(9+r)(10+r)=1120

The limit is 1120. Since the limit exists then the log term is not needed and we can set C=0. Therefore the second solution has the form

y2(x)=n=0bnxn+r=n=0bnxn5

Eq (3) derived above is used to find all bn coefficients. The case n=0 is skipped since it was used to find the roots of the indicial equation. b0 is arbitrary and taken as b0=1. For 1n the recursive equation is

(4)bn(n+r)(n+r1)+bn1(n+r1)+6bn(n+r)+bn1=0

Which for for the root r=5 becomes

(4A)bn(n5)(n6)+bn1(n6)+6bn(n5)+bn1=0

Solving for bn from the recursive equation (4) gives

(5)bn=bn1n+5+r

Which for the root r=5 becomes

(6)bn=bn1n

At this point, it is a good idea to keep track of bn in a table both before substituting r=5 and after as more terms are found using the above recursive equation.

n bn,r bn
b0 1 1

For n=1, using the above recursive equation gives

b1=16+r

Which for the root r=5 becomes

b1=1

And the table now becomes

n bn,r bn
b0 1 1
b1 16+r 1

For n=2, using the above recursive equation gives

b2=1(6+r)(7+r)

Which for the root r=5 becomes

b2=12

And the table now becomes

n bn,r bn
b0 1 1
b1 16+r 1
b2 1(6+r)(7+r) 12

For n=3, using the above recursive equation gives

b3=1(6+r)(7+r)(8+r)

Which for the root r=5 becomes

b3=16

And the table now becomes

n bn,r bn
b0 1 1
b1 16+r 1
b2 1(6+r)(7+r) 12
b3 1(6+r)(7+r)(8+r) 16

For n=4, using the above recursive equation gives

b4=1(6+r)(7+r)(8+r)(9+r)

Which for the root r=5 becomes

b4=124

And the table now becomes

n bn,r bn
b0 1 1
b1 16+r 1
b2 1(6+r)(7+r) 12
b3 1(6+r)(7+r)(8+r) 16
b4 1(6+r)(7+r)(8+r)(9+r) 124

For n=5, using the above recursive equation gives

b5=1(6+r)(7+r)(8+r)(9+r)(10+r)

Which for the root r=5 becomes

b5=1120

And the table now becomes

n bn,r bn
b0 1 1
b1 16+r 1
b2 1(6+r)(7+r) 12
b3 1(6+r)(7+r)(8+r) 16
b4 1(6+r)(7+r)(8+r)(9+r) 124
b5 1(6+r)(7+r)(8+r)(9+r)(10+r) 1120

Using the above table, then the solution y2(x) is

y2(x)=1(b0+b1x+b2x2+b3x3+b4x4+b5x5+b6x6)=1x+x22x36+x424x5120+O(x6)x5

Therefore the homogeneous solution is

yh(x)=c1y1(x)+c2y2(x)=c1(1x6+x242x3336+x43024x530240+O(x6))+c2(1x+x22x36+x424x5120+O(x6))x5

Hence the final solution is

y=yh=c1(1x6+x242x3336+x43024x530240+O(x6))+c2(1x+x22x36+x424x5120+O(x6))x5
Maple. Time used: 0.029 (sec). Leaf size: 44
Order:=6; 
ode:=x^2*diff(diff(y(x),x),x)+(x^2+6*x)*diff(y(x),x)+x*y(x) = 0; 
dsolve(ode,y(x),type='series',x=0);
 
y=c1(116x+142x21336x3+13024x4130240x5+O(x6))+c2(28802880x+1440x2480x3+120x424x5+O(x6))x5

Maple trace

Methods for second order ODEs: 
--- Trying classification methods --- 
trying a quadrature 
checking if the LODE has constant coefficients 
checking if the LODE is of Euler type 
trying a symmetry of the form [xi=0, eta=F(x)] 
<- linear_1 successful
 

Maple step by step

Let’s solvex2(ddxddxy(x))+(x2+6x)(ddxy(x))+xy(x)=0Highest derivative means the order of the ODE is2ddxddxy(x)Isolate 2nd derivativeddxddxy(x)=y(x)x(x+6)(ddxy(x))xGroup terms withy(x)on the lhs of the ODE and the rest on the rhs of the ODE; ODE is linearddxddxy(x)+(x+6)(ddxy(x))x+y(x)x=0Check to see ifx0=0is a regular singular pointDefine functions[P2(x)=x+6x,P3(x)=1x]xP2(x)is analytic atx=0(xP2(x))|x=0=6x2P3(x)is analytic atx=0(x2P3(x))|x=0=0x=0is a regular singular pointCheck to see ifx0=0is a regular singular pointx0=0Multiply by denominators(ddxddxy(x))x+(x+6)(ddxy(x))+y(x)=0Assume series solution fory(x)y(x)=k=0akxk+rRewrite ODE with series expansionsConvertxm(ddxy(x))to series expansion form=0..1xm(ddxy(x))=k=0ak(k+r)xk+r1+mShift index usingk>k+1mxm(ddxy(x))=k=1+mak+1m(k+1m+r)xk+rConvertx(ddxddxy(x))to series expansionx(ddxddxy(x))=k=0ak(k+r)(k+r1)xk+r1Shift index usingk>k+1x(ddxddxy(x))=k=1ak+1(k+1+r)(k+r)xk+rRewrite ODE with series expansionsa0r(5+r)x1+r+(k=0(ak+1(k+1+r)(k+6+r)+ak(k+1+r))xk+r)=0a0cannot be 0 by assumption, giving the indicial equationr(5+r)=0Values of r that satisfy the indicial equationr{5,0}Each term in the series must be 0, giving the recursion relation(k+1+r)(ak+1(k+6+r)+ak)=0Recursion relation that defines series solution to ODEak+1=akk+6+rRecursion relation forr=5ak+1=akk+1Solution forr=5[y(x)=k=0akxk5,ak+1=akk+1]Recursion relation forr=0ak+1=akk+6Solution forr=0[y(x)=k=0akxk,ak+1=akk+6]Combine solutions and rename parameters[y(x)=(k=0akxk5)+(k=0bkxk),ak+1=akk+1,bk+1=bkk+6]
Mathematica. Time used: 0.029 (sec). Leaf size: 68
ode=x^2*D[y[x],{x,2}]+(6*x+x^2)*D[y[x],x]+x*y[x]==0; 
ic={}; 
AsymptoticDSolveValue[{ode,ic},y[x],{x,0,5}]
 
y(x)c2(x43024x3336+x242x6+1)+c1(1x51x4+12x316x2+124x)
Sympy. Time used: 0.987 (sec). Leaf size: 56
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(x**2*Derivative(y(x), (x, 2)) + x*y(x) + (x**2 + 6*x)*Derivative(y(x), x),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics,hint="2nd_power_series_regular",x0=0,n=6)
 
y(x)=C2(x530240+x43024x3336+x242x6+1)+C1(x424x36+x22x+1)x5+O(x6)