4.1.15 \(y'(x)=1-y(x) \cot (x)\)

ODE
\[ y'(x)=1-y(x) \cot (x) \] ODE Classification

[_linear]

Book solution method
Linear ODE

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

\[\left \{\left \{y(x)\to c_1 \csc (x)-\cot (x)\right \}\right \}\]

Maple
cpu = 0.007 (sec), leaf count = 15

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

DSolve[y'[x] == 1 - Cot[x]*y[x],y[x],x]

Mathematica raw output

{{y[x] -> -Cot[x] + C[1]*Csc[x]}}

Maple raw input

dsolve(diff(y(x),x) = 1-y(x)*cot(x), y(x),'implicit')

Maple raw output

y(x) = (-cos(x)+_C1)/sin(x)