I wanted to understand how velocity changes over time when applying a constant power to a body of mass $m$. I figured out that in this case, since $$P=d/dt(KE)=d/dt(\frac{1}{2}mv^2),$$ integrating I get finally that $v(t)=\sqrt(\frac{2Pt}{m})$. Very easy here.
Now I want to find the same when at the same time a constant power is applied there is an opposite force, like drag $F_d$, that depends on the velocity of the body. Considering air densit $\rho$, drag coefficient $C_d$ and area $A$, in time $t$ that power would be $$P_d(t)=v(t)F_d(t)= (C_d A \frac{\rho}{2}v^2(t))v(t).$$ Since that power depends on the velocity, I cannot just say $P_{net}=P-P_d$ and proceed as before to obtain a speed over time formula. Could anyone provide any insight on this?