Solution of the differential equation \(\displaystyle\frac{dy}{dx}=\cos(x+y+3)\) is:
Answer & explanation
Correct answer: option 3
The correct answer is Option (3) → \(y=2\tan^{-1}(x+c)-x-3\)
The right side depends on x + y + 3 only, so substitute v = x + y + 3:
\( \displaystyle \frac{dv}{dx} = 1 + \frac{dy}{dx} = 1 + \cos v \)
Now the variables separate:
\( \displaystyle \frac{dv}{1+\cos v} = dx \)
Using \(1 + \cos v = 2\cos^2\frac{v}{2}\):
\( \displaystyle \int\frac{1}{2}\sec^2\frac{v}{2}\,dv = \int dx \)
\( \displaystyle \tan\frac{v}{2} = x + c \)
\(v = 2\tan^{-1}(x + c)\)
Putting back v = x + y + 3:
\(x + y + 3 = 2\tan^{-1}(x + c)\)
\(y = 2\tan^{-1}(x + c) - x - 3\)