intfactor - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


DEtools

  

intfactor

  

look for integrating factors for a given ODE

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

intfactor(ODE, y(x), _mu = int_factor_form, try_hard=true)

Parameters

ODE

-

ordinary differential equation (any order)

y(x)

-

(optional) dependent variable; required when the ODE contains more than one function being differentiated

try_hard = true

-

(optional) to search for integrating factors depending on n-1 variables, where n is the ODE order

_mu = int_factor_form

-

(optional) to search for integrating factors having the indicated form

Description

• 

For a given nth order ODE

ODENx,y,y' ,...,yn1yn+Mx,y,y' ,...,yn1=0

  

intfactor looks for integrating factors -- say mu -- such that mu*ODE is an exact ODE, that is, a total derivative with respect to x, of some function R of x, y, and its derivatives up to order n1. As a rule, intfactor first isolates the highest derivative, and then looks for the mus. When successful, intfactor returns mu or a sequence of them; otherwise it returns NULL. To see the PDE satisfied by mu in the general case, use odepde and gensys.

• 

The knowledge of an integrating factor -- say mu -- is sufficient to reduce the order of a given ODE by one; in the case of first order ODEs this reduction of order leads directly to their solution. The reduced ODEs obtained from the knowledge of mu are also called first integrals and can be computed by using the firint command (see examples below).

• 

By default intfactor looks for "as many" integrating factors as the differential order of the given ODE, and it returns an answer as soon as these integrating factors are found, or when all its schemes have already been tried.

• 

In the case of first order ODEs, an integrating factor depending on only the dependent or the independent variable -- say x and y -- is calculated as explained in standard textbooks. Integrating factors depending on both x and y are built by first determining pairs of infinitesimals of underlying Lie groups (see symgen) and using this information to build the mus.

• 

In the case of second order ODEs, after isolating y'', intfactor is able to find integrating factors of the form μx,y', μy,y', and μx,y, when they exist. In the μx,y case, it is sometimes necessary to solve an auxiliary second order linear ODE and the success of the command relies on the ability of dsolve in solving that ODE.

• 

In the case of third and higher nth order ODEs, intfactor searches for integrating factors depending on any two of {x,y,y',y'',...yn1}, by formulating and tackling a linear PDE system for mu (see gensys). When integrating factors with such a dependence exist, the success of intfactor in computing them depends on the success of the dsolve and pdsolve commands in solving the differential equations of that PDE system.

• 

Given an nth order ODE and calling intfactor with the optional argument try_hard = true, the routines search for mu depending on any n-1 of {x,y,y',y'',...yn1} by tackling the related linear PDE system for mu as explained in the previous paragraph. Although this "hard" approach widens the chances of success significantly, the number of different mu problems being tackled is equal to the differential order and each of them involves more than two variables, so this approach could be much slower than the default one, especially for ODEs of order 4 or higher.

• 

Apart from the computable integrating factor types described, in the case of second and higher order ODEs, for some particular ODE families, intfactor is able to compute mus depending on all the variables, that is, of the form mux,y,y',...yn1, provided that mu is polynomial in the yn1 derivative. In the particular case of third order ODEs intfactor can in addition compute - when they exist - integrating factors of the form muy'' without restrictions to the functional form of mu.

• 

It is also possible to request to intfactor the search of integrating factors of some predefined form by using the option '_mu = int_factor_form'. In this approach, int_factor_form, could be either an algebraic expression or a list of them, containing unknowns in the form of functions of x,y,y',... and / or any symbols whose values are to be determined. When int_factor_form contains no unknowns, only a direct test of it using mutest is performed to validate or discard the suggestion. When the indicated form contains unknowns, intfactor sets up a related algebraic/ODE/PDE system of equations for these unknowns and attempt to solve it using Maple's solve, dsolve and pdsolve commands. This option is particularly useful when the intfactor algorithms fail in finding any integrating factor, but you have some idea of the functional form of such factors (see example at the end of this page).

• 

When, for a given high order ODE, many integrating factors are returned, the sequence of mus can be used to reduce the given ODE by many orders at once. Note however that sometimes not all of the integrating factors lead to "different" reductions of order. The reason is that if mu leads to a reduced ODE -- say R1 -- then fR1μ, where f is an arbitrary function, is also an integrating factor and leads to the same reduced ODE. Hence, different subroutines may find different integrating factors which are actually leading to just one reduction of order. To determine if two integrating factors lead to different reductions of order, you can first calculate the related first integrals using firint - see examples.

• 

From a given ODE and an integrating factor for it, you can compute the integrating factor of another ODE, obtained from the first one by performing any arbitrary change of variables. To compute this integrating factor for the changed ODE, use muchange. To test whether an expression is an integrating factor for a given ODE, use the mutest command.

• 

The intfactor command is in some sense complementary to the redode command in that the output of one of them is the input for the other one and vice versa.

• 

This function is part of the DEtools package, and so it can be used in the form intfactor(..) only after executing the command with(DEtools). However, it can always be accessed through the long form of the command by using DEtools[intfactor](..).

Examples

withDEtools:

PDEtoolsdeclareyx,prime=x

yxwill now be displayed asy

derivatives with respect toxof functions of one variable will now be displayed with '

(1)

Here is an ODE depending on an arbitrary function F.

ODEdiffyx,x=2ax2yx+2Fxyx24axa

ODEy'=2ax2y+2Fxy24axa

(2)

A pair of symmetry infinitesimals for this ODE is given by (see symgen):

infinitesimalssymgenODE

infinitesimals_ξ=x2y,_η=2a

(3)

From these infinitesimals, a related integrating factor for ODE is given by:

μintfactorODE

μ2Fxy24axa+yFxy24ax

(4)

Note that when the ODE is given as an equation A=B, it is converted to the form AB=0 before calculating mu.

Let's see the change on the ODE type produced by mu.

odeadvisorODE

_1st_order,_with_symmetry_[F(x),G(y)]

(5)

odeadvisorμODE

_exact,_1st_order,_with_symmetry_[F(x),G(y)]

(6)

Here is a second order example with two integrating factors. Its solution is obtained using them to reduce the ODE order by two at once.

ODE2diffyx,x,x12yx4+yxxx2yxdiffyx,x12xdiffyx,x2

ODE2y''y4+yx2x2yy'y'2x2

(7)

μintfactorODE2

μx2ⅇyx2,ⅇyx2x

(8)

odeadvisorμ1ODE2

_2nd_order,_exact,_nonlinear,_2nd_order,_with_linear_symmetries,_2nd_order,_reducible,_mu_xy

(9)

firintμ1ODE2

ⅇyx26+yx+x2ⅇyx2y'+_C1=0

(10)

firintμ2ODE2

ⅇyx2yx2+ⅇyx2y'x+_C1=0

(11)

Eliminating y' from these two first integrals and renaming  _C1_C2 in one of them we obtain the ODE solution; this process is performed internally by dsolve to arrive at:

dsolveODE2

y=2lnc__2x36c__16x

(12)

A third order ODE example and two integrating factors for it:

ODE3diffyx,x,x,x=diffyx,xx+yxdiffyx,x,xyxx

ODE3y'''=y'x+yy''yx

(13)

μintfactorODE3

μ1yx,1y''

(14)

odeadvisor1yxxODE3

_3rd_order,_exact,_nonlinear,_3rd_order,_with_linear_symmetries,_3rd_order,_reducible,_mu_y2,_3rd_order,_reducible,_mu_poly_yn

(15)

For ODE3 above, using its defaults intfactor found two integrating factors. If however we use the try_hard=true option, an integrating factor depending on an arbitrary function  _F1y''x y is obtained.

intfactorODE3,try_hard

1y'',f__1y''yxyx

(16)

Integrating factors can be tested using mutest, which returns zero when the integrating factor is correct, meaning that it cancels the appropriate integrating factor PDE system (see odepde).

mapDEtoolsmutest,,ODE3

0,0

(17)

A fourth order ODE example and an integrating factor polynomial in the highest possible derivative y''' (for an ODE of order n, mu can depend at most on the nth-1 derivative).

ODE4diffyx,x,x,x,x=12x2diffyx,x,xdiffyx,x,x,x2lnx2diffyx,xdiffyx,x,x,x2lnx2xyx3x2diffyx,x2diffyx,x,x,x2lnx2yx2+2yx+2diffyx,xlnxxlnx2yx3x2diffyx,xdiffyx,x,x,x

ODE4y''''=x2y''y'''2lnx2y'y'''2lnx2xy3x2y'2y'''2lnx2y2+2y+2y'lnxx2lnx2y3x2y'y'''

(18)

μintfactorODE4

μy'y'''xy

(19)

A second order ODE with three integrating factors:

odediffdiffyx,x,x=1xdiffyx,x2yx+xdiffyx,xyx

odey''=y'2y+y'xxy

(20)

μintfactorode

μyx,x2y,1y'

(21)

Of the three integrating factors found, only two of them lead to different reductions of order. The reduction obtained using μ1 is as follows.

R1firintμ1ode,yx

R1y22+y'xy+c__1=0

(22)

explicit_R1diffyx,x=solveR1,diffyx,x

explicit_R1y'=y2+2c__12yx

(23)

The reduction obtained using μ2:

R2firintμ2ode,yx

R2yy'x2+c__1=0

(24)

explicit_R2diffyx,x=solveR2,diffyx,x

explicit_R2y'=c__1x2y

(25)

The reduction obtained using μ3:

R3firintμ3ode,yx

R3lny'+lny+2lnx+c__1=0

(26)

explicit_R3diffyx,x=solveR3,diffyx,x

explicit_R3y'=1ⅇc__1yx2

(27)

When the algorithms implemented in intfactor fail in computing integrating factors - or to investigate the existence of more or different type of integrating factors - we can give a hint to intfactor by using the option _mu = some_mu_form, where some_mu_form contains some unknowns - functions of the ODE variables or just symbols - whose values are to be determined. For example, for the following ODE we use intfactor to compute - if possible - integrating factors of the form xfy,y' for some function fy,y' to be determined.

odediffyx,x,x=yx+xdiffyx,x+2xyxdiffyx,x+x2diffyx,x2diffyx,xyxx

odey''=y+y'x+2y'xy+x2y'2y'xy

(28)

intfactorode,_μ=xfy,_y1

xyy'2,xyEi12yy'2

(29)

mapDEtoolsmutest,,ode

0,0

(30)

In this example, we indicate a form for the integrating factor which depends on 4 symbolic constants k1 to k4 to be determined.

odediffyx,`$`x,4=2diffyx,x2diffyx,`$`x,3+diffyx,x3diffyx,`$`x,3+diffyx,`$`x,3diffyx,x,xdiffyx,x2+yxdiffyx,x+diffyx,x2xdiffyx,x,xyxxdiffyx,x2x+yx+diffyx,x

odey''''=2y'2y'''+y'3y'''+y'''y''y'2+yy'+y'2xyxy''y'2x+y+y'

(31)

hint_μ=k1x+k2y+k3_y1+k4_y2+k5_y3

hint_μ=k3_y1+k4_y2+k5_y3+k1x+k2y

(32)

intfactorode,hint

x+y+y'

(33)

See Also

DEtools

DEtools[equinv]

DEtools[firint]

DEtools[gensys]

DEtools[mutest]

DEtools[odeadvisor]

DEtools[odepde]

DEtools[redode]

DEtools[symgen]

DEtools[symtest]

dsolve

odetest

PDEtools

PDEtools[dchange]