81.7.8 problem 8-7

Internal problem ID [21582]
Book : The Differential Equations Problem Solver. VOL. I. M. Fogiel director. REA, NY. 1978. ISBN 78-63609
Section : Chapter 8. Riccati Equation. Page 124.
Problem number : 8-7
Date solved : Thursday, October 02, 2025 at 07:58:11 PM
CAS classification : [_Riccati]

\begin{align*} y^{\prime }&=1+x +x^{2} \cos \left (x \right )-\left (1+4 x \cos \left (x \right )\right ) y+2 y^{2} \cos \left (x \right ) \end{align*}
Maple
ode:=diff(y(x),x) = 1+x+x^2*cos(x)-(1+4*x*cos(x))*y(x)+2*y(x)^2*cos(x); 
dsolve(ode,y(x), singsol=all);
 
\[ \text {No solution found} \]
Mathematica
ode=D[y[x],x]==  (1+x+x^2*Cos[x])-(1+4*x*Cos[x])*y[x]+2*y[x]^2*Cos[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 

Not solved

Sympy
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-x**2*cos(x) - x + (4*x*cos(x) + 1)*y(x) - 2*y(x)**2*cos(x) + Derivative(y(x), x) - 1,0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
NotImplementedError : The given ODE -x**2*cos(x) + 4*x*y(x)*cos(x) - x - 2*y(x)**2*cos(x) + y(x) + Derivative(y(x), x) - 1 cannot be solved by the factorable group method