To solve the integral \( \int \sin^{-1} \left( \sqrt{\frac{x}{a+x}} \right) dx \), we can follow these steps:
### Step 1: Substitution
Let’s start by substituting \( x = a \tan^2 \theta \). This means \( dx = 2a \tan \theta \sec^2 \theta \, d\theta \).
### Step 2: Change the Integral
Now, substitute \( x \) and \( dx \) in the integral:
\[
\int \sin^{-1} \left( \sqrt{\frac{a \tan^2 \theta}{a + a \tan^2 \theta}} \right) \cdot 2a \tan \theta \sec^2 \theta \, d\theta
\]
### Step 3: Simplify the Argument of \( \sin^{-1} \)
The expression inside the \( \sin^{-1} \) simplifies as follows:
\[
\sqrt{\frac{a \tan^2 \theta}{a(1 + \tan^2 \theta)}} = \sqrt{\frac{\tan^2 \theta}{1 + \tan^2 \theta}} = \frac{\tan \theta}{\sec \theta} = \sin \theta
\]
Thus, we have:
\[
\int \sin^{-1}(\sin \theta) \cdot 2a \tan \theta \sec^2 \theta \, d\theta
\]
### Step 4: Use the Identity for \( \sin^{-1} \)
Since \( \sin^{-1}(\sin \theta) = \theta \) for \( \theta \) in the range \( \left[-\frac{\pi}{2}, \frac{\pi}{2}\right] \), we can rewrite the integral:
\[
2a \int \theta \tan \theta \sec^2 \theta \, d\theta
\]
### Step 5: Integration by Parts
Let \( u = \theta \) and \( dv = \tan \theta \sec^2 \theta \, d\theta \). Then, \( du = d\theta \) and \( v = \tan^2 \theta / 2 \).
Using integration by parts:
\[
\int u \, dv = uv - \int v \, du
\]
This gives:
\[
2a \left( \frac{\theta \tan^2 \theta}{2} - \int \frac{\tan^2 \theta}{2} \, d\theta \right)
\]
### Step 6: Integrate \( \tan^2 \theta \)
Recall that \( \tan^2 \theta = \sec^2 \theta - 1 \):
\[
\int \tan^2 \theta \, d\theta = \int (\sec^2 \theta - 1) \, d\theta = \tan \theta - \theta
\]
Thus,
\[
\int \tan^2 \theta \, d\theta = \tan \theta - \theta
\]
### Step 7: Substitute Back
Substituting back, we have:
\[
2a \left( \frac{\theta \tan^2 \theta}{2} - \frac{1}{2} \left( \tan \theta - \theta \right) \right)
\]
This simplifies to:
\[
a \theta \tan^2 \theta - a \left( \tan \theta - \theta \right)
\]
### Step 8: Replace \( \theta \) with \( x \)
Recall that \( \theta = \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) \) and \( \tan \theta = \sqrt{\frac{x}{a}} \):
\[
= a \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) \cdot \frac{x}{a} - a \left( \sqrt{\frac{x}{a}} - \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) \right) + C
\]
This gives the final result:
\[
= x \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) - a \sqrt{\frac{x}{a}} + a \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) + C
\]
### Final Answer
\[
= x \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) - \sqrt{ax} + a \tan^{-1} \left( \sqrt{\frac{x}{a}} \right) + C
\]