Sage: Ticket #28319: Some ODEs with known solutions cause Sage to hang indefinitely
https://trac.sagemath.org/ticket/28319
<p>
Maxima's <code>contrib_ode</code> package links to several other Maxima packages, including <code>kovacicODE</code>, which implements Kovacic's algorithm. This algorithm finds all elementary solutions to a second-order linear, homogeneous differential equation with rational coefficients.
</p>
<p>
Although Sage has an interface to this package, it doesn't seem to work right. I checked this in Sage 8.9.beta4.
</p>
<p>
For example, this differential equation is Example 1 in §3.2 of Kovacic's original paper [1]:
</p>
<pre class="wiki">sage: r = 1/4*(4*x^6 - 8*x^5 + 12*x^4 + 4*x^3 + 7*x^2 - 20*x + 4)/x^4
sage: y = function('y')(x)
sage: desolve(diff(y,x,2) - r*y, y)
</pre><p>
This yields the message "Maxima was unable to solve this ODE. Consider to set option contrib_ode to True."
</p>
<p>
This message is intelligible, but is not grammatically correct. Running <code>desolve</code> with <code>contrib_ode=True</code>:
</p>
<pre class="wiki">sage: desolve(diff(y,x,2) - r*y, y, contrib_ode=True)
</pre><p>
causes Sage to hang until a keyboard interrupt. <code>ps</code> doesn't show maxima running at all during this time.
</p>
<p>
[1] gives a closed-form solution that can be easily verified:
</p>
<pre class="wiki">sage: f = x^(-3/2)*(x^2-1)*exp(-1/x+x^2/2-x)
sage: expand(diff(f,x,2) - r*f)
0
</pre><p>
We should investigate this problem, fix it (and the grammar of the error message), and possibly add all of the examples from [1] to our test suite.
</p>
<p>
[1]: Kovacic, <em>An algorithm for solving second order linear homogeneous differential equations</em>, J. Symbolic Comput. 2 (1986), no. 1, 3–43. MR 839134 (88c:12011)
</p>
en-usSagehttps://trac.sagemath.org/chrome/site/logo_sagemath_trac.png
https://trac.sagemath.org/ticket/28319
Trac 1.2Erik BrayMon, 30 Dec 2019 14:48:17 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:1
https://trac.sagemath.org/ticket/28319#comment:1
<ul>
<li><strong>milestone</strong>
changed from <em>sage-8.9</em> to <em>sage-9.1</em>
</li>
</ul>
<p>
Ticket retargeted after milestone closed
</p>
TicketMatthias KöppeTue, 14 Apr 2020 19:41:51 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:2
https://trac.sagemath.org/ticket/28319#comment:2
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.1</em> to <em>sage-9.2</em>
</li>
</ul>
<p>
Batch modifying tickets that will likely not be ready for 9.1, based on a review of the ticket title, branch/review status, and last modification date.
</p>
TicketMatthias KöppeSat, 29 Aug 2020 16:37:33 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:3
https://trac.sagemath.org/ticket/28319#comment:3
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.2</em> to <em>sage-9.3</em>
</li>
</ul>
TicketMatthias KöppeSat, 13 Feb 2021 20:51:01 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:4
https://trac.sagemath.org/ticket/28319#comment:4
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.3</em> to <em>sage-9.4</em>
</li>
</ul>
<p>
Setting new milestone based on a cursory review of ticket status, priority, and last modification date.
</p>
TicketMatthias KöppeMon, 19 Jul 2021 01:43:17 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:5
https://trac.sagemath.org/ticket/28319#comment:5
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.4</em> to <em>sage-9.5</em>
</li>
</ul>
TicketMatthias KöppeSat, 18 Dec 2021 19:41:23 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:6
https://trac.sagemath.org/ticket/28319#comment:6
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.5</em> to <em>sage-9.6</em>
</li>
</ul>
TicketMatthias KöppeTue, 03 May 2022 15:17:06 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:7
https://trac.sagemath.org/ticket/28319#comment:7
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.6</em> to <em>sage-9.7</em>
</li>
</ul>
TicketMatthias KöppeMon, 19 Sep 2022 18:58:47 GMTmilestone changed
https://trac.sagemath.org/ticket/28319#comment:8
https://trac.sagemath.org/ticket/28319#comment:8
<ul>
<li><strong>milestone</strong>
changed from <em>sage-9.7</em> to <em>sage-9.8</em>
</li>
</ul>
Ticket