# Available Methods for DSolve?

I would like to know, apart from Method->Automatic what are available methods for DSolve.

sol = DSolve[equationList, f[t], t, Method -> "Holonomic"]


I discovered only "Holonomic". Are there more available methods and if yes for what kind of problems are they good for? I failed to find anything in the documentation.

• "EvaluateIntegrals" | "InactiveIntegrals" | "Holonomic" | Automatic are the ones I know.... Sep 10, 2022 at 17:26
• For instance, DSolve[x^2 y''[x] + xy'[x] + y[x] == Exp[4 Log [x]], y[x], x, Method -> "EvaluateIntegrals"] takes 400+ sec. and produces the same answer as DSolve[x^2 y''[x] + xy'[x] + y[x] == Exp[4 Log [x]], y[x], x] in around 0.35 sec. "InactiveIntegrals" seems the same as Automatic, and allows Inactive[] integrals, but does not force them. (Example from mathematica.stackexchange.com/questions/258268/…) Sep 10, 2022 at 17:44
• Found another: eqns = {y'[t] == z[t], z'[t] == -10, y == 1, z == 0}; events = {WhenEvent[y[t] == 0, {y[t] -> 0, z[t] -> -(70/100) z[t]}]}; sol = DSolve[Join[eqns, events], {y[t], z[t]}, {t, 0, 2}, Method -> {"Events", "MaxEvents" -> 3}] Sep 10, 2022 at 17:54

### Summary

These are what I've discovered (in V13.1):

Method -> Automatic
Method -> "EvaluateIntegrals"
Method -> "InactiveIntegrals" (* same as Automatic? *)
Method -> {"Events", "MaxEvents" -> n}
Method -> "Holonomic"


I don't believe they can be mixed. If you do, what happens varies. Either DSolve returns unevaluated or the combination is treated as Automatic. For instance, Method -> {"EvaluateIntegrals", {"Events", "MaxEvents" -> 3}} is treated as Automatic in "Events" example and leads to unevaluated DSolve[] in the other examples below. Method parsing does not seem to be as robust as in NDSolve or NIntegrate (probably why IncludeSingularSolutions is a separate option and not a Method option).

### Method -> "EvaluateIntegrals"

The following takes 400+ sec. and produces the same answer as Method -> Automatic, with unevaluated integrals, in this case:

DSolve[x^2 y''[x] + xy'[x] + y[x] == Exp[4 Log [x]], y[x], x,
Method -> "EvaluateIntegrals"]


### Method -> "InactiveIntegrals"

Method -> "InactiveIntegrals" seems the same as Method -> Automatic, and allows Inactive[] integrals, but does not force them. The following takes around 0.35 sec. with either option setting and produces the same result

DSolve[x^2 y''[x] + xy'[x] + y[x] == Exp[4 Log [x]], y[x], x,
Method -> "InactiveIntegrals"]


The foregoing examples are adapted from Help!!! DSolve is coming out weirdly

### Method -> {"Events", "MaxEvents" -> 3}

The following is adapted from the docs for DSolve and without the "MaxEvents" constraint produces a Piecewise solution with five cases.

eqns = {y'[t] == z[t], z'[t] == -10, y == 1, z == 0};
events = {WhenEvent[y[t] == 0,
{y[t] -> 0, z[t] -> -(70/100) z[t]}]};
sol = DSolve[Join[eqns, events], {y[t], z[t]}, {t, 0, 2},
Method -> {"Events", "MaxEvents" -> 3}]


DSolve::maxev: The maximum number of events has been reached. The currently computed solution has been returned.

(* output: Piecewise with three cases *)


### Method -> "Holonomic"

For linear equations, it produces a DifferentialRoot:

DSolve[y'[x] == y[x], y, x, Method -> "Holonomic"]
(*
{{y -> DifferentialRoot[
Function[{\[FormalY], \[FormalX]},
{-\[FormalY][\[FormalX]] + \[FormalY]'[\[FormalX]] == 0,
\[FormalY] == C}]]}}
*)


Unceremoniously fails on nonlinear equations:

DSolve[y'[x] == y[x]^2, y, x, Method -> "Holonomic"]
(*
DSolve[Derivative[y][x] == y[x]^2, y, x, Method -> "Holonomic"]
*)