How do I solve this linear equation?
y'+2ytan(x)=sin(x)
The answer can be found here: y'+2ytan(x)=sin(x) - Wolfram|Alpha
But I would be really greatful if someone could explain the steps involved.
How do I solve this linear equation?
y'+2ytan(x)=sin(x)
The answer can be found here: y'+2ytan(x)=sin(x) - Wolfram|Alpha
But I would be really greatful if someone could explain the steps involved.
first thing you need to do is find you integrating factor which will be
$\displaystyle 2\tan{x}$
Next
$\displaystyle e^{\int{2\tan{x}}}dx = e^{-2\ln{\cos{x}}} = e^{\ln{\cos^{-2}{x}}} = \cos^{-2}{x} = \sec^2{x}$
so now
$\displaystyle y\sec^2{x} = \int \sin{x}\sec^2{x}dx = \int\sec{x}\tan{x}$
integrate that and you get
$\displaystyle y\sec^2{x} = \sec{x} + C$
divide by $\displaystyle \sec^2{x}$ and get
$\displaystyle y = \cos{x} +C\cos^2{x}$