50.14.15 problem 2(g)

Internal problem ID [8053]
Book : Differential Equations: Theory, Technique, and Practice by George Simmons, Steven Krantz. McGraw-Hill NY. 2007. 1st Edition.
Section : Chapter 2. Problems for Review and Discovery. Drill excercises. Page 105
Problem number : 2(g)
Date solved : Monday, January 27, 2025 at 03:39:58 PM
CAS classification : [[_2nd_order, _quadrature]]

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

With initial conditions

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

Solution by Maple

Time used: 1.082 (sec). Leaf size: 130

dsolve([diff(y(x),x$2)=tan(x),y(1) = 1, D(y)(1) = -1],y(x), singsol=all)
 
\[ y = \frac {\left (-i {\mathrm e}^{2 i}-i\right ) \operatorname {polylog}\left (2, -{\mathrm e}^{2 i x}\right )+2 x \left ({\mathrm e}^{2 i}+1\right ) \ln \left ({\mathrm e}^{2 i x}+1\right )+\left (i {\mathrm e}^{2 i}+i\right ) \operatorname {polylog}\left (2, -{\mathrm e}^{2 i}\right )+\left (-2 \,{\mathrm e}^{2 i}-2\right ) \ln \left ({\mathrm e}^{2 i}+1\right )+\left (2 \ln \left (\cos \left (1\right )\right ) x -2 x \ln \left (\cos \left (x \right )\right )+\left (-2 x +2\right ) \tan \left (1\right )-i x^{2}+\left (-2-2 i\right ) x +4+3 i\right ) {\mathrm e}^{2 i}+2 \ln \left (\cos \left (1\right )\right ) x -2 x \ln \left (\cos \left (x \right )\right )+\left (-2 x +2\right ) \tan \left (1\right )-i x^{2}+\left (-2+2 i\right ) x +4-i}{2 \,{\mathrm e}^{2 i}+2} \]

Solution by Mathematica

Time used: 0.032 (sec). Leaf size: 86

DSolve[{D[y[x],{x,2}]==Tan[x],{y[1]==1,Derivative[1][y][1]==-1}},y[x],x,IncludeSingularSolutions -> True]
 
\[ y(x)\to \frac {1}{2} \left (-i \operatorname {PolyLog}\left (2,-e^{2 i x}\right )+i \operatorname {PolyLog}\left (2,-e^{2 i}\right )-i x^2-2 x+2 x \log \left (1+e^{2 i x}\right )-2 x \log (\cos (x))+2 x \log (\cos (1))+(4+i)-2 \log \left (1+e^{2 i}\right )\right ) \]