Question:

If \( y = f(x) \) is the solution of the differential equation \( (1 + \sin x) \frac{dy}{dx} + \cos x = 0 \), such that \( f(0) = 0 \), then \( f\left( \frac{\pi}{2} \right) \) is equal to

Show Hint

For integrals of the form \( \int \frac{f'(x)}{f(x)} dx \), the result is always \( \ln|f(x)| + C \).
Updated On: Apr 2, 2026
  • \( \ln 2 \)
  • \( -\ln 2 \)
  • \( \ln 3 \)
  • \( \ln 4 \)
Hide Solution
collegedunia
Verified By Collegedunia

The Correct Option is B

Solution and Explanation

Step 1: Understanding the Concept The given equation is a first-order ordinary differential equation. To find the solution \( y = f(x) \), we need to separate the variables \( x \) and \( y \) and integrate both sides of the equation.

Step 2: Separating Variables and Integration The given equation is: \( (1 + \sin x) \frac{dy}{dx} + \cos x = 0 \). Rearranging terms: \( (1 + \sin x) \frac{dy}{dx} = -\cos x \) which simplifies to \( \frac{dy}{dx} = -\frac{\cos x}{1 + \sin x} \). Integrating both sides: \( \int dy = -\int \frac{\cos x}{1 + \sin x} dx \). Let \( u = 1 + \sin x \), then \( du = \cos x dx \). The integral becomes: \( y = -\ln|1 + \sin x| + C \).

Step 3: Finding the Constant of Integration Using \( f(0) = 0 \): \( 0 = -\ln|1 + \sin 0| + C \). Since \( \sin 0 = 0 \), we get \( 0 = -\ln(1) + C \), so \( C = 0 \). Thus, \( f(x) = -\ln(1 + \sin x) \).

Step 4: Final Answer Now, calculate \( f\left( \frac{\pi}{2} \right) = -\ln\left(1 + \sin \frac{\pi}{2}\right) \). Since \( \sin \frac{\pi}{2} = 1 \), \( f\left( \frac{\pi}{2} \right) = -\ln(1 + 1) = -\ln 2 \). Therefore, the correct option is (2).

Was this answer helpful?
0
0