15.12.23 problem 23

Internal problem ID [3167]
Book : Differential Equations by Alfred L. Nelson, Karl W. Folley, Max Coral. 3rd ed. DC heath. Boston. 1964
Section : Exercise 20, page 90
Problem number : 23
Date solved : Tuesday, March 04, 2025 at 04:04:34 PM
CAS classification : [[_3rd_order, _missing_y]]

\begin{align*} y^{\prime \prime \prime }+y^{\prime }&=\tan \left (x \right ) \end{align*}

Maple. Time used: 0.008 (sec). Leaf size: 71
ode:=diff(diff(diff(y(x),x),x),x)+diff(y(x),x) = tan(x); 
dsolve(ode,y(x), singsol=all);
 
\[ y = \frac {i \left ({\mathrm e}^{i x}-{\mathrm e}^{-i x}\right ) \ln \left (\frac {i {\mathrm e}^{i x}-1}{-{\mathrm e}^{i x}+i}\right )}{2}+c_{1} \sin \left (x \right )-c_2 \cos \left (x \right )-\ln \left ({\mathrm e}^{i x}-i\right )-\ln \left ({\mathrm e}^{i x}+i\right )+c_3 +\ln \left ({\mathrm e}^{i x}\right ) \]
Mathematica. Time used: 0.053 (sec). Leaf size: 35
ode=D[y[x],{x,3}]+D[y[x],x]==Tan[x]; 
ic={}; 
DSolve[{ode,ic},y[x],x,IncludeSingularSolutions->True]
 
\[ y(x)\to -\sin (x) \text {arctanh}(\sin (x))-\frac {1}{2} \log \left (\cos ^2(x)\right )-c_2 \cos (x)+c_1 \sin (x)+c_3 \]
Sympy. Time used: 0.347 (sec). Leaf size: 36
from sympy import * 
x = symbols("x") 
y = Function("y") 
ode = Eq(-tan(x) + Derivative(y(x), x) + Derivative(y(x), (x, 3)),0) 
ics = {} 
dsolve(ode,func=y(x),ics=ics)
 
\[ y{\left (x \right )} = C_{1} + C_{3} \cos {\left (x \right )} + \left (C_{2} + \frac {\log {\left (\sin {\left (x \right )} - 1 \right )}}{2} - \frac {\log {\left (\sin {\left (x \right )} + 1 \right )}}{2}\right ) \sin {\left (x \right )} - \log {\left (\cos {\left (x \right )} \right )} \]