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

Online Help

All Products    Maple    MapleSim


DEtools

  

convertsys

  

convert a system of differential equations to a first-order system

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

convertsys(deqns, inits, vars, ivar, yvec, ypvec)

Parameters

deqns

-

ordinary differential equation, or set or list of equations; can be specified as expressions, which are assumed equal to zero

inits

-

set or list of initial conditions

vars

-

function or list or set of functions; dependent variables of the system

ivar

-

independent variable

yvec

-

(optional) name to be used for the solution vector in the first-order system

ypvec

-

(optional) name to be used for the yvec' vector in the first-order system

Description

• 

DEtools[convertsys] converts a system of one or more ordinary differential equations to a system of first-order differential equations. Corresponding initial conditions (if specified) are also converted.

• 

The initial conditions inits must each be of the form function = expression.  See examples below. Note: if no initial conditions are available, inits must still be specified as {} or [].

• 

The convertsys command returns a list eqnlist,Ydefs,x0,Y0 where

  

* eqnlist is the list of equations representing the first-order system Y'x=fx,Yx in which the Y vector is specified by yvec1,...,yvecneqns and the Y' vector by ypvec1,...,ypvecneqns.

  

* Ydefs is the list of equations defining the yveci names in terms of the original functions.

  

* x0 is the point at which the initial conditions are specified. It is returned as undefined if inits is the empty set.

  

* Y0 is a list representing the vector of initial conditions (possibly empty).  Only one of the initial conditions needs to be specified for this list to be nonempty.  Note that the ordering of Y0 matches that of Ydefs, not that of inits.

• 

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

Examples

withDEtools:

deq1diffyt,`$`t,2=ytxt,diffxt,t=xt:

init1y0=1,Dy0=2,x0=3:

convertsysdeq1,init1,xt,yt,t,y,y_p

y_p1=y1,y_p2=y3,y_p3=y2y1,y1=xt,y2=yt,y3=ⅆⅆtyt,0,3,1,2

(1)

deq2D3yx=yxx:

init2y0=3,Dy0=2,D2y0=1:

convertsysdeq2,init2,yx,x

YP1=Y2,YP2=Y3,YP3=Y1x,Y1=yx,Y2=ⅆⅆxyx,Y3=ⅆ2ⅆx2yx,0,3,2,1

(2)

deq3diffyt,`$`t,2=100exp10t+exp10t:

convertsysdeq3,,yt,t,V

YP1=V2,YP2=100ⅇ10t+100ⅇ10t,V1=yt,V2=ⅆⅆtyt,undefined,

(3)

convertsysdeq3,Dy0=1,yt,t,V

YP1=V2,YP2=100ⅇ10t+100ⅇ10t,V1=yt,V2=ⅆⅆtyt,0,y0,1

(4)

See Also

DEtools