You are on page 1of 5

Journal of Science (JOS) 131

Vol. 2, No. 3, 2012 ISSN 2324-9854


Copyright © World Science Publisher, United States
www.worldsciencepublisher.org

A Method for Solving the Special Type of Cauchy-Euler


Differential Equations and its Algorithms in MATLAB

Mehdi Delkhosh

Islamic Azad University, Bardaskan Branch, ◌Department


ِ of Mathematics, Bardaskan, Iran

Email: mehdidelkhosh@yahoo.com

Abstract – In many applications of sciences, for solve many them, often appear equations of type N-Order Linear
differential equations, where the number of them is Cauchy-Euler differential equations (also known as the Euler
differential equation). i.e. Cauchy-Euler differential equations often appear in analysis of computer algorithms, notably
in analysis of quicksort and search trees; a number of physics and engineering applications, such as when solving
Laplace's equation in polar coordinates; and many other sciences.
In this paper, we use variable change method for solving the special type of N-Order Cauchy-Euler differential
equations. We applying a variable change in the equation, and then obtain the conditions, where if we have an equation
that applies to these conditions, a simple analytical solution for the equation can be obtained. Because in this method, an
analytical solution is obtained, therefore, it is not necessary to use numerical methods to solve the problem.

Keywords – Cauchy-Euler differential equation, Euler differential equation, ordinary differential equation, linear
differential equations, Equidimensional equations, Wronskian, MATLAB.

1. Introduction an xn y (n)  an1 xn1 y (n1)  ...  a1x1 y  a0 y  0 (1)


where an , an1 ,..., a1 , a0 are constants, an  0 , n is a
In many applications of sciences, for solve many
positive integer, y is analytic function or formal power
them, often appear equations of type N-Order Linear
differential equations, where the number of them is series.
Cauchy-Euler differential equations (also known as the Such equations are also referred to in the literature as
Euler differential equation) [1, 2, 7, 9, 11, 13, 14, 15, 16, Cauchy-Euler equations, Euler–Cauchy equations, or
18, 20, 21, 22, 23, 24, 26]. equidimensional equations.
Cauchy-Euler differential equations often appear in Cauchy-Euler differential equation with the
analysis of computer algorithms, notably in analysis of substitution x  et reduces this equation to a linear
quicksort and search trees; a number of physics and differential equation with constant coefficients; we will
engineering applications, such as when solving Laplace's introduce a new and simpler method for solving some of
equation in polar coordinates; and many other sciences. Cauchy-Euler differential equations.
There are several methods for solving equations, there
one of which can be seen in the literature [4, 5, 6, 12, 15, 1.2. Wronskian
19, 24, 25, 26].
In this paper, for solving analytical some N-Order The Wronskian of two functions f and g is [1, 2, 3]
Cauchy-Euler differential equations, applying a variable W ( x)  W ( f , g )  f g  fg  .
change in the equation, then we get conditions where if
More generally, for n real- or complex- valued
an equation is also conditions, a simple analytical
functions f 1 , f 2 ,..., f n , which are n − 1 times
solution is obtained for it.
Before going to the main point, we start to introduce differentiable on ( a, b) , the Wronskian
two following items: W ( x)  W ( f1,..., f n ) as a function on (a, b) is defined by
f1  fn
1.1. N-Order Cauchy-Euler Differential
W ( x)     (2)
Equation
f1( n 1)  f n( n 1)
Homogeneous Cauchy-Euler differential equation of That is, it is the determinant of the matrix constructed
order n is: by placing the functions in the first row, the first
Delkhosh, JOS, Vol. 2, No. 3, pp. 131-135, 2012 132

derivative of each function in the second row, and so on y  u.v


through the (n - 1)st derivative, thus forming a square y  u.v  u.v
matrix sometimes called a fundamental matrix.
y  u.v  2u.v  u.v
When the functions f i are solutions of a linear
differential equation, the Wronskian can be found 

 .u
n
explicitly using Abel's identity, even if the functions f i
y (n)   n
k
( nk )
.v ( k )
are not known explicitly: k 0
Theorem: if P ( x) y   Q ( x) y   R ( x) y  0 then After placing in equation (1), we have:
Q  v.u   vu   vu   vu  ...  v u   v u
an xn n ( n) n ( n1) n ( n2) n ( n3) n ( n1) n ( n)

 P dx .
0 1 2 3 n1
 n

W ( x)  e  a x  vu   vu
n1
n1 n1
0   vu  ...  v u   v u
( n1) n1
1
( n2) n1
2
( n3) n1
n2
( n2) n1
n1
( n1)

Proof: let two solution of equation by y1 and y2 ,  a x  vu


n2   vu
n2
0  ...  v u   v u
n 2 ( n2) n 2
1
( n3) n 2
n1
( n1) n2
n2
( n2)


then, since these solutions satisfy the equation, we have
Py1  Qy1  Ry1  0  a2 x2 vu   vu   vu
2
0
2
1
2
2

Py2  Qy2  Ry2  0  a x  vu   vu


1
1 1
0
1
1

 a0 vu
Multiplying the first equation by y2 , the second by 0
y1 , and subtracting we find
P.( y1 y2  y2 y1)  Q.( y1 y2  y2 y1 )  0 After categories, we have:
an x n .v.u( n) 
Since Wronskian is given by W  y1 y2  y2 y thus
a x  v  a
n
n n
1 n1 x n1  vu
n1
0
( n1)

P.
dW
 Q.W  0 a x  v  a
n
n n
2 n1
n1 n1
x1  v  a n 2 x n2  vu
n 2
0
( n2)

a x  v  a  vu
dx
Solving, we obtain an important relation known as n
n n
3 n1
n1 n1
x 2  v  a n2
n 2 n 2
x 1  v  a n3 xn3 n3
0
( n3)

Abel's identity, given by 


Q
 P dx .■ a x  v  a x  v   a x  v  a x  vu 
n
n n
n1
( n1)
n1
n1 n1
n 2
( n 2)
2
2 2
1 1
1 1
0
W ( x)  e a x  v  a x  v  a x  v   a x  v  a vu  0
n
n n
n
( n)
n1
n1 n1
n1
( n1)
n 2
n2 n 2
n 2
( n2)
1
1 1
1 0

In general case, for N-Order Liner Ordinary


Differential Equation (1), we obtain Or
W ( x)  e 
 p n 1 dx
k 
 a
n
(3) an x n v.u ( n )    n i
k i n i x n i v ( k i ) u ( n  k )  0 (5)
k 1  i  0 
where an  0 .
2. Solving the Special type of Cauchy-Euler Now, we assume that the coefficient u ( n 1) is zero
Differential Equations and we can calculate the value v (x ) , i.e.

Theorem (Main Theorem): If, the coefficients an x n  v  a


n
1 n 1 x n 1  v  0
n 1
0

an , an1 ,..., a1 , a0 in a homogeneous Cauchy-Euler an 1 1 (6)


 v   v
differential equation of order n : nan x
an xn y ( n)  an1 xn1 y (n1)  ...  a1 x1 y  a0 y  0 
an1
Ln ( x ) 
an1

verify in the conditions: ve na n


x na n

( n  k  1) ank 1 Now, corresponding to equation (3) we have


an k  an1  n(k  1)an  
an 1

an 1
k .n an Ln ( x )

where k  2,3,..., n .
v( x )  e nan
x nan
 n W ( x)
Then, the answer to equation will be (7)
a

C 
 n 1
y ( x)  x na n
x n 1  ...  C1 x1  C0 . Now, using Equation (6), (7) and assuming that the
n 1
coefficients u ,u ,..., u, u are zero, we get the
( n  2) ( n  3)

Proof: we show that Cauchy-Euler differential condition that if an equation is also conditions, can be
equation (1) is changeable to two linear differential solved with this method:
equations. The coefficient u ( n  2 ) :
By replacing of change variable an x n  v  a
n
2 n 1 x n 1  v  a
n 1
1 n2 x n2  v  0
n2
0
y  u ( x).v( x) (4) according to equation (7) we have
in equation (1), where u (x ) and v (x) are continuous (n  1) an1
and differentiable functions, and
an  2  an1  nan 
2!.n an
(8)
Delkhosh, JOS, Vol. 2, No. 3, pp. 131-135, 2012 133

And, the coefficient u ( n3) : y ( x)  v( x).u ( x)  xC1 x  C0   C1 x 2  C0 x


an x n  v  a
n
3 n 1 x n 1  v  a
n 1
2 n 2 x n2  v  a
n2
1 n 3 x n 3  v  0
n 3
0 Analytical and very simple answer is obtained.

EX.2) Solve the equation


(n  1)(n  2) an1 2 2 8
an3 
3!.n 2 an2

an1  3nan1an  2n 2 an2  x 3 y  2 x 2 y  xy  y0
3 27
(9) (15)
Solution: By virtue of equation (1) we have
In general, we can obtain the following recursive 2 8 . Obviously, that
a3  1 , a2  2 , a1   , a0 
relation: 3 27
( n  k  1) ank 1 equations (8) and (9) are established, i.e.
ank  an1  n(k  1)an  (10)
(3  1) 2
k .n an
a1  2  3   2
where k  2,3,..., n . 2!.3 1 3
(3  1)(3  2) 2
a0  4  18  18  8
So, if the coefficients in Cauchy-Euler differential 3!.32 1 27
equation, in Equation (10) and the above assumptions is So, we have:
2
true, according to equation (5) we have: 
v( x)  x 3
, u( x)  C2 x 2  C1 x1  C0
an x n v.u ( n )  0  u ( n)  0
And, the answer to linear differential equation(15) will
Or be
u ( x)  Cn1 x n1  ...  C1 x1  C0 2

(11)


y ( x )  v ( x ).u ( x )  x 3 C 2 x 2  C1 x  C0 
Where C n1 ,..., C1 , C0 are arbitrary real numbers. Analytical and very simple answer is obtained.

EX.3) Solve the equation


So, we have from Equations (4), (7) and (11):
20 160 (16)
1  2 x 3 y  4 x 2 y  xy  y0
 p n 1 dx
3 27
v( x)  e n
 n W ( x) (12) Solution: By virtue of equation (1) we have
n 1
u ( x)  Cn 1 x  ...  C1 x  C0 1
20 160 . Obviously, that
a  2 , a  4 , a  
3 2 1 , a  0
And, the answer to Cauchy-Euler differential equation 3 27
(1) will be equation (8) is established, i.e.
(3  1) 4
4  6   20
an 1

C  a1 

n 1
y ( x )  v( x).u ( x)  x na n
n 1 x  ...  C1 x1  C0 2!.3  2 3
(3  1)(3  2) 4
(13) a0  16  72  72  160
3!.32 4 27
In a similar manner, Cauchy-Euler differential So, we have:
2
equations of the type
v( x)  x 3 , u( x)  C2 x 2  C1 x1  C0
an ( Ax  B)n y ( n)  ...  a1 ( Ax  B)1 y  a0 y  0
And, the answer to linear differential equation (16)
Where an ,..., a1 , a0 and A, B are constants and will be
A, an  0 . An answer is as follows: 2

a n1

y ( x)  v( x).u ( x)  x 3 C2 x 2  C1 x  C0 
C  ...  C1 ( Ax  B )  C0  .■

y ( x)  x na n A
n 1 ( Ax  B) n 1 1 Analytical and very simple answer is obtained.

3. Examples and Applications 4. Algorithms in MATLAB

4.1. Algorithm for Finding the Coefficients


EX.1) Solve the equation
 5 x 2 y  10 xy  10 y  0 (14) Algorithm for finding the coefficients in equation (10)
Solution: By virtue of equation (1) we have are true, is as follows:
a2  -5 , a1  10 , a0  10 . Obviously, that equation First, in MATLAB  Menu "File"  Select
(8) is established, i.e. "NEW"  Select "M-File"  The following function
(2  1) 10 to copy in file, and then save the file to "euler_find.m"
a0  10  2.(5)   10 name:
2!.2  5
So, we have:
function euler_find(a)
v( x)  x1 , u( x)  C1 x1  C0 syms n k
And, the answer to Cauchy-Euler differential equation n=a{3};
(14) will be for k=2:n
Delkhosh, JOS, Vol. 2, No. 3, pp. 131-135, 2012 134

a{k+1}=(((n-k+1)*a{k}*(a{2}-n*(k-1)*a{1}))/(n*k*a{1})); >> f{2}="the intended Coefficient: a1";


disp(sprintf('a(%d)', n-k)); >>…
display(simplify(a{k+1})); >> f{n}="the intended Coefficient: an-1";
end >> f{n+1}="the intended Coefficient: an-1";
end >> euler_test(f)

Secondly, in the window "Command Windows" of EX.5) in the window "Command Windows" of
MATLAB, type the following commands: MATLAB, type the following commands:
>> f{1}=0;
>> f{1}= "Coefficient : an"; >> f{2}=6;
>> f{2}= "Coefficient : an-1"; >> f{3}=6;
>> f{3} = "Order differential equation: n"; >> f{4}=1;
>> euler_find(f) >> euler_test(f)

EX.4) in the window "Command Windows" of Then, key "ENTER"


MATLAB, type the following commands: >> yes
>>> f{1}=1;
>> f{2}=-3; Thus, if a3  1 , a2  6 , a1  6 , a0  0 , equation
>> f{3}=3;
>> euler_find(f) (10) are established, i.e. equation
x3 y  6 x 2 y  6 xy  0. y  0
Then, key "ENTER" is the answer to:
a(1)
ans = y ( x)  x 2 C2 x 2  C1 x  C0  .
6

a(0) 5. Conclusion
ans =
-6
In many applications of science, for solve many them,
Thus, functions that are true in the equation (10), are
often appear equations of type N-Order Linear
calculated, the desired equation is as follows:
differential equations, where the number of them is
x 3 y  3x 2 y  6 xy  6 y  0 Cauchy-Euler differential equations (also known as the
i.e. Euler differential equation).
y ( x)  x1 C2 x 2  C1 x  C0  . Cauchy-Euler differential equations often appear in
analysis of computer algorithms, notably in analysis of
quicksort and search trees; a number of physics and
engineering applications, such as when solving Laplace's
4.2. Algorithm to check the true Coefficients equation in polar coordinates; and many other sciences.
The key step in transforming the unified equation is
Algorithm to check the true coefficients in equation the equation (10).
(10), is as follows: Many difficult problems in the field of static and
First, in MATLAB  Menu "File"  Select dynamic mechanics are solved by the unified equation
"NEW"  Select "M-File"  The following function proposed in this paper.
to copy in file, and then save the file to " euler_test.m"
name:

function euler_test(a)
References
syms n k
n=size(a,2)-1; [1] F.B. Hilderbrand, Advanced Calculus for
Applications (2-ed), New Jersey, 1976.
k=2;
flag=1;
while(flag==1 && k<=n) [2] S.H. Javadpour, an Introduction to Ordinary and
if (abs((a{n-k+1}*(n*k*a{n+1}))-((n-k+1)*a{n-k+2}*(a{n}- Partial Differential Equations, Iran, Alavi, 1993.
n*(k-1)*a{n+1})))<=1e-012)
flag=1;
k=k+1;
[3] P.V. O’Neil, Advanced Engineering Math-ematics
else (2-ed), California, Wadsworth, 1987.
flag=0;
end [4] L. Qiusheng, C. Hong, L. Guiqing, Static and
end
if (flag==1)
Dynamic analysis of straight bars with variable cross-
display('Yes'); section, Computer & Structures Vol. 59, No. 6, p.1185-
else 1191, 1996.
display('No');
end
end
[5] L. Qiusheng, C. Hong, L. Guiqing, Analysis of Free
Vibrations of Tall Buildings, Journal of Engineering
Secondly, in the window "Command Windows" of Mechanics, Vol. 120, No. 9, pp. 1861-1876, 1994
MATLAB, type the following commands:
>> f{1}="the intended Coefficient: a0";
Delkhosh, JOS, Vol. 2, No. 3, pp. 131-135, 2012 135

[6] D. Demir, N. Bildik, A. Konuralp, A. Demir, The [19] K. Batiha, B. Batiha, A New Algorithm for Solving
Numerical Solutions for the Damped Generalized Linear Ordinary Differential Equations, World Applied
Regularized Long-wave Equation by Variational Method, Sciences Journal 15 (12): 1774-1779, 2011.
World Applied Sciences Journal 13 (Special Issue of
Applied Math): 08-17, 2011. [20] M.A. Gondal, A.S. Arife, Majid Khan and Iqtadar
Hussain, An Efficient Numerical Method for Solving
[7] S.T. Mohyud-Din, Solutions of Nonlinear Differential Linear and Nonlinear Partial Differential Equations by
Equations by Exp-function Method, World Applied Combining Homotopy Analysis and Transform Method,
Sciences Journal 7 (Special Issue for Applied Math): World Applied Sciences Journal 14 (12): 1786-1791,
116-147, 2009. 2011.

[8] F. Olver, L. Maximon, Bessel function, NIST [21] J. Gine, J. Llibre, A Family of Isochronous Foci
Handbook of Mathematical Functions, Cambridge With Darboux First Integral, Pacific Journal Of
University Press, ISBN 978-0521192255, MR2723248, Mathematics, Vol. 218, No. 2, P. 343-356, 2005
2010
[22] M. Bridgeman, R.D. Canary, Bounding the Bending
[9] M. Allame, N. Azad, Solution of Third Order Of A Hyperbolic 3-ManifolD, Pacific Journal Of
Nonlinear Equation by Taylor Series Expansion, World Mathematics, Vol. 218, No. 2, P. 299-314, 2005
Applied Sciences Journal 14 (1): 59-62, 2011.
[23] Hua-Huai Chern, Hsien-Kuei Hwang, Tsung-Hsi
[10] S. Teukolsky, WT. Vetterling, Section 6.5. Bessel Tsai, An asymptotic theory for Cauchy–Euler differential
Functions of Integer Order, Numerical Recipes: The Art equations with applications to the analysis of algorithms,
of Scientific Computing (3rd ed.), New York: Cambridge Journal Of Algorithms, Vol. 44,, P. 177-225, 2002
University Press, ISBN 978-0-521-88068-8, 2007
[24] Yahya Qaid Hasan, Solving first-order ordinary
[11] A. Borhanifar, M.M. Kabir, A. HosseinPour, A differential equations by Modified Adomian
Numerical Method for Solution of the Heat Equation decomposition method, Advances in Intelligent
with Nonlocal Nonlinear Condition, World Applied Transportation Systems, Vol. 1, No. 4, 2012
Sciences Journal 13 (11): 2405-2409, 2011.
[25] Xiao-Jun Yang, Heat Transfer in Discontinuous
[12] P. Dawkins, "Differential Equations." Chapter 6, Media, Advances in Mechanical Engineering and its
http://tutorial.math.lamar.edu/terms.aspx, 2007 Applications, Vol. 1, No. 3, 2012

[13] N.H. Sweilam, A.M. Nagy, Numerical Solution of [26] Xinxiu Li, Numerical solution of fractional partial
Fractional Wave Equation using Crank-Nicholson differential equations using cubic B-spline wavelet
Method, World Applied Sciences Journal 13 (Special collocation method, Advances in Computational
Issue of Applied Math): 71-75, 2011. Mathematics and its Applications, Vol. 1, No. 3, 2012

[14] M. Gülsu, Y. Öztürk, M. Sezer, Numerical Solution


of Singular Integra-differential Equations with Cauchy
Kernel, World Applied Sciences Journal 13 (12): 2420-
2427, 2011.

[15] E. Kreyszig, "Advanced Engineering Mathematics",


Wiley. ISBN 978-0470084847, 2006

[16] T. Mohyud-Din, A. Yildirim, M. Berberler, M.


Hosseini, Numerical Solution of Modified Equal Width
Wave Equation, World Applied Sciences Journal 8 (7):
792-798, 2010.

[17] M. Delkhosh, The Conversion a Bessel’s Equation


to a Self-Adjoint Equation and Applications, World
Applied Sciences Journal 15 (12): 1687-1691, 2011.

[18] B. Raftari, Numerical Solutions of the Linear


Volterra Integro-differential Equations: Homotopy
Perturbation Method and Finite Difference Method,
World Applied Sciences Journal 9 (Special Issue of
Applied Math): 07-12, 2010.

You might also like