Answer:
y= x + cosx
Step-by-step explanation:
[tex]cosx\frac{\mathrm{d}y }{\mathrm{d} x}+(sinx)y-1=0\\cosx\frac{\mathrm{d}y }{\mathrm{d} x}+(sinx)y=1\\\frac{\mathrm{d}y }{\mathrm{d} x}+(tanx)y=secx[/tex]
now equation is in linear differential form
finding integrating factor;
I.F. = [tex]e^{\int tanx dx} = e^{ln\ secx} = secx[/tex]
[tex]y=\frac{1}{I.F}(\int Q dx + c)[/tex]
[tex]y=\dfrac{1}{secx}(\int secx dx + c)[/tex]
[tex]y=\int dx + c(cosx)\\y= x + c(cosx)[/tex]
using y(0) = 1
1 = 0 + c(cos 0)
c = 1
hence solution becomes
y= x + cosx