2.1.275 Problem 278

Solved as second order ode using Kovacic algorithm
Maple
Mathematica
Sympy

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

Solve

u+4uxa2u=0

Solved as second order ode using Kovacic algorithm

Time used: 0.362 (sec)

Writing the ode as

(1)u+4uxa2u=0(2)Au+Bu+Cu=0

Comparing (1) and (2) shows that

A=1(3)B=4xC=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=a2x2+2x2

Comparing the above to (5) shows that

s=a2x2+2t=x2

Therefore eq. (4) becomes

(7)z(x)=(a2x2+2x2)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.275: 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)=22=0

The poles of r in eq. (7) and the order of each pole are determined by solving for the roots of t=x2. There is a pole at x=0 of order 2. 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. Since there is a pole of order 2 then necessary conditions for case two are met. Therefore

L=[1,2]

Attempting to find a solution using case n=1.

Looking at poles of order 2. The partial fractions decomposition of r is

r=2x2+a2

For the pole at x=0 let b be the coefficient of 1x2 in the partial fractions decomposition of r given above. Therefore b=2. Hence

[r]c=0αc+=12+1+4b=2αc=121+4b=1

Since the order of r at is Or()=0 then

v=Or()2=02=0

[r] is the sum of terms involving xi for 0iv in the Laurent series for r at . Therefore

[r]=i=0vaixi(8)=i=00aixi

Let a be the coefficient of xv=x0 in the above sum. The Laurent series of r at is

(9)ra+1ax212a3x4+12a5x658a7x8+78a9x102116a11x12+3316a13x14+

Comparing Eq. (9) with Eq. (8) shows that

a=a

From Eq. (9) the sum up to v=0 gives

[r]=i=00aixi(10)=a

Now we need to find b, where b be the coefficient of xv1=x1=1x in r minus the coefficient of same term but in ([r])2 where [r] was found above in Eq (10). Hence

([r])2=a2

This shows that the coefficient of 1x in the above is 0. Now we need to find the coefficient of 1x in r. How this is done depends on if v=0 or not. Since v=0 then starting from r=st and doing long division in the form

r=Q+Rt

Where Q is the quotient and R is the remainder. Then the coefficient of 1x in r will be the coefficient in R of the term in x of degree of t minus one, divided by the leading coefficient in t. Doing long division gives

r=st=a2x2+2x2=Q+Rx2=(a2)+(2x2)=2x2+a2

Since the degree of t is 2, then we see that the coefficient of the term x in the remainder R is 0. Dividing this by leading coefficient in t which is 1 gives 0. Now b can be found.

b=(0)(0)=0

Hence

[r]=aα+=12(bav)=12(0a0)=0α=12(bav)=12(0a0)=0

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

r=a2x2+2x2

pole c location pole order [r]c αc+ αc
0 2 0 2 1

Order of r at [r] α+ α
0 a 0 0

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 α=0 then

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

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]=1x+()(a)=1xa=ax1x

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

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

Let

(2A)p(x)=x+a0

Substituting the above in eq. (1A) gives

(0)+2(1xa)(1)+((1x2)+(1xa)2(a2x2+2x2))=02aa02x=0

Solving for the coefficients ai in the above using method of undetermined coefficients gives

{a0=1a}

Substituting these coefficients in p(x) in eq. (2A) results in

p(x)=x+1a

Therefore the first solution to the ode z=rz is

z1(x)=peωdx=(x+1a)e(1xa)dx=(x+1a)eaxln(x)=(ax+1)eaxax

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

u1=z1e12BAdx=z1e124x1dx=z1e2ln(x)=z1(1x2)

Which simplifies to

u1=(ax+1)eaxx3a

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

u2=u1eBAdxu12dx

Substituting gives

u2=u1e4x1dx(u1)2dx=u1e4ln(x)(u1)2dx=u1((ax1)e2ax2a(ax+1))

Therefore the solution is

u=c1u1+c2u2=c1((ax+1)eaxx3a)+c2((ax+1)eaxx3a((ax1)e2ax2a(ax+1)))

Will add steps showing solving for IC soon.

Maple. Time used: 0.005 (sec). Leaf size: 32
ode:=diff(diff(u(x),x),x)+4/x*diff(u(x),x)-a^2*u(x) = 0; 
dsolve(ode,u(x), singsol=all);
 
u=c1eax(ax1)+c2eax(ax+1)x3

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 
   Reducible group (found an exponential solution) 
   Reducible group (found another exponential solution) 
<- Kovacics algorithm successful
 

Maple step by step

Let’s solveddxddxu(x)+4(ddxu(x))xa2u(x)=0Highest derivative means the order of the ODE is2ddxddxu(x)Check to see ifx0=0is a regular singular pointDefine functions[P2(x)=4x,P3(x)=a2]xP2(x)is analytic atx=0(xP2(x))|x=0=4x2P3(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+4ddxu(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(3+r)x1+r+a1(1+r)(4+r)xr+(k=1(ak+1(k+r+1)(k+4+r)a2ak1)xk+r)=0a0cannot be 0 by assumption, giving the indicial equationr(3+r)=0Values of r that satisfy the indicial equationr{3,0}Each term must be 0a1(1+r)(4+r)=0Each term in the series must be 0, giving the recursion relationak+1(k+r+1)(k+4+r)a2ak1=0Shift index usingk>k+1ak+2(k+2+r)(k+5+r)a2ak=0Recursion relation that defines series solution to ODEak+2=a2ak(k+2+r)(k+5+r)Recursion relation forr=3ak+2=a2ak(k1)(k+2)Solution forr=3[u(x)=k=0akxk3,ak+2=a2ak(k1)(k+2),2a1=0]Recursion relation forr=0ak+2=a2ak(k+2)(k+5)Solution forr=0[u(x)=k=0akxk,ak+2=a2ak(k+2)(k+5),4a1=0]Combine solutions and rename parameters[u(x)=(k=0bkxk3)+(k=0ckxk),bk+2=a2bk(k1)(k+2),2b1=0,ck+2=a2ck(k+2)(k+5),4c1=0]
Mathematica. Time used: 0.073 (sec). Leaf size: 68
ode=D[u[x],{x,2}]+4/x*D[u[x],x]-a^2*u[x]==0; 
ic={}; 
DSolve[{ode,ic},u[x],x,IncludeSingularSolutions->True]
 
u(x)2π((iac2x+c1)sinh(ax)(ac1x+ic2)cosh(ax))ax5/2iax
Sympy. Time used: 0.233 (sec). Leaf size: 37
from sympy import * 
x = symbols("x") 
a = symbols("a") 
u = Function("u") 
ode = Eq(-a**2*u(x) + Derivative(u(x), (x, 2)) + 4*Derivative(u(x), x)/x,0) 
ics = {} 
dsolve(ode,func=u(x),ics=ics)
 
u(x)=C1J32(xa2)+C2Y32(xa2)x32