Given that $\displaystyle f(x)=\frac{1}{3x}-2\sec^2\left(\frac{x}{2}\right)-e^{-2x+3}$, evaluate $\int f(x) \mathrm{d}x$.
Attempt: $$\begin{aligned} \int f(x) \mathrm{d}x&=\int \left[ \frac{x}{3}-2\sec^2\left(\frac{x}{2}\right)-e^{-2x+3}\right]\mathrm{d}x \\ &=\frac{x^2}{6}-4\tan\left(\frac{x}{2}\right)-\frac{e^{-2x+3}}{-2}+C \\ &= \frac{x^2}{6}-4\tan\left(\frac{x}{2}\right)+\frac{e^{-2x+3}}{2}+C \end{aligned}$$
Did I find the antiderivative correctly? Any feedback would be appreciated.
Instead of evaluating $$\int \left(\frac{1}{3x}-2\sec^2\left(\frac x2\right)-e^{-2x+3}\right)dx$$ You seem to have evaluated $$\int \left(\frac{x}{3}-2\sec^2\left(\frac x2\right)-e^{-2x+3}\right)dx$$
Your evaluation for the incorrect integrand is correct though, and to get the actual answer, you only need to change the first term from $\frac{x}{3}$ to $\frac{1}{3x}$, whose integration will involve the natural logarithm.
Can you finish?