I want to integrate $\int \frac{1}{2x}dx$
The way I would solve it: $$\frac{1}{a}f(ax + b)$$ where $$f(x) = \ln x$$ My answer $\frac{1}{2}\ln(2x) + k$
The correct way seems to be to factor out $\frac{1}{2}$ from the initial integral, leaving $\int \frac{1}{x}$. The correct answer $\frac{1}{2}\ln(x) + k$
Where did I go wrong?
Say $I=\int \frac {1}{2x} dx$.
Therefore, $$\begin {align} & I =\int \frac {1}{2x} dx \\ & =\int \frac {1}{2}\cdot \frac {2}{2x} dx \\ & =\frac {1}{2}\cdot \int \frac {1}{2x} d(2x) \\ & =\frac {1}{2} \ln (2x) + k\end{align}$$
So you see that the integration is totally correct. There is no flaw in it. However the integration constant $k $ will make the difference and give the correct value as predicted by the other answer in case of a definite integral.