4.2.46 \(y'(x)=f(x) y(x)+g(x) y(x)^k\)

ODE
\[ y'(x)=f(x) y(x)+g(x) y(x)^k \] ODE Classification

[_Bernoulli]

Book solution method
The Bernoulli ODE

Mathematica
cpu = 0.493421 (sec), leaf count = 64

\[\left \{\left \{y(x)\to \left (e^{-(k-1) \int _1^x f(K[1]) \, dK[1]} \left (c_1-(k-1) \int _1^x g(K[2]) e^{(k-1) \int _1^{K[2]} f(K[1]) \, dK[1]} \, dK[2]\right )\right ){}^{\frac {1}{1-k}}\right \}\right \}\]

Maple
cpu = 0.019 (sec), leaf count = 48

\[ \left \{ \left ( y \left ( x \right ) \right ) ^{1-k}+{\frac {-\int \!-{{\rm e}^{\int \!f \left ( x \right ) \left ( k-1 \right ) \,{\rm d}x}}g \left ( x \right ) \left ( k-1 \right ) \,{\rm d}x-{\it \_C1}}{{{\rm e}^{\int \!f \left ( x \right ) \left ( k-1 \right ) \,{\rm d}x}}}}=0 \right \} \] Mathematica raw input

DSolve[y'[x] == f[x]*y[x] + g[x]*y[x]^k,y[x],x]

Mathematica raw output

{{y[x] -> ((C[1] - (-1 + k)*Integrate[E^((-1 + k)*Integrate[f[K[1]], {K[1], 1, K
[2]}])*g[K[2]], {K[2], 1, x}])/E^((-1 + k)*Integrate[f[K[1]], {K[1], 1, x}]))^(1
 - k)^(-1)}}

Maple raw input

dsolve(diff(y(x),x) = f(x)*y(x)+g(x)*y(x)^k, y(x),'implicit')

Maple raw output

y(x)^(1-k)+(-Int(-exp(Int(f(x)*(k-1),x))*g(x)*(k-1),x)-_C1)/exp(Int(f(x)*(k-1),x
)) = 0