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

Online Help

All Products    Maple    MapleSim





split into cases and sequentially decouple a system of equations taking into account its integrability conditions


Calling Sequence





Calling Sequence

casesplit(sys, optional_1, optional_2,...)




single DE, or list or set of DEs; any system of differential equations

optional_1, optional_2, ...


(optional) arguments can be given in any order and are described as follows



list or set of solving variables represented by names or functions, or list or set of them



indicates that in addition to the splitting into cases a graphical representation of the splitting is to be plotted

ivars={y1, y2, ...}


indicates that {y1, y2,...} are independent variables regardless of whether they appear in the unknowns of the system

ivars=[y1, y2, ...]


the right-hand side is a list; indicates the ranking ordering for the independent variables



useful to produce ODEs from PDEs, indicates the use of an elimination ranking for the independent variables instead of the default orderly one

lex(f(y1, y2...)


indicates the elimination ranking ordering of the independent variables to be as in f



P is a list or set of names or functions that are solving variables with lower priority than any other variable



if boolean = true then run only one round of computations; if false run always two, otherwise let casesplit decide



avoid the computation of the singular cases when the system is nonlinear



avoid splitting into cases with respect to elements of A, where A is a list or set of names or functions



compute with a timelimit of N seconds per case



discard cases with solution space of dimension less than N

rankingused = ...


the right-hand side is a name that will be assigned the ranking used for the unknowns of the system

ivarsused = ...


the right-hand side is a name that will be assigned the independent variables of the system with the ordering they were ranked



default, force splitting by using the Rif subpackage of DEtools



force splitting by using the DifferentialAlgebra package



The casesplit function receives one DE,  or a set or a list of DEs (it is also possible to include inequations and non-differential equations) and splits the system into regular systems associated with different cases. The union of the non-singular solutions of these regular systems returned is equal to the full set of solutions, including the singular ones, of the original input system. Each regular system automatically satisfies all the integrability conditions. The splitting into cases is performed by using the Rif subpackage of DEtools (default), or using the DifferentialAlgebra package when the keyword 'diffalg' is given as an optional argument. casesplit also works with anticommutative variables set using the Physics package using the approach explained in PerformOnAnticommutativeSystem.


The casesplit command is useful for studying the different cases of a given DE system, uncoupling the system in different ways using different orderings for the solving variables (rankings), and determining whether the system is inconsistent. The casesplit command can also be used to remove redundancies and to make the system complete, including simplifying it by using all its integrability conditions. All these tasks are automatically performed each time casesplit is invoked.


Ranking is a fundamental concept related to the splitting process performed through casesplit. A ranking is basically an ordering of the variables of the problem (herein called solving variables) in the form of a list of functions or symbol variables, as in fx,gx,hx,a (one can also specify functions by using only their names as in f,g,h,a). Different rankings imply different uncoupling orderings and, hence, different manners of splitting and uncoupling the DE system (see checkrank, DifferentialAlgebra[Tools][Display], and the examples below).


In the case of a system of ordinary differential equations (ODEs), provided the system is not subdetermined, the default output of casesplit consists of a sequence of uncoupled ODE systems, where the uncoupling ordering used is that of the solving variables in the ranking. The ranking is provided by the user as a list or automatically set by casesplit. That means, for instance, that if a system depending on the functions fx,gx,hx is given with this list as ranking, the equations in each returned system are of the form [..fx..=..fx,gx,hx..,..gx=..gx,hx..,..hx..=..hx]. So, the last equation involves only hx, the next to the last equation involves gx and hx, and the first equation involves the three functions. This is called sequential uncoupling.


In the case of a system of partial differential equations (PDEs), the situation is the same as with ODEs but the concept of sequential uncoupling requires clarification. Concretely, instead of one equation related to each function, one could receive many equations. For instance, if a system depending on the functions fx,y,z,gx,y,z,hx,y,z is given and with this list as ranking, the equations in each returned system are of the form [eqsf=..f,g,h..,eqsg=..g,h..,eqsh=..h..], where eqsh=..h.. means equations (possibly PDEs) only depending on 'h' and so on.


The casesplit command also works with systems of equations that involve mathematical functions, provided that they have a differential equation representation that is rational in the independent variables, the function and its derivatives - i.e a differential polynomial form. That is indeed the case of most of the mathematical functions as well as of indefinite integrals, fractional and symbolic (generic) powers. For example, the exponential function, fx=ⅇx satisfies f '=f. When these functions are present in the system, they are replaced by auxiliary unknowns representing them and the corresponding differential equations they satisfy are added to the system, the system is processed, and before returning these auxiliary unknowns are replaced by the actual functions they represent.


The arguments of mathematical functions present in the system can be arbitrary algebraic expressions, possibly including other mathematical functions, with no limits to the levels of nesting, for example: gx=ⅇBesselJn,x. These cases are processed by first performing changes of variables that result in a differential polynomial form representing the expression, then proceeding as explained in the previous item.


The casesplit command also works with systems that involve unknown functions whose arguments are not just variables (i.e.: of type name) but generic algebraic expressions. Provided that some conditions are met, through changes of variables the system of equations can be transformed into an equivalent system where the transformed functions all depend on simple variables of type name, this system is processed, a further change of variables to revert to the original variables is performed, and the result is returned.


Finally, casesplit works as well with systems that involve D derivatives evaluated at points represented by algebraic expressions. The key idea is that any D derivative of this type can be mapped into a function of variables not of type name that can in turn be represented in differential polynomial form as a first order PDE, obtained by running backwards what is know as the PDE characteristic strip solving method. This approach makes it possible to perform differential elimination with these objects, as well as solving PDE systems in terms of arbitrary functions, that, at some point in the solving process, become functions of algebraic expressions (variables not of type name) and where the intermediate subsystem involves D derivatives of these functions.

Input and Output


The first argument sys can be one DE, or a set or a list of DEs, possibly including inequations and non-differential equations (such as algebraic constraints). Equations are entered by using expr1=expr2, or expr1. In this case it is assumed that expr1 = 0. Inequations are entered by using expr1expr2.


The output of casesplit is a sequence of expressions representing the different cases (possibly only one) and corresponding equations and inequations (these are the ones returned by the corresponding Equations and Inequations commands of DifferentialAlgebra). Each case is returned as a function of two operands and displayed as &lsqb;eq1,eq2,...&rsqb;&where&lsqb;ineq10,ineq20,...&rsqb;. Both operands are lists. This printing is obtained, however, by using a print/foo mechanism, and the true structure of each returned case is a function `casesplit/ans`( [ eq1, eq2, ...], [ ineq1 <> 0, ineq2 <> 0, ...] ).


The actual splitting of a system obtained when calling casesplit is basically computed through various calls to different commands of the DifferentialAlgebra package, or optionally the DEtools[Rif] package. These are the two Maple differential elimination packages.


Apart from simplifying the steps required by a direct use of DifferentialAlgebra, casesplit radically extends the domain of computation of DifferentialAlgebra or DEtools[Rif]. Concretely, casesplit can split a system into regular cases even when this system contains non-polynomial objects, such as fractional or abstract powers, most Maple known functions (for example, exponentials, logarithms, trigonometric, and special functions) and also any arbitrary composition of these non-polynomial objects, for example, expsqrtBesselJ....


This extension of the domain of computation is performed by rewriting all non-polynomial objects by using auxiliary functions of the form _Fn (n being an integer) and adding to the input system the polynomial (algebraic and differential) equations these _Fn functions satisfy (see dpolyform). For example, &ExponentialE;x is replaced by _F1x, and the auxiliary ODE &DifferentialD;2&DifferentialD;x2_F1x=_F1x is added to the system. These auxiliary functions, the equations they satisfy, and their consequences are removed before returning the output.

Optional arguments


All arguments after the first one are optional and can be included in any order.


When the solving variables are not specified, casesplit takes all unknown functions found in the DE system as solving variables, and uses its own heuristic methods to determine what could be the best uncoupling ordering for the given system. However, it is possible to specify a ranking, which indicates the solving variables and their order. When the ranking to be specified involves only one variable, it can be given as this variable, or its name, for example, f for fx&comma;y&comma;z. In all cases the ranking can be specified as a list or a set of solving variables, functions can be indicated by only their names, and this set or list can include 'symbol' solving variables (equivalent to functions with all derivatives equal to zero).


When the ranking is given as a set or list, each of its elements can, in turn, also be a set or list of names or functions. For example, f&comma;g&comma;h&comma;j&comma;k, f&comma;g&comma;h&comma;j&comma;k, and h&comma;f&comma;g&comma;j&comma;k are valid rankings. In such cases, the solving ordering for the elements inside each set {...} is decided by casesplit. Only one level of nested list or sets is allowed.


Using standard terminology, a ranking as in f&comma;g&comma;h - also called lexicographic or elimination ranking - leads to a splitting using a lexicographic ordering. When a ranking is given as a nested list, for example f&comma;g&comma;h, the splitting is performed by using a total degree ordering. These rankings are also called total degree or orderly rankings. Total degree rankings, however, generally do not result in the uncoupling of the given system. They simplify the system by using integrability conditions, and so check for inconsistencies as well as lead to a version of the system with the lowest differential order. This usually leads to faster computations than when using lexicographic ordering. To understand the meaning associated with a given ranking, use the checkrank or DifferentialAlgebra[Tools][Display] commands. Input rankings in casesplit have exactly the same meaning they have in calls to commands of the DifferentialAlgebra package.


When the ranking is not specified, you can see the ranking used by setting infolevel[casesplit] := 2. Setting this variable to 3 causes the display of the input sent to RosenfeldGroebner or DEtools[rifsimp], as well.


The independent variables of a given system are determined by default as the variables on which the unknown functions of the system depend. However, there may be cases in which other variables, not present in the unknown functions of the system, are also independent variables of the problem. These extra independent variables can be indicated using the ivars = {...} optional argument. In such a case, these variables are added to those determined as the independent variables of the problem. This is useful, for example, when the unknowns of the system depend - say - on x, y, but the equations involve - say - z, and you are not interested in solutions depending on z.


By default, the solving ordering for the independent variables of the system is automatically determined by casesplit, such that lower order differentiation variables are ranked lower. Alternatively, this ordering can be enforced to be anyone using the optional argument ivars = [...], specifying its right-hand side as a list with the desired ordering, leading in most of the cases to slight differences in the output (see DifferentialAlgebra[Tools][Display]).


By default, the ranking used with respect to the independent variables is of orderly type (see paragraphs above). To specify an elimination lexicographical ranking add the keyword lex anywhere in the calling sequence. Combining this option with the ivars = [...] option (right-hand side as a list) is useful to generate ODEs from PDE systems when that is possible. The ODEs appearing in the output are the consequence of using an elimination ranking for the independent variables. When ivars = [...] is not given, but lex is given, the elimination raking is set with the ordering for the independent variables chosen by casesplit; or when lex(f) is given, where f is an unknown of the system, the ordering used for ranking the independent variables will be that of the function f.


By default, all unknown functions found in the system and not indicated in the ranking are considered solving variables "with less priority", and are automatically inserted at the end of the ranking. Note however that symbol variables found in the system require an explicit declaration in the ranking to be considered as "solving variables". "Solving variables" with less priority can also be indicated using the optional argument parameters={...} where the right-hand side can also be a list.


In the case of DE systems, the default strategy of casesplit is to solve the system in two rounds. In the first round, a simpler ranking is used to express the more differentiated solving variables with respect to the other ones. Typically this ranking is built as &lsqb;&lsqb;f1,f2,...&rsqb;&rsqb;, and relies on a faster "total degree" process. In the second round, each of the systems (equations and inequations) obtained in the first round are processed separately, but this time with the ranking given by the user (or set by casesplit if no ranking is given). When the optional argument 'fast' is given, casesplit processes the system in only one round. In such a case, if the ranking is given it is used. Otherwise, the ranking is set as &lsqb;&lsqb;f,g,h,...&rsqb;&rsqb; (that is, total degree ordering) and usually does not lead to an uncoupling of the system.


By default, casesplit splits a nonlinear problem into all the related (perhaps only one) regular cases. This set of regular cases can also be understood as consisting of the main case (general case) plus all the possible singular cases. To avoid spending time in computing these singular cases, one can use the singsol=false optional argument, leading to the computation of only the general case.


By using the optional argument arbitrary=A, where A is a list or set of names or functions, one can force casesplit to avoid considering these functions as solving variables and so avoid splitting into cases with respect to them. This option is quite useful for computations in which the value of some unknown functions must remain arbitrary. It also typically reduces the computation time significantly.


By default, casesplit splits a problem into cases regardless of the time required to compute each case. There are problems, however, for which this default is not practical since some of the cases would take too much time to compute. For these cases, use the ctl=N optional argument to impose a timelimit of N seconds per case, at the cost of missing the output of cases requiring more than N seconds to be computed.


The optional argument mindim=N is useful when we know, in advance, that we are not interested in cases in which the solution space has dimension less than N. This option saves computing time.


If rankingused = .. is passed as argument, where the right-hand side is assignable (e.g., a name), the ranking used for the unknowns will be assigned to that right-hand side.


If ivarsused = .. is passed as argument, where the right-hand side is assignable (e.g., a name), the independent variables of the system, with the ordering they were ranked, will be assigned to that right-hand side.


By default, casesplit makes use of the Rif subpackage of DEtools. In most cases, however, it is possible to perform the same computations by using the DifferentialAlgebra package instead of Rif, by giving the extra argument diffalg. Any of the following optional arguments imply on computations which casesplit can only run using Rif: singsol=false, arbitrary, ctl=N.


The casesplit routine can be used for many different purposes. These examples are organized as follows: first, some typical situations; then, three worked examples in the framework of integrating factors and symmetries for second order ODEs; and finally, an illustration of how different rankings can be used to obtain different results in a DE system with many variables.



For convenience, first declare some functions of t to be displayed using only their names (for example, ft as f), and t as the prime variable (see PDEtools[declare]).


ftwill now be displayed asf

gtwill now be displayed asg

htwill now be displayed ash

jtwill now be displayed asj

ytwill now be displayed asy

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


The splitting of a single nonlinear ODE into three cases (two of them related to singular solutions) is illustrated here.







To see a graphical representation of this splitting use the caseplot option


========= Pivots Legend =========






To identify which of these cases lead to the singular solutions, it suffices to note that singular solutions depend on fewer arbitrary constants, that is, they are solutions to ODEs of lower differential order. If there is only one input equation, it can be given directly (no braces or square brackets are required) and there is no need for a ranking specification.

When there are more variables, the ranking given can lead to different regular systems. For the following example, the ranking was chosen by casesplit's heuristics.




If infolevel is set to a greater integer (possible settings are 1 through 5), more detailed information about the computation method is displayed.





-> Solving ordering to be used: [y, x]

Ranking for 1st round is: [[y, x]]
Ranking for 2nd round is: [y, x]

1st round is performed, original system is split into 1 cases

2nd round is performed; processing answer ...



Here, the results of the other possible ranking, x&comma;y, are shown.


Ranking for 1st round is: [[x, y]]
Ranking for 2nd round is: [x, y]

1st round is performed, original system is split into 1 cases

2nd round is performed, original system is now split into 2 cases. Processing answer ...



This also shows that different rankings may lead to a different number of cases. However, the union of the set of solutions to each case is always equal to the solution to the original problem independent of the ranking used.

The uncoupling of systems with many variables is a more difficult problem. In some cases, as in the following ODE system, the uncoupling ordering determined by casesplit succeeds.





-> Solving ordering to be used: [j, h]

Ranking for 1st round is: [[j, h, f, _F1, g, _F2]]
Ranking for 2nd round is: [j, h, f, _F1, g, _F2]

1st round is performed, original system is split into 2 cases

2nd round is performed; processing answer ...



In the answer above, we see from the displayed information (userinfo) that the ranking chosen by casesplit's heuristics was j&comma;h&comma;f&comma;g. This means that each returned case has j expressed in terms of h,f,g, then h in terms of f,g, f in terms of g and, eventually, a condition on g alone. This is the case for all input systems provided that they are not subdetermined (for instance, too many functions for too few equations).

Regarding the functions _F1 and _F2 displayed in the userinfo, they were introduced to transform the non-polynomial system into a polynomial one by extending the system with auxiliary functions _F1 and _F2 and related auxiliary equations. They are removed before returning the answer. To see the polynomial version of the problem actually processed use the dpolyform command.

It is important to remember that, depending on the input system, the ranking chosen by casesplit heuristics may not be the best one. It could, for example, lead to an uncoupling process with too many large intermediate equations. In such a case, the user's suggestion in the form of a different ranking may solve the problem.

In other cases, independent of the ranking, the differential elimination process may be to expensive in time. For these cases one can use the ctl=N optional argument to impose a timelimit of N seconds per case, at the cost of missing the output of cases requiring more time to compute.




casesplit works with systems involving mathematical functions whose arguments are arbitrary algebraic expressions provided they can be represented in differential polynomial form, which is possible provided that each constituting part of the expression, by itself, admits a differential polynomial form. For example




A differential polynomial form for this expression is




These differential polynomial forms can be verified for correctness as usual using odetest or pdetest when it is the case of PDEs. In this case, we test that fx=&ExponentialE;BesselJν&comma;x satisfies this ODE




So, if such an expression appears in the system of equations received by casesplit its differential polynomial form is constructed as in the above, this equation is added to the system and the expression replaced by the auxiliary unknown fx, this extended system is processed and before returning a result fx is replaced back by the original expression it represented.

When unknown functions whose arguments are algebraic expressions (i.e. not variables of type name) are present in the system, when possible, a change of variables is performed such that the transformed functions all depend on variables of type name, the transformed system is tackled, and a further change of variables to revert to the original variables is performed before the result is returned. For example,




The natural ranking for this system takes H higher than F or G (i.e. write H as a function of the other ones)




Writing F or G as a function of H, however, turns evident the (otherwise implicit) relationship between the derivatives of G (or F) and H. To see this, rank F and G higher H




These arbitrary objects whose arguments are not of type name can appear nested, and provided a differential polynomial form exists for each component of the composition of expressions, a differential polynomial form exists for the composition, and with that casesplit can handle the case when it appears in a given system of equations. For example, a differential polynomial form for this composite expression is:










When the system involves D derivatives evaluated at points that are represented by algebraic expressions, these derivative can be mapped into a function of variables not of type name that can in turn be represented in differential polynomial form as explained in the Description section. This is particularly useful to tackle PDEs. For example




A differential polynomial form for this pde is given by




This is a higher order PDE that can be solved in terms of arbitrary functions




and from this solution, a solution to the original problem can be derived.

A PDE example where we indicate that 'f(x,y,z)' is our solving variable. Hence, hx and gy&comma;z are viewed as function parameters of the problem.







The following is a PDE system which is inconsistent.





Warning: System is inconsistent

A series of worked examples follows.

Worked example I


yxwill now be displayed asy

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





Show that the ode[3] has no integrating factors depending on less than three variables.

There are three possible cases to consider: μ(x,y), μ(x,y'), and μ(y,y'). Starting with μ(x,y), we first set the PDE which must be satisfied by this integrating factor (see odepde).




Now, noting that the PDE above is polynomial in y&apos; and y&apos;&apos; (represented by _y1 and _y2, respectively), take the corresponding coefficients and set each one to zero to obtain a PDE system for μ(x,y). These tasks (setting the determining PDE above and splitting it into a system by setting each coefficient of y&apos;&apos; equal to zero) are automatically performed by gensys.




Taking into account the integrability conditions implicit in the system above, this system simplifies to the following.




This shows that there is no solution other than the trivial μ = 0.

For the case  μ(x,y'):







So, there is no solution of the form μ(x,y'). Finally, for μ(y,y'):







From these three results, we conclude that ode[3] has no integrating factors depending on only two variables.

Worked example II

Show that ode[4] has only one point symmetry, _&xi;=1&comma;_&eta;=0.




First, set up the PDE system for the symmetry (the infinitesimal symmetry generators ξ and η). Again, this can be done by using odepde to obtain the determining PDE and then splitting it by taking coefficients or in one step by using gensys.







The system above has only the solution _&xi;=_C1&comma;_&eta;=0, which is equivalent to _&xi;=1&comma;_&eta;=0.

Worked example III




Determine the conditions on gx such that ode[5] has point symmetries with both infinitesimals different from zero.

First, set up the determining PDE system for the infinitesimals ξ and η.




Note that the dependent variable y is also specified. Otherwise, gensys complains since ode[5] contains derivatives of both y and g, and it cannot determine the dependent variable of the problem. y could be specified as the second argument as well. Now state, using inequations, that both infinitesimals should be different from zero.




Next, run casesplit. In doing so, different rankings could lead to what is wanted. Use ξ&comma;η&comma;g to solve for ξ&comma;η as functions of g, plus separated extra conditions on g alone (these are the conditions we want). When solving for ξ&comma;η, do not uncouple ξ from η. This uncoupling is irrelevant since it would take more time and resources to be computed, and only the conditions on g are wanted.




In the answer above, we see three systems, each one associated to different conditions on gx, and both ξ and η expressed in terms of each other and g.

The last example illustrates the use of different rankings. Consider the following PDE system.




You can assign the ranking for the unknowns and/or the ordering used for the independent variables by passing the optional arguments rankingused = R and/or ivarsused = ii, where the right-hand sides, R and ii, can actually be any assignable objects. For example, discarding the singular cases for simplicity, the triangularization of this system and ranking and ordering of independent variables used for that are: