4.1.32 \(y'(x)=\sin (2 x)-y(x) \tan (x)\)

ODE
\[ y'(x)=\sin (2 x)-y(x) \tan (x) \] ODE Classification

[_linear]

Book solution method
Linear ODE

Mathematica
cpu = 0.0193996 (sec), leaf count = 15

\[\left \{\left \{y(x)\to \cos (x) \left (c_1-2 \cos (x)\right )\right \}\right \}\]

Maple
cpu = 0.008 (sec), leaf count = 13

\[ \left \{ y \relax (x ) =\cos \relax (x ) \left (-2\,\cos \relax (x ) +{\it \_C1} \right ) \right \} \] Mathematica raw input

DSolve[y'[x] == Sin[2*x] - Tan[x]*y[x],y[x],x]

Mathematica raw output

{{y[x] -> (C[1] - 2*Cos[x])*Cos[x]}}

Maple raw input

dsolve(diff(y(x),x) = sin(2*x)-y(x)*tan(x), y(x),'implicit')

Maple raw output

y(x) = cos(x)*(-2*cos(x)+_C1)