61.10.3 problem 16

Internal problem ID [12111]
Book : Handbook of exact solutions for ordinary differential equations. By Polyanin and Zaitsev. Second edition
Section : Chapter 1, section 1.2. Riccati Equation. subsection 1.2.6-2. Equations with cosine.
Problem number : 16
Date solved : Sunday, March 30, 2025 at 10:50:51 PM
CAS classification : [_Riccati]

\begin{align*} y^{\prime }&=y^{2}+\lambda ^{2}+c \cos \left (\lambda x +a \right )^{n} \cos \left (\lambda x +b \right )^{-n -4} \end{align*}

Maple
ode:=diff(y(x),x) = y(x)^2+lambda^2+c*cos(lambda*x+a)^n*cos(lambda*x+b)^(-n-4); 
dsolve(ode,y(x), singsol=all);
 
\[ \text {No solution found} \]
Mathematica
ode=D[y[x],x]==y[x]^2+\[Lambda]^2+c*Cos[\[Lambda]*x+a]^n*Cos[\[Lambda]*x+b]^(-n-4); 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 

Not solved

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