Concept:
When the numerator resembles the derivative of the denominator, use substitution:
\[
\int \frac{f'(x)}{f(x)} dx = \ln|f(x)| + C
\]
If not exact, split the numerator appropriately.
Step 1: Let
\[
I = \int \frac{x+2}{2x^2 + 6x + 5} dx
\]
Differentiate denominator:
\[
\frac{d}{dx}(2x^2 + 6x + 5) = 4x + 6
\]
We express numerator in terms of \(4x+6\):
\[
x+2 = \frac{1}{4}(4x+6) + \frac{1}{2}
\]
Step 2: Split the integral
\[
I = \int \frac{\frac{1}{4}(4x+6)}{2x^2+6x+5} dx + \int \frac{\frac{1}{2}}{2x^2+6x+5} dx
\]
\[
I = \frac{1}{4} \int \frac{4x+6}{2x^2+6x+5} dx + \frac{1}{2} \int \frac{dx}{2x^2+6x+5}
\]
Step 3: First integral (log form)
\[
= \frac{1}{4} \ln|2x^2+6x+5|
\]
Step 4: Second integral (complete square)
\[
2x^2+6x+5 = 2(x^2+3x) + 5
\]
\[
= 2\left[(x+\tfrac{3}{2})^2 + \tfrac{1}{4}\right]
\]
So,
\[
\int \frac{dx}{2x^2+6x+5}
= \frac{1}{2} \int \frac{dx}{(x+\tfrac{3}{2})^2 + (\tfrac{1}{2})^2}
\]
Using:
\[
\int \frac{dx}{x^2+a^2} = \frac{1}{a}\tan^{-1}\left(\frac{x}{a}\right)
\]
\[
= \frac{1}{2} \cdot 2 \tan^{-1}(2x+3)
= \tan^{-1}(2x+3)
\]
Step 5: Multiply constant
\[
\frac{1}{2} \times \tan^{-1}(2x+3) = \frac{1}{2}\tan^{-1}(2x+3)
\]
Final Answer:
\[
\boxed{\frac{1}{4}\ln|2x^2+6x+5| + \frac{1}{2}\tan^{-1}(2x+3) + C}
\]
Explanation:
The numerator was decomposed into a derivative form plus a constant. One part gave a logarithm, while the remaining quadratic produced an inverse tangent after completing the square.