Answer: \(\frac{\mathrm dy}{\mathrm dx}=(3x+1)\mathrm e^{3x+2}\), and \(\int x\mathrm e^{3x+2}\,\mathrm dx=\frac13x\mathrm e^{3x+2}-\frac19\mathrm e^{3x+2}+C\).
Set up the integral using the correct limits or antiderivative first. When definite integration is used, evaluate the upper limit and lower limit separately before subtracting.
Use the product rule on \(y=x\mathrm e^{3x+2}\):
\(\frac{\mathrm dy}{\mathrm dx}=x\cdot3\mathrm e^{3x+2}+1\cdot\mathrm e^{3x+2}.\)
Therefore
\(\frac{\mathrm dy}{\mathrm dx}=(3x+1)\mathrm e^{3x+2}.\)
From this result,
\(3x\mathrm e^{3x+2}=\frac{\mathrm dy}{\mathrm dx}-\mathrm e^{3x+2}.\)
So
\(\int x\mathrm e^{3x+2}\,\mathrm dx=\frac13\int3x\mathrm e^{3x+2}\,\mathrm dx.\)
Using the derivative found in part (a),
\(\int3x\mathrm e^{3x+2}\,\mathrm dx=x\mathrm e^{3x+2}-\int\mathrm e^{3x+2}\,\mathrm dx.\)
Now
\(\int\mathrm e^{3x+2}\,\mathrm dx=\frac13\mathrm e^{3x+2}.\)
Hence
\(\int x\mathrm e^{3x+2}\,\mathrm dx=\frac13x\mathrm e^{3x+2}-\frac19\mathrm e^{3x+2}+C.\)
This gives the required answer: \(\frac{\mathrm dy}{\mathrm dx}=(3x+1)\mathrm e^{3x+2}\), and \(\int x\mathrm e^{3x+2}\,\mathrm dx=\frac13x\mathrm e^{3x+2}-\frac19\mathrm e^{3x+2}+C\).