2.1.274 Problem 277

Solved as second order ode using Kovacic algorithm
Maple
Mathematica
Sympy

Internal problem ID [9444]
Book : Collection of Kovacic problems
Section : section 1
Problem number : 277
Date solved : Friday, April 25, 2025 at 06:08:28 PM
CAS classification : [[_2nd_order, _with_linear_symmetries]]

Solve

u+2ux+a2u=0

Solved as second order ode using Kovacic algorithm

Time used: 0.163 (sec)

Writing the ode as

(1)u+2ux+a2u=0(2)Au+Bu+Cu=0

Comparing (1) and (2) shows that

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

Applying the Liouville transformation on the dependent variable gives

z(x)=ueB2Adx

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=a21

Comparing the above to (5) shows that

s=a2t=1

Therefore eq. (4) becomes

(7)z(x)=(a2)z(x)

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

u=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.274: 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)=00=0

There are no poles in r. Therefore the set of poles Γ is empty. Since there is no odd order pole larger than 2 and the order at is 0 then the necessary conditions for case one are met. Therefore

L=[1]

Since r=a2 is not a function of x, then there is no need run Kovacic algorithm to obtain a solution for transformed ode z=rz as one solution is

z1(x)=ea2x

Using the above, the solution for the original ode can now be found. The first solution to the original ode in u is found from

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

Which simplifies to

u1=ea2xx

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

u2=u1eBAdxu12dx

Substituting gives

u2=u1e2x1dx(u1)2dx=u1e2ln(x)(u1)2dx=u1(a2e2a2x2a2)

Therefore the solution is

u=c1u1+c2u2=c1(ea2xx)+c2(ea2xx(a2e2a2x2a2))

Will add steps showing solving for IC soon.

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

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)] 
checking if the LODE is missing y 
-> Trying a Liouvillian solution using Kovacics algorithm 
   A Liouvillian solution exists 
   Group is reducible or imprimitive 
<- Kovacics algorithm successful
 

Maple step by step

Let’s solveddxddxu(x)+2(ddxu(x))x+a2u(x)=0Highest derivative means the order of the ODE is2ddxddxu(x)Check to see ifx0=0is a regular singular pointDefine functions[P2(x)=2x,P3(x)=a2]xP2(x)is analytic atx=0(xP2(x))|x=0=2x2P3(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 denominatorsa2u(x)x+(ddxddxu(x))x+2ddxu(x)=0Assume series solution foru(x)u(x)=k=0akxk+rRewrite ODE with series expansionsConvertxu(x)to series expansionxu(x)=k=0akxk+r+1Shift index usingk>k1xu(x)=k=1ak1xk+rConvertddxu(x)to series expansionddxu(x)=k=0ak(k+r)xk+r1Shift index usingk>k+1ddxu(x)=k=1ak+1(k+r+1)xk+rConvertx(ddxddxu(x))to series expansionx(ddxddxu(x))=k=0ak(k+r)(k+r1)xk+r1Shift index usingk>k+1x(ddxddxu(x))=k=1ak+1(k+r+1)(k+r)xk+rRewrite ODE with series expansionsa0r(1+r)x1+r+a1(1+r)(2+r)xr+(k=1(ak+1(k+r+1)(k+2+r)+a2ak1)xk+r)=0a0cannot be 0 by assumption, giving the indicial equationr(1+r)=0Values of r that satisfy the indicial equationr{1,0}Each term must be 0a1(1+r)(2+r)=0Each term in the series must be 0, giving the recursion relationak+1(k+r+1)(k+2+r)+a2ak1=0Shift index usingk>k+1ak+2(k+2+r)(k+3+r)+a2ak=0Recursion relation that defines series solution to ODEak+2=a2ak(k+2+r)(k+3+r)Recursion relation forr=1ak+2=a2ak(k+1)(k+2)Solution forr=1[u(x)=k=0akxk1,ak+2=a2ak(k+1)(k+2),0=0]Recursion relation forr=0ak+2=a2ak(k+2)(k+3)Solution forr=0[u(x)=k=0akxk,ak+2=a2ak(k+2)(k+3),2a1=0]Combine solutions and rename parameters[u(x)=(k=0bkxk1)+(k=0ckxk),bk+2=a2bk(k+1)(k+2),0=0,ck+2=a2ck(k+2)(k+3),2c1=0]
Mathematica. Time used: 0.032 (sec). Leaf size: 42
ode=D[u[x],{x,2}]+2/x*D[u[x],x]+a^2*u[x]==0; 
ic={}; 
DSolve[{ode,ic},u[x],x,IncludeSingularSolutions->True]
 
u(x)eiax(2c1ic2e2iaxa)2x
Sympy. Time used: 0.237 (sec). Leaf size: 24
from sympy import * 
x = symbols("x") 
a = symbols("a") 
u = Function("u") 
ode = Eq(a**2*u(x) + Derivative(u(x), (x, 2)) + 2*Derivative(u(x), x)/x,0) 
ics = {} 
dsolve(ode,func=u(x),ics=ics)
 
u(x)=C1J12(ax)+C2Y12(ax)x