GenerateSimilarODE - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Mozilla Firefox.

Online Help

All Products    Maple    MapleSim


RandomTools

  

GenerateSimilarODE

  

create a random differential equation similar to the one given

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

GenerateSimilarODE( eqn )

Parameters

eqn

-

differential equation with one dependent and one independent variable

Description

• 

The GenerateSimilarODE command takes an ordinary differential equation (ODE) eqn with 1 dependent and 1 independent variable and returns a similar ODE in the same variables.

• 

Linear ordinary differential equations with constant coefficients that have order higher than 1 return a linear ordinary differential equations with constant coefficients that have similar roots to the characteristic polynomial of the ODE. Each real root in eqn will have a corresponding real root in the output ODE, each repeated root in eqn will correspond to a repeated root in the output ODE. A pair of complex conjugate roots in eqn will correspond to a pair of complex conjugate roots in the output ODE.

• 

Linear ordinary differential equations with constant coefficients that have order higher than 1 and a forcing function that contains functions that are linearly dependent to the solution of the homogeneous ODE produce an ODE with the similar roots described above and a forcing function that has functions that are linearly dependent to the solutions of the homogeneous output ODE.   

• 

Bessel differential equations or differential equations that can be converted into Bessel differential equations return Bessel differential equations or differential equations that can be converted into Bessel differential equations.

• 

Differential equations that when solved produce terminating Legendre polynomials return differential equations that when solved produce terminating Legendre polynomials.

• 

Differential equations that when solved produce terminating Laguerre polynomials return differential equations that when solved produce terminating Laguerre polynomials.

• 

Chebyshev differential equations produce Chebyshev differential equations.

Examples

> 

with⁡RandomTools:

> 

ODE1≔%diff⁡y⁡x,x⁢y⁡x+sin⁡x=exp⁡x⁢y⁡x

ODE1≔ⅆⅆxy⁡x⁢y⁡x+sin⁡x=ⅇx⁢y⁡x

(1)
> 

GenerateSimilarODE⁡ODE1

4⁢ⅆⅆxy⁡x⁢y⁡x−9⁢cos⁡x=−7⁢ⅇ−6⁢x⁢y⁡x

(2)

2nd order linear ODE with constant coefficients with a characteristic polynomial that has real roots.

> 

ODE2≔%diff⁡y⁡x,`$`⁡x,2+%diff⁡y⁡x,x−6⁢y⁡x=0

ODE2≔ⅆ2ⅆx2y⁡x+ⅆⅆxy⁡x−6⁢y⁡x=0

(3)
> 

dsolve⁡ODE2

y⁡x=c__1⁢ⅇ2⁢x+c__2⁢ⅇ−3⁢x

(4)
> 

newODE2≔GenerateSimilarODE⁡ODE2

newODE2≔19⁢ⅆⅆxy⁡x−ⅆ2ⅆx2y⁡x−90⁢y⁡x=0

(5)
> 

dsolve⁡newODE2

y⁡x=c__1⁢ⅇ9⁢x+c__2⁢ⅇ10⁢x

(6)

2nd order linear ODE with constant coefficients with a repeated root.

> 

ODE3≔%diff⁡y⁡x,`$`⁡x,2−6⁢%diff⁡y⁡x,x+9⁢y⁡x=0

ODE3≔ⅆ2ⅆx2y⁡x−6⁢ⅆⅆxy⁡x+9⁢y⁡x=0

(7)
> 

dsolve⁡ODE3

y⁡x=c__1⁢ⅇ3⁢x+c__2⁢ⅇ3⁢x⁢x

(8)
> 

newODE3≔GenerateSimilarODE⁡ODE3

newODE3≔−16⁢ⅆⅆxy⁡x+ⅆ2ⅆx2y⁡x+64⁢y⁡x=0

(9)
> 

dsolve⁡newODE3

y⁡x=c__1⁢ⅇ8⁢x+c__2⁢ⅇ8⁢x⁢x

(10)

2nd order linear ODE with a pair of complex conjugate roots.

> 

ODE4≔%diff⁡y⁡x,`$`⁡x,2−2⁢%diff⁡y⁡x,x+2⁢y⁡x=0

ODE4≔ⅆ2ⅆx2y⁡x−2⁢ⅆⅆxy⁡x+2⁢y⁡x=0

(11)
> 

dsolve⁡ODE4

y⁡x=c__1⁢ⅇx⁢sin⁡x+c__2⁢ⅇx⁢cos⁡x

(12)
> 

newODE4≔GenerateSimilarODE⁡ODE4

newODE4≔−20⁢ⅆⅆxy⁡x+ⅆ2ⅆx2y⁡x+101⁢y⁡x=0

(13)
> 

dsolve⁡newODE4

y⁡x=c__1⁢ⅇ10⁢x⁢sin⁡x+c__2⁢ⅇ10⁢x⁢cos⁡x

(14)

2nd order linear ODE with forcing function that contains a function that is linearly dependent to a solution to the homogeneous ODE.

> 

ODE5≔%diff⁡y⁡x,`$`⁡x,2+%diff⁡y⁡x,x−6⁢y⁡x=x⁢exp⁡2⁢x

ODE5≔ⅆ2ⅆx2y⁡x+ⅆⅆxy⁡x−6⁢y⁡x=x⁢ⅇ2⁢x

(15)
> 

dsolve⁡ODE5

y⁡x=ⅇ2⁢x⁢c__2+ⅇ−3⁢x⁢c__1+ⅇ2⁢x⁢x⁢5⁢x−250

(16)
> 

newODE5≔GenerateSimilarODE⁡ODE5

newODE5≔−18⁢ⅆⅆxy⁡x−ⅆ2ⅆx2y⁡x−80⁢y⁡x=−10⁢x⁢ⅇ−8⁢x

(17)
> 

dsolve⁡newODE5

y⁡x=ⅇ−8⁢x⁢c__2+ⅇ−10⁢x⁢c__1+5⁢x⁢x−1⁢ⅇ−8⁢x2

(18)

Bessel differential equation.

> 

ODE6≔x2⁢%diff⁡y⁡x,`$`⁡x,2+x⁢%diff⁡y⁡x,x+x2⁢y⁡x=0

ODE6≔x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2⁢y⁡x=0

(19)
> 

dsolve⁡ODE6

y⁡x=c__1⁢BesselJ⁡0,x+c__2⁢BesselY⁡0,x

(20)
> 

newODE6≔GenerateSimilarODE⁡ODE6

newODE6≔x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2−36⁢y⁡x=0

(21)
> 

dsolve⁡newODE6

y⁡x=c__1⁢BesselJ⁡6,x+c__2⁢BesselY⁡6,x

(22)
> 

ODE7≔x2⁢%diff⁡y⁡x,`$`⁡x,2+x⁢%diff⁡y⁡x,x+x2−9⁢y⁡x=0

ODE7≔x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2−9⁢y⁡x=0

(23)
> 

dsolve⁡ODE7

y⁡x=c__1⁢BesselJ⁡3,x+c__2⁢BesselY⁡3,x

(24)
> 

newODE7≔GenerateSimilarODE⁡ODE7

newODE7≔x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2−49⁢y⁡x=0

(25)
> 

dsolve⁡newODE7

y⁡x=c__1⁢BesselJ⁡7,x+c__2⁢BesselY⁡7,x

(26)

ODEs that can be converted to a Bessel differential equation.

> 

ODE8≔x2⁢%diff⁡y⁡x,`$`⁡x,2+2⁢x⁢%diff⁡y⁡x,x+x2⁢y⁡x=0

ODE8≔x2⁢ⅆ2ⅆx2y⁡x+2⁢x⁢ⅆⅆxy⁡x+x2⁢y⁡x=0

(27)
> 

dsolve⁡ODE8

y⁡x=c__1⁢sin⁡xx+c__2⁢cos⁡xx

(28)
> 

newODE8≔GenerateSimilarODE⁡ODE8

newODE8≔x2⁢ⅆ2ⅆx2y⁡x+3⁢x⁢ⅆⅆxy⁡x+x2−4⁢y⁡x=0

(29)
> 

dsolve⁡newODE8

y⁡x=c__1⁢BesselJ⁡5,xx+c__2⁢BesselY⁡5,xx

(30)
> 

ODE9≔2⁢x2⁢%diff⁡y⁡x,`$`⁡x,2+x⁢%diff⁡y⁡x,x+x2⁢y⁡x=0

ODE9≔2⁢x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2⁢y⁡x=0

(31)
> 

dsolve⁡ODE9

y⁡x=c__1⁢x14⁢BesselJ⁡14,2⁢x2+c__2⁢x14⁢BesselY⁡14,2⁢x2

(32)
> 

newODE9≔GenerateSimilarODE⁡ODE9

newODE9≔5⁢x2⁢ⅆ2ⅆx2y⁡x+x⁢ⅆⅆxy⁡x+x2−4⁢y⁡x=0

(33)
> 

dsolve⁡newODE9

y⁡x=c__1⁢x25⁢BesselJ⁡2⁢65,5⁢x5+c__2⁢x25⁢BesselY⁡2⁢65,5⁢x5

(34)

Terminating Laguerre polynomials.

> 

ODE10≔x⁢%diff⁡y⁡x,`$`⁡x,2+1−x⁢%diff⁡y⁡x,x+y⁡x=0

ODE10≔x⁢ⅆ2ⅆx2y⁡x+1−x⁢ⅆⅆxy⁡x+y⁡x=0

(35)
> 

dsolve⁡ODE10

y⁡x=c__1⁢x−1+c__2⁢x−1⁢Ei1⁡−x+ⅇx

(36)
> 

newODE10≔GenerateSimilarODE⁡ODE10

newODE10≔x⁢ⅆ2ⅆx2y⁡x+1−x⁢ⅆⅆxy⁡x+2⁢y⁡x=0

(37)
> 

dsolve⁡newODE10

y⁡x=c__1⁢x2−4⁢x+2+c__2⁢x2−4⁢x+2⁢Ei1⁡−x4+ⅇx⁢x−34

(38)
> 

ODE11≔x⁢%diff⁡y⁡x,`$`⁡x,2+1−x⁢%diff⁡y⁡x,x+5⁢y⁡x=0

ODE11≔x⁢ⅆ2ⅆx2y⁡x+1−x⁢ⅆⅆxy⁡x+5⁢y⁡x=0

(39)
> 

dsolve⁡ODE11

y⁡x=c__1⁢x5−25⁢x4+200⁢x3−600⁢x2+600⁢x−120+c__2⁢x5−25⁢x4+200⁢x3−600⁢x2+600⁢x−120⁢Ei1⁡−x600+ⅇx⁢x4−24⁢x3+177⁢x2−444⁢x+274600

(40)
> 

newODE11≔GenerateSimilarODE⁡ODE11

newODE11≔x⁢ⅆ2ⅆx2y⁡x+1−x⁢ⅆⅆxy⁡x=0

(41)
> 

dsolve⁡newODE11

y⁡x=c__1+Ei1⁡−x⁢c__2

(42)

Terminating Legendre polynomials.

> 

ODE12≔1−x2⁢%diff⁡y⁡x,`$`⁡x,2−2⁢x⁢%diff⁡y⁡x,x+6⁢y⁡x=0

ODE12≔−x2+1⁢ⅆ2ⅆx2y⁡x−2⁢x⁢ⅆⅆxy⁡x+6⁢y⁡x=0

(43)
> 

dsolve⁡ODE12

y⁡x=c__1⁢−3⁢x2+1+c__2⁢3⁢x2−1⁢ln⁡x−12+−3⁢x2+1⁢ln⁡x+12+3⁢x

(44)
> 

newODE12≔GenerateSimilarODE⁡ODE12

newODE12≔−x2+1⁢ⅆ2ⅆx2y⁡x−2⁢x⁢ⅆⅆxy⁡x−y⁡x−x2+1=0

(45)
> 

dsolve⁡newODE12

y⁡x=c__1⁢x−x2+1+c__2−x2+1

(46)
> 

ODE13≔1−x2⁢%diff⁡y⁡x,`$`⁡x,2−2⁢x⁢%diff⁡y⁡x,x+12⁢y⁡x=0

ODE13≔−x2+1⁢ⅆ2ⅆx2y⁡x−2⁢x⁢ⅆⅆxy⁡x+12⁢y⁡x=0

(47)
> 

dsolve⁡ODE13

y⁡x=c__1⁢−53⁢x3+x+c__2⁢−19+5⁢x3−3⁢x⁢ln⁡x−124+−5⁢x3+3⁢x⁢ln⁡x+124+5⁢x212

(48)
> 

newODE13≔GenerateSimilarODE⁡ODE13

newODE13≔−x2+1⁢ⅆ2ⅆx2y⁡x−2⁢x⁢ⅆⅆxy⁡x+20⁢y⁡x=0

(49)
> 

dsolve⁡newODE13

y⁡x=c__1⁢353⁢x4−10⁢x2+1+c__2⁢35⁢x4−30⁢x2+3⁢ln⁡x−16+−35⁢x4+30⁢x2−3⁢ln⁡x+16+35⁢x33−55⁢x9

(50)

Chebyshev differential equation.

> 

ODE14≔1−x2⁢%diff⁡y⁡x,`$`⁡x,2−x⁢%diff⁡y⁡x,x+25⁢y⁡x=0

ODE14≔−x2+1⁢ⅆ2ⅆx2y⁡x−x⁢ⅆⅆxy⁡x+25⁢y⁡x=0

(51)
> 

dsolve⁡ODE14

y⁡x=c__1x+x2−15+c__2⁢x+x2−15

(52)
> 

newODE14≔GenerateSimilarODE⁡ODE14

newODE14≔−x2+1⁢ⅆ2ⅆx2y⁡x−x⁢ⅆⅆxy⁡x+36⁢y⁡x=0

(53)
> 

dsolve⁡newODE14

y⁡x=c__1x+x2−16+c__2⁢x+x2−16

(54)

Compatibility

• 

The RandomTools[GenerateSimilarODE] command was introduced in Maple 2021.

• 

For more information on Maple 2021 changes, see Updates in Maple 2021.

See Also

HowDoI,WorkWithRandomGenerators

InertForm

rand

RandomTools

RandomTools[Generate]

RandomTools[GenerateSimilar]

randpoly