2.2.16 Problem 17

Solved as second order ode using change of variable on x method 2
Solved as second order ode using change of variable on x method 1
Solved as second order Bessel ode
Solved as second order ode using Kovacic algorithm
Maple
Mathematica
Sympy

Internal problem ID [9138]
Book : Second order enumerated odes
Section : section 2
Problem number : 17
Date solved : Friday, April 25, 2025 at 05:57:14 PM
CAS classification : [[_Emden, _Fowler], [_2nd_order, _linear, `_with_symmetry_[0,F(x)]`]]

Solved as second order ode using change of variable on x method 2

Time used: 0.254 (sec)

Solve

y+2yx+a2yx4=0

In normal form the ode

(1)y+2yx+a2yx4=0

Becomes

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

Where

p(x)=2xq(x)=a2x4

Applying change of variables τ=g(x) to (2) gives

(3)d2dτ2y(τ)+p1(ddτy(τ))+q1y(τ)=0

Where τ is the new independent variable, and

(4)p1(τ)=τ(x)+p(x)τ(x)τ(x)2(5)q1(τ)=q(x)τ(x)2

Let p1=0. Eq (4) simplifies to

τ(x)+p(x)τ(x)=0

This ode is solved resulting in

τ=ep(x)dxdx=e2xdxdx=e2ln(x)dx=1x2dx(6)=1x

Using (6) to evaluate q1 from (5) gives

q1(τ)=q(x)τ(x)2=a2x41x4(7)=a2

Substituting the above in (3) and noting that now p1=0 results in

d2dτ2y(τ)+q1y(τ)=0d2dτ2y(τ)+a2y(τ)=0

The above ode is now solved for y(τ).This is second order with constant coefficients homogeneous ODE. In standard form the ODE is

Ay(τ)+By(τ)+Cy(τ)=0

Where in the above A=1,B=0,C=a2. Let the solution be y=eλτ. Substituting this into the ODE gives

(1)λ2eτλ+a2eτλ=0

Since exponential function is never zero, then dividing Eq(2) throughout by eλτ gives

(2)a2+λ2=0

Equation (2) is the characteristic equation of the ODE. Its roots determine the general solution form.Using the quadratic formula

λ1,2=B2A±12AB24AC

Substituting A=1,B=0,C=a2 into the above gives

λ1,2=0(2)(1)±1(2)(1)02(4)(1)(a2)=±a2

Hence

λ1=+a2λ2=a2

Which simplifies to

λ1=iaλ2=ia

Since roots are complex conjugate of each others, then let the roots be

λ1,2=α±iβ

Where α=0 and β=a. Therefore the final solution, when using Euler relation, can be written as

y=eατ(c1cos(βτ)+c2sin(βτ))

Which becomes

y=e0(c1cos(aτ)+c2sin(aτ))

Or

y=c1cos(aτ)+c2sin(aτ)

Will add steps showing solving for IC soon.

The above solution is now transformed back to y(x) using (6) which results in

y(x)=c1cos(ax)c2sin(ax)

Will add steps showing solving for IC soon.

Summary of solutions found

y(x)=c1cos(ax)c2sin(ax)

Solved as second order ode using change of variable on x method 1

Time used: 0.201 (sec)

Solve

y+2yx+a2yx4=0

In normal form the ode

(1)y+2yx+a2yx4=0

Becomes

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

Where

p(x)=2xq(x)=a2x4

Applying change of variables τ=g(x) to (2) results

(3)d2dτ2y(τ)+p1(ddτy(τ))+q1y(τ)=0

Where τ is the new independent variable, and

(4)p1(τ)=τ(x)+p(x)τ(x)τ(x)2(5)q1(τ)=q(x)τ(x)2

Let q1=c2 where c is some constant. Therefore from (5)

τ=1cq(6)=a2x4cτ=2a2ca2x4x5

Substituting the above into (4) results in

p1(τ)=τ(x)+p(x)τ(x)τ(x)2=2a2ca2x4x5+2xa2x4c(a2x4c)2=0

Therefore ode (3) now becomes

y(τ)+p1y(τ)+q1y(τ)=0(7)d2dτ2y(τ)+c2y(τ)=0

The above ode is now solved for y(τ). Since the ode is now constant coefficients, it can be easily solved to give

y(τ)=c1cos(cτ)+c2sin(cτ)

Now from (6)

τ=1cqdx=a2x4dxc=xa2x4c

Substituting the above into the solution obtained gives

y=c1cos(xa2x4)c2sin(xa2x4)

Will add steps showing solving for IC soon.

Summary of solutions found

y=c1cos(xa2x4)c2sin(xa2x4)

Solved as second order Bessel ode

Time used: 0.101 (sec)

Solve

y+2yx+a2yx4=0

Writing the ode as

(1)x2y+2yx+a2yx2=0

Bessel ode has the form

(2)x2y+yx+(n2+x2)y=0

The generalized form of Bessel ode is given by Bowman (1958) as the following

(3)x2y+(12α)xy+(β2γ2x2γn2γ2+α2)y=0

With the standard solution

(4)y=xα(c1BesselJ(n,βxγ)+c2BesselY(n,βxγ))

Comparing (3) to (1) and solving for α,β,n,γ gives

α=12β=an=12γ=1

Substituting all the above into (4) gives the solution as

y=c12sin(ax)xπaxc22cos(ax)xπax

Will add steps showing solving for IC soon.

Summary of solutions found

y=c12sin(ax)xπaxc22cos(ax)xπax

Solved as second order ode using Kovacic algorithm

Time used: 0.298 (sec)

Solve

y+2yx+a2yx4=0

Writing the ode as

(1)y+2yx+a2yx4=0(2)Ay+By+Cy=0

Comparing (1) and (2) shows that

A=1(3)B=2xC=a2x4

Applying the Liouville transformation on the dependent variable gives

z(x)=yeB2Adx

Then (2) becomes

(4)z(x)=rz(x)

Where r is given by

(5)r=st=2AB2BA+B24AC4A2

Substituting the values of A,B,C from (3) in the above and simplifying gives

(6)r=a2x4

Comparing the above to (5) shows that

s=a2t=x4

Therefore eq. (4) becomes

(7)z(x)=(a2x4)z(x)

Equation (7) is now solved. After finding z(x) then y is found using the inverse transformation

y=z(x)eB2Adx

The first step is to determine the case of Kovacic algorithm this ode belongs to. There are 3 cases depending on the order of poles of r and the order of r at . The following table summarizes these cases.

Case

Allowed pole order for r

Allowed value for O()

1

{0,1,2,4,6,8,}

{,6,4,2,0,2,3,4,5,6,}

2

Need to have at least one pole that is either order 2 or odd order greater than 2. Any other pole order is allowed as long as the above condition is satisfied. Hence the following set of pole orders are all allowed. {1,2},{1,3},{2},{3},{3,4},{1,2,5}.

no condition

3

{1,2}

{2,3,4,5,6,7,}

Table 2.33: Necessary conditions for each Kovacic case

The order of r at is the degree of t minus the degree of s. Therefore

O()=deg(t)deg(s)=40=4

The poles of r in eq. (7) and the order of each pole are determined by solving for the roots of t=x4. There is a pole at x=0 of order 4. Since there is no odd order pole larger than 2 and the order at is 4 then the necessary conditions for case one are met. Therefore

L=[1]

Attempting to find a solution using case n=1.

Looking at higher order poles of order 2v4 (must be even order for case one).Then for each pole c, [r]c is the sum of terms 1(xc)i for 2iv in the Laurent series expansion of r expanded around each pole c. Hence

(1B)[r]c=2vai(xc)i

Let a be the coefficient of the term 1(xc)v in the above where v is the pole order divided by 2. Let b be the coefficient of 1(xc)v+1 in r minus the coefficient of 1(xc)v+1 in [r]c. Then

αc+=12(ba+v)αc=12(ba+v)

The partial fraction decomposition of r is

r=a2x4

There is pole in r at x=0 of order 4, hence v=2. Expanding r as Laurent series about this pole c=0 gives

(2B)[r]ciax2+

Using eq. (1B), taking the sum up to v=2 the above becomes

(3B)[r]c=iax2

The above shows that the coefficient of 1(x0)2 is

a=ia

Now we need to find b. let b be the coefficient of the term 1(xc)v+1 in r minus the coefficient of the same term but in the sum [r]c found in eq. (3B). Here c is current pole which is c=0. This term becomes 1x3. The coefficient of this term in the sum [r]c is seen to be 0 and the coefficient of this term r is found from the partial fraction decomposition from above to be 0. Therefore

b=(0)(0)=0

Hence

[r]c=iax2αc+=12(ba+v)=12(0ia+2)=1αc=12(ba+v)=12(0ia+2)=1

Since the order of r at is 4>2 then

[r]=0α+=0α=1

The following table summarizes the findings so far for poles and for the order of r at where r is

r=a2x4

pole c location pole order [r]c αc+ αc
0 4 iax2 1 1

Order of r at [r] α+ α
4 0 0 1

Now that the all [r]c and its associated αc± have been determined for all the poles in the set Γ and [r] and its associated α± have also been found, the next step is to determine possible non negative integer d from these using

d=αs()cΓαcs(c)

Where s(c) is either + or and s() is the sign of α±. This is done by trial over all set of families s=(s(c))cΓ until such d is found to work in finding candidate ω. Trying α=1 then

d=α(αc1)=1(1)=0

Since d an integer and d0 then it can be used to find ω using

ω=cΓ(s(c)[r]c+αcs(c)xc)+s()[r]

The above gives

ω=(()[r]c1+αc1xc1)+()[r]=iax2+1x+()(0)=iax2+1x=ia+xx2

Now that ω is determined, the next step is find a corresponding minimal polynomial p(x) of degree d=0 to solve the ode. The polynomial p(x) needs to satisfy the equation

(1A)p+2ωp+(ω+ω2r)p=0

Let

(2A)p(x)=1

Substituting the above in eq. (1A) gives

(0)+2(iax2+1x)(0)+((2iax31x2)+(iax2+1x)2(a2x4))=00=0

The equation is satisfied since both sides are zero. Therefore the first solution to the ode z=rz is

z1(x)=peωdx=e(iax2+1x)dx=xeiax

The first solution to the original ode in y is found from

y1=z1e12BAdx=z1e122x1dx=z1eln(x)=z1(1x)

Which simplifies to

y1=eiax

The second solution y2 to the original ode is found using reduction of order

y2=y1eBAdxy12dx

Substituting gives

y2=y1e2x1dx(y1)2dx=y1e2ln(x)(y1)2dx=y1(ie2iax2a)

Therefore the solution is

y=c1y1+c2y2=c1(eiax)+c2(eiax(ie2iax2a))

Will add steps showing solving for IC soon.

Summary of solutions found

y=c1eiaxic2eiax2a
Maple. Time used: 0.002 (sec). Leaf size: 21
ode:=diff(diff(y(x),x),x)+2/x*diff(y(x),x)+a^2/x^4*y(x) = 0; 
dsolve(ode,y(x), singsol=all);
 
y=c1sin(ax)+c2cos(ax)

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
 

Mathematica. Time used: 0.02 (sec). Leaf size: 25
ode=D[y[x],{x,2}]+2/x*D[y[x],x]+a^2/x^4*y[x]==0; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
y(x)c1cos(ax)c2sin(ax)
Sympy. Time used: 0.219 (sec). Leaf size: 44
from sympy import * 
x = symbols("x") 
a = symbols("a") 
y = Function("y") 
ode = Eq(a**2*y(x)/x**4 + Derivative(y(x), (x, 2)) + 2*Derivative(y(x), x)/x,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
y(x)=C1axJ12(ax)ax+C2Y12(ax)x