28.1.108 problem 131

Internal problem ID [4414]
Book : Differential equations for engineers by Wei-Chau XIE, Cambridge Press 2010
Section : Chapter 2. First-Order and Simple Higher-Order Differential Equations. Page 78
Problem number : 131
Date solved : Sunday, March 30, 2025 at 03:18:08 AM
CAS classification : [[_3rd_order, _missing_y]]

\begin{align*} y^{\prime \prime \prime }&=2 \left (y^{\prime \prime }-1\right ) \cot \left (x \right ) \end{align*}

Maple. Time used: 0.001 (sec). Leaf size: 33
ode:=diff(diff(diff(y(x),x),x),x) = 2*(diff(diff(y(x),x),x)-1)*cot(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {\left (c_1 -1\right ) \cos \left (2 x \right )}{8}+\frac {c_1 \,x^{2}}{4}+\frac {x^{2}}{4}+c_2 x -\frac {c_1}{8}+c_3 +\frac {1}{8} \]
Mathematica. Time used: 0.142 (sec). Leaf size: 33
ode=D[y[x],{x,3}]==2*(D[y[x],{x,2}]-1)*Cot[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to \frac {1}{4} (2+c_1) x^2+c_3 x+\frac {1}{8} c_1 \cos (2 x)+c_2 \]
Sympy. Time used: 0.641 (sec). Leaf size: 24
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq((2 - 2*Derivative(y(x), (x, 2)))/tan(x) + Derivative(y(x), (x, 3)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} + C_{2} x - \frac {C_{3} \sin ^{2}{\left (x \right )}}{4} + \frac {x^{2} \left (C_{3} + 2\right )}{4} \]