Find the solution of the differential equation that satisfies the given initial condition $~y'=\frac{x~y~\sin x}{y+1}, ~~~~y(0)=1~$ Find the solution of the differential equation that satisfies the given initial condition $$~y'=\frac{x~y~\sin x}{y+1}, ~~~~~~y(0)=1~$$
When I integrate this function I get 
$$y+\ln(y)= -x\cos x + \sin x + C.$$
Have I integrated the function correctly? 
How do I complete the second part of the question $~y(0)=1~$

What you can do is to use the so-called Separation of variables (see for example https://en.wikipedia.org/wiki/Separation_of_variables):


*

*Write $y' = \frac{dy}{dx}$

*Do the following transformation: $\frac{dy}{dx} = \frac{xy \sin(x)}{y+1} \Longleftrightarrow \frac{y+1}{y} dy = x\sin(x) dx$. Now integrate both sides (with respect to the corresponding variable), arriving at

*$\int (1 + \frac{1}{y}) dy = \int x \sin(x) dx \Longleftrightarrow y + \ln(y) = \sin(x) - x \cos(x) + C$.

*To get the integration constant $C$, set $x = 0$ and $y = 1$, then: $1 = 0 + C \Longleftrightarrow C = 1$.

*You'll not be able to solve the equation in 3 for the function $y = y(x)$ in terms of elementary functions (such as trigonometric functions, exponential/logarithmic functions etc.); But what you can do is to use the so-called Lambert W function, see https://en.wikipedia.org/wiki/Lambert_W_function. Then you will get $y(x) = W(e^{\sin(x) - x \cos(x) + 1})$.

