Step 1: Understanding the Concept:
Notice that \(\frac{d}{dx}(xe^x) = (x + 1)e^x\). This suggests the substitution \(t = xe^x\).
Step 2: Key Formula or Approach:
Multiply numerator and denominator by \(e^x\): \(\frac{(x+1)e^x}{xe^x(1 + xe^x)}\).
Step 3: Detailed Explanation:
With \(t = xe^x\), \(dt = (x + 1)e^x\,dx\), so the integral is \(\int\frac{dt}{t(1 + t)}\).
Partial fractions: \(\frac{1}{t(1+t)} = \frac1t - \frac{1}{1+t}\).
\[ \int\left(\frac1t - \frac1{1+t}\right)dt = \log t - \log(1 + t) + c = \log\frac{xe^x}{1 + xe^x} + c \]
Final Answer:
The integral is \(\log\frac{xe^x}{1 + xe^x} + c\), option (A).
\[ \boxed{\log\frac{xe^x}{1+xe^x}+c} \]