To solve the integral \( \int \frac{3x - 1}{\sqrt{x^2 + 9}} \, dx \), we can break it down into two separate integrals. Here’s a step-by-step solution:
### Step 1: Separate the Integral
We can rewrite the integral as:
\[
\int \frac{3x}{\sqrt{x^2 + 9}} \, dx - \int \frac{1}{\sqrt{x^2 + 9}} \, dx
\]
### Step 2: Solve the First Integral
For the first integral \( \int \frac{3x}{\sqrt{x^2 + 9}} \, dx \), we can use the substitution:
\[
t = x^2 + 9 \implies dt = 2x \, dx \implies dx = \frac{dt}{2x}
\]
Thus, we have:
\[
\int \frac{3x}{\sqrt{x^2 + 9}} \, dx = 3 \int \frac{x}{\sqrt{t}} \cdot \frac{dt}{2x} = \frac{3}{2} \int t^{-1/2} \, dt
\]
Now, integrating \( t^{-1/2} \):
\[
\frac{3}{2} \cdot 2 t^{1/2} = 3 \sqrt{t} = 3 \sqrt{x^2 + 9}
\]
### Step 3: Solve the Second Integral
Now, we solve the second integral \( \int \frac{1}{\sqrt{x^2 + 9}} \, dx \). This integral can be solved using the formula:
\[
\int \frac{1}{\sqrt{x^2 + a^2}} \, dx = \ln |x + \sqrt{x^2 + a^2}| + C
\]
For our case, \( a = 3 \):
\[
\int \frac{1}{\sqrt{x^2 + 9}} \, dx = \ln |x + \sqrt{x^2 + 9}|
\]
### Step 4: Combine the Results
Combining both results, we have:
\[
\int \frac{3x - 1}{\sqrt{x^2 + 9}} \, dx = 3\sqrt{x^2 + 9} - \ln |x + \sqrt{x^2 + 9}| + C
\]
### Final Answer
Thus, the final answer is:
\[
\int \frac{3x - 1}{\sqrt{x^2 + 9}} \, dx = 3\sqrt{x^2 + 9} - \ln |x + \sqrt{x^2 + 9}| + C
\]